rust/tests/mir-opt/gvn.borrowed.GVN.panic-unwind.diff
2024-08-18 16:07:33 -07:00

30 lines
690 B
Diff

- // MIR for `borrowed` before GVN
+ // MIR for `borrowed` after GVN
fn borrowed(_1: T) -> () {
let mut _0: ();
let mut _2: T;
let mut _3: &T;
bb0: {
_2 = copy _1;
_3 = &_1;
_0 = opaque::<&T>(copy _3) -> [return: bb1, unwind continue];
}
bb1: {
- _0 = opaque::<T>(copy _2) -> [return: bb2, unwind continue];
+ _0 = opaque::<T>(copy _1) -> [return: bb2, unwind continue];
}
bb2: {
- _0 = opaque::<T>(copy (*_3)) -> [return: bb3, unwind continue];
+ _0 = opaque::<T>(copy _1) -> [return: bb3, unwind continue];
}
bb3: {
return;
}
}