diff options
author | Kaveh R. Ghazi <ghazi@caip.rutgers.edu> | 1999-08-24 13:34:04 +0000 |
---|---|---|
committer | Kaveh Ghazi <ghazi@gcc.gnu.org> | 1999-08-24 13:34:04 +0000 |
commit | 69277eec7740edb7968777c8ca4f43286eab820e (patch) | |
tree | 7e5beb032b12a5f206bc4a2895f87b97907ab018 /gcc/genrecog.c | |
parent | 33f58a4e96ff4e46a0f238fac2a7927eb5845f09 (diff) | |
download | gcc-69277eec7740edb7968777c8ca4f43286eab820e.zip gcc-69277eec7740edb7968777c8ca4f43286eab820e.tar.gz gcc-69277eec7740edb7968777c8ca4f43286eab820e.tar.bz2 |
genattr.c (function_unit_desc): Constify a char*.
* genattr.c (function_unit_desc): Constify a char*. Add prototype.
(main): Add prototypes.
* genattrtab.c (substitute_address, write_const_num_delay_slots,
attr_eq, attr_numeral, attr_equal_p, attr_copy_rtx): Prototype.
(write_attr_get): Emit prototypes along with function definition.
(write_eligible_delay): Mark a parameter with ATTRIBUTE_UNUSED.
(write_complex_function): Emit static prototype along with
function definition.
* genemit.c (gen_split): Emit prototypes along with function
definition.
* genoutput.c (output_epilogue): Add prototype to `insn_outfun'.
Likewise for predicates and `insn_operand_predicate'.
(process_template): Emit static prototype along with function
definition.
* genrecog.c (make_insn_sequence): Constify a char*. Add
prototypes for get_split_*().
(write_subroutine): Emit prototypes along with function
definition.
From-SVN: r28822
Diffstat (limited to 'gcc/genrecog.c')
-rw-r--r-- | gcc/genrecog.c | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/gcc/genrecog.c b/gcc/genrecog.c index ebe5d30..8fb846b 100644 --- a/gcc/genrecog.c +++ b/gcc/genrecog.c @@ -213,7 +213,7 @@ make_insn_sequence (insn, type) struct decision_head head; { - static char *last_real_name = "insn"; + static const char *last_real_name = "insn"; static int last_real_code = 0; char *name; @@ -306,7 +306,7 @@ make_insn_sequence (insn, type) if (type == SPLIT) /* Define the subroutine we will call below and emit in genemit. */ - printf ("extern rtx gen_split_%d ();\n", last->insn_code_number); + printf ("extern rtx gen_split_%d PROTO ((rtx *));\n", last->insn_code_number); return head; } @@ -1032,6 +1032,19 @@ write_subroutine (tree, type) int i; if (type == SPLIT) + printf ("extern rtx split"); + else + printf ("extern int recog"); + if (tree != 0 && tree->subroutine_number > 0) + printf ("_%d", tree->subroutine_number); + else if (type == SPLIT) + printf ("_insns"); + printf (" PROTO ((rtx, rtx"); + if (type == RECOG) + printf (", int *"); + printf ("));\n"); + + if (type == SPLIT) printf ("rtx\nsplit"); else printf ("int\nrecog"); |