* genattr.c (main): Add extern prototype. Call return, not exit.
* genattrtab.c (main): Likewise.
* gencheck.c (main): Likewise.
* gencodes.c (main): Likewise.
* genconfig.c (main): Likewise.
* genemit.c (main): Likewise.
* genextract.c (main): Likewise.
* genflags.c (main): Likewise.
* gengenrtl.c (main): Likewise.
* genopinit.c (main): Likewise.
* genoutput.c (main): Likewise.
* genpeep.c (main): Likewise.
* genrecog.c (main): Likewise.
* genattr.c (get_insn_name): Mark parameter with ATTRIBUTE_UNUSED.
* genattrtab.c (get_insn_name): Likewise.
* gencodes.c (get_insn_name): Likewise.
* genconfig.c (get_insn_name): Likewise.
* genemit.c (get_insn_name): Likewise.
* genextract.c (get_insn_name): Likewise.
* genflags.c (get_insn_name): Likewise.
* genopinit.c (get_insn_name): Likewise.
* genpeep.c (get_insn_name): Likewise.
* gencheck.c (usage): Add static prototype.
* genextract.c (print_path): Constify a char*.
* genopinit.c (optabs): Likewise.
* genoutput.c (operand_data, data, output_predicate_decls,
compare_operands): Likewise.
* genrecog.c (write_tree): Add default case in switch.
From-SVN: r29434
+Wed Sep 15 10:09:48 1999 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * genattr.c (main): Add extern prototype. Call return, not exit.
+ * genattrtab.c (main): Likewise.
+ * gencheck.c (main): Likewise.
+ * gencodes.c (main): Likewise.
+ * genconfig.c (main): Likewise.
+ * genemit.c (main): Likewise.
+ * genextract.c (main): Likewise.
+ * genflags.c (main): Likewise.
+ * gengenrtl.c (main): Likewise.
+ * genopinit.c (main): Likewise.
+ * genoutput.c (main): Likewise.
+ * genpeep.c (main): Likewise.
+ * genrecog.c (main): Likewise.
+
+ * genattr.c (get_insn_name): Mark parameter with ATTRIBUTE_UNUSED.
+ * genattrtab.c (get_insn_name): Likewise.
+ * gencodes.c (get_insn_name): Likewise.
+ * genconfig.c (get_insn_name): Likewise.
+ * genemit.c (get_insn_name): Likewise.
+ * genextract.c (get_insn_name): Likewise.
+ * genflags.c (get_insn_name): Likewise.
+ * genopinit.c (get_insn_name): Likewise.
+ * genpeep.c (get_insn_name): Likewise.
+
+ * gencheck.c (usage): Add static prototype.
+ * genextract.c (print_path): Constify a char*.
+ * genopinit.c (optabs): Likewise.
+ * genoutput.c (operand_data, data, output_predicate_decls,
+ compare_operands): Likewise.
+ * genrecog.c (write_tree): Add default case in switch.
+
Wed Sep 15 09:59:16 1999 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* rtl.h (get_insn_name, print_rtl_with_bb): Add prototypes.
return ptr;
}
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
printf ("/* Generated automatically by the program `genattr'\n\
printf("#define ATTR_FLAG_very_unlikely\t0x20\n");
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */
const char *
get_insn_name (code)
- int code;
+ int code ATTRIBUTE_UNUSED;
{
return NULL;
}
}
\f
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
/* Set up true and false rtx's */
write_length_unit_log ();
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */
const char *
get_insn_name (code)
- int code;
+ int code ATTRIBUTE_UNUSED;
{
return NULL;
}
(char*)0
};
-void usage ()
+static void usage PROTO ((void));
+
+static void
+usage ()
{
fprintf (stderr,"Usage: gencheck\n");
}
-int main (argc, argv)
+extern int main PROTO ((int, char **));
+
+int
+main (argc, argv)
int argc;
- char *argv[] ATTRIBUTE_UNUSED;
+ char **argv ATTRIBUTE_UNUSED;
{
int i;
default:
usage ();
- exit (1);
+ return (1);
}
printf ("/* This file is generated using gencheck. Do not edit. */\n");
return ptr;
}
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
printf ("/* Generated automatically by the program `gencodes'\n\
printf ("#endif /* MAX_INSN_CODE */\n");
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */
const char *
get_insn_name (code)
- int code;
+ int code ATTRIBUTE_UNUSED;
{
return NULL;
}
return ptr;
}
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
printf ("/* Generated automatically by the program `genconfig'\n\
printf ("#define HAVE_peephole2\n");
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */
const char *
get_insn_name (code)
- int code;
+ int code ATTRIBUTE_UNUSED;
{
return NULL;
}
{
register int i;
int operands;
- char *name = "split";
+ const char *name = "split";
if (GET_CODE (split) == DEFINE_PEEPHOLE2)
name = "peephole2";
return ptr;
}
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
/* Assign sequential codes to all entries in the machine description
output_add_clobbers ();
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */
const char *
get_insn_name (code)
- int code;
+ int code ATTRIBUTE_UNUSED;
{
return NULL;
}
static void gen_insn PROTO ((rtx));
static void walk_rtx PROTO ((rtx, const char *));
-static void print_path PROTO ((char *));
+static void print_path PROTO ((const char *));
static void
gen_insn (insn)
static void
print_path (path)
- char *path;
+ const char *path;
{
register int len = strlen (path);
register int i;
return output;
}
\f
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
/* Assign sequential codes to all entries in the machine description
printf (" }\n}\n");
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */
const char *
get_insn_name (code)
- int code;
+ int code ATTRIBUTE_UNUSED;
{
return NULL;
}
return ptr;
}
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
printf ("/* Generated automatically by the program `genflags'\n\
printf ("#endif /* NO_MD_PROTOTYPES */\n");
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */
const char *
get_insn_name (code)
- int code;
+ int code ATTRIBUTE_UNUSED;
{
return NULL;
}
/* This is the main program. We accept only one argument, "-h", which
says we are writing the genrtl.h file. Otherwise we are writing the
genrtl.c file. */
+extern int main PROTO ((int, char **));
int
main (argc, argv)
gencode ();
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* The reason we use \% is to avoid sequences of the form %-capletter-%
which SCCS treats as magic. This gets warnings which you should ignore. */
-const char *optabs[] =
+const char * const optabs[] =
{ "extendtab[(int) %B][(int) %A][0] = CODE_FOR_%(extend%a\%b2%)",
"extendtab[(int) %B][(int) %A][1] = CODE_FOR_%(zero_extend%a\%b2%)",
"fixtab[(int) %A][(int) %B][0] = CODE_FOR_%(fix%F\%a%I\%b2%)",
return ptr;
}
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
printf ("/* Generated automatically by the program `genopinit'\n\
printf ("}\n");
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */
const char *
get_insn_name (code)
- int code;
+ int code ATTRIBUTE_UNUSED;
{
return NULL;
}
{
struct operand_data *next;
int index;
- char *predicate;
- char *constraint;
+ const char *predicate;
+ const char *constraint;
enum machine_mode mode;
unsigned char n_alternatives;
char address_p;
struct data
{
struct data *next;
- char *name;
- char *template;
+ const char *name;
+ const char *template;
int code_number;
int index_number;
int n_operands; /* Number of operands this insn recognizes */
static void
output_predicate_decls ()
{
- struct predicate { char *name; struct predicate *next; } *predicates = 0;
+ struct predicate { const char *name; struct predicate *next; } *predicates = 0;
register struct operand_data *d;
struct predicate *p;
compare_operands (d0, d1)
struct operand_data *d0, *d1;
{
- char *p0, *p1;
+ const char *p0, *p1;
p0 = d0->predicate;
if (!p0)
return ptr;
}
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
output_prologue ();
output_get_insn_name ();
fflush (stdout);
- exit (ferror (stdout) != 0 || have_error
+ return (ferror (stdout) != 0 || have_error
? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
-
- /* NOTREACHED */
- return 0;
}
static int
return ptr;
}
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
printf ("/* Generated automatically by the program `genpeep'\n\
printf ("#endif\n");
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */
const char *
get_insn_name (code)
- int code;
+ int code ATTRIBUTE_UNUSED;
{
return NULL;
}
name_prefix = "recog";
call_suffix = ", pnum_clobbers";
break;
+ default:
+ abort();
}
if (! initial && tree->subroutine_number > 0)
{
return val;
}
+extern int main PROTO ((int, char **));
+
int
main (argc, argv)
int argc;
if (infile == 0)
{
perror (argv[1]);
- exit (FATAL_EXIT_CODE);
+ return (FATAL_EXIT_CODE);
}
next_insn_code = 0;
}
fflush (stdout);
- exit (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
- /* NOTREACHED */
- return 0;
+ return (ferror (stdout) != 0 ? FATAL_EXIT_CODE : SUCCESS_EXIT_CODE);
}
/* Define this so we can link with print-rtl.o to get debug_rtx function. */