[Bug tree-optimization/109513] Missed Dead Code Elimination when using __builtin_unreachable

2023-04-17 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109513

--- Comment #3 from Andrew Pinski  ---
(In reply to Andrew Pinski from comment #2)
> This is interesting because the C++ front-end causes slightly different IR
> and with __builtin_unreachable produces decent code at -O3 still.

The difference is due to -ffinite-loops .

[Bug tree-optimization/109513] Missed Dead Code Elimination when using __builtin_unreachable

2023-04-17 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109513

--- Comment #2 from Andrew Pinski  ---
This is interesting because the C++ front-end causes slightly different IR and
with __builtin_unreachable produces decent code at -O3 still.

[Bug tree-optimization/109513] Missed Dead Code Elimination when using __builtin_unreachable

2023-04-17 Thread marxin at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109513

Martin Liška  changed:

   What|Removed |Added

 CC||hubicka at gcc dot gnu.org,
   ||marxin at gcc dot gnu.org
 Ever confirmed|0   |1
   Last reconfirmed||2023-04-17
 Status|UNCONFIRMED |NEW

--- Comment #1 from Martin Liška  ---
The __builtin_unreachable missed optimization started with
r8-4670-gb00ff621f6eea4.