[jdk11u-dev] Integrated: JDK-8282589: runtime/ErrorHandling/ErrorHandler.java fails on MacOS aarch64 in jdk 11
Thomas Stuefe
stuefe at openjdk.java.net
Fri Mar 11 07:41:40 UTC 2022
On Mon, 28 Feb 2022 13:52:08 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:
> In JDK 11 only, we see errors in runtime/ErrorHandling/ErrorHandler.java. The test induces an artificial (but real) segfault and checks the VMs reaction to it (that the hs-err file is written correctly and contains expected output).
>
> The test does this by reading from `char* p = NULL;`. This is not guaranteed to work, and does not in this case: the process gets a "BPT/Trap" message instead and dies.
>
> This code (`VMError::controlled_crash()`) has been streamlined and rewritten for later releases, and there we consistently use a known non-null address to invalid memory instead, which seems to work reliably for MacOs aarch64 too.
>
> ---
>
> The patch, instead of downporting the whole reworkings of `VMError::controlled_crash`, just reuses the code which checks a segfault against a non-null invalid address. That way we do the same as newer releases, but with minimal changes.
This pull request has now been integrated.
Changeset: 51b45e74
Author: Thomas Stuefe <stuefe at openjdk.org>
URL: https://git.openjdk.java.net/jdk11u-dev/commit/51b45e740caba64e8369e57f30fa065595148d07
Stats: 10 lines in 2 files changed: 6 ins; 3 del; 1 mod
8282589: runtime/ErrorHandling/ErrorHandler.java fails on MacOS aarch64 in jdk 11
Reviewed-by: vkempik
-------------
PR: https://git.openjdk.java.net/jdk11u-dev/pull/842
More information about the jdk-updates-dev
mailing list