Noticed a few issues in the documentation:
https://carstenbauer.github.io/ThreadPinning.jl/stable/refs/api_pinning/
- pinthreads() may not work as expected by the end user. Namely, for such case:

One could expect that 5 Julia threads would be assigned to the first 3 cores:

Which would be consistent with the documentation:

Instead, it is more likely to get something like this:

That is because the number of threads affected is limited by the length of input vector to pinthreads():
https://github.com/carstenbauer/ThreadPinningCore.jl/blob/cb78f3b950af45a3b766bd418806b258eb0ebc90/src/internals.jl#L209
Which is probably intended but may be misleading. I think it is worth mentioning in the documentation this pitfall, which becomes even more important with things like NUMA nodes (part of the threads may be left on another node accidentally) or experiments with oversubscribing.
There is also a typo (highlighted in the screenshot).
- Description of
ThreadPinning.setaffinity_cpuids() is missing: examples for ThreadPinning.setaffinity() are there instead.

Noticed a few issues in the documentation:
https://carstenbauer.github.io/ThreadPinning.jl/stable/refs/api_pinning/
One could expect that 5 Julia threads would be assigned to the first 3 cores:
Which would be consistent with the documentation:
Instead, it is more likely to get something like this:
That is because the number of threads affected is limited by the length of input vector to
pinthreads():https://github.com/carstenbauer/ThreadPinningCore.jl/blob/cb78f3b950af45a3b766bd418806b258eb0ebc90/src/internals.jl#L209
Which is probably intended but may be misleading. I think it is worth mentioning in the documentation this pitfall, which becomes even more important with things like NUMA nodes (part of the threads may be left on another node accidentally) or experiments with oversubscribing.
There is also a typo (highlighted in the screenshot).
ThreadPinning.setaffinity_cpuids()is missing: examples forThreadPinning.setaffinity()are there instead.