@@ -73,7 +73,7 @@ MM_IndexableObjectAllocationModel::initializeAllocateDescription(MM_EnvironmentB
7373
7474 case GC_ArrayletObjectModel::InlineContiguous:
7575 /* Check if we're dealing with a camouflaged discontiguous array - these arrays will require slow-path allocate */
76- if (isVirtualLargeObjectHeapEnabled && (!extensions-> indexableObjectModel . shouldDataBeAdjacentToHeader (_dataSize) )) {
76+ if (isVirtualLargeObjectHeapEnabled && (!_isDataAdjacent )) {
7777 if (isGCAllowed ()) {
7878 layoutSizeInBytes = _dataSize;
7979 setAllocatable (true );
@@ -145,7 +145,6 @@ MM_IndexableObjectAllocationModel::initializeIndexableObject(MM_EnvironmentBase
145145 GC_ArrayObjectModel *indexableObjectModel = &extensions->indexableObjectModel ;
146146 J9IndexableObject *spine = (J9IndexableObject*)initializeJavaObject (env, allocatedBytes);
147147 _allocateDescription.setSpine (spine);
148- bool shouldDataBeAdjacentToHeader = false ;
149148 bool isVirtualLargeObjectHeapEnabled = indexableObjectModel->isVirtualLargeObjectHeapEnabled ();
150149
151150 if (NULL != spine) {
@@ -163,8 +162,7 @@ MM_IndexableObjectAllocationModel::initializeIndexableObject(MM_EnvironmentBase
163162 indexableObjectModel->setSizeInElementsForContiguous (spine, _numberOfIndexedFields);
164163#if defined(J9VM_ENV_DATA64)
165164 if (((J9JavaVM *)env->getLanguageVM ())->isIndexableDataAddrPresent ) {
166- shouldDataBeAdjacentToHeader = indexableObjectModel->shouldDataBeAdjacentToHeader (spine);
167- if (shouldDataBeAdjacentToHeader) {
165+ if (_isDataAdjacent) {
168166 indexableObjectModel->setDataAddrForContiguous (spine);
169167 } else {
170168 /* Set NULL temporarily to avoid possible complication with GC occurring while the object is partially initialized. */
@@ -179,15 +177,15 @@ MM_IndexableObjectAllocationModel::initializeIndexableObject(MM_EnvironmentBase
179177 switch (_layout) {
180178 case GC_ArrayletObjectModel::InlineContiguous:
181179#if defined(J9VM_GC_SPARSE_HEAP_ALLOCATION)
182- if (isVirtualLargeObjectHeapEnabled && !shouldDataBeAdjacentToHeader ) {
180+ if (isVirtualLargeObjectHeapEnabled && !_isDataAdjacent ) {
183181 /* We still need to create leaves for discontiguous arrays that will be allocated at off-heap. */
184182 spine = getSparseAddressAndDecommitLeaves (env, spine);
185183 if (NULL != spine) {
186184 Assert_MM_true (1 <= _numberOfArraylets);
187185 }
188186 }
189187#endif /* defined (J9VM_GC_SPARSE_HEAP_ALLOCATION) */
190- if (!isVirtualLargeObjectHeapEnabled || shouldDataBeAdjacentToHeader ) {
188+ if (!isVirtualLargeObjectHeapEnabled || _isDataAdjacent ) {
191189 Assert_MM_true (1 == _numberOfArraylets);
192190 }
193191 break ;
0 commit comments