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]

Fix to recog.c problem


This fixes the recog.c problem I recently reported.

Wed Mar 21 14:27:11 2001  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>

	* recog.c (push_operand): Fix error in last change that caused
	undefined symbol on many targets.

*** recog.c	2001/03/21 17:54:00	1.91
--- recog.c	2001/03/21 19:08:11
*************** push_operand (op, mode)
*** 1351,1354 ****
--- 1351,1360 ----
       enum machine_mode mode;
  {
+   unsigned int rounded_size = GET_MODE_SIZE (mode);
+ 
+ #ifdef PUSH_ROUNDING
+   rounded_size = PUSH_ROUNDING (rounded_size);
+ #endif
+ 
    if (GET_CODE (op) != MEM)
      return 0;
*************** push_operand (op, mode)
*** 1359,1363 ****
    op = XEXP (op, 0);
  
!   if (PUSH_ROUNDING (GET_MODE_SIZE (mode)) == GET_MODE_SIZE (mode))
      {
        if (GET_CODE (op) != STACK_PUSH_CODE)
--- 1365,1369 ----
    op = XEXP (op, 0);
  
!   if (rounded_size == GET_MODE_SIZE (mode))
      {
        if (GET_CODE (op) != STACK_PUSH_CODE)
*************** push_operand (op, mode)
*** 1366,1370 ****
    else
      {
-       int rounded_size = PUSH_ROUNDING (GET_MODE_SIZE (mode));
        if (GET_CODE (op) != PRE_MODIFY
  	  || GET_CODE (XEXP (op, 1)) != PLUS
--- 1372,1375 ----
*************** push_operand (op, mode)
*** 1372,1376 ****
  	  || GET_CODE (XEXP (XEXP (op, 1), 1)) != CONST_INT
  #ifdef STACK_GROWS_DOWNWARD
! 	  || INTVAL (XEXP (XEXP (op, 1), 1)) != -rounded_size
  #else
  	  || INTVAL (XEXP (XEXP (op, 1), 1)) != rounded_size
--- 1377,1381 ----
  	  || GET_CODE (XEXP (XEXP (op, 1), 1)) != CONST_INT
  #ifdef STACK_GROWS_DOWNWARD
! 	  || INTVAL (XEXP (XEXP (op, 1), 1)) != - (int) rounded_size
  #else
  	  || INTVAL (XEXP (XEXP (op, 1), 1)) != rounded_size


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