summaryrefslogtreecommitdiff
path: root/test/CodeGen/ARM/vmov.ll
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2011-11-15 02:12:34 +0000
committerEvan Cheng <evan.cheng@apple.com>2011-11-15 02:12:34 +0000
commiteaa192af18677c4dc5894e049514d8a6b1d6d7c2 (patch)
treedc9dd55a7dd8a5f11f9e547107584e4fa1c408ca /test/CodeGen/ARM/vmov.ll
parentbfc9429c2b814469adf3930dda31539d1c3319d8 (diff)
downloadllvm-eaa192af18677c4dc5894e049514d8a6b1d6d7c2.tar.gz
llvm-eaa192af18677c4dc5894e049514d8a6b1d6d7c2.tar.bz2
llvm-eaa192af18677c4dc5894e049514d8a6b1d6d7c2.tar.xz
Add vmov.f32 to materialize f32 immediate splats which cannot be handled by
integer variants. rdar://10437054 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@144608 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/ARM/vmov.ll')
-rw-r--r--test/CodeGen/ARM/vmov.ll18
1 files changed, 18 insertions, 0 deletions
diff --git a/test/CodeGen/ARM/vmov.ll b/test/CodeGen/ARM/vmov.ll
index ab56e5bb29..0396a41a35 100644
--- a/test/CodeGen/ARM/vmov.ll
+++ b/test/CodeGen/ARM/vmov.ll
@@ -353,3 +353,21 @@ define void @noTruncStore(<4 x i32>* %a, <4 x i16>* %b) nounwind {
store <4 x i16> %tmp2, <4 x i16>* %b, align 8
ret void
}
+
+; Use vmov.f32 to materialize f32 immediate splats
+; rdar://10437054
+define void @v_mov_v2f32(<2 x float>* nocapture %p) nounwind {
+entry:
+;CHECK: v_mov_v2f32:
+;CHECK: vmov.f32 d{{.*}}, #-1.600000e+01
+ store <2 x float> <float -1.600000e+01, float -1.600000e+01>, <2 x float>* %p, align 4
+ ret void
+}
+
+define void @v_mov_v4f32(<4 x float>* nocapture %p) nounwind {
+entry:
+;CHECK: v_mov_v4f32:
+;CHECK: vmov.f32 q{{.*}}, #3.100000e+01
+ store <4 x float> <float 3.100000e+01, float 3.100000e+01, float 3.100000e+01, float 3.100000e+01>, <4 x float>* %p, align 4
+ ret void
+}