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]

Remove warnings in expr.c


On non-PUSH_ROUNDING machines, there is a warning of unused parameters.  It
seemed cleanest to only define emit_single_push_insn if PUSH_ROUNDING.

Tested with bootstrap on alphaev56 and building a cross-cokmpiler toa
PUSH_ROUNDING machine (i386).

Thu Aug  9 11:30:20 2001  Richard Kenner  <kenner@vlsi1.ultra.nyu.edu>

	* expr.c (emit_single_push_insn): Only exists ifdef PUSH_ROUNDING.
	(move_by_pieces_1): If would call it, abort if no PUSH_ROUNDING.

*** expr.c	2001/08/08 22:06:47	1.344
--- expr.c	2001/08/09 15:16:39
*************** static void do_compare_and_jump	PARAMS (
*** 173,177 ****
--- 173,179 ----
  					 rtx, rtx));
  static rtx do_store_flag	PARAMS ((tree, rtx, enum machine_mode, int));
+ #ifdef PUSH_ROUNDING
  static void emit_single_push_insn PARAMS ((enum machine_mode, rtx, tree));
+ #endif
  
  /* Record for each mode whether we can move a register directly to or
*************** convert_modes (mode, oldmode, x, unsigne
*** 1388,1398 ****
  #endif
  
! /* Generate several move instructions to copy LEN bytes
!    from block FROM to block TO.  (These are MEM rtx's with BLKmode).
!    The caller must pass FROM and TO
!     through protect_from_queue before calling.
  
!    When TO is NULL, the emit_single_push_insn is used to push the
!    FROM to stack.
  
     ALIGN is maximum alignment we can assume.  */
--- 1390,1399 ----
  #endif
  
! /* Generate several move instructions to copy LEN bytes from block FROM to
!    block TO.  (These are MEM rtx's with BLKmode).  The caller must pass FROM
!    and TO through protect_from_queue before calling.
  
!    If PUSH_ROUNDING is defined and TO is NULL, emit_single_push_insn is
!    used to push FROM to the stack.
  
     ALIGN is maximum alignment we can assume.  */
*************** move_by_pieces_1 (genfun, mode, data)
*** 1601,1605 ****
  	emit_insn ((*genfun) (to1, from1));
        else
! 	emit_single_push_insn (mode, from1, NULL);
  
        if (HAVE_POST_INCREMENT && data->explicit_inc_to > 0)
--- 1602,1612 ----
  	emit_insn ((*genfun) (to1, from1));
        else
! 	{
! #ifdef PUSH_ROUNDING
! 	  emit_single_push_insn (mode, from1, NULL);
! #else
! 	  abort ();
! #endif
! 	}
  
        if (HAVE_POST_INCREMENT && data->explicit_inc_to > 0)
*************** get_push_address (size)
*** 3145,3149 ****
--- 3152,3159 ----
  }
  
+ #ifdef PUSH_ROUNDING
+ 
  /* Emit single push insn.  */
+ 
  static void
  emit_single_push_insn (mode, x, type)
*************** emit_single_push_insn (mode, x, type)
*** 3152,3156 ****
       tree type;
  {
- #ifdef PUSH_ROUNDING
    rtx dest_addr;
    unsigned rounded_size = PUSH_ROUNDING (GET_MODE_SIZE (mode));
--- 3162,3165 ----
*************** emit_single_push_insn (mode, x, type)
*** 3197,3204 ****
      }
    emit_move_insn (dest, x);
- #else
-   abort();
- #endif
  }
  
  /* Generate code to push X onto the stack, assuming it has mode MODE and
--- 3206,3211 ----
      }
    emit_move_insn (dest, x);
  }
+ #endif
  
  /* Generate code to push X onto the stack, assuming it has mode MODE and


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