Skip to content

Commit c4c4c56

Browse files
committed
Replace mir_map.0 dump with built phase change dump
1 parent 36285c5 commit c4c4c56

File tree

52 files changed

+136
-112
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+136
-112
lines changed

compiler/rustc_mir_transform/src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -288,7 +288,7 @@ fn mir_const<'tcx>(
288288

289289
let mut body = tcx.mir_built(def).steal();
290290

291-
rustc_middle::mir::dump_mir(tcx, None, "mir_map", &0, &body, |_, _| Ok(()));
291+
pass_manager::dump_mir_for_phase_change(tcx, &body);
292292

293293
pm::run_passes(
294294
tcx,

compiler/rustc_mir_transform/src/shim.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -845,7 +845,7 @@ pub fn build_adt_ctor(tcx: TyCtxt<'_>, ctor_id: DefId) -> Body<'_> {
845845
span,
846846
);
847847

848-
rustc_middle::mir::dump_mir(tcx, None, "mir_map", &0, &body, |_, _| Ok(()));
848+
crate::pass_manager::dump_mir_for_phase_change(tcx, &body);
849849

850850
body
851851
}

src/test/mir-opt/match_false_edges.full_tested_match.PromoteTemps.after.mir renamed to src/test/mir-opt/building/match_false_edges.full_tested_match.built.after.mir

+14-15
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// MIR for `full_tested_match` after PromoteTemps
1+
// MIR for `full_tested_match` after built
22

33
fn full_tested_match() -> () {
44
let mut _0: (); // return place in scope 0 at $DIR/match_false_edges.rs:+0:28: +0:28
@@ -12,7 +12,6 @@ fn full_tested_match() -> () {
1212
let mut _8: i32; // in scope 0 at $DIR/match_false_edges.rs:+2:35: +2:36
1313
let _9: i32; // in scope 0 at $DIR/match_false_edges.rs:+3:14: +3:15
1414
let mut _10: i32; // in scope 0 at $DIR/match_false_edges.rs:+3:24: +3:25
15-
let mut _11: &std::option::Option<i32>; // in scope 0 at $DIR/match_false_edges.rs:+2:14: +2:15
1615
scope 1 {
1716
}
1817
scope 2 {
@@ -34,15 +33,15 @@ fn full_tested_match() -> () {
3433

3534
bb1: {
3635
_1 = (const 3_i32, const 3_i32); // scope 0 at $DIR/match_false_edges.rs:+4:17: +4:23
37-
goto -> bb10; // scope 0 at $DIR/match_false_edges.rs:+4:17: +4:23
36+
goto -> bb11; // scope 0 at $DIR/match_false_edges.rs:+4:17: +4:23
3837
}
3938

4039
bb2: {
4140
falseEdge -> [real: bb5, imaginary: bb3]; // scope 0 at $DIR/match_false_edges.rs:+2:9: +2:16
4241
}
4342

4443
bb3: {
45-
falseEdge -> [real: bb9, imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:16
44+
falseEdge -> [real: bb10, imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:16
4645
}
4746

4847
bb4: {
@@ -51,14 +50,10 @@ fn full_tested_match() -> () {
5150

5251
bb5: {
5352
StorageLive(_6); // scope 0 at $DIR/match_false_edges.rs:+2:14: +2:15
54-
_11 = const _; // scope 0 at $DIR/match_false_edges.rs:+2:14: +2:15
55-
// mir::Constant
56-
// + span: $DIR/match_false_edges.rs:14:14: 14:15
57-
// + literal: Const { ty: &Option<i32>, val: Unevaluated(full_tested_match, [], Some(promoted[0])) }
58-
_6 = &(((*_11) as Some).0: i32); // scope 0 at $DIR/match_false_edges.rs:+2:14: +2:15
53+
_6 = &((_2 as Some).0: i32); // scope 0 at $DIR/match_false_edges.rs:+2:14: +2:15
5954
_4 = &shallow _2; // scope 0 at $DIR/match_false_edges.rs:+1:19: +1:27
6055
StorageLive(_7); // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
61-
_7 = guard() -> [return: bb6, unwind: bb11]; // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
56+
_7 = guard() -> [return: bb6, unwind: bb12]; // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
6257
// mir::Constant
6358
// + span: $DIR/match_false_edges.rs:14:20: 14:25
6459
// + literal: Const { ty: fn() -> bool {guard}, val: Value(<ZST>) }
@@ -80,34 +75,38 @@ fn full_tested_match() -> () {
8075
StorageDead(_8); // scope 2 at $DIR/match_false_edges.rs:+2:36: +2:37
8176
StorageDead(_5); // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
8277
StorageDead(_6); // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
83-
goto -> bb10; // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
78+
goto -> bb11; // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
8479
}
8580

8681
bb8: {
82+
goto -> bb9; // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
83+
}
84+
85+
bb9: {
8786
StorageDead(_7); // scope 0 at $DIR/match_false_edges.rs:+2:26: +2:27
8887
StorageDead(_6); // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
8988
goto -> bb3; // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
9089
}
9190

92-
bb9: {
91+
bb10: {
9392
StorageLive(_9); // scope 0 at $DIR/match_false_edges.rs:+3:14: +3:15
9493
_9 = ((_2 as Some).0: i32); // scope 0 at $DIR/match_false_edges.rs:+3:14: +3:15
9594
StorageLive(_10); // scope 3 at $DIR/match_false_edges.rs:+3:24: +3:25
9695
_10 = _9; // scope 3 at $DIR/match_false_edges.rs:+3:24: +3:25
9796
_1 = (const 2_i32, move _10); // scope 3 at $DIR/match_false_edges.rs:+3:20: +3:26
9897
StorageDead(_10); // scope 3 at $DIR/match_false_edges.rs:+3:25: +3:26
9998
StorageDead(_9); // scope 0 at $DIR/match_false_edges.rs:+3:25: +3:26
100-
goto -> bb10; // scope 0 at $DIR/match_false_edges.rs:+3:25: +3:26
99+
goto -> bb11; // scope 0 at $DIR/match_false_edges.rs:+3:25: +3:26
101100
}
102101

103-
bb10: {
102+
bb11: {
104103
StorageDead(_2); // scope 0 at $DIR/match_false_edges.rs:+5:6: +5:7
105104
StorageDead(_1); // scope 0 at $DIR/match_false_edges.rs:+5:6: +5:7
106105
_0 = const (); // scope 0 at $DIR/match_false_edges.rs:+0:28: +6:2
107106
return; // scope 0 at $DIR/match_false_edges.rs:+6:2: +6:2
108107
}
109108

110-
bb11 (cleanup): {
109+
bb12 (cleanup): {
111110
resume; // scope 0 at $DIR/match_false_edges.rs:+0:1: +6:2
112111
}
113112
}

src/test/mir-opt/match_false_edges.full_tested_match2.PromoteTemps.before.mir renamed to src/test/mir-opt/building/match_false_edges.full_tested_match2.built.after.mir

+13-9
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// MIR for `full_tested_match2` before PromoteTemps
1+
// MIR for `full_tested_match2` after built
22

33
fn full_tested_match2() -> () {
44
let mut _0: (); // return place in scope 0 at $DIR/match_false_edges.rs:+0:29: +0:29
@@ -32,7 +32,7 @@ fn full_tested_match2() -> () {
3232
}
3333

3434
bb1: {
35-
falseEdge -> [real: bb9, imaginary: bb3]; // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:13
35+
falseEdge -> [real: bb10, imaginary: bb3]; // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:13
3636
}
3737

3838
bb2: {
@@ -47,7 +47,7 @@ fn full_tested_match2() -> () {
4747
_1 = (const 2_i32, move _10); // scope 3 at $DIR/match_false_edges.rs:+4:20: +4:26
4848
StorageDead(_10); // scope 3 at $DIR/match_false_edges.rs:+4:25: +4:26
4949
StorageDead(_9); // scope 0 at $DIR/match_false_edges.rs:+4:25: +4:26
50-
goto -> bb10; // scope 0 at $DIR/match_false_edges.rs:+4:25: +4:26
50+
goto -> bb11; // scope 0 at $DIR/match_false_edges.rs:+4:25: +4:26
5151
}
5252

5353
bb4: {
@@ -59,7 +59,7 @@ fn full_tested_match2() -> () {
5959
_6 = &((_2 as Some).0: i32); // scope 0 at $DIR/match_false_edges.rs:+2:14: +2:15
6060
_4 = &shallow _2; // scope 0 at $DIR/match_false_edges.rs:+1:19: +1:27
6161
StorageLive(_7); // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
62-
_7 = guard() -> [return: bb6, unwind: bb11]; // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
62+
_7 = guard() -> [return: bb6, unwind: bb12]; // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
6363
// mir::Constant
6464
// + span: $DIR/match_false_edges.rs:25:20: 25:25
6565
// + literal: Const { ty: fn() -> bool {guard}, val: Value(<ZST>) }
@@ -81,28 +81,32 @@ fn full_tested_match2() -> () {
8181
StorageDead(_8); // scope 2 at $DIR/match_false_edges.rs:+2:36: +2:37
8282
StorageDead(_5); // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
8383
StorageDead(_6); // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
84-
goto -> bb10; // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
84+
goto -> bb11; // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
8585
}
8686

8787
bb8: {
88+
goto -> bb9; // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
89+
}
90+
91+
bb9: {
8892
StorageDead(_7); // scope 0 at $DIR/match_false_edges.rs:+2:26: +2:27
8993
StorageDead(_6); // scope 0 at $DIR/match_false_edges.rs:+2:36: +2:37
9094
falseEdge -> [real: bb3, imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+2:20: +2:27
9195
}
9296

93-
bb9: {
97+
bb10: {
9498
_1 = (const 3_i32, const 3_i32); // scope 0 at $DIR/match_false_edges.rs:+3:17: +3:23
95-
goto -> bb10; // scope 0 at $DIR/match_false_edges.rs:+3:17: +3:23
99+
goto -> bb11; // scope 0 at $DIR/match_false_edges.rs:+3:17: +3:23
96100
}
97101

98-
bb10: {
102+
bb11: {
99103
StorageDead(_2); // scope 0 at $DIR/match_false_edges.rs:+5:6: +5:7
100104
StorageDead(_1); // scope 0 at $DIR/match_false_edges.rs:+5:6: +5:7
101105
_0 = const (); // scope 0 at $DIR/match_false_edges.rs:+0:29: +6:2
102106
return; // scope 0 at $DIR/match_false_edges.rs:+6:2: +6:2
103107
}
104108

105-
bb11 (cleanup): {
109+
bb12 (cleanup): {
106110
resume; // scope 0 at $DIR/match_false_edges.rs:+0:1: +6:2
107111
}
108112
}

src/test/mir-opt/match_false_edges.main.PromoteTemps.before.mir renamed to src/test/mir-opt/building/match_false_edges.main.built.after.mir

+47-26
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// MIR for `main` before PromoteTemps
1+
// MIR for `main` after built
22

33
fn main() -> () {
44
let mut _0: (); // return place in scope 0 at $DIR/match_false_edges.rs:+0:11: +0:11
@@ -43,41 +43,54 @@ fn main() -> () {
4343
}
4444

4545
bb1: {
46-
falseEdge -> [real: bb9, imaginary: bb4]; // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:11
46+
falseEdge -> [real: bb13, imaginary: bb6]; // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:11
4747
}
4848

4949
bb2: {
50-
falseEdge -> [real: bb5, imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+2:9: +2:17
50+
falseEdge -> [real: bb8, imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+2:9: +2:17
5151
}
5252

5353
bb3: {
54+
goto -> bb1; // scope 0 at $DIR/match_false_edges.rs:+1:13: +1:26
55+
}
56+
57+
bb4: {
58+
_3 = discriminant(_2); // scope 0 at $DIR/match_false_edges.rs:+1:19: +1:26
59+
switchInt(move _3) -> [1_isize: bb6, otherwise: bb5]; // scope 0 at $DIR/match_false_edges.rs:+1:13: +1:26
60+
}
61+
62+
bb5: {
5463
StorageLive(_14); // scope 0 at $DIR/match_false_edges.rs:+5:9: +5:11
5564
_14 = _2; // scope 0 at $DIR/match_false_edges.rs:+5:9: +5:11
5665
_1 = const 4_i32; // scope 5 at $DIR/match_false_edges.rs:+5:15: +5:16
5766
StorageDead(_14); // scope 0 at $DIR/match_false_edges.rs:+5:15: +5:16
58-
goto -> bb14; // scope 0 at $DIR/match_false_edges.rs:+5:15: +5:16
67+
goto -> bb19; // scope 0 at $DIR/match_false_edges.rs:+5:15: +5:16
5968
}
6069

61-
bb4: {
62-
falseEdge -> [real: bb10, imaginary: bb3]; // scope 0 at $DIR/match_false_edges.rs:+4:9: +4:16
70+
bb6: {
71+
falseEdge -> [real: bb14, imaginary: bb5]; // scope 0 at $DIR/match_false_edges.rs:+4:9: +4:16
6372
}
6473

65-
bb5: {
74+
bb7: {
75+
goto -> bb5; // scope 0 at $DIR/match_false_edges.rs:+1:13: +1:26
76+
}
77+
78+
bb8: {
6679
StorageLive(_7); // scope 0 at $DIR/match_false_edges.rs:+2:14: +2:16
6780
_7 = &((_2 as Some).0: i32); // scope 0 at $DIR/match_false_edges.rs:+2:14: +2:16
6881
_5 = &shallow _2; // scope 0 at $DIR/match_false_edges.rs:+1:19: +1:26
6982
StorageLive(_8); // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
70-
_8 = guard() -> [return: bb6, unwind: bb15]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
83+
_8 = guard() -> [return: bb9, unwind: bb20]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
7184
// mir::Constant
7285
// + span: $DIR/match_false_edges.rs:34:21: 34:26
7386
// + literal: Const { ty: fn() -> bool {guard}, val: Value(<ZST>) }
7487
}
7588

76-
bb6: {
77-
switchInt(move _8) -> [false: bb8, otherwise: bb7]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
89+
bb9: {
90+
switchInt(move _8) -> [false: bb11, otherwise: bb10]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
7891
}
7992

80-
bb7: {
93+
bb10: {
8194
StorageDead(_8); // scope 0 at $DIR/match_false_edges.rs:+2:27: +2:28
8295
FakeRead(ForMatchGuard, _5); // scope 0 at $DIR/match_false_edges.rs:+2:27: +2:28
8396
FakeRead(ForGuardBinding, _7); // scope 0 at $DIR/match_false_edges.rs:+2:27: +2:28
@@ -86,41 +99,45 @@ fn main() -> () {
8699
_1 = const 1_i32; // scope 2 at $DIR/match_false_edges.rs:+2:32: +2:33
87100
StorageDead(_6); // scope 0 at $DIR/match_false_edges.rs:+2:32: +2:33
88101
StorageDead(_7); // scope 0 at $DIR/match_false_edges.rs:+2:32: +2:33
89-
goto -> bb14; // scope 0 at $DIR/match_false_edges.rs:+2:32: +2:33
102+
goto -> bb19; // scope 0 at $DIR/match_false_edges.rs:+2:32: +2:33
90103
}
91104

92-
bb8: {
105+
bb11: {
106+
goto -> bb12; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
107+
}
108+
109+
bb12: {
93110
StorageDead(_8); // scope 0 at $DIR/match_false_edges.rs:+2:27: +2:28
94111
StorageDead(_7); // scope 0 at $DIR/match_false_edges.rs:+2:32: +2:33
95-
falseEdge -> [real: bb1, imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
112+
falseEdge -> [real: bb3, imaginary: bb1]; // scope 0 at $DIR/match_false_edges.rs:+2:21: +2:28
96113
}
97114

98-
bb9: {
115+
bb13: {
99116
StorageLive(_9); // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:11
100117
_9 = _2; // scope 0 at $DIR/match_false_edges.rs:+3:9: +3:11
101118
_1 = const 2_i32; // scope 3 at $DIR/match_false_edges.rs:+3:15: +3:16
102119
StorageDead(_9); // scope 0 at $DIR/match_false_edges.rs:+3:15: +3:16
103-
goto -> bb14; // scope 0 at $DIR/match_false_edges.rs:+3:15: +3:16
120+
goto -> bb19; // scope 0 at $DIR/match_false_edges.rs:+3:15: +3:16
104121
}
105122

106-
bb10: {
123+
bb14: {
107124
StorageLive(_11); // scope 0 at $DIR/match_false_edges.rs:+4:14: +4:15
108125
_11 = &((_2 as Some).0: i32); // scope 0 at $DIR/match_false_edges.rs:+4:14: +4:15
109126
_5 = &shallow _2; // scope 0 at $DIR/match_false_edges.rs:+1:19: +1:26
110127
StorageLive(_12); // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
111128
StorageLive(_13); // scope 0 at $DIR/match_false_edges.rs:+4:27: +4:28
112129
_13 = (*_11); // scope 0 at $DIR/match_false_edges.rs:+4:27: +4:28
113-
_12 = guard2(move _13) -> [return: bb11, unwind: bb15]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
130+
_12 = guard2(move _13) -> [return: bb15, unwind: bb20]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
114131
// mir::Constant
115132
// + span: $DIR/match_false_edges.rs:36:20: 36:26
116133
// + literal: Const { ty: fn(i32) -> bool {guard2}, val: Value(<ZST>) }
117134
}
118135

119-
bb11: {
120-
switchInt(move _12) -> [false: bb13, otherwise: bb12]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
136+
bb15: {
137+
switchInt(move _12) -> [false: bb17, otherwise: bb16]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
121138
}
122139

123-
bb12: {
140+
bb16: {
124141
StorageDead(_13); // scope 0 at $DIR/match_false_edges.rs:+4:28: +4:29
125142
StorageDead(_12); // scope 0 at $DIR/match_false_edges.rs:+4:28: +4:29
126143
FakeRead(ForMatchGuard, _5); // scope 0 at $DIR/match_false_edges.rs:+4:28: +4:29
@@ -130,24 +147,28 @@ fn main() -> () {
130147
_1 = const 3_i32; // scope 4 at $DIR/match_false_edges.rs:+4:33: +4:34
131148
StorageDead(_10); // scope 0 at $DIR/match_false_edges.rs:+4:33: +4:34
132149
StorageDead(_11); // scope 0 at $DIR/match_false_edges.rs:+4:33: +4:34
133-
goto -> bb14; // scope 0 at $DIR/match_false_edges.rs:+4:33: +4:34
150+
goto -> bb19; // scope 0 at $DIR/match_false_edges.rs:+4:33: +4:34
134151
}
135152

136-
bb13: {
153+
bb17: {
154+
goto -> bb18; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
155+
}
156+
157+
bb18: {
137158
StorageDead(_13); // scope 0 at $DIR/match_false_edges.rs:+4:28: +4:29
138159
StorageDead(_12); // scope 0 at $DIR/match_false_edges.rs:+4:28: +4:29
139160
StorageDead(_11); // scope 0 at $DIR/match_false_edges.rs:+4:33: +4:34
140-
falseEdge -> [real: bb3, imaginary: bb3]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
161+
falseEdge -> [real: bb7, imaginary: bb5]; // scope 0 at $DIR/match_false_edges.rs:+4:20: +4:29
141162
}
142163

143-
bb14: {
164+
bb19: {
144165
StorageDead(_2); // scope 0 at $DIR/match_false_edges.rs:+6:6: +6:7
145166
StorageDead(_1); // scope 0 at $DIR/match_false_edges.rs:+6:6: +6:7
146167
_0 = const (); // scope 0 at $DIR/match_false_edges.rs:+0:11: +7:2
147168
return; // scope 0 at $DIR/match_false_edges.rs:+7:2: +7:2
148169
}
149170

150-
bb15 (cleanup): {
171+
bb20 (cleanup): {
151172
resume; // scope 0 at $DIR/match_false_edges.rs:+0:1: +7:2
152173
}
153174
}

src/test/mir-opt/match_false_edges.rs renamed to src/test/mir-opt/building/match_false_edges.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ fn guard2(_: i32) -> bool {
88

99
// no_mangle to make sure this gets instantiated even in an executable.
1010
#[no_mangle]
11-
// EMIT_MIR match_false_edges.full_tested_match.PromoteTemps.after.mir
11+
// EMIT_MIR match_false_edges.full_tested_match.built.after.mir
1212
pub fn full_tested_match() {
1313
let _ = match Some(42) {
1414
Some(x) if guard() => (1, x),
@@ -19,7 +19,7 @@ pub fn full_tested_match() {
1919

2020
// no_mangle to make sure this gets instantiated even in an executable.
2121
#[no_mangle]
22-
// EMIT_MIR match_false_edges.full_tested_match2.PromoteTemps.before.mir
22+
// EMIT_MIR match_false_edges.full_tested_match2.built.after.mir
2323
pub fn full_tested_match2() {
2424
let _ = match Some(42) {
2525
Some(x) if guard() => (1, x),
@@ -28,7 +28,7 @@ pub fn full_tested_match2() {
2828
};
2929
}
3030

31-
// EMIT_MIR match_false_edges.main.PromoteTemps.before.mir
31+
// EMIT_MIR match_false_edges.main.built.after.mir
3232
fn main() {
3333
let _ = match Some(1) {
3434
Some(_w) if guard() => 1,

src/test/mir-opt/const-promotion-extern-static.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ static mut BAR: *const &i32 = [&Y].as_ptr();
1212
// EMIT_MIR const_promotion_extern_static.FOO-promoted[0].SimplifyCfg-elaborate-drops.after.mir
1313
static mut FOO: *const &i32 = [unsafe { &X }].as_ptr();
1414

15-
// EMIT_MIR const_promotion_extern_static.BOP.mir_map.0.mir
15+
// EMIT_MIR const_promotion_extern_static.BOP.built.after.mir
1616
static BOP: &i32 = &13;
1717

1818
fn main() {}

src/test/mir-opt/const_promotion_extern_static.BOP.mir_map.0.mir renamed to src/test/mir-opt/const_promotion_extern_static.BOP.built.after.mir

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// MIR for `BOP` 0 mir_map
1+
// MIR for `BOP` after built
22

33
static BOP: &i32 = {
44
let mut _0: &i32; // return place in scope 0 at $DIR/const-promotion-extern-static.rs:+0:13: +0:17

src/test/mir-opt/enum_cast.bar.mir_map.0.mir renamed to src/test/mir-opt/enum_cast.bar.built.after.mir

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// MIR for `bar` 0 mir_map
1+
// MIR for `bar` after built
22

33
fn bar(_1: Bar) -> usize {
44
debug bar => _1; // in scope 0 at $DIR/enum_cast.rs:+0:8: +0:11

src/test/mir-opt/enum_cast.boo.mir_map.0.mir renamed to src/test/mir-opt/enum_cast.boo.built.after.mir

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// MIR for `boo` 0 mir_map
1+
// MIR for `boo` after built
22

33
fn boo(_1: Boo) -> usize {
44
debug boo => _1; // in scope 0 at $DIR/enum_cast.rs:+0:8: +0:11

0 commit comments

Comments
 (0)