code wiki / _hdl_build / nx_emit_kat.nx
nx_emit_kat.nx
buildroot/runtime/_hdl_build/nx_emit_kat.nx
about
nx_emit_kat.nx -- the portable arithmetic KAT, compiled by the SOVEREIGN x86_64 chain
(nx_cc_sovereign -> nxasm_x86, NO gcc, NO qemu) and executed natively. main returns 42 IFF the
backend computes (a*b)+(a-b) correctly for THREE distinct input pairs (37, 10, 81) -- so a
constant-folding, miscompiled, or hollow backend cannot reach 42 (it would return 1/2/3 pointing
at the first wrong KAT). This is the run-proof KAT the per-ISA emit gates execute on each
hardware target's SOVEREIGN emulator (nx_emu_rv64/arm64/mips64/ppc64le/...), replacing qemu.
license_tier: ORIGINAL
dependencies 0 imports · 0 importers
imports: none
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
| 8 | func kat(a: i64, b: i64) -> i64 { return (a * b) + (a - b) } called by 1: main |
| 9 | func main() -> i64 calls 1: kat |