code wiki / (root) / nx_swcompare_evidence_gate.nx

nx_swcompare_evidence_gate.nx

buildroot/runtime/nx_swcompare_evidence_gate.nx

33140 B561 linesdepth 3pulls 7 transitivereach 0 importersview sourcekind gate/prooftopic swcompare
docsdependenciesstructsconstsfunctions

about

nx_swcompare_evidence_gate.nx -- THE REFEREE'S GROUNDING RULER, AND THE ONE QUESTION IT MUST NOT GET WRONG: CAN A COMMENT GROUND A PUBLISHED CLAIM? WHY IT EXISTS (measured 2026-09-01). nx_swcompare_evidence decided grounding with ev_find_line -- a WORD-BOUNDARY SUBSTRING over the raw organ source, comments and string literals and call sites all included. gt_drape_mesh returns matches=1 over 23,412 files (corpus_complete=1) and that ONE hit is a COMMENT in nx_garment_twin.nx line 11. The referee reported phototwin's GARMENT row [LANDED] and fired LANDED-UNFLIPPED -- the flip worklist is where a seat looks for the cheapest closure on a board, so the instrument was actively instructing someone to publish a capability that does not exist. A SCANNER THAT DOES NOT SKIP COMMENTS MEASURES THE DOCUMENTATION, NOT THE CODE. THE SUBJECT OF THIS GATE IS THE RULER, and the fix was an ADOPTION, not an invention: the referee now composes nx_symdecl_lib's sd_present_buf, the estate's ONE SYMBOL RULER, which the GENERATOR (nx_swcompare_matrix), the REGEN, the RANKER and the WATCH-STATE lib were ALL already calling. The referee was the fifth wheel. So every tooth here is IN-PROCESS against that lib plus the DEMOTED ruler kept beside it as a named control -- a fixture on which the two rulers AGREE proves nothing about either, so each discrimination tooth asserts BOTH answers. AND THE CENSUS IS THE POINT, NOT AN EXTRA. A ruler change rewrites every published cell, so it may not ship on a sampled number: `census` walks EVERY .matrix row in BOTH compare trees and reports how many currently-grounded axes are carried ONLY by a non-declaration occurrence. That count is the number of published capabilities that do not exist. It is REPORTED, never voted on -- an uncalibrated classifier must report numbers and never verdicts, and a gate that went RED on other boards' data would be permanently red and therefore ignored. license_tier: ORIGINAL No hw writes (Rule 26).

dependencies 6 imports · 0 importers

nx_syscalls.nx nx_gate_verdict.nx nx_symdecl_lib.nx nx_matrix_sym_lib.nx nx_comparetree_lib.nx nx_artifact_root.nx nx_swcompare_evidence_gate.nx

imports: nx_syscalls.nxnx_gate_verdict.nxnx_symdecl_lib.nxnx_matrix_sym_lib.nxnx_comparetree_lib.nxnx_artifact_root.nx

imported by: nobody (leaf or entry point)

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

main sys_mkdir 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 ↻ eg_path gv_cat eg_writez eg_write sys_openat_wr sys_write ↻ sys_close eg_zlen gv_cat ↻ eg_write ↻ gv_ctr sys_mmap ↻ gv_head gv_puts sys_write ↻ eg_read sys_openat_rd sys_read sys_close ↻ gv_check gv_puts ↻ eg_wordbound_control eg_zlen ↻

structs

none

consts

33const EG_MODE_755: i64 = 493
34const EG_MODE_644: i64 = 420
35const EG_ROOT: *u8 = "/tmp/nx_swcompare_evidence_gate"
38const EG_PATH: i64 = 512
39const EG_SRC_CAP: i64 = 2097152
43const EG_MATRIX_CAP: i64 = 524288
44const EG_DENT: i64 = 262144
45const EG_NAME: i64 = 256
46const EG_SET_CAP: i64 = 65536
47const EG_SYM: i64 = 512
48const EG_LINE: i64 = 8192
49const EG_FIELDS: i64 = 32
50const EG_MINFIELDS: i64 = 9
51const EG_PIPE: i64 = 124
52const EG_NL: i64 = 10
53const EG_HASH: i64 = 35
54const EG_AT: i64 = 64
55const EG_DQ: i64 = 34
56const EG_SEP: i64 = 58
60const EG_BOARD_BUDGET: i64 = 4096
61const EG_MATRIX_SUF: *u8 = ".matrix"
63const EG_O_BOARDS: i64 = 0
64const EG_O_ROWS: i64 = 1
65const EG_O_NEW: i64 = 2
66const EG_O_OLD: i64 = 3
67const EG_O_SUBSTRONLY: i64 = 4
68const EG_O_DECLONLY: i64 = 5
69const EG_O_UNREAD: i64 = 6
70const EG_O_OVER: i64 = 7
71const EG_O_GAPS: i64 = 8
77const EG_O_ABSTAIN: i64 = 9
78const EG_O_ABSTAIN_OLD: i64 = 10
79const EG_O_SLOTS: i64 = 12

functions

81func eg_zlen(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n }
82func eg_say(s: *u8) -> i64 { sys_write(1, s, eg_zlen(s)); return 0 }
83func eg_num(v: i64) -> i64 { gv_num(v); return 0 }
called by 1: eg_census_print calls 1: gv_num
89func eg_identch(c: i64) -> i64
96func eg_wordbound_control(b: *u8, n: i64, sym: *u8) -> i64
called by 2: eg_boardmain calls 2: eg_zleneg_identch
115func eg_path(name: *u8, dst: *u8) -> i64
called by 1: main calls 1: gv_cat
122func eg_write(path: *u8, body: *u8, n: i64) -> i64
130func eg_writez(path: *u8, body: *u8) -> i64 { return eg_write(path, body, eg_zlen(body)) }
called by 1: main calls 2: eg_writeeg_zlen
137func eg_split(line: *u8, ln: i64, fs: *i64, fe: *i64, maxf: i64) -> i64
called by 1: eg_board
149func eg_fcopy(line: *u8, s: i64, e: i64, dst: *u8, cap: i64) -> i64
called by 1: eg_board
156func eg_read(path: *u8, buf: *u8, cap: i64) -> i64
163func eg_line_at(buf: *u8, n: i64, off: i64, dst: *u8, cap: i64) -> i64
called by 1: eg_board
173func eg_control_off(b: *u8, n: i64, sym: *u8) -> i64
called by 1: eg_board calls 2: eg_zleneg_identch
191func eg_set_has(set: *u8, setlen: i64, name: *u8) -> i64
called by 1: eg_scan_dir
209func eg_board(dom: *u8, out: *i64, verbose: i64, mbuf: *u8, src: *u8, line: *u8, fs: *i64, fe: *i64) -> i64
309func eg_scan_dir(dir: *u8, set: *u8, setlen0: i64, out: *i64, verbose: i64, mbuf: *u8, src: *u8, line: *u8, fs: *i64, fe: *i64) -> i64
355func eg_census(out: *i64, verbose: i64) -> i64
369func eg_census_print(out: *i64) -> i64
calls 2: eg_sayeg_num
393func main(argc: i64, argv: *i64) -> i64