rust/tests/mir-opt/loop_test.main.SimplifyCfg-promote-consts.after.mir

53 lines
2.6 KiB
Rust
Raw Normal View History

2020-08-16 03:44:53 -05:00
// MIR for `main` after SimplifyCfg-promote-consts
2020-04-02 16:09:01 -05:00
fn main() -> () {
2022-07-27 13:47:42 -05:00
let mut _0: (); // return place in scope 0 at $DIR/loop_test.rs:+0:11: +0:11
let _1: (); // in scope 0 at $DIR/loop_test.rs:+4:5: +6:6
let mut _2: bool; // in scope 0 at $DIR/loop_test.rs:+4:8: +4:12
let mut _3: !; // in scope 0 at $DIR/loop_test.rs:+4:13: +6:6
let mut _4: !; // in scope 0 at $DIR/loop_test.rs:+7:5: +10:6
let mut _5: (); // in scope 0 at $DIR/loop_test.rs:+0:1: +11:2
let _6: i32; // in scope 0 at $DIR/loop_test.rs:+8:13: +8:14
2020-04-02 16:09:01 -05:00
scope 1 {
2022-07-27 13:47:42 -05:00
debug x => _6; // in scope 1 at $DIR/loop_test.rs:+8:13: +8:14
2020-04-02 16:09:01 -05:00
}
bb0: {
2022-07-27 13:47:42 -05:00
StorageLive(_1); // scope 0 at $DIR/loop_test.rs:+4:5: +6:6
StorageLive(_2); // scope 0 at $DIR/loop_test.rs:+4:8: +4:12
_2 = const true; // scope 0 at $DIR/loop_test.rs:+4:8: +4:12
switchInt(move _2) -> [0: bb2, otherwise: bb1]; // scope 0 at $DIR/loop_test.rs:+4:8: +4:12
2020-04-02 16:09:01 -05:00
}
2020-10-02 15:11:24 -05:00
bb1: {
2022-07-27 13:47:42 -05:00
_0 = const (); // scope 0 at $DIR/loop_test.rs:+5:9: +5:15
StorageDead(_2); // scope 0 at $DIR/loop_test.rs:+6:5: +6:6
StorageDead(_1); // scope 0 at $DIR/loop_test.rs:+6:5: +6:6
return; // scope 0 at $DIR/loop_test.rs:+11:2: +11:2
2020-04-02 16:09:01 -05:00
}
bb2: {
2022-07-27 13:47:42 -05:00
_1 = const (); // scope 0 at $DIR/loop_test.rs:+6:6: +6:6
StorageDead(_2); // scope 0 at $DIR/loop_test.rs:+6:5: +6:6
StorageDead(_1); // scope 0 at $DIR/loop_test.rs:+6:5: +6:6
StorageLive(_4); // scope 0 at $DIR/loop_test.rs:+7:5: +10:6
goto -> bb3; // scope 0 at $DIR/loop_test.rs:+7:5: +10:6
2020-04-02 16:09:01 -05:00
}
2020-10-02 15:11:24 -05:00
bb3: {
2023-04-05 03:17:40 -05:00
falseUnwind -> [real: bb4, unwind: bb5]; // scope 0 at $DIR/loop_test.rs:+7:5: +10:6
2020-04-02 16:09:01 -05:00
}
2020-10-02 15:11:24 -05:00
bb4: {
2022-07-27 13:47:42 -05:00
StorageLive(_6); // scope 0 at $DIR/loop_test.rs:+8:13: +8:14
_6 = const 1_i32; // scope 0 at $DIR/loop_test.rs:+8:17: +8:18
FakeRead(ForLet(None), _6); // scope 0 at $DIR/loop_test.rs:+8:13: +8:14
StorageDead(_6); // scope 0 at $DIR/loop_test.rs:+10:5: +10:6
2021-06-08 19:00:00 -05:00
goto -> bb3; // scope 0 at no-location
2020-10-02 15:11:24 -05:00
}
2021-01-01 12:38:11 -06:00
bb5 (cleanup): {
2022-07-27 13:47:42 -05:00
resume; // scope 0 at $DIR/loop_test.rs:+0:1: +11:2
2020-04-02 16:09:01 -05:00
}
}