From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 6CB563857C51; Thu, 29 Jun 2023 23:01:16 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 6CB563857C51 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1688079676; bh=BFL8HzqkECtINInywJ9kNnwNS+bqnrW9jcv28XrbGiQ=; h=From:To:Subject:Date:In-Reply-To:References:From; b=rowKZDi8QE9RJEG2y/zburRs1Wv8nBiU2m997er3gneSwRt/NaYBsDVxapphOuXaU Zme45i4UirZATUDFQa6o6qfz59QmhXlbwJxX2hOtFpf/X8+y55pmYBPyg2NHDKa3HN QGpAEq5pKIxVhZ2J476K4PMjyYmquOVhK2+Ysp7o= From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/109741] alignas(64) in libstdc++-v3/src/c++11/shared_ptr.cc Date: Thu, 29 Jun 2023 23:01:15 +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: 13.1.0 X-Bugzilla-Keywords: build 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: 11.5 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=3D109741 --- Comment #17 from CVS Commits --- The releases/gcc-13 branch has been updated by Jonathan Wakely : https://gcc.gnu.org/g:dbd4acd72274f3b3d542ebf68f9962eda8f8b769 commit r13-7509-gdbd4acd72274f3b3d542ebf68f9962eda8f8b769 Author: Jonathan Wakely Date: Tue May 16 15:09:20 2023 +0100 libstdc++: Disable cacheline alignment for DJGPP [PR109741] DJGPP (and maybe other targets) uses MAX_OFILE_ALIGNMENT=3D16 which mea= ns that globals (and static objects) can't have alignment greater than 16. This causes an error for the locks defined in src/c++11/shared_ptr.cc because we try to align them to the cacheline size, to avoid false sharing. Add a configure check for the increased alignment, and live with false sharing where we can't increase the alignment. libstdc++-v3/ChangeLog: PR libstdc++/109741 * acinclude.m4 (GLIBCXX_CHECK_ALIGNAS_CACHELINE): Define. * config.h.in: Regenerate. * configure: Regenerate. * configure.ac: Use GLIBCXX_CHECK_ALIGNAS_CACHELINE. * src/c++11/shared_ptr.cc (__gnu_internal::get_mutex): Do not align lock table if not supported. use __GCC_DESTRUCTIVE_SIZE instead of hardcoded 64. (cherry picked from commit 94a311abf783de754f0f1b2d4c1f00a9788e795b)=