gcc/gcc ChangeLog simplify-rtx.c testsuite/Cha ...

sayle@gcc.gnu.org sayle@gcc.gnu.org
Fri Apr 9 21:39:00 GMT 2004


CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	sayle@gcc.gnu.org	2004-04-09 21:39:14

Modified files:
	gcc            : ChangeLog simplify-rtx.c 
	gcc/testsuite  : ChangeLog 
Added files:
	gcc/testsuite/gcc.c-torture/execute: 20040409-1.c 20040409-2.c 
	                                     20040409-3.c 

Log message:
	* simplify-rtx.c (mode_signbit_p): New function to check whether
	an RTX is an immediate constant that represents the most significant
	bit of a given machine mode.
	(simplify_unary_operation) <NOT>: Optimize ~(X+C) as X ^ ~C, where
	C is the sign bit.
	(simplify_binary_operation) <PLUS>: Optimize (X^C1) + C2 as X^(C1^C2)
	when C2 is the sign bit.
	(simplify_binary_operation) <XOR>: Canonicalize X^C as X+C when C
	is the sign bit.  Optimize (X+C1) ^ C2 as X^(C1^C2) when C1 is the
	sign bit.
	
	* gcc.c-torture/execute/20040409-1.c: New test case.
	* gcc.c-torture/execute/20040409-2.c: New test case.
	* gcc.c-torture/execute/20040409-3.c: New test case.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.3378&r2=2.3379
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/simplify-rtx.c.diff?cvsroot=gcc&r1=1.185&r2=1.186
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.3666&r2=1.3667
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/execute/20040409-1.c.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/execute/20040409-2.c.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/execute/20040409-3.c.diff?cvsroot=gcc&r1=NONE&r2=1.1



More information about the Gcc-cvs mailing list