code wiki / _hdl_build / nx_rv64_tier.nx
nx_rv64_tier.nx
buildroot/runtime/_hdl_build/nx_rv64_tier.nx
about
nx_rv64_tier.nx -- the TIERED EXECUTION ENGINE (the SOTA emulator architecture: V8/HotSpot/QEMU-TCG-style). It
INTERPRETS cold code via the shared fk_step (so it cannot diverge from the golden interpreter), PROFILES loop
back-edges, and when a loop header crosses a hotness threshold it JIT-compiles that loop's region and CACHES the
native code; on subsequent entries the loop runs NATIVELY. Loops the JIT can't handle (unsupported op / control
flow leaving the region) simply stay interpreted -- fail-safe, never miscompiled. This is what makes the JIT
accelerate REAL mixed programs, not isolated loops. license_tier: ORIGINAL
dependencies 3 imports · 9 importers
imports: nx_syscalls.nxnx_rv64_fast.nxnx_rv64_jit.nx
imported by: nx_hwtest_matrix.nxnx_rv64_cjit_gate.nxnx_rv64_ctier_gate.nxnx_rv64_difftest.nxnx_rv64_jit_w_gate.nxnx_rv64_realc_gate.nxnx_rv64_run_bin_tier.nxnx_rv64_tier_gate.nxnx_rv64_toolchain_gate.nx
structs
| 73 | struct CReg |
consts
| none |
functions
| 13 | func tier_run(opk: *i64, rd: *i64, rs1: *i64, rs2: *i64, imm: *i64, ncount: i64, reg: *i64, mem: *u8, membytes: i64, maxsteps: i64, dev: *NxVirtioMmio, threshold: i64, stats: *i64) -> i64 called by 6: run_engine_tiermainmainmainmainmain calls 5: sys_mmapjit_set_membasefk_stepjit_compilejit_mmap_rwx |
| 86 | func jit_compile_creg(c: *CReg) -> i64 |
| 130 | func tier_run_c(opk: *i64, rd: *i64, rs1: *i64, rs2: *i64, imm: *i64, nhalf: i64, reg: *i64, mem: *u8, membytes: i64, maxsteps: i64, dev: *NxVirtioMmio, threshold: i64, stats: *i64) -> i64 |
| 187 | func tier_main_ignore() -> i64 { return 0 } |