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]

Re: simplify multiplication by reciprocals to division


> On Mon, Jul 16, 2001 at 10:40:27PM +0200, Jan Hubicka wrote:
> > 	* combine.c (combine_simplify_rtx): Attempt to simplify
> > 	a*(b/c) as (a*b)/c for floats in unsafe_math mode.
> 
> Presumably C is a constant and B isn't?  I'd think you'd
> only want to do this under those conditions, which you 
> aren't checking.
What I do is to call the simplify-rtx, that will suceed only
if the value is nice constant.

It will work only in case both a and b are constants, or
b is eighter 1 or -1.

Honza
> 
> 
> r~


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