RFR: 8324514: ClassLoaderData::print_on should print address of class loader [v3]
Coleen Phillimore
coleenp at openjdk.org
Tue Jan 23 14:16:27 UTC 2024
On Tue, 23 Jan 2024 14:10:01 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:
>> src/hotspot/share/classfile/classLoaderData.cpp line 1006:
>>
>>> 1004: out->print_cr("");
>>> 1005: }
>>> 1006: out->print_cr(" - class loader " INTPTR_FORMAT, p2i(_class_loader.peek_raw()));
>>
>> This peek_raw feels like a dangerous addition. Could be misused(?) @kimbarrett has been looking at OopHandle, maybe he has an opinion. I can't remember why/whether we can't do a peek on an unloaded class loader. Also @fisk is the definitive source of this info (plus you guys on Shenandoah too).
>
> Yes, I suppose we did want to print the oop not the OopHandle pointer.
If not peek(), I kind of think I'd prefer the !_unloading test more than a peek_raw().
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/17534#discussion_r1463344780
More information about the hotspot-runtime-dev
mailing list