hey there, I just read the release notes of mold-1.7.0 and it states that a certain fix for dev-cpp/tbb is needed if you do use system-tbb: from the release notes: mold 1.7.0 is a new release of the high-speed linker. Just like previous versions, you need to apply oneapi-src/oneTBB@137c1a8 to libtbb if you do not use a bundled version of OneTBB library. OneTBB has merged this patch, but the most recent release of OneTBB hasn't picked it up yet. link: https://github.com/oneapi-src/oneTBB/commit/137c1a88b690acf3525e0f279720ac489ce66481
from the issue/bug report: >On many Unix-like systems, pthread_create can fail spuriously even if >the running machine has enough resources to spawn a new thread. >Therefore, if EAGAIN is returned from pthread_create, we actually have >to try again. >I observed this issue when running the mold linker >(https://github.com/rui314/mold) under a heavy load. mold uses OneTBB >for parallelization.
Sorry, I thought we had. Good spot!
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ae4a95da4cdb44ac97adfc4c48d89317c315b5d1 commit ae4a95da4cdb44ac97adfc4c48d89317c315b5d1 Author: Sam James <sam@gentoo.org> AuthorDate: 2022-11-19 02:27:29 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2022-11-19 03:19:13 +0000 dev-cpp/tbb: backport pthread EAGAIN patch for mold Closes: https://bugs.gentoo.org/881161 Signed-off-by: Sam James <sam@gentoo.org> .../tbb/files/tbb-2021.7.0-pthread-eagain.patch | 135 +++++++++++++++++++++ dev-cpp/tbb/tbb-2021.7.0-r1.ebuild | 41 +++++++ 2 files changed, 176 insertions(+)
The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=55b2421aad41d6b1fed898ae6d551fd6f7c7e3d9 commit 55b2421aad41d6b1fed898ae6d551fd6f7c7e3d9 Author: Sam James <sam@gentoo.org> AuthorDate: 2023-01-05 00:38:12 +0000 Commit: Sam James <sam@gentoo.org> CommitDate: 2023-01-05 00:38:12 +0000 sys-devel/mold: depend on fixed dev-cpp/tbb for pthreads Bug: https://bugs.gentoo.org/881161 Signed-off-by: Sam James <sam@gentoo.org> sys-devel/mold/{mold-1.7.1.ebuild => mold-1.7.1-r1.ebuild} | 4 ++-- sys-devel/mold/{mold-1.8.0.ebuild => mold-1.8.0-r1.ebuild} | 4 ++-- sys-devel/mold/mold-9999.ebuild | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-)