code wiki / (root) / nx_forkfresh_gate.nx

nx_forkfresh_gate.nx

buildroot/runtime/nx_forkfresh_gate.nx

13983 B222 linesdepth 6pulls 7 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

about

nx_forkfresh_gate.nx -- THE REFEREE FOR FORK FRESHNESS (nx_forkfresh_lib), 2026-08-31. IN-PROCESS over nx_forkfresh_lib.nx, deliberately. Nothing can import a main(), and a gate that fork/execs the deployed nx_compare_regen.elf reports NOT-REACHED for every mutant -- its GREEN would prove nothing about the code under test. organ_gate.conf carries that reasoning five times over. SCOPE, STATED SO IT CANNOT BE OVER-READ: this proves the DECISION CORE -- path derivation, the digest ruler, the four-state classification and the abstention contract. It does NOT prove the nx_compare_regen emit loop, its watchlist pass or its census; those stay unreferee'd and are the next rung, not a claim being made here. FIXTURES LIVE IN /tmp/nx_forkfresh_gate/ AND NEVER IN knowledge/store/: a gate that shares its fixture with a production beat reports on the fixture, not on the code (measured estate-wide, ratcheted). Setup truncate-writes every fixture it needs on every run, and the two ABSENT fixtures are absent BY CONSTRUCTION -- they are paths this gate never creates -- so the run is idempotent without a teardown. A gate that is not idempotent reports on its first run and lies about every run after. license_tier: ORIGINAL No hw writes (Rule 26). expect_exit: 0

dependencies 2 imports · 0 importers

nx_gate_verdict.nx nx_forkfresh_lib.nx nx_forkfresh_gate.nx

imports: nx_gate_verdict.nxnx_forkfresh_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_head gv_puts sys_write 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_subjects gv_puts ↻ gv_num sys_mmap ↻ sys_write ↻ sys_munmap gv_need gv_puts ↻ fg_write gv_check gv_puts ↻ ff_classify sys_mmap ↻ ff_digest_file sys_mmap ↻ sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read

structs

none

consts

21const FG_DIR: *u8 = "/tmp/nx_forkfresh_gate"
22const FG_MODE_DIR: i64 = 493 // 0755
23const FG_MODE_FILE: i64 = 420 // 0644
24const FG_BODY_BYTES: i64 = 4096
25const FG_SUBJECTS: i64 = 5 // the five fixture pairs this gate classifies
26const FG_ABC_LEN: i64 = 3
27const FG_FILLER: i64 = 65 // ASCII A -- fixture body filler
28const FG_MUTANT: i64 = 66 // ASCII B -- the ONE byte that differs at equal size
29const FG_MUT_AT: i64 = 2048 // mid-body, so neither a header nor a tail special case
30const FG_SETUP_FILES: i64 = 7
33const FG_DIR_SMALL: i64 = 1024
34const FG_DIR_LARGE: i64 = 4096

functions

36func fg_write(path: *u8, buf: *u8, n: i64) -> i64
called by 1: main
48func fg_streq(a: *u8, b: *u8) -> i64
called by 1: main
58func main(argc: i64, argv: *i64) -> i64