RFR: 8231943: ZGC: Enable serviceability/dcmd/gc/RunGCTest
Per Liden
per.liden at oracle.com
Wed Oct 16 10:27:32 UTC 2019
Hi Thomas,
On 10/16/19 10:07 AM, Thomas Schatzl wrote:
> Hi,
>
> On 07.10.19 14:38, Per Liden wrote:
>> This test is currently disabled for ZGC, but it can easily be enabled
>> by adjusting the expected log string. ZGC doesn't print "Pause Full",
>> but it still prints the "(Diagnostic Command)" part.
>>
> Not sure if that checking only for that satisfies the requirements of
> the test. I mean that this is a test to verify that jcmd executes (or
> starts) a GC. I do not think checking for "(Diagnostic Command)" is
> enough - it could be any diagnostic command that could be executed.
I don't think that's quite true, since the file we're greping in is the
GC log (not stdout), which we know only contains stuff from gc=info. So,
only if the GC itself is printing "(Diagnostic Command)" on gc=info
level somewhere else is this a problem, which I would find somewhat
surprising, no?
>
> What does ZGC print here? Can the check be made more specific?
"Garbage Collection (Diagnostic Command)"
I opted to search for just "(Diagnostic Command)" mainly to keep the
test GC agnostic. I don't have a strong opinion, but I don't believe
making more specific greps will make the test more robust in practice,
for the reason described above.
cheers,
Per
>
>> Also, the test enables gc=debug logging, which is unnecessary since
>> this is always printed on the gc=info level.
>>
>> Bug: https://bugs.openjdk.java.net/browse/JDK-8231943
>> Webrev: http://cr.openjdk.java.net/~pliden/8231943/webrev.0
>>
>
> Thanks,
> Thomas
More information about the hotspot-gc-dev
mailing list