This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug target/71186] New: PowerPC64: Autovectorised code hits ICE with -O3 -mpower9 -mlra


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

            Bug ID: 71186
           Summary: PowerPC64: Autovectorised code hits ICE with -O3
                    -mpower9 -mlra
           Product: gcc
           Version: 7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: anton at samba dot org
  Target Milestone: ---

The following testcase:

static unsigned short x[(16384/sizeof(unsigned short))] __attribute__ ((aligned
(16)));
static unsigned short y[(16384/sizeof(unsigned short))] __attribute__ ((aligned
(16)));
static unsigned short a;

void obfuscate(void *a, ...);

static void __attribute__((noinline)) do_one(void)
{
 unsigned long i;

 obfuscate(x, y, &a);

 for (i = 0; i < (16384/sizeof(unsigned short)); i++)
  y[i] = a * x[i];

 obfuscate(x, y, &a);
}

int main(void)
{
 unsigned long i;

 for (i = 0; i < 1000000; i++)
  do_one();

 return 0;
}

built with:

gcc -O3 -Wall -mcpu=power9 -mlra testcase.c

gets an ICE:

scale_unsigned_short.c: In function âdo_oneâ:
scale_unsigned_short.c:17:1: error: insn does not satisfy its constraints:
 }
 ^
(insn 81 43 86 3 (set (reg:V8HI 77 0 [199])
        (vec_duplicate:V8HI (const_int 0 [0]))) scale_unsigned_short.c:14 1045
{xxspltib_v8hi_nosplit}
     (expr_list:REG_EQUIV (const_vector:V8HI [
                (const_int 0 [0])
                (const_int 0 [0])
                (const_int 0 [0])
                (const_int 0 [0])
                (const_int 0 [0])
                (const_int 0 [0])
                (const_int 0 [0])
                (const_int 0 [0])
            ])
        (nil)))
scale_unsigned_short.c:17:1: internal compiler error: in
extract_constrain_insn, at recog.c:2190
0x108211f3 _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
        ../../gcc/gcc/rtl-error.c:108
0x1082124b _fatal_insn_not_found(rtx_def const*, char const*, int, char const*)
        ../../gcc/gcc/rtl-error.c:119
0x107e6f57 extract_constrain_insn(rtx_insn*)
        ../../gcc/gcc/recog.c:2190
0x106d5137 check_rtl
        ../../gcc/gcc/lra.c:2022
0x106daa8f lra(_IO_FILE*)
        ../../gcc/gcc/lra.c:2432
0x1067abab do_reload
        ../../gcc/gcc/ira.c:5381
0x1067abab execute
        ../../gcc/gcc/ira.c:5565

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]