Use mimalloc for benchmarks on all platforms

This commit is contained in:
Loïc Lecrenier 2022-08-10 16:56:42 +02:00
parent 8f73251012
commit fb2b6c0c28
6 changed files with 0 additions and 31 deletions

View File

@ -9,14 +9,8 @@ milli = { path = "../milli" }
anyhow = "1.0.56"
serde_json = { version = "1.0.79", features = ["preserve_order"] }
csv = "1.1.6"
[target.'cfg(target_os = "linux")'.dependencies]
jemallocator = "0.3.2"
[target.'cfg(target_os = "macos")'.dependencies]
mimalloc = { version = "0.1.29", default-features = false }
[dev-dependencies]
heed = { git = "https://github.com/meilisearch/heed", tag = "v0.12.1" }
criterion = { version = "0.3.5", features = ["html_reports"] }

View File

@ -2,11 +2,6 @@ use criterion::{criterion_group, criterion_main};
use milli::tokenizer::TokenizerBuilder;
use milli::{FormatOptions, MatcherBuilder, MatchingWord, MatchingWords};
#[cfg(target_os = "linux")]
#[global_allocator]
static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc;
#[cfg(target_os = "macos")]
#[global_allocator]
static ALLOC: mimalloc::MiMalloc = mimalloc::MiMalloc;

View File

@ -14,11 +14,6 @@ use rand::seq::SliceRandom;
use rand_chacha::rand_core::SeedableRng;
use roaring::RoaringBitmap;
#[cfg(target_os = "linux")]
#[global_allocator]
static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc;
#[cfg(target_os = "macos")]
#[global_allocator]
static ALLOC: mimalloc::MiMalloc = mimalloc::MiMalloc;

View File

@ -5,11 +5,6 @@ use criterion::{criterion_group, criterion_main};
use milli::update::Settings;
use utils::Conf;
#[cfg(target_os = "linux")]
#[global_allocator]
static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc;
#[cfg(target_os = "macos")]
#[global_allocator]
static ALLOC: mimalloc::MiMalloc = mimalloc::MiMalloc;

View File

@ -5,11 +5,6 @@ use criterion::{criterion_group, criterion_main};
use milli::update::Settings;
use utils::Conf;
#[cfg(target_os = "linux")]
#[global_allocator]
static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc;
#[cfg(target_os = "macos")]
#[global_allocator]
static ALLOC: mimalloc::MiMalloc = mimalloc::MiMalloc;

View File

@ -5,11 +5,6 @@ use criterion::{criterion_group, criterion_main};
use milli::update::Settings;
use utils::Conf;
#[cfg(target_os = "linux")]
#[global_allocator]
static ALLOC: jemallocator::Jemalloc = jemallocator::Jemalloc;
#[cfg(target_os = "macos")]
#[global_allocator]
static ALLOC: mimalloc::MiMalloc = mimalloc::MiMalloc;