aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGen/Generic
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2005-04-02 05:35:00 +0000
committerChris Lattner <sabre@nondot.org>2005-04-02 05:35:00 +0000
commit597f22f6cd5c0bfa5ffc6ddf4cf5b2796efba867 (patch)
treeb07d9462d568348b7ac6159ef96b51caf5366448 /test/CodeGen/Generic
parentb7edaa1d0851d9cac75cb31233412f473fc820d1 (diff)
new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21016 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen/Generic')
-rw-r--r--test/CodeGen/Generic/fneg-fabs.ll26
1 files changed, 26 insertions, 0 deletions
diff --git a/test/CodeGen/Generic/fneg-fabs.ll b/test/CodeGen/Generic/fneg-fabs.ll
new file mode 100644
index 0000000000..a533fe5599
--- /dev/null
+++ b/test/CodeGen/Generic/fneg-fabs.ll
@@ -0,0 +1,26 @@
+; RUN: llvm-as < %s | llc
+
+double %fneg(double %X) {
+ %Y = sub double -0.0, %X
+ ret double %Y
+}
+
+float %fnegf(float %X) {
+ %Y = sub float -0.0, %X
+ ret float %Y
+}
+
+declare double %fabs(double)
+declare float %fabsf(float)
+
+
+double %fabstest(double %X) {
+ %Y = call double %fabs(double %X)
+ ret double %Y
+}
+
+float %fabsftest(float %X) {
+ %Y = call float %fabsf(float %X)
+ ret float %Y
+}
+