code wiki / (root) / nx_perf_rehearsal.nx

nx_perf_rehearsal.nx

buildroot/runtime/nx_perf_rehearsal.nx

12144 B214 linesdepth 6pulls 11 transitivereach 3 importersview sourcekind tooltopic perf
docsdependenciesstructsconstsfunctions

about

nx_perf_rehearsal.nx -- THE MISSING FEEDBACK EDGE (operator 2026-06-23: "our analytics becomes a feedback loop of s class exceed improving like the nishi conductor would do with the nishi orchestra"). The rehearsal loop EXISTS but is CORRECTNESS-ONLY: nx_conductor_notes names the weakest section from RED gate arcs (examiner_arcs.log); nx_woodshed drills a module until it builds clean. A capability that is GREEN-BUT-SLOW (passes gates, LOSES the race on latency) is INVISIBLE to the teacher. This is the adapter that feeds PERFORMANCE/RACE analytics (nx_apm_sweep latency, nx_diora_leaderboard BEHIND) INTO the conductor's weakest-section call -- so the team drills what LOSES RACES, not just what is broken. COMPOSES the conductor-notes idiom (extended gate-red -> perf-behind); does NOT duplicate it. No new monitor/census. Routes a BEHIND to a sectional drill (the trainer); an EXCEED bumps readiness. license_tier: ORIGINAL

dependencies 5 imports · 3 importers

nx_syscalls.nx nx_itoa_lib.nx nx_benchmark.nx nx_mcp_route.nx nx_sha256.nx nx_perf_rehearsal.nx nx_perf_rehearsal_actual_gate_t179 nx_perf_rehearsal_cli_gate_t179.nx nx_perf_rehearsal_gate_t179.nx

imports: nx_syscalls.nxnx_itoa_lib.nxnx_benchmark.nxnx_mcp_route.nxnx_sha256.nx

imported by: nx_perf_rehearsal_actual_gate_t179.nxnx_perf_rehearsal_cli_gate_t179.nxnx_perf_rehearsal_gate_t179.nx

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main pr_release_cli pr_p sys_write mr_equal mr_len pr_hex pr_load sys_read_file sys_openat_rd sys_lseek 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 nxa_dump_sizes sys_read sys_munmap sys_close sys_mmap ↻ sha256_digest_checked_nati sha256_checked_input sys_mmap_shared sha256_workspace_bytes sha256_context_aligned_byt sha256_digest_mapping_nati sha256_workspace_bytes ↻ sha256_digest_workspace sha256_checked_input ↻ sha256_workspace_bytes ↻ sha256_ranges_overlap sha256_init_workspace

structs

none

consts

13const PR_MAGIC_1105: i64 = 1105
15const PR_LOG: *u8 = "knowledge/status/perf_rehearsal.log"

functions

17func pr_p(s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(1,s,n); return 0 }
22func pr_n(v: i64) -> i64 { nxi_out(v); return 0 }
23func pr_cat(dst: *u8, off: i64, s: *u8) -> i64 { var i: i64=0; while s[i]!=(0 as u8){dst[off+i]=s[i];i=i+1} return off+i }
called by 1: pr_note
24func pr_catn(dst: *u8, off: i64, v: i64) -> i64 { var m: i64=v; var o: i64=off; if m<0{dst[o]=45 as u8;o=o+1;m=0-m} let t: *u8=sys_mmap(24); var k: i64=0; if m==0{t[0]=48 as u8;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{dst[o+i]=t[k-1-i];i=i+1} return o+k }
called by 1: pr_note calls 1: sys_mmap
29func pr_note(cap: *u8, nishi: i64, incumbent: i64, lower_better: i64, lfd: i64) -> i64
50func pr_uint(v:*NxValue,bad:*i64)->i64
called by 1: pr_num
63func pr_num(v:*NxValue,key:*u8,bad:*i64)->i64 { return pr_uint(mr_member(v,key,bad),bad) }
called by 2: pr_factpr_validate calls 2: pr_uintmr_member
64func pr_text(v:*NxValue,bad:*i64)->i64
called by 1: pr_same
71func pr_same(a:*NxValue,b:*NxValue,bad:*i64)->i64
called by 1: pr_validate calls 1: pr_text
77func pr_hex(p:*u8,n:i64)->i64
83func pr_digest_value(v:*NxValue,bad:*i64)->i64
called by 1: pr_validate calls 1: pr_hex
89func pr_hash_field(v:*NxValue,key:*u8,expected:*u8,bad:*i64)->i64
called by 1: pr_validate calls 3: mr_memberpr_hexmr_equal
97func pr_fact(v:*NxValue,key:*u8,bad:*i64)->i64
called by 1: pr_validate calls 2: pr_numbm_release_fact
102func pr_validate(r:*NxValue,p:*NxValue,candidate:*u8,incumbent:*u8,now:i64)->i64
182func pr_load(path:*u8,expected:*u8)->*NxValue
201func pr_release_cli(argc:i64,argv:*i64)->i64
214func main(argc:i64,argv:*i64)->i64 { return pr_release_cli(argc,argv) }
calls 1: pr_release_cli