-
-
Notifications
You must be signed in to change notification settings - Fork 21.4k
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
Vulkan: Toggling the SSAO Half Size option in Project Settings causes memory leak #63202
Comments
Does the memory usage continue increasing each frame or does it only increase once and then stay static? |
Tested for ~3 minutes and it increased continuously. |
Same for SSIL. Note that SSIL is disabled but "Half Size" on for SSIL still causes a memory leak (because AO is enabled?) |
It might be worth checking whether #62478 fixes this. |
Hmmm, yeah would be good to check if my PR already deals with it or else see if I can fix it in there as any fix will probably be lost due to the merge conflicts not picking this up properly. That said, the code for allocating and freeing buffers used by these effects was all over the place and should be more readable in my PR. It should be easier to check and see if we forget to free something. |
I just tested with revision 0a420c4, which should include @BastiaanOlij's PR, on a local debug build of the editor and was able to reproduce the memory leak with the minimal reproduction project. The leak happened when either SSAO or SSIL was enabled. When both were disabled, no measurable memory leak was shown in he Debugger Monitor. |
Thanks @allenwp , I'll have a closer look as soon as I can, most of my PR was restructuring, not changing how it works but it should be easier now to compare allocations and whether they are being freed up. |
Not sure if this could be related to this issue, it may be a flow on effect, but I couldn't find any memory leak in SSAO (yet, I'll do more testing). |
Can this be re-tested on the latest master? |
@BastiaanOlij This time I tested using a Memory leak reproduced using the reproduction project that is attached to initial comment of this issue on 0a420c4, v4.0.alpha16.official [86dd3f3], and 79b21e9 (latest master). |
Thanks Allen, I'm going to try and see if I can reproduce it at this end. |
I think I fixed it, see PR #65738 |
Godot version
v4.0.alpha11.official [afdae67]
System information
Windows 11, Vulkan, Nvida RTX 2080 Ti
Issue description
when ssao is enabled and turn off the ssao/half_size option in Project Setting will cause memory leak
turn on half_size:
turn off half_size:
Steps to reproduce
Open any scene in godot. Enable SSAO in the WorldEnvironment, and toggle the ssao/half_size option in Project Setting and you will see the memory difference in the debugger
Minimal reproduction project
SSAO_Bug.zip
The text was updated successfully, but these errors were encountered: