Intermittent Crash in NSight Graphics Frame Debug Capture

Hello,

I have encountered a crash in our Vulkan application when capturing frames in NSight Graphics for debugging.

This is intermittent (75% repro) and seems to occur in the “Refreshing event timings” phase. Sometimes a capture succeeds, but hitting “Refresh Event Timings” later repro’s the crash.

Attaching a debugger to our application before capturing the frame allows us to see the call stack. Our presentation thread is executing vkQueuePresentKHR. A separate thread has a stack involving the NVidia driver and NSight interception dll:

nvoglv64.dll!00007ffc42265dfa()
nvoglv64.dll!00007ffc425e31cd()
nvoglv64.dll!00007ffc425e021a()
nvoglv64.dll!00007ffc424d5b72()
Nvda.Graphics.Interception.dll!00007ffbebdf9684()
Nvda.Graphics.Interception.dll!00007ffbebeb32a8()
Nvda.Graphics.Interception.dll!00007ffbec75a046()
Nvda.Graphics.Interception.dll!00007ffbec75d0c0()
Nvda.Graphics.Interception.dll!00007ffbec750b93()
Nvda.Graphics.Interception.dll!00007ffbec75038e()
Nvda.Graphics.Interception.dll!00007ffbeca9284a()
ucrtbase.dll!thread_start<unsigned int (__cdecl*)(void *),1>()
kernel32.dll!BaseThreadInitThunk()
ntdll.dll!RtlUserThreadStart()

I have replicated this with a minified C++ capture. The capture is also crashing intermittently, without the rest of the application logic.

In the minified repro, we have a single render pass and draw call using a vertex buffer that has been uploaded in a separate transfer queue with a staging buffer. Performing the vkCmdCopyBuffer on the graphics queue rather than the separate transfer queue seems to mask the issue.

Also, please note that we are using both VK_KHR_imageless_framebuffer and VK_KHR_synchronization2. I noticed that the generated VulkanReplay.cpp code does not support overriding image views for swapchain images in the chained VkRenderPassAttachmentBeginInfo structure in VulkanReplay_CmdBeginRenderPass2. It appears that this is implemented only for VulkanReplay_CmdBeginRenderPass. Calling vkCmdBeginRenderPass rather than vkCmdBeginRenderPass2 does not seem to work around the issue; however.

Please advise if I can provide more details to help.

Thank you kindly,

  • Kearwood “Kip” Gilbert

Please note that the call stack was captured using NSight Graphics 2023.2.0 and the Geforce 535.98 driver on an RTX 3060.

Hi Kearwood,

Can you provide me with the repro example? That would allow us to make progress the quickest.

Thanks,
Jeff@NVIDIA