-
Notifications
You must be signed in to change notification settings - Fork 422
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
Sometimes crashing during animated layer resize #2031
Comments
Er, uh, why did you close this? If there's a problem with our code, and you have a fix for it, you should probably submit it to this repo. We'd really appreciate that. |
Because it was moved inside here: f0cb31a#diff-ee7f9cb03a11bba9ad9e2f634103f46908e74a8e5e630894a0a94340f312fd1bR1329 |
It looks like you have a race condition, where you are occasionally destroying the swapchain before the command buffer that is presenting its images has finished executing, or in your case, hasn't been scheduled into the GPU (which would happen almost immediately after submission to the queue). Are you performing a |
Were you are running with If the current code is still causing this problem, PR #2297 may fix this. Please test again with that update, and re-close this issue if it fixes the problem. |
Getting crash when addPresentedHandler is called at:
MoltenVK/MoltenVK/MoltenVK/GPUObjects/MVKImage.mm
Line 1321 in 568cc3a
I'm suspecting 9f64faa and f0cb31a.
If I remove all commits inclusive from 9f64faa I cannot reproduce the crash.
If I remove all commits from 9f64faa, but keep 9f64faa a28437d 7fe4963 f0cb31a I can reproduce the crash.
Removing just f0cb31a breaks sizing completely with
[mvk-error] VK_TIMEOUT: MTLCommandBuffer "vkQueueSubmit MTLCommandBuffer on Queue 0-0" execution failed (code 2): Caused GPU Timeout Error (IOAF code 2)
.Crash is difficult to reproduce but the way I'm reproducing is by spamming animated window resize (Window->Zoom with assigned key bind) where layer frame is auto resized to window frame, so autoresizingMask must be set, I use [.layerWidthSizable, .layerHeightSizable], but could reproduce with other masks.
If I enable "Reduce motion" in Accessibility preferences, window zoom becomes non animated and I can't reproduce the crash.
Unfortunately I can't reproduce it with cube and can't provide any simple example application.
Tested on macOS 11.7 only.
The text was updated successfully, but these errors were encountered: