mempool: add the minimum size configuration of mempool

The minimum size of mempool can be configured through CONFIG_MM_MPOOL_MINISIZE

Signed-off-by: liwenxiang1 <liwenxiang1@xiaomi.com>
This commit is contained in:
liwenxiang1
2024-05-06 21:42:49 +08:00
committed by Xiang Xiao
parent 821196eb22
commit 015a45517e
3 changed files with 18 additions and 3 deletions
+10 -3
View File
@@ -216,10 +216,11 @@ config MM_HEAP_MEMPOOL_THRESHOLD
== 0 Enable pool feature, but disable the umm/kmm pool function.
< 0 Disable pool feature.
if MM_HEAP_MEMPOOL_THRESHOLD > 0
config MM_HEAP_MEMPOOL_EXPAND_SIZE
int "The expand size for each mempool in multiple mempool"
default 4096
depends on MM_HEAP_MEMPOOL_THRESHOLD > 0
---help---
This size describes the size of each expansion of each memory
pool with insufficient memory in the multi-level memory pool.
@@ -227,17 +228,23 @@ config MM_HEAP_MEMPOOL_EXPAND_SIZE
config MM_HEAP_MEMPOOL_DICTIONARY_EXPAND_SIZE
int "The expand size for multiple mempool's dictionary"
default MM_HEAP_MEMPOOL_EXPAND_SIZE
depends on MM_HEAP_MEMPOOL_THRESHOLD > 0
---help---
This size describes the multiple mempool dictionary expand.
config MM_HEAP_MEMPOOL_CHUNK_SIZE
int "The multiples pool chunk size"
default 0
depends on MM_HEAP_MEMPOOL_THRESHOLD > 0
---help---
This size describes the multiple mempool chunk size.
config MM_MIN_BLKSIZE
int "Minimum memory block size"
default 0
---help---
Users can configure the minimum memory block size as needed
endif # MM_HEAP_MEMPOOL_THRESHOLD > 0
config MM_HEAP_MEMPOOL_BACKTRACE_SKIP
int "The skip depth of backtrace for mempool"
default 6