From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 92156385841D; Thu, 28 Jul 2022 07:49:53 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 92156385841D From: "yangyujie at loongson dot cn" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/106462] New: LRA on mips64el: unable to reload (subreg:SI (reg:DI)) constrained by "f" Date: Thu, 28 Jul 2022 07:49:53 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 13.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: yangyujie at loongson dot cn X-Bugzilla-Status: UNCONFIRMED 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_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone attachments.created Message-ID: 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 Jul 2022 07:49:53 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D106462 Bug ID: 106462 Summary: LRA on mips64el: unable to reload (subreg:SI (reg:DI)) constrained by "f" Product: gcc Version: 13.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target Assignee: unassigned at gcc dot gnu.org Reporter: yangyujie at loongson dot cn Target Milestone: --- Created attachment 53368 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=3D53368&action=3Dedit -freport-bug dump Hi, compiling the following code with gcc 13.0.0 20220728 (mips64el-linux-gnuabi64): extern void bar (float x, short y); void foo (int argc) { short c =3D argc * 2; float a =3D (float)(short)c, b =3D 9.5; bar (b/a, c); } failed with: mips64el-linux-gnuabi64-gcc fail.c -O1 -mabi=3D64 -msingle-float -S -o /dev= /null fail.c: In function 'foo': fail.c:9:1: error: unable to find a register to spill 9 | } | ^ fail.c:9:1: error: this is the insn: (insn 12 27 15 2 (set (reg:SF 202 [ a ]) (float:SF (subreg/s/u:SI (reg/v:DI 209 [orig:197 c ] [197]) 0))) "fail.c":6:11 270 {floatsisf2} (expr_list:REG_DEAD (reg/v:DI 209 [orig:197 c ] [197]) (nil))) during RTL pass: reload fail.c:9:1: internal compiler error: in lra_split_hard_reg_for, at lra-assigns.cc:1871 Please submit a full bug report, with preprocessed source. See for instructions. Preprocessed source stored into /tmp/ccZs64gB.out file, please attach this = to your bugreport. This bug is also reproducible on gcc-8.3.0, so it seems to be around for qu= ite a while.=