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]

Re: New function: simplify_subreg


--- 3776,3805 ----
  	  && (GET_MODE_SIZE (mode)
  	      <= GET_MODE_SIZE (GET_MODE (SUBREG_REG (x)))))
  	{
! 	  rtx temp;
! 	  temp = simplify_subreg (mode, SUBREG_REG (x), op0_mode,
! 				  SUBREG_BYTE (x));
! 	  if (temp)
! 	    return temp;
  	}
  
        /* If we are in a SET_DEST, these other cases can't apply.  */
        if (in_dest)
  	return x;
  
!       /* An SIMPLIFY_SUBREG is able to handle this case as well, but
!          we want to go throught gen_lowpart_for_combine.  */
        if (CONSTANT_P (SUBREG_REG (x))
! 	  && subreg_lowpart_parts_p (mode, op0_mode, SUBREG_BYTE (x)))
  	return gen_lowpart_for_combine (mode, SUBREG_REG (x));
  
!       {
! 	rtx temp;
! 	temp = simplify_subreg (mode, SUBREG_REG (x), op0_mode,
! 		       		SUBREG_BYTE (x));
! 	if (temp)
! 	  return temp;
!       }

I don't understand the above.  It seems to be calling simplify_subreg
in the same way twice.  If correct, there needs to be more comments
saying why.  Also, the comment above isn't gramattically correct and 
you shouldn't capitalize the function name in the comment.


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