RFR: 8366483: ShowRegistersOnAssertTest uses wrong register pattern string for Windows on AArch64

David Holmes dholmes at openjdk.org
Mon Sep 1 07:05:44 UTC 2025


On Sun, 31 Aug 2025 03:48:18 GMT, Saint Wesonga <duke at openjdk.org> wrote:

> ShowRegistersOnAssertTest.java verifies that registers are printed in the error log when VMError::controlled_crash() is called. However, it searches for the pattern "R0=", which is valid on Linux AArch64 only. The Windows AArch64 [os::print_context](https://github.com/openjdk/jdk/blob/999761d0f6d37c9cd6ec482620800b694c5fb9ad/src/hotspot/os_cpu/windows_aarch64/os_windows_aarch64.cpp#L184-L186) implementation outputs registers in the format "X0 =". This change updates the test to use this pattern on the Windows AArch64 platform. The test passes with this change.

Seems okay.

I have to ask though: why are the registers labelled X instead of R?

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

Marked as reviewed by dholmes (Reviewer).

PR Review: https://git.openjdk.org/jdk/pull/27022#pullrequestreview-3172328000


More information about the hotspot-runtime-dev mailing list