feat: switch musl builds to jemalloc allocator for stability
Update Cargo.lock to remove unused dependencies and update tikv-jemallocator. Configure src/obikmer/Cargo.toml to use jemalloc for static musl builds, addressing fragmentation issues with the default multi-threaded allocator. Update main.rs to conditionally set Jemalloc as the global allocator when targeting musl. - Remove unused dependencies from Cargo.lock: anes, block-pseudorand, chiapos-chacha8, criterion, criterion-plot, itertools (and its either dep), nanorand, hermit-abi, is-terminal, plotters ecosystem, tinytemplate deps, voracious_radix_sort rayon dep, and web-sys deps. - Update tikv-jemallocator version from 0.5.4 to 0.7.0 in Cargo.lock. - Add tikv-jemallocator = "0.7.0" to musl-specific dependencies in src/obikmer/Cargo.toml. - Set Jemalloc as the global allocator in main.rs for static musl builds.
This commit is contained in:
1 parent
d0668eb167
commit
af525cd268
3 files changed
+20
-161
No files matched your search
@@ -36,6 +36,13 @@ serde_yaml = "0.9"
|
||||
tracing = "0.1.44"
|
||||
tracing-subscriber = { version = "0.3", features = ["fmt", "env-filter"] }
|
||||
|
||||
# musl's built-in allocator fragments badly under the merge's multi-threaded
|
||||
# allocation pattern (map count and RSS drift, see DevDocMD/implementation/
|
||||
# merge_mmap_audit.md). Static musl builds use jemalloc instead; glibc and
|
||||
# macOS builds keep the system allocator.
|
||||
[target.'cfg(target_env = "musl")'.dependencies]
|
||||
tikv-jemallocator = "0.7.0"
|
||||
|
||||
[features]
|
||||
default = ["numa"]
|
||||
numa = ["obisys/numa"]
|
||||
Reference in new issue
Block a user