nyash-codex
d82c332a40
feat(joinir): Phase 135 P0 - ConditionLoweringBox allocator SSOT (ValueId collision fix)
## Summary
Root cause: ConditionLoweringBox was bypassing ConditionContext.alloc_value (SSOT allocator),
causing ValueId collisions between JoinIR condition params and lowered instructions.
## Changes
1. **ConditionLoweringBox (expr_lowerer.rs)**: Must use ConditionContext.alloc_value
- Pass &mut ConditionContext to lower_condition (SSOT allocator)
- Eliminates internal counter usage
2. **Allocator unification (condition_lowerer.rs, method_call_lowerer.rs)**:
- Accept &mut dyn FnMut() -> ValueId as allocator parameter
- Ensures all lowering paths use same SSOT allocator
3. **Boundary Copy deduplication (joinir_inline_boundary_injector.rs)**:
- Deduplicate condition_bindings by dst
- Fail-Fast if different sources target same dst (MIR SSA violation)
4. **Trim pattern fixes (trim_loop_lowering.rs, trim_pattern_validator.rs, stmts.rs)**:
- Use builder.next_value_id() instead of value_gen.next() in function context
- Ensures function-level ValueId allocation respects reserved PHI dsts
## Acceptance
✅ ./target/release/hakorune --verify apps/tests/phase133_json_skip_whitespace_min.hako
✅ Smoke: phase135_trim_mir_verify.sh - MIR SSA validation PASS
✅ Regression: phase132_exit_phi_parity.sh - 3/3 PASS
✅ Regression: phase133_json_skip_whitespace_llvm_exe.sh - compile-only PASS
🤖 Generated with Claude Code
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
2025-12-15 18:49:08 +09:00
..
2025-12-14 19:34:02 +09:00
2025-12-15 06:00:48 +09:00
2025-12-03 13:42:05 +09:00
2025-12-15 18:49:08 +09:00
2025-12-14 18:27:24 +09:00
2025-12-14 18:55:05 +09:00
2025-12-15 18:49:08 +09:00
2025-12-13 17:26:15 +09:00
2025-12-14 05:24:31 +09:00
2025-12-14 09:47:23 +09:00
2025-12-05 16:08:56 +09:00
2025-12-04 06:02:03 +09:00
2025-12-04 06:02:03 +09:00
2025-12-03 13:59:06 +09:00
2025-12-05 23:33:06 +09:00
2025-12-05 23:33:06 +09:00
2025-12-13 22:21:04 +09:00
2025-12-14 18:27:24 +09:00
2025-12-08 04:14:28 +09:00
2025-12-02 21:52:18 +09:00
2025-12-10 00:01:53 +09:00
2025-12-04 06:02:03 +09:00
2025-12-14 19:34:02 +09:00
2025-12-08 06:14:03 +09:00
2025-12-08 00:09:45 +09:00
2025-12-03 14:33:04 +09:00
2025-12-06 16:22:38 +09:00
2025-12-08 18:36:13 +09:00
2025-12-04 17:47:19 +09:00
2025-12-11 20:54:33 +09:00
2025-12-11 00:33:04 +09:00
2025-12-11 00:33:04 +09:00
2025-12-12 03:15:45 +09:00
2025-12-12 04:06:03 +09:00
2025-12-12 03:31:58 +09:00
2025-12-12 04:40:46 +09:00
2025-12-12 07:13:34 +09:00
2025-12-12 04:50:26 +09:00
2025-12-12 16:40:20 +09:00
2025-12-12 17:12:58 +09:00
2025-12-12 22:15:41 +09:00
2025-12-12 23:02:40 +09:00
2025-12-12 23:02:40 +09:00
2025-12-13 02:22:29 +09:00
2025-12-13 03:47:54 +09:00
2025-12-13 03:41:20 +09:00
2025-12-13 03:41:26 +09:00
2025-12-13 03:23:02 +09:00
2025-12-13 03:41:40 +09:00
2025-12-13 03:41:40 +09:00
2025-12-13 03:41:40 +09:00
2025-12-13 05:34:56 +09:00
2025-12-13 05:34:56 +09:00
2025-12-13 05:35:04 +09:00
2025-12-13 05:35:14 +09:00
2025-12-13 05:35:35 +09:00
2025-12-13 21:32:35 +09:00
2025-12-13 16:20:33 +09:00
2025-12-13 19:01:14 +09:00
2025-12-13 19:01:14 +09:00
2025-12-13 19:01:14 +09:00
2025-12-14 05:24:31 +09:00
2025-12-14 05:55:21 +09:00
2025-12-14 05:27:39 +09:00
2025-12-14 05:24:31 +09:00
2025-12-14 05:24:31 +09:00
2025-12-15 11:47:58 +09:00
2025-12-14 06:25:42 +09:00
2025-12-14 09:19:00 +09:00
2025-12-14 09:19:00 +09:00
2025-12-15 06:00:48 +09:00
2025-12-12 03:15:45 +09:00
2025-12-08 21:26:57 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-12 04:19:06 +09:00
2025-12-12 04:19:06 +09:00
2025-12-11 02:35:31 +09:00
2025-12-12 03:15:45 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 13:13:08 +09:00
2025-12-12 03:15:45 +09:00
2025-12-12 04:19:06 +09:00
2025-12-12 04:19:06 +09:00
2025-12-11 15:08:14 +09:00
2025-12-11 15:08:14 +09:00
2025-12-07 21:02:20 +09:00
2025-12-07 21:02:20 +09:00
2025-12-12 05:07:01 +09:00
2025-12-12 17:51:53 +09:00
2025-12-12 18:08:00 +09:00
2025-12-12 18:45:08 +09:00
2025-12-12 22:51:21 +09:00
2025-12-12 22:51:21 +09:00
2025-12-12 23:02:40 +09:00
2025-12-13 03:23:02 +09:00
2025-12-13 05:34:56 +09:00
2025-12-13 05:35:04 +09:00
2025-12-13 05:35:35 +09:00
2025-12-13 05:35:35 +09:00
2025-12-05 16:06:39 +09:00
2025-12-06 11:10:38 +09:00
2025-12-12 04:19:06 +09:00
2025-12-10 18:45:04 +09:00
2025-12-10 19:08:18 +09:00
2025-12-10 22:48:45 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 02:35:31 +09:00
2025-12-11 15:08:14 +09:00
2025-11-23 05:53:27 +09:00
2025-12-07 21:02:20 +09:00
2025-12-14 03:36:45 +09:00
2025-12-14 21:28:41 +09:00
2025-12-14 21:28:41 +09:00
2025-12-10 21:53:27 +09:00
2025-12-12 23:11:45 +09:00
2025-12-10 00:29:25 +09:00
2025-12-04 03:58:02 +09:00
2025-12-04 12:40:01 +09:00
2025-11-21 07:00:05 +09:00
2025-11-21 08:03:03 +09:00
2025-11-21 08:03:03 +09:00
2025-12-08 15:17:53 +09:00
2025-11-20 17:10:03 +09:00
2025-11-20 17:10:03 +09:00
2025-11-20 17:10:03 +09:00