code wiki / _hdl_build / nx_builddeploy_gate.nx
nx_builddeploy_gate.nx
buildroot/runtime/_hdl_build/nx_builddeploy_gate.nx
about
nx_builddeploy_gate.nx -- holds nx_builddeploy_lib, THE ruler for "may this build write a
consumer-visible binary?". IN-PROCESS by construction: the lib is pure integer logic in this gate's own
build closure, so nx_gate_bite can actually reach it. A gate that fork/execs a deployed elf cannot be
mutation-proven (every mutant reads NOT-REACHED), which is precisely why the queued-build class went
unmeasured -- the decision lived inline in a 105KB builder that no fixture could drive.
THE DEFECT THIS EXISTS TO STOP, measured 2026-08-26 from the queue's own artifact:
[nx_sov_build_run] nx_gate_roster_run: DEPLOYED to serving root (twin refresh, live for the next
fork) -> ../nx_gate_roster_run.elf
seeded by /api/build's load-refusal path, which had told the caller only that the build was deferred
and to "promote deliberately afterwards".
THE TWO TEETH THAT MATTER ARE A PAIR, AND EITHER ALONE IS A TRAP:
- build-only must install NOTHING (stops the defect)
- the DEFAULT path must still refresh a present twin (stops the over-correction)
A fix that silenced the first by disabling all installs would reintroduce LM-026 staleness estate-wide
and every consumer would silently fork a stale binary. Both directions are held here.
license_tier: ORIGINAL No hw writes (Rule 26). expect_exit: 0
dependencies 3 imports · 0 importers
imports: nx_gate_verdict.nxnx_tool_run.nxnx_builddeploy_lib.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| 24 | const BDG_BOOL_STATES: i64 = 2 // any twin probe answers exactly: present or absent |
| 25 | const BDG_DKIND_STATES: i64 = 3 // organ_kind.conf answers daemon(1), not-daemon(0), UNPROVEN(-1) |
| 26 | const BDG_DKIND_LO: i64 = 0 - 1 |
| 27 | const BDG_DKIND_HI: i64 = 1 |
| 28 | const BDG_NOT_DAEMON: i64 = 0 |
| 29 | const BDG_IS_DAEMON: i64 = 1 |
| 30 | const BDG_UNPROVEN: i64 = 0 - 1 |
functions
| 32 | func bdg_eq(a: i64, b: i64) -> i64 { if a == b { return 1 } return 0 } called by 1: main |
| 35 | func bdg_retain(mark:*u8,out:*u8,n:i64)->i64 |
| 43 | func bdg_runtime(runner:*u8,target:*u8,f1:*u8,f2:*u8,tail:*u8,expected:i64,mark:*u8,ctr:*i64)->i64 |
| 54 | func bdg_same_file(path:*u8,before:*u8,n:i64)->i64 called by 1: bdg_runtime_checks |
| 59 | func bdg_runtime_checks(runner:*u8,target:*u8,ctr:*i64)->i64 |
| 86 | func bdg_text_eq(a:*u8,b:*u8)->i64 called by 1: main |
| 90 | func bdg_process_fixture(runner:*u8,mode:*u8,budget:*u8,expected:i64,ctr:*i64)->i64 |
| 98 | func main(argc: i64, argv: *i64) -> i64 |