mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2026-11-25 18:07:32 +00:00
feat: Add mimalloc support, drop hardened_malloc
This commit is contained in:
1 parent
68068574d3
commit
d4ac77a023
8 files changed
+44
-68
No files matched your search
+7
-20
@@ -1,27 +1,14 @@
|
||||
//! Integration with allocators
|
||||
|
||||
// jemalloc
|
||||
#[cfg(all(not(target_env = "msvc"), feature = "jemalloc"))]
|
||||
pub mod default;
|
||||
|
||||
#[cfg(feature = "jemalloc")]
|
||||
pub mod je;
|
||||
#[cfg(all(not(target_env = "msvc"), feature = "jemalloc"))]
|
||||
#[cfg(feature = "jemalloc")]
|
||||
pub use je::{memory_stats, memory_usage, memory_usage_stats, trim};
|
||||
|
||||
#[cfg(all(not(target_env = "msvc"), feature = "hardened_malloc", not(feature = "jemalloc")))]
|
||||
pub mod hardened;
|
||||
#[cfg(all(
|
||||
not(target_env = "msvc"),
|
||||
feature = "hardened_malloc",
|
||||
not(feature = "jemalloc")
|
||||
))]
|
||||
pub use hardened::{memory_stats, memory_usage, memory_usage_stats, trim};
|
||||
#[cfg(all(feature = "mimalloc", not(feature = "jemalloc")))]
|
||||
pub mod mimalloc;
|
||||
|
||||
#[cfg(any(
|
||||
target_env = "msvc",
|
||||
all(not(feature = "hardened_malloc"), not(feature = "jemalloc"))
|
||||
))]
|
||||
pub mod default;
|
||||
#[cfg(any(
|
||||
target_env = "msvc",
|
||||
all(not(feature = "hardened_malloc"), not(feature = "jemalloc"))
|
||||
))]
|
||||
#[cfg(not(feature = "jemalloc"))]
|
||||
pub use default::{memory_stats, memory_usage, memory_usage_stats, trim};
|
||||
Reference in new issue
Block a user