]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - gcc/tree-ssa-copy.c
Merger of git branch "gimple-classes-v2-option-3"
[thirdparty/gcc.git] / gcc / tree-ssa-copy.c
index 7c22c5e9eb1bac15e88e0ca560e450fd6d597253..3833dff03e0a88e4b23bd1c0e47528be13ce4eb1 100644 (file)
@@ -340,7 +340,7 @@ copy_prop_visit_stmt (gimple stmt, edge *taken_edge_p, tree *result_p)
    set it to be the value of the LHS of PHI.  */
 
 static enum ssa_prop_result
-copy_prop_visit_phi_node (gimple phi)
+copy_prop_visit_phi_node (gphi *phi)
 {
   enum ssa_prop_result retval;
   unsigned i;
@@ -461,9 +461,8 @@ init_copy_prop (void)
 
   FOR_EACH_BB_FN (bb, cfun)
     {
-      gimple_stmt_iterator si;
-
-      for (si = gsi_start_bb (bb); !gsi_end_p (si); gsi_next (&si))
+      for (gimple_stmt_iterator si = gsi_start_bb (bb); !gsi_end_p (si);
+          gsi_next (&si))
        {
          gimple stmt = gsi_stmt (si);
          ssa_op_iter iter;
@@ -487,9 +486,10 @@ init_copy_prop (void)
              set_copy_of_val (def, def);
        }
 
-      for (si = gsi_start_phis (bb); !gsi_end_p (si); gsi_next (&si))
+      for (gphi_iterator si = gsi_start_phis (bb); !gsi_end_p (si);
+          gsi_next (&si))
        {
-          gimple phi = gsi_stmt (si);
+          gphi *phi = si.phi ();
           tree def;
 
          def = gimple_phi_result (phi);