< prev index next >

src/share/vm/opto/split_if.cpp

Print this page

        

@@ -71,11 +71,12 @@
   if( get_ctrl(n) != blk1 && get_ctrl(n) != blk2 )
     return false;               // Not block local
   if( n->is_Phi() ) return false; // Local PHIs are expected
 
   // Recursively split-up inputs
-  for (uint i = 1; i < n->req(); i++) {
+  uint first_input = n->Opcode() == Op_ShenandoahWBMemProj ? 0 : 1;
+  for (uint i = first_input; i < n->req(); i++) {
     if( split_up( n->in(i), blk1, blk2 ) ) {
       // Got split recursively and self went dead?
       if (n->outcnt() == 0)
         _igvn.remove_dead_node(n);
       return true;

@@ -214,10 +215,11 @@
   }
   // Announce phi to optimizer
   register_new_node(phi, blk1);
 
   // Remove cloned-up value from optimizer; use phi instead
+  split_mem_thru_phi(n, blk1, phi);
   _igvn.replace_node( n, phi );
 
   // (There used to be a self-recursive call to split_up() here,
   // but it is not needed.  All necessary forward walking is done
   // by do_split_if() below.)
< prev index next >