https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118995
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |missed-optimization --- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Yes assume is not always taken into account. `if(expr) __unreachable();` will always be better unless expr is just a comparison and then the assume will be "inlined" into a similar thing. THIS is due to assume can't have side effects and we don't have a good way to handle it assume functions without side effects and inlining back into the function.