code wiki / _hdl_build / nx_recip64_test.nx

nx_recip64_test.nx

buildroot/runtime/_hdl_build/nx_recip64_test.nx

3398 B97 linesdepth 10pulls 11 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

about

nx_recip64_test.nx -- proves the 64-bit Goldschmidt divider GATE-NETWORK (nx_recip64_synth) emits what the bit-exact scalar computes: cross-checked vs the proven unsigned oracle (nx_rv64im_udiv / urem), quotient AND remainder, over dense-small + every power of two + random FULL 64-bit (incl. bit-63-set, via xorshift) + the overflow edges. Known answer: "<ok> <total>" ok==total.

dependencies 2 imports · 0 importers

nx_recip64.nx rv64im_min_alu.nx nx_recip64_test.nx

imports: nx_recip64.nxrv64im_min_alu.nx

imported by: nobody (leaf or entry point)

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

main nx_recip64_synth div_const r64_msb div_const ↻ div_op2 div_op2 ↻ r64_mulhu nx_mul_wide_synth nx_sink_init_mem nx_mul_wide_sink nx_sink_const nx_hdl_wire nx_sink_cell nx_hdl_wire ↻ sys_mmap div_mux r64t_chk nx_gsim_run nx_gsim_kind_supported nx_gsim_eval_cell nx_rv64im_udiv nx_rv64im_ltu nx_rv64im_urem nx_rv64im_udiv ↻ nx_rv64im_lshr _emit_dec _nl

structs

none

consts

10const R64T_HALF: i64 = 0 - 9223372036854775808 // 2^63

functions

12func _emit_dec(v: i64) -> i64
called by 1: main
20func _nl() -> i64 { let z: *u8 = sys_mmap(2); z[0] = 10; sys_write(1, z, 1); return 0 }
called by 1: main
22func r64t_chk(g: *NxGsim, qnet: i64, rnet: i64, N: i64, D: i64) -> i64
33func main() -> i64