From f130aa69996d3d483202bf0e35a19a9fc3c87cee Mon Sep 17 00:00:00 2001 From: Jens Peters Date: Fri, 28 Jun 2024 21:22:15 +0200 Subject: [PATCH] d3d12: Log OUT_OF_BAND_IGNORE --- src/nvapi_d3d12.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/nvapi_d3d12.cpp b/src/nvapi_d3d12.cpp index c317a86e..c5cc25a8 100644 --- a/src/nvapi_d3d12.cpp +++ b/src/nvapi_d3d12.cpp @@ -459,6 +459,7 @@ extern "C" { NvAPI_Status __cdecl NvAPI_D3D12_NotifyOutOfBandCommandQueue(ID3D12CommandQueue* pCommandQueue, NV_OUT_OF_BAND_CQ_TYPE cqType) { constexpr auto n = __func__; + thread_local bool alreadyLoggedTypeIgnore = false; thread_local bool alreadyLoggedError = false; thread_local bool alreadyLoggedOk = false; @@ -474,6 +475,9 @@ extern "C" { if (nvapiD3dInstance->IsUsingLfx() || !NvapiD3dLowLatencyDevice::SupportsLowLatency(pCommandQueue)) return NoImplementation(n); + if (cqType == OUT_OF_BAND_IGNORE && !std::exchange(alreadyLoggedTypeIgnore, true)) + log::info("NvAPI_D3D12_NotifyOutOfBandCommandQueue is called with OUT_OF_BAND_IGNORE"); + if (!NvapiD3d12Device::NotifyOutOfBandCommandQueue(pCommandQueue, static_cast(cqType))) return Error(n, alreadyLoggedError);