re PR rtl-optimization/49474 (ppc ICEs with -O3 (bootstrapping with -O3 and --disable...
authorAndrew Pinski <pinskia@gmail.com>
Tue, 12 Jul 2011 18:46:10 +0000 (11:46 -0700)
committerAndrew Pinski <pinskia@gcc.gnu.org>
Tue, 12 Jul 2011 18:46:10 +0000 (11:46 -0700)
2011-07-12  Andrew Pinski  <pinskia@gmail.com>

PR rtl-opt/49474
* cprop.c (find_implicit_sets): Correct the condition.

2011-07-12  Andrew Pinski  <pinskia@gmail.com>

PR rtl-opt/49474
* gcc.c-torture/compile/pr49474.c: New testcase.

From-SVN: r176213

gcc/ChangeLog
gcc/cprop.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.c-torture/compile/pr49474.c [new file with mode: 0644]

index 462ee7d281db2c7c5db8dc3fd218a1f991a0a902..f3abf4d05537e7a18407fa04415f4aa6ffc54308 100644 (file)
@@ -1,3 +1,8 @@
+2011-07-12  Andrew Pinski  <pinskia@gmail.com>
+
+       PR rtl-opt/49474
+       * cprop.c (find_implicit_sets): Correct the condition.
+
 2011-07-12  Richard Henderson  <rth@redhat.com>
 
        PR target/49713
index 83193b9d6b47e5264a63becfa44b18f504212b87..584ffd202bac80948060beeaed5d0d2a8232561e 100644 (file)
@@ -1332,7 +1332,7 @@ find_implicit_sets (void)
   FOR_EACH_BB (bb)
     {
       /* Check for more than one successor.  */
-      if (! EDGE_COUNT (bb->succs) > 1)
+      if (EDGE_COUNT (bb->succs) <= 1)
        continue;
 
       cond = fis_get_condition (BB_END (bb));
index 88f61ccce5613601878c273cb6ad72cc9e803b8b..5d1cab63c7c28e00a9edc9f590b72a8a5bdead48 100644 (file)
@@ -1,3 +1,8 @@
+2011-07-12  Andrew Pinski  <pinskia@gmail.com>
+
+       PR rtl-opt/49474
+       * gcc.c-torture/compile/pr49474.c: New testcase.
+
 2011-07-12  Jakub Jelinek  <jakub@redhat.com>
 
        PR tree-optimization/49712
diff --git a/gcc/testsuite/gcc.c-torture/compile/pr49474.c b/gcc/testsuite/gcc.c-torture/compile/pr49474.c
new file mode 100644 (file)
index 0000000..0368ccb
--- /dev/null
@@ -0,0 +1,16 @@
+typedef struct gfc_formal_arglist
+{
+  int next;
+}
+gfc_actual_arglist;
+update_arglist_pass (gfc_actual_arglist* lst, int po, unsigned argpos,
+       const char *name)
+{
+  ((void)(__builtin_expect(!(argpos > 0), 0) ? __builtin_unreachable(), 0 : 0));
+  if (argpos == 1)
+      return 0;
+  if (lst)
+    lst->next = update_arglist_pass (lst->next, po, argpos - 1, name);
+  else
+    lst = update_arglist_pass (((void *)0), po, argpos - 1, name);
+}