From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 8E8253857BB6; Fri, 15 Jul 2022 11:21:43 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8E8253857BB6 From: "marxin at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/105946] [12 Regression] ICE in maybe_warn_pass_by_reference, at tree-ssa-uninit.cc:843 Date: Fri, 15 Jul 2022 11:21:43 +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: 13.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: marxin at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: rguenth at gcc dot gnu.org X-Bugzilla-Target-Milestone: 12.2 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc keywords 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 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 15 Jul 2022 11:21:43 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D105946 Martin Li=C5=A1ka changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |marxin at gcc dot gnu.org Keywords|needs-reduction | --- Comment #4 from Martin Li=C5=A1ka --- Reduced to something like: $ cat ice.ii void __throw_bad_array_new_length(); template void forward(); template struct __new_allocator { int allocate(long __n, const void * =3D 0) { if (__builtin_expect(__n, false)) if (__n) __throw_bad_array_new_length(); } }; template struct allocator_traits; template struct allocator_traits<__new_allocator<_Tp>> { using allocator_type =3D __new_allocator<_Tp>; using pointer =3D _Tp; using size_type =3D long; static pointer allocate(allocator_type &__a, size_type __n) { __a.allocate(__n); } }; struct __alloc_traits : allocator_traits<__new_allocator> {}; template struct _Rb_tree { struct _Alloc_node { _Alloc_node(_Rb_tree); template void operator()(_Arg) { __new_allocator __trans_tmp_1; __alloc_traits::allocate(__trans_tmp_1, 1); } }; template int _M_insert_(int, int, _Arg &&, _NodeGen &); template int _M_insert_unique(_Arg &&); }; template template int _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_M_insert_( int, int, _Arg &&, _NodeGen &__node_gen) { __node_gen(forward<_Arg>); } template template int _Rb_tree<_Key, _Val, _KeyOfValue, _Compare, _Alloc>::_M_insert_unique( _Arg &&) { int __res_1, __res_0; _Alloc_node __an(*this); _M_insert_(__res_0, __res_1, forward<_Arg>, __an); } struct set { _Rb_tree _M_t; int insert___x; void insert() { _M_t._M_insert_unique(insert___x); } }; main() { set the_set; the_set.insert(); }=