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

            Bug ID: 104279
           Summary: ICE on valid code at -O1 and above on
                    x86_64-linux-gnu: verify_gimple failed
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zhendong.su at inf dot ethz.ch
  Target Milestone: ---

It appears to be a recent regression. 

[551] % gcctk -v
Using built-in specs.
COLLECT_GCC=gcctk
COLLECT_LTO_WRAPPER=/local/suz-local/software/local/gcc-trunk/libexec/gcc/x86_64-pc-linux-gnu/12.0.1/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: ../gcc-trunk/configure --disable-bootstrap
--prefix=/local/suz-local/software/local/gcc-trunk --enable-languages=c,c++
--disable-werror --enable-multilib --with-system-zlib
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 12.0.1 20220129 (experimental) [master r12-6930-gf6f2d6cfec1] (GCC)
[552] %
[552] % gcctk -O0 small.c; ./a.out
[553] %
[553] % gcctk -O1 small.c
small.c: In function ‘main’:
small.c:6:1: error: bogus comparison result type
    6 | }
      | ^
unsigned int
_5 = a.1_3 == 4294967294;
during GIMPLE pass: fre
small.c:6:1: internal compiler error: verify_gimple failed
0xe52365 verify_gimple_in_cfg(function*, bool)
        ../../gcc-trunk/gcc/tree-cfg.cc:5559
0xce8ece execute_function_todo
        ../../gcc-trunk/gcc/passes.cc:2084
0xce9952 execute_todo
        ../../gcc-trunk/gcc/passes.cc:2138
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.
[554] %
[554] % cat small.c
unsigned a, b;
int main() {
  b = ~(0 || ~0);
  a = ~b / ~a;
  return 0;
}

Reply via email to