Skip to content

Align Unsafe.arrayLayout(Object[] array) for Valhalla compatibility#24286

Open
konark2010 wants to merge 1 commit into
eclipse-openj9:masterfrom
konark2010:valhalla-change-match
Open

Align Unsafe.arrayLayout(Object[] array) for Valhalla compatibility#24286
konark2010 wants to merge 1 commit into
eclipse-openj9:masterfrom
konark2010:valhalla-change-match

Conversation

@konark2010

@konark2010 konark2010 commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Replace Unsafe.arrayLayout(Class<?>) with arrayLayout(Object[]) and updated its usage to align with the change

Fixes: #24249

This PR has to be aligned with this PR to avoid failures

@konark2010

Copy link
Copy Markdown
Contributor Author

@theresa-m and @hangshao0 please review

@theresa-m

Copy link
Copy Markdown
Contributor

@konark2010 do you have a personal build to show that this is working with the Valhalla unsafe tests?

@hangshao0 hangshao0 added comp:vm project:valhalla Used to track Project Valhalla related work labels Jul 3, 2026
@konark2010

Copy link
Copy Markdown
Contributor Author

@konark2010 do you have a personal build to show that this is working with the Valhalla unsafe tests?

No I do not have any build for it but will do it now

@konark2010

Copy link
Copy Markdown
Contributor Author

@theresa-m

Copy link
Copy Markdown
Contributor

https://hyc-runtimes-jenkins.swg-devops.com/job/Build_JDKnext_x86-64_linux_valhalla_Personal/608/

You need to add your repos and branches as well under OPENJ9_REPO/OPENJ9_BRANCH and OPENJDK_REPO/OPENJDK_BRANCH.

@konark2010 konark2010 force-pushed the valhalla-change-match branch 2 times, most recently from e7f4b12 to dc3c445 Compare July 8, 2026 20:26
@hangshao0

Copy link
Copy Markdown
Contributor

https://hyc-runtimes-jenkins.swg-devops.com/job/Build_JDKnext_x86-64_linux_valhalla_Personal/608/

You need to add your repos and branches as well under OPENJ9_REPO/OPENJ9_BRANCH and OPENJDK_REPO/OPENJDK_BRANCH.

@konark2010 Do you have an updated and passed personal build ?

@konark2010

Copy link
Copy Markdown
Contributor Author

https://hyc-runtimes-jenkins.swg-devops.com/job/Build_JDKnext_x86-64_linux_valhalla_Personal/608/

You need to add your repos and branches as well under OPENJ9_REPO/OPENJ9_BRANCH and OPENJDK_REPO/OPENJDK_BRANCH.

@konark2010 Do you have an updated and passed personal build ?

I have an another build but it got fail in some tests, so I am working on their fix

@konark2010 konark2010 force-pushed the valhalla-change-match branch 2 times, most recently from d1a8e2e to e5e79ff Compare July 13, 2026 16:33
@konark2010

Copy link
Copy Markdown
Contributor Author

@konark2010 konark2010 marked this pull request as ready for review July 13, 2026 19:40
@theresa-m

Copy link
Copy Markdown
Contributor

Please update the description to accurately describe the change. There is only one arrayLayout method so there is no overloading here.

@konark2010 konark2010 force-pushed the valhalla-change-match branch from e5e79ff to 81be944 Compare July 14, 2026 16:56
@konark2010

Copy link
Copy Markdown
Contributor Author

@theresa-m done with the changes in the issue description and commit body

Comment thread jcl/src/java.base/share/classes/jdk/internal/misc/Unsafe.java Outdated
Replace Unsafe.arrayLayout(Class<?> arrayClass) with
Unsafe.arrayLayout(Object[] array) to match the
Valhalla changes. Update the Valhalla functional test
to use the updated method signature.

Fixes: eclipse-openj9#24249

Signed-off-by: Konark Shah <Konarkshah2010@gmail.com>
@konark2010 konark2010 force-pushed the valhalla-change-match branch from c331a01 to 0d387fe Compare July 14, 2026 19:07
@konark2010 konark2010 requested a review from hangshao0 July 14, 2026 19:07
@hangshao0

Copy link
Copy Markdown
Contributor

Jenkins test sanity.functional,extended zlinuxval jdknext

@hangshao0

hangshao0 commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

@konark2010 The PR build failed.

@konark2010

Copy link
Copy Markdown
Contributor Author

@konark2010 The PR build failed.

will look onto it but it is strange as the personal build was passing

@hangshao0

Copy link
Copy Markdown
Contributor

it is strange as the personal build was passing

Your personal build runs sanity.functional tests only. The PR build fails at extended.functional tests.

@theresa-m

Copy link
Copy Markdown
Contributor

Those failures are related to #23827

@hangshao0

Copy link
Copy Markdown
Contributor

Those failures are related to #23827

OK, good to know. Pls open an issue for that.

@theresa-m

Copy link
Copy Markdown
Contributor

#24364

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

Labels

comp:vm project:valhalla Used to track Project Valhalla related work

Projects

Status: TODO: VM

Development

Successfully merging this pull request may close these issues.

OpenJ9 doesn't have Unsafe.arrayLayout(Object[] array)

3 participants