Index: gcc/target.h
===================================================================
--- gcc/target.h	(revision 161310)
+++ gcc/target.h	(working copy)
@@ -976,6 +976,10 @@ struct gcc_target
     bool (*return_in_memory) (const_tree type, const_tree fndecl);
     bool (*return_in_msb) (const_tree type);
 
+    /* ??? FIXME: we shouldn't use CUMULATIVE_ARGS in the target hook
+       interface, here, because this is a target dependent type.
+       We should use union cumulative_args_u instead.  */
+
     /* Return true if a parameter must be passed by reference.  TYPE may
        be null if this is a libcall.  CA may be null if this query is
        from __builtin_va_arg.  */
Index: gcc/function.c
===================================================================
--- gcc/function.c	(revision 161310)
+++ gcc/function.c	(working copy)
@@ -3375,7 +3375,7 @@ assign_parms (tree fndecl)
   /* For stdarg.h function, save info about
      regs and stack space used by the named args.  */
 
-  crtl->args.info = all.args_so_far;
+  INCOMING_ARGS_INFO (crtl->args) = all.args_so_far;
 
   /* Set the rtx used for the function return value.  Put this in its
      own variable so any optimizers that need this information don't have
Index: gcc/function.h
===================================================================
--- gcc/function.h	(revision 161310)
+++ gcc/function.h	(working copy)
@@ -27,6 +27,7 @@ along with GCC; see the file COPYING3.  
 #include "vecprim.h"
 #include "tm.h"		/* For CUMULATIVE_ARGS.  */
 #include "hard-reg-set.h"
+#include "target-gtypes.h"
 
 /* Stack of pending (incomplete) sequences saved by `start_sequence'.
    Each element describes one pending sequence.
@@ -210,12 +211,14 @@ struct GTY(()) incoming_args {
 
   /* Quantities of various kinds of registers
      used for the current function's args.  */
-  CUMULATIVE_ARGS info;
+  cumulative_args_u GTY ((desc ("cfun ? cfun->target_arch : -1"))) info;
 
   /* The arg pointer hard register, or the pseudo into which it was copied.  */
   rtx internal_arg_pointer;
 };
 
+#define INCOMING_ARGS_INFO(INCOMING_ARGS) ((INCOMING_ARGS).info._ca)
+
 /* Data for function partitioning.  */
 struct GTY(()) function_subsections {
   /* Assembly labels for the hot and cold text sections, to
@@ -607,6 +610,9 @@ struct GTY(()) function {
      adjusts one of its arguments and forwards to another
      function.  */
   unsigned int is_thunk : 1;
+
+  /* Target architecture to compile this function for.  */
+  unsigned int target_arch : 8;
 };
 
 /* If va_list_[gf]pr_size is set to this, it means we don't know how
Index: gcc/Makefile.in
===================================================================
--- gcc/Makefile.in	(revision 161310)
+++ gcc/Makefile.in	(working copy)
@@ -800,6 +800,9 @@ T =
 T_TARGET =
 T_TARGET : $(T_TARGET)
 
+# For building rtl pases for extra target architectures.
+TARGET_NUM=0
+
 # This should name the specs file that we're going to install.  Target
 # Makefiles may override it and name another file to be generated from
 # the built-in specs and installed as the default spec, as long as
@@ -1668,7 +1671,9 @@ cs-tconfig.h: Makefile
 
 cs-tm.h: Makefile
 	TARGET_CPU_DEFAULT="$(target_cpu_default)" \
-	HEADERS="$(tm_include_list)" DEFINES="$(tm_defines)" \
+	HEADERS="$(tm_include_list)" \
+	DEFINES="TARGET_NUM=$(TARGET_NUM) \
+	$(tm_defines)" \
 	$(SHELL) $(srcdir)/mkconfig.sh tm.h
 
 cs-tm_p.h: Makefile
@@ -3671,7 +3676,7 @@ s-constrs-h: $(MD_DEPS) build/genpreds$(
 
 GTFILES = $(CPP_ID_DATA_H) $(srcdir)/input.h $(srcdir)/coretypes.h \
   $(srcdir)/vecprim.h $(srcdir)/vecir.h \
-  $(host_xm_file_list) \
+  $(host_xm_file_list) target-gtypes.h \
   $(tm_file_list) $(HASHTAB_H) $(SPLAY_TREE_H) $(srcdir)/bitmap.h \
   $(srcdir)/alias.h $(srcdir)/coverage.c $(srcdir)/rtl.h \
   $(srcdir)/optabs.h $(srcdir)/tree.h $(srcdir)/libfuncs.h $(SYMTAB_H) \
@@ -3848,6 +3853,17 @@ build/genpreds.o : genpreds.c $(RTL_BASE
 build/genrecog.o : genrecog.c $(RTL_BASE_H) $(BCONFIG_H) $(SYSTEM_H)	\
   coretypes.h $(GTM_H) errors.h $(READ_MD_H) gensupport.h
 
+target-gtypes.h: s-target-gtypes; @true
+# using struct instead of union makes this gty-safe.
+s-target-gtypes: Makefile
+	(echo 'typedef union GTY (())'; \
+	 echo '  {'; \
+	 echo '    CUMULATIVE_ARGS GTY ((tag ("TARGET_NUM"))) _ca;'; \
+	 echo '  } cumulative_args_u;'; \
+	) >> tmp-target-gtypes.h
+	$(SHELL) $(srcdir)/../move-if-change tmp-target-gtypes.h target-gtypes.h
+	$(STAMP) s-target-gtypes
+
 # Compile the programs that generate insn-* from the machine description.
 # They are compiled with $(COMPILER_FOR_BUILD), and associated libraries,
 # since they need to run on this machine
Index: gcc/config/alpha/alpha.c
===================================================================
--- gcc/config/alpha/alpha.c	(revision 161310)
+++ gcc/config/alpha/alpha.c	(working copy)
@@ -185,9 +185,9 @@ static struct alpha_rtx_cost_data const 
 
 /* Get the number of args of a function in one of two ways.  */
 #if TARGET_ABI_OPEN_VMS || TARGET_ABI_UNICOSMK
