< prev index next >

src/hotspot/share/opto/loopopts.cpp

Print this page

        

*** 309,318 **** --- 309,319 ---- set_ctrl_and_loop(m, find_non_split_ctrl(idom(n_ctrl))); continue; } return NULL; } + assert(m->is_Phi() || is_dominator(get_ctrl(m), n_ctrl), "m has strange control"); } return n_ctrl; }
*** 611,621 **** iff->_prob > (1.0f - infrequent_prob)) return NULL; // -------------- // Now replace all Phis with CMOV's ! Node *cmov_ctrl = iff->in(0); uint flip = (lp->Opcode() == Op_IfTrue); while (1) { PhiNode* phi = NULL; for (DUIterator_Fast imax, i = region->fast_outs(imax); i < imax; i++) { Node *out = region->fast_out(i); --- 612,622 ---- iff->_prob > (1.0f - infrequent_prob)) return NULL; // -------------- // Now replace all Phis with CMOV's ! Node *cmov_ctrl = region; uint flip = (lp->Opcode() == Op_IfTrue); while (1) { PhiNode* phi = NULL; for (DUIterator_Fast imax, i = region->fast_outs(imax); i < imax; i++) { Node *out = region->fast_out(i);
*** 624,647 **** break; } } if (phi == NULL) break; if (PrintOpto && VerifyLoopOptimizations) { tty->print_cr("CMOV"); } - // Move speculative ops - for (uint j = 1; j < region->req(); j++) { - Node *proj = region->in(j); - Node *inp = phi->in(j); - if (get_ctrl(inp) == proj) { // Found local op - #ifndef PRODUCT - if (PrintOpto && VerifyLoopOptimizations) { - tty->print(" speculate: "); - inp->dump(); - } - #endif - set_ctrl(inp, cmov_ctrl); - } - } Node *cmov = CMoveNode::make(cmov_ctrl, iff->in(1), phi->in(1+flip), phi->in(2-flip), _igvn.type(phi)); register_new_node( cmov, cmov_ctrl ); _igvn.replace_node( phi, cmov ); #ifndef PRODUCT if (TraceLoopOpts) { --- 625,634 ----
< prev index next >