code wiki / _hdl_build / _debolt_gate.nx
_debolt_gate.nx
buildroot/runtime/_hdl_build/_debolt_gate.nx
about
_debolt_gate.nx -- standing DE-BOLT LICENSE for X-CLEAN-002 (retire function-splitting).
The "split functions to stay under 21 same-fn calls / dodge nxasm rc=6" workaround guards a
cause that is NON-REPRODUCIBLE on the current self-hosted toolchain (R1-T1-004 swept 21..120
all rc=0; _bs_poison env/scratch poison 12 configs non-repro; _rc6_gate GREEN). This gate makes
the retirement SAFE + REGRESSION-LOCKED by PROVING the unsplit shape: two single functions with
40 and 50 calls to one helper -- counts well past the old 21 threshold -- both BUILD (this file
must compile through nx_cc->nxasm to run at all) and compute the EXACT result. If a future
toolchain change ever reintroduced a same-fn-call ceiling, this gate goes RED (build-fail or
wrong sum) and the de-bolt is halted. NO nxasm edits -- this licenses consolidation, it does not
touch the assembler. license_tier: ORIGINAL
dependencies 1 imports · 0 importers
imports: nx_syscalls.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
| none |
functions
| 13 | func db_puts(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 } |
| 14 | func db_putn(v: i64) -> i64 { let bb: *u8 = sys_mmap(28); var m: i64=v; if m<0 {m=0-m}; let t: *u8 = sys_mmap(28); var k: i64=0; if m==0 {t[0]=48;k=1}; while m>0 {t[k]=(48+(m%10)) as u8; m=m/10; k=k+1}; var i: i64=0; while i<k {bb[i]=t[k-1-i]; i=i+1}; sys_write(1, bb, k); return 0 } |
| 16 | func db_h(x: i64) -> i64 { return x + 1 } |
| 19 | func db_big40() -> i64 |
| 29 | func db_big50() -> i64 |
| 39 | func main() -> i64 |