carstenbauer / ThreadPinning.jl

Readily pin Julia threads to CPU-threads
https://carstenbauer.github.io/ThreadPinning.jl/
MIT License
106 stars 7 forks source link

Disable warning when pinthreads(:affinitymask) under Slurm #88

Closed simonbyrne closed 7 months ago

simonbyrne commented 7 months ago

In a slurm job:

julia> pinthreads(:affinitymask)
┌ Warning: You seem to be running in a SLURM allocation that doesn't cover the entire node. Most likely, only a subset of the available CPU-threads will be accessible. This might lead to unexpected pinning results.
└ @ ThreadPinning ~/.julia/packages/ThreadPinning/BPm8Z/src/pinning.jl:272

From what I understand, pinthreads(:affinitymask) should be safe under Slurm (since Slurm sets the affinity itself)

carstenbauer commented 7 months ago

@simonbyrne I'm confused, this seems to already be implemented. We have warn = false as the default for pinthreads(:affinitymask). I also just confirmed that there is no warning for :affinitymask (there is for other pinning strategies).

Are you perhaps on an old version?

simonbyrne commented 7 months ago

Ah, I was using the latest released version (0.7.17). It is indeed fixed on main.

carstenbauer commented 7 months ago

I wonder why I didn't tag a new release. Will check and release a new version soon.