Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DX12 wrong swap-chain buffer reference error #5094

Closed
valaphee opened this issue Jan 19, 2024 · 1 comment
Closed

DX12 wrong swap-chain buffer reference error #5094

valaphee opened this issue Jan 19, 2024 · 1 comment

Comments

@valaphee
Copy link
Contributor

valaphee commented Jan 19, 2024

Description
Pull request #4899 with desired_maximum_frame_latency set to 2 seem to not work at least on my PC, as all examples now run with 1.0 FPS and the error

ID3D12CommandQueue::ExecuteCommandLists: A command list, which writes to a swapchain back buffer, may only be executed when that back buffer is the back buffer that will be presented during the next call to Present*. Such a back buffer is also re
ferred to as the "current back buffer". Swap Chain: 0x0000015343D9C8A0:'Unnamed Object' - Current Back Buffer Buffer: 0x0000015343E96EB0:'Unnamed ID3D12Resource Object' - Attempted Write Buffer: 0x0000015343C9C4A0:'Unnamed ID3D12Resource Object' [ STATE_SETTING ERROR #907: EXECUTECOMMANDLISTS_WRONGSWAPCHAINBUFFERREFERENCE]

appears 3 times each frame.

The water example directly crashes:

[2024-01-19T00:04:14Z ERROR wgpu_hal::auxil::dxgi::exception] ID3D12Device::RemoveDevice: Device removal has been triggered for the following reason (DXGI_ERROR_ACCESS_DENIED: The application attempted to use a resource it does not access to.  This  could be, for example, rendering to a texture while only having read access.). [ EXECUTION ERROR #232: DEVICE_REMOVAL_PROCESS_AT_FAULT]
[2024-01-19T00:04:14Z ERROR wgpu_hal::auxil::dxgi::result] Buffer creation failed: 0x887A0005
[2024-01-19T00:04:14Z ERROR wgpu::backend::wgpu_core] Handling wgpu errors as fatal by default
thread 'main' panicked at 'wgpu error: Validation Error

Caused by:
    In Queue::write_buffer
    Parent device is lost

Repro steps
Running the examples using the dx12 backend

Expected vs observed behavior
Fallback/default to 3 if 2 doesn't work for desired_maximum_frame_latency, or working desired_maximum_frame_latency with set to 2

Extra materials

Platform
Windows 11 23H2, RX 6900 XT (driver version 23.12.1)

@cwfitzgerald
Copy link
Member

cwfitzgerald commented Jan 19, 2024

Duplicate of #5088

Should be fixed by #5091, can you check if this fixes the problem

@cwfitzgerald cwfitzgerald closed this as not planned Won't fix, can't repro, duplicate, stale Jan 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants