Skip to content

8387252: [lworld] LoadFlattenedArrayStub may not consider the spill inserted by RA#2579

Open
zifeihan wants to merge 1 commit into
openjdk:lworldfrom
zifeihan:JDK-8387252
Open

8387252: [lworld] LoadFlattenedArrayStub may not consider the spill inserted by RA#2579
zifeihan wants to merge 1 commit into
openjdk:lworldfrom
zifeihan:JDK-8387252

Conversation

@zifeihan

@zifeihan zifeihan commented Jun 24, 2026

Copy link
Copy Markdown
Member

Hi, as discussed here, openjdk/jdk#31122 (comment)

I think there's a bug here. Although this issue occurs on RISC-V, we can see that this spill was automatically inserted by RA; we didn't perform any operations manually.
And maybe the reason of a spill move [c_rarg5|L] [stack:10|L] inserted by RA is probably because the registers are under a lot of pressure at this stage.
I created a new issue to track https://bugs.openjdk.org/browse/JDK-8387252, and I'll try to reproduce this bug on other architectures.



Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed (1 review required, with at least 1 Committer)

Issue

  • JDK-8387252: [lworld] LoadFlattenedArrayStub may not consider the spill inserted by RA (Bug - P3)

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/valhalla.git pull/2579/head:pull/2579
$ git checkout pull/2579

Update a local copy of the PR:
$ git checkout pull/2579
$ git pull https://git.openjdk.org/valhalla.git pull/2579/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 2579

View PR using the GUI difftool:
$ git pr show -t 2579

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/valhalla/pull/2579.diff

Using Webrev

Link to Webrev Comment

@bridgekeeper

bridgekeeper Bot commented Jun 24, 2026

Copy link
Copy Markdown

👋 Welcome back gcao! A progress list of the required criteria for merging this PR into lworld will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk

openjdk Bot commented Jun 24, 2026

Copy link
Copy Markdown

❗ This change is not yet ready to be integrated.
See the Progress checklist in the description for automated requirements.

@openjdk openjdk Bot added the rfr Pull request is ready for review label Jun 24, 2026
@mlbridge

mlbridge Bot commented Jun 24, 2026

Copy link
Copy Markdown

Webrevs

// Otherwise, the RA may insert a spill at the load's def point
// (inside the conditional code), and the stub's continuation jump
// would skip that spill, leaving the spill slot stale.
load_result = new_register(T_OBJECT);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't the rlock_result just above in line 2381 do exactly that?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

rfr Pull request is ready for review

Development

Successfully merging this pull request may close these issues.

2 participants