< prev index next >

src/share/vm/opto/cfgnode.cpp

Print this page

        

*** 1663,1673 **** return top; } bool uncasted = false; Node* uin = unique_input(phase, false); ! if (uin == NULL) { uncasted = true; uin = unique_input(phase, true); } if (uin == top) { // Simplest case: no alive inputs. if (can_reshape) // IGVN transformation --- 1663,1673 ---- return top; } bool uncasted = false; Node* uin = unique_input(phase, false); ! if (uin == NULL && can_reshape) { uncasted = true; uin = unique_input(phase, true); } if (uin == top) { // Simplest case: no alive inputs. if (can_reshape) // IGVN transformation
*** 1700,1709 **** --- 1700,1711 ---- } } } if (uncasted) { + // Wait until after parsing for the type information to propagate from the casts + assert(can_reshape, "Invalid during parsing"); const Type* phi_type = bottom_type(); assert(phi_type->isa_int() || phi_type->isa_ptr(), "bad phi type"); int opcode; if (phi_type->isa_int()) { opcode = Op_CastII;
*** 1718,1729 **** // Add a cast to carry the control dependency of the Phi that is // going away Node* cast = ConstraintCastNode::make_cast(opcode, r, uin, phi_type, true); cast = phase->transform(cast); // set all inputs to the new cast so the Phi is removed by Identity for (uint i = 1; i < req(); i++) { ! set_req(i, cast); } uin = cast; } // One unique input. --- 1720,1732 ---- // Add a cast to carry the control dependency of the Phi that is // going away Node* cast = ConstraintCastNode::make_cast(opcode, r, uin, phi_type, true); cast = phase->transform(cast); // set all inputs to the new cast so the Phi is removed by Identity + PhaseIterGVN* igvn = phase->is_IterGVN(); for (uint i = 1; i < req(); i++) { ! set_req_X(i, cast, igvn); } uin = cast; } // One unique input.
< prev index next >