You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
IntervalArithmetic should respect the number of threads #782
The IntervalArithmetic.jl initialization explicitly sets its OpenBLASConsistentFPCSR library to use Sys.CPU_THREADS ÷ 2 threads.
However it should respect OPENBLAS_NUM_THREADS=1 and LinearAlgebra.BLAS.set_num_threads(1) if these are set, so that users can clamp the number of threads used by their process to a given maximum number.
Of course this could be configurable somehow, but a user needs to be able to guarantee not to have half their CPU taken over by IntervalArithmetic without their knowledge or permission :)
I am not sure it makes sense for LinearAlgebra.BLAS.set_num_threads(1) to also impact OpenBLASConsistentFPCSR.
I think we are doing the same as MKL.jl. Here is a quote from their README file:
To set or get the global number of threads used by MKL, use MKL.{set/get}_num_threads. This does not affect specific domains where the number of threads is set with mkl_domain_set_num_threads. Calling LinearAlgebra.BLAS.{set/get}_num_threads is domain-specific and only refers to the BLAS domain (unlike other backends, where the number of threads used by LAPACK is also modified).
Btw setting the number of threads is done via IntervalArithmetic.configure(; nthreads=1).
Activity
OlivierHnt commentedon Oct 7, 2026
I am not sure it makes sense for
LinearAlgebra.BLAS.set_num_threads(1)to also impactOpenBLASConsistentFPCSR.I think we are doing the same as MKL.jl. Here is a quote from their README file:
Btw setting the number of threads is done via
IntervalArithmetic.configure(; nthreads=1).