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

            Bug ID: 117816
           Summary: ICE: in rtl_verify_bb_insns, at cfgrtl.cc:2837: flow
                    control insn inside a basic block with -O
                    -favoid-store-forwarding -fnon-call-exceptions
                    -fno-forward-propagate -finstrument-functions
           Product: gcc
           Version: 15.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: rtl-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zsojka at seznam dot cz
  Target Milestone: ---
              Host: x86_64-pc-linux-gnu
            Target: x86_64-pc-linux-gnu

Created attachment 59730
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=59730&action=edit
reduced testcase

Compiler output:
$ x86_64-pc-linux-gnu-gcc -O -fnon-call-exceptions -favoid-store-forwarding
-fno-forward-propagate -finstrument-functions testcase.c
testcase.c: In function 'foo':
testcase.c:9:1: error: in basic block 2:
    9 | }
      | ^
testcase.c:9:1: error: flow control insn inside a basic block
(insn 18 60 61 2 (set (reg:SI 104 [ _11 ])
        (mem:SI (reg/f:DI 110) [2 MEM[(int *)_3]+0 S4 A32])) "testcase.c":8:8
discrim 1 96 {*movsi_internal}
     (expr_list:REG_DEAD (reg/f:DI 110)
        (expr_list:REG_EH_REGION (const_int 1 [0x1])
            (nil))))
during RTL pass: avoid_store_forwarding
testcase.c:9:1: internal compiler error: in rtl_verify_bb_insns, at
cfgrtl.cc:2837
0x2e559de internal_error(char const*, ...)
        /repo/gcc-trunk/gcc/diagnostic-global-context.cc:517
0xebbcab fancy_abort(char const*, int, char const*)
        /repo/gcc-trunk/gcc/diagnostic.cc:1696
0x83969b _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
        /repo/gcc-trunk/gcc/rtl-error.cc:108
0x10a19c3 rtl_verify_bb_insns
        /repo/gcc-trunk/gcc/cfgrtl.cc:2837
0x10ab0ae rtl_verify_flow_info_1
        /repo/gcc-trunk/gcc/cfgrtl.cc:2924
0x10ab0ae rtl_verify_flow_info
        /repo/gcc-trunk/gcc/cfgrtl.cc:3169
0x108c8bf verify_flow_info()
        /repo/gcc-trunk/gcc/cfghooks.cc:283
0x14fc0c1 execute_function_todo
        /repo/gcc-trunk/gcc/passes.cc:2113
0x14fc647 execute_todo
        /repo/gcc-trunk/gcc/passes.cc:2155
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.

$ x86_64-pc-linux-gnu-gcc -v
Using built-in specs.
COLLECT_GCC=/repo/gcc-trunk/binary-latest-amd64/bin/x86_64-pc-linux-gnu-gcc
COLLECT_LTO_WRAPPER=/repo/gcc-trunk/binary-trunk-20241127062712-r15-5717-g32f6485849c826-checking-yes-rtl-df-extra-amd64/bin/../libexec/gcc/x86_64-pc-linux-gnu/15.0.0/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /repo/gcc-trunk//configure --enable-languages=c,c++
--enable-valgrind-annotations --disable-nls --enable-checking=yes,rtl,df,extra
--with-cloog --with-ppl --with-isl --build=x86_64-pc-linux-gnu
--host=x86_64-pc-linux-gnu --target=x86_64-pc-linux-gnu
--with-ld=/usr/bin/x86_64-pc-linux-gnu-ld
--with-as=/usr/bin/x86_64-pc-linux-gnu-as --enable-libsanitizer
--disable-libstdcxx-pch
--prefix=/repo/gcc-trunk//binary-trunk-20241127062712-r15-5717-g32f6485849c826-checking-yes-rtl-df-extra-amd64
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 15.0.0 20241127 (experimental) (GCC)

Reply via email to