@@ -68,7 +68,7 @@ extern crate test;
6868// See docs in https://github.com/rust-lang/rust/blob/master/compiler/rustc/src/main.rs
6969// about jemalloc.
7070#[ cfg( feature = "jemalloc" ) ]
71- extern crate tikv_jemalloc_sys as jemalloc_sys ;
71+ extern crate libmimalloc_sys ;
7272
7373use std:: env:: { self , VarError } ;
7474use std:: io:: { self , IsTerminal } ;
@@ -132,18 +132,18 @@ pub fn main() {
132132 use std:: os:: raw:: { c_int, c_void} ;
133133
134134 #[ used]
135- static _F1: unsafe extern "C" fn ( usize , usize ) -> * mut c_void = jemalloc_sys :: calloc ;
135+ static _F1: unsafe extern "C" fn ( usize , usize ) -> * mut c_void = libmimalloc_sys :: mi_calloc ;
136136 #[ used]
137137 static _F2: unsafe extern "C" fn ( * mut * mut c_void , usize , usize ) -> c_int =
138- jemalloc_sys :: posix_memalign ;
138+ libmimalloc_sys :: mi_posix_memalign ;
139139 #[ used]
140- static _F3: unsafe extern "C" fn ( usize , usize ) -> * mut c_void = jemalloc_sys :: aligned_alloc ;
140+ static _F3: unsafe extern "C" fn ( usize , usize ) -> * mut c_void = libmimalloc_sys :: mi_aligned_alloc ;
141141 #[ used]
142- static _F4: unsafe extern "C" fn ( usize ) -> * mut c_void = jemalloc_sys :: malloc ;
142+ static _F4: unsafe extern "C" fn ( usize ) -> * mut c_void = libmimalloc_sys :: mi_malloc ;
143143 #[ used]
144- static _F5: unsafe extern "C" fn ( * mut c_void , usize ) -> * mut c_void = jemalloc_sys :: realloc ;
144+ static _F5: unsafe extern "C" fn ( * mut c_void , usize ) -> * mut c_void = libmimalloc_sys :: mi_realloc ;
145145 #[ used]
146- static _F6: unsafe extern "C" fn ( * mut c_void ) = jemalloc_sys :: free ;
146+ static _F6: unsafe extern "C" fn ( * mut c_void ) = libmimalloc_sys :: mi_free ;
147147
148148 #[ cfg( target_os = "macos" ) ]
149149 {
0 commit comments