-
Notifications
You must be signed in to change notification settings - Fork 967
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::Instance fd leak #3813
Comments
Is there any possible way to get the backtrace where these FDs are made? |
From experimenting with strace I found that these are X11 display sockets. gdb suggests:
It seems as though: Line 119 in ad45f29
is missing a |
Introduces a DisplayOwner struct to own both the library and associated display pointer; their lifetimes are combined in that struct. The display pointer is encapsulated in a DisplayRef. When DisplayOwner is dropped, it ensures that the DisplayRef is correctly closed prior to unloading the library. refs: gfx-rs#3813
Introduces a DisplayOwner struct to own both the library and associated display pointer; their lifetimes are combined in that struct. The display pointer is encapsulated in a DisplayRef. When DisplayOwner is dropped, it ensures that the DisplayRef is correctly closed prior to unloading the library. refs: gfx-rs#3813
Introduces a DisplayOwner struct to own both the library and associated display pointer; their lifetimes are combined in that struct. The display pointer is encapsulated in a DisplayRef. When DisplayOwner is dropped, it ensures that the DisplayRef is correctly closed prior to unloading the library. refs: gfx-rs#3813
Introduces a DisplayOwner struct to own both the library and associated display pointer; their lifetimes are combined in that struct. The display pointer is encapsulated in a DisplayRef. When DisplayOwner is dropped, it ensures that the DisplayRef is correctly closed prior to unloading the library. refs: #3813
Fixed by #3924 |
Description
wgpu::Instance::new
leaks a unix domain socket on each callRepro steps
Strip down the
hello
example:Then run
lsof -p PID
where PID is the pid of thehello
example:The number of unix domain socket lines corresponds to the number of times that
wgpu::Instance::new
is called.Expected vs observed behavior
I'd expect all resources to be released when the
Instance
is dropped. Instead, resources are leaked.Extra materials
See above
Platform
Information about your OS, version of
wgpu
, your tech stack, etc.This was reported in:
but reproduces with 4478c52 of this repo, independent of wezterm.
This is running on Fedora 38 under X11 with the following adapters:
The user reporting the issue to wezterm was running X11 with awesome on an nvidia system; I don't believe that this is driver specific.
The text was updated successfully, but these errors were encountered: