OSDN Git Service

* gcc.dg/loop-4.c: New test.
authorebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 17 May 2004 20:53:55 +0000 (20:53 +0000)
committerebotcazou <ebotcazou@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 17 May 2004 20:53:55 +0000 (20:53 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@81946 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/testsuite/gcc.dg/loop-4.c [new file with mode: 0644]

diff --git a/gcc/testsuite/gcc.dg/loop-4.c b/gcc/testsuite/gcc.dg/loop-4.c
new file mode 100644 (file)
index 0000000..c83fd1c
--- /dev/null
@@ -0,0 +1,25 @@
+/* PR optimization/11841 */
+/* Originator: Andrey Panov <panov@canopus.iacp.dvo.ru> */
+/* Reduced testcase by Volker Reichelt <reichelt@igpm.rwth-aachen.de> */
+
+/* Verify that the (old) loop unroller doesn't wrongly mark a pseudo
+   referenced in a note as local.  */
+
+/* { dg-do run } */
+/* { dg-options "-O2 -funroll-loops" } */
+
+int *a;
+
+int main()
+{
+  double d[6];
+  int i, j;
+
+  for (i=0; i<4; ++i)
+    for (j=0; j<3; ++j)
+      d[i+j] = 0;
+
+  a = &i;
+
+  return 0;
+}