optabs.c (expand_binop_directly): Fix signed/unsigned comparison.

2007-07-05  Sandra Loosemore  <sandra@codesourcery.com>

	gcc/
	* optabs.c (expand_binop_directly): Fix signed/unsigned comparison.

From-SVN: r126382
This commit is contained in:
Sandra Loosemore 2007-07-05 15:11:05 -04:00 committed by Sandra Loosemore
parent 6e29b5a488
commit 9ee3427440
2 changed files with 5 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2007-07-05 Sandra Loosemore <sandra@codesourcery.com>
* optabs.c (expand_binop_directly): Fix signed/unsigned comparison.
2007-07-05 Uros Bizjak <ubizjak@gmail.com>
* rtl.def (NOTE): Change print format string to print

View File

@ -1456,7 +1456,7 @@ expand_binop (enum machine_mode mode, optab binoptab, rtx op0, rtx op1,
{
optab otheroptab = (binoptab == rotl_optab ? rotr_optab : rotl_optab);
rtx newop1;
int bits = GET_MODE_BITSIZE (mode);
unsigned int bits = GET_MODE_BITSIZE (mode);
if (GET_CODE (op1) == CONST_INT)
newop1 = GEN_INT (bits - INTVAL (op1));