-
Notifications
You must be signed in to change notification settings - Fork 920
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Free the raw device when
wgpu::Device
is dropped.
Go ahead and call `global.device_drop` from `direct::Context::device_drop`. Let `Global::device_drop` simply drop the life guard's `RefCount`, and put off everything else entailed in freeing a device until `Device::maintain` says its queue is empty and there are no more references to it. (The user can reach that function, even after dropping their `Device`, by calling `wgpu::Instance::poll_all`.) Fixes #2563.
- Loading branch information
Showing
4 changed files
with
96 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters