summaryrefslogtreecommitdiffstats
path: root/gcc/testsuite/gcc.dg
diff options
context:
space:
mode:
authorwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>1998-03-18 16:28:32 +0000
committerwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>1998-03-18 16:28:32 +0000
commit3f59d0822c8505f36e53687a3e77e149be754ec9 (patch)
tree21fd8ce865d8f61998fb3c3be1aa1902eb3edd10 /gcc/testsuite/gcc.dg
parent1122c4f58eacc69a76109cfb0105af95a17bbfaf (diff)
downloadppe42-gcc-3f59d0822c8505f36e53687a3e77e149be754ec9.tar.gz
ppe42-gcc-3f59d0822c8505f36e53687a3e77e149be754ec9.zip
Testcase for reg-stack failure for testcase using fp conditional move.
* gcc.dg/980313-1.c: New test for fp conditional move on PPro. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@18679 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.dg')
-rw-r--r--gcc/testsuite/gcc.dg/980313-1.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/980313-1.c b/gcc/testsuite/gcc.dg/980313-1.c
new file mode 100644
index 00000000000..746e4631b08
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/980313-1.c
@@ -0,0 +1,21 @@
+/* { dg-do compile { target i?86-*-* } } */
+/* { dg-options "-O2 -march=pentiumpro" } */
+
+extern __inline double
+__expm1 (double __x)
+{
+ double __temp;
+ __temp -= 1.0;
+ return __temp;
+}
+extern __inline double
+__sgn1 (double __x)
+{
+ return __x >= 0.0 ? 1.0 : -1.0;
+}
+double
+tanh (double __x)
+{
+ register double __exm1 = __expm1 (__x);
+ return __exm1 / (__exm1 + 2.0) * __sgn1 (-__x);
+}
OpenPOWER on IntegriCloud