RFR: 8194312: Support parallel and concurrent JNI global handle processing
serguei.spitsyn at oracle.com
serguei.spitsyn at oracle.com
Tue Jan 9 03:57:21 UTC 2018
On 1/8/18 16:58, Kim Barrett wrote:
>> On Jan 8, 2018, at 7:20 PM, serguei.spitsyn at oracle.com wrote:
>>
>> Hi Kim,
>>
>> A couple of quick minor comments.
> Thanks.
>
>> http://cr.openjdk.java.net/~kbarrett/8194312/open.00/src/jdk.hotspot.agent/share/classes/sun/jvm/hotspot/utilities/PointerLocation.java.frames.html
>> 241 } else if (isInStrongGlobalJNIHandles() ||
>> 242 isInWeakGlobalJNIHandles()) {
>>
>> 243 tty.print("In ");
>>
>> 244 if (isInStrongGlobalJNIHandles()) {
>>
>> 245 tty.print("strong global");
>>
>> 246 } else if (isInWeakGlobalJNIHandles()) {
>>
>> 247 tty.print("weak global");
>> 248 }
>>
>> A suggestion to simplify it a little bit as follows:
>> } else if (isInStrongGlobalJNIHandles()) {
>>
>> tty.print("In strong global");
>>
>> } else if (isInWeakGlobalJNIHandles()) {
>>
>> tty.print("In weak global");
>> }
> Good idea. Will do.
>
>> http://cr.openjdk.java.net/~kbarrett/8194312/open.00/src/hotspot/share/gc/shared/oopStorage.cpp.html
>> 61 void OopStorage::BlockList::push_back(const Block& block) {
>> 62 const Block* old = _tail;
>> 63 if (old == NULL) {
>> 64 assert(_tail == NULL, "invariant");
>> 65 _head = _tail = █
>> 66 } else {
>> 67 _get_entry(*old)._next = █
>> 68 _get_entry(block)._prev = old;
>> 69 _tail = █
>> 70 }
>> 71 }
>>
>> It seems, the assert should check _head instead of _tail.
> Oops! Will do.
Thanks!
Also, this fragment looks strange:
354 if (block->is_empty()) {
355 log_debug(oopstorage, blocks)("%s: block not empty " PTR_FORMAT, name(), p2i(block));
356 --_empty_block_count;
357 }
Should the message tell "block is empty" instead of "block not empty"?
Thanks,
Serguei
More information about the hotspot-dev
mailing list