795 B
795 B
Fast Ops Optimizations Plan (Draft)
Baseline
- See
notes/nested_range_baseline.md
Candidates (not started)
- Primitive comparisons (done)
- Emit fast CMP variants for known ObjString/ObjInt/ObjReal using temp/stable slots.
- MixedCompareBenchmarkTest: 374 ms -> 347 ms.
- Mixed numeric ops
- Ensure INT+REAL arithmetic uses INT_TO_REAL + REAL op with no extra moves/boxing.
- Boolean conversion
- Skip OBJ_TO_BOOL when compiler already has a BOOL slot.
- Range/loop hot path
- Keep range iteration in INT ops, avoid accidental boxing.
- Confirm loop-var slots avoid re-boxing in loop bodies.
- String ops
- Extend fast path for string comparisons in hot loops.
- Box/unbox audit
- Identify remaining BOX_OBJ / OBJ_TO_* in inner loops and eliminate when safe.