code wiki / (root) / nx_lang_h2h_gate.nx

nx_lang_h2h_gate.nx

buildroot/runtime/nx_lang_h2h_gate.nx

10276 B143 linesdepth 3pulls 4 transitivereach 0 importersview sourcekind gate/prooftopic lang
docsdependenciesstructsconstsfunctions

about

nx_lang_h2h_gate.nx -- THE REFEREE for the /compare/lang head-to-head receipt (2026-09-01). Subject: knowledge/compare/lang.bench, the receipt nx_lang_h2h writes, read through the ONE reader every consumer shares (nx_bench_receipt_lib). The gate proves the receipt is a measurement and not a claim: - a reference arm and a NishiLang arm exist and are VALID, every VALID arm printed the reference checksum, every VALID arm carries its run count, min <= median, a positive median, a 64-hex source sha256 and a 64-hex binary sha256, a ratio derived from the reference median, a repro command and a 4-field host line; - the writer's @verdict and the reader's re-derived verdict AGREE (rows edited after writing are caught); - the classifier BITES: a planted checksum mismatch reads VOID, a missing reference reads UNMEASURABLE, an empty receipt reads EMPTY, a forged @verdict over void rows is a writer/reader disagreement. It says NOTHING about whether the numbers are good: that is the page's honest verdict to state and the operator's to accept. A receipt that is absent SKIPs (I could not look), never RED. exit: 0 GREEN . 1 RED . 3 SKIP (gv_verdict) license_tier: ORIGINAL No hw writes (Rule 26).

dependencies 3 imports · 0 importers

nx_syscalls.nx nx_gate_verdict.nx nx_bench_receipt_lib.nx nx_lang_h2h_gate.nx

imports: nx_syscalls.nxnx_gate_verdict.nxnx_bench_receipt_lib.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 ↻ gv_head gv_puts sys_write ↻ sys_mmap ↻ lg_fixture br_cat br_put br_catn br_put ↻ sys_mmap ↻ br_parse br_init sys_mmap ↻ br_starts br_atoi br_verdict_code br_streq br_split br_streq ↻ br_status_code br_streq ↻ br_verdict br_ref_index

structs

none

consts

17const LG_PATH: i64 = 1024
18const LG_FIX: i64 = 8192
19const LG_WORD: i64 = 8
20const LG_SHA_HEX: i64 = 64
21const LG_HOST_FIELDS: i64 = 4
22const LG_PIPE: i64 = 124
23const LG_NX_ARM: *u8 = "nishilang-checked"
24const LG_RATIO_PROBE: i64 = 2020
25const LG_RATIO_PROBE_TEXT: *u8 = "2.02x"

functions

27func lg_count_pipes(s: *u8) -> i64 { var c: i64 = 0; var i: i64 = 0; while s[i] != (0 as u8) { if (s[i] as i64) == LG_PIPE { c = c + 1 } i = i + 1 } return c }
called by 1: main
28func lg_is_hex64(s: *u8) -> i64
called by 1: main
42func lg_resolve(out: *u8) -> i64
called by 1: main calls 3: br_catsys_openat_rdsys_close
53func lg_fixture(dst: *u8, chk2: i64, withref: i64, verdictword: *u8) -> i64
called by 1: main calls 3: br_catbr_putbr_catn
64func main(argc: i64, argv: *i64) -> i64