← blackwellsmatter.com / #004 · 2026-12-05
note #004 · undocumented isa & hardware bestiary rtx 5090 gb202 · rtx pro 6000 · b300 sm_103a

The Blackwell ISA Bestiary: Undocumented E3M4 FP8, QADD4, TTU* Ops, Silent CS2R Pair-Writes & L2::evict_first SASS

brute-force encoding sweeps on RTX 5090 & B300 · 132 unlisted silicon-passing opcodes · 101 phantom scheduling mnemonics · hardware traps nvdisasm hides

E3M4
SECRET FP8 CODE 2
36/36 dense+sparse on 5090
144/256
OMMA.SF VALID
incl. undoc UE8M0.4X
132+101
HIDDEN OPCODES
132 live · 101 sched-table
-56%
KV L2 EVICTION
UR6:UR7=0x12f00000 SASS

01 E3M4: The Secret 6th FP8 Format Hiding at Type Code 2

When CUDA 13.1 added compute_120f for block-scaled MMA (QMMA.SF, opcode 0x47a), the PTX ISA documented five 3-bit element type codes: 0=E4M3, 1=E5M2, 3=E3M2, 4=E2M3, and 5=E2M1. Notice the hole right in the middle: type code 2 was skipped in PTX ISA 9.2, the OCP MX spec, and nvdisasm 13.1.

Patching type code 2 (hi64 |= 0x100000 for operand A, 0x040000 for operand B) directly onto an RTX 5090 proved it is not reserved — it is a fully functional, undocumented 8-bit floating-point format: E3M4 ([S:1][EEE:3][MMMM:4], exponent bias 3, max normal 31.0, no inf/NaN, 2× the mantissa precision of E4M3 at the exact same 8-bit bandwidth).

QMMA.SF 3-bit type codes (0x47a, RTX 5090 silicon sweep):
  0 = E4M3 (8b, max 448)    3 = E3M2 (6b, max 28)    6 = ILLEGAL (715)
  1 = E5M2 (8b, max 57344)  4 = E2M3 (6b, max 7.5)   7 = ILLEGAL (715)
  2 = E3M4 (8b, max 31.0, [email protected] = 0.0625, 4 mantissa bits — UNDOCUMENTED!)

                   Precision (mantissa bits)
                   2       3       4
        ┌────────────────────────────────┐
   5    │  E5M2  │       │               │  wide range, low precision
   4    │        │ E4M3  │               │  standard FP8
Exp 3   │  E3M2  │       │ E3M4 (code 2) │  2x E4M3 precision; UE8M0 handles range
   2    │        │ E2M3  │               │  native SM120 FP6 (BFP6)
   1    │  E2M1  │       │               │  FP4 (E2M3 + exp_scale)
        └────────────────────────────────┘

Every single bit-pattern test matched 9/9 exactly on RTX 5090 (0x01 → 0.015625 up to 0x7E → 30.0, with sign bit verified via 0x80=0, 0xBC=|0x3C|, 0xFE=|0x7E|), and all 36/36 dense (QMMA.SF.16832) + 36/36 sparse (QMMA.SF.SP.16864) cross-format combinations with E4M3/E5M2/E3M2/E2M3/E2M1 executed cleanly. All 22 E3M4 InsKeys are now catalogued in blackwell-isa.

02 OMMA.SF 256-Byte Sweep, MXINT8 (0x47e) & Sparse K=128 FP4

Next, we binary-patched all 256 values of hi[23:16] on OMMA.SF (opcode 0x47f) in isolated fresh CUDA subprocesses on RTX 5090. Result: 144 accepted, 112 hardware-illegal, revealing a clean 16-column periodicity:

OMMA.SF hi[23:16] exhaustive 256-value hardware sweep (RTX 5090, GB202)
Legend:  █ = valid output   ○ = valid zero   ✗ = ILLEGAL_INSTRUCTION (715)

       0 1 2 3 4 5 6 7 8 9 A B C D E F
  0_   █ █ ✗ █ █ █ ✗ █ █ █ ✗ ○ ✗ ✗ ✗ ✗   ← bits[7:4] = scale byte/thread selector
  1_   █ █ ✗ █ █ █ ✗ █ █ █ ✗ █ ✗ ✗ ✗ ✗     (all 16 values legal; never traps)
  ..   (identical legality mask repeats for 2_ .. F_)
  F_   █ █ ✗ █ █ █ ✗ █ █ █ ✗ █ ✗ ✗ ✗ ✗

