https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115551
Xi Ruoyao <xry111 at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |xry111 at gcc dot gnu.org --- Comment #1 from Xi Ruoyao <xry111 at gcc dot gnu.org> --- "c1 << (-5 + 5)" is fine but "(c1 << -5) << 5" invokes undefined behavior. Thus we need some range info to do this optimization.