Skip to content

Commit

Permalink
Remove some value type primitive uses
Browse files Browse the repository at this point in the history
- remove J9ROMCLASS_IS_PRIMITIVE_VALUE_TYPE
- remove J9AccPrimitiveValueType

Signed-off-by: Theresa Mammarella <[email protected]>
  • Loading branch information
theresa-m committed Jul 9, 2024
1 parent 677181c commit ecb4d03
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 13 deletions.
1 change: 0 additions & 1 deletion runtime/oti/j9javaaccessflags.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@
#define J9AccInterface 0x00000200 /* class */
#define J9AccGetterMethod 0x00000200 /* method */
#define J9AccAbstract 0x00000400 /* class method */
#define J9AccPrimitiveValueType 0x00000800 /* class(Valhalla) */
#define J9AccStrict 0x00000800 /* method */
#define J9AccSynthetic 0x00001000 /* class method field */
#define J9AccAnnotation 0x00002000 /* class */
Expand Down
6 changes: 0 additions & 6 deletions runtime/oti/j9modifiers_api.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,6 @@
#define J9ROMCLASS_IS_VALUE(romClass) FALSE
#endif /* J9VM_OPT_VALHALLA_VALUE_TYPES */

#if defined(J9VM_OPT_VALHALLA_FLATTENABLE_VALUE_TYPES)
#define J9ROMCLASS_IS_PRIMITIVE_VALUE_TYPE(romClass) _J9ROMCLASS_SUNMODIFIER_IS_SET((romClass), J9AccPrimitiveValueType)
#else /* defined(J9VM_OPT_VALHALLA_FLATTENABLE_VALUE_TYPES) */
#define J9ROMCLASS_IS_PRIMITIVE_VALUE_TYPE(romClass) FALSE
#endif /* defined(J9VM_OPT_VALHALLA_FLATTENABLE_VALUE_TYPES) */

#define J9ROMMETHOD_IS_GETTER(romMethod) _J9ROMMETHOD_J9MODIFIER_IS_SET((romMethod), J9AccGetterMethod)
#define J9ROMMETHOD_IS_FORWARDER(romMethod) _J9ROMMETHOD_J9MODIFIER_IS_SET((romMethod), J9AccForwarderMethod)
#define J9ROMMETHOD_IS_EMPTY(romMethod) _J9ROMMETHOD_J9MODIFIER_IS_SET((romMethod), J9AccEmptyMethod)
Expand Down
7 changes: 1 addition & 6 deletions runtime/vm/createramclass.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2310,13 +2310,8 @@ internalCreateRAMClassDone(J9VMThread *vmThread, J9ClassLoader *classLoader, J9C
}
}
#if defined(J9VM_OPT_VALHALLA_FLATTENABLE_VALUE_TYPES)
if (J9ROMCLASS_IS_PRIMITIVE_VALUE_TYPE(romClass)
|| J9_ARE_ALL_BITS_SET(classFlags, J9ClassAllowsInitialDefaultValue)
) {
if (J9_ARE_ALL_BITS_SET(classFlags, J9ClassAllowsInitialDefaultValue)) {
UDATA instanceSize = state->ramClass->totalInstanceSize;
if (J9ROMCLASS_IS_PRIMITIVE_VALUE_TYPE(romClass)) {
classFlags |= J9ClassIsPrimitiveValueType;
}
if ((instanceSize <= javaVM->valueFlatteningThreshold)
&& !J9ROMCLASS_IS_CONTENDED(romClass)
) {
Expand Down

0 comments on commit ecb4d03

Please sign in to comment.