Skip to content

Commit c42bce4

Browse files
committed
Replace jemalloc with mimalloc
1 parent 0ee5617 commit c42bce4

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

charabia/Cargo.toml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,7 @@ german-segmentation = []
8181
criterion = "0.5"
8282
quickcheck = "1"
8383
quickcheck_macros = "1"
84-
85-
[target.'cfg(any(all(target_os = "linux", any(target_arch = "x86_64", target_arch = "aarch64", all(target_arch = "powerpc64", target_endian = "little"))), all(target_os = "macos", target_arch = "aarch64")))'.dev-dependencies]
86-
jemallocator = "0.5.4"
84+
mimalloc = "0.1.43"
8785

8886
[[bench]]
8987
name = "bench"

charabia/benches/bench.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
use charabia::{Language, Script, Segment, Tokenize};
22
use criterion::{black_box, criterion_group, criterion_main, BenchmarkId, Criterion};
3+
use mimalloc::MiMalloc;
34

4-
#[cfg(any(all(target_os = "linux", any(target_arch = "x86_64", target_arch = "aarch64", all(target_arch = "powerpc64", target_endian = "little"))), all(target_os = "macos", target_arch = "aarch64")))]
55
#[global_allocator]
6-
static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc;
6+
static GLOBAL: MiMalloc = MiMalloc;
77

88
static DATA_SET: &[((usize, Script, Language), &str)] = &[
99
// short texts (~130 bytes)

0 commit comments

Comments
 (0)