1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-01 00:12:50 +01:00
llvm-mirror/test/Bitcode/ptest-old.ll
Nadav Rotem 7eefbe1005 Add AutoUpgrade support for the SSE4 ptest intrinsics.
Patch by Michael Kuperstein.

llvm-svn: 158295
2012-06-10 18:42:51 +00:00

23 lines
1.0 KiB
LLVM

; RUN: llvm-as < %s | llvm-dis | FileCheck %s
define i32 @foo(<4 x float> %bar) nounwind {
entry:
; CHECK: call i32 @llvm.x86.sse41.ptestc(<2 x i64>
%res1 = call i32 @llvm.x86.sse41.ptestc(<4 x float> %bar, <4 x float> %bar)
; CHECK: call i32 @llvm.x86.sse41.ptestz(<2 x i64>
%res2 = call i32 @llvm.x86.sse41.ptestz(<4 x float> %bar, <4 x float> %bar)
; CHECK: call i32 @llvm.x86.sse41.ptestnzc(<2 x i64>
%res3 = call i32 @llvm.x86.sse41.ptestnzc(<4 x float> %bar, <4 x float> %bar)
%add1 = add i32 %res1, %res2
%add2 = add i32 %add1, %res2
ret i32 %add2
}
; CHECK: declare i32 @llvm.x86.sse41.ptestc(<2 x i64>, <2 x i64>) nounwind readnone
; CHECK: declare i32 @llvm.x86.sse41.ptestz(<2 x i64>, <2 x i64>) nounwind readnone
; CHECK: declare i32 @llvm.x86.sse41.ptestnzc(<2 x i64>, <2 x i64>) nounwind readnone
declare i32 @llvm.x86.sse41.ptestc(<4 x float>, <4 x float>) nounwind readnone
declare i32 @llvm.x86.sse41.ptestz(<4 x float>, <4 x float>) nounwind readnone
declare i32 @llvm.x86.sse41.ptestnzc(<4 x float>, <4 x float>) nounwind readnone