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

--- Comment #2 from Zhendong Su <zhendong.su at inf dot ethz.ch> ---
Another similar/related test:

[553] % gcctk -O2 small.c; ./a.out
[554] % 
[554] % gcctk -O3 small.c
[555] % ./a.out
Aborted
[556] % cat small.c
int a, b;
int main() {
  for (; a < 4; a += 2)
    if (a > 2)
      while (b++);
        ;
  if (a != 4)
    __builtin_abort();
  return 0;
}

Reply via email to