SWDEV-497841 - Add VmHeapArray support (#76)

Add VmHeapArray class to reduce the pressure on VA reservation, since
multiple memory pools can be active at the same time.

[ROCm/clr commit: e974f7fde1]
Этот коммит содержится в:
Andryeyev, German authored and GitHub committed 2025-04-03 21:04:18 +05:30
1 родитель 3ceab5ba02
Коммит 4c9cc6ba30
5 files changed
+218 -43

No files matched your search

+3 -1
Просмотреть файл
@@ -378,6 +378,7 @@ hipError_t MemoryPool::SetAttribute(hipMemPoolAttr attr, void* value) {
return hipErrorInvalidValue;
}
max_total_size_ = reset;
ResetMaxMappedSize();
break;
case hipMemPoolAttrUsedMemCurrent:
// Should be GetAttribute only
@@ -424,7 +425,8 @@ hipError_t MemoryPool::GetAttribute(hipMemPoolAttr attr, void* value) {
break;
case hipMemPoolAttrReservedMemHigh:
// High watermark of all allocated memory in OS, since the last reset
*reinterpret_cast<uint64_t*>(value) = max_total_size_;
*reinterpret_cast<uint64_t*>(value) = (state_.use_vm_heap_)
? MaxMappedSize() : max_total_size_;
break;
case hipMemPoolAttrUsedMemCurrent:
// Total currently used memory by the pool