< prev index next >

src/share/vm/opto/ifnode.cpp

Print this page
rev 7756 : 8071996: split_if accesses NULL region of ConstraintCast
Reviewed-by: kvn

*** 143,156 **** // Make sure we can account for all Phi uses for (DUIterator_Fast kmax, k = u->fast_outs(kmax); k < kmax; k++) { Node* v = u->fast_out(k); // User of the phi // CNC - Allow only really simple patterns. // In particular I disallow AddP of the Phi, a fairly common pattern ! if( v == cmp ) continue; // The compare is OK ! if( (v->is_ConstraintCast()) && ! v->in(0)->in(0) == iff ) continue; // CastPP/II of the IfNode is OK // Disabled following code because I cannot tell if exactly one // path dominates without a real dominator check. CNC 9/9/1999 //uint vop = v->Opcode(); //if( vop == Op_Phi ) { // Phi from another merge point might be OK // Node *r = v->in(0); // Get controlling point --- 143,164 ---- // Make sure we can account for all Phi uses for (DUIterator_Fast kmax, k = u->fast_outs(kmax); k < kmax; k++) { Node* v = u->fast_out(k); // User of the phi // CNC - Allow only really simple patterns. // In particular I disallow AddP of the Phi, a fairly common pattern ! if (v == cmp) continue; // The compare is OK ! if (v->is_ConstraintCast()) { ! // If the cast is derived from data flow edges, it may not have a control. ! // If so, it should be save to split. But follow-up code can not deal with ! // this (l. 359). So skip. ! if (v->in(0) == NULL) { ! return NULL; ! } ! if (v->in(0)->in(0) == iff) { continue; // CastPP/II of the IfNode is OK + } + } // Disabled following code because I cannot tell if exactly one // path dominates without a real dominator check. CNC 9/9/1999 //uint vop = v->Opcode(); //if( vop == Op_Phi ) { // Phi from another merge point might be OK // Node *r = v->in(0); // Get controlling point
< prev index next >