From 320cebb8f975434d46ab91987108fe86742ee9a6 Mon Sep 17 00:00:00 2001 From: Philip Rebohle Date: Sat, 14 Apr 2018 13:03:14 +0200 Subject: [PATCH] [dxvk] Improved memory allocation debug output --- src/dxvk/dxvk_memory.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/dxvk/dxvk_memory.cpp b/src/dxvk/dxvk_memory.cpp index 605b41f0..00ebc8b2 100644 --- a/src/dxvk/dxvk_memory.cpp +++ b/src/dxvk/dxvk_memory.cpp @@ -288,9 +288,13 @@ namespace dxvk { result = this->tryAlloc(req, flags & ~VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT); if (result.memory() == VK_NULL_HANDLE) { - throw DxvkError(str::format( - "DxvkMemoryAllocator: Failed to allocate ", - req.size, " bytes")); + Logger::err(str::format( + "DxvkMemoryAllocator: Memory allocation failed", + "\n Size: ", req.size, + "\n Alignment: ", req.alignment, + "\n Mem flags: ", "0x", std::hex, flags, + "\n Mem types: ", "0x", std::hex, req.memoryTypeBits)); + throw DxvkError("DxvkMemoryAllocator: Memory allocation failed"); } return result;