From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id C349A3858D28; Wed, 7 Sep 2022 20:10:58 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org C349A3858D28 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1662581458; bh=UagD/0tmZZ/jV5w8Gcuk3HM8jRj2V+U96YFuWro+7ww=; h=From:To:Subject:Date:In-Reply-To:References:From; b=yXyVLq4t/B/vtOZ1Q1laOJaWkMif3pFI/bEIBXH1qNBkCg9HWhgPRzVQaAJjzKfbS 4uIMpb9EisCTx8PSoSdbFGrysoh5X3tAVfPH9YDd+10vnPqS+yMrHnarMUKphmu9Xf 4Gztpit6Xc2+cmeLbZl+QbM0xcnshCnP1AEZsgUk= From: "markmigm at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/106820] internal compiler error: in function_and_variable_visibility [for std::shared_ptr{b,??} use via module] Date: Wed, 07 Sep 2022 20:10:57 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 12.2.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: markmigm at gmail dot com X-Bugzilla-Status: UNCONFIRMED 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=3D106820 --- Comment #3 from Mark Millard --- (In reply to Mark Millard from comment #2) I managed to build lang/gcc12 with -g -O0 in use and so can report: The failing assert looks like: gcc_assert ((!DECL_WEAK (node->decl) && !DECL_COMDAT (node->decl)) || TREE_PUBLIC (node->decl) || node->weakref || DECL_EXTERNAL (node->decl)); And in a debugger I see: (lldb) print node->decl->decl_with_vis.weak_flag (unsigned int) $2 =3D 1 (lldb) print node->decl->decl_with_vis.comdat_flag (unsigned int) $3 =3D 0 (lldb) print node->weakref (unsigned int) $4 =3D 0 (lldb) print node->decl->decl_common.decl_flag_1 (unsigned int) $5 =3D 0 and: (lldb) call debug_tree(node->decl) unit-size align:32 warn_if_not_align:0 symtab:0 alias-set -1 canonical-ty= pe 0x8cd415e8 precision:32 min max pointer_to_this reference_to_this > SI size unit-size align:32 warn_if_not_align:0 symtab:0 alias-set -1 canonical-type 0x939e7f18 arg-types chain >> pointer_to_this > addressable used static tree_3 weak in_system_header decl_5 decl_6 DI /usr/local/lib/gcc12/include/c++/aarch64-portbld-freebsd14.0/bits/gthr-defa= ult.h:121:1 align:32 warn_if_not_align:0 context attributes > value readonly constant static "pthread_mutex_unlock\000">> chain >>> full-name "int __gthrw_pthread_mutex_unlock(pthread_mutex**)" module 1:/usr/local/lib/gcc12/include/c++/memory exported chain >=