From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id BA643384A40A; Thu, 26 Nov 2020 10:17:59 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org BA643384A40A From: "marxin at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug ipa/98000] g++-10 internal compiler error: verify_cgraph_node failed Date: Thu, 26 Nov 2020 10:17:59 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: ipa X-Bugzilla-Version: 10.2.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: marxin at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: marxin 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 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: Thu, 26 Nov 2020 10:17:59 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D98000 --- Comment #4 from Martin Li=C5=A1ka --- Reduced test-case: $ cat pr98000.C struct { template T *operator()(T); } hb_addressof; template static int _hb_cmp_method(Ts.= ..) { return 0; } template inline bool hb_bsearch_impl(K key, V, int compar(void *, void *)) { V p; int __trans_tmp_2 =3D *hb_addressof(key) =3D compar(&__trans_tmp_2, p); return false; } struct hb_array_t { int arrayZ; }; struct hb_sorted_array_t : hb_array_t { void bsearch() { hb_bsearch_impl(bsearch_impl_x, &arrayZ, _hb_cmp_method); } int bsearch_impl_x; }; template struct hb_lazy_loader_t { Returned *operator->(); }; namespace OT { struct COLR; } struct hb_ot_face_t { hb_lazy_loader_t COLR; }; struct { hb_ot_face_t table; } hb_ot_color_glyph_get_layers_face; namespace OT { struct IntType { typedef int wide_type; operator wide_type(); }; struct UnsizedArrayOf; struct OffsetTo { template friend UnsizedArrayOf operator+(Base, OffsetTo); }; template using LOffsetTo =3D OffsetTo; template using LNNOffsetTo =3D LOffsetTo; struct UnsizedArrayOf { void as_array(int); }; struct SortedUnsizedArrayOf { hb_sorted_array_t __trans_tmp_4; void bsearch() { __trans_tmp_4.bsearch(); } }; struct COLR { SortedUnsizedArrayOf __trans_tmp_3; int get_glyph_layers() { __trans_tmp_3.bsearch(); int __trans_tmp_3 =3D numLayers; (this + layersZ).as_array(__trans_tmp_3); } LNNOffsetTo layersZ; IntType numLayers; }; } // namespace OT void hb_ot_color_glyph_get_layers() { hb_ot_color_glyph_get_layers_face.table.COLR->get_glyph_layers(); } fails with: g++ pr98000.C -c -fchecking -Og since r10-7306-g72b3bc895f023bf4=