SWDEV-576718 - provide option to limit memory cache usage (#2810)

* SWDEV-576718 - provide option to limit memory cache usage

* SWDEV-576718 - Use MiB instead of MB in description
Tá an tiomantas seo le fáil i:
Xie, AlexBin
2026-01-26 11:35:01 -05:00
tiomanta ag GitHub
tuismitheoir 265d0a2d2b
tiomantas e22c9b457e
D'athraigh 2 comhad le 6 breiseanna agus 1 scriosta
+3
Féach ar an gComhad
@@ -347,6 +347,9 @@ bool Settings::create(const Pal::DeviceProperties& palProp,
#endif
}
resourceCacheSize_ = std::min(resourceCacheSize_,
(uint64_t)GPU_MAX_RESOURCE_CACHE_SIZE * Mi);
// If is Rebar, override prepinned memory size.
if ((heaps[Pal::GpuHeapInvisible].logicalSize == 0) &&
(heaps[Pal::GpuHeapLocal].logicalSize > 256 * Mi)) {
+3 -1
Féach ar an gComhad
@@ -83,7 +83,9 @@ release(size_t, GPU_PINNED_XFER_SIZE, 32, \
release(size_t, GPU_PINNED_MIN_XFER_SIZE, 128, \
"The minimal buffer size for pinned read/write transfers in MiB") \
release(size_t, GPU_RESOURCE_CACHE_SIZE, 64, \
"The resource cache size in MB") \
"The resource cache size in MiB") \
release(size_t, GPU_MAX_RESOURCE_CACHE_SIZE, 16777216, \
"The max resource cache size in MiB") \
release(size_t, GPU_MAX_SUBALLOC_SIZE, 4096, \
"The maximum size accepted for suballocations in KB") \
release(size_t, GPU_NUM_MEM_DEPENDENCY, 256, \