http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52134

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |TREE

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> 2012-02-06 
19:45:41 UTC ---
Short testcase:
unsigned f(unsigned t)
{
  return (t*4)&-4;
}
int f1(int t)
{
  return (t*4)&-4;
}

Both should be optimized to just t*4.  In fact we do it on the RTL level.
*4 is changed to <<a 2 on the RTL level and simplified with the & when doing
combine.

Reply via email to