code wiki / (root) / fp32_parts_test.nx

fp32_parts_test.nx

buildroot/runtime/fp32_parts_test.nx

2434 B83 linesdepth 4pulls 4 transitivereach 0 importersview sourcekind gate/proof
docsdependenciesstructsconstsfunctions

about

fp32_parts_test.nx -- round-trip literal conversion. Verifies fp32_from_parts produces the correct IEEE 754 bit pattern for common literal values. These are the reference encodings the parser will embed in VK_CONST_INT values when it hits TK_FLOAT. Canonical patterns cross-referenced against C compilers: 0.0 -> 0x00000000 1.0 -> 0x3F800000 2.0 -> 0x40000000 0.5 -> 0x3F000000 1.5 -> 0x3FC00000 3.14 -> 0x4048F5C3 (exact fp32; our integer encoder may round by a ULP, so we allow ULP tolerance)

dependencies 2 imports · 0 importers

syscalls.nx quant.nx fp32_parts_test.nx

imports: syscalls.nxquant.nx

imported by: nobody (leaf or entry point)

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

main fp32_from_parts ulp_close

structs

none

consts

none

functions

19func ulp_close(a: i64, b: i64) -> i64 {
called by 1: main
28func main() -> i64 {