refactor(mir): phase260 p0 edge-args plumbing (strangler) + ssot api + docs
This commit is contained in:
@ -394,7 +394,7 @@ impl MirInterpreter {
|
||||
};
|
||||
Ok(BlockOutcome::Return(result))
|
||||
}
|
||||
Some(MirInstruction::Jump { target }) => Ok(BlockOutcome::Next {
|
||||
Some(MirInstruction::Jump { target, .. }) => Ok(BlockOutcome::Next {
|
||||
target: *target,
|
||||
predecessor: block.id,
|
||||
}),
|
||||
@ -402,6 +402,7 @@ impl MirInterpreter {
|
||||
condition,
|
||||
then_bb,
|
||||
else_bb,
|
||||
..
|
||||
}) => {
|
||||
// Dev counter: count branch terminators actually evaluated
|
||||
self.branch_count = self.branch_count.saturating_add(1);
|
||||
|
||||
@ -388,7 +388,7 @@ impl WasmCodegen {
|
||||
}
|
||||
|
||||
// Control Flow Instructions (Critical for loops and conditions)
|
||||
MirInstruction::Jump { target } => {
|
||||
MirInstruction::Jump { target, .. } => {
|
||||
// Unconditional jump to target basic block
|
||||
// Use WASM br instruction to break to the target block
|
||||
Ok(vec![format!("br $block_{}", target.as_u32())])
|
||||
@ -398,6 +398,7 @@ impl WasmCodegen {
|
||||
condition,
|
||||
then_bb,
|
||||
else_bb,
|
||||
..
|
||||
} => {
|
||||
// Conditional branch based on condition value
|
||||
// Load condition value and branch accordingly
|
||||
|
||||
Reference in New Issue
Block a user