Low nibble [ b3 b2 | b1 b0 ]:
  bits[3:2] scale config:  00 = UE8M0 + 4X (.E8.4X)     → ACCEPTED on GPU, NOT emitted by ptxas!
                           01 = UE4M3 + 4X (.UE4M3.4X)  → ptxas ✓ · GPU ✓
                           10 = UE8M0 + 2X (.E8)        → ptxas ✓ · GPU ✓
                           11 = UE4M3 + 2X (.UE4M3)     → ptxas rejects · GPU TRAPS (715)
  bits[1:0] modifier:      00 default · 01 mod-A · 10 ILLEGAL · 11 mod-B

Sweeping 0x400–0x4FF on RTX 5090 also turned up 0x47e — QMMA.SF.16832.F32.MXINT8.MXINT8.E8 (following the exact bit-10 pattern of 0x27a → 0x47a), plus 8 sparse K=128 FP4 encodings under OMMA.SF.SP.168128 (0x47f). Meanwhile, sweeping 1,105 IMMA discriminator bits proved SM120 IMMA is hardwired to 8-bit inputs (zero hidden INT16 mode), and patching 44 Mercury 0xa02 descriptors confirmed that for simple stubs, SASS bits — not Mercury — determine QMMA format.

03 The Weird Instruction Menagerie (SM120, B300 & Firmware Sched Tables)

Cross-referencing our measured sm120.json / sm103a.json tables, our 6-template RTX 5090 brute-force sweep (369 unique passing 12-bit opcodes, of which 132 are still unlisted in public sm120.json!), and NVIDIA's internal scheduling tables (235 unique mnemonics, 101 absent from public ISA tables) yields a remarkable zoo of exotic Blackwell hardware instructions:

Instruction / Family 12-bit Op / Arch What It Actually Is
QADD4 / QMUL4 (.E4M3x4.E2M1x4) 0x27d / 0x27c (B300) 4-wide mixed FP8×FP4 vector add & multiply with .SATFINITE in one instruction (QFMA4 also appears in sched tables).
CREDUX (F32.{MAX,MAXABS,MIN}) 0x2cc (B300) Hardware cross-warp / cluster reduction directly into a uniform register (UR), replacing SMEM tree reductions.
FHADD (mixed half + F32) 0x221 (both) Adds selected F16/BF16 half (H0/H1) to full FP32; verified bit-exact across 5,984 outputs on both B300 & B200.
VHMNMX / VIMNMX3 0x247 / 0x20f (B300) 3-operand vector FP16/BF16 & integer min/max with optional fused .RELU.
B2R / QSPC / RPCMOV 0x31c / 0x3aa / 0x352-3 Barrier-to-register read (B2R.RESULT), pointer address-space query (QSPC), and return-PC move (RPCMOV).
UGETNEXTWORKID / ACQBULK / PREEXIT 0x3ca / 0x82e / 0x82d Hardware persistent-CTA work stealing (BROADCAST/SELFCAST), bulk resource acquire, and warp early-exit hint.
Unlisted 0x200 mutators (0x216, 0x21a, 0x233, 0x203, 0x34e, 0x3c0, 0x443…) 132 live ops (5090) 0x216: D[0]=(B==0)?A:0, D[1]=C; 0x21a: exact inverse (B!=0); 0x233: D[0]=0, D[1]=C; 0x204/21e/21f/22c: passthroughs.
TTUOPEN / TTULD / TTUST / TTUGO / TTUCLOSE / TTUMACROFUSE sched-table only Raw SASS interface to the hardware Ray-Tracing Tree Traversal Unit (BVH accelerator).
SPARSIFY / SPMETADATA / DECOMPRESS / FSWZADD sched-table only Hardware 2:4 pruning + metadata generation, decompression, and fused swizzle-add entries in NVIDIA's scheduling tables.
UDLC{HMMA,IMMA,QMMA,CP,BAR} & UDPC{BLKCP,TMALDG,RM} sched-table only Uniform datapath-local / device-producer-consumer copy & tensor instructions alongside NANOTRAP, BPT.PAUSE, UREGPRERELEASE, UTRACEEVENT.

