aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Guenther <rguenther@suse.de>2008-11-06 14:20:04 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2008-11-06 14:20:04 +0000
commit1ddb9ec910a77414305a4b3bba72e3f4ae02f92a (patch)
treea068f5c5aa3ae0b6a64f8ca7390414a911b3296f /gcc
parent6818f0fc846185c49f08e7a1c742b71fb0dc8388 (diff)
downloadgcc-1ddb9ec910a77414305a4b3bba72e3f4ae02f92a.zip
gcc-1ddb9ec910a77414305a4b3bba72e3f4ae02f92a.tar.gz
gcc-1ddb9ec910a77414305a4b3bba72e3f4ae02f92a.tar.bz2
pr37969.c: New testcase.
2008-11-06 Richard Guenther <rguenther@suse.de> * gcc.dg/c-torture/pr37969.c: New testcase. From-SVN: r141642
Diffstat (limited to 'gcc')
-rw-r--r--gcc/testsuite/ChangeLog4
-rw-r--r--gcc/testsuite/gcc.dg/torture/pr37969.c20
2 files changed, 24 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 76de5b9..04ec162 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,7 @@
+2008-11-06 Richard Guenther <rguenther@suse.de>
+
+ * gcc.dg/torture/pr37969.c: New testcase.
+
2008-11-05 Janis Johnson <janis187@us.ibm.com>
* lib/c-torture.exp: Use ADDITIONAL_TORTURE_OPTIONS if defined.
diff --git a/gcc/testsuite/gcc.dg/torture/pr37969.c b/gcc/testsuite/gcc.dg/torture/pr37969.c
new file mode 100644
index 0000000..cbb6f05
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/torture/pr37969.c
@@ -0,0 +1,20 @@
+/* { dg-do compile } */
+/* { dg-options "-funswitch-loops" } */
+
+void foo(double);
+void CreateDefaultTexture(double mnMinimum, double mnMaximum,
+ unsigned short nCreateWhat)
+{
+ double d = 0.0;
+ for(;;)
+ {
+ if(nCreateWhat & (0x0001)
+ && mnMinimum != 0.0)
+ d = mnMinimum;
+ if(nCreateWhat & (0x0002)
+ && mnMaximum != 0.0)
+ d = mnMaximum;
+ foo(d);
+ }
+}
+