Fuzzbug fix
This commit is contained in:
parent
65e47c8a32
commit
973ca3833a
|
@ -217,15 +217,18 @@ impl WasmRegion {
|
||||||
forward_targets
|
forward_targets
|
||||||
);
|
);
|
||||||
|
|
||||||
let top = WasmRegion::Block(
|
// Enclose loop nest in a virtual loop, to handle forward
|
||||||
0,
|
// edges in a unified way even outside any loop.
|
||||||
None,
|
let top = Self::compute_for_node(
|
||||||
loop_nest
|
cfg,
|
||||||
.nodes
|
&forward_targets,
|
||||||
.iter()
|
&Node::Loop(BlockId::MAX, loop_nest.nodes.clone()),
|
||||||
.map(|node| Self::compute_for_node(cfg, &forward_targets, node))
|
|
||||||
.collect::<Vec<_>>(),
|
|
||||||
);
|
);
|
||||||
|
let subregions = match top {
|
||||||
|
WasmRegion::Loop(_, subregions) => subregions,
|
||||||
|
_ => unreachable!(),
|
||||||
|
};
|
||||||
|
let top = WasmRegion::Block(0, None, subregions);
|
||||||
|
|
||||||
log::trace!("Wasm region: {:?}", top);
|
log::trace!("Wasm region: {:?}", top);
|
||||||
top
|
top
|
||||||
|
|
Loading…
Reference in a new issue