summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/passes.c2
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/gcc.dg/vect/pr32824.c15
4 files changed, 27 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 0d1fc700df5..7e9824399e8 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,9 @@
+2010-04-06 Changpeng Fang <changpeng.fang@amd.com>
+
+ PR middle-end/32824
+ * passes.c (init_optimization_passes): Move pass_lim before
+ pass_copy_prop and pass_dce_loop.
+
2010-04-06 Jakub Jelinek <jakub@redhat.com>
PR target/43667
diff --git a/gcc/passes.c b/gcc/passes.c
index 33d52affc77..8791ebc9dbc 100644
--- a/gcc/passes.c
+++ b/gcc/passes.c
@@ -885,9 +885,9 @@ init_optimization_passes (void)
{
struct opt_pass **p = &pass_tree_loop.pass.sub;
NEXT_PASS (pass_tree_loop_init);
+ NEXT_PASS (pass_lim);
NEXT_PASS (pass_copy_prop);
NEXT_PASS (pass_dce_loop);
- NEXT_PASS (pass_lim);
NEXT_PASS (pass_tree_unswitch);
NEXT_PASS (pass_scev_cprop);
NEXT_PASS (pass_record_bounds);
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index a485fcb3d7e..5127b32b9f4 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2010-04-06 Changpeng Fang <changpeng.fang@amd.com>
+
+ PR middle-end/32824
+ * gcc.dg/vect/pr32824: New.
+
2010-04-06 Tobias Burnus <burnus@net-b.de>
PR fortran/18918
diff --git a/gcc/testsuite/gcc.dg/vect/pr32824.c b/gcc/testsuite/gcc.dg/vect/pr32824.c
new file mode 100644
index 00000000000..8f36d1db2c6
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/pr32824.c
@@ -0,0 +1,15 @@
+/* { dg-do compile } */
+/* { dg-require-effective-target vect_int } */
+
+int a[16*100];
+int e;
+void foo(void)
+{
+ int i;
+ for(i = 0;i<16*100;i++)
+ e += a[i];
+}
+
+/* { dg-final { scan-tree-dump-times "vectorized 1 loops" 1 "vect" } } */
+/* { dg-final { cleanup-tree-dump "vect" } } */
+