diff options
| author | bors <bors@rust-lang.org> | 2020-02-11 07:36:59 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2020-02-11 07:36:59 +0000 |
| commit | b6690a8c35e9afa3e0f65140cc69d4ba1b9e78c4 (patch) | |
| tree | 038abc30010b3400090a949e420260c92428fb92 /src/test/codegen | |
| parent | dc4242d9052a42cdf329c3a2430d02a3b3d415cb (diff) | |
| parent | 1a8f5efab8ccd9d5f6ac794ab1bcf90b5efa536a (diff) | |
| download | rust-b6690a8c35e9afa3e0f65140cc69d4ba1b9e78c4.tar.gz rust-b6690a8c35e9afa3e0f65140cc69d4ba1b9e78c4.zip | |
Auto merge of #68961 - eddyb:dbg-stack-dunk, r=nagisa
rustc_codegen_ssa: only "spill" SSA-like values to the stack for debuginfo. This is an implementation of the idea described in https://github.com/rust-lang/rust/issues/68817#issuecomment-583719182. In short, instead of debuginfo forcing otherwise-SSA-like MIR locals into `alloca`s, and requiring a `load` for each use (or two, for scalar pairs), the `alloca` is now *only* used for attaching debuginfo with `llvm.dbg.declare`: the `OperandRef` is stored to the `alloca`, but *never loaded* from it. Outside of `debug_introduce_local`, nothing cares about the debuginfo-only `alloca`, and instead works with `OperandRef` the same as MIR locals without debuginfo before this PR. This should have some of the benefits of `llvm.dbg.value`, while working today. cc @nagisa @nikomatsakis
Diffstat (limited to 'src/test/codegen')
| -rw-r--r-- | src/test/codegen/naked-functions.rs | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/test/codegen/naked-functions.rs b/src/test/codegen/naked-functions.rs index 5050ed14994..493c1b9f0ba 100644 --- a/src/test/codegen/naked-functions.rs +++ b/src/test/codegen/naked-functions.rs @@ -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 |
