From 37f3a39962a0960d02d3a6fb848cc5038942c69d Mon Sep 17 00:00:00 2001 From: xrelkd <46590321+xrelkd@users.noreply.github.com> Date: Sat, 16 Dec 2023 05:52:46 +0800 Subject: [PATCH] feat(treewide): remove `mimalloc` --- Cargo.lock | 23 ----------------------- clipcat-menu/Cargo.toml | 2 -- clipcat-menu/src/main.rs | 5 ----- clipcat-notify/Cargo.toml | 2 -- clipcat-notify/src/main.rs | 4 ---- clipcatctl/Cargo.toml | 2 -- clipcatctl/src/main.rs | 5 ----- clipcatd/Cargo.toml | 2 -- clipcatd/src/main.rs | 5 ----- 9 files changed, 50 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 053a06df..85b37161 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -706,7 +706,6 @@ dependencies = [ "clipcat-external-editor", "http 1.0.0", "http-serde", - "mimalloc", "serde", "skim", "snafu", @@ -725,7 +724,6 @@ dependencies = [ "clap_complete", "clipcat-base", "clipcat-server", - "mimalloc", "mime", "serde", "serde_json", @@ -791,7 +789,6 @@ dependencies = [ "directories", "http 1.0.0", "http-serde", - "mimalloc", "mime", "serde", "simdutf8", @@ -817,7 +814,6 @@ dependencies = [ "exitcode", "libc", "linicon", - "mimalloc", "mime", "serde", "simdutf8", @@ -1971,16 +1967,6 @@ version = "0.2.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" -[[package]] -name = "libmimalloc-sys" -version = "0.1.35" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3979b5c37ece694f1f5e51e7ecc871fdb0f517ed04ee45f88d15d6d553cb9664" -dependencies = [ - "cc", - "libc", -] - [[package]] name = "libredox" version = "0.0.1" @@ -2113,15 +2099,6 @@ dependencies = [ "autocfg", ] -[[package]] -name = "mimalloc" -version = "0.1.39" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa01922b5ea280a911e323e4d2fd24b7fe5cc4042e0d2cda3c40775cdc4bdc9c" -dependencies = [ - "libmimalloc-sys", -] - [[package]] name = "mime" version = "0.3.17" diff --git a/clipcat-menu/Cargo.toml b/clipcat-menu/Cargo.toml index 123b324a..f405e0d5 100644 --- a/clipcat-menu/Cargo.toml +++ b/clipcat-menu/Cargo.toml @@ -12,8 +12,6 @@ categories.workspace = true keywords.workspace = true [dependencies] -mimalloc = "0.1" - tracing = "0.1" tracing-journald = "0.3" tracing-subscriber = "0.3" diff --git a/clipcat-menu/src/main.rs b/clipcat-menu/src/main.rs index c9a04b90..35eeb5da 100644 --- a/clipcat-menu/src/main.rs +++ b/clipcat-menu/src/main.rs @@ -3,13 +3,8 @@ mod config; mod error; mod finder; -use mimalloc::MiMalloc; - use self::cli::Cli; -#[global_allocator] -static GLOBAL: MiMalloc = MiMalloc; - fn main() { if let Err(err) = Cli::default().run() { eprintln!("Error: {err}"); diff --git a/clipcat-notify/Cargo.toml b/clipcat-notify/Cargo.toml index bf869e3a..0d8d5200 100644 --- a/clipcat-notify/Cargo.toml +++ b/clipcat-notify/Cargo.toml @@ -12,8 +12,6 @@ categories.workspace = true keywords.workspace = true [dependencies] -mimalloc = "0.1" - serde = { version = "1", features = ["derive"] } serde_json = "1" diff --git a/clipcat-notify/src/main.rs b/clipcat-notify/src/main.rs index 4330b1ef..d955c7b5 100644 --- a/clipcat-notify/src/main.rs +++ b/clipcat-notify/src/main.rs @@ -4,7 +4,6 @@ use std::{io::Write, sync::Arc}; use clap::{CommandFactory, Parser, Subcommand}; use clipcat_base::{ClipFilter, ClipboardKind}; -use mimalloc::MiMalloc; use serde::Serialize; use snafu::ResultExt; use time::OffsetDateTime; @@ -12,9 +11,6 @@ use tokio::runtime::Runtime; use self::error::Error; -#[global_allocator] -static GLOBAL: MiMalloc = MiMalloc; - #[derive(Parser)] #[clap(name = clipcat_base::NOTIFY_PROGRAM_NAME, author, version, about, long_about = None)] struct Cli { diff --git a/clipcatctl/Cargo.toml b/clipcatctl/Cargo.toml index 92fead3b..145c9813 100644 --- a/clipcatctl/Cargo.toml +++ b/clipcatctl/Cargo.toml @@ -12,8 +12,6 @@ categories.workspace = true keywords.workspace = true [dependencies] -mimalloc = "0.1" - tracing = "0.1" tracing-journald = "0.3" tracing-subscriber = "0.3" diff --git a/clipcatctl/src/main.rs b/clipcatctl/src/main.rs index f0dd97e9..98b39b5b 100644 --- a/clipcatctl/src/main.rs +++ b/clipcatctl/src/main.rs @@ -2,13 +2,8 @@ mod cli; mod config; mod error; -use mimalloc::MiMalloc; - use self::cli::Cli; -#[global_allocator] -static GLOBAL: MiMalloc = MiMalloc; - fn main() { match Cli::default().run() { Ok(exit_code) => { diff --git a/clipcatd/Cargo.toml b/clipcatd/Cargo.toml index c5941c20..2e50faf7 100644 --- a/clipcatd/Cargo.toml +++ b/clipcatd/Cargo.toml @@ -12,8 +12,6 @@ categories.workspace = true keywords.workspace = true [dependencies] -mimalloc = "0.1" - tracing = "0.1" tracing-journald = "0.3" tracing-subscriber = "0.3" diff --git a/clipcatd/src/main.rs b/clipcatd/src/main.rs index 7f5c50f5..703c31c1 100644 --- a/clipcatd/src/main.rs +++ b/clipcatd/src/main.rs @@ -3,13 +3,8 @@ mod config; mod error; mod pid_file; -use mimalloc::MiMalloc; - use self::{command::Cli, error::CommandError}; -#[global_allocator] -static GLOBAL: MiMalloc = MiMalloc; - fn main() { if let Err(err) = Cli::default().run() { eprintln!("Error: {err}");