facebook/igl

[Vulkan] CommandBuffer::popDebugGroupLabel() Crash after CommandBuffer::waitUntilCompleted()

vinsentli opened this issue · 5 comments

If call CommandBuffer::popDebugGroupLabel() after CommandBuffer::waitUntilCompleted(), it will crash.

void CommandBuffer::popDebugGroupLabel() const {
  ivkCmdEndDebugUtilsLabel(&ctx_.vf_, wrapper_.cmdBuf_);
}

Because wrapper_.cmdBuf_ has been set to VK_NULL_HANDLE in VulkanImmediateCommands::purge().

The callstack is :
CommandBuffer::waitUntilCompleted() --> VulkanImmediateCommands::wait()-->VulkanImmediateCommands::purge()

@vinsentli Why do you want to call popDebugGroupLabel() after a command buffer submission?

@corporateshark I just want to keep the gpu capture tree clear.
And There is no negative effects on OpenGL or Metal when Call popDebugGroupLabel() after CommandBuffer::Submit().
Of course, it is not necessary.

@vinsentli I see. Can you do popDebugGroupLabel() before Submit()?

@corporateshark Yes, I can call popDebugGroupLabel() before Submit()

@vinsentli Did it solve your issue?