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

wgpu-core contains deadlocks #5572

Open
1 of 6 tasks
jimblandy opened this issue Apr 20, 2024 · 0 comments
Open
1 of 6 tasks

wgpu-core contains deadlocks #5572

jimblandy opened this issue Apr 20, 2024 · 0 comments
Assignees

Comments

@jimblandy
Copy link
Member

jimblandy commented Apr 20, 2024

In the process of developing #5539, we identified at least one deadlock in wgpu-core, and I suspect there are others. We should fix these deadlocks, updating lock::rank as we go, and enable the lock::ranked run-time validation by default in debug builds.

The presence of deadlocks means that no cycle-free ranking of locks exists that won't cause panics in our current tests and examples. This means that the ranking defined in lock::rank must either remain incomplete, or we should change the implementation to permit ranking cycles for the time being. The latter option is unappealing, so we plan to land #5539 with an incomplete ranking, meaning that enabling the validate-locks feature will cause panics for now.

Issues for specific deadlocks:

jimblandy added a commit to jimblandy/wgpu that referenced this issue Apr 20, 2024
If `debug_assertions` or the `"validate-locks"` feature are enabled,
change `wgpu-core` to use a wrapper around `parking_lot::Mutex` that
checks for potential deadlocks.

At the moment, `wgpu-core` does contain deadlocks, so the ranking in
the `lock::rank` module is incomplete, in the interests of keeping it
acyclic. gfx-rs#5572 tracks the work needed to complete the ranking.
jimblandy added a commit to jimblandy/wgpu that referenced this issue Apr 20, 2024
If `debug_assertions` or the `"validate-locks"` feature are enabled,
change `wgpu-core` to use a wrapper around `parking_lot::Mutex` that
checks for potential deadlocks.

At the moment, `wgpu-core` does contain deadlocks, so the ranking in
the `lock::rank` module is incomplete, in the interests of keeping it
acyclic. gfx-rs#5572 tracks the work needed to complete the ranking.
jimblandy added a commit to jimblandy/wgpu that referenced this issue Apr 21, 2024
If `debug_assertions` or the `"validate-locks"` feature are enabled,
change `wgpu-core` to use a wrapper around `parking_lot::Mutex` that
checks for potential deadlocks.

At the moment, `wgpu-core` does contain deadlocks, so the ranking in
the `lock::rank` module is incomplete, in the interests of keeping it
acyclic. gfx-rs#5572 tracks the work needed to complete the ranking.
jimblandy added a commit to jimblandy/wgpu that referenced this issue Apr 22, 2024
If `debug_assertions` or the `"validate-locks"` feature are enabled,
change `wgpu-core` to use a wrapper around `parking_lot::Mutex` that
checks for potential deadlocks.

At the moment, `wgpu-core` does contain deadlocks, so the ranking in
the `lock::rank` module is incomplete, in the interests of keeping it
acyclic. gfx-rs#5572 tracks the work needed to complete the ranking.
jimblandy added a commit to jimblandy/wgpu that referenced this issue Apr 22, 2024
If `debug_assertions` or the `"validate-locks"` feature are enabled,
change `wgpu-core` to use a wrapper around `parking_lot::Mutex` that
checks for potential deadlocks.

At the moment, `wgpu-core` does contain deadlocks, so the ranking in
the `lock::rank` module is incomplete, in the interests of keeping it
acyclic. gfx-rs#5572 tracks the work needed to complete the ranking.
jimblandy added a commit to jimblandy/wgpu that referenced this issue Apr 22, 2024
If `debug_assertions` or the `"validate-locks"` feature are enabled,
change `wgpu-core` to use a wrapper around `parking_lot::Mutex` that
checks for potential deadlocks.

At the moment, `wgpu-core` does contain deadlocks, so the ranking in
the `lock::rank` module is incomplete, in the interests of keeping it
acyclic. gfx-rs#5572 tracks the work needed to complete the ranking.
jimblandy added a commit to jimblandy/wgpu that referenced this issue Apr 22, 2024
If `debug_assertions` or the `"validate-locks"` feature are enabled,
change `wgpu-core` to use a wrapper around `parking_lot::Mutex` that
checks for potential deadlocks.

At the moment, `wgpu-core` does contain deadlocks, so the ranking in
the `lock::rank` module is incomplete, in the interests of keeping it
acyclic. gfx-rs#5572 tracks the work needed to complete the ranking.
jimblandy added a commit to jimblandy/wgpu that referenced this issue Apr 22, 2024
If `debug_assertions` or the `"validate-locks"` feature are enabled,
change `wgpu-core` to use a wrapper around `parking_lot::Mutex` that
checks for potential deadlocks.

At the moment, `wgpu-core` does contain deadlocks, so the ranking in
the `lock::rank` module is incomplete, in the interests of keeping it
acyclic. gfx-rs#5572 tracks the work needed to complete the ranking.
jimblandy added a commit that referenced this issue Apr 23, 2024
If `debug_assertions` or the `"validate-locks"` feature are enabled,
change `wgpu-core` to use a wrapper around `parking_lot::Mutex` that
checks for potential deadlocks.

At the moment, `wgpu-core` does contain deadlocks, so the ranking in
the `lock::rank` module is incomplete, in the interests of keeping it
acyclic. #5572 tracks the work needed to complete the ranking.
@jimblandy jimblandy self-assigned this May 20, 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

1 participant