code wiki / (root) / nx_native_micro_bench.nx

nx_native_micro_bench.nx

buildroot/runtime/nx_native_micro_bench.nx

2104 B63 linesdepth 3pulls 3 transitivereach 0 importersview sourcekind benchtopic native
docsdependenciesstructsconstsfunctions

about

nx_native_micro_bench.nx -- minimal NATIVE x86_64 Nishi micro-bench. Goal: measure a tight integer-loop workload running NATIVE x86_64 (no qemu), output the wall-clock to stdout, return exit-code = 0. Apples-to-apples comparator vs the equivalent C loop run on the same hardware. Surfaces the substrate's REAL per-op cost when freed from the qemu interpreter (~100-1000x overhead). Workload: sum integers 0..N-1 with a register-only loop. Trivial math; the comparison is "how fast can Nishi emit tight loops on x86_64 vs gcc -O2 on the same loop."

dependencies 1 imports · 0 importers

nx_clock.nx nx_native_micro_bench.nx

imports: nx_clock.nx

imported by: nobody (leaf or entry point)

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

main nx_clock_monotonic_ns sys_mmap sys_clock_gettime_mono _emit_dec_i64

structs

none

consts

none

functions

20func _emit_dec_i64(fd: i64, n: i64) -> i64
called by 1: main
42func main() -> i64