2012-07-29 04:44:09 +02:00
|
|
|
; RUN: llc < %s -march=x86 -mcpu=yonah | FileCheck %s
|
2009-07-08 00:51:09 +02:00
|
|
|
|
2009-07-08 01:03:54 +02:00
|
|
|
|
2009-07-08 20:51:25 +02:00
|
|
|
define <4 x i32> @test1(<4 x i32> %A, <4 x i32> %B) nounwind {
|
|
|
|
; CHECK: test1:
|
|
|
|
; CHECK: pcmpgtd
|
|
|
|
; CHECK: ret
|
|
|
|
|
2009-07-08 01:03:54 +02:00
|
|
|
%C = icmp sgt <4 x i32> %A, %B
|
|
|
|
%D = sext <4 x i1> %C to <4 x i32>
|
|
|
|
ret <4 x i32> %D
|
|
|
|
}
|
|
|
|
|
2009-07-08 20:51:25 +02:00
|
|
|
define <4 x i32> @test2(<4 x i32> %A, <4 x i32> %B) nounwind {
|
|
|
|
; CHECK: test2:
|
|
|
|
; CHECK: pcmp
|
2012-07-29 04:44:09 +02:00
|
|
|
; CHECK: pcmp
|
|
|
|
; CHECK: pxor
|
2009-07-08 20:51:25 +02:00
|
|
|
; CHECK: ret
|
|
|
|
%C = icmp sge <4 x i32> %A, %B
|
|
|
|
%D = sext <4 x i1> %C to <4 x i32>
|
|
|
|
ret <4 x i32> %D
|
|
|
|
}
|
|
|
|
|
|
|
|
define <4 x i32> @test3(<4 x i32> %A, <4 x i32> %B) nounwind {
|
|
|
|
; CHECK: test3:
|
|
|
|
; CHECK: pcmpgtd
|
2010-03-31 00:47:00 +02:00
|
|
|
; CHECK: movdqa
|
2009-07-08 20:51:25 +02:00
|
|
|
; CHECK: ret
|
|
|
|
%C = icmp slt <4 x i32> %A, %B
|
|
|
|
%D = sext <4 x i1> %C to <4 x i32>
|
|
|
|
ret <4 x i32> %D
|
|
|
|
}
|
|
|
|
|
|
|
|
define <4 x i32> @test4(<4 x i32> %A, <4 x i32> %B) nounwind {
|
|
|
|
; CHECK: test4:
|
2010-03-31 00:47:00 +02:00
|
|
|
; CHECK: movdqa
|
2009-07-08 20:51:25 +02:00
|
|
|
; CHECK: pcmpgtd
|
|
|
|
; CHECK: ret
|
|
|
|
%C = icmp ugt <4 x i32> %A, %B
|
|
|
|
%D = sext <4 x i1> %C to <4 x i32>
|
|
|
|
ret <4 x i32> %D
|
|
|
|
}
|