code wiki / _hdl_build / nx_gossip_gate.nx

nx_gossip_gate.nx

buildroot/runtime/_hdl_build/nx_gossip_gate.nx

3709 B53 linesdepth 4pulls 5 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

about

nx_gossip_gate.nx -- proves epidemic anti-entropy convergence: peer A holds {X,Y}, peer B holds {Y,Z}. One symmetric gossip round (digest -> select-the-delta -> merge) leaves BOTH holding the union {X,Y,Z}, and each side ships ONLY the row the other lacked (efficient -- not the whole registry). Run pairwise across a mesh and the who-has-what converges everywhere. Composes nx_dist_index + nx_gossip. expect_exit: 0 license_tier: ORIGINAL

dependencies 4 imports · 0 importers

nx_dist_index.nx nx_g_puts_lib.nx nx_gossip.nx nx_syscalls.nx nx_gossip_gate.nx

imports: nx_dist_index.nxnx_g_puts_lib.nxnx_gossip.nxnx_syscalls.nx

imported by: nobody (leaf or entry point)

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

main g_puts sys_write sys_mmap di_publish di_has_cid sys_mmap ↻ di_cat di_contains di_strlen di_cat ↻ di_wdec sys_mmap ↻ g_ck g_puts ↻ di_count_rows gossip_digest di_eol di_tab gossip_select di_eol ↻ di_tab ↻ sys_mmap ↻ gossip_digest_has di_strlen ↻ di_eol ↻ di_memeq gossip_merge di_eol ↻ di_tab ↻ sys_mmap ↻ di_has_cid ↻ has3 di_has_cid ↻ sys_write ↻ sys_exit

structs

none

consts

none

functions

10func g_ck(name: *u8, cond: i64, st: *i64) -> i64 { st[1]=st[1]+1; if cond==1 { st[0]=st[0]+1; g_puts(" [OK] " as *u8) } else { g_puts(" [FAIL] " as *u8) } g_puts(name); g_puts("\n" as *u8); return 0 }
called by 1: main calls 1: g_puts
11func has3(reg: *u8, rlen: i64, a: *u8, b: *u8, c: *u8) -> i64 { var r: i64=1; if di_has_cid(reg,rlen,a)==0 {r=0} if di_has_cid(reg,rlen,b)==0 {r=0} if di_has_cid(reg,rlen,c)==0 {r=0} return r }
called by 1: main calls 1: di_has_cid
13func main() -> i64