summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/pipebuffer/pb_bufmgr.h
diff options
context:
space:
mode:
authorJosé Fonseca <[email protected]>2008-04-15 12:34:33 +0900
committerJosé Fonseca <[email protected]>2008-04-15 12:39:22 +0900
commita175e15f20b2a231cc9d09099e7b6d8aea6c624e (patch)
tree24dbbed3ca81fb994a1407ae373730e6bffc1720 /src/gallium/auxiliary/pipebuffer/pb_bufmgr.h
parentd3878b070b7b5084526b65499737cc686a6039b6 (diff)
gallium: Allow to use a single slab.
We often want to use a pool of equally sized buffers, so this makes the slab suballocator a drop-in replacement.
Diffstat (limited to 'src/gallium/auxiliary/pipebuffer/pb_bufmgr.h')
-rw-r--r--src/gallium/auxiliary/pipebuffer/pb_bufmgr.h22
1 files changed, 15 insertions, 7 deletions
diff --git a/src/gallium/auxiliary/pipebuffer/pb_bufmgr.h b/src/gallium/auxiliary/pipebuffer/pb_bufmgr.h
index b2d2520b67e..96f9af3825f 100644
--- a/src/gallium/auxiliary/pipebuffer/pb_bufmgr.h
+++ b/src/gallium/auxiliary/pipebuffer/pb_bufmgr.h
@@ -118,13 +118,21 @@ mm_bufmgr_create_from_buffer(struct pb_buffer *buffer,
* Slab sub-allocator.
*/
struct pb_manager *
-pb_slab_manager_create(struct pb_manager *provider,
- const struct pb_desc *desc,
- size_t smallestSize,
- size_t numSizes,
- size_t desiredNumBuffers,
- size_t maxSlabSize,
- size_t pageAlignment);
+pb_slab_manager_create(struct pb_manager *provider,
+ size_t bufSize,
+ size_t slabSize,
+ const struct pb_desc *desc);
+
+/**
+ * Allow a range of buffer size, by aggregating multiple slabs sub-allocators
+ * with different bucket sizes.
+ */
+struct pb_manager *
+pb_slab_range_manager_create(struct pb_manager *provider,
+ size_t minBufSize,
+ size_t maxBufSize,
+ size_t slabSize,
+ const struct pb_desc *desc);
/**