-
Notifications
You must be signed in to change notification settings - Fork 437
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
Memory leak with CpuBufferPool on macOS #931
Comments
Thanks for the issue. It is very unlikely that this an osx-only issue though. The code is totally cross platform. |
The same example does seem to work fine on Windows (different machine): capacity maxed out at 3 which seems correct. Running with MoltenVK 1.0 results in the same behaviour. AFAICT this is macOS only which is super bizzare. |
Actually waiting for the fence signal to return seems to workaround the issue. With the way vkWaitForFence() works, AFAIUI, the Ok() case will never be matched using a timeout of 0. I don't grok what the expected flow is supposed be here, but hopefully this will narrow down the underlying cause.
|
@ggazebo you might be interested in the solution mentioned in this comment - it's similar to the solution you mention but uses the existing |
|
Subbuffers allocated via a CpuBufferPool don't seem to be dropped properly on macOS. This eventually causes the app to crash with an overflow.
Issue can be seen with the teapot example, made more obvious using the change below.
I'm currently linking against MoltenVK 0.19.0.
Unsure if the issue exists when using the new 1.0 MoltenVK release. (I don't develop on macOS usually and at this point I don't know if I have 1.0 installed and linking correctly)
The text was updated successfully, but these errors were encountered: