elliminate more float extensions

Richard Henderson rth@redhat.com
Mon Jan 13 21:56:00 GMT 2003


On Sat, Jan 11, 2003 at 02:52:29PM +0100, Jan Hubicka wrote:
>   a=b*2.0;
>
> where multiplication is converted into a=b+save_expr(b).
> What is the proper way to deal with save expr in this case?
> Is it needed at all?

Not in this case, no.

And, really, if a save_expr were to be involved, it should
have been

	a = save_expr(b) + save_expr(b);

I would think one would be able to look at TREE_SIDE_EFFECTS
and notice that the save_expr was not necessary.
 
> 	* convert.c (strip_float_extensions):  Look for narrowest type handling
> 	FP constants.

I want to see that this doesn't result in extra conversions
for a target that doesn't support extend-on-load.

> +   /*  For floatingg point constant look up the narrowest type that can hold
		     ^^
typo



r~



More information about the Gcc-patches mailing list