Skip to content

Commit

Permalink
feat: improve jemalloc memory efficiency (#1689)
Browse files Browse the repository at this point in the history
  • Loading branch information
dm9pZCAq authored Sep 26, 2024
1 parent ae53ef4 commit e281671
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[env]
# environment variable for tikv-jemalloc-sys
#
# https://jemalloc.net/jemalloc.3.html#opt.narenas
# narenas is the maximum number of arenas to use for automatic multiplexing
# of threads and arenas. The default is four times the number of CPUs,
# or one if there is a single CPU.
#
# Improve memory efficiency by reducing fragmentation and ensuring all threads allocate from the same pool
JEMALLOC_SYS_WITH_MALLOC_CONF = "narenas:1"

0 comments on commit e281671

Please sign in to comment.