code wiki / _hdl_build / nx_capability_no_regression.nx

nx_capability_no_regression.nx

buildroot/runtime/_hdl_build/nx_capability_no_regression.nx

5451 B93 linesdepth 3pulls 3 transitivereach 2 importersview sourcekind librarytopic capability
docsdependenciesstructsconstsfunctions

about

nx_capability_no_regression.nx -- the NO-REGRESSION SAFEGUARD (operator: "a no regression safeguard"). As we climb the family tree into perfect objects, we must NEVER lose ground. Three guards, ratcheted/verified: (1) PERFECT count is a FLOOR (up-only): the climbed-capability count may rise or hold, never DROP (a frontier object un-climbing = regression). Reads `perfect=` from the capability_audit.log. (2) COLLISIONS is a CEILING (down-only): un-consolidated generations may fall or hold, never RISE (new sprawl = regression). Reads `collisions=`. (3) NO FUNCTIONALITY LOST: the merge-verification gates (nx_cidr_gate, nx_aec) must stay GREEN -- if a consolidation ever drops a capability, its union-gate goes RED and this trips. This is the deepest guard. Floors/ceilings persist in the sovereign seg_store. Run standing (conductor pulse) = the gains can't erode. license_tier: ORIGINAL

dependencies 2 imports · 2 importers

nx_seg_store.nx nx_syscalls.nx nx_capability_no_regression.nx nx_capability_no_regression_check. nx_capability_no_regression_gate.n

imports: nx_seg_store.nxnx_syscalls.nx

imported by: nx_capability_no_regression_check.nxnx_capability_no_regression_gate.nx

structs

none

consts

13const NR_MAGIC_1048576: i64 = 1048576
14const NR_MAGIC_1048560: i64 = 1048560
16const NR_STORE: *u8 = "knowledge/store/cap-no-regress"
17const NR_LOG: *u8 = "knowledge/status/capability_audit.log"
18const NR_RUNNER: *u8 = "_offc/nx_sov_build_run.elf"
19const NR_NONE: i64 = 0 - 2000000000 // sentinel: no baseline yet

functions

22func nr_metric(key: *u8) -> i64
40func nr_floor_step(floor: i64, current: i64, reg_out: *i64) -> i64
called by 2: nr_checkmain
45func nr_ceil_step(ceil: i64, current: i64, reg_out: *i64) -> i64
called by 2: nr_checkmain
51func nr_get(axis: *u8) -> i64
called by 1: nr_check calls 3: ss_opensys_mmapss_hget
57func nr_itoa(v: i64, out: *u8) -> i64 { var m: i64=v; if m<0{m=0-m} var k: i64=0; if m==0{out[0]=48 as u8;return 1} let t: *u8=sys_mmap(24); var nn: i64=0; while m>0{t[nn]=(48+(m%10)) as u8;m=m/10;nn=nn+1} while k<nn{out[k]=t[nn-1-k];k=k+1} return nn }
called by 1: nr_set_all calls 1: sys_mmap
58func nr_set_all(perfect_floor: i64, collision_ceil: i64) -> i64
66func nr_run_gate(gate: *u8) -> i64
77func nr_gates_green() -> i64
called by 2: mainmain calls 1: nr_run_gate
85func nr_check(perfect: i64, collisions: i64, reg_out: *i64) -> i64