Using Gnome 3.28 (CentOS 7.6) with llvmpipe driver, Mesa 18.0, but same problem exists with Gnome 3.30 (Ubuntu 18.10), Mesa 18.2. Opened a Gnome Terminal window. New shared memory segments are created every time the terminal window is resized (found it with: ipcs -m | wc -l). It looks XShmAttach() is called in src/glx/drisw_glx.c:XCreateDrawable(), but XShmDetach() is never called. Should it be called in XDestroyDrawable()?
I believe this recent patch should help: commit b344e32cdf7064a1f2ff7ef37027edda6589404f Author: Ray Zhang <zhanglei002@gmail.com> Date: Wed Feb 27 06:54:05 2019 +0000 glx: fix shared memory leak in X11 call XShmDetach to allow X server to free shared memory Fixes: bcd80be49a8260c2233d "drisw/glx: use XShm if possible" Signed-off-by: Ray Zhang <zhanglei002@gmail.com> Reviewed-by: Dave Airlie <airlied@redhat.com> Can you try top-of-tree Mesa?
And it appears this patch will be in the Mesa 19.0 release.
The patch fixed the issue. Thank you.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.