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

            Bug ID: 112913
           Summary: ICE: in curr_insn_transform, at
                    lra-constraints.cc:4308
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: iamanonymous.cs at gmail dot com
  Target Milestone: ---

*******************************************************************************
OS and Platform:
$ uname -a:
Linux ubuntu 4.15.0-213-generic #224-Ubuntu SMP Mon Jun 19 13:30:12 UTC 2023
x86_64 x86_64 x86_64 GNU/Linux
*******************************************************************************
gcc version:
$ gcc -v
Using built-in specs.
COLLECT_GCC=/root/gcc_set/202311291030/bin/gcc
COLLECT_LTO_WRAPPER=/root/gcc_set/202311291030/libexec/gcc/x86_64-pc-linux-gnu/14.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc/configure --prefix=/root/gcc_set/202311291030
--with-gmp=/root/build_essential --with-mpfr=/root/build_essential
--with-mpc=/root/build_essential --enable-languages=c,c++ --disable-multilib
--with-sanitizer=address,undefined,thread,leak
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 14.0.0 20231129 (experimental) (GCC) 

git version: 99fa0bfd63d97825c4221dcd3123940f1d0e6291
*******************************************************************************
Program:
$ cat mutant.c
typedef unsigned short uint16_t;
uint16_t a;

void
function (uint16_t **p)
{
  a = **p;
}

*******************************************************************************
Compiler explorer: 
Command Lines:
$ gcc -ffixed-rax -ffixed-rbx -ffixed-rcx -ffixed-rdx -ffixed-rdi -ffixed-rsi
-ffixed-r8 -ffixed-r9 -ffixed-r10 -ffixed-r11 -ffixed-r12 -ffixed-r13
-ffixed-r14 -fsanitize=address mutant.c
mutant.c: In function ‘function’:
mutant.c:8:1: error: unable to generate reloads for:
    8 | }
      | ^
(insn 31 30 32 4 (set (reg:CCGC 17 flags)
        (compare:CCGC (reg:QI 113 [ _21 ])
            (reg:QI 109 [ _17 ]))) "mutant.c":7:7 9 {*cmpqi_1}
     (expr_list:REG_DEAD (reg:QI 113 [ _21 ])
        (expr_list:REG_DEAD (reg:QI 109 [ _17 ])
            (nil))))
during RTL pass: reload
mutant.c:8:1: internal compiler error: in curr_insn_transform, at
lra-constraints.cc:4308
0x7e504e _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
        ../../gcc/gcc/rtl-error.cc:108
0x7bb7f8 curr_insn_transform
        ../../gcc/gcc/lra-constraints.cc:4308
0xe32206 lra_constraints(bool)
        ../../gcc/gcc/lra-constraints.cc:5511
0xe1d532 lra(_IO_FILE*)
        ../../gcc/gcc/lra.cc:2419
0xdd3241 do_reload
        ../../gcc/gcc/ira.cc:5973
0xdd3241 execute
        ../../gcc/gcc/ira.cc:6161
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

Also ICE on trunk, compiler explorer: https://godbolt.org/z/q1YT7vKzh
  • [Bug target/112913] New: ICE... iamanonymous.cs at gmail dot com via Gcc-bugs

Reply via email to