This is the mail archive of the gcc@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: [lno] [RFC] if-conversion and auto vectorizer


On Sun, Mar 14, 2004 at 06:28:51PM -0800, Alex Rosenberg wrote:
> Maybe I keep stating the obvious, but it seems to me that it would be 
> better to remove the MIN/MAX nodes, in favor of the SELECT node that 
> Dorit has suggested since MIN/MAX are just specific CMPs mated with a 
> SELECT.

No.

(1) MIN/MAX have better floating-point properties than conditional move.
    Consider 

	a = 0; b = NaN;

	c = a < b ? b : a;		// 0
    vs
	c = a > b ? a : b;		// NaN
    vs
	c = max(a, b);			// Undefined

    Undefined is good because then the target md pattern doesn't have to
    be careful to preserve one or the other of the values in the face of
    unordered comparisons.

(2) I reiterate that we will NOT be adding a new SELECT node.
    The sooner Dorit changes to use COND_EXPR as I asked, the better.


r~


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