We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c92c86f commit 71bf052Copy full SHA for 71bf052
llvm/test/Transforms/SLPVectorizer/X86/reduction-bool-logic-op-inside.ll
@@ -0,0 +1,19 @@
1
+; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 3
2
+; RUN: opt -S < %s --passes=slp-vectorizer | FileCheck %s
3
+
4
+define i1 @test(i32 %x) {
5
+; CHECK-LABEL: define i1 @test(
6
+; CHECK-SAME: i32 [[X:%.*]]) {
7
+; CHECK-NEXT: [[CMP:%.*]] = icmp sgt i32 [[X]], 1
8
+; CHECK-NEXT: [[OP_RDX:%.*]] = or i1 poison, [[CMP]]
9
+; CHECK-NEXT: ret i1 [[OP_RDX]]
10
+;
11
+ %cmp = icmp sgt i32 %x, 1
12
+ %sel1 = select i1 %cmp, i1 true, i1 poison
13
+ %sel2 = select i1 %sel1, i1 true, i1 poison
14
+ %sel3 = select i1 %sel2, i1 true, i1 poison
15
+ %sel4 = select i1 %cmp, i1 true, i1 poison
16
+ %ret = or i1 %sel3, %sel4
17
+ ret i1 %ret
18
+}
19
0 commit comments