aboutsummaryrefslogtreecommitdiffstats
path: root/test/CodeGen/SPARC
diff options
context:
space:
mode:
authorVenkatraman Govindaraju <venkatra@cs.wisc.edu>2013-08-25 17:03:02 +0000
committerVenkatraman Govindaraju <venkatra@cs.wisc.edu>2013-08-25 17:03:02 +0000
commit5ec8afa7cf9ae11def585fff043b0eabd735ac28 (patch)
treef2f3326a2976f62f556ce2618bc4944703d684b5 /test/CodeGen/SPARC
parent41f7baf181ef55fb6935ded8ced3797701a681ca (diff)
downloadexternal_llvm-5ec8afa7cf9ae11def585fff043b0eabd735ac28.zip
external_llvm-5ec8afa7cf9ae11def585fff043b0eabd735ac28.tar.gz
external_llvm-5ec8afa7cf9ae11def585fff043b0eabd735ac28.tar.bz2
[Sparc] Added V9's extra floating point registers and their aliases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@189195 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/SPARC')
-rw-r--r--test/CodeGen/SPARC/float.ll23
1 files changed, 23 insertions, 0 deletions
diff --git a/test/CodeGen/SPARC/float.ll b/test/CodeGen/SPARC/float.ll
index 8dfd371..ca9c40d 100644
--- a/test/CodeGen/SPARC/float.ll
+++ b/test/CodeGen/SPARC/float.ll
@@ -45,3 +45,26 @@ entry:
declare double @get_double()
declare double @llvm.fabs.f64(double) nounwind readonly
+; V8-LABEL: test_v9_floatreg:
+; V8: fsubd {{.+}}, {{.+}}, {{.+}}
+; V8: faddd {{.+}}, {{.+}}, [[R:%f(((1|2)?(0|2|4|6|8))|30)]]
+; V8: std [[R]], [%{{.+}}]
+; V8: ldd [%{{.+}}], %f0
+
+; V9-LABEL: test_v9_floatreg:
+; V9: fsubd {{.+}}, {{.+}}, {{.+}}
+; V9: faddd {{.+}}, {{.+}}, [[R:%f((3(2|4|6|8))|((4|5)(0|2|4|6|8))|(60|62))]]
+; V9: fmovd [[R]], %f0
+
+
+define double @test_v9_floatreg() {
+entry:
+ %0 = tail call double @get_double()
+ %1 = tail call double @get_double()
+ %2 = fsub double %0, %1
+ tail call void asm sideeffect "", "~{f0},~{f2},~{f3},~{f4},~{f5},~{f6},~{f7},~{f8},~{f9},~{f10},~{f11},~{f12},~{f13},~{f14},~{f15},~{f16},~{f17},~{f18},~{f19},~{f20},~{f21},~{f22},~{f23},~{f24},~{f25},~{f26},~{f27},~{f28},~{f29},~{f30},~{f31}"()
+ %3 = fadd double %2, %2
+ ret double %3
+}
+
+