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
std library thread.rs: undo attempt at NetBSD-specific "find parallelism".
First off, I have it on good authority this code is Just Wrong: by
default a given thread does not have affinity to any specific set
of CPUs.
This particular change came with this pull request:
rust-lang#112226
However, even worse, this code causes a segmentation fault for certain
NetBSD target architectures in the "bootstrap" program when building
rust natively on those platforms. So far armv7/9.0, powerpc/10.0_BETA,
and i386/9.3 all crash with a segmentation fault. However, for some
strange reason, this isn't consistent across the board: riscv64/current,
amd64/10.0_BETA, aarch64/9.0 and sparc64/10.0_BETA all pass this
hurdle. A trivial C reimplementation also doesn't crash on any of
these systems, ref. the thread which starts at
https://mail-index.netbsd.org/current-users/2023/10/10/msg044510.html
but also always prints 0. However, if we get a SEGV running this
code, the entire build fails, of course.
So ... while I do not have a full explanation for the SEGVs, this
undoes the addition from pull request 112226, and restores the ability
to build rust natively on the above flagged-as-problematical platforms.
0 commit comments