mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-02-01 13:11:39 +01:00
154413adc2
I moved a test from avx512-vbroadcast-crash.ll to avx512-vbroadcast.ll I defined HasAVX512 predicate as AssemblerPredicate. It means that you should invoke llvm-mc with "-mcpu=knl" to get encoding for AVX-512 instructions. I need this to let AsmMatcher to set different encoding for AVX and AVX-512 instructions that have the same mnemonic and operands (all scalar instructions). llvm-svn: 197041
28 lines
611 B
LLVM
28 lines
611 B
LLVM
; RUN: llc < %s -mtriple=x86_64-apple-darwin -mcpu=knl --show-mc-encoding | FileCheck %s
|
|
|
|
; CHECK: vucomisd {{.*}}encoding: [0x62
|
|
define double @test1(double %a, double %b) nounwind {
|
|
%tobool = fcmp une double %a, %b
|
|
br i1 %tobool, label %l1, label %l2
|
|
|
|
l1:
|
|
%c = fsub double %a, %b
|
|
ret double %c
|
|
l2:
|
|
%c1 = fadd double %a, %b
|
|
ret double %c1
|
|
}
|
|
|
|
; CHECK: vucomiss {{.*}}encoding: [0x62
|
|
define float @test2(float %a, float %b) nounwind {
|
|
%tobool = fcmp olt float %a, %b
|
|
br i1 %tobool, label %l1, label %l2
|
|
|
|
l1:
|
|
%c = fsub float %a, %b
|
|
ret float %c
|
|
l2:
|
|
%c1 = fadd float %a, %b
|
|
ret float %c1
|
|
}
|