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

--- Comment #10 from Gianfranco <costamagnagianfranco at yahoo dot it> ---
$ gcc -O3  -fstack-protector-strong  -fopenmp -ffast-math 
-fexpensive-optimizations testcase.i -c

This is the minimal cmdline to trigger the issue I could find.


cat testcase.i
typedef struct {
  int width
} dt_bilateral_t;
typedef dt_aligned_pixel_t[4];
#pragma omp declare simd
void dt_bilateral_splat(dt_bilateral_t *b) {
  int oy = b;
  float *buf;
  long offsets[8];
  for (int slice; slice < b; slice++) {
    for (int i; i < b->width; i++) {
      dt_aligned_pixel_t contrib;
      for (int k = 0; k < 4; k++)
        buf[offsets[k]] += contrib[k];
    }
    float *dest, *src = oy;
    for (int i = 0; i < oy; i++)
      dest[i] += src[i];
  }
}

testcase.i:3:1: warning: no semicolon at end of struct or union
    3 | } dt_bilateral_t;
      | ^
testcase.i:4:9: warning: type defaults to 'int' in declaration of
'dt_aligned_pixel_t' [-Wimplicit-int]
    4 | typedef dt_aligned_pixel_t[4];
      |         ^~~~~~~~~~~~~~~~~~
testcase.i: In function 'dt_bilateral_splat':
testcase.i:7:12: warning: initialization of 'int' from 'dt_bilateral_t *' makes
integer from pointer without a cast [-Wint-conversion]
    7 |   int oy = b;
      |            ^
testcase.i:10:25: warning: comparison between pointer and integer
   10 |   for (int slice; slice < b; slice++) {
      |                         ^
testcase.i:16:25: warning: initialization of 'float *' from 'int' makes pointer
from integer without a cast [-Wint-conversion]
   16 |     float *dest, *src = oy;
      |                         ^~
testcase.i: In function 'dt_bilateral_splat.simdclone.3':
testcase.i:20:1: error: unrecognizable insn:
   20 | }
      | ^
(insn 1109 1108 462 62 (set (mem/c:TF (plus:DI (reg/f:DI 31 sp)
                (const_int 512 [0x200])) [9  S16 A8])
        (reg:TF 55 v23)) -1
     (expr_list:REG_DEAD (reg:TF 55 v23)
        (nil)))
during RTL pass: sched_fusion
testcase.i:20:1: internal compiler error: in get_attr_type, at
config/aarch64/aarch64.md:24655
0xb1c083 internal_error(char const*, ...)
        ???:0
0xb0f58b fancy_abort(char const*, int, char const*)
        ???:0
0x77453f _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
        ???:0
0x774573 _fatal_insn_not_found(rtx_def const*, char const*, int, char const*)
        ???:0
0x1148503 get_attr_type(rtx_insn*)
        ???:0
0x10f5a2f schedule_block(basic_block_def**, void*)
        ???:0
0x10cb843 schedule_insns()
        ???:0
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <file:///usr/share/doc/gcc-13/README.Bugs> for instructions.

Reply via email to