src/share/vm/opto/loopopts.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File 6738933 Sdiff src/share/vm/opto

src/share/vm/opto/loopopts.cpp

Print this page




 915               // Don't allow the control input to be a CFG splitting node.
 916               // Such nodes should only have ProjNodes as outs, e.g. IfNode
 917               // should only have IfTrueNode and IfFalseNode (4985384).
 918               x_ctrl = find_non_split_ctrl(x_ctrl);
 919               assert(dom_depth(n_ctrl) <= dom_depth(x_ctrl), "n is later than its clone");
 920 
 921               x->set_req(0, x_ctrl);
 922             }
 923             register_new_node(x, x_ctrl);
 924 
 925             // Some institutional knowledge is needed here: 'x' is
 926             // yanked because if the optimizer runs GVN on it all the
 927             // cloned x's will common up and undo this optimization and
 928             // be forced back in the loop.  This is annoying because it
 929             // makes +VerifyOpto report false-positives on progress.  I
 930             // tried setting control edges on the x's to force them to
 931             // not combine, but the matching gets worried when it tries
 932             // to fold a StoreP and an AddP together (as part of an
 933             // address expression) and the AddP and StoreP have
 934             // different controls.
 935             if( !x->is_Load() ) _igvn._worklist.yank(x);
 936           }
 937           _igvn.remove_dead_node(n);
 938         }
 939       }
 940     }
 941   }
 942 
 943   // Check for Opaque2's who's loop has disappeared - who's input is in the
 944   // same loop nest as their output.  Remove 'em, they are no longer useful.
 945   if( n_op == Op_Opaque2 &&
 946       n->in(1) != NULL &&
 947       get_loop(get_ctrl(n)) == get_loop(get_ctrl(n->in(1))) ) {
 948     _igvn.add_users_to_worklist(n);
 949     _igvn.hash_delete(n);
 950     _igvn.subsume_node( n, n->in(1) );
 951   }
 952 }
 953 
 954 //------------------------------split_if_with_blocks---------------------------
 955 // Check for aggressive application of 'split-if' optimization,




 915               // Don't allow the control input to be a CFG splitting node.
 916               // Such nodes should only have ProjNodes as outs, e.g. IfNode
 917               // should only have IfTrueNode and IfFalseNode (4985384).
 918               x_ctrl = find_non_split_ctrl(x_ctrl);
 919               assert(dom_depth(n_ctrl) <= dom_depth(x_ctrl), "n is later than its clone");
 920 
 921               x->set_req(0, x_ctrl);
 922             }
 923             register_new_node(x, x_ctrl);
 924 
 925             // Some institutional knowledge is needed here: 'x' is
 926             // yanked because if the optimizer runs GVN on it all the
 927             // cloned x's will common up and undo this optimization and
 928             // be forced back in the loop.  This is annoying because it
 929             // makes +VerifyOpto report false-positives on progress.  I
 930             // tried setting control edges on the x's to force them to
 931             // not combine, but the matching gets worried when it tries
 932             // to fold a StoreP and an AddP together (as part of an
 933             // address expression) and the AddP and StoreP have
 934             // different controls.
 935             if( !x->is_Load() && !x->is_DecodeN() ) _igvn._worklist.yank(x);
 936           }
 937           _igvn.remove_dead_node(n);
 938         }
 939       }
 940     }
 941   }
 942 
 943   // Check for Opaque2's who's loop has disappeared - who's input is in the
 944   // same loop nest as their output.  Remove 'em, they are no longer useful.
 945   if( n_op == Op_Opaque2 &&
 946       n->in(1) != NULL &&
 947       get_loop(get_ctrl(n)) == get_loop(get_ctrl(n->in(1))) ) {
 948     _igvn.add_users_to_worklist(n);
 949     _igvn.hash_delete(n);
 950     _igvn.subsume_node( n, n->in(1) );
 951   }
 952 }
 953 
 954 //------------------------------split_if_with_blocks---------------------------
 955 // Check for aggressive application of 'split-if' optimization,


src/share/vm/opto/loopopts.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File