llvm.org GIT mirror llvm / 56938b6
merge r276347 [X86] Do not use AND8ri8 in AVX512 pattern This variant is (as documented in the TD) for disassembler use only, and should not be used in patterns - it is longer, and is broken on 64-bit. git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_39@287855 91177308-0d34-0410-b5e6-96231b3b80d8 Guy Blank 2 years ago
2 changed file(s) with 19 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
21232123 (COPY_TO_REGCLASS (i16 (EXTRACT_SUBREG $src, sub_16bit)), VK1)>;
21242124
21252125 def : Pat<(i1 (trunc (i8 GR8:$src))),
2126 (COPY_TO_REGCLASS (i16 (SUBREG_TO_REG (i64 0), (AND8ri8 $src, (i8 1)),
2126 (COPY_TO_REGCLASS (i16 (SUBREG_TO_REG (i64 0), (AND8ri $src, (i8 1)),
21272127 sub_8bit)), VK1)>;
21282128
21292129 def : Pat<(i1 (trunc (i8 (assertzext_i1 GR8:$src)))),
0 ; RUN: llc -mtriple=x86_64-pc-linux -mattr=+avx512f --show-mc-encoding < %s | FileCheck %s
1
2 declare i1 @bar()
3
4 ; CHECK-LABEL: @foo
5 ; CHECK-NOT: andb {{.*}} # encoding: [0x82,
6 define i1 @foo(i1 %i) nounwind {
7 entry:
8 br i1 %i, label %if, label %else
9
10 if:
11 %r = call i1 @bar()
12 br label %else
13
14 else:
15 %ret = phi i1 [%r, %if], [true, %entry]
16 ret i1 %ret
17 }