1
Fork 0

switch jemalloc-sys back to tikv-jemalloc-sys, and update to 0.6.0

This commit is contained in:
Rémy Rakic 2024-12-02 16:16:41 +00:00
parent efdd9e8020
commit a69fe84ec8
7 changed files with 23 additions and 19 deletions

View file

@ -1877,16 +1877,6 @@ version = "1.0.11"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b"
[[package]]
name = "jemalloc-sys"
version = "0.5.4+5.3.0-patched"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ac6c1946e1cea1788cbfde01c993b52a10e2da07f4bac608228d1bed20bfebf2"
dependencies = [
"cc",
"libc",
]
[[package]] [[package]]
name = "jobserver" name = "jobserver"
version = "0.1.32" version = "0.1.32"
@ -2287,7 +2277,6 @@ dependencies = [
"ctrlc", "ctrlc",
"directories", "directories",
"getrandom", "getrandom",
"jemalloc-sys",
"libc", "libc",
"libffi", "libffi",
"libloading", "libloading",
@ -2297,6 +2286,7 @@ dependencies = [
"rustc_version", "rustc_version",
"smallvec", "smallvec",
"tempfile", "tempfile",
"tikv-jemalloc-sys",
"ui_test", "ui_test",
"windows-sys 0.52.0", "windows-sys 0.52.0",
] ]
@ -3151,12 +3141,12 @@ checksum = "583034fd73374156e66797ed8e5b0d5690409c9226b22d87cb7f19821c05d152"
name = "rustc-main" name = "rustc-main"
version = "0.0.0" version = "0.0.0"
dependencies = [ dependencies = [
"jemalloc-sys",
"rustc_codegen_ssa", "rustc_codegen_ssa",
"rustc_driver", "rustc_driver",
"rustc_driver_impl", "rustc_driver_impl",
"rustc_smir", "rustc_smir",
"stable_mir", "stable_mir",
"tikv-jemalloc-sys",
] ]
[[package]] [[package]]
@ -5260,6 +5250,16 @@ dependencies = [
name = "tier-check" name = "tier-check"
version = "0.1.0" version = "0.1.0"
[[package]]
name = "tikv-jemalloc-sys"
version = "0.6.0+5.3.0-1-ge13ca993e8ccb9ba9847cc330696e02839f328f7"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "cd3c60906412afa9c2b5b5a48ca6a5abe5736aec9eb48ad05037a677e52e4e2d"
dependencies = [
"cc",
"libc",
]
[[package]] [[package]]
name = "time" name = "time"
version = "0.3.36" version = "0.3.36"

View file

@ -20,14 +20,14 @@ rustc_smir = { path = "../rustc_smir" }
stable_mir = { path = "../stable_mir" } stable_mir = { path = "../stable_mir" }
# tidy-alphabetical-end # tidy-alphabetical-end
[dependencies.jemalloc-sys] [dependencies.tikv-jemalloc-sys]
version = "0.5.0" version = "0.6.0"
optional = true optional = true
features = ['unprefixed_malloc_on_supported_platforms'] features = ['unprefixed_malloc_on_supported_platforms']
[features] [features]
# tidy-alphabetical-start # tidy-alphabetical-start
jemalloc = ['dep:jemalloc-sys'] jemalloc = ['dep:tikv-jemalloc-sys']
llvm = ['rustc_driver_impl/llvm'] llvm = ['rustc_driver_impl/llvm']
max_level_info = ['rustc_driver_impl/max_level_info'] max_level_info = ['rustc_driver_impl/max_level_info']
rustc_randomized_layouts = ['rustc_driver_impl/rustc_randomized_layouts'] rustc_randomized_layouts = ['rustc_driver_impl/rustc_randomized_layouts']

View file

@ -43,6 +43,8 @@ fn main() {
{ {
use std::os::raw::{c_int, c_void}; use std::os::raw::{c_int, c_void};
use tikv_jemalloc_sys as jemalloc_sys;
#[used] #[used]
static _F1: unsafe extern "C" fn(usize, usize) -> *mut c_void = jemalloc_sys::calloc; static _F1: unsafe extern "C" fn(usize, usize) -> *mut c_void = jemalloc_sys::calloc;
#[used] #[used]

View file

@ -68,7 +68,7 @@ extern crate test;
// See docs in https://github.com/rust-lang/rust/blob/master/compiler/rustc/src/main.rs // See docs in https://github.com/rust-lang/rust/blob/master/compiler/rustc/src/main.rs
// about jemalloc. // about jemalloc.
#[cfg(feature = "jemalloc")] #[cfg(feature = "jemalloc")]
extern crate jemalloc_sys; extern crate tikv_jemalloc_sys as jemalloc_sys;
use std::env::{self, VarError}; use std::env::{self, VarError};
use std::io::{self, IsTerminal}; use std::io::{self, IsTerminal};

View file

@ -31,8 +31,8 @@ directories = "5"
# Copied from `compiler/rustc/Cargo.toml`. # Copied from `compiler/rustc/Cargo.toml`.
# But only for some targets, it fails for others. Rustc configures this in its CI, but we can't # But only for some targets, it fails for others. Rustc configures this in its CI, but we can't
# easily use that since we support of-tree builds. # easily use that since we support of-tree builds.
[target.'cfg(any(target_os = "linux", target_os = "macos"))'.dependencies.jemalloc-sys] [target.'cfg(any(target_os = "linux", target_os = "macos"))'.dependencies.tikv-jemalloc-sys]
version = "0.5.0" version = "0.6.0"
features = ['unprefixed_malloc_on_supported_platforms'] features = ['unprefixed_malloc_on_supported_platforms']
[target.'cfg(unix)'.dependencies] [target.'cfg(unix)'.dependencies]

View file

@ -316,6 +316,8 @@ fn jemalloc_magic() {
// See there for further comments. // See there for further comments.
use std::os::raw::{c_int, c_void}; use std::os::raw::{c_int, c_void};
use tikv_jemalloc_sys as jemalloc_sys;
#[used] #[used]
static _F1: unsafe extern "C" fn(usize, usize) -> *mut c_void = jemalloc_sys::calloc; static _F1: unsafe extern "C" fn(usize, usize) -> *mut c_void = jemalloc_sys::calloc;
#[used] #[used]

View file

@ -307,7 +307,6 @@ const PERMITTED_RUSTC_DEPENDENCIES: &[&str] = &[
"intl_pluralrules", "intl_pluralrules",
"itertools", "itertools",
"itoa", "itoa",
"jemalloc-sys",
"jobserver", "jobserver",
"lazy_static", "lazy_static",
"leb128", "leb128",
@ -392,6 +391,7 @@ const PERMITTED_RUSTC_DEPENDENCIES: &[&str] = &[
"thiserror-impl", "thiserror-impl",
"thorin-dwp", "thorin-dwp",
"thread_local", "thread_local",
"tikv-jemalloc-sys",
"time", "time",
"time-core", "time-core",
"time-macros", "time-macros",