sparc-protos.h revision 90075
1/* Prototypes of target machine for GNU compiler, for Sun SPARC. 2 Copyright (C) 1999, 2000 Free Software Foundation, Inc. 3 Contributed by Michael Tiemann (tiemann@cygnus.com). 4 64 bit SPARC V9 support by Michael Tiemann, Jim Wilson, and Doug Evans, 5 at Cygnus Support. 6 7This file is part of GNU CC. 8 9GNU CC is free software; you can redistribute it and/or modify 10it under the terms of the GNU General Public License as published by 11the Free Software Foundation; either version 2, or (at your option) 12any later version. 13 14GNU CC is distributed in the hope that it will be useful, 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 20along with GNU CC; see the file COPYING. If not, write to 21the Free Software Foundation, 59 Temple Place - Suite 330, 22Boston, MA 02111-1307, USA. */ 23 24#ifndef __SPARC_PROTOS_H__ 25#define __SPARC_PROTOS_H__ 26 27#ifdef TREE_CODE 28extern struct rtx_def *function_value PARAMS ((tree, enum machine_mode, int)); 29extern void function_arg_advance PARAMS ((CUMULATIVE_ARGS *, 30 enum machine_mode, tree, int)); 31extern struct rtx_def *function_arg PARAMS ((const CUMULATIVE_ARGS *, 32 enum machine_mode, 33 tree, int, int)); 34extern int function_arg_partial_nregs PARAMS ((const CUMULATIVE_ARGS *, 35 enum machine_mode, 36 tree, int)); 37extern int function_arg_pass_by_reference PARAMS ((const CUMULATIVE_ARGS *, 38 enum machine_mode, 39 tree, int)); 40extern struct rtx_def *sparc_builtin_saveregs PARAMS ((void)); 41#ifdef RTX_CODE 42extern void init_cumulative_args PARAMS ((CUMULATIVE_ARGS *, tree, rtx, int)); 43extern void sparc_va_start PARAMS ((int, tree, rtx)); 44#endif 45extern struct rtx_def *sparc_va_arg PARAMS ((tree, tree)); 46extern unsigned long sparc_type_code PARAMS ((tree)); 47#ifdef ARGS_SIZE_RTX 48/* expr.h defines ARGS_SIZE_RTX and `enum direction' */ 49extern enum direction function_arg_padding PARAMS ((enum machine_mode, tree)); 50#endif /* ARGS_SIZE_RTX */ 51#endif /* TREE_CODE */ 52 53extern void load_pic_register PARAMS ((void)); 54extern void order_regs_for_local_alloc PARAMS ((void)); 55extern int compute_frame_size PARAMS ((int, int)); 56extern int check_pic PARAMS ((int)); 57extern int short_branch PARAMS ((int, int)); 58extern int sparc_flat_epilogue_delay_slots PARAMS ((void)); 59extern unsigned long sparc_flat_compute_frame_size PARAMS ((int)); 60extern void sparc_function_profiler PARAMS ((FILE *, int)); 61extern void sparc_function_block_profiler PARAMS ((FILE *, int)); 62extern void sparc_block_profiler PARAMS ((FILE *, int)); 63extern void sparc_function_block_profiler_exit PARAMS ((FILE *)); 64extern void sparc_override_options PARAMS ((void)); 65extern int leaf_return_peephole_ok PARAMS ((void)); 66extern void sparc_output_scratch_registers PARAMS ((FILE *)); 67extern void sparc_flat_save_restore PARAMS ((FILE *, const char *, 68 unsigned int, unsigned long, 69 unsigned long, const char *, 70 const char *, unsigned long)); 71 72#ifdef RTX_CODE 73extern enum machine_mode select_cc_mode PARAMS ((enum rtx_code, rtx, rtx)); 74/* Define the function that build the compare insn for scc and bcc. */ 75extern rtx gen_compare_reg PARAMS ((enum rtx_code code, rtx, rtx)); 76extern void sparc_emit_float_lib_cmp PARAMS ((rtx, rtx, enum rtx_code)); 77/* This function handles all v9 scc insns */ 78extern int gen_v9_scc PARAMS ((enum rtx_code, rtx *)); 79extern void sparc_initialize_trampoline PARAMS ((rtx, rtx, rtx)); 80extern void sparc64_initialize_trampoline PARAMS ((rtx, rtx, rtx)); 81extern rtx legitimize_pic_address PARAMS ((rtx, enum machine_mode, rtx)); 82extern void sparc_defer_case_vector PARAMS ((rtx, rtx, int)); 83extern void sparc_emit_set_const32 PARAMS ((rtx, rtx)); 84extern void sparc_emit_set_const64 PARAMS ((rtx, rtx)); 85extern void sparc_emit_set_symbolic_const64 PARAMS ((rtx, rtx, rtx)); 86extern int sparc_splitdi_legitimate PARAMS ((rtx, rtx)); 87extern int sparc_absnegfloat_split_legitimate PARAMS ((rtx, rtx)); 88extern char *output_cbranch PARAMS ((rtx, int, int, int, int, rtx)); 89extern const char *output_return PARAMS ((rtx *)); 90extern const char *output_sibcall PARAMS ((rtx, rtx)); 91extern char *output_v9branch PARAMS ((rtx, int, int, int, int, int, rtx)); 92extern void emit_v9_brxx_insn PARAMS ((enum rtx_code, rtx, rtx)); 93extern void print_operand PARAMS ((FILE *, rtx, int)); 94extern int mems_ok_for_ldd_peep PARAMS ((rtx, rtx, rtx)); 95extern int arith_double_4096_operand PARAMS ((rtx, enum machine_mode)); 96extern int arith_4096_operand PARAMS ((rtx, enum machine_mode)); 97extern int zero_operand PARAMS ((rtx, enum machine_mode)); 98extern int fp_zero_operand PARAMS ((rtx, enum machine_mode)); 99extern int reg_or_0_operand PARAMS ((rtx, enum machine_mode)); 100extern int eligible_for_epilogue_delay PARAMS ((rtx, int)); 101extern int eligible_for_return_delay PARAMS ((rtx)); 102extern int eligible_for_sibcall_delay PARAMS ((rtx)); 103extern int emit_move_sequence PARAMS ((rtx, enum machine_mode)); 104extern int fp_sethi_p PARAMS ((rtx)); 105extern int fp_mov_p PARAMS ((rtx)); 106extern int fp_high_losum_p PARAMS ((rtx)); 107extern int mem_min_alignment PARAMS ((rtx, int)); 108extern int pic_address_needs_scratch PARAMS ((rtx)); 109extern int reg_unused_after PARAMS ((rtx, rtx)); 110extern int register_ok_for_ldd PARAMS ((rtx)); 111extern int registers_ok_for_ldd_peep PARAMS ((rtx, rtx)); 112extern int sparc_flat_eligible_for_epilogue_delay PARAMS ((rtx, int)); 113extern int v9_regcmp_p PARAMS ((enum rtx_code)); 114extern char *sparc_v8plus_shift PARAMS ((rtx *, rtx, const char *)); 115/* Function used for V8+ code generation. Returns 1 if the high 116 32 bits of REG are 0 before INSN. */ 117extern int sparc_check_64 PARAMS ((rtx, rtx)); 118extern int sparc_return_peephole_ok PARAMS ((rtx, rtx)); 119extern rtx gen_df_reg PARAMS ((rtx, int)); 120#endif /* RTX_CODE */ 121 122#endif /* __SPARC_PROTOS_H__ */ 123