gallium/pipebuffer: add pb_slab utility

Graphics / Mesa 3D Graphics Library / Mesa - Nicolai Hähnle [amd.com] - 27 September 2016 09:44 UTC

This is a simple framework for slab allocation from buffers that fits into the buffer management scheme of the radeon and amdgpu winsyses where bufmgrs aren't used.

The utility knows about different sized allocations and explicitly manages reclaim of allocations that have pending fences. It manages all the free lists but does not actually touch buffer objects directly, relying on callbacks for that.

84f156c gallium/pipebuffer: add pb_slab utility
src/gallium/auxiliary/Makefile.sources | 2 +
src/gallium/auxiliary/pipebuffer/pb_slab.c | 252 ++++++++++++++++++++++++++++
src/gallium/auxiliary/pipebuffer/pb_slab.h | 155 +++++++++++++++++
3 files changed, 409 insertions(+)

Upstream: cgit.freedesktop.org


  • Share