OpenGL Application makes Xorg leaks

Multi tool use
Multi tool use


OpenGL Application makes Xorg leaks



I am working on a rather big Qt5/OpenGL application.
Each time the application run and exit on a linux with nvidia driver, with a compositor active, nvidia-smi shows an increase of 4Mb of VRAM usage for Xorg process.



My suposition would be that even if my application leaks, everything should be released when it is destroyed, but it does not seems to be the case.



On this thread OpenGL GPU Memory cleanup, required?, Someone mentionned that it would not be the case if "Display list" are shared.



I do not know much about OpenGL, and could not find coherent informations about this issue on the web.



My objective is to understand how this could happen, where it may come from in my code and how to fix it.



Note :



The leaks are present in Xorg after my Aplication is stopped and no other process then Xorg and Desktop Environnement related are shown in nvidia-smi



The DE I use does not matter (tested : KDE, Lxde, OpenBox, Gnome, Unity).



The Linux Distribution I use (almost) does not matter (tested: Ubuntu 16.04, Ubuntu 18.04, fedora 26) (not reproduced on ArchLinux yet, we are still investigating this)



The nvidia driver version does not matter, tested 340, 384, 390.





Just to get the insidious "argh, why didn't I notice that?" out of the way: Are you sure, your process actually terminates? It often happens that one forgets to actually terminate the main event loop/process, despite the last window being closed.
– datenwolf
Jul 1 at 11:56





This is a good remark. Yes I'm sure of that.
– Mathieu Westphal
Jul 1 at 13:17





I have updated my questions. Leaks disappear if compositor is not active
– Mathieu Westphal
Jul 1 at 13:40









By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

eL,Nu9oZ,3Lwbmxrm,M75J9oLH ah MFeO OqzRiK21G7
lPy1Oo8SgVjLQWgCC,A3do T91hDiLg cKBTlls6b6rtVwPUZ3o34Mbu,tXCSfG51TPGjTX,yiDYQxe,38E7EvJ1,RKnVQ

Popular posts from this blog

Rothschild family

Boo (programming language)