Repository navigation
Benchmarks - Add experimental MI455X MXFP4 hipBLASLt GEMM - #882
gusui-msft wants to merge 16 commits into
Conversation
There was a problem hiding this comment.
🔵 Needs a closer look
Client flag syntax needs correction, and end-to-end GPU/client behavior remains unvalidated.
1 open finding
What changed in this PR
Adds experimental, opt-in MXFP4 support to the existing ROCm hipBLASLt GEMM benchmark without changing legacy defaults.
Changes:
- Adds device, client capability, argument, and result validation.
- Adds synthetic tests for MXFP4 commands and failure handling.
- Documents requirements, metrics, and pending hardware qualification.
| File | Description |
|---|---|
| tests/benchmarks/micro_benchmarks/test_hipblaslt_function.py | Adds synthetic MXFP4 and invalid-throughput tests. |
| superbench/benchmarks/micro_benchmarks/hipblaslt_function.py | Adds gated MXFP4 execution and validated metrics. |
| docs/user-tutorial/benchmarks/micro-benchmarks.md | Documents experimental usage and validation limits. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #882 +/- ##
==========================================
+ Coverage 86.58% 86.71% +0.12%
==========================================
Files 107 107
Lines 8419 8486 +67
==========================================
+ Hits 7290 7359 +69
+ Misses 1129 1127 -2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
🔵 Needs a closer look
The MXFP4 path has only synthetic coverage, requiring human merge judgment while native gfx950/RocRoller execution, packing and scales, correctness tolerances, and kernel timing remain unvalidated.
No open issues 🎉
1 resolved since last review
Review effort: Balanced
There was a problem hiding this comment.
🔵 Needs a closer look
Human review is needed because the experimental gfx950/ROCm MXFP4 path has only synthetic coverage, leaving vendor packing/scales, verification tolerance, and GPU-event timing unvalidated on hardware.
1 open issue
Review effort: Balanced
There was a problem hiding this comment.
🔵 Needs a closer look
Human review is needed to judge whether the experimental opt-in gate is sufficient given synthetic-only coverage and missing native gfx950 validation of MXFP4 packing, correctness, and verification thresholds.
1 open issue
Review effort: Balanced
There was a problem hiding this comment.
🔵 Needs a closer look
Native gfx950 validation remains pending, so human hardware review is needed to confirm MXFP4 kernel execution, decoded-input verification, the 1e-5 tolerance, and exclusion of setup and verification from measured latency.
No open issues 🎉
1 resolved since last review
Review effort: Balanced
There was a problem hiding this comment.
🔵 Needs a closer look
Pending MI455X/gfx1250 hardware validation leaves native MXFP4 execution, the suitability of the norm_error < 1e-5 bound, and repeatable GPU-event performance unverified by synthetic CPU tests.
No open issues 🎉
Review effort: Balanced
There was a problem hiding this comment.
🔵 Needs a closer look
Target MI455X/gfx1250 hardware qualification remains pending for native MXFP4 execution, the norm_error < 1e-5 bound, and repeatable GPU-event timing with a compatible hipBLASLt client.
No open issues 🎉
Review effort: Balanced
Add an opt-in gfx950 MXFP4 path using the ROCm 7.2.4 client contract: E2M1 inputs, 32-element E8M0 blocks, FP32 output, and mandatory CPU verification. Preserve legacy commands and metrics while rejecting invalid throughput and validating the new result contract.\n\nAdd capability, command, parser, failure, and regression coverage. Native client builds, GPU correctness, kernel evidence, and performance baselines remain pending; no production configuration is enabled. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Pass verify, GPU timing and kernel-info options as standalone boolean switches to the pinned hipBLASLt client. Add a token-contract regression that catches value-consuming syntax independently of the expected command string. Apply the repository-pinned YAPF formatting to both changed Python files. Validate the complete generated argv with the original vendor option parser on CPU and keep native GPU qualification pending. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Require the reported alpha and beta to equal the requested values. Compare their decimal values exactly so alternate printed forms are valid but a different operation cannot produce correctness or performance metrics. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Record experimental metrics only after validating the MXFP4 case. Preserve existing throughput behavior for other precisions, accept equivalent capability text and diagnostic footers, and shorten the tutorial and table-driven regression cases. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Separate recognition of a unique result row from metric validation and apply the same finite-positive rule to device throughput and latency. This keeps the parser within the existing complexity limit without changing the legacy path. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Retain full client help only on failure or explicit raw logging. Exercise the results parser without probing a device or client, and use distinct M/N/K dimensions so a swapped output cannot pass. Keep the MXFP4 metrics in the existing GEMM table. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Keep existing precision arguments, parser formatting and test helpers intact. Restore the public tutorial and leave the example, deployment scope and hardware qualification notes in the PR description instead. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Selecting mxfp4 already opts in to the experimental path. Drop the duplicate boolean option while retaining the default FP16 input, architecture, client and verification checks. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Use the gfx1250 hipBLASLt client contract rather than obsolete block-dimension options. Check B32E8 on both operands, support the MAF2 input pattern, require strict CPU verification and kernel identification, and retain the default and legacy precision behavior. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Consolidate command checks and keep the subprocess failure case that can otherwise record misleading metrics from a valid result row. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Check the advertised scale and initialization values. Let the client reject unsupported ordinary switches during execution, where a nonzero exit already suppresses metrics. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Return argument diagnostics directly and query the visible GPU architecture once. Only classify missing fields or invalid scalar text and case values as client output errors; leave wrapper bookkeeping failures to the benchmark runner. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Use strict verification without the redundant verify flag, and name the row parser and test benchmark factory for what they return. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Reject mixed --in_types whenever mxfp4 or maf2_0 is requested, not only with maf2_0 initialization, so mixed lists with hpl or trig_float fail argument validation instead of aborting device preflight across legacy datatypes. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
e5bc5ed to
56a45be
Compare
There was a problem hiding this comment.
🔵 Needs a closer look
MI455X/gfx1250 hardware qualification is still needed to confirm native MXFP4 execution, calibrate the numerical-error bound, and validate client compatibility and repeatable GPU-event timing.
No open issues 🎉
Review effort: Balanced
Count result headers directly instead of guessing trailing CSV rows, and stop re-parsing hardcoded CLI constants with Decimal while preserving case, kernel, timing and verification guards. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>


