2008-11-06 Richard Guenther <rguenther@suse.de>
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 6 Nov 2008 14:20:04 +0000 (14:20 +0000)
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 6 Nov 2008 14:20:04 +0000 (14:20 +0000)
        * gcc.dg/c-torture/pr37969.c: New testcase.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@141642 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/torture/pr37969.c [new file with mode: 0644]

index 76de5b9..04ec162 100644 (file)
@@ -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 (file)
index 0000000..cbb6f05
--- /dev/null
@@ -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);
+    }
+}
+