From 278d660cdc29f45e9a284daa96419fb65d23dc75 Mon Sep 17 00:00:00 2001 From: Mateusz Jablonski Date: Tue, 22 Oct 2019 15:28:44 +0200 Subject: [PATCH] Correct max number of handles for residency Change-Id: Icab563f837543f75f7f150645c84408a665bbfc1 Signed-off-by: Mateusz Jablonski --- runtime/os_interface/windows/wddm_residency_controller.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/os_interface/windows/wddm_residency_controller.cpp b/runtime/os_interface/windows/wddm_residency_controller.cpp index 1d5613aabd..4d94376116 100644 --- a/runtime/os_interface/windows/wddm_residency_controller.cpp +++ b/runtime/os_interface/windows/wddm_residency_controller.cpp @@ -300,7 +300,7 @@ bool WddmResidencyController::trimResidencyToBudget(uint64_t bytes) { bool WddmResidencyController::makeResidentResidencyAllocations(const ResidencyContainer &allocationsForResidency) { const size_t residencyCount = allocationsForResidency.size(); - std::unique_ptr handlesForResidency(new D3DKMT_HANDLE[residencyCount * maxFragmentsCount]); + std::unique_ptr handlesForResidency(new D3DKMT_HANDLE[residencyCount * maxFragmentsCount * maxHandleCount]); uint32_t totalHandlesCount = 0; auto lock = this->acquireLock();