04 Silent Silicon Quirks & Traps That nvdisasm Hides

Knowing hidden opcodes is fun; surviving the undocumented side effects of documented opcodes is what keeps production kernels from crashing silently at 3 AM. Five empirical traps we had to diagnose on live silicon:

4.1 B300 CS2R R2, SRZ Silently Zeroes R3 Too

While patching FlashAttention-4 forward on HGX B300 (sm_103a), replacing CS2R R2, SRZ with a 32-bit MOV R2, 0 caused an inexplicable CUDA_EXCEPTION_5: Warp Out of range Address on a downstream UTCHMMA tmem[UR19] — completely invisible to compute-sanitizer memcheck. Stepping over the instruction in cuda-gdb with a poisoned register proved the hidden 64-bit hardware semantic:

cuda-gdb hardware breakpoint at 0x1300 on B300 SXM6 (sm_103a):
  (cuda-gdb) set $R3 = 0xdeadbeef
  (cuda-gdb) stepi                 // executes: CS2R R2, SRZ  (text names ONLY R2!)
  $R2 = 0x00000000
  $R3 = 0x00000000                 // HW silently wrote the 64-bit pair R2:R3!
  /*1350*/ R2UR UR19, R3           // consumer depended on R3 == 0 -> TMEM addr!

4.2 SM120 HMMA BF16 a1 ↔ a2 Swap, Live B-Bytes & FP4 Shift

4.3 LDCU.256 Trap, ISETP.GE + QMMA Bug & Master Hazard Table

Silicon Hazard (573 SM120 + 633 B300 cells) Measured Floor Failure Mode When Violated
UBLKCP.S.G (TMA bulk load) S12 (no Y) Hardware issue law: S01/S02/S04/S08 → CUDA_ERROR_LAUNCH_FAILED; S12 clean.
QMMA operand WAR hold 8 cy Fixed-latency overwrite 2–4 cy after QMMA corrupts bits even behind a waited read barrier.
F2F.BF16.F32 conversion Scoreboard Hidden variable-latency op: reading without write barrier gives wrong bits even at S15.
@P guard & LDGSTS trailing P2 S13 (no Y) Razor-sharp 12 → 13 cliff (99.2–100% wrong at S12; 6,377/6,377 B300 ptxas pairs use S13).
B300 STS vs STS.128 address 2 vs 5/3/0 Lowering LEA/IADD3/IMAD → STS.128 below 5 triggers 0xe30 MISALIGNED_ADDRESS on B300.
B300 ALU ↔ IMAD crossing S05 (+1 cy) Same-domain clean at S04; crossing ALU ↔ IMAD fails 655,360/655,360 threads at S04.
Multi-register grid alignment 64b %2 · 128b %4 Odd IMAD.WIDE pair or off-grid LDG/STG/IADD.64 traps CUDA 715 (23/23 probes).

05 Production Payoff: L2::evict_first & 769-Op MoE Prefill SASS

Putting these exact hardware laws into vLLM-Moet for GLM-5.3 753B EXL3 produced two bare-metal SM120 cubin families assembled directly with cubit:

// cubit SM120 SASS: synthesizing L2::evict_first (0x12f00000) for 1-shot MoE weights
[B------:R-:W-:Y:S01] UMOV          UR6, 0x12f00000 ;               // L2::evict_first policy descriptor
[B------:R-:W-:Y:S01] UMOV          UR7, URZ ;                      // even-aligned pair UR6:UR7
[B------:R-:W0:Y:S02] LDGSTS.E.64   [R_smem], desc[UR6][R_wt.64] ;  // 151-201 MB weights -> evict first
[B------:R-:W1:Y:S02] LDGSTS.E.128  [R_act_s], desc[UR4][R_act.64] ;// keep shared activations + KV hot
GLM-5.3 753B ws8-v3 Prefill and m8_l2ef Decode
Figure 1 — Production Silicon Impact (8× RTX PRO 6000, GLM-5.3 753B): (A) ws8-v3 warp-specialized SASS + deterministic gather beats NVFP4 across 131K–500K cold prefill. (B) m8_l2ef trims E2E decode step latency by 6–8% by stopping one-shot weights from thrashing KV cache in L2.
← #005 sm120 execution overlap #003 25.36 gh/s rtx 5090 →