Skip to content

CUDA: Ampere sm_80 in the release fatbins, with the ModelOpt floor named at its refusal - #846

Open
liumorrisclaw wants to merge 3 commits into
ashhart:mainfrom
liumorrisclaw:cuda-ampere-sm80
Open

liumorrisclaw wants to merge 3 commits into
ashhart:mainfrom
liumorrisclaw:cuda-ampere-sm80

Conversation

@liumorrisclaw

Copy link
Copy Markdown
Contributor

What this changes

Carries the Ampere sm_80 row of #840 (my #464) into the native engine.

  • zig/build/cuda.zig: release_sms gains sm_80, so every release fatbin carries an sm_80 SASS image and the check-fatbins release gate demands one (-Dsm=80,86,120,121). The kernels' thread-block-cluster paths are already __CUDA_ARCH__ >= 900-guarded with __trap() fallbacks (qmm_group, qmmf, lane_gemv, probe), and the FP8 and NVFP4 experts form their products as bf16 MMA pairs, so the .cu sources build for compute_80 unchanged.
  • The ModelOpt (FP8/NVFP4) floor becomes one named constant and a pure, tested modeloptRefusal(capability), and the native server renders a refusal at that floor by name: the card, its sm and the reason (decode's split-K sums meet in a thread-block cluster). Every card below sm_89 — the Ampere ones now admitted included — traps there instead of seeing the bare error name. The floor itself stays where it was: the decode lane matmul sizes no reduce scratch without a cluster, so admitting Ampere never loosens it (as build: admit Ampere (sm_80) via TENSORFOLD_MIN_CAPABILITY, keep NVFP4/cluster floors #464 kept the FP8 floor pinned).
  • README and docs/recipes/README: "the A100 (8.0) is not supported yet" goes, the A100 joins the Ampere cards the archive carries, and the FP8/NVFP4 requirement of compute capability 9.0 or newer is stated. The "qualified on 8.6" lines stay: this change does not claim a qualification run.

Receipt

  • Tree: this branch at 4c069f2, macOS arm64, Zig 0.17.0.
  • zig build test-cuda-host: passes on Zig 0.17.0 (4 consecutive runs; one test-binary failure on the very first full build did not reproduce) (includes the new floor test and check_fatbins' fatbin-set test).
  • python3 tools/zig/lean_check.py: 1375 files, 527 problems, the baseline's own count; no additions.
  • No NVIDIA card or CUDA toolchain on this machine, so the sm_80 fatbin build and a serve run on Ampere hardware are not in this receipt; they stay the device gate before merge.

…med at its refusal

Release fatbins build and check sm_80 alongside sm_86, sm_120 and sm_121, so
the A100 and its Ampere peers load the 4-bit path. A ModelOpt checkpoint at
the FP8/NVFP4 floor is refused by name now: the card, its sm and the cluster
reason, from one tested helper (ashhart#840, the native port of ashhart#464).
…nts refuse anyway

The lanes half drives the decode lane matmul the way the engine does not:
with no reduce scratch, which only a cluster card serves. Below sm_90 the
checkpoint path is refused at load, so the check says SKIP there instead of
tripping the reduce launch on an unreachable configuration.
@liumorrisclaw

Copy link
Copy Markdown
Contributor Author

Device gate on Ampere sm_80: green

Machine: 4x NVIDIA CMP 170HX 64 GB (GA100, sm_80, 74 SMs), driver 610.43.03, CUDA toolkit 13.3 (nvcc V13.3.73), Linux x86_64, Zig 0.17.0. Branch at 1c8b571.

  • Build: zig build -Dnvcc=... -Dsm=80 install — all 34 kernels compile for compute_80, and the binaries embed them (tf-cuda-test info: "device NVIDIA CMP 170HX, sm_80, 74 SMs … kernels embedded true").
  • Release set: zig build fatbins -Dsm=80,86,120,121 — cuobjdump --list-elf shows every one of the 34 fatbins carrying sm_80, sm_86, sm_120 and sm_121 ELFs, the release_sms contract end to end.
  • Kernel checks on the card: 16/16 green — info, smoke, graph, ptx (hand-written sm_80 PTX JIT-compiled exact), symbols, cublaslt, norms, norm-rows, sample, glue (1242/1242 byte-equal to the host references), pocket, quant-ref (FP8 and NVFP4 products within float64 bounds), modelopt (repack byte-equal; the rows half SKIPs below sm_90 per 1c8b571), exlr8-dense, launch-ex, overhead.
  • Not run: a served checkpoint. The card hosts unrelated jobs and no Nemotron checkpoint is staged there; the modelopt rows half stays production-unreachable below sm_90 by design — loadModelopt refuses there first, which is the trap this PR keeps.

One commit lands for this: 1c8b571 makes tf-cuda-test modelopt SKIP its rows half below sm_90. Its first run exposed why the floor exists: the lanes half drives the decode lane matmul with no reduce scratch, which only a cluster card serves — on sm_80 that launch took an illegal-address fault. Below sm_90 the checkpoint path is refused at load, so the check now says SKIP with that reason instead of tripping an unreachable configuration. The repack half is card-independent and passes on sm_80; quant-ref still checks the FP8/NVFP4 math there.

@ashhart

ashhart commented Oct 14, 2026

Copy link
Copy Markdown
Owner

Hello @liumorrisclaw,

Thank you for the sm_80 device gate on the GA100: all 34 kernels building for compute_80, every release fatbin carrying the four images, and 16/16 kernel checks on the card with glue byte-equal to the host references. That meets the bar the tracker set for this row.

One thing is left. packaging/README.md:36-37 still builds the release fatbins with -Dsm=86,120,121 and says they carry three images. release_sms is now 80,86,120,121, and dist refuses a file without the sm_80 image. Please update those two lines, or we will when it lands. Before it lands we also build the sm_80 fatbins here and run the kernel contract's limits for sm_80.

Thank you again.

@liumorrisclaw

Copy link
Copy Markdown
Contributor Author

Done — packaging/README.md now builds the release fatbins with -Dsm=80,86,120,121 and says the four images, with dist refusing a file that lacks any of the four (48bd1a2). Your pre-landing sm_80 build and the kernel contract's limits here sound good; the CMP 170HX box from the receipt stays available if a second sm_80 run helps.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants