nx_select_test.nx
buildroot/runtime/nx_select_test.nx
about
nx_select_test.nx -- smoke for nx_select SA-4 MVP.
Exercises six scenarios across the selection pipeline:
1. Empty input -> NX_SEL_BAD_INPUT
2. Single candidate that fits -> returns that index
3. Two candidates, one's ISA mask excludes the host -> picks the fit
4. Two candidates both fit, different cost -> picks lower cost
5. Policy weight swap (throughput vs energy) flips selection
6. Tier filter (variant requires HPC, host is LAPTOP) -> filtered out
SA-4 verification gate per NISHI_SELF_ASSEMBLY_ROADMAP.md ยง8:
"picks variants A on hardware H_A and B on H_B with both smokes
passing on their respective hosts" -- demonstrated in code by
synthesizing probes for both hosts and asserting different
selections.
dependencies 4 imports · 0 importers
imports: nx_syscalls.nxnx_probe.nxnx_calibrate.nxnx_select.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| none |
functions
| 26 | func _make_probe(isa: i64) -> *NxProbeRecord |
| 39 | func main() -> i64 |