Skip to content

docs(examples): correct stale tcgen05 consumer Blackwell claims - #1202

Closed
pedrozaz wants to merge 0 commit into
NVIDIA:mainfrom
pedrozaz:docs/fix-tcgen05-sm120-claims
Closed

pedrozaz wants to merge 0 commit into
NVIDIA:mainfrom
pedrozaz:docs/fix-tcgen05-sm120-claims

Conversation

@pedrozaz

Copy link
Copy Markdown
Contributor

Summary

Fixes #1194. Multiple files across the tcgen05 and tcgen05_matmul standalone examples, the cuda-device module rustdoc, and the book's safety model chapter incorrectly list sm_120 (consumer Blackwell) as supporting tcgen05 / TMEM.

This PR aligns all of them with the correct hardware requirement: sm_100a (Datacenter Blackwell). It also introduces a can_execute_tcgen05() pre-check across both standalone examples (matching gemm_sol_final), avoiding unhandled driver JIT errors on unsupported architectures, and corrects the fallback ptxas target to -arch=sm_100a.

Changes

  • tcgen05/README.md & tcgen05_matmul/README.md: Update hardware requirements and comparison table from sm_100/sm_120 to sm_100a (Datacenter Blackwell); explicitly note sm_120 is not supported due to the absence of TMEM.
  • tcgen05/src/main.rs & tcgen05_matmul/src/main.rs: Add can_execute_tcgen05() pre-check before module loading (matching gemm_sol_final) to cleanly decline execution on consumer Blackwell / pre-Blackwell with informative diagnostics instead of driver errors; fix ptxas validation target to -arch=sm_100a.
  • cuda-device/src/tcgen05.rs: Correct Hardware Support rustdoc to list sm_100a (Datacenter B100/B200) alongside sm_103a (Blackwell Ultra) and sm_110a (Jetson Thor) under the compute_100 TMEM-capable architecture family, and explicitly note that sm_120 uses register-based mma.sync instead.
  • cuda-oxide-book/gpu-safety/the-safety-model.md: Map tcgen05 and TMEM to sm_100a (Blackwell DC) and CLC to sm_100+ (Blackwell) in the Tier 3 raw hardware table.

Testing

Verified on physical hardware with an NVIDIA GeForce RTX 5060 Ti (sm_120):

1. Unified runtime UX across tcgen05 and tcgen05_matmul on sm_120:

$ cargo oxide run tcgen05
=== Unified tcgen05 Example ===

GPU Compute Capability: sm_120

⚠️  tcgen05 (5th gen tensor cores) requires sm_100a (datacenter Blackwell).
   Your GPU is sm_120 (consumer Blackwell has no tcgen05/TMEM).
   PTX was generated successfully; run on sm_100a hardware to execute kernels.

📝 PTX Verification:
   PTX file generated at: .../tcgen05/tcgen05.ptx
$ cargo oxide run tcgen05_matmul
=== Unified tcgen05 Matmul Example ===

GPU Compute Capability: sm_120

⚠️  tcgen05 (5th gen tensor cores) requires sm_100a (datacenter Blackwell).
   Your GPU is sm_120 (consumer Blackwell has no tcgen05/TMEM).
   PTX was generated successfully; run on sm_100a hardware to execute kernels.

📝 PTX Verification:
   PTX file generated at: .../tcgen05_matmul/tcgen05_matmul.ptx

2. Instruction-level isolation of ptxas rejection on sm_120a:

Assembling a .target sm_120a PTX containing tcgen05.alloc confirms that the assembler rejects tcgen05 instructions at the instruction level on sm_120a:

$ cat << 'EOF' | ptxas -arch=sm_120a - -o /dev/null
.version 8.7
.target sm_120a
.address_size 64

.visible .entry test_kernel() {
    .reg .b32 %r0;
    tcgen05.alloc.cta_group::1.sync.aligned.shared::cta.b32 [%r0], 64;
    ret;
}
EOF
error   : Instruction 'tcgen05.alloc' not supported on .target 'sm_120a'
error   : Feature '.cta_group::1' not supported on .target 'sm_120a'

