public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "patrick at rivosinc dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/112535] New: [14] RISC-V ICE: error: unable to find a register to spill during RTL pass: reload
Date: Wed, 15 Nov 2023 01:54:38 +0000	[thread overview]
Message-ID: <bug-112535-4@http.gcc.gnu.org/bugzilla/> (raw)

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112535

            Bug ID: 112535
           Summary: [14] RISC-V ICE: error: unable to find a register to
                    spill during RTL pass: reload
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: patrick at rivosinc dot com
  Target Milestone: ---

Created attachment 56587
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56587&action=edit
-freport-bug output

> /scratch/tc-testing/tc-bisect-nov-7-2/build-rv64gc/bin/riscv64-unknown-linux-gnu-gcc -march=rv64gcv -mabi=lp64d -O2 red.c -freport-bug
red.c: In function 'g':
red.c:14:1: error: unable to find a register to spill
   14 | }
      | ^
red.c:14:1: error: this is the insn:
(insn 22 43 38 4 (set (mem:SI (subreg:DI (reg:V1DI 155 [orig:137 vect_a.17 ]
[137]) 0) [5 *_37+0 S4 A32])
        (const_int 0 [0])) "red.c":13:10 207 {*movsi_internal}
     (expr_list:REG_DEAD (reg:V1DI 155 [orig:137 vect_a.17 ] [137])
        (nil)))
during RTL pass: reload
red.c:14:1: internal compiler error: in lra_split_hard_reg_for, at
lra-assigns.cc:1861
0xa10e93 _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
        ../../../gcc/gcc/rtl-error.cc:108
0x1073958 lra_split_hard_reg_for()
        ../../../gcc/gcc/lra-assigns.cc:1861
0x106d339 lra(_IO_FILE*)
        ../../../gcc/gcc/lra.cc:2495
0x1024119 do_reload
        ../../../gcc/gcc/ira.cc:5973
0x1024119 execute
        ../../../gcc/gcc/ira.cc:6161
Please submit a full bug report, with preprocessed source.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
Preprocessed source stored into /tmp/cc1ljSwT.out file, please attach this to
your bugreport

Testcase
int *a, *f;
char b, c;
int ***d;
static int ****e = &d;
void g() {
  c = 3;
  for (; c; c--)
    if (c < 8) {
      f = 0;
      ***e = a;
    }
  if (b)
    ***d = 0;
}

I have not attempted to bisect it yet.

-freport-bug output attached.

             reply	other threads:[~2023-11-15  1:54 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-15  1:54 patrick at rivosinc dot com [this message]
2023-11-15  7:41 ` [Bug target/112535] [14 regression] " cvs-commit at gcc dot gnu.org
2023-11-15 11:58 ` rguenth at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-112535-4@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).