From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 3AEF33840C10; Tue, 9 Feb 2021 18:52:27 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3AEF33840C10 From: "bergner at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/99041] combine creates invalid address which ICEs in decompose_normal_address Date: Tue, 09 Feb 2021 18:52:27 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: rtl-optimization X-Bugzilla-Version: 11.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: bergner 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: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_status everconfirmed cf_reconfirmed_on 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: Tue, 09 Feb 2021 18:52:27 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D99041 Peter Bergner changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever confirmed|0 |1 Last reconfirmed| |2021-02-09 --- Comment #1 from Peter Bergner --- This looks like a combine issue. Before combine, we have: (insn 124 123 125 3 (set (reg:V2DF 198 [ MEM [(void *)_75] ]) (mem:V2DF (reg:DI 149 [ ivtmp.49 ]) [0 MEM [(void *)_75]+0 S16 A8])) "bug.ii":22:67 1130 {vsx_movv2df_64bit} (nil)) (insn 125 124 126 3 (set (reg:DI 199) (plus:DI (reg:DI 142 [ _63 ]) (reg:DI 149 [ ivtmp.49 ]))) "bug.ii":22:67 66 {*adddi3} (nil)) (insn 126 125 127 3 (set (reg:V2DF 200 [ MEM [(void *)_24 + _16 * 1] ]) (mem:V2DF (plus:DI (reg:DI 199) (reg:DI 197)) [0 MEM [(void *)_24 + _16 * 1]+0 S16 A8]= )) "bug.ii":22:67 1130 {vsx_movv2df_64bit} (expr_list:REG_DEAD (reg:DI 199) (nil))) (insn 127 126 128 3 (set (reg:OO 138 [ _41 ]) (unspec:OO [ (subreg:V16QI (reg:V2DF 198 [ MEM [(void *)_75] ]) 0) (subreg:V16QI (reg:V2DF 200 [ MEM [(void *)_24 + _16 *= 1] ]) 0) ] UNSPEC_MMA_ASSEMBLE)) 2074 {*mma_assemble_pair} (expr_list:REG_DEAD (reg:V2DF 200 [ MEM [(void *)_24 + _16 * 1] ]) (expr_list:REG_DEAD (reg:V2DF 198 [ MEM [(void *)_75] ]) (nil)))) After combine, we have: (note 124 123 125 3 NOTE_INSN_DELETED) (note 125 124 126 3 NOTE_INSN_DELETED) (note 126 125 127 3 NOTE_INSN_DELETED) (insn 127 126 128 3 (set (reg:OO 138 [ _41 ]) (unspec:OO [ (mem:V16QI (reg:DI 149 [ ivtmp.49 ]) [0 MEM [(void *)_75]+0 S16 A8]) (mem:V16QI (plus:DI (plus:DI (reg:DI 142 [ _63 ]) (reg:DI 149 [ ivtmp.49 ])) (reg:DI 197)) [0 MEM [(void *)_24 + _16 * 1]+0= S16 A8]) ] UNSPEC_MMA_ASSEMBLE)) 2074 {*mma_assemble_pair} (nil)) That bad address on the 2nd mem then makes it all the way to LRA which eventually dies when it calls decompose_normal_address on it. Segher, is combine allowed to create invalid addresses like that and LRA is supposed to fix it up or is this really a combine issue?=