diff options
Diffstat (limited to 'tests/mir-opt/sroa/structs.ref_copies.ScalarReplacementOfAggregates.diff')
-rw-r--r-- | tests/mir-opt/sroa/structs.ref_copies.ScalarReplacementOfAggregates.diff | 82 |
1 files changed, 41 insertions, 41 deletions
diff --git a/tests/mir-opt/sroa/structs.ref_copies.ScalarReplacementOfAggregates.diff b/tests/mir-opt/sroa/structs.ref_copies.ScalarReplacementOfAggregates.diff index 7b09ac182..d7c57c293 100644 --- a/tests/mir-opt/sroa/structs.ref_copies.ScalarReplacementOfAggregates.diff +++ b/tests/mir-opt/sroa/structs.ref_copies.ScalarReplacementOfAggregates.diff @@ -2,55 +2,55 @@ + // MIR for `ref_copies` after ScalarReplacementOfAggregates fn ref_copies(_1: &Foo) -> () { - debug x => _1; // in scope 0 at $DIR/structs.rs:+0:15: +0:16 - let mut _0: (); // return place in scope 0 at $DIR/structs.rs:+0:24: +0:24 - let _2: Foo; // in scope 0 at $DIR/structs.rs:+1:9: +1:10 -+ let _5: u8; // in scope 0 at $DIR/structs.rs:+1:9: +1:10 -+ let _6: (); // in scope 0 at $DIR/structs.rs:+1:9: +1:10 -+ let _7: &str; // in scope 0 at $DIR/structs.rs:+1:9: +1:10 -+ let _8: std::option::Option<isize>; // in scope 0 at $DIR/structs.rs:+1:9: +1:10 + debug x => _1; + let mut _0: (); + let _2: Foo; ++ let _5: u8; ++ let _6: (); ++ let _7: &str; ++ let _8: std::option::Option<isize>; scope 1 { -- debug y => _2; // in scope 1 at $DIR/structs.rs:+1:9: +1:10 -+ debug y => Foo{ .0 => _5, .1 => _6, .2 => _7, .3 => _8, }; // in scope 1 at $DIR/structs.rs:+1:9: +1:10 - let _3: u8; // in scope 1 at $DIR/structs.rs:+2:9: +2:10 +- debug y => _2; ++ debug y => Foo{ .0 => _5, .1 => _6, .2 => _7, .3 => _8, }; + let _3: u8; scope 2 { - debug t => _3; // in scope 2 at $DIR/structs.rs:+2:9: +2:10 - let _4: &str; // in scope 2 at $DIR/structs.rs:+3:9: +3:10 + debug t => _3; + let _4: &str; scope 3 { - debug u => _4; // in scope 3 at $DIR/structs.rs:+3:9: +3:10 + debug u => _4; } } } bb0: { -- StorageLive(_2); // scope 0 at $DIR/structs.rs:+1:9: +1:10 -- _2 = (*_1); // scope 0 at $DIR/structs.rs:+1:13: +1:15 -+ StorageLive(_5); // scope 0 at $DIR/structs.rs:+1:9: +1:10 -+ StorageLive(_6); // scope 0 at $DIR/structs.rs:+1:9: +1:10 -+ StorageLive(_7); // scope 0 at $DIR/structs.rs:+1:9: +1:10 -+ StorageLive(_8); // scope 0 at $DIR/structs.rs:+1:9: +1:10 -+ nop; // scope 0 at $DIR/structs.rs:+1:9: +1:10 -+ _5 = ((*_1).0: u8); // scope 0 at $DIR/structs.rs:+1:13: +1:15 -+ _6 = ((*_1).1: ()); // scope 0 at $DIR/structs.rs:+1:13: +1:15 -+ _7 = ((*_1).2: &str); // scope 0 at $DIR/structs.rs:+1:13: +1:15 -+ _8 = ((*_1).3: std::option::Option<isize>); // scope 0 at $DIR/structs.rs:+1:13: +1:15 -+ nop; // scope 0 at $DIR/structs.rs:+1:13: +1:15 - StorageLive(_3); // scope 1 at $DIR/structs.rs:+2:9: +2:10 -- _3 = (_2.0: u8); // scope 1 at $DIR/structs.rs:+2:13: +2:16 -+ _3 = _5; // scope 1 at $DIR/structs.rs:+2:13: +2:16 - StorageLive(_4); // scope 2 at $DIR/structs.rs:+3:9: +3:10 -- _4 = (_2.2: &str); // scope 2 at $DIR/structs.rs:+3:13: +3:16 -+ _4 = _7; // scope 2 at $DIR/structs.rs:+3:13: +3:16 - _0 = const (); // scope 0 at $DIR/structs.rs:+0:24: +4:2 - StorageDead(_4); // scope 2 at $DIR/structs.rs:+4:1: +4:2 - StorageDead(_3); // scope 1 at $DIR/structs.rs:+4:1: +4:2 -- StorageDead(_2); // scope 0 at $DIR/structs.rs:+4:1: +4:2 -+ StorageDead(_5); // scope 0 at $DIR/structs.rs:+4:1: +4:2 -+ StorageDead(_6); // scope 0 at $DIR/structs.rs:+4:1: +4:2 -+ StorageDead(_7); // scope 0 at $DIR/structs.rs:+4:1: +4:2 -+ StorageDead(_8); // scope 0 at $DIR/structs.rs:+4:1: +4:2 -+ nop; // scope 0 at $DIR/structs.rs:+4:1: +4:2 - return; // scope 0 at $DIR/structs.rs:+4:2: +4:2 +- StorageLive(_2); +- _2 = (*_1); ++ StorageLive(_5); ++ StorageLive(_6); ++ StorageLive(_7); ++ StorageLive(_8); ++ nop; ++ _5 = ((*_1).0: u8); ++ _6 = ((*_1).1: ()); ++ _7 = ((*_1).2: &str); ++ _8 = ((*_1).3: std::option::Option<isize>); ++ nop; + StorageLive(_3); +- _3 = (_2.0: u8); ++ _3 = _5; + StorageLive(_4); +- _4 = (_2.2: &str); ++ _4 = _7; + _0 = const (); + StorageDead(_4); + StorageDead(_3); +- StorageDead(_2); ++ StorageDead(_5); ++ StorageDead(_6); ++ StorageDead(_7); ++ StorageDead(_8); ++ nop; + return; } } |