code wiki / _hdl_build / nx_cdcl_sat_gate.nx

nx_cdcl_sat_gate.nx

buildroot/runtime/_hdl_build/nx_cdcl_sat_gate.nx

8966 B120 linesdepth 4pulls 4 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

dependencies 3 imports · 0 importers

nx_gate_gn.nx nx_gate_base.nx nx_syscalls.nx nx_cdcl_sat_gate.nx

imports: nx_gate_gn.nxnx_gate_base.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 gw sys_write sys_mmap solve sys_mmap ↻ lit_true var_of lit_false var_of ↻ var_of ↻ gn lit_true ↻ sys_exit

structs

none

consts

none

functions

17func grow(name: *u8, ok: i64) -> i64 { if ok==1 { gw(" PASS " as *u8) } else { gw(" FAIL " as *u8) } gw(name); gw("
calls 1: gw
19func var_of(lit: i64) -> i64 { if lit<0 { return 0-lit } return lit }
called by 2: solvemain calls 1: var_of
20func lit_true(lit: i64, val: *i64) -> i64 { let v: i64=var_of(lit); if val[v]==0 { return 0 } if lit>0 { if val[v]==1 { return 1 } return 0 } if val[v]==(0-1) { return 1 } return 0 }
called by 1: solve calls 1: var_of
21func lit_false(lit: i64, val: *i64) -> i64 { let v: i64=var_of(lit); if val[v]==0 { return 0 } if lit>0 { if val[v]==(0-1) { return 1 } return 0 } if val[v]==1 { return 1 } return 0 }
24func solve(NV: i64, nc0: i64, lits: *i64, cstart: *i64, clen: *i64, val: *i64, lc_out: *i64) -> i64
76func main() -> i64