Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
0e946df
Fix split-KV chunk deadlock; scale KV chunks with sequence length
sangeeta0201 Jul 31, 2026
3a931ae
Fix intermittent fused-layer deadlock: widen QKV epoch barrier to all…
sangeeta0201 Aug 1, 2026
3a2440d
Fix degenerate MoE W13->W2 barrier and untruncate device timing average
sangeeta0201 Aug 1, 2026
d99e8c3
Validate multi-layer pointer tables on the host before upload
sangeeta0201 Aug 1, 2026
27ac114
Add MPK_NIL_TRIPWIRE: survivable breadcrumbs for the nil-address fault
sangeeta0201 Aug 1, 2026
1231ff6
Tripwire: sub-phase breadcrumbs for the nil-address fault
sangeeta0201 Aug 1, 2026
e0da2ef
Fence TopK routing data before releasing MoE workers
sangeeta0201 Aug 1, 2026
0681f4c
Refresh all TaskDesc pointer slots in the multi-layer loop
sangeeta0201 Aug 2, 2026
49bd7ac
MI350: fence split-KV partials before the attention chunk barrier
sangeeta0201 Aug 3, 2026
c600e70
Fix MoE W13->W2 barrier deadlock: false sharing between the L2 atomic
sangeeta0201 Aug 3, 2026
6a571d9
Fix MoE deadlock: missing early-clobber on multi-load inline asm
sangeeta0201 Aug 3, 2026
a25a2c6
Add regression test for gfx950 scaled-MFMA pipeline hazards
sangeeta0201 Aug 4, 2026
6f3c42c
Fix two silent gfx950 scaled-MFMA hazards in the four pipelined loops
sangeeta0201 Aug 4, 2026
5c21c37
Perplexity for the MPK GPT-OSS path: logits sink + PPL_MODE
sangeeta0201 Aug 4, 2026
8cd5584
Perplexity sweep 512 -> 32768, and chunk the PPL diagnostics
sangeeta0201 Aug 4, 2026
6ab2a09
PPL_MXFP4_MATCH: score the Torch reference at MPK's weight precision
sangeeta0201 Aug 4, 2026
63b0278
Fix --max-layers not truncating the reference; add raw-logit dump
sangeeta0201 Aug 4, 2026
902d23a
Remove the dead activation-format switches; FP8 is unconditional
sangeeta0201 Aug 4, 2026
aef3e89
Recover most of the f1fa720 latency: narrow the Phase 2 wait, not the…
sangeeta0201 Aug 4, 2026
4f09181
Derive fused-layer barrier values from a deterministic layer index
sangeeta0201 Aug 5, 2026
2dc9a61
Gate the worker-state breadcrumbs behind MPK_WORKER_STATE
sangeeta0201 Aug 5, 2026
671e60c
Scope the attention-chunk fences to the XCD they actually span
sangeeta0201 Aug 5, 2026
386a3ab
Gate the g_ws_dev publication too
sangeeta0201 Aug 5, 2026
4ed604e
Drop the always-on startup/summary diagnostics; ignore build artifacts
sangeeta0201 Aug 5, 2026
ed61f0a
Apply clang-format 15 to the files this branch touches
sangeeta0201 Aug 5, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 19 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -72,4 +72,22 @@ ncu_tmp

#nsys
*.nsys-rep
*.sqlite
*.sqlite

# demo / CI run artifacts
outputs/

# standalone kernel test binaries (tests/standalone/build.sh)
tests/standalone/test_mfma_simple
tests/standalone/test_mfma_pipeline_hazards

# hipcc -save-temps intermediates
*-hip-amdgcn-amd-amdhsa-*.bc
*-hip-amdgcn-amd-amdhsa-*.hipi
*-hip-amdgcn-amd-amdhsa-*.s
*-hip-amdgcn-amd-amdhsa-*.out
*-hip-amdgcn-amd-amdhsa-*.out.resolution.txt
*-host-x86_64-unknown-linux-gnu.bc
*-host-x86_64-unknown-linux-gnu.hipi
*-host-x86_64-unknown-linux-gnu.s
*-hip-amdgcn-amd-amdhsa.hipfb
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ export MODEL_PATH=/path/to/gpt-oss-120b # local GPT-OSS 120B weights (or HF re
export GPU=0 # target GPU id

rm -rf demo/gpt_oss/permanent_output_dir
USE_FP8_ACT=1 HIP_VISIBLE_DEVICES=$GPU \
HIP_VISIBLE_DEVICES=$GPU \
python3 demo/gpt_oss/demo.py --use-mirage \
--model-path "$MODEL_PATH" \
--prompt "Tell me the history of america" \
Expand Down
8 changes: 5 additions & 3 deletions demo/gpt_oss/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ All commands below run from the repo root.

```bash
rm -rf demo/gpt_oss/permanent_output_dir
USE_FP8_ACT=1 HIP_VISIBLE_DEVICES=$GPU \
HIP_VISIBLE_DEVICES=$GPU \
python3 demo/gpt_oss/demo.py --use-mirage \
--model-path "$MODEL_PATH" \
--prompt "Tell me the history of america" \
Expand All @@ -39,7 +39,7 @@ The input prompt is set with `--prompt` (wrap it in double quotes):

```bash
rm -rf demo/gpt_oss/permanent_output_dir
USE_FP8_ACT=1 HIP_VISIBLE_DEVICES=$GPU \
HIP_VISIBLE_DEVICES=$GPU \
python3 demo/gpt_oss/demo.py --use-mirage \
--model-path "$MODEL_PATH" \
--prompt "Explain how transformers work in simple terms" \
Expand All @@ -52,13 +52,15 @@ Notes:
change the token count and make `Decode avg` non-comparable.
- `--max-seq-length` is the total sequence length (prompt + generated tokens). Keep
it at `512` for benchmarking; shorter values give artificially low TPOT.
- The GEMM arithmetic is not selectable: every MI300 kernel runs MXFP4 weights
against FP8 E4M3 activations (E8M0 per-128-element block scales) on
`v_mfma_scale_f32_16x16x128_f8f6f4`, accumulating in f32.

## Required environment

| Variable | Value | Why |
|----------|-------|-----|
| `MIRAGE_HOME` | repo root | Mirage repo root. |
| `USE_FP8_ACT` | `1` | FP8 activations (the benchmark config). |
| `HIP_VISIBLE_DEVICES` | GPU id | Target GPU. |

## Key flags
Expand Down
561 changes: 498 additions & 63 deletions demo/gpt_oss/demo.py

Large diffs are not rendered by default.

Loading
Loading