public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "pdimov at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug libstdc++/114865] std::atomic<X>::compare_exchange_strong seems to hang under GCC 13 on Ubuntu 23.04
Date: Fri, 26 Apr 2024 17:47:10 +0000	[thread overview]
Message-ID: <bug-114865-4-dfecN69XoB@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-114865-4@http.gcc.gnu.org/bugzilla/>

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114865

--- Comment #1 from Peter Dimov <pdimov at gmail dot com> ---
> The problem may well be inside libatomic, of course; I have no way to tell.

Narrator: but he did, in fact, have a way to tell.

This is a GHA run with GCC 9 to 13 tested on both Ubuntu 23.04 and Ubuntu
23.10, and only GCC 13 hangs.

https://github.com/boostorg/uuid/actions/runs/8852038822/job/24309866206

And indeed, the codegen from GCC 12 (https://godbolt.org/z/xc7oT76fn) is
radically different from (and much simpler than) the GCC 13 one
(https://godbolt.org/z/eP48xv3Mr).

I think that the problem has been introduced with this commit:

https://github.com/gcc-mirror/gcc/commit/157236dbd621644b3cec50b6cf38811959f3e78c

which, ironically enough, was supposed to improve the handling of types with
padding bits, but broke them entirely.

(I told the committee there was nothing wrong with compare_exchange as
specified, but did they listen to me? To ask the question is to answer it.)

  reply	other threads:[~2024-04-26 17:47 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-26 15:50 [Bug libstdc++/114865] New: " pdimov at gmail dot com
2024-04-26 17:47 ` pdimov at gmail dot com [this message]
2024-04-26 19:40 ` [Bug libstdc++/114865] " pdimov at gmail dot com
2024-04-26 23:14 ` [Bug libstdc++/114865] [13/14/15 Regression] " pinskia at gcc dot gnu.org
2024-04-26 23:16 ` pinskia at gcc dot gnu.org
2024-04-27  0:13 ` pdimov at gmail dot com
2024-04-27  0:16 ` pinskia at gcc dot gnu.org
2024-04-27  0:16 ` pinskia at gcc dot gnu.org
2024-04-27  0:22 ` pinskia at gcc dot gnu.org
2024-04-27  0:25 ` pinskia at gcc dot gnu.org
2024-04-27  0:29 ` pdimov at gmail dot com
2024-04-27  0:31 ` pdimov at gmail dot com
2024-04-27  0:35 ` [Bug libstdc++/114865] [13/14/15 Regression] std::atomic<X>::compare_exchange_strong seems to hang under GCC 13 for C++11 pinskia at gcc dot gnu.org
2024-04-27  0:38 ` pdimov at gmail dot com
2024-04-27  0:42 ` pinskia at gcc dot gnu.org
2024-04-27  0:42 ` pdimov at gmail dot com
2024-05-02 11:40 ` redi at gcc dot gnu.org
2024-05-02 11:41 ` redi at gcc dot gnu.org
2024-05-02 11:44 ` redi at gcc dot gnu.org
2024-05-02 11:47 ` redi at gcc dot gnu.org
2024-05-02 11:55 ` redi at gcc dot gnu.org
2024-05-02 15:13 ` pdimov at gmail dot com
2024-05-21  9:20 ` jakub at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-114865-4-dfecN69XoB@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).