code wiki / (root) / nx_swcompare_preview_matrix_t56.nx

nx_swcompare_preview_matrix_t56.nx

buildroot/runtime/nx_swcompare_preview_matrix_t56.nx

132755 B1647 linesdepth 10pulls 31 transitivereach 1 importersview sourcekind tooltopic swcompare
docsdependenciesstructsconstsfunctions

about

nx_swcompare_matrix.nx -- GENERIC, data-driven, liar-killed SoftwareCompare MATRIX generator. Reads knowledge/compare/<domain>.matrix (label|organ|symbol|exceed|ONE CELL PER @cols ENTRY|note + @title/@sub/@cols directives), MEASURES each Nishi cell by requiring the implementing symbol to EXIST in the real organ source on disk (no self-grading), and emits a head-to-head SoftwareCompare page (Nishi + N named competitors, N = the @cols count, bounded only by SWC_ROW_STRIDE). Retires the per-domain bespoke nx_swcompare_<domain> matrix organs: a new comparison = one .matrix data file, ZERO code. Two modes: no html arg = console census + liar-kill gate (exit 0/1); "html" = emit the page to stdout. NOTE: no '#' or '!' in string literals (nx_cc lexer trap) -> rgb() colors + DOCTYPE '!' emitted as a byte. license_tier: ORIGINAL expect_exit: 0

dependencies 7 imports · 1 importers

nx_syscalls.nx nx_tool_run.nx nx_comparetree_lib.nx nx_swcompare_preview_lib_t56.nx nx_catalog_lib.nx nx_swcompare_preview_sota_t56.nx nx_evprofile_lib.nx nx_swcompare_preview_matrix_t5 nx_compare_preview_effect_gate_t56

imports: nx_syscalls.nxnx_tool_run.nxnx_comparetree_lib.nxnx_swcompare_preview_lib_t56.nxnx_catalog_lib.nxnx_swcompare_preview_sota_t56.nxnx_evprofile_lib.nx

imported by: nx_compare_preview_effect_gate_t56.nx

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

main w sys_write sys_exit 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 ↻ scopy ct_compare_read_published ct_read_2dir sys_mmap ↻ ct_build_path ct_cat ct_read sys_openat_rd sys_read sys_close ct_pick ct_first_published ct_second_published ct_swap_tree ct_first_published ↻ ct_second_published ↻ sl_new sys_mmap ↻ sl_load sys_mmap ↻ scopy ↻

structs

none

consts

36const K_MAGIC_5381: i64 = 5381
42const GAL_PROBE_CAP: i64 = 16384 // a probe's stdout reserve (kkfacts decode measures ~1.5KB); brim announces
43const GAL_PROBE_AV: i64 = 6 // elf + up to 3 spec tokens + artifact path + NUL
44const K_MAGIC_262144: i64 = 262144
45const K_MAGIC_20480: i64 = 20480
46const K_MAGIC_20479: i64 = 20479
53const SWC_ROW_STRIDE: i64 = 16
54const SWC_ROW_FIXED: i64 = 5
74const MXH_MAX: i64 = 64 // distinct class tokens; the ladder has 10 verdicts plus GATE: variants, and an overflow is COUNTED, never silent
254const RP_HDR: *u8 = "<h3 id='refs'>References</h3>\n<div class='meth'><b>Beyond a link list.</b> Every reference below resolves twice &mdash; the publisher's copy and, where banked, the estate's own <b>non-rottable library mirror</b> with a <b>content pin</b> &mdash; and carries its <b>evidence class</b> plus the exact claim on this page it grounds. Keyed marks like <span class='cite'>[key]</span> in the matrix notes jump here. A dash means honestly absent, never assumed.</div>\n<ol class='refs'>\n" as *u8
314const GAL_KIND_IMG: i64 = 1
315const GAL_KIND_VIDEO: i64 = 2
316const GAL_KIND_AUDIO: i64 = 3
317const GAL_KIND_TEXT: i64 = 4
318const GAL_TEXT_PREVIEW: i64 = 2048 // bytes of a text artifact shown inline; the whole file stays one click away
319const GAL_NSFW_PREFIX: *u8 = "nsfw:" as *u8
366const GAL_IMG_EXTRA: *u8 = "loading='lazy'" as *u8
622const RANK_READ_CAP: i64 = 65536
710const EVB_PATH_CAP: i64 = 512
711const EVB_SECS_PER_DAY: i64 = 86400
712const EVB_SECS_PER_HOUR: i64 = 3600
714const EVB_SCROLL_OPEN: *u8 = "<div style='overflow-x:auto'>"

