rustc_codegen_ssa: use `debug_introduce_local` on Operand call results.
This commit is contained in:
parent
6dff769e37
commit
ef63e88a9d
|
@ -1145,6 +1145,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
|
|||
let op = bx.load_operand(place);
|
||||
place.storage_dead(bx);
|
||||
self.locals[index] = LocalRef::Operand(Some(op));
|
||||
self.debug_introduce_local(bx, index);
|
||||
}
|
||||
LocalRef::Operand(Some(op)) => {
|
||||
assert!(op.layout.is_zst(), "assigning to initialized SSAtemp");
|
||||
|
@ -1186,6 +1187,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
|
|||
let op = bx.load_operand(tmp);
|
||||
tmp.storage_dead(bx);
|
||||
self.locals[index] = LocalRef::Operand(Some(op));
|
||||
self.debug_introduce_local(bx, index);
|
||||
}
|
||||
DirectOperand(index) => {
|
||||
// If there is a cast, we have to store and reload.
|
||||
|
@ -1200,6 +1202,7 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
|
|||
OperandRef::from_immediate_or_packed_pair(bx, llval, ret_abi.layout)
|
||||
};
|
||||
self.locals[index] = LocalRef::Operand(Some(op));
|
||||
self.debug_introduce_local(bx, index);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
// ignore-tidy-linelength
|
||||
|
||||
// compile-flags: -C no-prepopulate-passes
|
||||
|
||||
#![crate_type = "lib"]
|
||||
|
@ -61,19 +59,19 @@ pub fn naked_recursive() {
|
|||
|
||||
naked_empty();
|
||||
|
||||
// CHECK-NEXT: %{{[0-9]+}} = call i{{[0-9]+}} @naked_with_return()
|
||||
// CHECK-NEXT: %_4 = call i{{[0-9]+}} @naked_with_return()
|
||||
|
||||
// FIXME(#39685) Avoid one block per call.
|
||||
// CHECK-NEXT: br label %bb2
|
||||
// CHECK: bb2:
|
||||
|
||||
// CHECK-NEXT: %{{[0-9]+}} = call i{{[0-9]+}} @naked_with_args_and_return(i{{[0-9]+}} %{{[0-9]+}})
|
||||
// CHECK-NEXT: %_3 = call i{{[0-9]+}} @naked_with_args_and_return(i{{[0-9]+}} %_4)
|
||||
|
||||
// FIXME(#39685) Avoid one block per call.
|
||||
// CHECK-NEXT: br label %bb3
|
||||
// CHECK: bb3:
|
||||
|
||||
// CHECK-NEXT: call void @naked_with_args(i{{[0-9]+}} %{{[0-9]+}})
|
||||
// CHECK-NEXT: call void @naked_with_args(i{{[0-9]+}} %_3)
|
||||
|
||||
// FIXME(#39685) Avoid one block per call.
|
||||
// CHECK-NEXT: br label %bb4
|
||||
|
|
Loading…
Reference in New Issue