nx_gguf_dequant_kat_gate.nx
buildroot/runtime/nx_gguf_dequant_kat_gate.nx
about
nx_gguf_dequant_kat_gate.nx -- KATs for the DEBT-EATEN quant family (2026-07-15): every newly added
block dequant (Q4_0/Q4_1/Q5_1/Q5_K/Q3_K/Q2_K/F16/BF16) is checked against HAND-DERIVED expected values
on hand-constructed blocks (known bits in -> exact Q16 out), plus the loud-fail contract and the
canonical stride table. The fleet's live types (F32/Q5_0/Q8_0/Q4_K/Q6_K) keep their existing gates;
this gate covers the types no current model ships -- so the NEXT model never hits a silent hole.
T1 Q4_0 / Q4_1 / Q5_1 KATs exact T2 F16 / BF16 KATs exact
T3 Q5_K KAT exact (scale-pair unpack + qh high-bit + dmin) T4 Q3_K KAT exact (6-bit scales, hmask -4)
T5 Q2_K KAT exact (sc/min nibbles) T6 LOUD-FAIL: unknown type -> -1 from stride/to_q16/row
expect_exit: 0 license_tier: ORIGINAL No hw writes (Rule 26).
dependencies 9 imports · 0 importers
imports: nx_syscalls.nxnx_tier.nxnx_le.nxnx_tensor.nxnx_gguf.nxnx_gguf_load.nxnx_gguf_meta.nxnx_nofloat_llm.nxnx_gate_verdict.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| none |
functions
| 20 | func kq_w(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 } |
| 21 | func kq_n(v: i64) -> i64 |
| 34 | func kq_chk(name: *u8, got: i64, want: i64, fails: *i64) -> i64 |
| 42 | func main() -> i64 |