https://issues.dlang.org/show_bug.cgi?id=19513

Dlang Bot <dlang-bot@dlang.rocks> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |pull

--- Comment #1 from Dlang Bot <dlang-bot@dlang.rocks> ---
@kubo39 created dlang/phobos pull request #7030 "Fix Issue 19513 - Use
sched_getaffinity(2) to get the number of CPU cores if abailable" fixing this
issue:

- Fix Issue 19513 - Use sched_getaffinity(2) to get the number of CPU
  cores if available

  Currently std.parallelism.totalCPUs is implemented by
  sysconf(_SC_NPROCESSORS_ONLN) on Posix platoform. However, on GNU/Linux,
  usable number of processors may be restricted if a process runs in
  container. In case it's better to use sched_getaffinity(2).

  ref: http://man7.org/linux/man-pages/man1/nproc.1.html

https://github.com/dlang/phobos/pull/7030

--

Reply via email to