JDK-8334843 : RISC-V: Fix wraparound checking for r_array_index in lookup_secondary_supers_table_slow_path
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 24
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: linux
  • CPU: riscv
  • Submitted: 2024-06-24
  • Updated: 2024-07-19
  • Resolved: 2024-06-28
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 24
24 b05Fixed
Related Reports
Relates :  
Description
Branch condition for r_array_index wraparound checking in lookup_secondary_supers_table_slow_path is wrong.
```
    // Check for wraparound.
    Label skip;
    bge(r_array_length, r_array_index, skip);
    mv(r_array_index, zr);
    bind(skip);
```
As discussed at https://github.com/openjdk/jdk/pull/19320/files#r1650548279 here. If length == index, then we must set index to 0. That is `blt(r_array_index,r_array_length,skip);`.
Comments
A pull request was submitted for review. Branch: master URL: https://git.openjdk.org/jdk/pull/19852 Date: 2024-06-24 09:25:31 +0000
19-07-2024

Changeset: cd46c87d Author: Gui Cao <gcao@openjdk.org> Committer: Fei Yang <fyang@openjdk.org> Date: 2024-06-28 01:44:14 +0000 URL: https://git.openjdk.org/jdk/commit/cd46c87dc916b2b74067accf80c62df1792f74cf
28-06-2024