RFR: 8374744: Enable dumping of APX EGPRs (R16–R31) in JVM fatal error logs [v2]
Srinivas Vamsi Parasa
sparasa at openjdk.org
Thu Jan 29 21:48:18 UTC 2026
On Fri, 16 Jan 2026 22:25:30 GMT, Sandhya Viswanathan <sviswanathan at openjdk.org> wrote:
>> Srinivas Vamsi Parasa has updated the pull request incrementally with one additional commit since the last revision:
>>
>> undo verbose code to print registers; repalce it with for loop
>
> src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp line 449:
>
>> 447: // Dump APX EGPRs (R16-R31)
>> 448: apx_state* apx = get_apx_state(uc);
>> 449: if (UseAPX && apx != nullptr) {
>
> This could be done as:
> apx_state* apx = UseAPX ? get_apx_state(uc) : nullptr;
> if (apx != nullptr) {
Please see the updated code with the suggested change.
> src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp line 469:
>
>> 467: st->print(", R30=" INTPTR_FORMAT, (intptr_t)apx->regs[14]);
>> 468: st->print(", R31=" INTPTR_FORMAT, (intptr_t)apx->regs[15]);
>> 469: st->cr();
>
> This could be done with a for loop.
Please see the new code with the for loop.
> src/hotspot/os_cpu/linux_x86/os_linux_x86.cpp line 556:
>
>> 554: CASE_PRINT_REG_APX(30, "R30=", 14); break;
>> 555: CASE_PRINT_REG_APX(31, "R31=", 15); break;
>> 556: }
>
> Don't need a switch case here. Could be achieved with something like below:
>
> st->print("R%d=", n);
> print_location(st, apx->regs[n]);
Please see the new code without the switch statement.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/29098#discussion_r2743684120
PR Review Comment: https://git.openjdk.org/jdk/pull/29098#discussion_r2743684769
PR Review Comment: https://git.openjdk.org/jdk/pull/29098#discussion_r2743685853
More information about the hotspot-dev
mailing list