code wiki / _hdl_build / nx_eng_diff_miscompile_test.nx

nx_eng_diff_miscompile_test.nx

buildroot/runtime/_hdl_build/nx_eng_diff_miscompile_test.nx

3729 B67 linesdepth 3pulls 3 transitivereach 0 importersview sourcekind gate/prooftopic eng
docsdependenciesstructsconstsfunctions

about

nx_eng_diff_miscompile_test.nx -- prove the ENGINEER's differential logic-miscompile detector, and MONITOR the live compiler with it. GATE (must hold): the detector mechanism is sound (agree on equal, diverge on unequal) AND the trusted memory-staged reference equals the known answer. MONITOR (reported): whether the HIGH-register-pressure form diverges -- the known-open class the full-pipeline gate is blind to. A divergence here is the canary firing, not a regression in this test. main() is kept low-pressure (delegated compares, memory-backed verdicts) so the gate itself is not a victim of the very bug it watches for.

dependencies 1 imports · 0 importers

nx_eng_diff_miscompile.nx nx_eng_diff_miscompile_test.nx

imports: nx_eng_diff_miscompile.nx

imported by: nobody (leaf or entry point)

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

main ed_puts ed_eq eng_diff eng_detect_logic_miscompil ed_hp ed_heavy sys_mmap ed_lp sys_mmap ↻ ed_heavy ↻ eng_diff ↻ ed_num ed_puts ↻ tally3

structs

none

consts

none

functions

13func ed_puts(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 2: ed_nummain
14func ed_num(v: i64) -> i64
called by 1: main calls 1: ed_puts
23func ed_eq(a: i64, b: i64) -> i64 { if a == b { return 1 } return 0 }
called by 1: main
26func tally3(r: *i64) -> i64
called by 1: main
33func main() -> i64