code wiki / _hdl_build / nx_hash_kat.nx

nx_hash_kat.nx

buildroot/runtime/_hdl_build/nx_hash_kat.nx

3138 B55 linesdepth 4pulls 4 transitivereach 0 importersview sourcekind tooltopic hash
docsdependenciesstructsconstsfunctions

about

nx_hash_kat.nx -- KAT for nx_hash (FNV-1a-64 + open-addressing table). HONESTY [W] weak point (reach=101, 5 children, ZERO tests): the shared hash under many organs was unproven. FNV-1a KAT'd vs the CANONICAL published vectors (a wrong constant/loop-order fails); table proven by put/get roundtrip, absent-key, collision-probe correctness, and update-in-place. license_tier: ORIGINAL expect_exit:0

dependencies 2 imports · 0 importers

nx_syscalls.nx nx_hash.nx nx_hash_kat.nx

imports: nx_syscalls.nxnx_hash.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main sys_mmap nx_hash_fnv1a_bytes hw sys_write hx sys_mmap ↻ sys_write ↻ nx_hash_new nx_hash_put nx_hash_probe nx_hash_fnv1a_i64 nx_hash_get nx_hash_probe ↻ nx_hash_has nx_hash_probe ↻ sys_write ↻

structs

none

consts

none

functions

8func hw(s: *u8) -> i64 { var n:i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 }
called by 1: main calls 1: sys_write
9func hx(v: i64) -> i64 { let d: *u8="0123456789abcdef" as *u8; let o: *u8=sys_mmap(20); o[0]=48 as u8; o[1]=120 as u8; var i: i64=0; while i<16 { o[2+i]=d[(v>>((15-i)*4))&15]; i=i+1 } sys_write(1,o,18); return 0 }
called by 1: main calls 2: sys_mmapsys_write
11func main() -> i64