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: [PATCH] Microblaze: Fixes for RTL Checking


Hi!

On Thu, Mar 09, 2017 at 10:18:43AM -0800, Michael Eager wrote:
> --- a/gcc/config/microblaze/microblaze.c
> +++ b/gcc/config/microblaze/microblaze.c
> @@ -3323,10 +3323,10 @@ microblaze_expand_shift (rtx operands[])
>               || (GET_CODE (operands[1]) == SUBREG));
> 
>    /* Shift by zero -- copy regs if necessary.  */
> -  if ((GET_CODE (operands[2]) == CONST_INT) && (INTVAL (operands[2]) == 0))
> +  if (CONST_INT_P (operands[2]) && (operands[2] == const0_rtx)

You don't need that first test since you have the second (and the parens
are superfluous as well).


Segher


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