Commit | Line | Data |
---|---|---|
252b5132 | 1 | /* tc-fr30.h -- Header file for tc-fr30.c. |
b3adc24a | 2 | Copyright (C) 1998-2020 Free Software Foundation, Inc. |
252b5132 RH |
3 | |
4 | This file is part of GAS, the GNU Assembler. | |
5 | ||
6 | GAS is free software; you can redistribute it and/or modify | |
7 | it under the terms of the GNU General Public License as published by | |
ec2655a6 | 8 | the Free Software Foundation; either version 3, or (at your option) |
252b5132 RH |
9 | any later version. |
10 | ||
11 | GAS is distributed in the hope that it will be useful, | |
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 | GNU General Public License for more details. | |
15 | ||
16 | You should have received a copy of the GNU General Public License | |
17 | along with GAS; see the file COPYING. If not, write to | |
4b4da160 NC |
18 | the Free Software Foundation, 51 Franklin Street - Fifth Floor, |
19 | Boston, MA 02110-1301, USA. */ | |
252b5132 RH |
20 | |
21 | #define TC_FR30 | |
22 | ||
252b5132 RH |
23 | #define LISTING_HEADER "FR30 GAS " |
24 | ||
25 | /* The target BFD architecture. */ | |
26 | #define TARGET_ARCH bfd_arch_fr30 | |
27 | ||
28 | #define TARGET_FORMAT "elf32-fr30" | |
29 | ||
30 | #define TARGET_BYTES_BIG_ENDIAN 1 | |
31 | ||
252b5132 RH |
32 | /* Permit temporary numeric labels. */ |
33 | #define LOCAL_LABELS_FB 1 | |
34 | ||
ea1562b3 | 35 | #define DIFF_EXPR_OK /* .-foo gets turned into PC relative relocs. */ |
252b5132 RH |
36 | |
37 | /* We don't need to handle .word strangely. */ | |
38 | #define WORKING_DOT_WORD | |
39 | ||
55cf6793 | 40 | /* Values passed to md_apply_fix don't include the symbol value. */ |
a161fe53 AM |
41 | #define MD_APPLY_SYM_VALUE(FIX) 0 |
42 | ||
55cf6793 | 43 | #define md_apply_fix gas_cgen_md_apply_fix |
252b5132 | 44 | |
a161fe53 AM |
45 | #define tc_fix_adjustable(FIX) fr30_fix_adjustable (FIX) |
46 | struct fix; | |
ea1562b3 | 47 | extern bfd_boolean fr30_fix_adjustable (struct fix *); |
252b5132 | 48 | |
252b5132 RH |
49 | #define tc_gen_reloc gas_cgen_tc_gen_reloc |
50 | ||
51 | /* Call md_pcrel_from_section(), not md_pcrel_from(). */ | |
a161fe53 | 52 | #define MD_PCREL_FROM_SECTION(FIX, SEC) md_pcrel_from_section (FIX, SEC) |
ea1562b3 | 53 | extern long md_pcrel_from_section (struct fix *, segT); |
252b5132 RH |
54 | |
55 | /* For 8 vs 16 vs 32 bit branch selection. */ | |
56 | #define TC_GENERIC_RELAX_TABLE md_relax_table | |
57 | extern const struct relax_type md_relax_table[]; | |
58 | ||
59 | /* We need a special version of the TC_START_LABEL macro so that we | |
60 | allow the LDI:8, LDI:20, LDI:32 and delay slot instructions to be | |
2e57ce7b AM |
61 | parsed as such. We need to be able to change the contents of the |
62 | var storing what was at the NUL delimiter. */ | |
63 | #define TC_START_LABEL(STR, NUL_CHAR, NEXT_CHAR) \ | |
64 | (NEXT_CHAR == ':' && !fr30_is_colon_insn (STR, &NUL_CHAR)) | |
65 | extern int fr30_is_colon_insn (char *, char *); |