|
|
b822355431
|
docs: Phase 129 progress report (P0-P3 complete)
## Completed ✅
P0: LLVM EXE smoke test for Phase 128
- VM+LLVM parity verified
- Regression tests pass (phase103, phase118, phase128)
P2: Post-if return var fixture + VM smoke
- phase129_if_only_post_if_return_var_min.hako
- Tests join_k env merge pattern
- Currently passes via fallback (non-Normalized)
P3: Documentation complete
- README.md: Goal, design, scope
- P1-implementation-plan.md: Detailed refactoring plan
- PROGRESS.md: This report
## In Progress 🔄
P1: Materialize join_k continuation
- Status: Analysis complete, awaiting user decision
- Options:
- A: In-place (fast, risky)
- B: Phased (recommended, safe)
## Test Results ✅
- cargo test --lib: 1165 passed
- phase128 VM: PASS
- phase128 LLVM EXE: PASS
- phase129 VM: PASS (fallback path)
- Regression: ALL PASS
## Feedback
Box-First:
- JoinKBuilder module proposed (join_k generation)
- EnvBuilder future consideration
Fail-Fast:
- verify_normalized_structure proposed
- verify_branch_is_return_literal too restrictive
Legacy:
- Phase 123-124 lower_if_node incomplete
- Placeholder logic in lhs_vid resolution
## Next Steps
Awaiting user/ChatGPT decision on Option A vs B
|
2025-12-18 07:20:46 +09:00 |
|
|
|
0d2eafd780
|
docs: Phase 129 P1 implementation plan (join_k materialization)
Detailed analysis of current state and required changes:
Current Issues:
- lower_if_node only processes then branch (incomplete)
- No join_k function generation
- verify_branch_is_return_literal too restrictive
- No env merging logic
Required Changes:
- Create JoinKBuilder helper (Box-First)
- Generate join_k as real JoinFunction
- then/else tail-call join_k with env
- Process post-if statements in join_k body
- Add verify_normalized_structure checks
Implementation Options:
- Option A: In-place modification (risky, fast)
- Option B: Phased approach (recommended, safe)
Recommended: Option B (3-phase rollout)
- Phase 129-A: JoinKBuilder foundation
- Phase 129-B: Branch lowering to join_k
- Phase 129-C: Post-if statement support
Open Questions:
1. Function ID allocation strategy
2. Post-if statement detection mechanism
3. env parameter passing representation
4. join_k naming convention
Next: User/ChatGPT decision on approach
|
2025-12-18 07:19:22 +09:00 |
|