src/share/vm/opto/connode.cpp
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File
*** old/src/share/vm/opto/connode.cpp	Tue Mar 25 15:47:06 2014
--- new/src/share/vm/opto/connode.cpp	Tue Mar 25 15:47:06 2014

*** 397,407 **** --- 397,407 ---- //------------------------------Value------------------------------------------ // Take 'join' of input and cast-up type const Type *ConstraintCastNode::Value( PhaseTransform *phase ) const { if( in(0) && phase->type(in(0)) == Type::TOP ) return Type::TOP; ! const Type* ft = phase->type(in(1))->filter_speculative(_type); #ifdef ASSERT // Previous versions of this function had some special case logic, // which is no longer necessary. Make sure of the required effects. switch (Opcode()) {
*** 491,501 **** --- 491,511 ---- : in_type; } else { result = my_type->cast_to_ptr_type( my_type->join_ptr(in_ptr) ); } } return result; + + // This is the code from TypePtr::xmeet() that prevents us from + // having 2 ways to represent the same type. We have to replicate it + // here because we don't go through meet/join. + if (result->remove_speculative() == result->speculative()) { + result = result->remove_speculative(); + } + + // Same as above: because we don't go through meet/join, remove the + // speculative type if we know we won't use it. + return result->cleanup_speculative(); // JOIN NOT DONE HERE BECAUSE OF INTERFACE ISSUES. // FIX THIS (DO THE JOIN) WHEN UNION TYPES APPEAR! //

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