-#define NUM_ARGS crtl->args.info.num_args
+#define NUM_ARGS INCOMING_ARGS_INFO (crtl->args).num_args
 #else
-#define NUM_ARGS crtl->args.info
+#define NUM_ARGS INCOMING_ARGS_INFO (crtl->args)
 #endif
 
 #define REG_PV 27
Index: gcc/config/frv/frv.c
===================================================================
--- gcc/config/frv/frv.c	(revision 161310)
+++ gcc/config/frv/frv.c	(working copy)
@@ -2251,7 +2251,8 @@ static void
 frv_expand_builtin_va_start (tree valist, rtx nextarg)
 {
   tree t;
-  int num = crtl->args.info - FIRST_ARG_REGNUM - FRV_NUM_ARG_REGS;
+  int num
+    = INCOMING_ARGS_INFO (crtl->args) - FIRST_ARG_REGNUM - FRV_NUM_ARG_REGS;
 
   nextarg = gen_rtx_PLUS (Pmode, virtual_incoming_args_rtx,
 			  GEN_INT (UNITS_PER_WORD * num));
@@ -2259,7 +2260,7 @@ frv_expand_builtin_va_start (tree valist
   if (TARGET_DEBUG_ARG)
     {
       fprintf (stderr, "va_start: args_info = %d, num = %d\n",
-	       crtl->args.info, num);
+	       INCOMING_ARGS_INFO (crtl->args), num);
 
       debug_rtx (nextarg);
     }
Index: gcc/config/s390/s390.c
===================================================================
--- gcc/config/s390/s390.c	(revision 161310)
+++ gcc/config/s390/s390.c	(working copy)
@@ -7113,9 +7113,9 @@ s390_register_info (int clobbered_regs[]
     {
       /* Varargs functions need to save gprs 2 to 6.  */
       if (cfun->va_list_gpr_size
-	  && crtl->args.info.gprs < GP_ARG_NUM_REG)
+	  && INCOMING_ARGS_INFO (crtl->args).gprs < GP_ARG_NUM_REG)
 	{
-	  int min_gpr = crtl->args.info.gprs;
+	  int min_gpr = INCOMING_ARGS_INFO (crtl->args).gprs;
 	  int max_gpr = min_gpr + cfun->va_list_gpr_size;
 	  if (max_gpr > GP_ARG_NUM_REG)
 	    max_gpr = GP_ARG_NUM_REG;
@@ -7137,9 +7137,9 @@ s390_register_info (int clobbered_regs[]
 
       /* Mark f0, f2 for 31 bit and f0-f4 for 64 bit to be saved.  */
       if (TARGET_HARD_FLOAT && cfun->va_list_fpr_size
-	  && crtl->args.info.fprs < FP_ARG_NUM_REG)
+	  && INCOMING_ARGS_INFO (crtl->args).fprs < FP_ARG_NUM_REG)
 	{
-	  int min_fpr = crtl->args.info.fprs;
+	  int min_fpr = INCOMING_ARGS_INFO (crtl->args).fprs;
 	  int max_fpr = min_fpr + cfun->va_list_fpr_size;
 	  if (max_fpr > FP_ARG_NUM_REG)
 	    max_fpr = FP_ARG_NUM_REG;
@@ -8604,7 +8604,7 @@ s390_build_builtin_va_list (void)
    The following global variables are used to initialize
    the va_list structure:
 
-     crtl->args.info:
+     INCOMING_ARGS_INFO (crtl->args):
        holds number of gprs and fprs used for named arguments.
      crtl->args.arg_offset_rtx:
        holds the offset of the first anonymous stack argument
@@ -8631,8 +8631,8 @@ s390_va_start (tree valist, rtx nextarg 
 
   /* Count number of gp and fp argument registers used.  */
 
-  n_gpr = crtl->args.info.gprs;
-  n_fpr = crtl->args.info.fprs;
+  n_gpr = INCOMING_ARGS_INFO (crtl->args).gprs;
+  n_fpr = INCOMING_ARGS_INFO (crtl->args).fprs;
 
   if (cfun->va_list_gpr_size)
     {
Index: gcc/config/spu/spu.c
===================================================================
--- gcc/config/spu/spu.c	(revision 161310)
+++ gcc/config/spu/spu.c	(working copy)
@@ -4100,7 +4100,7 @@ spu_build_builtin_va_list (void)
    The following global variables are used to initialize
    the va_list structure:
 
-     crtl->args.info;
+     INCOMING_ARGS_INFO (crtl->args);
        the CUMULATIVE_ARGS for this function
 
      crtl->args.arg_offset_rtx:
Index: gcc/config/sparc/sparc.c
===================================================================
--- gcc/config/sparc/sparc.c	(revision 161310)
+++ gcc/config/sparc/sparc.c	(working copy)
@@ -5890,7 +5890,7 @@ sparc_function_value_regno_p (const unsi
 static rtx
 sparc_builtin_saveregs (void)
 {
-  int first_reg = crtl->args.info.words;
+  int first_reg = INCOMING_ARGS_INFO (crtl->args).words;
   rtx address;
   int regno;
 
Index: gcc/config/i386/i386.c
===================================================================
--- gcc/config/i386/i386.c	(revision 161310)
+++ gcc/config/i386/i386.c	(working copy)
@@ -7058,9 +7058,9 @@ ix86_va_start (tree valist, rtx nextarg)
   sav = build3 (COMPONENT_REF, TREE_TYPE (f_sav), valist, f_sav, NULL_TREE);
 
   /* Count number of gp and fp argument registers used.  */
-  words = crtl->args.info.words;
-  n_gpr = crtl->args.info.regno;
-  n_fpr = crtl->args.info.sse_regno;
+  words = INCOMING_ARGS_INFO (crtl->args).words;
+  n_gpr = INCOMING_ARGS_INFO (crtl->args).regno;
+  n_fpr = INCOMING_ARGS_INFO (crtl->args).sse_regno;
 
   if (cfun->va_list_gpr_size)
     {
Index: gcc/config/sh/sh.c
===================================================================
--- gcc/config/sh/sh.c	(revision 161310)
+++ gcc/config/sh/sh.c	(working copy)
@@ -6519,7 +6519,7 @@ calc_live_regs (HARD_REG_SET *live_regs_
   /* Force PR to be live if the prologue has to call the SHmedia
      argument decoder or register saver.  */
   if (TARGET_SHCOMPACT
-      && ((crtl->args.info.call_cookie
+      && ((INCOMING_ARGS_INFO (crtl->args).call_cookie
 	   & ~ CALL_COOKIE_RET_TRAMP (1))
 	  || crtl->saves_all_registers))
     pr_live = 1;
@@ -6546,7 +6546,7 @@ calc_live_regs (HARD_REG_SET *live_regs_
 	  : (/* Only push those regs which are used and need to be saved.  */
 	     (TARGET_SHCOMPACT
 	      && flag_pic
-	      && crtl->args.info.call_cookie
+	      && INCOMING_ARGS_INFO (crtl->args).call_cookie
 	      && reg == PIC_OFFSET_TABLE_REGNUM)
 	     || (df_regs_ever_live_p (reg)
 		 && ((!call_really_used_regs[reg]
@@ -6802,14 +6802,15 @@ sh_expand_prologue (void)
   pretend_args = crtl->args.pretend_args_size;
   if (TARGET_VARARGS_PRETEND_ARGS (current_function_decl)
       && (NPARM_REGS(SImode)
-	  > crtl->args.info.arg_count[(int) SH_ARG_INT]))
+	  > INCOMING_ARGS_INFO (crtl->args).arg_count[(int) SH_ARG_INT]))
     pretend_args = 0;
   /* Dwarf2 module doesn't expect frame related insns here.  */
   output_stack_adjust (-pretend_args
-		       - crtl->args.info.stack_regs * 8,
+		       - INCOMING_ARGS_INFO (crtl->args).stack_regs * 8,
 		       stack_pointer_rtx, 0, NULL, false);
 
-  if (TARGET_SHCOMPACT && flag_pic && crtl->args.info.call_cookie)
+  if (TARGET_SHCOMPACT && flag_pic
+      && INCOMING_ARGS_INFO (crtl->args).call_cookie)
     /* We're going to use the PIC register to load the address of the
        incoming-argument decoder and/or of the return trampoline from
        the GOT, so make sure the PIC register is preserved and
@@ -6817,7 +6818,8 @@ sh_expand_prologue (void)
     df_set_regs_ever_live (PIC_OFFSET_TABLE_REGNUM, true);
 
   if (TARGET_SHCOMPACT
-      && (crtl->args.info.call_cookie & ~ CALL_COOKIE_RET_TRAMP(1)))
+      && (INCOMING_ARGS_INFO (crtl->args).call_cookie
+	  & ~ CALL_COOKIE_RET_TRAMP(1)))
     {
       int reg;
 
@@ -6825,20 +6827,21 @@ sh_expand_prologue (void)
 	 be pushed onto the stack live, so that register renaming
 	 doesn't overwrite them.  */
       for (reg = 0; reg < NPARM_REGS (SImode); reg++)
-	if (CALL_COOKIE_STACKSEQ_GET (crtl->args.info.call_cookie)
+	if ((CALL_COOKIE_STACKSEQ_GET
+	     (INCOMING_ARGS_INFO (crtl->args).call_cookie))
 	    >= NPARM_REGS (SImode) - reg)
 	  for (; reg < NPARM_REGS (SImode); reg++)
 	    emit_insn (gen_shcompact_preserve_incoming_args
 		       (gen_rtx_REG (SImode, FIRST_PARM_REG + reg)));
 	else if (CALL_COOKIE_INT_REG_GET
-		 (crtl->args.info.call_cookie, reg) == 1)
+		 (INCOMING_ARGS_INFO (crtl->args).call_cookie, reg) == 1)
 	  emit_insn (gen_shcompact_preserve_incoming_args
 		     (gen_rtx_REG (SImode, FIRST_PARM_REG + reg)));
 
       emit_move_insn (gen_rtx_REG (Pmode, MACL_REG),
 		      stack_pointer_rtx);
       emit_move_insn (gen_rtx_REG (SImode, R0_REG),
-		      GEN_INT (crtl->args.info.call_cookie));
+		      GEN_INT (INCOMING_ARGS_INFO (crtl->args).call_cookie));
       emit_move_insn (gen_rtx_REG (SImode, MACH_REG),
 		      gen_rtx_REG (SImode, R0_REG));
     }
@@ -6863,7 +6866,8 @@ sh_expand_prologue (void)
 	      rtx insn;
 
 	      if (i >= (NPARM_REGS(SImode)
-			- crtl->args.info.arg_count[(int) SH_ARG_INT]
+			- (INCOMING_ARGS_INFO
+			   (crtl->args).arg_count[(int) SH_ARG_INT])
 			))
 		break;
 	      insn = push (rn);
@@ -7119,7 +7123,8 @@ sh_expand_prologue (void)
     frame_insn (GEN_MOV (hard_frame_pointer_rtx, stack_pointer_rtx));
 
   if (TARGET_SHCOMPACT
-      && (crtl->args.info.call_cookie & ~ CALL_COOKIE_RET_TRAMP(1)))
+      && (INCOMING_ARGS_INFO (crtl->args).call_cookie
+	  & ~ CALL_COOKIE_RET_TRAMP(1)))
     {
       /* This must NOT go through the PLT, otherwise mach and macl
 	 may be clobbered.  */
@@ -7381,7 +7386,7 @@ sh_expand_epilogue (bool sibcall_p)
 
   output_stack_adjust (crtl->args.pretend_args_size
 		       + save_size + d_rounding
-		       + crtl->args.info.stack_regs * 8,
+		       + INCOMING_ARGS_INFO (crtl->args).stack_regs * 8,
 		       stack_pointer_rtx, e, NULL, false);
 
   if (crtl->calls_eh_return)
@@ -7504,11 +7509,13 @@ static rtx
 sh_builtin_saveregs (void)
 {
   /* First unnamed integer register.  */
-  int first_intreg = crtl->args.info.arg_count[(int) SH_ARG_INT];
+  int first_intreg
+    = INCOMING_ARGS_INFO (crtl->args).arg_count[(int) SH_ARG_INT];
   /* Number of integer registers we need to save.  */
   int n_intregs = MAX (0, NPARM_REGS (SImode) - first_intreg);
   /* First unnamed SFmode float reg */
-  int first_floatreg = crtl->args.info.arg_count[(int) SH_ARG_FLOAT];
+  int first_floatreg
+    = INCOMING_ARGS_INFO (crtl->args).arg_count[(int) SH_ARG_FLOAT];
   /* Number of SFmode float regs to save.  */
   int n_floatregs = MAX (0, NPARM_REGS (SFmode) - first_floatreg);
   rtx regbuf, fpregs;
@@ -7523,22 +7530,22 @@ sh_builtin_saveregs (void)
 
 	  while (pushregs < NPARM_REGS (SImode) - 1
 		 && (CALL_COOKIE_INT_REG_GET
-			(crtl->args.info.call_cookie,
+			(INCOMING_ARGS_INFO (crtl->args).call_cookie,
 			 NPARM_REGS (SImode) - pushregs)
 		     == 1))
 	    {
-	      crtl->args.info.call_cookie
+	      INCOMING_ARGS_INFO (crtl->args).call_cookie
 		&= ~ CALL_COOKIE_INT_REG (NPARM_REGS (SImode)
 					  - pushregs, 1);
 	      pushregs++;
 	    }
 
 	  if (pushregs == NPARM_REGS (SImode))
-	    crtl->args.info.call_cookie
+	    INCOMING_ARGS_INFO (crtl->args).call_cookie
 	      |= (CALL_COOKIE_INT_REG (0, 1)
 		  | CALL_COOKIE_STACKSEQ (pushregs - 1));
 	  else
-	    crtl->args.info.call_cookie
+	    INCOMING_ARGS_INFO (crtl->args).call_cookie
 	      |= CALL_COOKIE_STACKSEQ (pushregs);
 
 	  crtl->args.pretend_args_size += 8 * n_intregs;
@@ -7748,7 +7755,7 @@ sh_va_start (tree valist, rtx nextarg)
   TREE_SIDE_EFFECTS (t) = 1;
   expand_expr (t, const0_rtx, VOIDmode, EXPAND_NORMAL);
 
-  nfp = crtl->args.info.arg_count[SH_ARG_FLOAT];
+  nfp = INCOMING_ARGS_INFO (crtl->args).arg_count[SH_ARG_FLOAT];
   if (nfp < 8)
     nfp = 8 - nfp;
   else
@@ -7763,7 +7770,7 @@ sh_va_start (tree valist, rtx nextarg)
   TREE_SIDE_EFFECTS (t) = 1;
   expand_expr (t, const0_rtx, VOIDmode, EXPAND_NORMAL);
 
-  nint = crtl->args.info.arg_count[SH_ARG_INT];
+  nint = INCOMING_ARGS_INFO (crtl->args).arg_count[SH_ARG_INT];
   if (nint < 4)
     nint = 4 - nint;
   else
@@ -8550,11 +8557,11 @@ initial_elimination_offset (int from, in
 
   if (from == ARG_POINTER_REGNUM && to == HARD_FRAME_POINTER_REGNUM)
     return total_saved_regs_space + total_auto_space
-      + crtl->args.info.byref_regs * 8;
+      + INCOMING_ARGS_INFO (crtl->args).byref_regs * 8;
 
   if (from == ARG_POINTER_REGNUM && to == STACK_POINTER_REGNUM)
     return total_saved_regs_space + total_auto_space
-      + crtl->args.info.byref_regs * 8;
+      + INCOMING_ARGS_INFO (crtl->args).byref_regs * 8;
 
   /* Initial gap between fp and sp is 0.  */
   if (from == HARD_FRAME_POINTER_REGNUM && to == STACK_POINTER_REGNUM)
@@ -10126,7 +10133,7 @@ sh_allocate_initial_value (rtx hard_reg)
       if (current_function_is_leaf
 	  && ! sh_pr_n_sets ()
 	  && ! (TARGET_SHCOMPACT
-		&& ((crtl->args.info.call_cookie
+		&& ((INCOMING_ARGS_INFO (crtl->args).call_cookie
 		     & ~ CALL_COOKIE_RET_TRAMP (1))
 		    || crtl->saves_all_registers)))
 	x = hard_reg;
@@ -10736,7 +10743,7 @@ sh_function_ok_for_sibcall (tree decl, t
 {
   return (1
 	  && (! TARGET_SHCOMPACT
-	      || crtl->args.info.stack_regs == 0)
+	      || INCOMING_ARGS_INFO (crtl->args).stack_regs == 0)
 	  && ! sh_cfun_interrupt_handler_p ()
 	  && (! flag_pic
 	      || (decl && ! TREE_PUBLIC (decl))
@@ -11651,7 +11658,7 @@ sh_get_pr_initial_val (void)
      PR register on SHcompact, because it might be clobbered by the prologue.
      We check first if that is known to be the case.  */
   if (TARGET_SHCOMPACT
-      && ((crtl->args.info.call_cookie
+      && ((INCOMING_ARGS_INFO (crtl->args).call_cookie
 	   & ~ CALL_COOKIE_RET_TRAMP (1))
 	  || crtl->saves_all_registers))
     return gen_frame_mem (SImode, return_address_pointer_rtx);
Index: gcc/config/sh/sh.md
===================================================================
--- gcc/config/sh/sh.md	(revision 161310)
+++ gcc/config/sh/sh.md	(working copy)
@@ -9018,7 +9018,8 @@ (define_expand "return"
     }
 
   if (TARGET_SHCOMPACT
-      && (crtl->args.info.call_cookie & CALL_COOKIE_RET_TRAMP (1)))
+      && (INCOMING_ARGS_INFO (crtl->args).call_cookie
+	  & CALL_COOKIE_RET_TRAMP (1)))
     {
       emit_jump_insn (gen_shcompact_return_tramp ());
       DONE;
@@ -9028,7 +9029,7 @@ (define_expand "return"
 (define_insn "*return_i"
   [(return)]
   "TARGET_SH1 && ! (TARGET_SHCOMPACT
-		    && (crtl->args.info.call_cookie
+		    && (INCOMING_ARGS_INFO (crtl->args).call_cookie
 			& CALL_COOKIE_RET_TRAMP (1)))
    && reload_completed
    && lookup_attribute (\"trap_exit\",
@@ -9055,7 +9056,7 @@ (define_insn "*return_trapa"
 (define_expand "shcompact_return_tramp"
   [(return)]
   "TARGET_SHCOMPACT
-   && (crtl->args.info.call_cookie & CALL_COOKIE_RET_TRAMP (1))"
+   && (INCOMING_ARGS_INFO (crtl->args).call_cookie & CALL_COOKIE_RET_TRAMP (1))"
   "
 {
   rtx reg = gen_rtx_REG (Pmode, R0_REG);
@@ -9068,7 +9069,7 @@ (define_expand "shcompact_return_tramp"
 (define_insn "shcompact_return_tramp_i"
   [(parallel [(return) (use (reg:SI R0_REG))])]
   "TARGET_SHCOMPACT
-   && (crtl->args.info.call_cookie & CALL_COOKIE_RET_TRAMP (1))"
+   && (INCOMING_ARGS_INFO (crtl->args).call_cookie & CALL_COOKIE_RET_TRAMP (1))"
   "jmp	@r0%#"
   [(set_attr "type" "jump_ind")
    (set_attr "needs_delay_slot" "yes")])
Index: gcc/config/avr/avr.c
===================================================================
--- gcc/config/avr/avr.c	(revision 161310)
+++ gcc/config/avr/avr.c	(working copy)
@@ -2748,7 +2748,7 @@ bool
 avr_frame_pointer_required_p (void)
 {
   return (cfun->calls_alloca
-	  || crtl->args.info.nregs == 0
+	  || INCOMING_ARGS_INFO (crtl->args).nregs == 0
   	  || get_frame_size () > 0);
 }
 
Index: gcc/config/xtensa/xtensa.c
===================================================================
--- gcc/config/xtensa/xtensa.c	(revision 161310)
+++ gcc/config/xtensa/xtensa.c	(working copy)
@@ -2699,7 +2699,7 @@ static rtx
 xtensa_builtin_saveregs (void)
 {
   rtx gp_regs;
-  int arg_words = crtl->args.info.arg_words;
+  int arg_words = INCOMING_ARGS_INFO (crtl->args).arg_words;
   int gp_left = MAX_ARGS_IN_REGISTERS - arg_words;
 
   if (gp_left <= 0)
@@ -2736,7 +2736,7 @@ xtensa_va_start (tree valist, rtx nextar
   tree t, u;
   int arg_words;
 
-  arg_words = crtl->args.info.arg_words;
+  arg_words = INCOMING_ARGS_INFO (crtl->args).arg_words;
 
   f_stk = TYPE_FIELDS (va_list_type_node);
   f_reg = TREE_CHAIN (f_stk);
@@ -3131,7 +3131,7 @@ order_regs_for_local_alloc (void)
 
       /* Use the AR registers in increasing order (skipping a0 and a1)
 	 but save the incoming argument registers for a last resort.  */
-      num_arg_regs = crtl->args.info.arg_words;
+      num_arg_regs = INCOMING_ARGS_INFO (crtl->args).arg_words;
       if (num_arg_regs > MAX_ARGS_IN_REGISTERS)
 	num_arg_regs = MAX_ARGS_IN_REGISTERS;
       for (i = GP_ARG_FIRST; i < 16 - num_arg_regs; i++)
Index: gcc/config/stormy16/stormy16.c
===================================================================
--- gcc/config/stormy16/stormy16.c	(revision 161310)
+++ gcc/config/stormy16/stormy16.c	(working copy)
@@ -1355,7 +1355,7 @@ xstormy16_expand_builtin_va_start (tree 
 
   t = build2 (MODIFY_EXPR, TREE_TYPE (count), count,
 	      build_int_cst (NULL_TREE,
-			     crtl->args.info * UNITS_PER_WORD));
+			     INCOMING_ARGS_INFO (crtl->args) * UNITS_PER_WORD));
   TREE_SIDE_EFFECTS (t) = 1;
   expand_expr (t, const0_rtx, VOIDmode, EXPAND_NORMAL);
 }
Index: gcc/config/m68hc11/m68hc11.c
===================================================================
--- gcc/config/m68hc11/m68hc11.c	(revision 161310)
+++ gcc/config/m68hc11/m68hc11.c	(working copy)
@@ -1617,7 +1617,7 @@ expand_prologue (void)
      If the first argument is a 32-bit quantity, the D+X registers
      are used.  Use Y to compute the frame.  Otherwise, X is cheaper.
      For 68HC12, this scratch register is not used.  */
-  if (crtl->args.info.nregs == 2)
+  if (INCOMING_ARGS_INFO (crtl->args).nregs == 2)
     scratch = iy_reg;
   else
     scratch = ix_reg;
Index: gcc/config/iq2000/iq2000.c
===================================================================
--- gcc/config/iq2000/iq2000.c	(revision 161310)
+++ gcc/config/iq2000/iq2000.c	(working copy)
@@ -1376,7 +1376,7 @@ iq2000_va_start (tree valist, rtx nextar
   /* Find out how many non-float named formals.  */
   int gpr_save_area_size;
   /* Note UNITS_PER_WORD is 4 bytes.  */
-  int_arg_words = crtl->args.info.arg_words;
+  int_arg_words = INCOMING_ARGS_INFO (crtl->args).arg_words;
 
   if (int_arg_words < 8 )
     /* Adjust for the prologue's economy measure.  */
Index: gcc/config/ia64/ia64.c
===================================================================
--- gcc/config/ia64/ia64.c	(revision 161310)
+++ gcc/config/ia64/ia64.c	(working copy)
@@ -3152,7 +3152,8 @@ ia64_expand_prologue (void)
   /* We don't need an alloc instruction if we've used no outputs or locals.  */
   if (current_frame_info.n_local_regs == 0
       && current_frame_info.n_output_regs == 0
-      && current_frame_info.n_input_regs <= crtl->args.info.int_regs
+      && (current_frame_info.n_input_regs
+	  <= INCOMING_ARGS_INFO (crtl->args).int_regs)
       && !TEST_HARD_REG_BIT (current_frame_info.mask, AR_PFS_REGNUM))
     {
       /* If there is no alloc, but there are input registers used, then we
Index: gcc/config/rs6000/rs6000.c
===================================================================
--- gcc/config/rs6000/rs6000.c	(revision 161310)
+++ gcc/config/rs6000/rs6000.c	(working copy)
@@ -8718,10 +8718,10 @@ rs6000_va_start (tree valist, rtx nextar
 		f_sav, NULL_TREE);
 
   /* Count number of gp and fp argument registers used.  */
-  words = crtl->args.info.words;
-  n_gpr = MIN (crtl->args.info.sysv_gregno - GP_ARG_MIN_REG,
+  words = INCOMING_ARGS_INFO (crtl->args).words;
+  n_gpr = MIN (INCOMING_ARGS_INFO (crtl->args).sysv_gregno - GP_ARG_MIN_REG,
 	       GP_ARG_NUM_REG);
-  n_fpr = MIN (crtl->args.info.fregno - FP_ARG_MIN_REG,
+  n_fpr = MIN (INCOMING_ARGS_INFO (crtl->args).fregno - FP_ARG_MIN_REG,
 	       FP_ARG_NUM_REG);
 
   if (TARGET_DEBUG_ARG)
@@ -17399,7 +17399,8 @@ compute_vrsave_mask (void)
      them in again.  More importantly, the mask we compute here is
      used to generate CLOBBERs in the set_vrsave insn, and we do not
      wish the argument registers to die.  */
-  for (i = crtl->args.info.vregno - 1; i >= ALTIVEC_ARG_MIN_REG; --i)
+  for (i = INCOMING_ARGS_INFO (crtl->args).vregno - 1;
+       i >= ALTIVEC_ARG_MIN_REG; --i)
     mask &= ~ALTIVEC_REG_BIT (i);
 
   /* Similarly, remove the return value from the set.  */
Index: gcc/config/arc/arc.c
===================================================================
--- gcc/config/arc/arc.c	(revision 161310)
+++ gcc/config/arc/arc.c	(working copy)
@@ -2277,8 +2277,8 @@ static void
 arc_va_start (tree valist, rtx nextarg)
 {
   /* See arc_setup_incoming_varargs for reasons for this oddity.  */
-  if (crtl->args.info < 8
-      && (crtl->args.info & 1))
+  if (INCOMING_ARGS_INFO (crtl->args) < 8
+      && (INCOMING_ARGS_INFO (crtl->args) & 1))
     nextarg = plus_constant (nextarg, UNITS_PER_WORD);
 
   std_expand_builtin_va_start (valist, nextarg);
Index: gcc/config/arm/arm.c
===================================================================
--- gcc/config/arm/arm.c	(revision 161310)
+++ gcc/config/arm/arm.c	(working copy)
@@ -5059,7 +5059,7 @@ thumb_find_work_register (unsigned long 
   if (! cfun->machine->uses_anonymous_args
       && crtl->args.size >= 0
       && crtl->args.size <= (LAST_ARG_REGNUM * UNITS_PER_WORD)
-      && crtl->args.info.nregs < 4)
+      && INCOMING_ARGS_INFO (crtl->args).nregs < 4)
     return LAST_ARG_REGNUM;
 
   /* Otherwise look for a call-saved register that is going to be pushed.  */
Index: gcc/config/mips/mips.c
===================================================================
--- gcc/config/mips/mips.c	(revision 161310)
+++ gcc/config/mips/mips.c	(working copy)
@@ -5472,7 +5472,7 @@ mips_va_start (tree valist, rtx nextarg)
       int fpr_save_area_size;
       int fpr_offset;
 
-      cum = &crtl->args.info;
+      cum = &INCOMING_ARGS_INFO (crtl->args);
       gpr_save_area_size
 	= (MAX_ARGS_IN_REGISTERS - cum->num_gprs) * UNITS_PER_WORD;
       fpr_save_area_size
@@ -6015,7 +6015,8 @@ mips16_build_function_stub (void)
   fprintf (asm_out_file, "\t# Stub function for %s (",
 	   current_function_name ());
   separator = "";
-  for (f = (unsigned int) crtl->args.info.fp_code; f != 0; f >>= 2)
+  for (f = (unsigned int) INCOMING_ARGS_INFO (crtl->args).fp_code;
+       f != 0; f >>= 2)
     {
       fprintf (asm_out_file, "%s%s", separator,
 	       (f & 3) == 1 ? "float" : "double");
@@ -6051,7 +6052,7 @@ mips16_build_function_stub (void)
   output_asm_insn ("la\t%^,%0", &symbol);
 
   /* Move the arguments from floating-point registers to general registers.  */
-  mips_output_args_xfer (crtl->args.info.fp_code, 'f');
+  mips_output_args_xfer (INCOMING_ARGS_INFO (crtl->args).fp_code, 'f');
 
   /* Jump to the MIPS16 function.  */
   output_asm_insn ("jr\t%^", NULL);
@@ -9814,7 +9815,7 @@ mips_output_function_prologue (FILE *fil
      floating-point arguments.  */
   if (TARGET_MIPS16
       && TARGET_HARD_FLOAT_ABI
-      && crtl->args.info.fp_code != 0)
+      && INCOMING_ARGS_INFO (crtl->args).fp_code != 0)
     mips16_build_function_stub ();
 
   /* Get the function name the same way that toplev.c does before calling
Index: gcc/config/v850/v850.c
===================================================================
--- gcc/config/v850/v850.c	(revision 161310)
+++ gcc/config/v850/v850.c	(working copy)
@@ -1583,7 +1583,7 @@ expand_prologue (void)
     }
 
   /* Save arg registers to the stack if necessary.  */
-  else if (crtl->args.info.anonymous_args)
+  else if (INCOMING_ARGS_INFO (crtl->args).anonymous_args)
     {
       if (TARGET_PROLOG_FUNCTION && TARGET_V850E && !TARGET_DISABLE_CALLT)
 	emit_insn (gen_save_r6_r9_v850e ());
Index: gcc/config/mmix/mmix.c
===================================================================
--- gcc/config/mmix/mmix.c	(revision 161310)
+++ gcc/config/mmix/mmix.c	(working copy)
@@ -831,9 +831,9 @@ mmix_reorg (void)
      wasteful to optimize for unused parameter registers.  As of
      2002-04-30, df_regs_ever_live_p (n) seems to be set for only-reads too, but
      that might change.  */
-  if (!TARGET_ABI_GNU && regno < crtl->args.info.regs - 1)
+  if (!TARGET_ABI_GNU && regno < INCOMING_ARGS_INFO (crtl->args).regs - 1)
     {
-      regno = crtl->args.info.regs - 1;
+      regno = INCOMING_ARGS_INFO (crtl->args).regs - 1;
 
       /* We don't want to let this cause us to go over the limit and make
 	 incoming parameter registers be misnumbered and treating the last
