From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 2F25A3858002; Thu, 28 Apr 2022 11:51:33 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 2F25A3858002 From: "jakub at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug debug/105415] [9/10/11/12 Regression] '-fcompare-debug' failure w/ -O2 -ftree-parallelize-loops=2 since r7-4900-g59ec925b1199f9 Date: Thu, 28 Apr 2022 11:51:33 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: debug X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: compare-debug-failure X-Bugzilla-Severity: normal X-Bugzilla-Who: jakub at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 10.4 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, 28 Apr 2022 11:51:33 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D105415 --- Comment #5 from Jakub Jelinek --- I've included debug printouts into the if (x_node =3D=3D NULL) body before = return 0; and sort -u of the dump shows in powerpc64le-linux bootstrap so far (still ongoing) shows: ../../gcc/fortran/decl.cc match_attr_spec *.LC320 ../../gcc/fortran/decl.cc match_attr_spec *.LC455 ../../gcc/fortran/decl.cc match_attr_spec *.LC456 ../../gcc/fortran/decl.cc match_attr_spec *.LC457 ../../gcc/fortran/decl.cc match_attr_spec *.LC458 ../../gcc/fortran/decl.cc match_attr_spec *.LC459 ../../gcc/fortran/decl.cc match_attr_spec *.LC460 ../../gcc/fortran/decl.cc match_attr_spec *.LC461 ../../gcc/fortran/decl.cc match_attr_spec *.LC462 ../../gcc/fortran/decl.cc match_attr_spec *.LC463 ../../gcc/fortran/decl.cc match_attr_spec *.LC464 ../../gcc/fortran/decl.cc match_attr_spec *.LC465 ../../gcc/fortran/decl.cc match_attr_spec *.LC466 ../../gcc/fortran/decl.cc match_attr_spec *.LC467 ../../gcc/fortran/decl.cc match_attr_spec *.LC468 ../../gcc/fortran/decl.cc match_attr_spec *.LC469 ../../gcc/fortran/decl.cc match_attr_spec *.LC470 ../../gcc/fortran/decl.cc match_attr_spec *.LC471 ../../gcc/fortran/decl.cc match_attr_spec *.LC472 ../../gcc/fortran/decl.cc match_attr_spec *.LC473 ../../gcc/fortran/decl.cc match_attr_spec *.LC474 ../../gcc/fortran/decl.cc match_attr_spec *.LC475 ../../gcc/fortran/decl.cc match_attr_spec *.LC476 ../../gcc/fortran/parse.cc next_statement *.LC704 ../../gcc/fortran/scanner.cc gfc_next_char_literal *.LC52 ../../gcc/fortran/scanner.cc gfc_next_char_literal *.LC53 ../../gcc/fortran/scanner.cc gfc_next_char_literal *.LC57 ../../gcc/fortran/scanner.cc load_file *.LC102 so seems decls without varpool nodes are mostly constant pool decls. So perhaps --- gcc/alias.cc.jj 2022-04-28 12:33:15.169434009 +0200 +++ gcc/alias.cc 2022-04-28 13:47:34.402456905 +0200 @@ -2219,12 +2219,19 @@ compare_base_symbol_refs (const_rtx x_ba || (!TREE_STATIC (x_decl) && !TREE_PUBLIC (x_decl))) return 0; - symtab_node *x_node =3D symtab_node::get_create (x_decl) - ->ultimate_alias_target (); - /* External variable cannot be in section anchor. */ - if (!x_node->definition) + symtab_node *x_node =3D symtab_node::get (x_decl); + tree x_decl2 =3D x_decl; + if (x_node !=3D NULL) + { + x_node =3D x_node->ultimate_alias_target (); + /* External variable cannot be in section anchor. */ + if (!x_node->definition) + return 0; + x_decl2 =3D x_node->decl; + } + else if (DECL_EXTERNAL (x_decl)) return 0; - x_base =3D XEXP (DECL_RTL (x_node->decl), 0); + x_base =3D XEXP (DECL_RTL (x_decl2), 0); /* If not in anchor, we can disambiguate. */ if (!SYMBOL_REF_HAS_BLOCK_INFO_P (x_base)) return 0; might be better.=