Skip to content

Commit

Permalink
Merge pull request #18865 from amicic/balanced_copyscansize
Browse files Browse the repository at this point in the history
Detach copy-cache size bounds from TLH size bounds for Balanced
  • Loading branch information
dmitripivkine authored Feb 1, 2024
2 parents ac66d8c + c9b9477 commit eb1c385
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions runtime/gc_vlhgc/CopyForwardScheme.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ MM_CopyForwardScheme::initialize(MM_EnvironmentVLHGC *env)
UDATA minCacheCount = threadCount * cachesPerThread;

/* Estimate how many caches we might need to describe the entire heap */
UDATA heapCaches = extensions->memoryMax / extensions->tlhMaximumSize;
UDATA heapCaches = extensions->memoryMax / extensions->scavengerScanCacheMaximumSize;

/* use whichever value is higher */
UDATA totalCacheCount = OMR_MAX(minCacheCount, heapCaches);
Expand Down Expand Up @@ -297,8 +297,8 @@ MM_CopyForwardScheme::initialize(MM_EnvironmentVLHGC *env)
}

/* Set the min/max sizes for copy scan cache allocation when allocating a general purpose area (does not include non-standard sized objects) */
_minCacheSize = _extensions->tlhMinimumSize;
_maxCacheSize = _extensions->tlhMaximumSize;
_minCacheSize = _extensions->scavengerScanCacheMinimumSize;
_maxCacheSize = _extensions->scavengerScanCacheMaximumSize;

/* Cached pointer to the inter region remembered set */
_interRegionRememberedSet = MM_GCExtensions::getExtensions(env)->interRegionRememberedSet;
Expand Down
2 changes: 1 addition & 1 deletion runtime/gc_vlhgc/CopyScanCacheChunkVLHGCInHeap.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
uintptr_t
MM_CopyScanCacheChunkVLHGCInHeap::numberOfCachesInChunk(MM_EnvironmentVLHGC *env)
{
uintptr_t tlhMinimumSize = MM_GCExtensions::getExtensions(env)->tlhMinimumSize;
uintptr_t tlhMinimumSize = MM_GCExtensions::getExtensions(env)->scavengerScanCacheMinimumSize;
uintptr_t sizeToAllocate = sizeof(MM_CopyScanCacheChunkVLHGCInHeap);
uintptr_t numberOfCaches = 1;

Expand Down

0 comments on commit eb1c385

Please sign in to comment.