mesa/src/gallium/winsys
José Fonseca e29525f79f winsys/sw/xlib: Prevent shared memory segment leakage.
Running piglit with this was causing all sort of weird stuff happening
to my desktop (Chromium webpages become blank, Qt Creator flickered,
etc).  I tracked this down to shared memory segment leakage when GL is
not shutdown properly. The segments can be seen running `ipcs` and
looking for nattch==0.

This changes fixes this by calling shmctl(IPC_RMID) soon after creation
(which does not remove the segment immediately, but simply marks it for
removal when no more processes are attached).

This matches src/mesa/drivers/x11/xm_buffer.c behaviour.

v2:
- move shmctl(IPC_RMID) after XShmAttach() for *BSD, per Chris Wilson
- remove stray debug printfs, spotted by Ian Romanick

NOTE: This is a candidate for stable branches.

Reviewed-by: Brian Paul <brianp@vmware.com>
2013-04-24 16:54:58 +01:00
..
freedreno/drm freedreno: gallium driver for adreno 2013-03-11 21:53:24 -04:00
i915 i915g: Use PIPE_FLUSH_END_OF_FRAME to trigger throttling 2013-03-08 19:34:50 -08:00
nouveau/drm Remove hacks for static Makefiles 2013-01-13 00:55:37 +01:00
radeon winsys/radeon: use query_value for timestamp, remove query_timestamp 2013-04-16 13:56:47 +02:00
svga/drm winsys/svga: improve error/debug message output 2013-03-19 15:18:38 -06:00
sw winsys/sw/xlib: Prevent shared memory segment leakage. 2013-04-24 16:54:58 +01:00
Makefile.am build: Get rid of GALLIUM_WINSYS_DIRS 2013-04-15 12:05:55 -07:00