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

            Bug ID: 125025
           Summary: [5-17] ICE at -O1 -fsanitize=undefined during GIMPLE
                    pass: profile_estimate
           Product: gcc
           Version: 17.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: sanitizer
          Assignee: unassigned at gcc dot gnu.org
          Reporter: xxs_chy at outlook dot com
                CC: dodji at gcc dot gnu.org, dvyukov at gcc dot gnu.org,
                    jakub at gcc dot gnu.org, kcc at gcc dot gnu.org
  Target Milestone: ---

Reproducer: https://godbolt.org/z/5h93bs91P

Testcase:
#include <stdint.h>
void f2(int8_t a0) {
  int8_t v4;
  _Bool c7;
  int8_t v8 = 91;
  v4 = v8 + v8;
  v8 = 15 - 50;
  a0 = v8 * v4;
  v8 = v4 - a0;
lbl_br10:
  c7 = a0 <= 0;
  if (c7)
    return;
  v4 = v8 - 24;
  a0 = a0 + v4;
  goto lbl_br10;
}

Command:
> gcc -O1 -fsanitize=undefined case.c
> <GCC ICE dump>

Reply via email to