code wiki / _hdl_build / nx_analyst_markets.nx

nx_analyst_markets.nx

buildroot/runtime/_hdl_build/nx_analyst_markets.nx

7188 B123 linesdepth 5pulls 6 transitivereach 0 importersview sourcekind tooltopic analyst
docsdependenciesstructsconstsfunctions

about

nx_analyst_markets.nx -- AN10 RUNNER: evaluate knowledge/analyst/ac_markets.cmp (overseas + wholesale lens) and emit the cross-border report. Self-checking against hand-computed values; durable Examiner anchor ANALYST-MKT. license_tier: ORIGINAL

dependencies 2 imports · 0 importers

nx_market_cmp.nx nx_syscalls.nx nx_analyst_markets.nx

imports: nx_market_cmp.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 mc_parse_file sys_mmap ↻ sys_read_file sys_openat_rd sys_lseek sys_mmap ↻ sys_read sys_close mc_parse mc_alloc sys_mmap ↻ ld_line_end mc_line ld_skip sys_mmap ↻ ld_ints sys_mmap ↻ ld_int ld_skip ↻ sg_valid am_wf sys_write sys_exit mc_eval sys_mmap ↻ mc_per_ton mc_structure mc_spread_q10 mc_distinct_classes sys_mmap ↻ mc_ratio_q10 mc_per_ton ↻ sys_openat_wr am_label am_wn sys_mmap ↻ sys_write ↻ mc_equip_share_permil

structs

none

consts

6const K_MAGIC_191666: i64 = 191666
7const K_MAGIC_32000: i64 = 32000
8const K_MAGIC_1602: i64 = 1602
9const K_MAGIC_44800: i64 = 44800
10const K_MAGIC_175000: i64 = 175000
11const K_MAGIC_1024: i64 = 1024
12const K_MAGIC_4000: i64 = 4000
13const K_MAGIC_4571: i64 = 4571
14const K_MAGIC_125000: i64 = 125000
15const K_MAGIC_28000: i64 = 28000
16const K_MAGIC_10036: i64 = 10036

functions

18func am_wf(fd: i64, s: *u8) -> i64 { var n: i64=0; while s[n]!=(0 as u8){n=n+1} sys_write(fd,s,n); return 0 }
called by 1: main calls 1: sys_write
19func am_wn(fd: i64, v: i64) -> i64 { let bb: *u8=sys_mmap(28); var m: i64=v; if m<0{m=0-m;sys_write(fd,"-" as *u8,1)} let t: *u8=sys_mmap(28); 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 i: i64=0; while i<k{bb[i]=t[k-1-i];i=i+1} sys_write(fd,bb,k); return 0 }
called by 1: main calls 2: sys_mmapsys_write
21func am_label(i: i64) -> *u8
called by 1: main
28func main() -> i64