-
Notifications
You must be signed in to change notification settings - Fork 706
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
Add new method Class.isIdentity() #16041
Conversation
1. Add implementation of Class.isIdentity() 2. Update tests Closes eclipse-openj9#16027 Signed-off-by: Hang Shao <hangshao@ca.ibm.com>
For potential PR builds, the functional Valhalla tests won't compile at this moment. The compilation errors should be resolved by #16040. |
Closes #eclipse-openj9#16031 Signed-off-by: Hang Shao <hangshao@ca.ibm.com>
I've closed #16040 and moved all the changes here. |
@@ -127,6 +127,10 @@ initializeArrayROMClass(J9ROMArrayClass *romClass, J9UTF8 *className, U_32 array | |||
NNSRP_SET(romClass->className, className); | |||
NNSRP_SET(romClass->superclassName, &arrayROMClasses.objectClassName); | |||
romClass->modifiers = J9AccFinal | J9AccPublic | J9AccClassArray | J9AccAbstract; | |||
#if defined(J9VM_OPT_VALHALLA_VALUE_TYPES) | |||
/* Arrays are always identity classes. */ | |||
romClass->modifiers |= J9AccClassHasIdentity; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we add the flag for non-Arrays as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, for non-array classes it is set here:
openj9/runtime/bcutil/ClassFileOracle.cpp
Lines 817 to 819 in 52ab41f
if (_isIdentityFlagNeeded) { | |
_classFile->accessFlags |= CFR_ACC_IDENTITY; | |
} |
Jenkins test sanity,extended xlinuxval jdknext |
Jenkins test sanity win jdk8 |
Jenkins test sanity plinuxvalst jdknext |
The PR build failure is due to #16028. |
Closes #16027 #16031
Signed-off-by: Hang Shao hangshao@ca.ibm.com