RFR: 8338139: {ClassLoading, Memory}MXBean::isVerbose methods are inconsistent with their setVerbose methods [v2]
Stefan Karlsson
stefank at openjdk.org
Mon Aug 19 19:56:26 UTC 2024
On Mon, 19 Aug 2024 16:43:59 GMT, Daniel D. Daugherty <dcubed at openjdk.org> wrote:
>> src/hotspot/share/services/memoryService.cpp line 218:
>>
>>> 216:
>>> 217: return false;
>>> 218: }
>>
>> If we have `-Xlog:gc` and `-Xlog:gc+foo` set I think this version of
>> `MemoryService::get_verbose()` will return `false`. Is that really
>> what we want?
>
> Update: Looks like the CSR says that's exactly what we want.
Wait. This is not what the implementation does. If you specify -Xlog:gc and -Xlog:gc+init (using a real tag instead of foo), `get_verbose` will return true. It only cares about the tag set that is exactly 'gc' and ignores the 'gc+init' tag set.
I'm adding a test line to show that.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/20628#discussion_r1722277276
More information about the serviceability-dev
mailing list