RFR: 8306667: RISC-V: Fix storeImmN0 matching rule by using zr register

Guoxiong Li gli at openjdk.org
Fri May 12 01:03:57 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

LGTM

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

Marked as reviewed by gli (Committer).

PR Review: https://git.openjdk.org/jdk/pull/13577#pullrequestreview-1423631219


More information about the hotspot-compiler-dev mailing list