aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorElena Demikhovsky <elena.demikhovsky@intel.com>2011-11-29 15:00:45 +0000
committerElena Demikhovsky <elena.demikhovsky@intel.com>2011-11-29 15:00:45 +0000
commitf68b214e2d06849091b5ff3dd5d5efe29722dcc3 (patch)
tree230cfe7f111effc763ec9e060ea221f1a1589edf /test
parentf267972d2864545f82f1eac7e922f85280a4d654 (diff)
downloadexternal_llvm-f68b214e2d06849091b5ff3dd5d5efe29722dcc3.zip
external_llvm-f68b214e2d06849091b5ff3dd5d5efe29722dcc3.tar.gz
external_llvm-f68b214e2d06849091b5ff3dd5d5efe29722dcc3.tar.bz2
Fixed vsqrt.ss intrinsic usage - order of input operands was wrong.
Added a test. Thanks Bruno for reviewing the patch. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145403 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r--test/CodeGen/X86/avx-arith.ll11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/CodeGen/X86/avx-arith.ll b/test/CodeGen/X86/avx-arith.ll
index 59988ca..4aa3370 100644
--- a/test/CodeGen/X86/avx-arith.ll
+++ b/test/CodeGen/X86/avx-arith.ll
@@ -259,3 +259,14 @@ define <4 x i64> @mul-v4i64(<4 x i64> %i, <4 x i64> %j) nounwind readnone {
ret <4 x i64> %x
}
+declare <4 x float> @llvm.x86.sse.sqrt.ss(<4 x float>) nounwind readnone
+
+define <4 x float> @int_sqrt_ss() {
+; CHECK: int_sqrt_ss
+; CHECK: vsqrtss
+ %x0 = load float addrspace(1)* undef, align 8
+ %x1 = insertelement <4 x float> undef, float %x0, i32 0
+ %x2 = call <4 x float> @llvm.x86.sse.sqrt.ss(<4 x float> %x1) nounwind
+ ret <4 x float> %x2
+}
+