]> git.proxmox.com Git - rustc.git/blob - src/test/mir-opt/issue_73223.main.SimplifyArmIdentity.diff
New upstream version 1.66.0+dfsg1
[rustc.git] / src / test / mir-opt / issue_73223.main.SimplifyArmIdentity.diff
1 - // MIR for `main` before SimplifyArmIdentity
2 + // MIR for `main` after SimplifyArmIdentity
3
4 fn main() -> () {
5 let mut _0: (); // return place in scope 0 at $DIR/issue-73223.rs:+0:11: +0:11
6 let _1: i32; // in scope 0 at $DIR/issue-73223.rs:+1:9: +1:14
7 let mut _2: std::option::Option<i32>; // in scope 0 at $DIR/issue-73223.rs:+1:23: +1:30
8 let mut _3: isize; // in scope 0 at $DIR/issue-73223.rs:+2:9: +2:16
9 let _4: i32; // in scope 0 at $DIR/issue-73223.rs:+2:14: +2:15
10 let mut _5: !; // in scope 0 at $DIR/issue-73223.rs:+3:17: +3:23
11 let mut _7: i32; // in scope 0 at $DIR/issue-73223.rs:+6:22: +6:27
12 let _8: (); // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
13 let mut _9: (&i32, &i32); // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
14 let mut _10: &i32; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
15 let mut _11: &i32; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
16 let _12: i32; // in scope 0 at $DIR/issue-73223.rs:+7:23: +7:24
17 let mut _15: bool; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
18 let mut _16: bool; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
19 let mut _17: i32; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
20 let mut _18: i32; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
21 let mut _19: !; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
22 let _21: !; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
23 let mut _22: core::panicking::AssertKind; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
24 let mut _23: &i32; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
25 let _24: &i32; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
26 let mut _25: &i32; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
27 let _26: &i32; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
28 let mut _27: std::option::Option<std::fmt::Arguments<'_>>; // in scope 0 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
29 scope 1 {
30 debug split => _1; // in scope 1 at $DIR/issue-73223.rs:+1:9: +1:14
31 let _6: std::option::Option<i32>; // in scope 1 at $DIR/issue-73223.rs:+6:9: +6:14
32 scope 3 {
33 debug _prev => _6; // in scope 3 at $DIR/issue-73223.rs:+6:9: +6:14
34 let _13: &i32; // in scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
35 let _14: &i32; // in scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
36 let mut _28: &i32; // in scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
37 scope 4 {
38 debug left_val => _13; // in scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
39 debug right_val => _14; // in scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
40 let _20: core::panicking::AssertKind; // in scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
41 scope 5 {
42 debug kind => _20; // in scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
43 }
44 }
45 }
46 }
47 scope 2 {
48 debug v => _4; // in scope 2 at $DIR/issue-73223.rs:+2:14: +2:15
49 }
50
51 bb0: {
52 StorageLive(_1); // scope 0 at $DIR/issue-73223.rs:+1:9: +1:14
53 StorageLive(_2); // scope 0 at $DIR/issue-73223.rs:+1:23: +1:30
54 Deinit(_2); // scope 0 at $DIR/issue-73223.rs:+1:23: +1:30
55 ((_2 as Some).0: i32) = const 1_i32; // scope 0 at $DIR/issue-73223.rs:+1:23: +1:30
56 discriminant(_2) = 1; // scope 0 at $DIR/issue-73223.rs:+1:23: +1:30
57 _3 = const 1_isize; // scope 0 at $DIR/issue-73223.rs:+1:23: +1:30
58 goto -> bb3; // scope 0 at $DIR/issue-73223.rs:+1:17: +1:30
59 }
60
61 bb1: {
62 nop; // scope 0 at $DIR/issue-73223.rs:+3:17: +3:23
63 StorageDead(_2); // scope 0 at $DIR/issue-73223.rs:+4:6: +4:7
64 StorageDead(_1); // scope 0 at $DIR/issue-73223.rs:+8:1: +8:2
65 return; // scope 0 at $DIR/issue-73223.rs:+8:2: +8:2
66 }
67
68 bb2: {
69 unreachable; // scope 0 at $DIR/issue-73223.rs:+1:23: +1:30
70 }
71
72 bb3: {
73 StorageLive(_4); // scope 0 at $DIR/issue-73223.rs:+2:14: +2:15
74 _4 = ((_2 as Some).0: i32); // scope 0 at $DIR/issue-73223.rs:+2:14: +2:15
75 _1 = _4; // scope 2 at $DIR/issue-73223.rs:+2:20: +2:21
76 StorageDead(_4); // scope 0 at $DIR/issue-73223.rs:+2:20: +2:21
77 StorageDead(_2); // scope 0 at $DIR/issue-73223.rs:+4:6: +4:7
78 StorageLive(_6); // scope 1 at $DIR/issue-73223.rs:+6:9: +6:14
79 StorageLive(_7); // scope 1 at $DIR/issue-73223.rs:+6:22: +6:27
80 _7 = _1; // scope 1 at $DIR/issue-73223.rs:+6:22: +6:27
81 Deinit(_6); // scope 1 at $DIR/issue-73223.rs:+6:17: +6:28
82 ((_6 as Some).0: i32) = move _7; // scope 1 at $DIR/issue-73223.rs:+6:17: +6:28
83 discriminant(_6) = 1; // scope 1 at $DIR/issue-73223.rs:+6:17: +6:28
84 StorageDead(_7); // scope 1 at $DIR/issue-73223.rs:+6:27: +6:28
85 StorageLive(_8); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
86 StorageLive(_9); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
87 StorageLive(_10); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
88 _10 = &_1; // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
89 StorageLive(_11); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
90 _28 = const _; // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
91 // mir::Constant
92 // + span: $SRC_DIR/core/src/macros/mod.rs:LL:COL
93 // + literal: Const { ty: &i32, val: Unevaluated(main, [], Some(promoted[0])) }
94 _11 = _28; // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
95 Deinit(_9); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
96 (_9.0: &i32) = move _10; // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
97 (_9.1: &i32) = move _11; // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
98 StorageDead(_11); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
99 StorageDead(_10); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
100 StorageLive(_13); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
101 _13 = (_9.0: &i32); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
102 StorageLive(_14); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
103 _14 = (_9.1: &i32); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
104 StorageLive(_15); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
105 StorageLive(_16); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
106 StorageLive(_17); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
107 _17 = (*_13); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
108 StorageLive(_18); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
109 _18 = const 1_i32; // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
110 _16 = Eq(move _17, const 1_i32); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
111 StorageDead(_18); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
112 StorageDead(_17); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
113 _15 = Not(move _16); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
114 StorageDead(_16); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
115 switchInt(move _15) -> [false: bb5, otherwise: bb4]; // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
116 }
117
118 bb4: {
119 StorageLive(_20); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
120 Deinit(_20); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
121 discriminant(_20) = 0; // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
122 StorageLive(_21); // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
123 StorageLive(_22); // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
124 _22 = const core::panicking::AssertKind::Eq; // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
125 // mir::Constant
126 // + span: $SRC_DIR/core/src/macros/mod.rs:LL:COL
127 // + literal: Const { ty: core::panicking::AssertKind, val: Value(Scalar(0x00)) }
128 StorageLive(_23); // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
129 StorageLive(_24); // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
130 _24 = _13; // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
131 _23 = _24; // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
132 StorageLive(_25); // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
133 StorageLive(_26); // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
134 _26 = _14; // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
135 _25 = _26; // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
136 StorageLive(_27); // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
137 Deinit(_27); // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
138 discriminant(_27) = 0; // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
139 _21 = core::panicking::assert_failed::<i32, i32>(const core::panicking::AssertKind::Eq, move _23, move _25, move _27); // scope 5 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
140 // mir::Constant
141 // + span: $SRC_DIR/core/src/macros/mod.rs:LL:COL
142 // + literal: Const { ty: for<'a, 'b, 'c> fn(core::panicking::AssertKind, &'a i32, &'b i32, Option<Arguments<'c>>) -> ! {core::panicking::assert_failed::<i32, i32>}, val: Value(<ZST>) }
143 // mir::Constant
144 // + span: $SRC_DIR/core/src/macros/mod.rs:LL:COL
145 // + literal: Const { ty: core::panicking::AssertKind, val: Value(Scalar(0x00)) }
146 }
147
148 bb5: {
149 nop; // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
150 StorageDead(_15); // scope 4 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
151 StorageDead(_14); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
152 StorageDead(_13); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
153 StorageDead(_9); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
154 StorageDead(_8); // scope 3 at $SRC_DIR/core/src/macros/mod.rs:LL:COL
155 nop; // scope 0 at $DIR/issue-73223.rs:+0:11: +8:2
156 StorageDead(_6); // scope 1 at $DIR/issue-73223.rs:+8:1: +8:2
157 StorageDead(_1); // scope 0 at $DIR/issue-73223.rs:+8:1: +8:2
158 return; // scope 0 at $DIR/issue-73223.rs:+8:2: +8:2
159 }
160 }
161