https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95836
--- Comment #2 from Gabriel Ravier <gabravier at gmail dot com> --- Yeah I wasn't sure whether this was legitimate, I was just trying to give a small example here, I dont think doesn't changes anything to how the optimization is able to work unless GCC has targets where `a << b` with `b > BITS_IN_A` traps.