* tree-ssa-loop-prefetch.c (determine_unroll_factor): Bound the unroll
[official-gcc.git] / gcc / config / arm / arm-protos.h
1 /* Prototypes for exported functions defined in arm.c and pe.c
2 Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
3 Free Software Foundation, Inc.
4 Contributed by Richard Earnshaw (rearnsha@arm.com)
5 Minor hacks by Nick Clifton (nickc@cygnus.com)
6
7 This file is part of GCC.
8
9 GCC 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)
12 any later version.
13
14 GCC 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.
18
19 You should have received a copy of the GNU General Public License
20 along with GCC; see the file COPYING. If not, write to
21 the Free Software Foundation, 51 Franklin Street, Fifth Floor,
22 Boston, MA 02110-1301, USA. */
23
24 #ifndef GCC_ARM_PROTOS_H
25 #define GCC_ARM_PROTOS_H
26
27 extern void arm_override_options (void);
28 extern int use_return_insn (int, rtx);
29 extern int arm_regno_class (int);
30 extern void arm_load_pic_register (unsigned long);
31 extern int arm_volatile_func (void);
32 extern const char *arm_output_epilogue (rtx);
33 extern void arm_expand_prologue (void);
34 extern const char *arm_strip_name_encoding (const char *);
35 extern void arm_asm_output_labelref (FILE *, const char *);
36 extern void thumb2_asm_output_opcode (FILE *);
37 extern unsigned long arm_current_func_type (void);
38 extern HOST_WIDE_INT arm_compute_initial_elimination_offset (unsigned int,
39 unsigned int);
40 extern HOST_WIDE_INT thumb_compute_initial_elimination_offset (unsigned int,
41 unsigned int);
42 extern unsigned int arm_dbx_register_number (unsigned int);
43 extern void arm_output_fn_unwind (FILE *, bool);
44
45
46 #ifdef TREE_CODE
47 extern int arm_return_in_memory (tree);
48 extern void arm_encode_call_attribute (tree, int);
49 #endif
50 #ifdef RTX_CODE
51 extern bool arm_vector_mode_supported_p (enum machine_mode);
52 extern int arm_hard_regno_mode_ok (unsigned int, enum machine_mode);
53 extern int const_ok_for_arm (HOST_WIDE_INT);
54 extern int arm_split_constant (RTX_CODE, enum machine_mode, rtx,
55 HOST_WIDE_INT, rtx, rtx, int);
56 extern RTX_CODE arm_canonicalize_comparison (RTX_CODE, enum machine_mode,
57 rtx *);
58 extern int legitimate_pic_operand_p (rtx);
59 extern rtx legitimize_pic_address (rtx, enum machine_mode, rtx);
60 extern rtx legitimize_tls_address (rtx, rtx);
61 extern int arm_legitimate_address_p (enum machine_mode, rtx, RTX_CODE, int);
62 extern int thumb1_legitimate_address_p (enum machine_mode, rtx, int);
63 extern int thumb2_legitimate_address_p (enum machine_mode, rtx, int);
64 extern int thumb_legitimate_offset_p (enum machine_mode, HOST_WIDE_INT);
65 extern rtx arm_legitimize_address (rtx, rtx, enum machine_mode);
66 extern rtx thumb_legitimize_address (rtx, rtx, enum machine_mode);
67 extern rtx thumb_legitimize_reload_address (rtx *, enum machine_mode, int, int,
68 int);
69 extern int arm_const_double_rtx (rtx);
70 extern int neg_const_double_rtx_ok_for_fpa (rtx);
71 extern enum reg_class vfp_secondary_reload_class (enum machine_mode, rtx);
72 extern bool arm_tls_referenced_p (rtx);
73
74 extern int cirrus_memory_offset (rtx);
75 extern int arm_coproc_mem_operand (rtx, bool);
76 extern int arm_no_early_store_addr_dep (rtx, rtx);
77 extern int arm_no_early_alu_shift_dep (rtx, rtx);
78 extern int arm_no_early_alu_shift_value_dep (rtx, rtx);
79 extern int arm_no_early_mul_dep (rtx, rtx);
80
81 extern int tls_mentioned_p (rtx);
82 extern int symbol_mentioned_p (rtx);
83 extern int label_mentioned_p (rtx);
84 extern RTX_CODE minmax_code (rtx);
85 extern int adjacent_mem_locations (rtx, rtx);
86 extern int load_multiple_sequence (rtx *, int, int *, int *, HOST_WIDE_INT *);
87 extern const char *emit_ldm_seq (rtx *, int);
88 extern int store_multiple_sequence (rtx *, int, int *, int *, HOST_WIDE_INT *);
89 extern const char * emit_stm_seq (rtx *, int);
90 extern rtx arm_gen_load_multiple (int, int, rtx, int, int,
91 rtx, HOST_WIDE_INT *);
92 extern rtx arm_gen_store_multiple (int, int, rtx, int, int,
93 rtx, HOST_WIDE_INT *);
94 extern int arm_gen_movmemqi (rtx *);
95 extern enum machine_mode arm_select_cc_mode (RTX_CODE, rtx, rtx);
96 extern enum machine_mode arm_select_dominance_cc_mode (rtx, rtx,
97 HOST_WIDE_INT);
98 extern rtx arm_gen_compare_reg (RTX_CODE, rtx, rtx);
99 extern rtx arm_gen_return_addr_mask (void);
100 extern void arm_reload_in_hi (rtx *);
101 extern void arm_reload_out_hi (rtx *);
102 extern int arm_const_double_inline_cost (rtx);
103 extern bool arm_const_double_by_parts (rtx);
104 extern const char *fp_immediate_constant (rtx);
105 extern const char *output_call (rtx *);
106 extern const char *output_call_mem (rtx *);
107 extern const char *output_mov_long_double_fpa_from_arm (rtx *);
108 extern const char *output_mov_long_double_arm_from_fpa (rtx *);
109 extern const char *output_mov_long_double_arm_from_arm (rtx *);
110 extern const char *output_mov_double_fpa_from_arm (rtx *);
111 extern const char *output_mov_double_arm_from_fpa (rtx *);
112 extern const char *output_move_double (rtx *);
113 extern const char *output_move_vfp (rtx *operands);
114 extern const char *output_add_immediate (rtx *);
115 extern const char *arithmetic_instr (rtx, int);
116 extern void output_ascii_pseudo_op (FILE *, const unsigned char *, int);
117 extern const char *output_return_instruction (rtx, int, int);
118 extern void arm_poke_function_name (FILE *, const char *);
119 extern void arm_print_operand (FILE *, rtx, int);
120 extern void arm_print_operand_address (FILE *, rtx);
121 extern void arm_final_prescan_insn (rtx);
122 extern int arm_debugger_arg_offset (int, rtx);
123 extern int arm_is_longcall_p (rtx, int, int);
124 extern int arm_emit_vector_const (FILE *, rtx);
125 extern const char * arm_output_load_gr (rtx *);
126 extern const char *vfp_output_fstmd (rtx *);
127 extern void arm_set_return_address (rtx, rtx);
128 extern int arm_eliminable_register (rtx);
129 extern const char *arm_output_shift(rtx *, int);
130
131 extern bool arm_output_addr_const_extra (FILE *, rtx);
132
133 #if defined TREE_CODE
134 extern rtx arm_function_arg (CUMULATIVE_ARGS *, enum machine_mode, tree, int);
135 extern void arm_init_cumulative_args (CUMULATIVE_ARGS *, tree, rtx, tree);
136 extern bool arm_pad_arg_upward (enum machine_mode, tree);
137 extern bool arm_pad_reg_upward (enum machine_mode, tree, int);
138 extern bool arm_needs_doubleword_align (enum machine_mode, tree);
139 extern rtx arm_function_value(tree, tree);
140 #endif
141 extern int arm_apply_result_size (void);
142
143 #if defined AOF_ASSEMBLER
144 extern rtx aof_pic_entry (rtx);
145 extern void aof_add_import (const char *);
146 extern void aof_delete_import (const char *);
147 extern void zero_init_section (void);
148 #endif /* AOF_ASSEMBLER */
149
150 #endif /* RTX_CODE */
151
152 extern int arm_float_words_big_endian (void);
153
154 /* Thumb functions. */
155 extern void arm_init_expanders (void);
156 extern const char *thumb_unexpanded_epilogue (void);
157 extern void thumb1_expand_prologue (void);
158 extern void thumb1_expand_epilogue (void);
159 #ifdef TREE_CODE
160 extern int is_called_in_ARM_mode (tree);
161 #endif
162 extern int thumb_shiftable_const (unsigned HOST_WIDE_INT);
163 #ifdef RTX_CODE
164 extern void thumb1_final_prescan_insn (rtx);
165 extern void thumb2_final_prescan_insn (rtx);
166 extern const char *thumb_load_double_from_address (rtx *);
167 extern const char *thumb_output_move_mem_multiple (int, rtx *);
168 extern const char *thumb_call_via_reg (rtx);
169 extern void thumb_expand_movmemqi (rtx *);
170 extern rtx arm_return_addr (int, rtx);
171 extern void thumb_reload_out_hi (rtx *);
172 extern void thumb_reload_in_hi (rtx *);
173 extern void thumb_set_return_address (rtx, rtx);
174 extern const char *thumb2_output_casesi(rtx *);
175 #endif
176
177 /* Defined in pe.c. */
178 extern int arm_dllexport_name_p (const char *);
179 extern int arm_dllimport_name_p (const char *);
180
181 #ifdef TREE_CODE
182 extern void arm_pe_unique_section (tree, int);
183 extern void arm_pe_encode_section_info (tree, rtx, int);
184 extern int arm_dllexport_p (tree);
185 extern int arm_dllimport_p (tree);
186 extern void arm_mark_dllexport (tree);
187 extern void arm_mark_dllimport (tree);
188 #endif
189
190 extern void arm_pr_long_calls (struct cpp_reader *);
191 extern void arm_pr_no_long_calls (struct cpp_reader *);
192 extern void arm_pr_long_calls_off (struct cpp_reader *);
193
194 #endif /* ! GCC_ARM_PROTOS_H */