functions

75func mx_tokclass_len(s: *u8) -> i64 { var i: i64 = 0; while s[i] != (0 as u8) { if s[i] == (32 as u8) { return i } i = i + 1 } return i }
called by 2: mx_tokclass_eqmain
76func mx_tokclass_eq(a: *u8, b: *u8) -> i64
called by 1: main calls 1: mx_tokclass_len
86func atoi(s: *u8) -> i64
called by 2: pc_stripmain
103func swc_src_hash(b: *u8, n: i64) -> i64
called by 1: main
114func mark(fd: i64, code: i64) -> i64
called by 2: mark_tdmain calls 2: wwc
125func mark_td(fd: i64, name: *u8, code: i64, nishi: i64) -> i64
called by 1: main calls 2: wmark
141func pc_pts(code: i64) -> i64 { if code == 2 { return 3 } if code == 1 { return 2 } if code == 3 { return 1 } return 0 }
called by 1: pc_strip
142func pc_strip(fd: i64, nishi: i64, exceed: i64, iswatch: i64, adopt: i64, rem: *u8, cf: *i64, ncol: i64, rf: *i64, rr: i64) -> i64
called by 1: main calls 3: pc_ptswatoi
202func dstate_REMOVED_SEE_LIB(fd: i64, id: *u8, ds: *u8, dn: i64) -> i64
calls 2: wwc
261func gp_probe(dom: *u8, file: *u8) -> i64
273func wesc(fd: i64, b: *u8, n: i64) -> i64
284func gal_probe_run(probe: *u8, dom: *u8, file: *u8, pbuf: *u8, plen: *i64) -> i64
320func gal_kind_code(k: *u8) -> i64
called by 1: gal_pass_heading calls 1: streq
328func gal_kind_name(c: i64) -> *u8
337func gal_attr(fd: i64, s: *u8) -> i64
called by 1: gal_html_heading calls 2: wwc
349func gal_text_preview(fd: i64, dom: *u8, file: *u8) -> i64
372func gal_text(fd: i64, s: *u8) -> i64
381func gal_html(fld: *i64, count: i64, dom: *u8, probe: *u8, kind: i64, gated: i64) -> i64 { return gal_html_heading(fld, count, dom, probe, kind, gated, 2) }
382func gal_html_heading(fld: *i64, count: i64, dom: *u8, probe: *u8, kind: i64, gated: i64, heading_level: i64) -> i64
446func gal_json(fld: *i64, count: i64, dom: *u8, probe: *u8, kind: i64, gated: i64) -> i64
469func gal_pass(path: *u8, buf: *u8, cap: i64, mode: i64, dom: *u8) -> i64 { return gal_pass_heading(path, buf, cap, mode, dom, 2) }
470func gal_pass_heading(path: *u8, buf: *u8, cap: i64, mode: i64, dom: *u8, heading_level: i64) -> i64
514func plan_pass_PRELIFT_UNREACHABLE(path: *u8, buf: *u8, cap: i64, phase: i64) -> i64
604func con_row(label: *u8, ns: i64) -> i64
626func rank_pass(dom: *u8, cap: i64) -> i64 { return rank_pass_heading(dom, cap, 2) }
627func rank_pass_heading(dom: *u8, cap: i64, heading_level: i64) -> i64
718func evb_remedy(fired: i64, name: *u8, remedy: *u8) -> i64
725func evb_pair(label: *u8, a: i64, b: i64) -> i64
730func evb_one(label: *u8, a: i64) -> i64
738func evb_word(label: *u8, word: *u8) -> i64
756func evb_bite(f: *i64) -> i64
774func ev_pass(dom: *u8) -> i64 { return ev_pass_heading(dom, 2) }
775func ev_pass_heading(dom: *u8, heading_level: i64) -> i64
899func main(argc: i64, argv: *i64) -> i64