]> git.ipfire.org Git - thirdparty/gcc.git/blame - gcc/config/sparc/sparc-protos.h
sparc-protos.h (sparc_branch_cost): Declare.
[thirdparty/gcc.git] / gcc / config / sparc / sparc-protos.h
CommitLineData
6a151f87 1/* Prototypes of target machine for SPARC.
85ec4feb 2 Copyright (C) 1999-2018 Free Software Foundation, Inc.
b1474bb7 3 Contributed by Michael Tiemann (tiemann@cygnus.com).
6a151f87 4 64-bit SPARC-V9 support by Michael Tiemann, Jim Wilson, and Doug Evans,
b1474bb7
KG
5 at Cygnus Support.
6
de0a398e 7This file is part of GCC.
b1474bb7 8
de0a398e 9GCC is free software; you can redistribute it and/or modify
b1474bb7 10it under the terms of the GNU General Public License as published by
2f83c7d6 11the Free Software Foundation; either version 3, or (at your option)
b1474bb7
KG
12any later version.
13
de0a398e 14GCC is distributed in the hope that it will be useful,
b1474bb7
KG
15but WITHOUT ANY WARRANTY; without even the implied warranty of
16MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17GNU General Public License for more details.
18
19You should have received a copy of the GNU General Public License
2f83c7d6
NC
20along with GCC; see the file COPYING3. If not see
21<http://www.gnu.org/licenses/>. */
b1474bb7
KG
22
23#ifndef __SPARC_PROTOS_H__
24#define __SPARC_PROTOS_H__
25
26#ifdef TREE_CODE
b1474bb7 27#ifdef RTX_CODE
e80d5f80 28extern void init_cumulative_args (CUMULATIVE_ARGS *, tree, rtx, tree);
b1474bb7 29#endif
e80d5f80 30extern unsigned long sparc_type_code (tree);
b1474bb7
KG
31#endif /* TREE_CODE */
32
e80d5f80 33extern void order_regs_for_local_alloc (void);
9e6a4b77 34extern int sparc_initial_elimination_offset (int);
9ac617d4 35extern void sparc_expand_prologue (void);
b11b0904
EB
36extern void sparc_flat_expand_prologue (void);
37extern void sparc_expand_epilogue (bool);
38extern void sparc_flat_expand_epilogue (bool);
5be9b7a1 39extern bool sparc_can_use_return_insn_p (void);
e80d5f80 40extern int check_pic (int);
e80d5f80
KG
41extern void sparc_profile_hook (int);
42extern void sparc_override_options (void);
e80d5f80 43extern void sparc_output_scratch_registers (FILE *);
8d12174d 44extern void sparc_target_macros (void);
6af11d2b 45extern void sparc_emit_membar_for_model (enum memmodel, int, int);
227efe87 46extern int sparc_branch_cost (bool, bool);
b1474bb7
KG
47
48#ifdef RTX_CODE
ef4bddc2 49extern machine_mode select_cc_mode (enum rtx_code, rtx, rtx);
b1474bb7 50/* Define the function that build the compare insn for scc and bcc. */
f90b7a5a
PB
51extern rtx gen_compare_reg (rtx cmp);
52extern rtx sparc_emit_float_lib_cmp (rtx, rtx, enum rtx_code);
ef4bddc2
RS
53extern void sparc_emit_floatunsdi (rtx [2], machine_mode);
54extern void sparc_emit_fixunsdi (rtx [2], machine_mode);
e80d5f80
KG
55extern void emit_tfmode_binop (enum rtx_code, rtx *);
56extern void emit_tfmode_unop (enum rtx_code, rtx *);
57extern void emit_tfmode_cvt (enum rtx_code, rtx *);
5751a10b
JJ
58extern bool constant_address_p (rtx);
59extern bool legitimate_pic_operand_p (rtx);
ef4bddc2 60extern rtx sparc_legitimize_reload_address (rtx, machine_mode, int, int,
58e6223e 61 int, int *win);
bc6d3f91 62extern void load_got_register (void);
1910440e 63extern void sparc_emit_call_insn (rtx, rtx);
e80d5f80 64extern void sparc_defer_case_vector (rtx, rtx, int);
ef4bddc2 65extern bool sparc_expand_move (machine_mode, rtx *);
e80d5f80 66extern void sparc_emit_set_symbolic_const64 (rtx, rtx, rtx);
dc7342d2
EB
67extern int sparc_split_reg_mem_legitimate (rtx, rtx);
68extern void sparc_split_reg_mem (rtx, rtx, machine_mode);
69extern void sparc_split_mem_reg (rtx, rtx, machine_mode);
70extern int sparc_split_reg_reg_legitimate (rtx, rtx);
71extern void sparc_split_reg_reg (rtx, rtx, machine_mode);
e1faf324
DM
72extern const char *output_ubranch (rtx, rtx_insn *);
73extern const char *output_cbranch (rtx, rtx, int, int, int, rtx_insn *);
74extern const char *output_return (rtx_insn *);
75extern const char *output_sibcall (rtx_insn *, rtx);
76extern const char *output_v8plus_shift (rtx_insn *, rtx *, const char *);
77extern const char *output_v8plus_mult (rtx_insn *, rtx *, const char *);
78extern const char *output_v9branch (rtx, rtx, int, int, int, int, rtx_insn *);
260c8ba3 79extern const char *output_probe_stack_range (rtx, rtx);
e1faf324 80extern const char *output_cbcond (rtx, rtx, rtx_insn *);
f90b7a5a
PB
81extern bool emit_scc_insn (rtx []);
82extern void emit_conditional_branch_insn (rtx []);
b5ccb9ed 83extern int registers_ok_for_ldd_peep (rtx, rtx);
e80d5f80 84extern int mems_ok_for_ldd_peep (rtx, rtx, rtx);
ef4bddc2 85extern rtx widen_mem_for_ldd_peep (rtx, rtx, machine_mode);
b32d5189 86extern int empty_delay_slot (rtx_insn *);
82082f65 87extern int emit_cbcond_nop (rtx_insn *);
84034c69
DM
88extern int eligible_for_call_delay (rtx_insn *);
89extern int eligible_for_return_delay (rtx_insn *);
90extern int eligible_for_sibcall_delay (rtx_insn *);
ef4bddc2 91extern int emit_move_sequence (rtx, machine_mode);
e80d5f80
KG
92extern int fp_sethi_p (rtx);
93extern int fp_mov_p (rtx);
94extern int fp_high_losum_p (rtx);
95extern int mem_min_alignment (rtx, int);
96extern int pic_address_needs_scratch (rtx);
e80d5f80 97extern int register_ok_for_ldd (rtx);
157891a3 98extern int memory_ok_for_ldd (rtx);
e80d5f80 99extern int v9_regcmp_p (enum rtx_code);
b1474bb7
KG
100/* Function used for V8+ code generation. Returns 1 if the high
101 32 bits of REG are 0 before INSN. */
b32d5189 102extern int sparc_check_64 (rtx, rtx_insn *);
e80d5f80 103extern rtx gen_df_reg (rtx, int);
470b6e51 104extern void sparc_expand_compare_and_swap (rtx op[]);
e00560c2 105extern void sparc_expand_vector_init (rtx, rtx);
ef4bddc2
RS
106extern void sparc_expand_vec_perm_bmask(machine_mode, rtx);
107extern bool sparc_expand_conditional_move (machine_mode, rtx *);
108extern void sparc_expand_vcond (machine_mode, rtx *, int, int);
109unsigned int sparc_regmode_natural_size (machine_mode);
b1474bb7
KG
110#endif /* RTX_CODE */
111
6af11d2b 112extern rtl_opt_pass *make_pass_work_around_errata (gcc::context *);
9a738908 113
b1474bb7 114#endif /* __SPARC_PROTOS_H__ */