Skip to content

Conversation

@JasonFengJ9
Copy link
Member

@JasonFengJ9 JasonFengJ9 commented Sep 18, 2025

Valhalla support to merge latest OpenJDK contents

Updated Access APIs according to Valhalla JavaLangAccess;
Added Unsafe.getAndSetReference/getAndSetReferenceAcquire/getAndSetReferenceRelease/notifyStrictStaticAccess stub methods;
Removed Unsafe.uninitializedDefaultValue/newArrayInstance;
Removed @ImplicitlyConstructible;
Removed JVM_IsImplicitlyConstructibleClass/JVM_NewNullRestrictedArray;
Added JVM_CopyOfSpecialArray/JVM_IsAtomicArray/JVM_NewNullRestrictedNonAtomicArray stub methods;
Updated VALUE_TYPES_MAJOR_VERSION;
Replaced ValueClass.newNullRestrictedArray() with ValueClass.newNullRestrictedAtomicArray();
Added @Strict annotations;
Removed CheckedType/NormalCheckedType/NullRestrictedCheckedType, ValueClass isImplicitlyConstructible` references;
Disabled tests expecting implicitly constructible classes as inputs;
Keep the array initialization temporarily;
Updated test build setup.

Related to

A personal build JDKnext_x86-64_linux_valhalla

Co-authored-by: Theresa Mammarella Theresa.T.Mammarella@ibm.com
Signed-off-by: Jason Feng fengj@ca.ibm.com

@JasonFengJ9
Copy link
Member Author

@theresa-m could you have a look?

Copy link
Contributor

@theresa-m theresa-m left a comment

Choose a reason for hiding this comment

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

It looks like ValueClass.newNullRestrictedArray has been replaced by ValueClass.newNullRestrictedAtomicArray and ValueClass.newNullRestrictedNonAtomicArray. Instead of removing the tests that rely on newNullRestrictedArray I suggest replacing them all with newNullRestrictedAtomicArray for now. Once newNullRestrictedNonAtomicArray is implemented the tests can be updated to use the correct one.

Copy link
Contributor

@theresa-m theresa-m left a comment

Choose a reason for hiding this comment

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

@a7ehuo can you take a look at the jit related changes and tests?

@theresa-m theresa-m requested a review from a7ehuo September 29, 2025 17:18
@JasonFengJ9 JasonFengJ9 requested a review from theresa-m October 2, 2025 13:08
@JasonFengJ9 JasonFengJ9 marked this pull request as ready for review October 2, 2025 13:08
@JasonFengJ9 JasonFengJ9 requested a review from dsouzai as a code owner October 2, 2025 13:08
@JasonFengJ9 JasonFengJ9 requested a review from keithc-ca October 2, 2025 13:08
@keithc-ca
Copy link
Contributor

Please open a pull request at https://github.com/ibmruntimes/openj9-openjdk-jdk.valuetypes with the content required for this change.

@theresa-m
Copy link
Contributor

There are more tests that can be enabled. The flattened field tests should mostly work except those that relied on classes with the implicit creation annotation. Something like theresa-m@119430d

@JasonFengJ9 JasonFengJ9 force-pushed the valhalla26 branch 2 times, most recently from 581fdac to 10366c7 Compare October 3, 2025 12:43
@JasonFengJ9 JasonFengJ9 requested a review from keithc-ca October 3, 2025 12:45
@keithc-ca
Copy link
Contributor

I think this looks good, but I'd like to hear from @theresa-m, especially with respect to the test code.

When everyone is happy, this should be rebased to avoid implicit merges.

Copy link
Contributor

@theresa-m theresa-m left a comment

Choose a reason for hiding this comment

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

Looks good to me. Thanks for making these changes.

@JasonFengJ9
Copy link
Member Author

@hzongaro could you review the JIT change?

@keithc-ca
Copy link
Contributor

@hzongaro - A friendly reminder that this awaits your review.

could you review the JIT change?

Copy link
Member

@hzongaro hzongaro left a comment

Choose a reason for hiding this comment

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

Sorry for my delay in reviewing these changes. I'm approving the JIT changes, and I have opened a follow up issue #22769 for someone on the JIT team to go back and add JIT recognition of newly introduced methods for creating non-atomic arrays, etc.

@keithc-ca
Copy link
Contributor

Please rebase to avoid implicit merges.

Updated Access APIs according to Valhalla JavaLangAccess;
Added Unsafe.getAndSetReference/getAndSetReferenceAcquire/getAndSetReferenceRelease/notifyStrictStaticAccess
stub methods;
Removed Unsafe.uninitializedDefaultValue/newArrayInstance;
Removed @ImplicitlyConstructible;
Removed JVM_IsImplicitlyConstructibleClass/JVM_NewNullRestrictedArray;
Added JVM_CopyOfSpecialArray/JVM_IsAtomicArray/JVM_NewNullRestrictedNonAtomicArray
stub methods;
Updated VALUE_TYPES_MAJOR_VERSION;
Replaced ValueClass.newNullRestrictedArray() with
ValueClass.newNullRestrictedAtomicArray();
Added @strict annotations;
Removed CheckedType/NormalCheckedType/NullRestrictedCheckedType,
ValueClass isImplicitlyConstructible references;
Disabled tests expecting implicitly constructible classes as inputs;
Keep the array initialization temporarily;
Updated test build setup.

Co-authored-by: Theresa Mammarella <Theresa.T.Mammarella@ibm.com>
Signed-off-by: Jason Feng <fengj@ca.ibm.com>
@JasonFengJ9
Copy link
Member Author

Rebased

@keithc-ca
Copy link
Contributor

Jenkins test sanity amac jdk25,jdknext

@JasonFengJ9
Copy link
Member Author

https://openj9-jenkins.osuosl.org/job/Test_openjdknext_j9_sanity.functional_aarch64_mac_Personal_testList_0/51/consoleFull
https://openj9-jenkins.osuosl.org/job/Test_openjdknext_j9_sanity.functional_aarch64_mac_Personal_testList_1/51/consoleFull

15:35:06  Testing: JFR File name test - approx 5mins
15:35:26  ---TEST RESULTS---
15:35:26  Number of PASSED tests: 11 out of 12
15:35:26  Number of FAILED tests: 1 out of 12
15:35:26  
15:35:26  JFR File name test - approx 5mins
15:35:26  cmdLineTester_jfr_0_FAILED

15:22:36  ---TEST RESULTS---
15:22:36  Number of PASSED tests: 12 out of 13
15:22:36  Number of FAILED tests: 1 out of 13
15:22:36  
15:22:36  ---SUMMARY OF FAILED TESTS---
15:22:36  runWorkload - approx 300 seconds
15:22:36  -----------------------------
15:22:36  
15:22:36  -----------------------------------
15:22:36  cmdLineTester_jfrEvents_0_FAILED

This is #22746

@keithc-ca keithc-ca merged commit fa79456 into eclipse-openj9:master Oct 14, 2025
6 of 9 checks passed
@JasonFengJ9 JasonFengJ9 deleted the valhalla26 branch October 14, 2025 23:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants