/* Output bytecodes for GNU C-compiler.
- Copyright (C) 1993 Free Software Foundation, Inc.
+ Copyright (C) 1993, 1994 Free Software Foundation, Inc.
This file is part of GNU CC.
#include "config.h"
+#ifdef __STDC__
+#include "gstdarg.h"
+#else
#include "gvarargs.h"
+#endif
#include "machmode.h"
#include "rtl.h"
#include "real.h"
of literal values in the call. First argument is the instruction, the
remaining arguments are literals of size HOST_WIDE_INT or smaller. */
void
-bc_emit_instruction (va_alist)
- va_dcl
+bc_emit_instruction VPROTO((enum bytecode_opcode opcode, ...))
{
- va_list arguments;
+#ifndef __STDC__
enum bytecode_opcode opcode;
+#endif
+ va_list arguments;
int nliteral, instruction;
+ VA_START (arguments, opcode);
- va_start (arguments);
+#ifndef __STDC__
+ opcode = va_arg (arguments, enum bytecode_opcode);
+#endif
/* Emit instruction bytecode */
- opcode = va_arg (arguments, enum bytecode_opcode);
bc_emit_bytecode (opcode);
instruction = (int) opcode;
#include "tree.h"
#include "flags.h"
#include "expr.h"
+#ifdef __STDC__
+#include "gstdarg.h"
+#else
#include "gvarargs.h"
+#endif
#include "insn-flags.h"
/* Decide whether a function's arguments should be processed
move memory references across the non-const call. */
void
-emit_library_call (va_alist)
- va_dcl
+emit_library_call VPROTO((rtx orgfun, int no_queue, enum machine_mode outmode,
+ int nargs, ...))
{
+#ifndef __STDC__
+ rtx orgfun;
+ int no_queue;
+ enum machine_mode outmode;
+ int nargs;
+#endif
va_list p;
/* Total size in bytes of all the stack-parms scanned so far. */
struct args_size args_size;
/* Size of arguments before any adjustments (such as rounding). */
struct args_size original_args_size;
register int argnum;
- enum machine_mode outmode;
- int nargs;
rtx fun;
- rtx orgfun;
int inc;
int count;
rtx argblock = 0;
struct args_size offset; struct args_size size; };
struct arg *argvec;
int old_inhibit_defer_pop = inhibit_defer_pop;
- int no_queue = 0;
rtx use_insns;
/* library calls are never indirect calls. */
int current_call_is_indirect = 0;
- va_start (p);
- orgfun = fun = va_arg (p, rtx);
+ VA_START (p, nargs);
+
+#ifndef __STDC__
+ orgfun = va_arg (p, rtx);
no_queue = va_arg (p, int);
outmode = va_arg (p, enum machine_mode);
nargs = va_arg (p, int);
+#endif
+
+ fun = orgfun;
/* Copy all the libcall-arguments out of the varargs data
and into a vector ARGVEC.
If VALUE is nonzero, VALUE is returned. */
rtx
-emit_library_call_value (va_alist)
- va_dcl
+emit_library_call_value VPROTO((rtx orgfun, rtx value, int no_queue,
+ enum machine_mode outmode, int nargs, ...))
{
+#ifndef __STDC__
+ rtx orgfun;
+ rtx value;
+ int no_queue;
+ enum machine_mode outmode;
+ int nargs;
+#endif
va_list p;
/* Total size in bytes of all the stack-parms scanned so far. */
struct args_size args_size;
/* Size of arguments before any adjustments (such as rounding). */
struct args_size original_args_size;
register int argnum;
- enum machine_mode outmode;
- int nargs;
rtx fun;
- rtx orgfun;
int inc;
int count;
rtx argblock = 0;
struct args_size offset; struct args_size size; };
struct arg *argvec;
int old_inhibit_defer_pop = inhibit_defer_pop;
- int no_queue = 0;
rtx use_insns;
- rtx value;
rtx mem_value = 0;
int pcc_struct_value = 0;
int struct_value_size = 0;
/* library calls are never indirect calls. */
int current_call_is_indirect = 0;
- va_start (p);
- orgfun = fun = va_arg (p, rtx);
+ VA_START (p, nargs);
+
+#ifndef __STDC__
+ orgfun = va_arg (p, rtx);
value = va_arg (p, rtx);
no_queue = va_arg (p, int);
outmode = va_arg (p, enum machine_mode);
nargs = va_arg (p, int);
+#endif
+
+ fun = orgfun;
/* If this kind of value comes back in memory,
decide where in memory it should come back. */
combine anyway. */
#include "config.h"
+#ifdef __STDC__
+#include "gstdarg.h"
+#else
#include "gvarargs.h"
+#endif
/* Must precede rtl.h for FFS. */
#include <stdio.h>
rtx, int));
static int recog_for_combine PROTO((rtx *, rtx, rtx *));
static rtx gen_lowpart_for_combine PROTO((enum machine_mode, rtx));
-static rtx gen_rtx_combine (); /* This is varargs. */
+static rtx gen_rtx_combine PROTO((enum rtx_code code, enum machine_mode mode,
+ ...));
static rtx gen_binary PROTO((enum rtx_code, enum machine_mode,
rtx, rtx));
static rtx gen_unary PROTO((enum rtx_code, enum machine_mode, rtx));
/*VARARGS2*/
static rtx
-gen_rtx_combine (va_alist)
- va_dcl
+gen_rtx_combine VPROTO((enum rtx_code code, enum machine_mode mode, ...))
{
- va_list p;
+#ifndef __STDC__
enum rtx_code code;
enum machine_mode mode;
+#endif
+ va_list p;
int n_args;
rtx args[3];
int i, j;
char *fmt;
rtx rt;
- va_start (p);
+ VA_START (p, mode);
+
+#ifndef __STDC__
code = va_arg (p, enum rtx_code);
mode = va_arg (p, enum machine_mode);
+#endif
+
n_args = GET_RTX_LENGTH (code);
fmt = GET_RTX_FORMAT (code);
is the kind of rtx's they make and what arguments they use. */
#include "config.h"
+#ifdef __STDC__
+#include "gstdarg.h"
+#else
#include "gvarargs.h"
+#endif
#include "rtl.h"
#include "tree.h"
#include "flags.h"
/*VARARGS2*/
rtx
-gen_rtx (va_alist)
- va_dcl
+gen_rtx VPROTO((enum rtx_code code, enum machine_mode mode, ...))
{
- va_list p;
+#ifndef __STDC__
enum rtx_code code;
enum machine_mode mode;
+#endif
+ va_list p;
register int i; /* Array indices... */
register char *fmt; /* Current rtx's format... */
register rtx rt_val; /* RTX to return to caller... */
- va_start (p);
+ VA_START (p, mode);
+
+#ifndef __STDC__
code = va_arg (p, enum rtx_code);
mode = va_arg (p, enum machine_mode);
+#endif
if (code == CONST_INT)
{
/*VARARGS1*/
rtvec
-gen_rtvec (va_alist)
- va_dcl
+gen_rtvec VPROTO((int n, ...))
{
- int n, i;
+#ifndef __STDC__
+ int n;
+#endif
+ int i;
va_list p;
rtx *vector;
- va_start (p);
+ VA_START (p, n);
+
+#ifndef __STDC__
n = va_arg (p, int);
+#endif
if (n == 0)
return NULL_RTVEC; /* Don't allocate an empty rtvec... */
vector = (rtx *) alloca (n * sizeof (rtx));
+
for (i = 0; i < n; i++)
vector[i] = va_arg (p, rtx);
va_end (p);
/* Convert RTL to assembler code and output it, for GNU compiler.
- Copyright (C) 1987, 1988, 1989, 1992, 1993 Free Software Foundation, Inc.
+ Copyright (C) 1987, 88, 89, 92, 93, 1994 Free Software Foundation, Inc.
This file is part of GNU CC.
FUNCTION_EPILOGUE. Those instructions never exist as rtl. */
#include "config.h"
+#ifdef __STDC__
+#include "gstdarg.h"
+#else
#include "gvarargs.h"
+#endif
#include "tree.h"
#include "rtl.h"
#include "regs.h"
We handle alternate assembler dialects here, just like output_asm_insn. */
void
-asm_fprintf (va_alist)
- va_dcl
+asm_fprintf VPROTO((FILE *file, char *p, ...))
{
- va_list argptr;
+#ifndef __STDC__
FILE *file;
+ char *p;
+#endif
+ va_list argptr;
char buf[10];
- char *p, *q, c;
+ char *q, c;
int i;
- va_start (argptr);
+ VA_START (argptr, p);
+
+#ifndef __STDC__
+ file = va_arg (argptr, FILE*);
+ p = va_arg (argptr, char*);
+#endif
- file = va_arg (argptr, FILE *);
- p = va_arg (argptr, char *);
buf[0] = '%';
while (c = *p++)
#include "config.h"
#include "obstack.h"
+#ifdef __STDC__
+#include "gstdarg.h"
+#else
#include "gvarargs.h"
+#endif
#include <stdio.h>
#ifndef R_OK
/* Output an error message and exit */
static void
-fatal (va_alist)
- va_dcl
+fatal VPROTO((char *format, ...))
{
- va_list ap;
+#ifndef __STDC__
char *format;
+#endif
+ va_list ap;
+
+ VA_START (ap, format);
+
+#ifndef __STDC__
+ format = va_arg (ap, char*);
+#endif
- va_start (ap);
- format = va_arg (ap, char *);
fprintf (stderr, "%s: ", programname);
vfprintf (stderr, format, ap);
va_end (ap);
}
static void
-error (va_alist)
- va_dcl
+error VPROTO((char *format, ...))
{
- va_list ap;
+#ifndef __STDC__
char *format;
+#endif
+ va_list ap;
+
+ VA_START (ap, format);
+
+#ifndef __STDC__
+ format = va_arg (ap, char*);
+#endif
- va_start (ap);
- format = va_arg (ap, char *);
fprintf (stderr, "%s: ", programname);
vfprintf (stderr, format, ap);
va_end (ap);