This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: [PATCH] H8300 Shift Optimization - comments


On Tue, 6 Aug 2002, Dhananjay R. Deshpande wrote:

> Hi,
> 
> > -----Original Message-----
> > From: tm [mailto:tm@mail.kloo.net]
> > Sent: Thursday, August 01, 2002 1:49 AM
> > To: Dhananjay R. Deshpande
> > Cc: Anita Kulkarni; kazu@cs.umass.edu; 
> > shumpei.kawasaki@hsa.hitachi.com;
> > gcc-patches@gcc.gnu.org
> > Subject: [PATCH] H8300 Shift Optimization - comments
> > 
> > 
> > 
> > It would be a good idea to update RTX_COSTS also to reflect the shift
> > optimizations so the compiler can evaluate the cost of operations
> > properly.
> > 
> In h8300.h, RTX_COST for HImode shifts is being returned as 2 for all shift counts. Couldn't understand why it is 2 for all shift counts when it will be much higher for high shift counts. 

Yep. It's horribly broken, which is why I suggested the changes.

I suspect GCC is currently making bad choices regarding shift and
multiplies for the H8 because the RTX_COST is so broken...

> 
> Regards,
> Dhananjay 
> > 
> > Toshi

Toshi



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]