3. Workspace verification:

  • cargo check and cargo clippy --workspace --all-targets -- -D warnings pass clean
  • All 102 cuda-device unit tests pass
  • cargo fmt --check clean

Checklist

  • All commits signed off (git commit -s)
  • SPDX headers on new source files (N/A — modified existing files only)

Copilot AI lite review requested due to automatic review settings August 29, 2026 14:05

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@nihalpasham

Copy link
Copy Markdown
Collaborator

This close was my mistake, not a judgment on the PR. What happened:

  • we reviewed this and decided to land it ourselves (we've been pushing large changes lately and didn't want contributors burning time on rebases)
  • while force-pushing the rebased branch here, I pushed the wrong ref; the branch briefly matched main, GitHub auto-closed the PR, and a closed PR revokes maintainer push access to your fork, so I couldn't restore it

The work lives on in #1206 with your commit and authorship intact. What survived the rebase and what didn't:

Sorry for the churn on your first contribution here; #1194 closes through #1206 and the credit is yours.

@nihalpasham nihalpasham added already-fixed Resolved on a newer commit or branch; no action needed documentation Improvements or additions to documentation bug Something isn't working cuda-feature A CUDA hardware/toolkit feature (TMA, tcgen05, WGMMA) intrinsics Device intrinsics and libdevice math mappings labels Aug 30, 2026
nihalpasham added a commit that referenced this pull request Aug 30, 2026
…ies #1202) (#1206)

* docs: correct tcgen05 hardware claims to sm_100a (datacenter Blackwell)

tcgen05/TMEM is a datacenter-Blackwell feature; consumer Blackwell
(sm_120, RTX 50 series) has no TMEM and no tcgen05 instruction set.
Fix every doc site that claimed sm_120 support:

- tcgen05 + tcgen05_matmul READMEs: required GPU is sm_100a, add
  explicit NOT-supported note for consumer Blackwell (sm_120)
- cuda-device tcgen05 rustdoc: drop the "sm_120: RTX 5090" bullet,
  frame the sm_100 TMEM-capable family instead
- book safety-model Tier 3 table: tcgen05/TMEM rows -> sm_100a
  (Blackwell DC), CLC row -> sm_100+ (Blackwell)
- tcgen05 example crate doc: "Blackwell-only (sm_100/sm_120)" ->
  "Blackwell datacenter-only (sm_100a)"

Doc-only slice of PR #1202; the PR's runtime changes were superseded
by the stronger capability gate that landed in #1203.

Signed-off-by: Guilherme Pedroza <[email protected]>

* docs: sync tcgen05 README transcripts with actual output; add sm_101a to family list

- both READMEs showed a "Loading PTX from: ..." line the examples
  never print; transcripts now match the post-#1203 load sequence
- tcgen05_matmul's non-datacenter transcript now quotes the literal
  warning the code prints ("WARNING: tcgen05 requires sm_100
  (datacenter Blackwell)!") plus the full PTX-verification tail
- cuda-device tcgen05 rustdoc family list gains sm_101a: the runtime
  allowlist in the examples accepts cc 10.0 / 10.1 / 10.3 / 11.0, so
  the docs must name all four arches

Signed-off-by: nihalpasham <[email protected]>

---------

Signed-off-by: Guilherme Pedroza <[email protected]>
Signed-off-by: nihalpasham <[email protected]>
Co-authored-by: Guilherme Pedroza <[email protected]>

This branch was previously deployed

1 inactive deployment
github-pages — 5d178280 Deployed Aug 30, 2026 by nihalpasham via deploy #1288
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

already-fixed Resolved on a newer commit or branch; no action needed bug Something isn't working cuda-feature A CUDA hardware/toolkit feature (TMA, tcgen05, WGMMA) documentation Improvements or additions to documentation intrinsics Device intrinsics and libdevice math mappings

Projects

None yet

Development

Successfully merging this pull request may close these issues.

tcgen05 examples and book chapters incorrectly claim sm_120 support

3 participants