File tree Expand file tree Collapse file tree 3 files changed +1
-42
lines changed Expand file tree Collapse file tree 3 files changed +1
-42
lines changed Original file line number Diff line number Diff line change 39
39
40
40
fn main ( ) {
41
41
// See the comment at the top of this file for an explanation of this.
42
- #[ cfg( feature = "jemalloc" ) ]
43
- {
44
- use std:: os:: raw:: { c_int, c_void} ;
45
-
46
- use tikv_jemalloc_sys as jemalloc_sys;
47
-
48
- #[ used]
49
- static _F1: unsafe extern "C" fn ( usize , usize ) -> * mut c_void = jemalloc_sys:: calloc;
50
- #[ used]
51
- static _F2: unsafe extern "C" fn ( * mut * mut c_void , usize , usize ) -> c_int =
52
- jemalloc_sys:: posix_memalign;
53
- #[ used]
54
- static _F3: unsafe extern "C" fn ( usize , usize ) -> * mut c_void = jemalloc_sys:: aligned_alloc;
55
- #[ used]
56
- static _F4: unsafe extern "C" fn ( usize ) -> * mut c_void = jemalloc_sys:: malloc;
57
- #[ used]
58
- static _F5: unsafe extern "C" fn ( * mut c_void , usize ) -> * mut c_void = jemalloc_sys:: realloc;
59
- #[ used]
60
- static _F6: unsafe extern "C" fn ( * mut c_void ) = jemalloc_sys:: free;
61
-
62
- // On OSX, jemalloc doesn't directly override malloc/free, but instead
63
- // registers itself with the allocator's zone APIs in a ctor. However,
64
- // the linker doesn't seem to consider ctors as "used" when statically
65
- // linking, so we need to explicitly depend on the function.
66
- #[ cfg( target_os = "macos" ) ]
67
- {
68
- unsafe extern "C" {
69
- fn _rjem_je_zone_register ( ) ;
70
- }
71
-
72
- #[ used]
73
- static _F7: unsafe extern "C" fn ( ) = _rjem_je_zone_register;
74
- }
75
- }
76
-
77
42
rustc_driver:: main ( )
78
43
}
Original file line number Diff line number Diff line change @@ -731,10 +731,7 @@ impl Step for Rustdoc {
731
731
// libraries here. The intuition here is that If we've built a compiler, we should be able
732
732
// to build rustdoc.
733
733
//
734
- let mut extra_features = Vec :: new ( ) ;
735
- if builder. config . jemalloc ( target) {
736
- extra_features. push ( "jemalloc" . to_string ( ) ) ;
737
- }
734
+ let extra_features = Vec :: new ( ) ;
738
735
739
736
let ToolBuildResult { tool_path, build_compiler, target_compiler } =
740
737
builder. ensure ( ToolBuild {
Original file line number Diff line number Diff line change @@ -758,9 +758,6 @@ impl Build {
758
758
crates. is_empty ( ) || possible_features_by_crates. contains ( feature)
759
759
} ;
760
760
let mut features = vec ! [ ] ;
761
- if self . config . jemalloc ( target) && check ( "jemalloc" ) {
762
- features. push ( "jemalloc" ) ;
763
- }
764
761
if ( self . config . llvm_enabled ( target) || kind == Kind :: Check ) && check ( "llvm" ) {
765
762
features. push ( "llvm" ) ;
766
763
}
You can’t perform that action at this time.
0 commit comments