[Bug tree-optimization/125420] [16/17 Regression] compiler hangs at -O3 in PRE
kaelfandrew at gmail dot com
gcc-bugzilla@gcc.gnu.org
Fri May 22 20:46:39 GMT 2026
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125420
--- Comment #4 from Kael Franco <kaelfandrew at gmail dot com> ---
(In reply to XChy from comment #0)
> Reproducer: https://godbolt.org/z/eK4jT1K5a
> Testcase:
> #include <stdint.h>
> int64_t g2;
> _Bool g10, f5_c8;
> void f5()
> {
> int16_t v5;
> _Bool c11;
> lbl_b1:
> g10 = c11 = 9;
> if (f5_c8)
> goto lbl_b6;
> lbl_bf5:
> g10 = 0;
> goto lbl_bf9;
> lbl_b6:
> g2 = 604998164811594898;
> if (g10) goto lbl_bf5;
> switch (v5)
> {
> case 4: goto lbl_sw13;
> default: goto lbl_sw_def14;
> }
> lbl_br8:
> g10 = 0;
> lbl_bf9:
> c11 = 0;
> goto lbl_b6;
> lbl_sw13:
> if (c11) goto lbl_b1;
> lbl_sw_def14:
> if (c11) goto lbl_bf9;
> goto lbl_br8;
> }
>
> GCC hangs when compiling this testcase at -O3.
r16-6679-g3ebe697f32197e
More information about the Gcc-bugs
mailing list