[llvm] [CaptureTracking] Supports analysis for derived pointers (PR #132744)
Antonio Frighetto via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 24 08:03:22 PDT 2025
================
@@ -132,3 +132,31 @@ TEST(CaptureTracking, MultipleUsesInSameInstruction) {
EXPECT_EQ(ICmp, CT.Captures[6]->getUser());
EXPECT_EQ(1u, CT.Captures[6]->getOperandNo());
}
+
+TEST(CaptureTracking, DerivedPointerIfBasePointerCaptured) {
+ StringRef Assembly = R"(
+ declare void @bar(ptr)
+
+ define void @test() {
+ %stkobj = alloca [2 x i32]
----------------
antoniofrighetto wrote:
```suggestion
%stack_obj = alloca [2 x i32]
```
https://github.com/llvm/llvm-project/pull/132744
More information about the llvm-commits
mailing list