code wiki / (root) / nx_rvc_gate.nx

nx_rvc_gate.nx

buildroot/runtime/nx_rvc_gate.nx

3970 B62 linesdepth 5pulls 6 transitivereach 0 importersview sourcekind gate/prooftopic rvc
docsdependenciesstructsconstsfunctions

about

nx_rvc_gate.nx -- THE VERDICT GATE for nishios NO3 (nx_rvc_run_suite, watch symbol rvc_run_suite). SUBJECT: the nx_rvc_run_suite ELF, forked for real (argv[1] overrides; default the serving-root _offc copy). It runs the organ's SELF-CONTAINED `selftest`, which builds a synthetic RV64 program in memory (no third-party corpus, so this gate is non-vacuous on the NAS where there is no gcc): the program stores two known words to a signature region, writes tohost, then loops. The runner's OWN compare core (the same rvc_run_img the real suite uses) is then exercised three ways: good a correct reference -> verdict PASS (T1) corrupt a WRONG reference word -> verdict FAIL (T2, THE KNOWN-FAILING CONTROL: a comparator that always PASSed -- a vacuous suite -- fails HERE, so no pass count can be quoted from a blind ruler) illegal a bad instruction word -> verdict UNSUPPORTED, not a silent PASS/FAIL (T3) empty a nonexistent pin -> zero runs, RED at the caller (T4, neg-control-empty-corpus) T5 requires the runner's own aggregate self-verdict GREEN and exit 0 (partition + all four held). The full per-group compliance numbers (I/M/C/privilege/Zifencei against the pinned repo references) are the LOCAL WITNESS (bench/riscv-arch-test/nishios_NO3_local_witness.txt) -- the third-party gcc assembler and the 12 MB corpus are laptop-only by the estate's no-gcc-on-NAS design; this gate proves the RUNNER MECHANISM everywhere, which is what makes that witness trustworthy. license_tier: ORIGINAL No hw writes (Rule 26). expect_exit: 0

dependencies 3 imports · 0 importers

nx_syscalls.nx nx_gate_verdict.nx nx_tool_run.nx nx_rvc_gate.nx

imports: nx_syscalls.nxnx_gate_verdict.nxnx_tool_run.nx

imported by: nobody (leaf or entry point)

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

main gv_ctr 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 ↻ gv_head gv_puts sys_write ↻ sys_mmap ↻ tr_run1_to sys_mmap ↻ tr_run_capture_to tr_run_capture_tr tr_run_capture_core tr_run_capture_core_owned tr_run_capture_core_eviden gv_puts ↻ gv_num sys_mmap ↻ sys_write ↻ sys_munmap tr_contains gv_check gv_puts ↻ gv_verdict gv_note_bare_rate gv_bare_rate gv_at

structs

none

consts

25const RVG_SUBJECT_DEFAULT: *u8 = "_offc/nx_rvc_run_suite.elf\x00"
26const RVG_CAP: i64 = 262144
27const RVG_TIMEOUT_MS: i64 = 60000 // the selftest runs a handful of tiny programs; a minute is a hang

functions

29func main(argc: i64, argv: *i64) -> i64