RFR: 8306667: RISC-V: Fix storeImmN0 matching rule by using zr register
Aleksey Shipilev
shade at openjdk.org
Thu May 11 23:16:46 UTC 2023
On Fri, 21 Apr 2023 10:16:44 GMT, Xiaolin Zheng <xlinzheng at openjdk.org> wrote:
> The `storeImmN0` in the RISC-V backend missed a `CompressedOops::base() == NULL` predication. Under non-zero-based compressed oops mode, the `xheapbase` can be a non-zero value and crashes the VM.
>
> Reproduced by `<JDK>/bin/java -Xcomp -XX:HeapBaseMinAddress=72030M -version` simply. A hs_err file is attached in the JBS issue.
>
> x86 uses `r12` as a zero register in `storeImmN0`, but RISC-V has a zero register so we can use it to implement the matching rule.
>
> Testing in progress.
>
> Thanks,
> Xiaolin
Looks reasonable.
-------------
Marked as reviewed by shade (Reviewer).
PR Review: https://git.openjdk.org/jdk/pull/13577#pullrequestreview-1395788527
More information about the hotspot-compiler-dev
mailing list