]> git.lizzy.rs Git - rust.git/blob - src/test/mir-opt/inst_combine_deref.simple_opt.InstCombine.diff
Rollup merge of #96603 - Alexendoo:const-generics-tests, r=Mark-Simulacrum
[rust.git] / src / test / mir-opt / inst_combine_deref.simple_opt.InstCombine.diff
1 - // MIR for `simple_opt` before InstCombine
2 + // MIR for `simple_opt` after InstCombine
3   
4   fn simple_opt() -> u64 {
5       let mut _0: u64;                     // return place in scope 0 at $DIR/inst_combine_deref.rs:3:20: 3:23
6       let _1: u64;                         // in scope 0 at $DIR/inst_combine_deref.rs:4:9: 4:10
7       scope 1 {
8           debug x => _1;                   // in scope 1 at $DIR/inst_combine_deref.rs:4:9: 4:10
9           let _2: &u64;                    // in scope 1 at $DIR/inst_combine_deref.rs:5:9: 5:10
10           scope 2 {
11               debug y => _2;               // in scope 2 at $DIR/inst_combine_deref.rs:5:9: 5:10
12               let _3: u64;                 // in scope 2 at $DIR/inst_combine_deref.rs:6:9: 6:10
13               scope 3 {
14                   debug z => _3;           // in scope 3 at $DIR/inst_combine_deref.rs:6:9: 6:10
15               }
16           }
17       }
18   
19       bb0: {
20           StorageLive(_1);                 // scope 0 at $DIR/inst_combine_deref.rs:4:9: 4:10
21           _1 = const 5_u64;                // scope 0 at $DIR/inst_combine_deref.rs:4:13: 4:14
22           StorageLive(_2);                 // scope 1 at $DIR/inst_combine_deref.rs:5:9: 5:10
23           _2 = &_1;                        // scope 1 at $DIR/inst_combine_deref.rs:5:13: 5:15
24           StorageLive(_3);                 // scope 2 at $DIR/inst_combine_deref.rs:6:9: 6:10
25 -         _3 = (*_2);                      // scope 2 at $DIR/inst_combine_deref.rs:6:13: 6:15
26 +         _3 = _1;                         // scope 2 at $DIR/inst_combine_deref.rs:6:13: 6:15
27           _0 = _3;                         // scope 3 at $DIR/inst_combine_deref.rs:7:5: 7:6
28           StorageDead(_3);                 // scope 2 at $DIR/inst_combine_deref.rs:8:1: 8:2
29           StorageDead(_2);                 // scope 1 at $DIR/inst_combine_deref.rs:8:1: 8:2
30           StorageDead(_1);                 // scope 0 at $DIR/inst_combine_deref.rs:8:1: 8:2
31           return;                          // scope 0 at $DIR/inst_combine_deref.rs:8:2: 8:2
32       }
33   }
34