RFR: JDK-8305507 Add support for grace period before AbortVMOnSafepointTimeout triggers [v2]
pete23hsbc
duke at openjdk.org
Mon Jul 3 10:52:58 UTC 2023
On Mon, 8 May 2023 06:52:38 GMT, David Holmes <dholmes at openjdk.org> wrote:
>> Wojciech Kudla has updated the pull request incrementally with one additional commit since the last revision:
>>
>> Simplified getting elapsed time since VM start, added test case for -XX:AbortVMOnSafepointTimeoutDelay
>
> test/hotspot/jtreg/runtime/Safepoint/TestAbortVMOnSafepointTimeout.java line 81:
>
>> 79: OutputAnalyzer output = new OutputAnalyzer(pb.start());
>> 80: output.shouldContain(TestWithDelay.PRE_STALL_TEXT);
>> 81: verifyAbortVmApplied(output);
>
> Surely in this case there is no abort ??? Otherwise how are you actually testing the delay?
@dholmes-ora I've read through the Test and think I now understand it, don't believe it needs a change but maybe I've missed something.
Process is started with 1500ms arming delay and 50ms safepoint timeout, with abort on timeout set.
A 999ms pause is induced. This would trigger the timeout and hence abort, but we are still within the arming delay window. We output PRE_STALL_TEXT so that the test can verify the arming delay succeeded. (tested on line 80).
A further 999ms pause is induced. This will take us past the end of the arming delay and therefore should trigger the VM abort. This is why we still expect the VM to abort (tested line 81).
tl;dr The test is checking that the abort timeout is initially disarmed, and also that it is correctly rearmed, hence why we still get an abort.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/13386#discussion_r1250690049
More information about the hotspot-runtime-dev
mailing list