[llvm] e79c196 - [LV] Add opaque pointer test for #55375.
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Wed May 11 03:25:12 PDT 2022
Author: Florian Hahn
Date: 2022-05-11T11:24:52+01:00
New Revision: e79c1962b9d7b0dda9d4481fc79fe55e762d0f5d
URL: https://github.com/llvm/llvm-project/commit/e79c1962b9d7b0dda9d4481fc79fe55e762d0f5d
DIFF: https://github.com/llvm/llvm-project/commit/e79c1962b9d7b0dda9d4481fc79fe55e762d0f5d.diff
LOG: [LV] Add opaque pointer test for #55375.
Added:
llvm/test/Transforms/LoopVectorize/X86/interleave-opaque-pointers.ll
Modified:
Removed:
################################################################################
diff --git a/llvm/test/Transforms/LoopVectorize/X86/interleave-opaque-pointers.ll b/llvm/test/Transforms/LoopVectorize/X86/interleave-opaque-pointers.ll
new file mode 100644
index 0000000000000..29f657e32951f
--- /dev/null
+++ b/llvm/test/Transforms/LoopVectorize/X86/interleave-opaque-pointers.ll
@@ -0,0 +1,26 @@
+; RUN: opt -passes=loop-vectorize -force-vector-width=2 -force-vector-interleave=1 -S %s | FileCheck %s
+
+; REQUIRES: asserts
+; XFAIL: *
+
+target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
+target triple = "x86_64-linux-gnu"
+
+%pair = type { ptr, ptr }
+
+define void @test_pr55375_interleave_opaque_ptr(ptr %start, ptr %end) {
+entry:
+ br label %loop
+
+loop:
+ %iv = phi ptr [ %start, %entry ], [ %iv.next, %loop ]
+ %iv.1 = getelementptr inbounds %pair, ptr %iv, i64 0, i32 1
+ store ptr %iv, ptr %iv.1, align 8
+ store ptr null, ptr %iv, align 8
+ %iv.next = getelementptr inbounds %pair, ptr %iv, i64 1
+ %ec = icmp eq ptr %iv.next, %end
+ br i1 %ec, label %exit, label %loop
+
+exit:
+ ret void
+}
More information about the llvm-commits
mailing list