rust/tests/mir-opt/simplify_cfg.main.SimplifyC...

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

69 lines
1.1 KiB
Diff
Raw Normal View History

2020-04-03 05:09:01 +08:00
- // MIR for `main` before SimplifyCfg-initial
+ // MIR for `main` after SimplifyCfg-initial
fn main() -> () {
2023-06-06 21:47:00 +08:00
let mut _0: ();
let mut _1: ();
let mut _2: bool;
let mut _3: !;
2020-04-03 05:09:01 +08:00
bb0: {
2023-06-06 21:47:00 +08:00
goto -> bb1;
2020-04-03 05:09:01 +08:00
}
bb1: {
2023-06-06 21:47:00 +08:00
- falseUnwind -> [real: bb2, unwind: bb11];
+ falseUnwind -> [real: bb2, unwind: bb6];
2021-09-18 08:00:00 +08:00
}
bb2: {
2023-06-06 21:47:00 +08:00
StorageLive(_2);
- _2 = bar() -> [return: bb3, unwind: bb11];
+ _2 = bar() -> [return: bb3, unwind: bb6];
2020-04-03 05:09:01 +08:00
}
2021-09-18 08:00:00 +08:00
bb3: {
2023-06-06 21:47:00 +08:00
switchInt(move _2) -> [0: bb5, otherwise: bb4];
2020-04-03 05:09:01 +08:00
}
2021-09-18 08:00:00 +08:00
bb4: {
2023-06-06 21:47:00 +08:00
_0 = const ();
- goto -> bb10;
+ StorageDead(_2);
+ return;
2020-04-03 05:09:01 +08:00
}
2021-09-18 08:00:00 +08:00
bb5: {
2023-06-06 21:47:00 +08:00
- goto -> bb8;
- }
-
2021-01-02 02:38:11 +08:00
- bb6: {
2023-06-06 21:47:00 +08:00
- unreachable;
2020-04-03 05:09:01 +08:00
- }
-
2021-01-02 02:38:11 +08:00
- bb7: {
2023-06-06 21:47:00 +08:00
- goto -> bb9;
2020-04-03 05:09:01 +08:00
- }
-
2021-01-02 02:38:11 +08:00
- bb8: {
2023-06-06 21:47:00 +08:00
_1 = const ();
- goto -> bb9;
- }
-
- bb9: {
2023-06-06 21:47:00 +08:00
StorageDead(_2);
goto -> bb1;
2020-04-03 05:09:01 +08:00
}
2020-10-03 04:11:24 +08:00
- bb10: {
2023-06-06 21:47:00 +08:00
- StorageDead(_2);
- return;
2021-01-02 02:38:11 +08:00
- }
-
- bb11 (cleanup): {
2021-09-18 08:00:00 +08:00
+ bb6 (cleanup): {
2023-06-06 21:47:00 +08:00
resume;
2020-10-03 04:11:24 +08:00
}
2020-04-03 05:09:01 +08:00
}