rust/tests/mir-opt/or_pattern.shortcut_second_...

101 lines
1.9 KiB
Rust

// MIR for `shortcut_second_or` after SimplifyCfg-initial
fn shortcut_second_or() -> () {
let mut _0: ();
let mut _1: ((i32, i32), i32);
let mut _2: (i32, i32);
let _3: (i32, i32);
let _4: i32;
scope 1 {
debug x => _3;
debug y => _4;
}
bb0: {
StorageLive(_1);
StorageLive(_2);
_2 = (const 0_i32, const 0_i32);
_1 = (move _2, const 0_i32);
StorageDead(_2);
PlaceMention(_1);
switchInt(((_1.0: (i32, i32)).0: i32)) -> [0: bb3, otherwise: bb2];
}
bb1: {
_0 = const ();
goto -> bb14;
}
bb2: {
switchInt(((_1.0: (i32, i32)).1: i32)) -> [1: bb4, otherwise: bb1];
}
bb3: {
switchInt((_1.1: i32)) -> [2: bb5, 3: bb6, otherwise: bb1];
}
bb4: {
switchInt((_1.1: i32)) -> [2: bb7, 3: bb8, otherwise: bb1];
}
bb5: {
falseEdge -> [real: bb10, imaginary: bb6];
}
bb6: {
falseEdge -> [real: bb11, imaginary: bb2];
}
bb7: {
falseEdge -> [real: bb12, imaginary: bb8];
}
bb8: {
falseEdge -> [real: bb13, imaginary: bb1];
}
bb9: {
_0 = const ();
StorageDead(_4);
StorageDead(_3);
goto -> bb14;
}
bb10: {
StorageLive(_3);
_3 = (_1.0: (i32, i32));
StorageLive(_4);
_4 = (_1.1: i32);
goto -> bb9;
}
bb11: {
StorageLive(_3);
_3 = (_1.0: (i32, i32));
StorageLive(_4);
_4 = (_1.1: i32);
goto -> bb9;
}
bb12: {
StorageLive(_3);
_3 = (_1.0: (i32, i32));
StorageLive(_4);
_4 = (_1.1: i32);
goto -> bb9;
}
bb13: {
StorageLive(_3);
_3 = (_1.0: (i32, i32));
StorageLive(_4);
_4 = (_1.1: i32);
goto -> bb9;
}
bb14: {
StorageDead(_1);
return;
}
}