From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id EC9C73851C00; Fri, 3 Mar 2023 19:10:36 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org EC9C73851C00 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1677870636; bh=iGDHb/xdwLA8jZBnazxZuo16iExkGOJ/6dyruTIjXOw=; h=From:To:Subject:Date:In-Reply-To:References:From; b=nWR74RXddjyLML/xnoq2ztuqEX+srJcsPjnXoiLstPRYgArPgKRxyDRz/9GG5fg0d zHdhj4O3Iz2UUdaEbFp5ORYtxBize8enL2fZ1MCzonLcsmUzVbspj+tGfVTqP+H7Le gvYdQaaMXhxDyryTHgF+dWEQCwOrRSu0LppW3plY= From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/104852] std::[j]thread::detach() still gives segmentation faults with glibc 2.34 Date: Fri, 03 Mar 2023 19:10:31 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Version: 11.2.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D104852 --- Comment #8 from CVS Commits --- The master branch has been updated by Alexandre Oliva : https://gcc.gnu.org/g:21edd841611a97442a6b95e8ec7e91ff8fd3a451 commit r13-6461-g21edd841611a97442a6b95e8ec7e91ff8fd3a451 Author: Alexandre Oliva Date: Fri Mar 3 15:59:36 2023 -0300 link pthread_join from std::thread ctor Like pthread_create, pthread_join may fail to be statically linked in absent strong uses, so add to user code strong references to both when std::thread objects are created. for libstdc++-v3/ChangeLog PR libstdc++/104852 PR libstdc++/95989 PR libstdc++/52590 * include/bits/std_thread.h (thread::_M_thread_deps): New static implicitly-inline member function. (std::thread template ctor): Pass it to _M_start_thread. * src/c++11/thread.cc (thread::_M_start_thread): Name depend parameter, force it live on entry.=