code wiki / (root) / nx_models_page_emit_gate.nx

nx_models_page_emit_gate.nx

buildroot/runtime/nx_models_page_emit_gate.nx

11337 B253 linesdepth 3pulls 4 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

about

nx_models_page_emit_gate.nx -- the models gallery is EMITTED FROM DATA and cannot drift from the assets: this gate proves the emitter END-TO-END by forking the deployed _offc elf over the real rows, the real corpus and the banked hand-page baseline. Teeth (per-tooth gv_check, verdict via gv_verdict so the exit code IS the verdict): - emit over production rows exits 0 and writes - card count equals row count and is nonzero (denominator IN the condition, both printed) - every row's measurement is announced on stdout - neg-control: removing a row makes its card VANISH (positional row, no content coupling) - baseline parity: every h2 title and every measured triple in knowledge/models_page.baseline appears in the emitted page (transcription proof: content moved, none lost) - honesty tokens carried (TEXM FACE MORF + the provenance caption) - generated-artefact stamp present - neg-control: empty rows REFUSE and write nothing - determinism: same inputs emit byte-identical output Fixtures live in /tmp/nx_models_page_emit_gate/ and are REBUILT AND REMOVED AT SETUP (a stale outC from a crashed run would fail the absence tooth -- idempotency is part of the gate). license_tier: ORIGINAL expect_exit: 0

dependencies 3 imports · 0 importers

nx_syscalls.nx nx_gatekit_lib.nx nx_gate_verdict.nx nx_models_page_emit_gate.nx

imports: nx_syscalls.nxnx_gatekit_lib.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 ↻ gv_head gv_puts sys_write ↻ gk_mkdir sys_mkdir gk_rm sys_unlinkat sys_mmap ↻ sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_munmap sys_close gv_need gv_puts ↻ gv_verdict gv_note_bare_rate gv_bare_rate gv_at gv_obj_has_n gv_at ↻

structs

none

consts

22const MPG_A_NL: i64 = 10
23const MPG_A_CR: i64 = 13
24const MPG_A_HASH: i64 = 35
25const MPG_A_PIPE: i64 = 124
26const MPG_A_D0: i64 = 48
27const MPG_A_D9: i64 = 57
28const MPG_EXIT_UNOBS: i64 = 3
29const MPG_CAP_STDOUT: i64 = 262144
30const MPG_CAP_PAGE: i64 = 1048576
31const MPG_CAP_PATH: i64 = 4096
32const MPG_WORD: i64 = 8
33const MPG_ROW2: i64 = 2
35const MPG_SUBJECT: *u8 = "_offc/nx_models_page_emit.elf"
36const MPG_ROWS: *u8 = "knowledge/models_page.rows"
37const MPG_BASE: *u8 = "knowledge/models_page.baseline"
38const MPG_DIR: *u8 = "/tmp/nx_models_page_emit_gate"
39const MPG_OUTA: *u8 = "/tmp/nx_models_page_emit_gate/outA.html"
40const MPG_OUTB: *u8 = "/tmp/nx_models_page_emit_gate/outB.html"
41const MPG_OUTC: *u8 = "/tmp/nx_models_page_emit_gate/outC.html"
42const MPG_OUTD: *u8 = "/tmp/nx_models_page_emit_gate/outD.html"
43const MPG_RMINUS: *u8 = "/tmp/nx_models_page_emit_gate/rows_minus"
44const MPG_REMPTY: *u8 = "/tmp/nx_models_page_emit_gate/rows_empty"

functions

46func mpg_find(hay: *u8, hn: i64, from: i64, ned: *u8, nl: i64) -> i64
61func mpg_finds(hay: *u8, hn: i64, from: i64, ned: *u8) -> i64 { return mpg_find(hay, hn, from, ned, gk_len(ned)) }
called by 2: mpg_num_aftermain calls 2: mpg_findgk_len
63func mpg_num_after(b: *u8, n: i64, ned: *u8) -> i64
called by 1: main calls 2: mpg_findsgk_len
77func mpg_count_occurs(b: *u8, n: i64, ned: *u8) -> i64
called by 1: main calls 2: gk_lenmpg_find
88func main(argc: i64, argv: *i64) -> i64