nx_crashresume_census_core.nx
buildroot/runtime/nx_crashresume_census_core.nx
about
nx_crashresume_census_core.nx -- importable CORE of the crash-resume census (CR-R0 of the
crash-resume->SOTA roadmap 2026-07-15): MEASURES whether the workstream capture plane is LIVE --
heartbeat staleness (max HBX epoch= in the log vs wall clock), registry/file mtime staleness
(newfstatat), and session-activity vs capture LAG (newest transcript mtime vs newest captured
state). Bank: registry+heartbeats sat DEAD 5 days at the 07-15 crash while 36 sessions worked ->
resume cost ~5h of hand archaeology; this census makes that rot VISIBLE within a cron tick.
PURE verdict funcs here (gate-locked). Cells NEVER fabricate: no evidence -> UNKNOWN; bounded
reads bias STALE (a truncated log can only under-report freshness, never invent it). Read-only.
license_tier: ORIGINAL
dependencies 2 imports · 13 importers
diagram shows first 10 each side; +0 more imports, +3 more importers in the complete lists below.
imports: nx_syscalls.nxnx_itoa_lib.nx
imported by: nx_capability_triage_core.nxnx_coindex_core.nxnx_crashresume_census.nxnx_crashresume_census_gate.nxnx_lock_reap_core.nxnx_memindex_budget_gate.nxnx_memindex_emit_gate.nxnx_memindex_put_gate.nxnx_opennet_posture_core.nxnx_shelltool_gate.nxnx_state_spool_core.nxnx_triage_ground.nxnx_ws_hygiene_core.nx
structs
| none |
consts
| 15 | const CCZ_EPBUF: i64 = 16 |
| 16 | const CCZ_STATBUF: i64 = 256 |
| 17 | const CCZ_STAT_MTIME_SLOT: i64 = 11 |
| 18 | const CCZ_DENTBUF: i64 = 65536 |
| 19 | const CCZ_PATHBUF: i64 = 2048 |
| 21 | const CR_RED: i64 = 0 |
| 22 | const CR_UNKNOWN: i64 = 1 |
| 23 | const CR_GREEN: i64 = 2 |
functions
| 25 | func ccz_slen(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n } |
| 27 | func ccz_max(a: i64, b: i64) -> i64 { if a > b { return a } return b } called by 1: main |
| 30 | func ccz_num_at(s: *u8, n: i64, off: i64, endp: *i64) -> i64 |
| 45 | func ccz_read(path: *u8, buf: *u8, cap: i64) -> i64 |
| 56 | func ccz_max_epoch(buf: *u8, n: i64) -> i64 |
| 77 | func ccz_mtime(path: *u8) -> i64 |
| 88 | func ccz_ends_with(name: *u8, ext: *u8) -> i64 |
| 98 | func ccz_newest_mtime_ext(dir: *u8, ext: *u8) -> i64 called by 2: mainmain calls 9: sys_openat_rdsys_mmapsys_getdents64dirent_reclendirent_nameccz_ends_with+3 |
| 138 | func ccz_cat_str(buf: *u8, off: i64, s: *u8) -> i64 |
| 149 | func ccz_stale_verdict(ts: i64, now: i64, window: i64) -> i64 |
| 157 | func ccz_lag_verdict(src_ts: i64, cap_ts: i64, window: i64) -> i64 |