Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Valhalla tests failed to compile #19459

Open
hangshao0 opened this issue May 7, 2024 · 4 comments
Open

Valhalla tests failed to compile #19459

hangshao0 opened this issue May 7, 2024 · 4 comments
Labels
comp:test project:valhalla Used to track Project Valhalla related work

Comments

@hangshao0
Copy link
Contributor

22:11:18      [javac] Compiling 15 source files to /home/jenkins/workspace/Test_openjdkValhalla_j9_extended.functional_x86-64_linux_valhalla_Nightly_testList_0/aqa-tests/functional/Valhalla/bin
22:11:18      [javac] error: invalid source release 22 with --enable-preview
22:11:18      [javac]   (preview language features are only supported for release 23)
22:11:18  
22:11:18  BUILD FAILED

Internal build link.
With #19446 merged, we bring in the latest Valhalla changes from OpenJDK. The JDK version has been updated to 23.

Keyword primitive is removed and Q type is also removed. Any tests depending on those won't compile anymore.

There are previous work refactoring Valhalla tests #18157 to remove dependency on primitive and Q type. We can remove these tests and enable the refactored version.

@hangshao0 hangshao0 added comp:test project:valhalla Used to track Project Valhalla related work labels May 7, 2024
@hangshao0
Copy link
Contributor Author

FYI @theresa-m

@theresa-m
Copy link
Contributor

theresa-m commented May 24, 2024

At this point javac does not have support for primitive classes and qtypes. It also does not have support for nullrestricted fields so there's not a way to represent primitive/nullrestricted (in OpenJ9 generally known as flattenable types) compiled from Java with the current extensions repository.
I can remove the tests that rely on primitive in src_qtypes like you suggest and once there is javac support for nullrestricted exists we can transition to the src_lw5 tests. What do you think @hangshao0 ?

@hangshao0
Copy link
Contributor Author

At this point javac does not have support for primitive classes and qtypes. It also does not have support for nullrestricted fields so there's not a way to represent primitive/nullrestricted (in OpenJ9 generally known as flattenable types) compiled from Java with the current extensions repository.

It seems that javac is depending on annotation @ImplicitlyConstructible and @NullRestricted to generate primitive VT and null restricted fields. Have you tried these annotations in test ?

https://github.com/ibmruntimes/openj9-openjdk-jdk.valuetypes/blob/9d2b808029fc22980fcbf56b7c653423b781d1e8/test/jdk/valhalla/valuetypes/NullRestrictedTest.java#L56-L65

@theresa-m
Copy link
Contributor

No, I'll try that out. Thanks.

theresa-m added a commit to theresa-m/openj9 that referenced this issue May 30, 2024
This change is needed to support @ImplicitlyConstructible and @NullRestricted annotations for functional tests. See eclipse-openj9#19459

In this change:
- J9ROMCLASS_IS_VALUE macro checks for ACC_IDENTITY flag instead of ACC_VALUE
- Remove J9AccValueType from codebase

There is more work to be done to fully remove ACC_VALUE (eclipse-openj9#18829) such as removing CFR_ACC_VALUE and adding runtime class file verification checks. Because functional value type tests are not able to run currently due to a recent update of the extensions repository I am making just a few changes toward getting those working.

I am also removing the assert in JVM_IsNullRestrictedArray which is triggered when building OpenJ9. This method can't be implemented right now because OpenJ9 doesn't have support for null restricted arrays yet. See eclipse-openj9#17340
theresa-m added a commit to theresa-m/openj9 that referenced this issue May 30, 2024
This change is needed to support @ImplicitlyConstructible and @NullRestricted annotations for functional tests. See eclipse-openj9#19459

In this change:
- J9ROMCLASS_IS_VALUE macro checks for ACC_IDENTITY flag instead of ACC_VALUE
- Remove J9AccValueType from codebase

There is more work to be done to fully remove ACC_VALUE (eclipse-openj9#18829) such as removing CFR_ACC_VALUE and adding runtime class file verification checks. Because functional value type tests are not able to run currently due to a recent update of the extensions repository I am making just a few changes toward getting those working.

I am also removing the assert in JVM_IsNullRestrictedArray which is triggered when building OpenJ9. This method can't be implemented right now because OpenJ9 doesn't have support for null restricted arrays yet. See eclipse-openj9#17340 eclipse-openj9#19460
theresa-m added a commit to theresa-m/openj9 that referenced this issue May 30, 2024
This change is needed to support @ImplicitlyConstructible and @NullRestricted annotations for functional tests. See eclipse-openj9#19459

In this change:
- J9ROMCLASS_IS_VALUE macro checks for ACC_IDENTITY flag instead of ACC_VALUE
- Remove J9AccValueType from codebase

There is more work to be done to fully remove ACC_VALUE (eclipse-openj9#18829) such as removing CFR_ACC_VALUE and adding runtime class file verification checks. Because functional value type tests are not able to run currently due to a recent update of the extensions repository I am making just a few changes toward getting those working.

I am also removing the assert in JVM_IsNullRestrictedArray which is triggered when building OpenJ9. This method can't be implemented right now because OpenJ9 doesn't have support for null restricted arrays yet. See eclipse-openj9#17340 eclipse-openj9#19460
theresa-m added a commit to theresa-m/openj9 that referenced this issue May 30, 2024
This change is needed to support @ImplicitlyConstructible and @NullRestricted annotations for functional tests. See eclipse-openj9#19459

In this change:
- J9ROMCLASS_IS_VALUE macro checks for ACC_IDENTITY flag instead of ACC_VALUE
- Remove J9AccValueType from codebase

There is more work to be done to fully remove ACC_VALUE (eclipse-openj9#18829) such as removing CFR_ACC_VALUE and adding runtime class file verification checks. Because functional value type tests are not able to run currently due to a recent update of the extensions repository I am making just a few changes toward getting those working.

I am also removing the assert in JVM_IsNullRestrictedArray which is triggered when building OpenJ9. This method can't be implemented right now because OpenJ9 doesn't have support for null restricted arrays yet. See eclipse-openj9#17340 eclipse-openj9#19460
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
comp:test project:valhalla Used to track Project Valhalla related work
Projects
None yet
Development

No branches or pull requests

2 participants