code wiki / _hdl_build / nx_pm.nx

nx_pm.nx

buildroot/runtime/_hdl_build/nx_pm.nx

6405 B103 linesdepth 5pulls 8 transitivereach 2 importersview sourcekind tooltopic pm
docsdependenciesstructsconstsfunctions

about

nx_pm.nx -- THE NISHI PM: the coordinator that routes work to the ONE Accountable role per the RACI, so workstreams / publishing / fixing / optimizing never compete for the same work. The RACI registry IS the PM's routing table (single source of truth). For a work request (activity + payload), the PM: 1. looks up the Accountable role in knowledge/registry/nishi_raci.tsv (exactly one, validated by nx_raci), 2. ROUTES it to that role's intake -- change-apply roles (doctor=fix, engineer=optimize) -> nx_role_queue submit (their isolated serialized queue); other roles -> recorded as that role's to perform, 3. LOGS the routing to the pmcoord channel in the sovereign seg-store knowledge/store/roles-* (the one coordination record; NO TSV). This is "the PM coordinates all the publishing and workstreams" -- RACI-driven, no collisions, auditable. usage: nx_pm route <activity> <target> <oldfile> <newfile> <requester> (target/files used only for apply-roles) nx_pm accountable <activity> license_tier: ORIGINAL

dependencies 4 imports · 2 importers

nx_syscalls.nx nx_role_queue.nx nx_role_store.nx nx_raci_sov.nx nx_pm.nx nx_pm_gate.nx nx_pm_sclass.nx

imports: nx_syscalls.nxnx_role_queue.nxnx_role_store.nxnx_raci_sov.nx

imported by: nx_pm_gate.nxnx_pm_sclass.nx

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

main rq_w sys_write da_slen rq_streq 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 ↻ pm_accountable raci_accountable_for ss_open ss_open2 ss_open3 sys_now_us sys_mmap ↻ ss_manifest_dyn ss3_admit ss3_load_range ssl_total_keys_mask ss3_ann ss_close_seg ss3_move ss3_remap_table sys_madvise ss_tr ss3_insert_new sys_munmap ss3_tomb_count

structs

none

consts

17const PM_MAGIC_2048: i64 = 2048
19const PM_COORD: *u8 = "knowledge/roles/pm_coord.tsv" // RETIRED file path (kept for provenance); routing now -> rs_append("pmcoord")

functions

21func pm_has(s: *u8, ch: i64) -> i64 { var i: i64=0; while s[i]!=(0 as u8){ if (s[i] as i64)==ch {return 1} i=i+1 } return 0 }
25func pm_accountable(activity: *u8, out_role: *u8) -> i64
31func pm_record(activity: *u8, role: *u8, requester: *u8, disp: *u8) -> i64
43func pm_route(activity: *u8, target: *u8, oldf: *u8, newf: *u8, requester: *u8) -> i64
60func pm_run(path: *u8, a1: *u8, a2: *u8, a3: *u8, a4: *u8, a5: *u8) -> i64
73func pm_publish(src: *u8, dest: *u8, site: *u8, requester: *u8, policy: *u8) -> i64
82func main(argc: i64, argv: *i64) -> i64