code wiki / (root) / fx_log2_test.nx

fx_log2_test.nx

buildroot/runtime/fx_log2_test.nx

2055 B58 linesdepth 4pulls 4 transitivereach 0 importersview sourcekind gate/prooftopic fx
docsdependenciesstructsconstsfunctions

about

fx_log2_test.nx -- KAT for the fixed-point binary logarithm. Run via the sovereign native lane: _offc/nx_compile_x86_native.elf fx_log2_test.nx > t.s as t.s -o t.o && ld -o t.elf t.o && ./t.elf ; echo $? Exit 0 = all assertions PASS; exit N = assertion N failed. Goldens hand-computed; powers of two are EXACT, irrationals are bounded (the fixed-point algorithm is deterministic, so the band is a tight correctness window, not a fudge factor).

dependencies 1 imports · 0 importers

fx.nx fx_log2_test.nx

imports: fx.nx

imported by: nobody (leaf or entry point)

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

main fx_log2 fx_mul within fx_log2_int fx_log2 ↻ fx_from_int fx_div

structs

none

consts

none

functions

15func within(a: i64, b: i64, tol: i64) -> i64
called by 1: main
22func main() -> i64