Copyright (C) 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
1999, 2000, 2001 Free Software Foundation, Inc.
-This file is part of GNU CC.
+This file is part of GCC.
-GNU CC is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
+GCC is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 2, or (at your option) any later
+version.
-GNU CC is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+for more details.
You should have received a copy of the GNU General Public License
-along with GNU CC; see the file COPYING. If not, write to
-the Free Software Foundation, 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA. */
+along with GCC; see the file COPYING. If not, write to the Free
+Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+02111-1307, USA. */
#include "config.h"
#include "system.h"
#endif
{
/* Now restore our arg pointer from the address at which it
- was saved in our stack frame.
- If there hasn't be space allocated for it yet, make
- some now. */
- if (arg_pointer_save_area == 0)
- arg_pointer_save_area
- = assign_stack_local (Pmode, GET_MODE_SIZE (Pmode), 0);
+ was saved in our stack frame. */
emit_move_insn (virtual_incoming_args_rtx,
- copy_to_reg (arg_pointer_save_area));
+ copy_to_reg (get_arg_pointer_save_area (cfun)));
}
}
#endif
static int
validate_arglist VPARAMS ((tree arglist, ...))
{
-#ifndef ANSI_PROTOTYPES
- tree arglist;
-#endif
enum tree_code code;
- va_list ap;
-
- VA_START (ap, arglist);
+ int res = 0;
-#ifndef ANSI_PROTOTYPES
- arglist = va_arg (ap, tree);
-#endif
+ VA_OPEN (ap, arglist);
+ VA_FIXEDARG (ap, tree, arglist);
do {
code = va_arg (ap, enum tree_code);
{
case 0:
/* This signifies an ellipses, any further arguments are all ok. */
- va_end (ap);
- return 1;
+ res = 1;
+ goto end;
case VOID_TYPE:
/* This signifies an endlink, if no arguments remain, return
true, otherwise return false. */
- va_end (ap);
- return arglist == 0;
+ res = arglist == 0;
+ goto end;
default:
/* If no parameters remain or the parameter's code does not
match the specified code, return false. Otherwise continue
checking any remaining arguments. */
if (arglist == 0 || code != TREE_CODE (TREE_TYPE (TREE_VALUE (arglist))))
- {
- va_end (ap);
- return 0;
- }
+ goto end;
break;
}
arglist = TREE_CHAIN (arglist);
} while (1);
+
+ /* We need gotos here since we can only have one VA_CLOSE in a
+ function. */
+ end: ;
+ VA_CLOSE (ap);
+
+ return res;
}
/* Default version of target-specific builtin setup that does nothing. */