Replace HashSet with BTreeSet for CFG predecessors/successors: - BasicBlock.predecessors: HashSet → BTreeSet - BasicBlock.successors: HashSet → BTreeSet - LoopFormOps.get_block_predecessors(): returns BTreeSet - BasicBlock.dominates(): takes &[BTreeSet<BasicBlockId>] This ensures deterministic PHI generation and test stability. Test results: - loop_with_continue_and_break tests: now deterministic (3/3 same output) - loopform tests: 14/14 PASS (no regressions) - merge_exit_with_classification tests: 3/3 PASS Technical changes (6 files): - basic_block.rs: BTreeSet types + new() initialization - loopform_builder.rs: trait signature + 2 mock implementations - phi_ops.rs: return type - json_v0_bridge/loop_.rs: return type Same pattern as Phase 25.1 (MirFunction.blocks HashMap → BTreeMap). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
loop_builder
SSA loop lowering for LoopForm v2. This module owns the block layout (preheader/header/body/latch/continue_merge/exit) and delegates PHI construction to phi_core.
Boundaries
- Handles loop CFG + variable snapshots only; no name解決やコード生成 beyond MIR emission.
- Uses
phi_coreboxes for PHI wiring; avoid duplicating PHI logic here. - Debug/experimental flags remain centralized in
loop_form.rs.
Submodules
control.rs: break/continue capture + predecessor bookkeepingloop_form.rs: main loop lowering pipelinestatements.rs: loop-body statement lowering entry pointif_lowering.rs: in-loopiflowering with JoinIR/PHI bridgephi_ops.rs: PHI emit helpers + LoopFormOps/PhiBuilderOps impls