< prev index next >

src/hotspot/share/prims/jvmtiTagMap.cpp

Print this page

        

*** 102,112 **** assert(tag != 0, "can't be zero"); _tag = tag; } inline bool equals(oop object) { ! return object == object_peek(); } inline JvmtiTagHashmapEntry* next() const { return _next; } inline void set_next(JvmtiTagHashmapEntry* next) { _next = next; } }; --- 102,112 ---- assert(tag != 0, "can't be zero"); _tag = tag; } inline bool equals(oop object) { ! return oopDesc::equals(object, object_peek()); } inline JvmtiTagHashmapEntry* next() const { return _next; } inline void set_next(JvmtiTagHashmapEntry* next) { _next = next; } };
*** 183,192 **** --- 183,193 ---- static unsigned int hash(oop key, int size) { ZGC_ONLY(assert(ZAddressMetadataShift >= sizeof(unsigned int) * BitsPerByte, "cast removes the metadata bits");) // shift right to get better distribution (as these bits will be zero // with aligned addresses) + key = Access<>::resolve(key); unsigned int addr = (unsigned int)(cast_from_oop<intptr_t>(key)); #ifdef _LP64 return (addr >> 3) % size; #else return (addr >> 2) % size;
< prev index next >