about summary refs log tree commit diff
path: root/tests/codegen/issues
diff options
context:
space:
mode:
authorTomasz Miąsko <tomasz.miasko@gmail.com>2025-03-14 10:48:02 +0100
committerTomasz Miąsko <tomasz.miasko@gmail.com>2025-05-17 09:49:03 +0200
commit3b7ca287a7ecb80185f2c679e663cd9c94cdc9f4 (patch)
treece9ebf422be0356564fe285b8fb2237ab52203c5 /tests/codegen/issues
parenta69bc17fb8026bdc0d24bb1896ff95f0eba1da4e (diff)
downloadrust-3b7ca287a7ecb80185f2c679e663cd9c94cdc9f4.tar.gz
rust-3b7ca287a7ecb80185f2c679e663cd9c94cdc9f4.zip
Describe lifetime of call argument temporaries passed indirectly
Diffstat (limited to 'tests/codegen/issues')
-rw-r--r--tests/codegen/issues/issue-98156-const-arg-temp-lifetime.rs27
1 files changed, 0 insertions, 27 deletions
diff --git a/tests/codegen/issues/issue-98156-const-arg-temp-lifetime.rs b/tests/codegen/issues/issue-98156-const-arg-temp-lifetime.rs
deleted file mode 100644
index aecb81caf22..00000000000
--- a/tests/codegen/issues/issue-98156-const-arg-temp-lifetime.rs
+++ /dev/null
@@ -1,27 +0,0 @@
-// This test checks that temporaries for indirectly-passed arguments get lifetime markers.
-
-//@ compile-flags: -Copt-level=3 -C no-prepopulate-passes -Zmir-opt-level=0
-
-#![crate_type = "lib"]
-
-extern "Rust" {
-    fn f(x: [u8; 1024]);
-}
-
-const A: [u8; 1024] = [0; 1024];
-
-// CHECK-LABEL: @const_arg_indirect
-#[no_mangle]
-pub unsafe fn const_arg_indirect() {
-    // Ensure that the live ranges for the two argument temporaries don't overlap.
-
-    // CHECK: call void @llvm.lifetime.start
-    // CHECK: call void @f
-    // CHECK: call void @llvm.lifetime.end
-    // CHECK: call void @llvm.lifetime.start
-    // CHECK: call void @f
-    // CHECK: call void @llvm.lifetime.end
-
-    f(A);
-    f(A);
-}