summaryrefslogtreecommitdiff
path: root/test/CodeGen/ARM/domain-conv-vmovs.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/ARM/domain-conv-vmovs.ll')
-rw-r--r--test/CodeGen/ARM/domain-conv-vmovs.ll22
1 files changed, 21 insertions, 1 deletions
diff --git a/test/CodeGen/ARM/domain-conv-vmovs.ll b/test/CodeGen/ARM/domain-conv-vmovs.ll
index a5c41144584c..b5586cc99fc1 100644
--- a/test/CodeGen/ARM/domain-conv-vmovs.ll
+++ b/test/CodeGen/ARM/domain-conv-vmovs.ll
@@ -78,7 +78,7 @@ define float @test_ineligible(float, float %in) {
; use-def chains would be messed up. Primarily a compile-test (we used to
; internal fault).
call void @bar()
-; CHECL: bl bar
+; CHECK: bl bar
; CHECK: vext.32
; CHECK: vext.32
ret float %val
@@ -98,3 +98,23 @@ define i32 @test_vmovs_no_sreg(i32 %in) {
ret i32 %resi
}
+
+
+; The point of this test is:
+; + Make sure s1 is live before the BL
+; + Make sure s1 is clobbered by the BL
+; + Convince LLVM to emit a VMOV to S0
+; + Convince LLVM to domain-convert this.
+
+; When all of those are satisfied, LLVM should *not* mark s1 as an implicit-use
+; because it's dead.
+
+declare float @clobbers_s1(float, float)
+
+define <2 x float> @test_clobbers_recognised(<2 x float> %invec, float %val) {
+ %elt = call float @clobbers_s1(float %val, float %val)
+
+ %vec = insertelement <2 x float> %invec, float %elt, i32 0
+ %res = fadd <2 x float> %vec, %vec
+ ret <2 x float> %res
+}