From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 4EB933857817; Wed, 12 May 2021 06:49:11 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4EB933857817 From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug go/100537] Bootstrap-O3 and bootstrap-debug fail on 32-bit ARM after gcc-12-657-ga076632e274a Date: Wed, 12 May 2021 06:49:10 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: go X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: ian at airs dot com X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cc assigned_to component 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: Wed, 12 May 2021 06:49:11 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D100537 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |cmang at google dot com, | |iant at google dot com Assignee|unassigned at gcc dot gnu.org |ian at airs dot com Component|middle-end |go --- Comment #4 from Richard Biener --- So the issue is that the go FE creates go..C479 and it somewhere builds the address of it but fails to set TREE_ADDRESSABLE. There are only a few build_fold_addr_expr calls in the FE: > grep -r build_fold_addr . ./go-gcc.cc: tree t =3D build_fold_addr_expr_loc(location.gcc_location(), this->t_); ./go-gcc.cc: tree ret =3D build_fold_addr_expr_loc(location.gcc_location(), func); ./go-gcc.cc: tree ret =3D build_fold_addr_expr_loc(location.gcc_location(), expr); ./go-gcc.cc: fn =3D build_fold_addr_expr_loc(location.gcc_location= (), ./go-gcc.cc:=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20 build_fold_addr_expr_loc(location.gcc_location(), one does mark the object addressable but all the others do not. So for those who can reproduce, run the failing compile in a debugger, see which ADDR_EXPR we complain about and then set a breakpoint in ggc_internal_alloc conditional on the return value being this ADDR_EXPR. That should nail one of the above after which you should call mark_addressable on the object.=