diff --git a/code/renderer/rhi_d3d12.cpp b/code/renderer/rhi_d3d12.cpp index c90e4f7..e17e9b2 100644 --- a/code/renderer/rhi_d3d12.cpp +++ b/code/renderer/rhi_d3d12.cpp @@ -1162,11 +1162,14 @@ namespace RHI void UploadManager::EndOfBufferReached() { - ri.Printf(PRINT_DEVELOPER, "Waiting for GPU upload: %s (%d T, %d B)\n", + const int64_t startUS = Sys_Microseconds(); + fence.WaitOnCPU(fenceValue); + const int64_t elapsedUS = Sys_Microseconds() - startUS; + ri.Printf(PRINT_DEVELOPER, "Waited %d ms for GPU upload: %s (%d T, %d B)\n", + (int)(elapsedUS / 1000), Com_FormatBytes(bufferByteOffset), batchTextureCount, batchBufferCount); - fence.WaitOnCPU(fenceValue); D3D(commandAllocator->Reset()); bufferByteOffset = 0; batchTextureCount = 0;