Integrated: 8261916: gtest/GTestWrapper.java vmErrorTest.unimplemented1_vm_assert failed

David Holmes dholmes at openjdk.java.net
Mon Mar 15 23:14:09 UTC 2021


On Mon, 15 Mar 2021 06:26:23 GMT, David Holmes <dholmes at openjdk.org> wrote:

> Please see bug report for gory details.
> 
> For the specific issue here of the vm_assert gtests I propose to make two changes to the VM:
> 
> 1. When core dumps are disabled, os::abort should call ::_exit not ::exit, as the former more closely models the abrupt termination of ::abort() but without the core dump.
> 
> 2. The race condition when SupressFatalErrorMessages is true is fixed by placing the check after the atomic set/check of the thread-id. That way only a single thread can trigger the fatal error processing. 
> 
> I was debating whether to make a slight change so that even when SuppressFatalErrorMessage is true, secondary failures will report that such an error occurred but not with any details. But I've left the existing silence for now. It is possible someone uses the flag to hide a message I would like to expose. I suppose adding additional output in debug builds only may be an option - options welcomed.
> 
> Testing:
>  - fully manual
> 
> I manually set up the conditions where a background thread could crash due to the atexit actions executing. I added special debug code to show what was happening in such cases, and that secondary errors were occurring. I then applied the fix for #2 and saw the second thread getting caught; then I applied fix #1 and the secondary crashes were gone.
> 
> Also did tier 1-3 testing and local gtest testing just to sanity check things.
> 
> Thanks,
> David

This pull request has now been integrated.

Changeset: 8c1112a6
Author:    David Holmes <dholmes at openjdk.org>
URL:       https://git.openjdk.java.net/jdk/commit/8c1112a6
Stats:     31 lines in 2 files changed: 20 ins; 3 del; 8 mod

8261916: gtest/GTestWrapper.java vmErrorTest.unimplemented1_vm_assert failed

Reviewed-by: dcubed, coleenp

-------------

PR: https://git.openjdk.java.net/jdk/pull/3002


More information about the hotspot-runtime-dev mailing list