From 89d99a258e02913af5b012247b7ca719578accd3 Mon Sep 17 00:00:00 2001 From: Tim Besard Date: Thu, 10 Sep 2020 10:51:51 +0200 Subject: [PATCH] Skip some methods on Apple, we already link compiler-rt there. --- base/Base.jl | 8 ++++---- base/runtime/runtime.jl | 14 +++++++++----- 2 files changed, 13 insertions(+), 9 deletions(-) diff --git a/base/Base.jl b/base/Base.jl index d621a4d76c2c13..4a4964c5fd7396 100644 --- a/base/Base.jl +++ b/base/Base.jl @@ -184,10 +184,6 @@ end include("osutils.jl") include("c.jl") -# run-time library -include("runtime/runtime.jl") -using .Runtime - # Core I/O include("io.jl") include("iobuffer.jl") @@ -224,6 +220,10 @@ include("sysinfo.jl") include("libc.jl") using .Libc: getpid, gethostname, time +# run-time library +include("runtime/runtime.jl") +using .Runtime + include("env.jl") # Concurrency diff --git a/base/runtime/runtime.jl b/base/runtime/runtime.jl index a84a667bd0e1a7..24fd80d35297ac 100644 --- a/base/runtime/runtime.jl +++ b/base/runtime/runtime.jl @@ -75,9 +75,11 @@ function truncsfhf2(val::Float32) end reinterpret(Float16, h) end -@ccallable Float16 __truncsfhf2(val::Float32) = truncsfhf2(val) -@ccallable Float16 __gnu_f2h_ieee(val::Float32) = truncsfhf2(val) -@ccallable Float16 __truncdfhf2(x::Float64) = truncsfhf2(Float32(x)) +if !Sys.isapple() + @ccallable Float16 __truncsfhf2(val::Float32) = truncsfhf2(val) + @ccallable Float16 __gnu_f2h_ieee(val::Float32) = truncsfhf2(val) + @ccallable Float16 __truncdfhf2(x::Float64) = truncsfhf2(Float32(x)) +end # extension function extendhfsf2(val::Float16) @@ -121,8 +123,10 @@ function extendhfsf2(val::Float16) end return reinterpret(Float32, ret) end -@ccallable Float32 __extendhfsf2(val::Float16) = extendhfsf2(val) -@ccallable Float32 __gnu_h2f_ieee(val::Float16) = extendhfsf2(val) +if !Sys.isapple() + @ccallable Float32 __extendhfsf2(val::Float16) = extendhfsf2(val) + @ccallable Float32 __gnu_h2f_ieee(val::Float16) = extendhfsf2(val) +end @ccallable Float64 __extendhfdf2(x::Float16) = Float64(extendhfdf2(x)) end