File tree Expand file tree Collapse file tree 2 files changed +18
-9
lines changed
builtins-test-intrinsics/src Expand file tree Collapse file tree 2 files changed +18
-9
lines changed Original file line number Diff line number Diff line change 1313#![ no_std]
1414#![ no_main]
1515
16+ // Ensure this `compiler_builtins` gets used, rather than the version injected from the sysroot.
17+ extern crate compiler_builtins;
1618extern crate panic_handler;
1719
1820#[ cfg( all( not( thumb) , not( windows) , not( target_arch = "wasm32" ) ) ) ]
@@ -592,7 +594,8 @@ fn run() {
592594 bb ( floatunsitf ( bb ( 2 ) ) ) ;
593595 bb ( floatuntidf ( bb ( 2 ) ) ) ;
594596 bb ( floatuntisf ( bb ( 2 ) ) ) ;
595- #[ cfg( f128_enabled) ]
597+ // FIXME(windows): segfault on Windows
598+ #[ cfg( all( f128_enabled, not( windows) ) ) ]
596599 bb ( floatuntitf ( bb ( 2 ) ) ) ;
597600 #[ cfg( f128_enabled) ]
598601 bb ( gttf ( bb ( 2. ) , bb ( 2. ) ) ) ;
@@ -650,14 +653,14 @@ fn something_with_a_dtor(f: &dyn Fn()) {
650653
651654#[ no_mangle]
652655#[ cfg( not( thumb) ) ]
653- fn main ( _argc : core:: ffi:: c_int , _argv : * const * const u8 ) -> core:: ffi:: c_int {
656+ extern "C" fn main ( _argc : core:: ffi:: c_int , _argv : * const * const u8 ) -> core:: ffi:: c_int {
654657 run ( ) ;
655658 0
656659}
657660
658661#[ no_mangle]
659662#[ cfg( thumb) ]
660- pub fn _start ( ) -> ! {
663+ extern "C" fn _start ( ) -> ! {
661664 run ( ) ;
662665 loop { }
663666}
Original file line number Diff line number Diff line change @@ -120,15 +120,21 @@ done
120120
121121rm -f " ${rlib_paths[@]} "
122122
123- build_intrinsics_test () {
124- cargo build --target " $target " -v --package builtins-test-intrinsics " $@ "
123+ run_intrinsics_test () {
124+ if [ " ${NO_STD:- } " = " 1" ]; then
125+ cmd=build
126+ else
127+ cmd=run
128+ fi
129+
130+ cargo " $cmd " --target " $target " -v --package builtins-test-intrinsics " $@ "
125131}
126132
127133# Verify that we haven't dropped any intrinsics/symbols
128- build_intrinsics_test
129- build_intrinsics_test --release
130- build_intrinsics_test --features c
131- build_intrinsics_test --features c --release
134+ run_intrinsics_test
135+ run_intrinsics_test --release
136+ run_intrinsics_test --features c
137+ run_intrinsics_test --features c --release
132138
133139# Verify that there are no undefined symbols to `panic` within our
134140# implementations
You can’t perform that action at this time.
0 commit comments