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

src/share/vm/opto/type.cpp

Print this page

        

*** 294,304 **** --- 294,307 ---- TypeInstPtr::MIRROR = TypeInstPtr::make(TypePtr::NotNull, current->env()->Class_klass()); TypeInstPtr::MARK = TypeInstPtr::make(TypePtr::BotPTR, current->env()->Object_klass(), false, 0, oopDesc::mark_offset_in_bytes()); TypeInstPtr::KLASS = TypeInstPtr::make(TypePtr::BotPTR, current->env()->Object_klass(), false, 0, oopDesc::klass_offset_in_bytes()); + TypeOopPtr::BOTTOM = TypeOopPtr::make(TypePtr::BotPTR, OffsetBot); + // Type used for new CheckCastPP node in Object.clone() intrinsic. + TypeOopPtr::NOTNULL = TypeOopPtr::make(TypePtr::NotNull, 0); TypeNarrowOop::NULL_PTR = TypeNarrowOop::make( TypePtr::NULL_PTR ); TypeNarrowOop::BOTTOM = TypeNarrowOop::make( TypeInstPtr::BOTTOM ); mreg2type[Op_Node] = Type::BOTTOM;
*** 2169,2178 **** --- 2172,2182 ---- } #endif //============================================================================= // Convenience common pre-built type. + const TypeOopPtr *TypeOopPtr::NOTNULL; const TypeOopPtr *TypeOopPtr::BOTTOM; //------------------------------TypeOopPtr------------------------------------- TypeOopPtr::TypeOopPtr( TYPES t, PTR ptr, ciKlass* k, bool xk, ciObject* o, int offset, int instance_id ) : TypePtr(t, ptr, offset),
*** 2234,2249 **** #endif } //------------------------------make------------------------------------------- const TypeOopPtr *TypeOopPtr::make(PTR ptr, ! int offset) { assert(ptr != Constant, "no constant generic pointers"); ciKlass* k = ciKlassKlass::make(); bool xk = false; ciObject* o = NULL; ! return (TypeOopPtr*)(new TypeOopPtr(OopPtr, ptr, k, xk, o, offset, InstanceBot))->hashcons(); } //------------------------------cast_to_ptr_type------------------------------- const Type *TypeOopPtr::cast_to_ptr_type(PTR ptr) const { --- 2238,2253 ---- #endif } //------------------------------make------------------------------------------- const TypeOopPtr *TypeOopPtr::make(PTR ptr, ! int offset, int instance_id) { assert(ptr != Constant, "no constant generic pointers"); ciKlass* k = ciKlassKlass::make(); bool xk = false; ciObject* o = NULL; ! return (TypeOopPtr*)(new TypeOopPtr(OopPtr, ptr, k, xk, o, offset, instance_id))->hashcons(); } //------------------------------cast_to_ptr_type------------------------------- const Type *TypeOopPtr::cast_to_ptr_type(PTR ptr) const {
*** 2328,2338 **** } } case OopPtr: { // Meeting to other OopPtrs const TypeOopPtr *tp = t->is_oopptr(); ! return make( meet_ptr(tp->ptr()), meet_offset(tp->offset()) ); } case InstPtr: // For these, flip the call around to cut down case KlassPtr: // on the cases I have to handle. case AryPtr: --- 2332,2343 ---- } } case OopPtr: { // Meeting to other OopPtrs const TypeOopPtr *tp = t->is_oopptr(); ! int instance_id = meet_instance_id(tp->instance_id()); ! return make( meet_ptr(tp->ptr()), meet_offset(tp->offset()), instance_id ); } case InstPtr: // For these, flip the call around to cut down case KlassPtr: // on the cases I have to handle. case AryPtr:
*** 2799,2809 **** } } case OopPtr: { // Meeting to OopPtrs // Found a OopPtr type vs self-InstPtr type ! const TypePtr *tp = t->is_oopptr(); int offset = meet_offset(tp->offset()); PTR ptr = meet_ptr(tp->ptr()); switch (tp->ptr()) { case TopPTR: case AnyNull: { --- 2804,2814 ---- } } case OopPtr: { // Meeting to OopPtrs // Found a OopPtr type vs self-InstPtr type ! const TypeOopPtr *tp = t->is_oopptr(); int offset = meet_offset(tp->offset()); PTR ptr = meet_ptr(tp->ptr()); switch (tp->ptr()) { case TopPTR: case AnyNull: {
*** 2810,2821 **** int instance_id = meet_instance_id(InstanceTop); return make(ptr, klass(), klass_is_exact(), (ptr == Constant ? const_oop() : NULL), offset, instance_id); } case NotNull: ! case BotPTR: ! return TypeOopPtr::make(ptr, offset); default: typerr(t); } } case AnyPtr: { // Meeting to AnyPtrs --- 2815,2828 ---- int instance_id = meet_instance_id(InstanceTop); return make(ptr, klass(), klass_is_exact(), (ptr == Constant ? const_oop() : NULL), offset, instance_id); } case NotNull: ! case BotPTR: { ! int instance_id = meet_instance_id(tp->instance_id()); ! return TypeOopPtr::make(ptr, offset, instance_id); ! } default: typerr(t); } } case AnyPtr: { // Meeting to AnyPtrs
*** 3257,3267 **** default: // All else is a mistake typerr(t); case OopPtr: { // Meeting to OopPtrs // Found a OopPtr type vs self-AryPtr type ! const TypePtr *tp = t->is_oopptr(); int offset = meet_offset(tp->offset()); PTR ptr = meet_ptr(tp->ptr()); switch (tp->ptr()) { case TopPTR: case AnyNull: { --- 3264,3274 ---- default: // All else is a mistake typerr(t); case OopPtr: { // Meeting to OopPtrs // Found a OopPtr type vs self-AryPtr type ! const TypeOopPtr *tp = t->is_oopptr(); int offset = meet_offset(tp->offset()); PTR ptr = meet_ptr(tp->ptr()); switch (tp->ptr()) { case TopPTR: case AnyNull: {
*** 3268,3279 **** int instance_id = meet_instance_id(InstanceTop); return make(ptr, (ptr == Constant ? const_oop() : NULL), _ary, _klass, _klass_is_exact, offset, instance_id); } case BotPTR: ! case NotNull: ! return TypeOopPtr::make(ptr, offset); default: ShouldNotReachHere(); } } case AnyPtr: { // Meeting two AnyPtrs --- 3275,3288 ---- int instance_id = meet_instance_id(InstanceTop); return make(ptr, (ptr == Constant ? const_oop() : NULL), _ary, _klass, _klass_is_exact, offset, instance_id); } case BotPTR: ! case NotNull: { ! int instance_id = meet_instance_id(tp->instance_id()); ! return TypeOopPtr::make(ptr, offset, instance_id); ! } default: ShouldNotReachHere(); } } case AnyPtr: { // Meeting two AnyPtrs
src/share/vm/opto/type.cpp
Index Unified diffs Context diffs Sdiffs Wdiffs Patch New Old Previous File Next File