Commit 11f9ed1a by Kaveh R. Ghazi Committed by Kaveh Ghazi

avr.c (avr_simplify_comparision_p, [...]): Don't use the 'U' suffix.

	* avr.c (avr_simplify_comparision_p, adjust_insn_length,
	mask_one_bit_p, output_reload_insisf): Don't use the 'U' suffix.
	* avr.h (reg_class): Likewise.
	* avr.md: Likewise.
	* mcore.c (try_constant_tricks, mcore_byte_offset,
	mcore_halfword_offset): Likewise.
	* sh.c (shl_sext_kind, gen_block_redirect, split_branches): Likewise.
	* v850.c (not_power_of_two_operand): Likewise.

From-SVN: r48073
parent aba649ba
2001-12-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> 2001-12-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* avr.c (avr_simplify_comparision_p, adjust_insn_length,
mask_one_bit_p, output_reload_insisf): Don't use the 'U' suffix.
* avr.h (reg_class): Likewise.
* avr.md: Likewise.
* mcore.c (try_constant_tricks, mcore_byte_offset,
mcore_halfword_offset): Likewise.
* sh.c (shl_sext_kind, gen_block_redirect, split_branches): Likewise.
* v850.c (not_power_of_two_operand): Likewise.
* clipper/clix.h (ASM_OUTPUT_ASCII): Avoid signed/unsigned * clipper/clix.h (ASM_OUTPUT_ASCII): Avoid signed/unsigned
warnings. warnings.
* convex.h (ASM_OUTPUT_ASCII): Likewise. * convex.h (ASM_OUTPUT_ASCII): Likewise.
......
...@@ -1358,7 +1358,7 @@ avr_simplify_comparision_p (mode, operator, x) ...@@ -1358,7 +1358,7 @@ avr_simplify_comparision_p (mode, operator, x)
{ {
unsigned int max = (mode == QImode ? 0xff : unsigned int max = (mode == QImode ? 0xff :
mode == HImode ? 0xffff : mode == HImode ? 0xffff :
mode == SImode ? 0xffffffffU : 0); mode == SImode ? 0xffffffff : 0);
if (max && operator && GET_CODE (x) == CONST_INT) if (max && operator && GET_CODE (x) == CONST_INT)
{ {
if (unsigned_condition (operator) != operator) if (unsigned_condition (operator) != operator)
...@@ -4242,8 +4242,8 @@ adjust_insn_length (insn, len) ...@@ -4242,8 +4242,8 @@ adjust_insn_length (insn, len)
if (GET_MODE (op[1]) == SImode) if (GET_MODE (op[1]) == SImode)
len = (((mask & 0xff) != 0xff) len = (((mask & 0xff) != 0xff)
+ ((mask & 0xff00) != 0xff00) + ((mask & 0xff00) != 0xff00)
+ ((mask & 0xff0000UL) != 0xff0000UL) + ((mask & 0xff0000L) != 0xff0000L)
+ ((mask & 0xff000000UL) != 0xff000000UL)); + ((mask & 0xff000000L) != 0xff000000L));
else if (GET_MODE (op[1]) == HImode) else if (GET_MODE (op[1]) == HImode)
len = (((mask & 0xff) != 0xff) len = (((mask & 0xff) != 0xff)
+ ((mask & 0xff00) != 0xff00)); + ((mask & 0xff00) != 0xff00));
...@@ -4257,8 +4257,8 @@ adjust_insn_length (insn, len) ...@@ -4257,8 +4257,8 @@ adjust_insn_length (insn, len)
if (GET_MODE (op[1]) == SImode) if (GET_MODE (op[1]) == SImode)
len = (((mask & 0xff) != 0) len = (((mask & 0xff) != 0)
+ ((mask & 0xff00) != 0) + ((mask & 0xff00) != 0)
+ ((mask & 0xff0000UL) != 0) + ((mask & 0xff0000L) != 0)
+ ((mask & 0xff000000UL) != 0)); + ((mask & 0xff000000L) != 0));
else if (GET_MODE (op[1]) == HImode) else if (GET_MODE (op[1]) == HImode)
len = (((mask & 0xff) != 0) len = (((mask & 0xff) != 0)
+ ((mask & 0xff00) != 0)); + ((mask & 0xff00) != 0));
...@@ -5162,9 +5162,9 @@ mask_one_bit_p (mask) ...@@ -5162,9 +5162,9 @@ mask_one_bit_p (mask)
unsigned HOST_WIDE_INT n=mask; unsigned HOST_WIDE_INT n=mask;
for (i = 0; i < 32; ++i) for (i = 0; i < 32; ++i)
{ {
if (n & 0x80000000UL) if (n & 0x80000000L)
{ {
if (n & 0x7fffffffUL) if (n & 0x7fffffffL)
return 0; return 0;
else else
return 32-i; return 32-i;
...@@ -5347,7 +5347,7 @@ output_reload_insisf (insn, operands, len) ...@@ -5347,7 +5347,7 @@ output_reload_insisf (insn, operands, len)
*len = 4 + ((INTVAL (src) & 0xff) != 0) *len = 4 + ((INTVAL (src) & 0xff) != 0)
+ ((INTVAL (src) & 0xff00) != 0) + ((INTVAL (src) & 0xff00) != 0)
+ ((INTVAL (src) & 0xff0000) != 0) + ((INTVAL (src) & 0xff0000) != 0)
+ ((INTVAL (src) & 0xff000000U) != 0); + ((INTVAL (src) & 0xff000000) != 0);
else else
*len = 8; *len = 8;
...@@ -5375,7 +5375,7 @@ output_reload_insisf (insn, operands, len) ...@@ -5375,7 +5375,7 @@ output_reload_insisf (insn, operands, len)
output_asm_insn (AS2 (ldi, %2, hlo8(%1)), operands); output_asm_insn (AS2 (ldi, %2, hlo8(%1)), operands);
output_asm_insn (AS2 (mov, %C0, %2), operands); output_asm_insn (AS2 (mov, %C0, %2), operands);
} }
if (cnst && ((INTVAL (src) & 0xff000000U) == 0)) if (cnst && ((INTVAL (src) & 0xff000000) == 0))
output_asm_insn (AS2 (mov, %D0, __zero_reg__), operands); output_asm_insn (AS2 (mov, %D0, __zero_reg__), operands);
else else
{ {
......
...@@ -613,8 +613,8 @@ enum reg_class { ...@@ -613,8 +613,8 @@ enum reg_class {
{(3 << REG_X)|(3 << REG_Y)|(3 << REG_Z)|(3 << REG_W)|(0xff << 16), \ {(3 << REG_X)|(3 << REG_Y)|(3 << REG_Z)|(3 << REG_W)|(0xff << 16), \
0x00000000}, /* LD_REGS, r16 - r31 */ \ 0x00000000}, /* LD_REGS, r16 - r31 */ \
{0x0000ffff,0x00000000}, /* NO_LD_REGS r0 - r15 */ \ {0x0000ffff,0x00000000}, /* NO_LD_REGS r0 - r15 */ \
{0xffffffffu,0x00000000}, /* GENERAL_REGS, r0 - r31 */ \ {0xffffffff,0x00000000}, /* GENERAL_REGS, r0 - r31 */ \
{0xffffffffu,0x00000003} /* ALL_REGS */ \ {0xffffffff,0x00000003} /* ALL_REGS */ \
} }
/* An initializer containing the contents of the register classes, as /* An initializer containing the contents of the register classes, as
integers which are bit masks. The Nth integer specifies the integers which are bit masks. The Nth integer specifies the
......
...@@ -996,9 +996,9 @@ ...@@ -996,9 +996,9 @@
output_asm_insn (AS2 (andi,%A0,lo8(%2)), operands); output_asm_insn (AS2 (andi,%A0,lo8(%2)), operands);
if ((mask & 0xff00) != 0xff00) if ((mask & 0xff00) != 0xff00)
output_asm_insn (AS2 (andi,%B0,hi8(%2)), operands); output_asm_insn (AS2 (andi,%B0,hi8(%2)), operands);
if ((mask & 0xff0000UL) != 0xff0000UL) if ((mask & 0xff0000L) != 0xff0000L)
output_asm_insn (AS2 (andi,%C0,hlo8(%2)), operands); output_asm_insn (AS2 (andi,%C0,hlo8(%2)), operands);
if ((mask & 0xff000000UL) != 0xff000000UL) if ((mask & 0xff000000L) != 0xff000000L)
output_asm_insn (AS2 (andi,%D0,hhi8(%2)), operands); output_asm_insn (AS2 (andi,%D0,hhi8(%2)), operands);
return \"\"; return \"\";
} }
...@@ -1080,9 +1080,9 @@ ...@@ -1080,9 +1080,9 @@
output_asm_insn (AS2 (ori,%A0,lo8(%2)), operands); output_asm_insn (AS2 (ori,%A0,lo8(%2)), operands);
if (mask & 0xff00) if (mask & 0xff00)
output_asm_insn (AS2 (ori,%B0,hi8(%2)), operands); output_asm_insn (AS2 (ori,%B0,hi8(%2)), operands);
if (mask & 0xff0000UL) if (mask & 0xff0000L)
output_asm_insn (AS2 (ori,%C0,hlo8(%2)), operands); output_asm_insn (AS2 (ori,%C0,hlo8(%2)), operands);
if (mask & 0xff000000UL) if (mask & 0xff000000L)
output_asm_insn (AS2 (ori,%D0,hhi8(%2)), operands); output_asm_insn (AS2 (ori,%D0,hhi8(%2)), operands);
return \"\"; return \"\";
} }
......
...@@ -719,7 +719,7 @@ try_constant_tricks (value, x, y) ...@@ -719,7 +719,7 @@ try_constant_tricks (value, x, y)
} }
} }
bit = 0x80000000UL; bit = 0x80000000L;
for (i = 0; i <= 31; i++) for (i = 0; i <= 31; i++)
{ {
...@@ -886,13 +886,13 @@ int ...@@ -886,13 +886,13 @@ int
mcore_byte_offset (mask) mcore_byte_offset (mask)
unsigned int mask; unsigned int mask;
{ {
if (mask == 0x00ffffffUL) if (mask == 0x00ffffffL)
return 0; return 0;
else if (mask == 0xff00ffffUL) else if (mask == 0xff00ffffL)
return 1; return 1;
else if (mask == 0xffff00ffUL) else if (mask == 0xffff00ffL)
return 2; return 2;
else if (mask == 0xffffff00UL) else if (mask == 0xffffff00L)
return 3; return 3;
return -1; return -1;
...@@ -906,7 +906,7 @@ mcore_halfword_offset (mask) ...@@ -906,7 +906,7 @@ mcore_halfword_offset (mask)
{ {
if (mask == 0x0000ffffL) if (mask == 0x0000ffffL)
return 0; return 0;
else if (mask == 0xffff0000UL) else if (mask == 0xffff0000L)
return 1; return 1;
return -1; return -1;
......
...@@ -1716,7 +1716,7 @@ shl_sext_kind (left_rtx, size_rtx, costp) ...@@ -1716,7 +1716,7 @@ shl_sext_kind (left_rtx, size_rtx, costp)
cost = ext_shift_insns[ext - insize] + 1 + shift_insns[size - ext]; cost = ext_shift_insns[ext - insize] + 1 + shift_insns[size - ext];
if (cost < best_cost) if (cost < best_cost)
{ {
kind = ext / 8U; kind = ext / (unsigned) 8;
best_cost = cost; best_cost = cost;
} }
} }
...@@ -1733,7 +1733,7 @@ shl_sext_kind (left_rtx, size_rtx, costp) ...@@ -1733,7 +1733,7 @@ shl_sext_kind (left_rtx, size_rtx, costp)
continue; continue;
if (cost < best_cost) if (cost < best_cost)
{ {
kind = ext / 8U + 2; kind = ext / (unsigned) 8 + 2;
best_cost = cost; best_cost = cost;
} }
} }
...@@ -2688,7 +2688,8 @@ gen_block_redirect (jump, addr, need_block) ...@@ -2688,7 +2688,8 @@ gen_block_redirect (jump, addr, need_block)
dest = XEXP (SET_SRC (PATTERN (jump)), 0); dest = XEXP (SET_SRC (PATTERN (jump)), 0);
/* If the branch is out of range, try to find a scratch register for it. */ /* If the branch is out of range, try to find a scratch register for it. */
if (optimize if (optimize
&& (INSN_ADDRESSES (INSN_UID (dest)) - addr + 4092U > 4092 + 4098)) && (INSN_ADDRESSES (INSN_UID (dest)) - addr + (unsigned) 4092
> 4092 + 4098))
{ {
rtx scan; rtx scan;
/* Don't look for the stack pointer as a scratch register, /* Don't look for the stack pointer as a scratch register,
...@@ -2764,7 +2765,7 @@ gen_block_redirect (jump, addr, need_block) ...@@ -2764,7 +2765,7 @@ gen_block_redirect (jump, addr, need_block)
{ {
dest = JUMP_LABEL (next); dest = JUMP_LABEL (next);
if (dest if (dest
&& (INSN_ADDRESSES (INSN_UID (dest)) - addr + 4092U && (INSN_ADDRESSES (INSN_UID (dest)) - addr + (unsigned) 4092
> 4092 + 4098)) > 4092 + 4098))
gen_block_redirect (next, INSN_ADDRESSES (INSN_UID (next)), -1); gen_block_redirect (next, INSN_ADDRESSES (INSN_UID (next)), -1);
} }
...@@ -3630,7 +3631,7 @@ split_branches (first) ...@@ -3630,7 +3631,7 @@ split_branches (first)
&& recog_memoized (beyond) == CODE_FOR_jump && recog_memoized (beyond) == CODE_FOR_jump
&& ((INSN_ADDRESSES && ((INSN_ADDRESSES
(INSN_UID (XEXP (SET_SRC (PATTERN (beyond)), 0))) (INSN_UID (XEXP (SET_SRC (PATTERN (beyond)), 0)))
- INSN_ADDRESSES (INSN_UID (insn)) + 252U) - INSN_ADDRESSES (INSN_UID (insn)) + (unsigned) 252)
> 252 + 258 + 2)) > 252 + 258 + 2))
gen_block_redirect (beyond, gen_block_redirect (beyond,
INSN_ADDRESSES (INSN_UID (beyond)), 1); INSN_ADDRESSES (INSN_UID (beyond)), 1);
...@@ -3644,7 +3645,7 @@ split_branches (first) ...@@ -3644,7 +3645,7 @@ split_branches (first)
&& recog_memoized (next) == CODE_FOR_jump && recog_memoized (next) == CODE_FOR_jump
&& ((INSN_ADDRESSES && ((INSN_ADDRESSES
(INSN_UID (XEXP (SET_SRC (PATTERN (next)), 0))) (INSN_UID (XEXP (SET_SRC (PATTERN (next)), 0)))
- INSN_ADDRESSES (INSN_UID (insn)) + 252U) - INSN_ADDRESSES (INSN_UID (insn)) + (unsigned) 252)
> 252 + 258 + 2)) > 252 + 258 + 2))
gen_block_redirect (next, INSN_ADDRESSES (INSN_UID (next)), 1); gen_block_redirect (next, INSN_ADDRESSES (INSN_UID (next)), 1);
} }
......
...@@ -1047,7 +1047,7 @@ not_power_of_two_operand (op, mode) ...@@ -1047,7 +1047,7 @@ not_power_of_two_operand (op, mode)
else if (mode == HImode) else if (mode == HImode)
mask = 0xffff; mask = 0xffff;
else if (mode == SImode) else if (mode == SImode)
mask = 0xffffffffU; mask = 0xffffffff;
else else
return 0; return 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment