tc.h revision 78828
1578Srgrimes/* tc.h - target cpu dependent 2578Srgrimes 3578Srgrimes Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 2000 41197Srgrimes Free Software Foundation, Inc. 56604Sache 61197Srgrimes This file is part of GAS, the GNU Assembler. 71197Srgrimes 81197Srgrimes GAS is free software; you can redistribute it and/or modify 91197Srgrimes it under the terms of the GNU General Public License as published by 10578Srgrimes the Free Software Foundation; either version 2, or (at your option) 11578Srgrimes any later version. 12578Srgrimes 13578Srgrimes GAS is distributed in the hope that it will be useful, 14578Srgrimes but WITHOUT ANY WARRANTY; without even the implied warranty of 15578Srgrimes MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16578Srgrimes GNU General Public License for more details. 17578Srgrimes 18578Srgrimes You should have received a copy of the GNU General Public License 19578Srgrimes along with GAS; see the file COPYING. If not, write to 20578Srgrimes the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ 21578Srgrimes 22578Srgrimes/* In theory (mine, at least!) the machine dependent part of the assembler 231197Srgrimes should only have to include one file. This one. -- JF */ 24578Srgrimes 25578Srgrimesextern const pseudo_typeS md_pseudo_table[]; 26578Srgrimes 27578Srgrimes/* JF moved this here from as.h under the theory that nobody except MACHINE.c 28578Srgrimes and write.c care about it anyway. */ 29578Srgrimes 30578Srgrimesstruct relax_type 31578Srgrimes{ 32578Srgrimes /* Forward reach. Signed number. > 0. */ 33578Srgrimes long rlx_forward; 34578Srgrimes /* Backward reach. Signed number. < 0. */ 35578Srgrimes long rlx_backward; 36578Srgrimes 37578Srgrimes /* Bytes length of this address. */ 38578Srgrimes unsigned char rlx_length; 39578Srgrimes 40578Srgrimes /* Next longer relax-state. 0 means there is no 'next' relax-state. */ 41578Srgrimes relax_substateT rlx_more; 42578Srgrimes}; 4311872Sphk 44578Srgrimestypedef struct relax_type relax_typeS; 45578Srgrimes 46578Srgrimesextern const int md_reloc_size; /* Size of a relocation record */ 47578Srgrimes 48578Srgrimeschar *md_atof PARAMS ((int what_statement_type, char *literalP, int *sizeP)); 492056Swollman#ifndef md_estimate_size_before_relax 502056Swollmanint md_estimate_size_before_relax PARAMS ((fragS * fragP, segT segment)); 512056Swollman#endif 522056Swollmanint md_parse_option PARAMS ((int c, char *arg)); 532056Swollmanvoid md_show_usage PARAMS ((FILE *)); 542056Swollmanlong md_pcrel_from PARAMS ((fixS * fixP)); 557430Sbdeshort tc_coff_fix2rtype PARAMS ((fixS * fixP)); 562056Swollmanvoid md_assemble PARAMS ((char *str)); 572056Swollmanvoid md_begin PARAMS ((void)); 582056Swollman#ifndef md_create_long_jump 592056Swollmanvoid md_create_long_jump PARAMS ((char *ptr, addressT from_addr, 602056Swollman addressT to_addr, fragS * frag, 612056Swollman symbolS * to_symbol)); 622056Swollman#endif 633816Swollman#ifndef md_create_short_jump 643816Swollmanvoid md_create_short_jump PARAMS ((char *ptr, addressT from_addr, 657430Sbde addressT to_addr, fragS * frag, 667430Sbde symbolS * to_symbol)); 677430Sbde#endif 687430Sbdevoid md_number_to_chars PARAMS ((char *buf, valueT val, int n)); 692056Swollman 702056Swollman#ifndef md_operand 712056Swollmanvoid md_operand PARAMS ((expressionS * expressionP)); 72578Srgrimes#endif 738375Srgrimes 748375Srgrimes#ifdef MD_APPLY_FIX3 758375Srgrimesint md_apply_fix3 PARAMS ((fixS * fixP, valueT *val, segT seg)); 768375Srgrimes#endif 778375Srgrimes#ifdef BFD_ASSEMBLER 788375Srgrimesint md_apply_fix PARAMS ((fixS * fixP, valueT *val)); 798375Srgrimes#ifndef md_convert_frag 808375Srgrimesvoid md_convert_frag PARAMS ((bfd * headers, segT sec, fragS * fragP)); 81578Srgrimes#endif 82578Srgrimes#ifndef tc_headers_hook 83578Srgrimesvoid tc_headers_hook PARAMS ((segT *, fixS *)); 84578Srgrimes#endif 852395Sache#ifndef RELOC_EXPANSION_POSSIBLE 86578Srgrimesextern arelent *tc_gen_reloc PARAMS ((asection *, fixS *)); 87578Srgrimes#else 88578Srgrimesextern arelent **tc_gen_reloc PARAMS ((asection *, fixS *)); 89578Srgrimes#endif 90578Srgrimes#else /* not BFD_ASSEMBLER */ 912477Sachevoid md_apply_fix PARAMS ((fixS * fixP, long val)); 92578Srgrimes#ifndef md_convert_frag 93578Srgrimesvoid md_convert_frag PARAMS ((object_headers * headers, segT, fragS * fragP)); 94578Srgrimes#endif 95578Srgrimes 96578Srgrimes#ifndef tc_crawl_symbol_chain 97578Srgrimesvoid tc_crawl_symbol_chain PARAMS ((object_headers * headers)); 98578Srgrimes#endif /* tc_crawl_symbol_chain */ 99578Srgrimes 100578Srgrimes#ifndef tc_headers_hook 101578Srgrimesvoid tc_headers_hook PARAMS ((object_headers * headers)); 102578Srgrimes#endif /* tc_headers_hook */ 103578Srgrimes#endif /* BFD_ASSEMBLER */ 104578Srgrimes 1051241Sjkh#ifndef md_section_align 1061241SjkhvalueT md_section_align PARAMS ((segT seg, valueT size)); 1071241Sjkh#endif 1081241Sjkh 1091241Sjkh#ifndef md_undefined_symbol 1101237SjkhsymbolS *md_undefined_symbol PARAMS ((char *name)); 1112477Sache#endif 1122477Sache 113578Srgrimes/* end of tc.h */ 114578Srgrimes