Skip to content

Commit ebc9533

Browse files
committed
Jemalloc updated to tikv-jemalloc-sys for reference.
1 parent e708cbd commit ebc9533

File tree

3 files changed

+24
-22
lines changed

3 files changed

+24
-22
lines changed

Cargo.lock

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1612,17 +1612,6 @@ version = "0.4.6"
16121612
source = "registry+https://github.com/rust-lang/crates.io-index"
16131613
checksum = "dc6f3ad7b9d11a0c00842ff8de1b60ee58661048eb8049ed33c73594f359d7e6"
16141614

1615-
[[package]]
1616-
name = "jemalloc-sys"
1617-
version = "0.3.2"
1618-
source = "registry+https://github.com/rust-lang/crates.io-index"
1619-
checksum = "0d3b9f3f5c9b31aa0f5ed3260385ac205db665baa41d49bb8338008ae94ede45"
1620-
dependencies = [
1621-
"cc",
1622-
"fs_extra",
1623-
"libc",
1624-
]
1625-
16261615
[[package]]
16271616
name = "jobserver"
16281617
version = "0.1.21"
@@ -3406,9 +3395,9 @@ checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2"
34063395
name = "rustc-main"
34073396
version = "0.0.0"
34083397
dependencies = [
3409-
"jemalloc-sys",
34103398
"rustc_codegen_ssa",
34113399
"rustc_driver",
3400+
"tikv-jemalloc-sys",
34123401
]
34133402

34143403
[[package]]
@@ -5065,6 +5054,17 @@ dependencies = [
50655054
name = "tier-check"
50665055
version = "0.1.0"
50675056

5057+
[[package]]
5058+
name = "tikv-jemalloc-sys"
5059+
version = "0.4.1+5.2.1-patched"
5060+
source = "registry+https://github.com/rust-lang/crates.io-index"
5061+
checksum = "8a26331b05179d4cb505c8d6814a7e18d298972f0a551b0e3cefccff927f86d3"
5062+
dependencies = [
5063+
"cc",
5064+
"fs_extra",
5065+
"libc",
5066+
]
5067+
50685068
[[package]]
50695069
name = "time"
50705070
version = "0.1.43"

compiler/rustc/Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@ rustc_driver = { path = "../rustc_driver" }
1111
# crate is intended to be used by codegen backends, which may not be in-tree.
1212
rustc_codegen_ssa = { path = "../rustc_codegen_ssa" }
1313

14-
[dependencies.jemalloc-sys]
15-
version = '0.3.0'
14+
[dependencies.tikv-jemalloc-sys]
15+
version = '0.4.1+5.2.1-patched'
1616
optional = true
1717
features = ['unprefixed_malloc_on_supported_platforms']
1818

1919
[features]
20-
jemalloc = ['jemalloc-sys']
20+
jemalloc = ['tikv-jemalloc-sys']
2121
llvm = ['rustc_driver/llvm']
2222
max_level_info = ['rustc_driver/max_level_info']

compiler/rustc/src/main.rs

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,25 @@ fn main() {
77
// dynamic libraries. That means to pull in jemalloc we need to actually
88
// reference allocation symbols one way or another (as this file is the only
99
// object code in the rustc executable).
10-
#[cfg(feature = "jemalloc-sys")]
10+
#[cfg(feature = "tikv-jemalloc-sys")]
1111
{
1212
use std::os::raw::{c_int, c_void};
1313

1414
#[used]
15-
static _F1: unsafe extern "C" fn(usize, usize) -> *mut c_void = jemalloc_sys::calloc;
15+
static _F1: unsafe extern "C" fn(usize, usize) -> *mut c_void = tikv_jemalloc_sys::calloc;
1616
#[used]
1717
static _F2: unsafe extern "C" fn(*mut *mut c_void, usize, usize) -> c_int =
18-
jemalloc_sys::posix_memalign;
18+
tikv_jemalloc_sys::posix_memalign;
1919
#[used]
20-
static _F3: unsafe extern "C" fn(usize, usize) -> *mut c_void = jemalloc_sys::aligned_alloc;
20+
static _F3: unsafe extern "C" fn(usize, usize) -> *mut c_void =
21+
tikv_jemalloc_sys::aligned_alloc;
2122
#[used]
22-
static _F4: unsafe extern "C" fn(usize) -> *mut c_void = jemalloc_sys::malloc;
23+
static _F4: unsafe extern "C" fn(usize) -> *mut c_void = tikv_jemalloc_sys::malloc;
2324
#[used]
24-
static _F5: unsafe extern "C" fn(*mut c_void, usize) -> *mut c_void = jemalloc_sys::realloc;
25+
static _F5: unsafe extern "C" fn(*mut c_void, usize) -> *mut c_void =
26+
tikv_jemalloc_sys::realloc;
2527
#[used]
26-
static _F6: unsafe extern "C" fn(*mut c_void) = jemalloc_sys::free;
28+
static _F6: unsafe extern "C" fn(*mut c_void) = tikv_jemalloc_sys::free;
2729
}
2830

2931
rustc_driver::set_sigpipe_handler();

0 commit comments

Comments
 (0)