This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug fortran/55935] [OOP] Fortran fronted has ADDR_EXPRs of FUNCTION_DECLs with bogus BLOCK


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55935

--- Comment #12 from Richard Biener <rguenth at gcc dot gnu.org> 2013-01-11 14:30:29 UTC ---
Index: gcc/tree-cfgcleanup.c
===================================================================
--- gcc/tree-cfgcleanup.c       (revision 195103)
+++ gcc/tree-cfgcleanup.c       (working copy)
@@ -412,7 +412,8 @@ remove_forwarder_block (basic_block bb)
            {
              gimple phi = gsi_stmt (gsi);
              source_location l = gimple_phi_arg_location_from_edge (phi,
succ);
-             add_phi_arg (phi, gimple_phi_arg_def (phi, succ->dest_idx), s,
l);
+             tree def = gimple_phi_arg_def (phi, succ->dest_idx);
+             add_phi_arg (phi, unshare_expr (def), s, l);
            }
        }
     }

is the only other that triggers in tree-ssa.exp with

Index: gcc/tree-cfg.c
===================================================================
--- gcc/tree-cfg.c      (revision 195103)
+++ gcc/tree-cfg.c      (working copy)
@@ -4440,8 +4460,8 @@ bool
 tree_node_can_be_shared (tree t)
 {
   if (IS_TYPE_OR_DECL_P (t)
-      || is_gimple_min_invariant (t)
       || TREE_CODE (t) == SSA_NAME
+      || CONSTANT_CLASS_P (t)
       || t == error_mark_node
       || TREE_CODE (t) == IDENTIFIER_NODE)
     return true;

execute.exp has more issue it seems.


removal of the handled_component_p block from tree_node_can_be_shared
has bootstrapped all languages ok, testing is still in progress.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]