code wiki / _hdl_build / nx_product_atlas_build.nx

nx_product_atlas_build.nx

buildroot/runtime/_hdl_build/nx_product_atlas_build.nx

6367 B129 linesdepth 5pulls 8 transitivereach 0 importersview sourcekind tooltopic product
docsdependenciesstructsconstsfunctions

about

nx_product_atlas_build.nx -- FIRST PRODUCT-ATLAS: ingest the design-to-market NEEDS + CAPABILITIES + the COMPONENT keywords in the need notes into an eco_graph store (productgraph-) so nx_atlas_recombine can walk PRODUCTS, not just software. Nodes: each need, each capability, each component keyword; edges: need->cap (fulfils, by keyword match) + need->component (from note). Then `nx_atlas_recombine knowledge/store/productgraph-` produces PRODUCT recombinations. Imports eco_graph + store_seed_lib (coexist since the ss_begin_cap fix). usage: nx_product_atlas_build [needs-prefix] [caps-prefix] [out-prefix] license_tier: ORIGINAL expect_exit:0

dependencies 4 imports · 0 importers

nx_store_seed_lib.nx nx_seg_store.nx nx_eco_graph.nx nx_syscalls.nx nx_product_atlas_build.nx

imports: nx_store_seed_lib.nxnx_seg_store.nxnx_eco_graph.nxnx_syscalls.nx

imported by: nobody (leaf or entry point)

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

main sys_mmap sts_load ss_open_cached ssc_init sys_mmap ↻ ssc_sig_of ss_cat sys_fstatat ssc_streq ss_open ss_open2 sys_mmap ↻ ss_manifest_dyn ss_manifest_file_dyn ss_cat ↻ ss_loadfile sys_map_file ss_readall ss_load_aux2 sys_mmap ↻ ss_cat ↻ ss_loadfile ↻ ss_r32 sys_munmap ssl_total_keys ss_r32 ↻ ssl_pow2 ssl_build ss_r32 ↻ ssl_hash_entry ssl_key_eq ss_r32 ↻ ssl_lookup ssl_hash_entry ↻ ssl_key_eq ↻ ss_manifest_free sys_munmap ↻ sys_munmap ↻ ssc_retire_handle

structs

none

consts

11const PA_MAGIC_1024: i64 = 1024
12const PA_MAGIC_2048: i64 = 2048
13const PA_MAGIC_262144: i64 = 262144
15const PA_CAP: i64 = 262144
16const PA_NL: i64 = 10
17const PA_TAB: i64 = 9
18const PA_SP: i64 = 32
19const PA_MAXCOL: i64 = 16
20const PA_MAXROW: i64 = 64
21const CT_NOTE: i64 = 6

functions

23func pa_slen(s: *u8) -> i64 { var n: i64 = 0; while s[n] != (0 as u8) { n = n + 1 } return n }
called by 1: pa_w
24func pa_w(s: *u8) -> i64 { sys_write(1, s, pa_slen(s)); return 0 }
called by 1: main calls 2: sys_writepa_slen
25func pa_wn(v: i64) -> i64 { let b: *u8 = sys_mmap(24); var m: i64 = v; if m < 0 { sys_write(1, "-" as *u8, 1); m = 0 - m } let t: *u8 = sys_mmap(24); var k: i64 = 0; if m == 0 { t[0] = 48 as u8; k = 1 } while m > 0 { t[k] = (48 + (m%10)) as u8; m = m/10; k = k + 1 } var j: i64 = 0; while j < k { b[j] = t[k-1-j]; j = j + 1 } sys_write(1, b, k); return 0 }
called by 1: main calls 2: sys_mmapsys_write
26func pa_copy(dst: *u8, src: *u8, a: i64, b: i64) -> i64 { var n: i64 = 0; var i: i64 = a; while i < b { if n < 200 { dst[n] = src[i]; n = n + 1 } i = i + 1 } dst[n] = 0 as u8; return n }
called by 1: main
27func pa_cols(q: *u8, ls: i64, le: i64, sp: *i64) -> i64
called by 1: pa_parse
42func pa_has_sub(q: *u8, a: i64, b: i64, w: *u8, wl: i64) -> i64
called by 1: main
54func pa_parse(buf: *u8, n: i64, na: *i64, nb: *i64, ta: *i64, tb: *i64) -> i64
called by 1: main calls 2: sys_mmappa_cols
71func main(argc: i64, argv: *i64) -> i64