Scope
Add
mxfp4to the existing ROCmhipblaslt-gemmwrapper for AMD Instinct MI455X (gfx1250). Usein_types: [mxfp4]with the layout and initialization shown below; FP16 remains the default. Existing FP32/FP16/BF16/FP8 commands and metrics are unchanged. No new package, image, production SKU configuration or threshold is introduced.Use a dedicated benchmark instance with a compatible
hipblaslt-bench. The reference client encodes 32-element E8M0 blocks for both inputs as--scaleA 3 --scaleB 3(B32E8); it does not use separate block row/column switches. The upstream gfx1250 test includes FP4 inputs, FP32 compute and output, TN andmaf2_0initialization.yaml hipblaslt-gemm: parameters: in_types: [mxfp4] shapes: ["130,128,512", "256,256,2048"] transA: T transB: N initialization: maf2_0The path requests one solution, GPU-event timing, kernel information and strict CPU verification. It checks the returned shape, dtypes, scale modes, timing/throughput consistency and verification fields before recording metrics. The wrapper additionally requires
norm_error < 1e-5; that conservative bound needs hardware calibration. Bothmxfp4andmaf2_0require a dedicatedmxfp4benchmark instance. Preflight validates the requested case, reads the GFX target from visible device 0 once, and checks the scale and initialization values advertised by the client. The verification, GPU-timer and kernel-info switches are passed directly to the client; a nonzero exit produces no metrics for that command.tolerant_faildoes not fall back to another precision.Validation