This helper is for code that coordinates several parallel operations in the
same R process. For an individual fit, use the fitting function's
ncores and nthreads arguments.
Value
A named list with the previous limits blas and openmp, returned
invisibly when setting a limit. NA_integer_ means the corresponding
runtime control is unavailable. Pass the list back with
do.call(l0glmThreads, previous) to restore the limits.
Details
Runtime BLAS control uses the thread API of the BLAS loaded by R. Supported APIs are OpenBLAS, oneMKL, FlexiBLAS and BLIS configured with automatic threading. Other BLAS builds use their existing configuration. OpenMP control applies to the runtime used by L0glm when compiled with OpenMP. Call this helper from the main thread of the R process.
