code wiki / (root) / nx_coindex_vs_git_gate.nx

nx_coindex_vs_git_gate.nx

buildroot/runtime/nx_coindex_vs_git_gate.nx

6440 B140 linesdepth 5pulls 5 transitivereach 0 importersview sourcekind gate/prooftopic coindex
docsdependenciesstructsconstsfunctions

about

nx_coindex_vs_git_gate.nx -- the EXTERNAL 3rd-party comparator that closes the SELF-GRADED-SUSPECT flag the coordinator raised on its own coindex/WMS "exceeds git" claim (anti-navel-gazing: a SOTA claim graded self/none must get a REAL external number -- git EXERCISED, not stated). Measures N=12 concurrent single-attempt writers to ONE shared store, both ways: coindex: N forked ci_append -> ALL land, ZERO writers refused (flock per tiny append, no serialization stall, no retry). git : N forked processes each `git add f<i> && git commit` in ONE repo -> they RACE on .git/index.lock; the losers EXIT NON-ZERO (refused, must retry) -- git's serialize-or- fail model, measured live. (git never loses COMMITTED data; the cost is writer refusal.) This is legitimate external measurement (fork+exec of the 3rd-party tool), NOT a workstream shell op. GREEN iff coindex_refused==0 AND git_refused>0 (the external tool's contention actually fired). Journals the measured comparison. license_tier: ORIGINAL expect_exit: 0

dependencies 2 imports · 0 importers

nx_syscalls.nx nx_coindex_core.nx nx_coindex_vs_git_gate.nx

imports: nx_syscalls.nxnx_coindex_core.nx

imported by: nobody (leaf or entry point)

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

main sys_mmap sys_openat_wr sys_close sys_now_ms sys_mmap ↻ sys_clock_gettime_mono sys_fork ccz_cat_str ccz_cat_num ci_append ci_lock sys_openat_wr ↻ sys_flock sys_close ↻ sys_openat_append ci_unlock sys_flock ↻ sys_close ↻ sys_mmap ↻ ccz_cat_str ↻ sys_write sys_close ↻ sys_exit sys_wait4 wait_exit_code ci_count sys_mmap ↻ ccz_read sys_openat_rd sys_read sys_close ↻ v_sh sys_fork ↻ sys_mmap ↻ sys_execve sys_exit ↻ sys_wait4 ↻ wait_exit_code ↻ v_git_cmd

structs

none

consts

19const NW: i64 = 12

functions

16func v_puts(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } sys_write(1, s, n); return 0 }
called by 1: main calls 1: sys_write
17func v_putn(v: i64) -> i64 { nxi_out(v); return 0 }
called by 1: main calls 1: nxi_out
22func v_sh(cmd: *u8) -> i64
40func v_git_cmd(i: i64, out: *u8) -> i64
called by 1: main calls 2: ccz_cat_strccz_cat_num
51func main(argc: i64, argv: *i64) -> i64