]> gcc.gnu.org Git - gcc.git/blame - gcc/config/i386/i386-protos.h
re PR target/19009 (Loading of FP constants into FP reg via SSE reg)
[gcc.git] / gcc / config / i386 / i386-protos.h
CommitLineData
188fc5b5 1/* Definitions of target machine for GCC for IA-32.
0e4970d7 2 Copyright (C) 1988, 1992, 1994, 1995, 1996, 1996, 1997, 1998, 1999,
283334f0 3 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
6baf1cc8 4
188fc5b5 5This file is part of GCC.
6baf1cc8 6
188fc5b5 7GCC is free software; you can redistribute it and/or modify
6baf1cc8
BS
8it under the terms of the GNU General Public License as published by
9the Free Software Foundation; either version 2, or (at your option)
10any later version.
11
188fc5b5 12GCC is distributed in the hope that it will be useful,
6baf1cc8
BS
13but WITHOUT ANY WARRANTY; without even the implied warranty of
14MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15GNU General Public License for more details.
16
17You should have received a copy of the GNU General Public License
188fc5b5 18along with GCC; see the file COPYING. If not, write to
6baf1cc8 19the Free Software Foundation, 59 Temple Place - Suite 330,
892a2d68 20Boston, MA 02111-1307, USA. */
6baf1cc8
BS
21
22/* Functions in i386.c */
b96a374d
AJ
23extern void override_options (void);
24extern void optimization_options (int, int);
6baf1cc8 25
b96a374d
AJ
26extern int ix86_can_use_return_insn_p (void);
27extern int ix86_frame_pointer_required (void);
28extern void ix86_setup_frame_addresses (void);
6baf1cc8 29
b96a374d
AJ
30extern void ix86_file_end (void);
31extern HOST_WIDE_INT ix86_initial_elimination_offset (int, int);
32extern void ix86_expand_prologue (void);
33extern void ix86_expand_epilogue (int);
6baf1cc8 34
b96a374d
AJ
35extern void ix86_output_addr_vec_elt (FILE *, int);
36extern void ix86_output_addr_diff_elt (FILE *, int, int);
f88c65f7 37
6baf1cc8 38#ifdef RTX_CODE
b96a374d
AJ
39extern int ix86_aligned_p (rtx);
40
41extern int standard_80387_constant_p (rtx);
42extern const char *standard_80387_constant_opcode (rtx);
43extern rtx standard_80387_constant_rtx (int);
44extern int standard_sse_constant_p (rtx);
45extern int symbolic_reference_mentioned_p (rtx);
46extern bool extended_reg_mentioned_p (rtx);
47extern bool x86_extended_QIreg_mentioned_p (rtx);
48extern bool x86_extended_reg_mentioned_p (rtx);
49
50extern int any_fp_register_operand (rtx, enum machine_mode);
51extern int register_and_not_any_fp_reg_operand (rtx, enum machine_mode);
52
53extern int fp_register_operand (rtx, enum machine_mode);
54extern int register_and_not_fp_reg_operand (rtx, enum machine_mode);
55
56extern int x86_64_general_operand (rtx, enum machine_mode);
57extern int x86_64_szext_general_operand (rtx, enum machine_mode);
58extern int x86_64_nonmemory_operand (rtx, enum machine_mode);
59extern int x86_64_szext_nonmemory_operand (rtx, enum machine_mode);
60extern int x86_64_immediate_operand (rtx, enum machine_mode);
61extern int x86_64_zext_immediate_operand (rtx, enum machine_mode);
b96a374d
AJ
62extern int symbolic_operand (rtx, enum machine_mode);
63extern int tls_symbolic_operand (rtx, enum machine_mode);
64extern int global_dynamic_symbolic_operand (rtx, enum machine_mode);
65extern int local_dynamic_symbolic_operand (rtx, enum machine_mode);
66extern int initial_exec_symbolic_operand (rtx, enum machine_mode);
67extern int local_exec_symbolic_operand (rtx, enum machine_mode);
68extern int pic_symbolic_operand (rtx, enum machine_mode);
69extern int call_insn_operand (rtx, enum machine_mode);
70extern int sibcall_insn_operand (rtx, enum machine_mode);
71extern int constant_call_address_operand (rtx, enum machine_mode);
72extern int const0_operand (rtx, enum machine_mode);
73extern int const1_operand (rtx, enum machine_mode);
74extern int const248_operand (rtx, enum machine_mode);
75extern int incdec_operand (rtx, enum machine_mode);
76extern int reg_no_sp_operand (rtx, enum machine_mode);
77extern int mmx_reg_operand (rtx, enum machine_mode);
78extern int general_no_elim_operand (rtx, enum machine_mode);
79extern int nonmemory_no_elim_operand (rtx, enum machine_mode);
80extern int q_regs_operand (rtx, enum machine_mode);
81extern int non_q_regs_operand (rtx, enum machine_mode);
82extern int sse_comparison_operator (rtx, enum machine_mode);
83extern int fcmov_comparison_operator (rtx, enum machine_mode);
84extern int cmp_fp_expander_operand (rtx, enum machine_mode);
85extern int ix86_comparison_operator (rtx, enum machine_mode);
86extern int ext_register_operand (rtx, enum machine_mode);
87extern int binary_fp_operator (rtx, enum machine_mode);
88extern int mult_operator (rtx, enum machine_mode);
89extern int div_operator (rtx, enum machine_mode);
90extern int arith_or_logical_operator (rtx, enum machine_mode);
91extern int promotable_binary_operator (rtx, enum machine_mode);
92extern int memory_displacement_operand (rtx, enum machine_mode);
93extern int cmpsi_operand (rtx, enum machine_mode);
94extern int long_memory_operand (rtx, enum machine_mode);
95extern int aligned_operand (rtx, enum machine_mode);
96extern enum machine_mode ix86_cc_mode (enum rtx_code, rtx, rtx);
97
70128ad9
AO
98extern int ix86_expand_movmem (rtx, rtx, rtx, rtx);
99extern int ix86_expand_clrmem (rtx, rtx, rtx);
b96a374d
AJ
100extern int ix86_expand_strlen (rtx, rtx, rtx, rtx);
101
102extern bool legitimate_constant_p (rtx);
103extern bool constant_address_p (rtx);
104extern bool legitimate_pic_operand_p (rtx);
105extern int legitimate_pic_address_disp_p (rtx);
106extern int legitimate_address_p (enum machine_mode, rtx, int);
b96a374d
AJ
107extern rtx legitimize_address (rtx, rtx, enum machine_mode);
108
109extern void print_reg (rtx, int, FILE*);
110extern void print_operand (FILE*, rtx, int);
111extern void print_operand_address (FILE*, rtx);
112extern bool output_addr_const_extra (FILE*, rtx);
113
114extern void split_di (rtx[], int, rtx[], rtx[]);
115extern void split_ti (rtx[], int, rtx[], rtx[]);
116
117extern const char *output_set_got (rtx);
118extern const char *output_387_binary_op (rtx, rtx*);
5ea9cb6e 119extern const char *output_387_reg_move (rtx, rtx*);
b96a374d
AJ
120extern const char *output_fix_trunc (rtx, rtx*);
121extern const char *output_fp_compare (rtx, rtx*, int, int);
122
b96a374d
AJ
123extern void i386_output_dwarf_dtprel (FILE*, int, rtx);
124
125extern void ix86_expand_clear (rtx);
126extern void ix86_expand_move (enum machine_mode, rtx[]);
127extern void ix86_expand_vector_move (enum machine_mode, rtx[]);
c38573a8 128extern void ix86_expand_vector_move_misalign (enum machine_mode, rtx[]);
ef719a44
RH
129extern rtx ix86_fixup_binary_operands (enum rtx_code,
130 enum machine_mode, rtx[]);
131extern void ix86_fixup_binary_operands_no_copy (enum rtx_code,
132 enum machine_mode, rtx[]);
b96a374d
AJ
133extern void ix86_expand_binary_operator (enum rtx_code,
134 enum machine_mode, rtx[]);
135extern int ix86_binary_operator_ok (enum rtx_code, enum machine_mode, rtx[]);
136extern void ix86_expand_unary_operator (enum rtx_code, enum machine_mode,
137 rtx[]);
7cacf53e
RH
138extern void ix86_expand_fp_absneg_operator (enum rtx_code, enum machine_mode,
139 rtx[]);
b96a374d
AJ
140extern int ix86_unary_operator_ok (enum rtx_code, enum machine_mode, rtx[]);
141extern int ix86_match_ccmode (rtx, enum machine_mode);
142extern rtx ix86_expand_compare (enum rtx_code, rtx *, rtx *);
143extern int ix86_use_fcomi_compare (enum rtx_code);
144extern void ix86_expand_branch (enum rtx_code, rtx);
145extern int ix86_expand_setcc (enum rtx_code, rtx);
146extern int ix86_expand_int_movcc (rtx[]);
147extern int ix86_expand_fp_movcc (rtx[]);
eaa49b49 148extern void ix86_split_sse_movcc (rtx[]);
b96a374d
AJ
149extern int ix86_expand_int_addcc (rtx[]);
150extern void ix86_expand_call (rtx, rtx, rtx, rtx, rtx, int);
151extern void x86_initialize_trampoline (rtx, rtx, rtx);
152extern rtx ix86_zero_extend_to_Pmode (rtx);
153extern void ix86_split_long_move (rtx[]);
154extern void ix86_split_ashldi (rtx *, rtx);
155extern void ix86_split_ashrdi (rtx *, rtx);
156extern void ix86_split_lshrdi (rtx *, rtx);
157extern rtx ix86_find_base_term (rtx);
7e6dc358 158extern int ix86_check_movabs (rtx, int);
b96a374d
AJ
159
160extern rtx assign_386_stack_local (enum machine_mode, int);
161extern int ix86_attr_length_immediate_default (rtx, int);
162extern int ix86_attr_length_address_default (rtx);
163
164extern enum machine_mode ix86_fp_compare_mode (enum rtx_code);
165
b96a374d
AJ
166extern rtx ix86_libcall_value (enum machine_mode);
167extern bool ix86_function_value_regno_p (int);
168extern bool ix86_function_arg_regno_p (int);
169extern int ix86_function_arg_boundary (enum machine_mode, tree);
170extern int ix86_return_in_memory (tree);
171extern void ix86_va_start (tree, rtx);
172extern rtx ix86_va_arg (tree, tree);
b96a374d
AJ
173
174extern rtx ix86_force_to_memory (enum machine_mode, rtx);
175extern void ix86_free_from_memory (enum machine_mode);
7c82106f
UB
176extern void ix86_split_fp_branch (enum rtx_code code, rtx, rtx,
177 rtx, rtx, rtx, rtx);
b96a374d
AJ
178extern int ix86_hard_regno_mode_ok (int, enum machine_mode);
179extern int ix86_register_move_cost (enum machine_mode, enum reg_class,
180 enum reg_class);
181extern int ix86_secondary_memory_needed (enum reg_class, enum reg_class,
182 enum machine_mode, int);
183extern enum reg_class ix86_preferred_reload_class (rtx, enum reg_class);
184extern int ix86_memory_move_cost (enum machine_mode, enum reg_class, int);
edeacc14 185extern void emit_i387_cw_initialization (rtx, rtx, int);
b96a374d
AJ
186extern bool ix86_fp_jump_nontrivial_p (enum rtx_code);
187extern void x86_order_regs_for_local_alloc (void);
188extern void x86_function_profiler (FILE *, int);
189extern void x86_emit_floatuns (rtx [2]);
5ae27cfa 190extern void ix86_emit_fp_unordered_jump (rtx);
397be6cf 191
c2fcfa4f
UB
192extern void ix86_emit_i387_log1p (rtx, rtx);
193
3c5cb3e4 194extern enum rtx_code ix86_reverse_condition (enum rtx_code, enum machine_mode);
4211a8fb 195
6baf1cc8 196#ifdef TREE_CODE
b96a374d
AJ
197extern void init_cumulative_args (CUMULATIVE_ARGS *, tree, rtx, tree);
198extern rtx function_arg (CUMULATIVE_ARGS *, enum machine_mode, tree, int);
b96a374d
AJ
199extern void function_arg_advance (CUMULATIVE_ARGS *, enum machine_mode,
200 tree, int);
201extern rtx ix86_function_value (tree);
6baf1cc8
BS
202#endif
203
204#endif
205
206#ifdef TREE_CODE
b96a374d 207extern int ix86_return_pops_args (tree, tree, int);
b96a374d
AJ
208
209extern int ix86_data_alignment (tree, int);
210extern int ix86_local_alignment (tree, int);
211extern int ix86_constant_alignment (tree, int);
b96a374d
AJ
212extern tree ix86_handle_shared_attribute (tree *, tree, tree, int, bool *);
213
214extern unsigned int i386_pe_section_type_flags (tree, const char *, int);
c18a5b6c 215extern void i386_pe_asm_named_section (const char *, unsigned int, tree);
b96a374d 216extern int x86_field_alignment (tree, int);
6baf1cc8 217#endif
772c5265 218
b96a374d 219extern rtx ix86_tls_get_addr (void);
f996902d 220
eb701deb
RH
221extern void ix86_expand_vector_init (bool, rtx, rtx);
222extern void ix86_expand_vector_set (bool, rtx, rtx, int);
223extern void ix86_expand_vector_extract (bool, rtx, rtx, int);
224
772c5265 225/* In winnt.c */
b96a374d
AJ
226extern int i386_pe_dllexport_name_p (const char *);
227extern int i386_pe_dllimport_name_p (const char *);
228extern void i386_pe_unique_section (tree, int);
229extern void i386_pe_declare_function_type (FILE *, const char *, int);
230extern void i386_pe_record_external_function (const char *);
231extern void i386_pe_record_exported_symbol (const char *, int);
232extern void i386_pe_asm_file_end (FILE *);
233extern void i386_pe_encode_section_info (tree, rtx, int);
234extern const char *i386_pe_strip_name_encoding (const char *);
235extern const char *i386_pe_strip_name_encoding_full (const char *);
236extern void i386_pe_output_labelref (FILE *, const char *);
8fe75e43
RH
237extern rtx maybe_get_pool_constant (rtx);
238
239extern char internal_label_prefix[16];
240extern int internal_label_prefix_len;
241
242enum ix86_address_seg { SEG_DEFAULT, SEG_FS, SEG_GS };
243struct ix86_address
244{
245 rtx base, index, disp;
246 HOST_WIDE_INT scale;
247 enum ix86_address_seg seg;
248};
249
250extern int ix86_decompose_address (rtx, struct ix86_address *);
251extern int memory_address_length (rtx addr);
252
253#ifdef RTX_CODE
254extern void ix86_fp_comparison_codes (enum rtx_code code, enum rtx_code *,
255 enum rtx_code *, enum rtx_code *);
256extern enum rtx_code ix86_fp_compare_code_to_integer (enum rtx_code);
257#endif
This page took 1.218327 seconds and 5 git commands to generate.