-
-
Notifications
You must be signed in to change notification settings - Fork 37
Closed
JuliaLang/julia
#55574Closed
Copy link
Labels
multithreadingBase.Threads and related functionalityBase.Threads and related functionality
Description
Similar to JuliaLang/julia#42340 we should probably also consider the affinity of the Julia process when deciding how many BLAS threads we spawn by default. Currently, we don't:
➜ sca50297@cl7fr1 ~ julia --threads=auto -q
julia> using LinearAlgebra; BLAS.get_num_threads()
16
julia> Threads.nthreads()
32
julia> Sys.CPU_THREADS
32
julia>
➜ sca50297@cl7fr1 ~ taskset -c 0,1 julia --threads=auto -q
julia> using LinearAlgebra; BLAS.get_num_threads()
16
julia> Threads.nthreads()
2In the latter case, despite the fact that our process is restricted to 2 hardware threads, we spawn 16 BLAS threads. That never seems to be a good choice.
PetrKryslUCSD and ctkelley
Metadata
Metadata
Assignees
Labels
multithreadingBase.Threads and related functionalityBase.Threads and related functionality