File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed
llvm/test/Transforms/SLPVectorizer/X86 Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change
1
+ ; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 6
2
+ ; RUN: opt -S --passes=slp-vectorizer -mtriple=x86_64-unknown-linux-gnu < %s -slp-threshold=-100 | FileCheck %s
3
+ define i1 @foo (i1 %v ) { ; assume %v is 1
4
+ ; CHECK-LABEL: define i1 @foo(
5
+ ; CHECK-SAME: i1 [[V:%.*]]) {
6
+ ; CHECK-NEXT: [[ENTRY:.*:]]
7
+ ; CHECK-NEXT: [[TMP0:%.*]] = insertelement <2 x i1> poison, i1 [[V]], i32 0
8
+ ; CHECK-NEXT: [[TMP1:%.*]] = shufflevector <2 x i1> [[TMP0]], <2 x i1> poison, <2 x i32> zeroinitializer
9
+ ; CHECK-NEXT: [[TMP2:%.*]] = mul <2 x i1> <i1 false, i1 true>, [[TMP1]]
10
+ ; CHECK-NEXT: [[TMP3:%.*]] = extractelement <2 x i1> [[TMP2]], i32 0
11
+ ; CHECK-NEXT: [[TMP4:%.*]] = extractelement <2 x i1> [[TMP2]], i32 1
12
+ ; CHECK-NEXT: [[SUB:%.*]] = sub i1 [[TMP3]], [[TMP4]]
13
+ ; CHECK-NEXT: ret i1 [[SUB]]
14
+ ;
15
+ entry:
16
+ %not = xor i1 %v , 1 ; 0
17
+ %not1 = xor i1 %not , 1 ; 1
18
+ %mul = mul i1 %v , 1 ; 1
19
+ %sub = sub i1 %not1 , %mul ; 0
20
+ ret i1 %sub ; 0
21
+ }
You can’t perform that action at this time.
0 commit comments