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

            Bug ID: 113656
           Summary: [x86] ICE in simplify_const_unary_operation, at
                    simplify-rtx.cc:1954 with new -mavx10.1
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: mjires at suse dot cz
                CC: haochen.jiang at intel dot com
  Target Milestone: ---
            Target: x86_64-pc-linux-gnu

Compiling reduced testcase gcc.target/i386/avx512fp16-broadcast-2.c results in
ICE. Bisected to initial AVX10.1 patch r14-5607-g2f8f7ee2db82a3.

$ cat avx512fp16-broadcast-2.c
_Float16 test_256_src[8];
void test_256() {
  for (int i = 0; i < 8; i++)
    test_256_src[i] = i - 8.4;
}


$ gcc avx512fp16-broadcast-2.c -frounding-math -O3 -mavx10.1
-funsafe-math-optimizations
during RTL pass: combine
avx512fp16-broadcast-2.c: In function ‘test_256’:
avx512fp16-broadcast-2.c:5:1: internal compiler error: in
simplify_const_unary_operation, at simplify-rtx.cc:1954
    5 | }
      | ^
0x169ccd4 simplify_const_unary_operation(rtx_code, machine_mode, rtx_def*,
machine_mode)
        /home/mjires/git/GCC/master/gcc/simplify-rtx.cc:1954
0x1698783 simplify_context::simplify_unary_operation(rtx_code, machine_mode,
rtx_def*, machine_mode)
        /home/mjires/git/GCC/master/gcc/simplify-rtx.cc:889
0x1696b93 simplify_context::simplify_gen_unary(rtx_code, machine_mode,
rtx_def*, machine_mode)
        /home/mjires/git/GCC/master/gcc/simplify-rtx.cc:360
0x169a0bb simplify_context::simplify_unary_operation_1(rtx_code, machine_mode,
rtx_def*)
        /home/mjires/git/GCC/master/gcc/simplify-rtx.cc:1304
0x16987aa simplify_context::simplify_unary_operation(rtx_code, machine_mode,
rtx_def*, machine_mode)
        /home/mjires/git/GCC/master/gcc/simplify-rtx.cc:893
0x101ade9 simplify_unary_operation(rtx_code, machine_mode, rtx_def*,
machine_mode)
        /home/mjires/git/GCC/master/gcc/rtl.h:3486
0x2e56f58 combine_simplify_rtx
        /home/mjires/git/GCC/master/gcc/combine.cc:5690
0x2e56c13 subst
        /home/mjires/git/GCC/master/gcc/combine.cc:5609
0x2e56946 subst
        /home/mjires/git/GCC/master/gcc/combine.cc:5536
0x2e56946 subst
        /home/mjires/git/GCC/master/gcc/combine.cc:5536
0x2e4f6f1 try_combine
        /home/mjires/git/GCC/master/gcc/combine.cc:3302
0x2e49be5 combine_instructions
        /home/mjires/git/GCC/master/gcc/combine.cc:1264
0x2e71cf2 rest_of_handle_combine
        /home/mjires/git/GCC/master/gcc/combine.cc:15091
0x2e71dae execute
        /home/mjires/git/GCC/master/gcc/combine.cc:15135
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.


$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/home/mjires/built/master/libexec/gcc/x86_64-pc-linux-gnu/14.0.1/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /home/mjires/git/GCC/master/configure
--prefix=/home/mjires/built/master --disable-bootstrap
--enable-languages=c,c++,fortran,lto --disable-multilib --disable-libsanitizer
--enable-checking : (reconfigured) /home/mjires/git/GCC/master/configure
--prefix=/home/mjires/built/master --disable-bootstrap
--enable-languages=c,c++,fortran,lto --disable-multilib --disable-libsanitizer
--enable-checking
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 14.0.1 20240129 (experimental) (GCC)

Reply via email to