diff options
Diffstat (limited to 'src/test/mir-opt/matches_reduce_branches.match_nested_if.MatchBranchSimplification.64bit.diff')
-rw-r--r-- | src/test/mir-opt/matches_reduce_branches.match_nested_if.MatchBranchSimplification.64bit.diff | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/src/test/mir-opt/matches_reduce_branches.match_nested_if.MatchBranchSimplification.64bit.diff b/src/test/mir-opt/matches_reduce_branches.match_nested_if.MatchBranchSimplification.64bit.diff new file mode 100644 index 000000000..672c6b34e --- /dev/null +++ b/src/test/mir-opt/matches_reduce_branches.match_nested_if.MatchBranchSimplification.64bit.diff @@ -0,0 +1,42 @@ +- // MIR for `match_nested_if` before MatchBranchSimplification ++ // MIR for `match_nested_if` after MatchBranchSimplification + + fn match_nested_if() -> bool { + let mut _0: bool; // return place in scope 0 at $DIR/matches_reduce_branches.rs:+0:25: +0:29 + let _1: bool; // in scope 0 at $DIR/matches_reduce_branches.rs:+1:9: +1:12 + let mut _2: bool; // in scope 0 at $DIR/matches_reduce_branches.rs:+2:24: +2:28 ++ let mut _3: bool; // in scope 0 at $DIR/matches_reduce_branches.rs:+2:24: +2:28 + scope 1 { + debug val => _1; // in scope 1 at $DIR/matches_reduce_branches.rs:+1:9: +1:12 + } + + bb0: { + StorageLive(_1); // scope 0 at $DIR/matches_reduce_branches.rs:+1:9: +1:12 + StorageLive(_2); // scope 0 at $DIR/matches_reduce_branches.rs:+2:24: +2:28 + _2 = const true; // scope 0 at $DIR/matches_reduce_branches.rs:+2:24: +2:28 +- switchInt(move _2) -> [false: bb2, otherwise: bb1]; // scope 0 at $DIR/matches_reduce_branches.rs:+2:24: +2:28 +- } +- +- bb1: { ++ StorageLive(_3); // scope 0 at $DIR/matches_reduce_branches.rs:+2:24: +2:28 ++ _3 = move _2; // scope 0 at $DIR/matches_reduce_branches.rs:+2:24: +2:28 + StorageDead(_2); // scope 0 at $DIR/matches_reduce_branches.rs:+2:51: +2:52 +- _1 = const true; // scope 0 at $DIR/matches_reduce_branches.rs:+8:13: +8:17 +- goto -> bb3; // scope 0 at $DIR/matches_reduce_branches.rs:+8:13: +8:17 +- } +- +- bb2: { +- StorageDead(_2); // scope 0 at $DIR/matches_reduce_branches.rs:+2:51: +2:52 +- _1 = const false; // scope 0 at $DIR/matches_reduce_branches.rs:+10:14: +10:19 +- goto -> bb3; // scope 0 at $DIR/matches_reduce_branches.rs:+10:14: +10:19 +- } +- +- bb3: { ++ _1 = Ne(_3, const false); // scope 0 at $DIR/matches_reduce_branches.rs:+10:14: +10:19 ++ StorageDead(_3); // scope 0 at $DIR/matches_reduce_branches.rs:+2:24: +2:28 + _0 = _1; // scope 1 at $DIR/matches_reduce_branches.rs:+12:5: +12:8 + StorageDead(_1); // scope 0 at $DIR/matches_reduce_branches.rs:+13:1: +13:2 + return; // scope 0 at $DIR/matches_reduce_branches.rs:+13:2: +13:2 + } + } + |