summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/X86/extractps.ll
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/test/CodeGen/X86/extractps.ll')
-rw-r--r--llvm/test/CodeGen/X86/extractps.ll23
1 files changed, 17 insertions, 6 deletions
diff --git a/llvm/test/CodeGen/X86/extractps.ll b/llvm/test/CodeGen/X86/extractps.ll
index 586099d7488..ca4a47a420c 100644
--- a/llvm/test/CodeGen/X86/extractps.ll
+++ b/llvm/test/CodeGen/X86/extractps.ll
@@ -1,12 +1,16 @@
-; RUN: llc < %s -mtriple=i686-- -mcpu=penryn > %t
-; RUN: not grep movd %t
-; RUN: grep "movss %xmm" %t | count 1
-; RUN: grep "extractps \$1, %xmm0, " %t | count 1
+; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
+; RUN: llc < %s -mtriple=i686-- -mcpu=penryn | FileCheck %s
; PR2647
@0 = external global float, align 16 ; <float*>:0 [#uses=2]
-define internal void @""() nounwind {
+define internal void @a() nounwind {
+; CHECK-LABEL: a:
+; CHECK: # %bb.0:
+; CHECK-NEXT: movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
+; CHECK-NEXT: rsqrtss %xmm0, %xmm0
+; CHECK-NEXT: movss %xmm0, __unnamed_1
+; CHECK-NEXT: retl
load float, float* @0, align 16 ; <float>:1 [#uses=1]
insertelement <4 x float> undef, float %1, i32 0 ; <<4 x float>>:2 [#uses=1]
call <4 x float> @llvm.x86.sse.rsqrt.ss( <4 x float> %2 ) ; <<4 x float>>:3 [#uses=1]
@@ -14,7 +18,14 @@ define internal void @""() nounwind {
store float %4, float* @0, align 16
ret void
}
-define internal void @""() nounwind {
+define internal void @b() nounwind {
+; CHECK-LABEL: b:
+; CHECK: # %bb.0:
+; CHECK-NEXT: movss {{.*#+}} xmm0 = mem[0],zero,zero,zero
+; CHECK-NEXT: movsldup {{.*#+}} xmm0 = xmm0[0,0,2,2]
+; CHECK-NEXT: rsqrtss %xmm0, %xmm0
+; CHECK-NEXT: extractps $1, %xmm0, __unnamed_1
+; CHECK-NEXT: retl
load float, float* @0, align 16 ; <float>:1 [#uses=1]
insertelement <4 x float> undef, float %1, i32 1 ; <<4 x float>>:2 [#uses=1]
call <4 x float> @llvm.x86.sse.rsqrt.ss( <4 x float> %2 ) ; <<4 x float>>:3 [#uses=1]
OpenPOWER on IntegriCloud