equal
deleted
inserted
replaced
160 template class ValueRecorder<Metadata*>; |
160 template class ValueRecorder<Metadata*>; |
161 template class ValueRecorder<jobject>; |
161 template class ValueRecorder<jobject>; |
162 |
162 |
163 oop ObjectLookup::ObjectEntry::oop_value() const { return JNIHandles::resolve(_value); } |
163 oop ObjectLookup::ObjectEntry::oop_value() const { return JNIHandles::resolve(_value); } |
164 |
164 |
165 ObjectLookup::ObjectLookup(): _gc_count(Universe::heap()->total_collections()), _values(4) {} |
165 ObjectLookup::ObjectLookup(): _values(4), _gc_count(Universe::heap()->total_collections()) {} |
166 |
166 |
167 void ObjectLookup::maybe_resort() { |
167 void ObjectLookup::maybe_resort() { |
168 // The values are kept sorted by address which may be invalidated |
168 // The values are kept sorted by address which may be invalidated |
169 // after a GC, so resort if a GC has occurred since last time. |
169 // after a GC, so resort if a GC has occurred since last time. |
170 if (_gc_count != Universe::heap()->total_collections()) { |
170 if (_gc_count != Universe::heap()->total_collections()) { |