Skip to content

Commit cf0e254

Browse files
committed
CpuId can only be loaded on x86
1 parent 8639ca8 commit cf0e254

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

src/LinearSolve.jl

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,13 +41,16 @@ import PrecompileTools
4141
import Krylov
4242
using SciMLBase
4343
import Preferences
44-
import CpuId
45-
4644
const CRC = ChainRulesCore
4745

48-
if Preferences.@load_preference("LoadMKL_JLL", !occursin("EPYC", CpuId.cpubrand()))
49-
using MKL_jll
50-
const usemkl = MKL_jll.is_available()
46+
@static if Sys.ARCH === :x86_64 || Sys.ARCH === :i686
47+
import CpuId
48+
if Preferences.@load_preference("LoadMKL_JLL", !occursin("EPYC", CpuId.cpubrand()))
49+
using MKL_jll
50+
const usemkl = MKL_jll.is_available()
51+
else
52+
const usemkl = false
53+
end
5154
else
5255
const usemkl = false
5356
end

0 commit comments

Comments
 (0)