code wiki / (root) / nx_rosterconf_lib.nx

nx_rosterconf_lib.nx

buildroot/runtime/nx_rosterconf_lib.nx

17884 B395 linesdepth 2pulls 2 transitivereach 3 importersview sourcekind library
docsdependenciesstructsconstsfunctions

about

nx_rosterconf_lib.nx -- WHICH CONFS ARE GATE ROSTERS, AND IS A GATE A ROW OF ONE (2026-09-18, ecosystem EC57). THE DEFECT THIS CLOSES: the heavy roster (knowledge/gateroster_heavy.conf, clock row gaterosterheavy) runs its gates into the SAME production journal as the main roster, while the two organs that ask "does a roster run this gate" each read ONE conf by name: nx_rungclose printed rostered=0 for a gate the heavy beat runs daily, and nx_execsurface credited it no roster surface. A NAME LIST OF CONFS WOULD LAG THE NEXT ROSTER THE SAME WAY, so the list is DERIVED from the resource that causes the execution: a ROSTER is a (conf, journal) PAIR -- the runner's default pair (what `beat` reads and writes when it names neither) plus every pair a clock row runs through `nx_gate_roster_run beat <conf> <journal>`. A third roster is read by declaring its clock row -- no edit here and none in any consumer. THE JOURNAL IS HALF OF THE PAIR (measured 2026-09-18 on the live plane: four beats, and two of them -- gateroster-slow and nofloatslow -- write knowledge/status/gateroster_slow.jrnl and nofloat_slow.jrnl, each keeping its own heartbeat beside its journal, so they must NOT be repointed onto the shared one). A reader that credits a roster must read ITS journal: the close ruler proves TESTED and OPERATED from the production journal plus the journal of every pair whose conf lists the gate, so a slow beat's evidence is read where that beat writes it. RCF_META_OTHER still counts the beats off the production journal. ONE GRAMMAR, MIRRORED FROM ITS AUTHORITY (nx_gate_roster_run.nx: main's argv parse, grr_load, grr_isid), so every organ that asks reads a conf exactly the way the beat that runs it does: a beat the program nx_gate_roster_run (any path, .elf or not; a longer or PREFIX name is another program) with the verb beat; its next argument, when present, is the conf (else RCF_CONF_DEFAULT) and the one after it the journal (else RCF_JRNL). trial and admit run candidates and argless runs nothing, so none of them names a roster. a row leading spaces skipped; a line opening with # or ; is a comment; the gate is the maximal run of name characters [A-Za-z0-9_./-] from there -- so an @directive names nothing, a CR a row carries from another host ends the name, and a longer or PREFIX name is another gate. Pure: every function takes buffers and numbers, so a gate drives it in-process (nx_rungclose_gate). license_tier: ORIGINAL No hw writes (Rule 26).

dependencies 1 imports · 3 importers

nx_syscalls.nx nx_rosterconf_lib.nx nx_execsurface.nx nx_rungclose.nx nx_rungclose_gate.nx

imports: nx_syscalls.nx

imported by: nx_execsurface.nxnx_rungclose.nxnx_rungclose_gate.nx

structs

none

consts

26const RCF_I64: i64 = 8
27const RCF_RUNNER: *u8 = "nx_gate_roster_run"
28const RCF_VERB: *u8 = "beat"
29const RCF_CONF_DEFAULT: *u8 = "knowledge/gateroster.conf" // the runner's GRR_CONF: what beat reads when it names no conf
32const RCF_JRNL: *u8 = "knowledge/status/gateroster.jrnl"
33const RCF_ARG_CONF: i64 = 0 // beat [conf] [journal] [ms]: the arguments after the verb, by position
34const RCF_ARG_JRNL: i64 = 1
35const RCF_ELF_SFX: *u8 = ".elf"
36const RCF_NOT_A_BEAT: i64 = 0 - 1
37const RCF_NONE: i64 = 0 - 1
39const RCF_TEXT_P: i64 = 0
40const RCF_TEXT_N: i64 = 1
41const RCF_TEXT_STRIDE: i64 = 2
43const RCF_META_BEATS: i64 = 0 // plane rows that are roster beats, whatever journal they write
44const RCF_META_BYTES: i64 = 1 // the pair list's length in bytes
45const RCF_META_OTHER: i64 = 2 // of them, the beats writing a journal other than RCF_JRNL (read from that journal)
46const RCF_META_SLOTS: i64 = 3
48const RCF_CH_TAB: i64 = 9
49const RCF_CH_NL: i64 = 10
50const RCF_CH_CR: i64 = 13
51const RCF_CH_SP: i64 = 32
52const RCF_CH_HASH: i64 = 35
53const RCF_CH_COMMA: i64 = 44
54const RCF_CH_MINUS: i64 = 45
55const RCF_CH_DOT: i64 = 46
56const RCF_CH_SLASH: i64 = 47
57const RCF_CH_0: i64 = 48
58const RCF_CH_9: i64 = 57
59const RCF_CH_SEMI: i64 = 59
60const RCF_CH_UA: i64 = 65
61const RCF_CH_UZ: i64 = 90
62const RCF_CH_US: i64 = 95
63const RCF_CH_LA: i64 = 97
64const RCF_CH_LZ: i64 = 122
308const RCF_PART_CONF: i64 = 0
309const RCF_PART_JRNL: i64 = 1

functions

66func rcf_slen(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n }
69func rcf_isid(c: i64) -> i64
called by 1: rcf_row_len
81func rcf_isblank(c: i64) -> i64
called by 1: rcf_token
89func rcf_line_end(buf: *u8, n: i64, p: i64) -> i64
100func rcf_span_is(buf: *u8, off: i64, len: i64, lit: *u8) -> i64
109func rcf_span_eq(a: *u8, ao: i64, al: i64, b: *u8, bo: i64, bl: i64) -> i64
117func rcf_token(buf: *u8, p: i64, e: i64, off: *i64) -> i64
called by 1: rcf_beat_arg calls 1: rcf_isblank
129func rcf_beat_arg(buf: *u8, coff: i64, clen: i64, k: i64, off: *i64) -> i64
160func rcf_beat_conf(buf: *u8, coff: i64, clen: i64, off: *i64) -> i64 { return rcf_beat_arg(buf, coff, clen, RCF_ARG_CONF, off) }
called by 4: rcf_confsmainmainmain calls 1: rcf_beat_arg
161func rcf_beat_jrnl(buf: *u8, coff: i64, clen: i64, off: *i64) -> i64 { return rcf_beat_arg(buf, coff, clen, RCF_ARG_JRNL, off) }
called by 3: rcf_confsmainmain calls 1: rcf_beat_arg
164func rcf_jrnl_is_prod(buf: *u8, jo: i64, jl: i64) -> i64
called by 3: rcf_confsmainmain calls 1: rcf_span_is
170func rcf_list_has(list: *u8, n: i64, buf: *u8, off: i64, len: i64) -> i64
181func rcf_list_add(list: *u8, n: i64, buf: *u8, off: i64, len: i64) -> i64
called by 1: rcf_confs calls 1: rcf_list_has
194func rcf_lines(list: *u8, n: i64) -> i64
202func rcf_line(list: *u8, n: i64, k: i64, off: *i64) -> i64
217func rcf_confs_bound(plane: *u8, pn: i64) -> i64
223func rcf_pair_compose(dst: *u8, cb: *u8, co: i64, cl: i64, jb: *u8, jo: i64, jl: i64) -> i64
called by 1: rcf_confs
241func rcf_confs(plane: *u8, pn: i64, list: *u8, meta: *i64) -> i64
286func rcf_pair_conf(list: *u8, n: i64, k: i64, off: *i64) -> i64
296func rcf_pair_jrnl(list: *u8, n: i64, k: i64, off: *i64) -> i64
310func rcf_pair_part(list: *u8, n: i64, k: i64, which: i64, off: *i64) -> i64
314func rcf_pair_origin(list: *u8, n: i64, k: i64, which: i64) -> i64
334func rcf_row_start(text: *u8, p: i64, e: i64) -> i64
339func rcf_row_len(text: *u8, c0: i64, e: i64) -> i64
349func rcf_has_gate(text: *u8, tn: i64, gate: *u8, gl: i64) -> i64
364func rcf_find(texts: *i64, k: i64, gate: *u8, gl: i64) -> i64
called by 2: rp_evalg_rfind calls 1: rcf_has_gate
376func rcf_join_confs(list: *u8, n: i64, dst: *u8, o0: i64) -> i64