This is the mail archive of the gcc-patches@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: force_operand tweek


On Fri, May 03, 2002 at 01:10:56PM +0200, Jan Hubicka wrote:
> !   if (GET_RTX_CLASS (GET_CODE (value)) == '2'
> !       || GET_RTX_CLASS (GET_CODE (value)) == 'c')

Be more consistent in your use of 'code'.

> !       op1 = force_operand (XEXP (value, 0), subtarget);
> !       op2 = force_operand (op2, NULL_RTX);
[...]
> ! 	default:
> ! 	  return expand_simple_binop (GET_MODE (value), code, op1,
> ! 				      force_operand (op2, NULL_RTX),
> ! 				      target, 1, OPTAB_LIB_WIDEN);

You've already forced op2 as an operand.

> ! 	case ASHIFTRT:
> ! 	  return expand_simple_binop (GET_MODE (value), code, op1, op2,
> ! 				      target, 0, OPTAB_LIB_WIDEN);

Which means that this special case should be folded into default.

> !   if (GET_RTX_CLASS (GET_CODE (value)) == '1')

else if; use 'code'.

Otherwise ok.


r~


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