code wiki / (root) / nx_dwline_corpus_gate.nx

nx_dwline_corpus_gate.nx

buildroot/runtime/nx_dwline_corpus_gate.nx

15730 B331 linesdepth 3pulls 4 transitivereach 0 importersview sourcekind gate/prooftopic dwline
docsdependenciesstructsconstsfunctions

about

nx_dwline_corpus_gate.nx -- DOES STATEMENT LINE INFO HOLD ACROSS THE REAL CORPUS, OR ONLY ON A TOY? WHY THIS EXISTS. nx_dwline_stmt_gate proved statement granularity on runtime/nx_probe_dbgtiny.nx: ELEVEN LINES, TWO FUNCTIONS, four .loc rows. That is a sample size of ONE, and a feature that works on one hand-written probe is not a feature that works. The estate compiles thousands of real files with deep nesting, matches, loops, multi-line expressions and 20-argument calls -- none of which the probe contains. ★ A PROOF ON A FIXTURE YOU WROTE TO BE EASY IS A PROOF ABOUT YOUR FIXTURE. WHAT THIS MEASURES, over every .nx in runtime/ up to a DECLARED cap: - how many files the compiler can build at all with -g (the honest denominator) - how many emit ANY .loc, and how many .loc rows in total - the same numbers from the OLD blessed function-granularity compiler, as the control - the RATIO of statement rows to function rows -- which is the actual claim under test - files where the new compiler emits FEWER rows than the old one (a regression, individually named) NO SILENT CAPS: the file count scanned, the cap, and any skipped/failed files are all REPORTED. A gate that quietly samples 20 files and prints a percentage is the thing this gate exists to replace. license_tier: ORIGINAL expect_exit: 0

dependencies 2 imports · 0 importers

syscalls.nx nx_gate_verdict.nx nx_dwline_corpus_gate.nx

imports: syscalls.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

main gv_ctr sys_mmap nxa_die sys_write sys_exit nxa_lock_take nxa_lock_addr sys_write ↻ nxa_lock_give nxa_lock_addr ↻ nxa_report_overrun sys_write ↻ nxa_dump_printable sys_write ↻ nxa_dump_sizes sys_write ↻ cg_atoi gv_head gv_puts sys_write ↻ cg_ends_nx gv_check gv_puts ↻ cg_run_out cg_read cg_count_funcs cg_count_loc gv_puts ↻ gv_num sys_mmap ↻ sys_write ↻ sys_munmap gv_verdict gv_note_bare_rate gv_bare_rate gv_at gv_obj_has_n gv_at ↻ gv_puts ↻

structs

none

consts

24const CG_CAP: i64 = 4194304
29const CG_MAXFILES: i64 = 12000
30const CG_NAMEBUF: i64 = 1048576
31const CG_OLD: *u8 = "_offc/nx_cc_sovereign.elf" as *u8
32const CG_NEW: *u8 = "../nx_compile_x86.elf" as *u8

functions

34func cg_run_out(elf: *u8, args: *i64, nargs: i64, outfile: *u8) -> i64
called by 1: main
57func cg_read(path: *u8, buf: *u8, cap: i64) -> i64
called by 1: main
71func cg_count_loc(buf: *u8, n: i64) -> i64
called by 1: main
88func cg_count_funcs(buf: *u8, n: i64) -> i64
called by 1: main
104func cg_ends_nx(nm: *u8, nl: i64) -> i64
called by 1: main
115func cg_atoi(s: *u8) -> i64
called by 1: main
128func main(argc: i64, argv: *i64) -> i64