pr2.2
This commit is contained in:
@@ -1,54 +1,3 @@
|
||||
# PR-2.2 — Simplify VM Execution Loop (Pure Stack Machine)
|
||||
|
||||
### Briefing
|
||||
|
||||
The VM should operate as a simple stack-based interpreter with a clear fetch–decode–execute loop, without hidden side channels or legacy behaviors.
|
||||
|
||||
### Target
|
||||
|
||||
* Normalize the VM main loop to a clean stack-machine structure.
|
||||
* Remove any legacy control paths tied to HIP/RC behavior.
|
||||
|
||||
### Work items
|
||||
|
||||
* Refactor the main interpreter loop to:
|
||||
|
||||
* Fetch instruction at PC.
|
||||
* Decode opcode.
|
||||
* Execute operation on stack/frames.
|
||||
* Remove any conditional logic that depends on HIP/RC state.
|
||||
* Ensure PC advancement is canonical and centralized.
|
||||
|
||||
### Acceptance checklist
|
||||
|
||||
* [ ] VM loop is structurally simple and readable.
|
||||
* [ ] No HIP/RC conditionals remain.
|
||||
* [ ] VM compiles and runs basic programs.
|
||||
* [ ] `cargo test` passes.
|
||||
|
||||
### Tests
|
||||
|
||||
* Existing tests only.
|
||||
|
||||
### Junie instructions
|
||||
|
||||
**You MAY:**
|
||||
|
||||
* Refactor the interpreter loop for clarity.
|
||||
* Remove legacy conditionals.
|
||||
|
||||
**You MUST NOT:**
|
||||
|
||||
* Change opcode semantics.
|
||||
* Introduce GC, closures, or coroutines here.
|
||||
* Redesign the instruction set.
|
||||
|
||||
**If unclear:**
|
||||
|
||||
* Ask before modifying control flow assumptions.
|
||||
|
||||
---
|
||||
|
||||
# PR-2.3 — Normalize Value Model (Stack vs Heap References)
|
||||
|
||||
### Briefing
|
||||
|
||||
Reference in New Issue
Block a user