public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "niancw29 at 163 dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/102858] New: ICE when compiling <thread> to "thread.gcm"
Date: Wed, 20 Oct 2021 15:05:38 +0000	[thread overview]
Message-ID: <bug-102858-4@http.gcc.gnu.org/bugzilla/> (raw)

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

            Bug ID: 102858
           Summary: ICE when compiling <thread> to "thread.gcm"
           Product: gcc
           Version: 11.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: niancw29 at 163 dot com
  Target Milestone: ---

Created attachment 51637
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=51637&action=edit
preprocessed file

Target: x86_64-pc-linux-gnu
Configured with: ../gcc-11.2.0/configure --disable-multilib
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 11.2.0 (GCC) 

command: g++ -std=c++20 -fmodules-ts -c -x c++-system-header thread
the compiler output: 

In file included from /usr/local/include/c++/11.2.0/bits/atomic_base.h:38,
                 from /usr/local/include/c++/11.2.0/atomic:41,
of module /usr/local/include/c++/11.2.0/atomic, imported at
/usr/local/include/c++/11.2.0/stop_token:34,
        included from /usr/local/include/c++/11.2.0/thread:40:
/usr/local/include/c++/11.2.0/bits/move.h: In instantiation of ‘constexpr
std::_Require<std::__not_<std::__is_tuple_like<_Tp> >,
std::is_move_constructible<_Tp>, std::is_move_assignable<_Tp> > std::swap(_Tp&,
_Tp&) [with _Tp = std::thread::id;
std::_Require<std::__not_<std::__is_tuple_like<_Tp> >,
std::is_move_constructible<_Tp>, std::is_move_assignable<_Tp> > = void]’:
/usr/local/include/c++/11.2.0/bits/std_thread.h:172:16:   required from here
/usr/local/include/c++/11.2.0/bits/move.h:204:19: internal compiler error: in
tsubst_copy, at cp/pt.c:16621
  204 |       _Tp __tmp = _GLIBCXX_MOVE(__a);
      |                   ^~~~~~~~~~~~~
0x62699c tsubst_copy
        ../../gcc-11.2.0/gcc/cp/pt.c:16621
0x7c15ce tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:20782
0x7c1dbb tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:19548
0x7c1dbb tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:19680
0x7c19bd tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:19548
0x7c19bd tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:20206
0x7d3124 tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*, bool,
bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:19548
0x7d3124 tsubst_expr(tree_node*, tree_node*, int, tree_node*, bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:19159
0x7d923c tsubst_expr(tree_node*, tree_node*, int, tree_node*, bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:16527
0x7d923c tsubst_init
        ../../gcc-11.2.0/gcc/cp/pt.c:16531
0x7d6121 tsubst_expr(tree_node*, tree_node*, int, tree_node*, bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:18368
0x7d4d6a tsubst_expr(tree_node*, tree_node*, int, tree_node*, bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:18184
0x7d4d6a tsubst_expr(tree_node*, tree_node*, int, tree_node*, bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:18199
0x7d3c5f tsubst_expr(tree_node*, tree_node*, int, tree_node*, bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:18184
0x7d3c5f tsubst_expr(tree_node*, tree_node*, int, tree_node*, bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:18550
0x7c7749 tsubst_expr(tree_node*, tree_node*, int, tree_node*, bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:25876
0x7c7749 instantiate_body
        ../../gcc-11.2.0/gcc/cp/pt.c:25876
0x7c809f instantiate_decl(tree_node*, bool, bool)
        ../../gcc-11.2.0/gcc/cp/pt.c:26170
0x7e3cfb instantiate_pending_templates(int)
        ../../gcc-11.2.0/gcc/cp/pt.c:26249
0x6f5fa8 c_parse_final_cleanups()
        ../../gcc-11.2.0/gcc/cp/decl2.c:4962

             reply	other threads:[~2021-10-20 15:05 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-20 15:05 niancw29 at 163 dot com [this message]
2021-10-20 15:39 ` [Bug c++/102858] " redi 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-102858-4@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).