code wiki / (root) / nx_sbr_admission_gate.nx

nx_sbr_admission_gate.nx

buildroot/runtime/nx_sbr_admission_gate.nx

18071 B361 linesdepth 5pulls 9 transitivereach 0 importersview sourcekind gate/prooftopic sbr
docsdependenciesstructsconstsfunctions

about

Executes a supplied candidate runner in fresh fixtures. Never promotes or compiles real code. Usage: nx_sbr_admission_gate <absolute-runner> <absolute-self> <existing-fixture-parent> <timeout-ms> Fixture parent must be an absolute, non-symlink directory. Every run gets a new private subtree. The only executable children are the supplied runner and this fixture ELF.

dependencies 4 imports · 0 importers

nx_gate_verdict.nx nx_tool_run.nx nx_sha256.nx nx_build_canon_input_lib.nx nx_sbr_admission_gate.nx

imports: nx_gate_verdict.nxnx_tool_run.nxnx_sha256.nxnx_build_canon_input_lib.nx

imported by: nobody (leaf or entry point)

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

main sag_eq sag_admitter sag_guarded sag_len sag_decimal sag_len ↻ gv_puts sys_write gv_num 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 sys_write ↻ nxa_dump_sizes sys_write ↻ sys_write ↻ sys_munmap sag_compiler sag_guarded ↻ sag_write sag_len ↻ gv_puts ↻ gv_puts ↻ sag_exists sag_decimal ↻ sag_safe_parent sag_len ↻ bci_relative_path bci_path_char gv_cat

structs

none

consts

9const SAG_PATH_CAP: i64 = 4096
10const SAG_CAPTURE_CAP: i64 = 65536
11const SAG_FILE_MODE: i64 = 384
12const SAG_DIR_MODE: i64 = 448
13const SAG_EINVAL: i64 = 0 - 22
14const SAG_SETUP_FAIL: i64 = 90
15const SAG_WITNESS_EXIT: i64 = 91
16const SAG_BYTE_BITS: i64 = 8
17const SAG_PTR_BYTES: i64 = 8
18const SAG_ARG_SLOTS: i64 = 8
19const SAG_DIGEST_BYTES: i64 = 32
20const SAG_HEX_BASE: i64 = 16
21const SAG_SOURCE: *u8 = "func main() -> i64 { return 0 }\n"
22const SAG_GUARD: *u8 = "NISHI-SBR-ADMISSION-FIXTURE\n"
23const SAG_TARGET: *u8 = "bci_target"
24const SAG_SOURCE_PATH: *u8 = "runtime/_hdl_build/bci_target.nx"
25const SAG_CANON: *u8 = "!_hdl_build/bci_target.nx\n"
26const SAG_CASE_OK: i64 = 0
27const SAG_CASE_CONF_MISSING: i64 = 1
28const SAG_CASE_CONF_EMPTY: i64 = 2
29const SAG_CASE_CONF_COMMENTS: i64 = 3
30const SAG_CASE_HASH_MISSING: i64 = 4
31const SAG_CASE_HASH_EMPTY: i64 = 5
32const SAG_CASE_HASH_BAD: i64 = 6
33const SAG_CASE_HASH_DUP: i64 = 7
34const SAG_CASE_HASH_ROW_MISSING: i64 = 8
35const SAG_CASE_SOURCE_EMPTY: i64 = 9
36const SAG_CASE_UNRELATED_ZERO: i64 = 10
37const SAG_CASE_UNRELATED_MALFORMED: i64 = 11
39const SAG_FIXTURE_MANIFEST_SEC: i64 = 100
40const SAG_FIXTURE_SOURCE_SEC: i64 = 200
41const SAG_TIMESPEC_PAIR_BYTES: i64 = 32

functions

43func sag_len(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n }
44func sag_eq(a: *u8, b: *u8) -> i64
called by 1: main
50func sag_decimal(s: *u8) -> i64
called by 3: sag_admittersag_casemain calls 1: sag_len
66func sag_join(root: *u8, relative: *u8) -> *u8
77func sag_write(path: *u8, bytes: *u8, n: i64) -> i64
87func sag_file(root: *u8, rel: *u8, value: *u8) -> i64
called by 1: sag_setup calls 3: sag_joinsag_writesag_len
93func sag_dir(root: *u8, rel: *u8) -> i64
called by 1: sag_setup calls 1: sag_join
109func sag_exists(path: *u8) -> i64
called by 2: sag_casemain
117func sag_safe_parent(path: *u8) -> i64
called by 1: main calls 2: sag_lenbci_relative_path
141func sag_guarded() -> i64
called by 2: sag_admittersag_compiler calls 1: sag_len
151func sag_admitter(invocation: *u8) -> i64
167func sag_compiler() -> i64
173func sag_manifest() -> *u8
193func sag_setup(root: *u8, self: *u8, mode: i64, primary: *u8, fallback: *u8, manifest: *u8) -> i64
260func sag_case(runroot: *u8, name: *u8, runner: *u8, self: *u8, timeout_text: *u8, mode: i64, primary: *u8, fallback: *u8, expected_rc: i64, expected_witness: i64, ctr: *i64) -> i64
299func main(argc: i64, argv: *i64) -> i64