summaryrefslogtreecommitdiff
path: root/slabs.h
diff options
context:
space:
mode:
authordormando <dormando@rydia.net>2016-06-21 21:25:57 -0700
committerdormando <dormando@rydia.net>2016-06-24 00:47:41 -0700
commitd7fb022db0df15f672b5442d710f60ccb4c86319 (patch)
tree4f45c03f65a5b5d469dc93c9967d7746c9e5985e /slabs.h
parentae6f4267fede1db1739f6616b7b85b92f1300588 (diff)
downloadmemcached-d7fb022db0df15f672b5442d710f60ccb4c86319.tar.gz
allow manually specifying slab class sizes
"-o slab_sizes=100-200-300-400-500" will create 5 slab classes of those specified sizes, with the final class being item_max_size. Using the new online stats sizes command, it's possible to determine if the typical factoral slab class growth rate doesn't align well with how items are stored. This is dangerous unless you really know what you're doing. If your items have an exact or very predictable size this makes a lot of sense. If they do not, the defaults are safer.
Diffstat (limited to 'slabs.h')
-rw-r--r--slabs.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/slabs.h b/slabs.h
index b993b5f..23e713c 100644
--- a/slabs.h
+++ b/slabs.h
@@ -8,7 +8,7 @@
3rd argument specifies if the slab allocator should allocate all memory
up front (if true), or allocate memory in chunks as it is needed (if false)
*/
-void slabs_init(const size_t limit, const double factor, const bool prealloc);
+void slabs_init(const size_t limit, const double factor, const bool prealloc, const uint32_t *slab_sizes);
/**