|
|
80df1cccd4
|
feat(control_tree): Phase 129-C post-if via post_k continuation
|
2025-12-18 08:33:56 +09:00 |
|
|
|
b2af9fb297
|
docs: update normalized_shadow references and Phase 129 status
|
2025-12-18 08:18:20 +09:00 |
|
|
|
36717cad4f
|
docs: update Now/INDEX for Phase 129-B join_k as-last
|
2025-12-18 07:54:16 +09:00 |
|
|
|
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 |
|
|
|
083be99214
|
test(joinir): Phase 129 P2 - add post-if return var fixture + VM smoke
- Add phase129_if_only_post_if_return_var_min.hako
- Pattern: x=1; if flag==1 { x=2 }; print(x)
- Tests join_k continuation env merge
- Add phase129_if_only_post_if_return_var_vm.sh
- Expected output: 2 (x updated in then branch)
- Dev-only: NYASH_JOINIR_DEV=1 HAKO_JOINIR_STRICT=1
Note: Currently passes via fallback path (non-Normalized)
P1 implementation (join_k materialization) is next step
|
2025-12-18 07:18:00 +09:00 |
|