1 /* Definitions of target machine for GNU compiler for Hitachi / SuperH SH.
2 Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000
3 Free Software Foundation, Inc.
4 Contributed by Steve Chamberlain (sac@cygnus.com).
5 Improved by Jim Wilson (wilson@cygnus.com).
7 This file is part of GNU CC.
9 GNU CC is free software; you can redistribute it and/or modify
10 it under the terms of the GNU General Public License as published by
11 the Free Software Foundation; either version 2, or (at your option)
14 GNU CC is distributed in the hope that it will be useful,
15 but WITHOUT ANY WARRANTY; without even the implied warranty of
16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 GNU General Public License for more details.
19 You should have received a copy of the GNU General Public License
20 along with GNU CC; see the file COPYING. If not, write to
21 the Free Software Foundation, 59 Temple Place - Suite 330,
22 Boston, MA 02111-1307, USA. */
24 #ifndef GCC_SH_PROTOS_H
25 #define GCC_SH_PROTOS_H
28 extern struct rtx_def
*sh_builtin_saveregs
PARAMS ((void));
29 extern struct rtx_def
*prepare_scc_operands
PARAMS ((enum rtx_code
));
31 /* Declare functions defined in sh.c and used in templates. */
33 extern const char *output_branch
PARAMS ((int, rtx
, rtx
*));
34 extern const char *output_ieee_ccmpeq
PARAMS ((rtx
, rtx
*));
35 extern const char *output_branchy_insn
PARAMS ((enum rtx_code
, const char *, rtx
, rtx
*));
36 extern const char *output_movedouble
PARAMS ((rtx
, rtx
[], enum machine_mode
));
37 extern const char *output_movepcrel
PARAMS ((rtx
, rtx
[], enum machine_mode
));
38 extern const char *output_far_jump
PARAMS ((rtx
, rtx
));
40 extern void machine_dependent_reorg
PARAMS ((rtx
));
41 extern struct rtx_def
*sfunc_uses_reg
PARAMS ((rtx
));
42 extern int barrier_align
PARAMS ((rtx
));
43 extern int sh_loop_align
PARAMS ((rtx
));
44 extern int fp_zero_operand
PARAMS ((rtx
));
45 extern int fp_one_operand
PARAMS ((rtx
));
46 extern int fp_int_operand
PARAMS ((rtx
));
47 extern rtx get_fpscr_rtx
PARAMS ((void));
48 extern rtx legitimize_pic_address
PARAMS ((rtx
, enum machine_mode
, rtx
));
49 extern int nonpic_symbol_mentioned_p
PARAMS ((rtx
));
50 extern void emit_sf_insn
PARAMS ((rtx
));
51 extern void emit_df_insn
PARAMS ((rtx
));
52 extern void print_operand_address
PARAMS ((FILE *, rtx
));
53 extern void print_operand
PARAMS ((FILE *, rtx
, int));
54 extern void output_pic_addr_const
PARAMS ((FILE *, rtx
));
55 extern int expand_block_move
PARAMS ((rtx
*));
56 extern int prepare_move_operands
PARAMS ((rtx
[], enum machine_mode mode
));
57 extern void from_compare
PARAMS ((rtx
*, int));
58 extern int shift_insns_rtx
PARAMS ((rtx
));
59 extern int shiftcosts
PARAMS ((rtx
));
60 extern int addsubcosts
PARAMS ((rtx
));
61 extern int andcosts
PARAMS ((rtx
));
62 extern int multcosts
PARAMS ((rtx
));
63 extern void gen_ashift
PARAMS ((int, int, rtx
));
64 extern void gen_ashift_hi
PARAMS ((int, int, rtx
));
65 extern void gen_shifty_op
PARAMS ((int, rtx
*));
66 extern void gen_shifty_hi_op
PARAMS ((int, rtx
*));
67 extern int expand_ashiftrt
PARAMS ((rtx
*));
68 extern int sh_dynamicalize_shift_p
PARAMS ((rtx
));
69 extern int shl_and_kind
PARAMS ((rtx
, rtx
, int *));
70 extern int shl_and_length
PARAMS ((rtx
));
71 extern int shl_and_scr_length
PARAMS ((rtx
));
72 extern int gen_shl_and
PARAMS ((rtx
, rtx
, rtx
, rtx
));
73 extern int shl_sext_kind
PARAMS ((rtx
, rtx
, int *));
74 extern int shl_sext_length
PARAMS ((rtx
));
75 extern int gen_shl_sext
PARAMS ((rtx
, rtx
, rtx
, rtx
));
76 extern rtx gen_datalabel_ref
PARAMS ((rtx
));
77 extern int regs_used
PARAMS ((rtx
, int));
78 extern void fixup_addr_diff_vecs
PARAMS ((rtx
));
79 extern int get_dest_uid
PARAMS ((rtx
, int));
80 extern void final_prescan_insn
PARAMS ((rtx
, rtx
*, int));
81 extern int symbol_ref_operand
PARAMS ((rtx
, enum machine_mode
));
82 extern int system_reg_operand
PARAMS ((rtx
, enum machine_mode
));
83 extern int general_movsrc_operand
PARAMS ((rtx
, enum machine_mode
));
84 extern int general_movdst_operand
PARAMS ((rtx
, enum machine_mode
));
85 extern int arith_reg_operand
PARAMS ((rtx
, enum machine_mode
));
86 extern int fp_arith_reg_operand
PARAMS ((rtx
, enum machine_mode
));
87 extern int arith_operand
PARAMS ((rtx
, enum machine_mode
));
88 extern int arith_reg_or_0_operand
PARAMS ((rtx
, enum machine_mode
));
89 extern int logical_operand
PARAMS ((rtx
, enum machine_mode
));
90 extern int tertiary_reload_operand
PARAMS ((rtx
, enum machine_mode
));
91 extern int fpscr_operand
PARAMS ((rtx
, enum machine_mode
));
92 extern int fpul_operand
PARAMS ((rtx
, enum machine_mode
));
93 extern int commutative_float_operator
PARAMS ((rtx
, enum machine_mode
));
94 extern int noncommutative_float_operator
PARAMS ((rtx
, enum machine_mode
));
95 extern int reg_unused_after
PARAMS ((rtx
, rtx
));
96 extern void expand_sf_unop
PARAMS ((rtx (*)(rtx
, rtx
, rtx
), rtx
*));
97 extern void expand_sf_binop
PARAMS ((rtx (*)(rtx
, rtx
, rtx
, rtx
), rtx
*));
98 extern void expand_df_unop
PARAMS ((rtx (*)(rtx
, rtx
, rtx
), rtx
*));
99 extern void expand_df_binop
PARAMS ((rtx (*)(rtx
, rtx
, rtx
, rtx
), rtx
*));
100 extern void expand_fp_branch
PARAMS ((rtx (*)(void), rtx (*)(void)));
101 extern int sh_insn_length_adjustment
PARAMS ((rtx
));
102 extern int sh_can_redirect_branch
PARAMS ((rtx
, rtx
));
103 extern void sh_expand_unop_v2sf
PARAMS ((enum rtx_code
, rtx
, rtx
));
104 extern void sh_expand_binop_v2sf
PARAMS ((enum rtx_code
, rtx
, rtx
, rtx
));
106 extern void sh_va_start
PARAMS ((tree
, rtx
));
107 extern rtx sh_va_arg
PARAMS ((tree
, tree
));
108 #endif /* TREE_CODE */
109 #endif /* RTX_CODE */
112 extern tree sh_build_va_list
PARAMS ((void));
113 #endif /* TREE_CODE */
115 extern const char *output_jump_label_table
PARAMS ((void));
116 extern int sh_handle_pragma
PARAMS ((int (*)(void), void (*)(int), const char *));
117 extern struct rtx_def
*get_fpscr_rtx
PARAMS ((void));
118 extern void output_file_start
PARAMS ((FILE *));
119 extern int sh_media_register_for_return
PARAMS ((void));
120 extern void sh_expand_prologue
PARAMS ((void));
121 extern void sh_expand_epilogue
PARAMS ((void));
122 extern int sh_need_epilogue
PARAMS ((void));
123 extern int initial_elimination_offset
PARAMS ((int, int));
124 extern int fldi_ok
PARAMS ((void));
125 extern int sh_pr_n_sets
PARAMS ((void));
126 extern int sh_hard_regno_rename_ok
PARAMS ((unsigned int, unsigned int));
127 extern int sh_cfun_interrupt_handler_p
PARAMS ((void));
128 extern void sh_initialize_trampoline
PARAMS ((rtx
, rtx
, rtx
));
129 extern enum reg_class sh_cannot_change_mode_class
130 PARAMS ((enum machine_mode
, enum machine_mode
));
133 extern void fpscr_set_from_mem
PARAMS ((int, HARD_REG_SET
));
136 #ifdef GCC_C_PRAGMA_H
137 extern void sh_pr_interrupt
PARAMS ((cpp_reader
*));
138 extern void sh_pr_trapa
PARAMS ((cpp_reader
*));
139 extern void sh_pr_nosave_low_regs
PARAMS ((cpp_reader
*));
142 #endif /* ! GCC_SH_PROTOS_H */