[brcm-2.4] remove asterisk from default vlan ports in netconfig
[openwrt.git] / toolchain / binutils / patches / 2.18 / 500-avr32.patch
1 --- a/bfd/archures.c
2 +++ b/bfd/archures.c
3 @@ -346,6 +346,11 @@ DESCRIPTION
4 .#define bfd_mach_avr4 4
5 .#define bfd_mach_avr5 5
6 .#define bfd_mach_avr6 6
7 +. bfd_arch_avr32, {* Atmel AVR32 *}
8 +.#define bfd_mach_avr32_ap 7000
9 +.#define bfd_mach_avr32_uc 3000
10 +.#define bfd_mach_avr32_ucr1 3001
11 +.#define bfd_mach_avr32_ucr2 3002
12 . bfd_arch_bfin, {* ADI Blackfin *}
13 .#define bfd_mach_bfin 1
14 . bfd_arch_cr16, {* National Semiconductor CompactRISC (ie CR16). *}
15 @@ -438,6 +443,7 @@ extern const bfd_arch_info_type bfd_alph
16 extern const bfd_arch_info_type bfd_arc_arch;
17 extern const bfd_arch_info_type bfd_arm_arch;
18 extern const bfd_arch_info_type bfd_avr_arch;
19 +extern const bfd_arch_info_type bfd_avr32_arch;
20 extern const bfd_arch_info_type bfd_bfin_arch;
21 extern const bfd_arch_info_type bfd_cr16_arch;
22 extern const bfd_arch_info_type bfd_cr16c_arch;
23 @@ -509,6 +515,7 @@ static const bfd_arch_info_type * const
24 &bfd_arc_arch,
25 &bfd_arm_arch,
26 &bfd_avr_arch,
27 + &bfd_avr32_arch,
28 &bfd_bfin_arch,
29 &bfd_cr16_arch,
30 &bfd_cr16c_arch,
31 --- a/bfd/config.bfd
32 +++ b/bfd/config.bfd
33 @@ -335,6 +335,10 @@ case "${targ}" in
34 targ_underscore=yes
35 ;;
36
37 + avr32-*-*)
38 + targ_defvec=bfd_elf32_avr32_vec
39 + ;;
40 +
41 c30-*-*aout* | tic30-*-*aout*)
42 targ_defvec=tic30_aout_vec
43 ;;
44 --- a/bfd/configure.in
45 +++ b/bfd/configure.in
46 @@ -619,6 +619,7 @@ do
47 bfd_efi_app_ia64_vec) tb="$tb efi-app-ia64.lo pepigen.lo cofflink.lo"; target_size=64 ;;
48 bfd_elf32_am33lin_vec) tb="$tb elf32-am33lin.lo elf32.lo $elf" ;;
49 bfd_elf32_avr_vec) tb="$tb elf32-avr.lo elf32.lo $elf" ;;
50 + bfd_elf32_avr32_vec) tb="$tb elf32-avr32.lo elf32.lo $elf" ;;
51 bfd_elf32_bfin_vec) tb="$tb elf32-bfin.lo elf32.lo $elf" ;;
52 bfd_elf32_bfinfdpic_vec) tb="$tb elf32-bfin.lo elf32.lo $elf" ;;
53 bfd_elf32_big_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
54 --- /dev/null
55 +++ b/bfd/cpu-avr32.c
56 @@ -0,0 +1,51 @@
57 +/* BFD library support routines for AVR32.
58 + Copyright 2003-2006 Atmel Corporation.
59 +
60 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
61 +
62 + This is part of BFD, the Binary File Descriptor library.
63 +
64 + This program is free software; you can redistribute it and/or modify
65 + it under the terms of the GNU General Public License as published by
66 + the Free Software Foundation; either version 2 of the License, or
67 + (at your option) any later version.
68 +
69 + This program is distributed in the hope that it will be useful,
70 + but WITHOUT ANY WARRANTY; without even the implied warranty of
71 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
72 + GNU General Public License for more details.
73 +
74 + You should have received a copy of the GNU General Public License
75 + along with this program; if not, write to the Free Software
76 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
77 +
78 +#include "bfd.h"
79 +#include "sysdep.h"
80 +#include "libbfd.h"
81 +
82 +#define N(machine, print, default, next) \
83 + { \
84 + 32, /* 32 bits in a word */ \
85 + 32, /* 32 bits in an address */ \
86 + 8, /* 8 bits in a byte */ \
87 + bfd_arch_avr32, /* architecture */ \
88 + machine, /* machine */ \
89 + "avr32", /* arch name */ \
90 + print, /* printable name */ \
91 + 1, /* section align power */ \
92 + default, /* the default machine? */ \
93 + bfd_default_compatible, \
94 + bfd_default_scan, \
95 + next, \
96 + }
97 +
98 +static const bfd_arch_info_type cpu_info[] =
99 +{
100 + N(bfd_mach_avr32_ap, "avr32:ap", FALSE, &cpu_info[1]),
101 + N(bfd_mach_avr32_uc, "avr32:uc", FALSE, &cpu_info[2]),
102 + N(bfd_mach_avr32_ucr1, "avr32:ucr1", FALSE, &cpu_info[3]),
103 + N(bfd_mach_avr32_ucr2, "avr32:ucr2", FALSE, NULL),
104 +};
105 +
106 +const bfd_arch_info_type bfd_avr32_arch =
107 + N(bfd_mach_avr32_ap, "avr32", TRUE, &cpu_info[0]);
108 --- /dev/null
109 +++ b/bfd/elf32-avr32.c
110 @@ -0,0 +1,3915 @@
111 +/* AVR32-specific support for 32-bit ELF.
112 + Copyright 2003-2006 Atmel Corporation.
113 +
114 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
115 +
116 + This file is part of BFD, the Binary File Descriptor library.
117 +
118 + This program is free software; you can redistribute it and/or modify
119 + it under the terms of the GNU General Public License as published by
120 + the Free Software Foundation; either version 2 of the License, or
121 + (at your option) any later version.
122 +
123 + This program is distributed in the hope that it will be useful,
124 + but WITHOUT ANY WARRANTY; without even the implied warranty of
125 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
126 + GNU General Public License for more details.
127 +
128 + You should have received a copy of the GNU General Public License
129 + along with this program; if not, write to the Free Software
130 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
131 +
132 +#include "bfd.h"
133 +#include "sysdep.h"
134 +#include "bfdlink.h"
135 +#include "libbfd.h"
136 +#include "elf-bfd.h"
137 +#include "elf/avr32.h"
138 +#include "elf32-avr32.h"
139 +
140 +#define xDEBUG
141 +#define xRELAX_DEBUG
142 +
143 +#ifdef DEBUG
144 +# define pr_debug(fmt, args...) fprintf(stderr, fmt, ##args)
145 +#else
146 +# define pr_debug(fmt, args...) do { } while (0)
147 +#endif
148 +
149 +#ifdef RELAX_DEBUG
150 +# define RDBG(fmt, args...) fprintf(stderr, fmt, ##args)
151 +#else
152 +# define RDBG(fmt, args...) do { } while (0)
153 +#endif
154 +
155 +/* When things go wrong, we want it to blow up, damnit! */
156 +#undef BFD_ASSERT
157 +#undef abort
158 +#define BFD_ASSERT(expr) \
159 + do \
160 + { \
161 + if (!(expr)) \
162 + { \
163 + bfd_assert(__FILE__, __LINE__); \
164 + abort(); \
165 + } \
166 + } \
167 + while (0)
168 +
169 +/* The name of the dynamic interpreter. This is put in the .interp section. */
170 +#define ELF_DYNAMIC_INTERPRETER "/lib/ld.so.1"
171 +
172 +#define AVR32_GOT_HEADER_SIZE 8
173 +#define AVR32_FUNCTION_STUB_SIZE 8
174 +
175 +#define ELF_R_INFO(x, y) ELF32_R_INFO(x, y)
176 +#define ELF_R_TYPE(x) ELF32_R_TYPE(x)
177 +#define ELF_R_SYM(x) ELF32_R_SYM(x)
178 +
179 +#define NOP_OPCODE 0xd703
180 +
181 +
182 +/* Mapping between BFD relocations and ELF relocations */
183 +
184 +static reloc_howto_type *
185 +bfd_elf32_bfd_reloc_type_lookup(bfd *abfd, bfd_reloc_code_real_type code);
186 +
187 +static reloc_howto_type *
188 +bfd_elf32_bfd_reloc_name_lookup(bfd *abfd, const char *r_name);
189 +
190 +static void
191 +avr32_info_to_howto (bfd *abfd, arelent *cache_ptr, Elf_Internal_Rela *dst);
192 +
193 +/* Generic HOWTO */
194 +#define GENH(name, align, size, bitsize, pcrel, bitpos, complain, mask) \
195 + HOWTO(name, align, size, bitsize, pcrel, bitpos, \
196 + complain_overflow_##complain, bfd_elf_generic_reloc, #name, \
197 + FALSE, 0, mask, pcrel)
198 +
199 +static reloc_howto_type elf_avr32_howto_table[] = {
200 + /* NAME ALN SZ BSZ PCREL BP COMPLAIN MASK */
201 + GENH(R_AVR32_NONE, 0, 0, 0, FALSE, 0, dont, 0x00000000),
202 +
203 + GENH(R_AVR32_32, 0, 2, 32, FALSE, 0, dont, 0xffffffff),
204 + GENH(R_AVR32_16, 0, 1, 16, FALSE, 0, bitfield, 0x0000ffff),
205 + GENH(R_AVR32_8, 0, 0, 8, FALSE, 0, bitfield, 0x000000ff),
206 + GENH(R_AVR32_32_PCREL, 0, 2, 32, TRUE, 0, signed, 0xffffffff),
207 + GENH(R_AVR32_16_PCREL, 0, 1, 16, TRUE, 0, signed, 0x0000ffff),
208 + GENH(R_AVR32_8_PCREL, 0, 0, 8, TRUE, 0, signed, 0x000000ff),
209 +
210 + /* Difference between two symbol (sym2 - sym1). The reloc encodes
211 + the value of sym1. The field contains the difference before any
212 + relaxing is done. */
213 + GENH(R_AVR32_DIFF32, 0, 2, 32, FALSE, 0, dont, 0xffffffff),
214 + GENH(R_AVR32_DIFF16, 0, 1, 16, FALSE, 0, signed, 0x0000ffff),
215 + GENH(R_AVR32_DIFF8, 0, 0, 8, FALSE, 0, signed, 0x000000ff),
216 +
217 + GENH(R_AVR32_GOT32, 0, 2, 32, FALSE, 0, signed, 0xffffffff),
218 + GENH(R_AVR32_GOT16, 0, 1, 16, FALSE, 0, signed, 0x0000ffff),
219 + GENH(R_AVR32_GOT8, 0, 0, 8, FALSE, 0, signed, 0x000000ff),
220 +
221 + GENH(R_AVR32_21S, 0, 2, 21, FALSE, 0, signed, 0x1e10ffff),
222 + GENH(R_AVR32_16U, 0, 2, 16, FALSE, 0, unsigned, 0x0000ffff),
223 + GENH(R_AVR32_16S, 0, 2, 16, FALSE, 0, signed, 0x0000ffff),
224 + GENH(R_AVR32_8S, 0, 1, 8, FALSE, 4, signed, 0x00000ff0),
225 + GENH(R_AVR32_8S_EXT, 0, 2, 8, FALSE, 0, signed, 0x000000ff),
226 +
227 + GENH(R_AVR32_22H_PCREL, 1, 2, 21, TRUE, 0, signed, 0x1e10ffff),
228 + GENH(R_AVR32_18W_PCREL, 2, 2, 16, TRUE, 0, signed, 0x0000ffff),
229 + GENH(R_AVR32_16B_PCREL, 0, 2, 16, TRUE, 0, signed, 0x0000ffff),
230 + GENH(R_AVR32_16N_PCREL, 0, 2, 16, TRUE, 0, signed, 0x0000ffff),
231 + GENH(R_AVR32_14UW_PCREL, 2, 2, 12, TRUE, 0, unsigned, 0x0000f0ff),
232 + GENH(R_AVR32_11H_PCREL, 1, 1, 10, TRUE, 4, signed, 0x00000ff3),
233 + GENH(R_AVR32_10UW_PCREL, 2, 2, 8, TRUE, 0, unsigned, 0x000000ff),
234 + GENH(R_AVR32_9H_PCREL, 1, 1, 8, TRUE, 4, signed, 0x00000ff0),
235 + GENH(R_AVR32_9UW_PCREL, 2, 1, 7, TRUE, 4, unsigned, 0x000007f0),
236 +
237 + GENH(R_AVR32_HI16, 16, 2, 16, FALSE, 0, dont, 0x0000ffff),
238 + GENH(R_AVR32_LO16, 0, 2, 16, FALSE, 0, dont, 0x0000ffff),
239 +
240 + GENH(R_AVR32_GOTPC, 0, 2, 32, FALSE, 0, dont, 0xffffffff),
241 + GENH(R_AVR32_GOTCALL, 2, 2, 21, FALSE, 0, signed, 0x1e10ffff),
242 + GENH(R_AVR32_LDA_GOT, 2, 2, 21, FALSE, 0, signed, 0x1e10ffff),
243 + GENH(R_AVR32_GOT21S, 0, 2, 21, FALSE, 0, signed, 0x1e10ffff),
244 + GENH(R_AVR32_GOT18SW, 2, 2, 16, FALSE, 0, signed, 0x0000ffff),
245 + GENH(R_AVR32_GOT16S, 0, 2, 16, FALSE, 0, signed, 0x0000ffff),
246 + GENH(R_AVR32_GOT7UW, 2, 1, 5, FALSE, 4, unsigned, 0x000001f0),
247 +
248 + GENH(R_AVR32_32_CPENT, 0, 2, 32, FALSE, 0, dont, 0xffffffff),
249 + GENH(R_AVR32_CPCALL, 2, 2, 16, TRUE, 0, signed, 0x0000ffff),
250 + GENH(R_AVR32_16_CP, 0, 2, 16, TRUE, 0, signed, 0x0000ffff),
251 + GENH(R_AVR32_9W_CP, 2, 1, 7, TRUE, 4, unsigned, 0x000007f0),
252 +
253 + GENH(R_AVR32_RELATIVE, 0, 2, 32, FALSE, 0, signed, 0xffffffff),
254 + GENH(R_AVR32_GLOB_DAT, 0, 2, 32, FALSE, 0, dont, 0xffffffff),
255 + GENH(R_AVR32_JMP_SLOT, 0, 2, 32, FALSE, 0, dont, 0xffffffff),
256 +
257 + GENH(R_AVR32_ALIGN, 0, 1, 0, FALSE, 0, unsigned, 0x00000000),
258 +
259 + GENH(R_AVR32_15S, 2, 2, 15, FALSE, 0, signed, 0x00007fff),
260 +};
261 +
262 +struct elf_reloc_map
263 +{
264 + bfd_reloc_code_real_type bfd_reloc_val;
265 + unsigned char elf_reloc_val;
266 +};
267 +
268 +static const struct elf_reloc_map avr32_reloc_map[] =
269 +{
270 + { BFD_RELOC_NONE, R_AVR32_NONE },
271 +
272 + { BFD_RELOC_32, R_AVR32_32 },
273 + { BFD_RELOC_16, R_AVR32_16 },
274 + { BFD_RELOC_8, R_AVR32_8 },
275 + { BFD_RELOC_32_PCREL, R_AVR32_32_PCREL },
276 + { BFD_RELOC_16_PCREL, R_AVR32_16_PCREL },
277 + { BFD_RELOC_8_PCREL, R_AVR32_8_PCREL },
278 + { BFD_RELOC_AVR32_DIFF32, R_AVR32_DIFF32 },
279 + { BFD_RELOC_AVR32_DIFF16, R_AVR32_DIFF16 },
280 + { BFD_RELOC_AVR32_DIFF8, R_AVR32_DIFF8 },
281 + { BFD_RELOC_AVR32_GOT32, R_AVR32_GOT32 },
282 + { BFD_RELOC_AVR32_GOT16, R_AVR32_GOT16 },
283 + { BFD_RELOC_AVR32_GOT8, R_AVR32_GOT8 },
284 +
285 + { BFD_RELOC_AVR32_21S, R_AVR32_21S },
286 + { BFD_RELOC_AVR32_16U, R_AVR32_16U },
287 + { BFD_RELOC_AVR32_16S, R_AVR32_16S },
288 + { BFD_RELOC_AVR32_SUB5, R_AVR32_16S },
289 + { BFD_RELOC_AVR32_8S_EXT, R_AVR32_8S_EXT },
290 + { BFD_RELOC_AVR32_8S, R_AVR32_8S },
291 +
292 + { BFD_RELOC_AVR32_22H_PCREL, R_AVR32_22H_PCREL },
293 + { BFD_RELOC_AVR32_18W_PCREL, R_AVR32_18W_PCREL },
294 + { BFD_RELOC_AVR32_16B_PCREL, R_AVR32_16B_PCREL },
295 + { BFD_RELOC_AVR32_16N_PCREL, R_AVR32_16N_PCREL },
296 + { BFD_RELOC_AVR32_11H_PCREL, R_AVR32_11H_PCREL },
297 + { BFD_RELOC_AVR32_10UW_PCREL, R_AVR32_10UW_PCREL },
298 + { BFD_RELOC_AVR32_9H_PCREL, R_AVR32_9H_PCREL },
299 + { BFD_RELOC_AVR32_9UW_PCREL, R_AVR32_9UW_PCREL },
300 +
301 + { BFD_RELOC_HI16, R_AVR32_HI16 },
302 + { BFD_RELOC_LO16, R_AVR32_LO16 },
303 +
304 + { BFD_RELOC_AVR32_GOTPC, R_AVR32_GOTPC },
305 + { BFD_RELOC_AVR32_GOTCALL, R_AVR32_GOTCALL },
306 + { BFD_RELOC_AVR32_LDA_GOT, R_AVR32_LDA_GOT },
307 + { BFD_RELOC_AVR32_GOT21S, R_AVR32_GOT21S },
308 + { BFD_RELOC_AVR32_GOT18SW, R_AVR32_GOT18SW },
309 + { BFD_RELOC_AVR32_GOT16S, R_AVR32_GOT16S },
310 + /* GOT7UW should never be generated by the assembler */
311 +
312 + { BFD_RELOC_AVR32_32_CPENT, R_AVR32_32_CPENT },
313 + { BFD_RELOC_AVR32_CPCALL, R_AVR32_CPCALL },
314 + { BFD_RELOC_AVR32_16_CP, R_AVR32_16_CP },
315 + { BFD_RELOC_AVR32_9W_CP, R_AVR32_9W_CP },
316 +
317 + { BFD_RELOC_AVR32_ALIGN, R_AVR32_ALIGN },
318 +
319 + { BFD_RELOC_AVR32_15S, R_AVR32_15S },
320 +};
321 +
322 +static reloc_howto_type *
323 +bfd_elf32_bfd_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
324 + bfd_reloc_code_real_type code)
325 +{
326 + unsigned int i;
327 +
328 + for (i = 0; i < sizeof(avr32_reloc_map) / sizeof(struct elf_reloc_map); i++)
329 + {
330 + if (avr32_reloc_map[i].bfd_reloc_val == code)
331 + return &elf_avr32_howto_table[avr32_reloc_map[i].elf_reloc_val];
332 + }
333 +
334 + return NULL;
335 +}
336 +
337 +static reloc_howto_type *
338 +bfd_elf32_bfd_reloc_name_lookup (bfd *abfd ATTRIBUTE_UNUSED,
339 + const char *r_name)
340 +{
341 + unsigned int i;
342 +
343 + for (i = 0;
344 + i < sizeof (elf_avr32_howto_table) / sizeof (elf_avr32_howto_table[0]);
345 + i++)
346 + if (elf_avr32_howto_table[i].name != NULL
347 + && strcasecmp (elf_avr32_howto_table[i].name, r_name) == 0)
348 + return &elf_avr32_howto_table[i];
349 +
350 + return NULL;
351 +}
352 +
353 +/* Set the howto pointer for an AVR32 ELF reloc. */
354 +static void
355 +avr32_info_to_howto (bfd *abfd ATTRIBUTE_UNUSED,
356 + arelent *cache_ptr,
357 + Elf_Internal_Rela *dst)
358 +{
359 + unsigned int r_type;
360 +
361 + r_type = ELF32_R_TYPE (dst->r_info);
362 + BFD_ASSERT (r_type < (unsigned int) R_AVR32_max);
363 + cache_ptr->howto = &elf_avr32_howto_table[r_type];
364 +}
365 +
366 +
367 +/* AVR32 ELF linker hash table and associated hash entries. */
368 +
369 +static struct bfd_hash_entry *
370 +avr32_elf_link_hash_newfunc(struct bfd_hash_entry *entry,
371 + struct bfd_hash_table *table,
372 + const char *string);
373 +static void
374 +avr32_elf_copy_indirect_symbol(struct bfd_link_info *info,
375 + struct elf_link_hash_entry *dir,
376 + struct elf_link_hash_entry *ind);
377 +static struct bfd_link_hash_table *
378 +avr32_elf_link_hash_table_create(bfd *abfd);
379 +
380 +/*
381 + Try to limit memory usage to something reasonable when sorting the
382 + GOT. If just a couple of entries end up getting more references
383 + than this, it won't affect performance at all, but if there are many
384 + of them, we could end up with the wrong symbols being assigned the
385 + first GOT entries.
386 +*/
387 +#define MAX_NR_GOT_HOLES 2048
388 +
389 +/*
390 + AVR32 GOT entry. We need to keep track of refcounts and offsets
391 + simultaneously, since we need the offsets during relaxation, and we
392 + also want to be able to drop GOT entries during relaxation. In
393 + addition to this, we want to keep the list of GOT entries sorted so
394 + that we can keep the most-used entries at the lowest offsets.
395 +*/
396 +struct got_entry
397 +{
398 + struct got_entry *next;
399 + struct got_entry **pprev;
400 + int refcount;
401 + bfd_signed_vma offset;
402 +};
403 +
404 +struct elf_avr32_link_hash_entry
405 +{
406 + struct elf_link_hash_entry root;
407 +
408 + /* Number of runtime relocations against this symbol. */
409 + unsigned int possibly_dynamic_relocs;
410 +
411 + /* If there are anything but R_AVR32_GOT18 relocations against this
412 + symbol, it means that someone may be taking the address of the
413 + function, and we should therefore not create a stub. */
414 + bfd_boolean no_fn_stub;
415 +
416 + /* If there is a R_AVR32_32 relocation in a read-only section
417 + against this symbol, we could be in trouble. If we're linking a
418 + shared library or this symbol is defined in one, it means we must
419 + emit a run-time reloc for it and that's not allowed in read-only
420 + sections. */
421 + asection *readonly_reloc_sec;
422 + bfd_vma readonly_reloc_offset;
423 +
424 + /* Record which frag (if any) contains the symbol. This is used
425 + during relaxation in order to avoid having to update all symbols
426 + whenever we move something. For local symbols, this information
427 + is in the local_sym_frag member of struct elf_obj_tdata. */
428 + struct fragment *sym_frag;
429 +};
430 +#define avr32_elf_hash_entry(ent) ((struct elf_avr32_link_hash_entry *)(ent))
431 +
432 +struct elf_avr32_link_hash_table
433 +{
434 + struct elf_link_hash_table root;
435 +
436 + /* Shortcuts to get to dynamic linker sections. */
437 + asection *sgot;
438 + asection *srelgot;
439 + asection *sstub;
440 +
441 + /* We use a variation of Pigeonhole Sort to sort the GOT. After the
442 + initial refcounts have been determined, we initialize
443 + nr_got_holes to the highest refcount ever seen and allocate an
444 + array of nr_got_holes entries for got_hole. Each GOT entry is
445 + then stored in this array at the index given by its refcount.
446 +
447 + When a GOT entry has its refcount decremented during relaxation,
448 + it is moved to a lower index in the got_hole array.
449 + */
450 + struct got_entry **got_hole;
451 + int nr_got_holes;
452 +
453 + /* Dynamic relocations to local symbols. Only used when linking a
454 + shared library and -Bsymbolic is not given. */
455 + unsigned int local_dynamic_relocs;
456 +
457 + bfd_boolean relocations_analyzed;
458 + bfd_boolean symbols_adjusted;
459 + bfd_boolean repeat_pass;
460 + bfd_boolean direct_data_refs;
461 + unsigned int relax_iteration;
462 + unsigned int relax_pass;
463 +};
464 +#define avr32_elf_hash_table(p) \
465 + ((struct elf_avr32_link_hash_table *)((p)->hash))
466 +
467 +static struct bfd_hash_entry *
468 +avr32_elf_link_hash_newfunc(struct bfd_hash_entry *entry,
469 + struct bfd_hash_table *table,
470 + const char *string)
471 +{
472 + struct elf_avr32_link_hash_entry *ret = avr32_elf_hash_entry(entry);
473 +
474 + /* Allocate the structure if it hasn't already been allocated by a
475 + subclass */
476 + if (ret == NULL)
477 + ret = (struct elf_avr32_link_hash_entry *)
478 + bfd_hash_allocate(table, sizeof(struct elf_avr32_link_hash_entry));
479 +
480 + if (ret == NULL)
481 + return NULL;
482 +
483 + memset(ret, 0, sizeof(struct elf_avr32_link_hash_entry));
484 +
485 + /* Give the superclass a chance */
486 + ret = (struct elf_avr32_link_hash_entry *)
487 + _bfd_elf_link_hash_newfunc((struct bfd_hash_entry *)ret, table, string);
488 +
489 + return (struct bfd_hash_entry *)ret;
490 +}
491 +
492 +/* Copy data from an indirect symbol to its direct symbol, hiding the
493 + old indirect symbol. Process additional relocation information.
494 + Also called for weakdefs, in which case we just let
495 + _bfd_elf_link_hash_copy_indirect copy the flags for us. */
496 +
497 +static void
498 +avr32_elf_copy_indirect_symbol(struct bfd_link_info *info,
499 + struct elf_link_hash_entry *dir,
500 + struct elf_link_hash_entry *ind)
501 +{
502 + struct elf_avr32_link_hash_entry *edir, *eind;
503 +
504 + _bfd_elf_link_hash_copy_indirect (info, dir, ind);
505 +
506 + if (ind->root.type != bfd_link_hash_indirect)
507 + return;
508 +
509 + edir = (struct elf_avr32_link_hash_entry *)dir;
510 + eind = (struct elf_avr32_link_hash_entry *)ind;
511 +
512 + edir->possibly_dynamic_relocs += eind->possibly_dynamic_relocs;
513 + edir->no_fn_stub = edir->no_fn_stub || eind->no_fn_stub;
514 +}
515 +
516 +static struct bfd_link_hash_table *
517 +avr32_elf_link_hash_table_create(bfd *abfd)
518 +{
519 + struct elf_avr32_link_hash_table *ret;
520 +
521 + ret = bfd_zmalloc(sizeof(*ret));
522 + if (ret == NULL)
523 + return NULL;
524 +
525 + if (! _bfd_elf_link_hash_table_init(&ret->root, abfd,
526 + avr32_elf_link_hash_newfunc,
527 + sizeof (struct elf_avr32_link_hash_entry)))
528 + {
529 + free(ret);
530 + return NULL;
531 + }
532 +
533 + /* Prevent the BFD core from creating bogus got_entry pointers */
534 + ret->root.init_got_refcount.glist = NULL;
535 + ret->root.init_plt_refcount.glist = NULL;
536 + ret->root.init_got_offset.glist = NULL;
537 + ret->root.init_plt_offset.glist = NULL;
538 +
539 + return &ret->root.root;
540 +}
541 +
542 +
543 +/* Initial analysis and creation of dynamic sections and symbols */
544 +
545 +static asection *
546 +create_dynamic_section(bfd *dynobj, const char *name, flagword flags,
547 + unsigned int align_power);
548 +static struct elf_link_hash_entry *
549 +create_dynamic_symbol(bfd *dynobj, struct bfd_link_info *info,
550 + const char *name, asection *sec,
551 + bfd_vma offset);
552 +static bfd_boolean
553 +avr32_elf_create_got_section (bfd *dynobj, struct bfd_link_info *info);
554 +static bfd_boolean
555 +avr32_elf_create_dynamic_sections (bfd *dynobj, struct bfd_link_info *info);
556 +static bfd_boolean
557 +avr32_check_relocs (bfd *abfd, struct bfd_link_info *info, asection *sec,
558 + const Elf_Internal_Rela *relocs);
559 +static bfd_boolean
560 +avr32_elf_adjust_dynamic_symbol(struct bfd_link_info *info,
561 + struct elf_link_hash_entry *h);
562 +
563 +static asection *
564 +create_dynamic_section(bfd *dynobj, const char *name, flagword flags,
565 + unsigned int align_power)
566 +{
567 + asection *sec;
568 +
569 + sec = bfd_make_section(dynobj, name);
570 + if (!sec
571 + || !bfd_set_section_flags(dynobj, sec, flags)
572 + || !bfd_set_section_alignment(dynobj, sec, align_power))
573 + return NULL;
574 +
575 + return sec;
576 +}
577 +
578 +static struct elf_link_hash_entry *
579 +create_dynamic_symbol(bfd *dynobj, struct bfd_link_info *info,
580 + const char *name, asection *sec,
581 + bfd_vma offset)
582 +{
583 + struct bfd_link_hash_entry *bh = NULL;
584 + struct elf_link_hash_entry *h;
585 + const struct elf_backend_data *bed = get_elf_backend_data (dynobj);
586 +
587 + if (!(_bfd_generic_link_add_one_symbol
588 + (info, dynobj, name, BSF_GLOBAL, sec, offset, NULL, FALSE,
589 + bed->collect, &bh)))
590 + return NULL;
591 +
592 + h = (struct elf_link_hash_entry *)bh;
593 + h->def_regular = 1;
594 + h->type = STT_OBJECT;
595 + h->other = STV_HIDDEN;
596 +
597 + return h;
598 +}
599 +
600 +static bfd_boolean
601 +avr32_elf_create_got_section (bfd *dynobj, struct bfd_link_info *info)
602 +{
603 + struct elf_avr32_link_hash_table *htab;
604 + flagword flags;
605 + const struct elf_backend_data *bed = get_elf_backend_data (dynobj);
606 +
607 + htab = avr32_elf_hash_table(info);
608 + flags = bed->dynamic_sec_flags;
609 +
610 + if (htab->sgot)
611 + return TRUE;
612 +
613 + htab->sgot = create_dynamic_section(dynobj, ".got", flags, 2);
614 + if (!htab->srelgot)
615 + htab->srelgot = create_dynamic_section(dynobj, ".rela.got",
616 + flags | SEC_READONLY, 2);
617 +
618 + if (!htab->sgot || !htab->srelgot)
619 + return FALSE;
620 +
621 + htab->root.hgot = create_dynamic_symbol(dynobj, info, "_GLOBAL_OFFSET_TABLE_",
622 + htab->sgot, 0);
623 + if (!htab->root.hgot)
624 + return FALSE;
625 +
626 + /* Make room for the GOT header */
627 + htab->sgot->size += bed->got_header_size;
628 +
629 + return TRUE;
630 +}
631 +
632 +/* (1) Create all dynamic (i.e. linker generated) sections that we may
633 + need during the link */
634 +
635 +static bfd_boolean
636 +avr32_elf_create_dynamic_sections (bfd *dynobj, struct bfd_link_info *info)
637 +{
638 + struct elf_avr32_link_hash_table *htab;
639 + flagword flags;
640 + const struct elf_backend_data *bed = get_elf_backend_data (dynobj);
641 +
642 + pr_debug("(1) create dynamic sections\n");
643 +
644 + htab = avr32_elf_hash_table(info);
645 + flags = bed->dynamic_sec_flags;
646 +
647 + if (!avr32_elf_create_got_section (dynobj, info))
648 + return FALSE;
649 +
650 + if (!htab->sstub)
651 + htab->sstub = create_dynamic_section(dynobj, ".stub",
652 + flags | SEC_READONLY | SEC_CODE, 2);
653 +
654 + if (!htab->sstub)
655 + return FALSE;
656 +
657 + return TRUE;
658 +}
659 +
660 +/* (2) Go through all the relocs and count any potential GOT- or
661 + PLT-references to each symbol */
662 +
663 +static bfd_boolean
664 +avr32_check_relocs (bfd *abfd, struct bfd_link_info *info, asection *sec,
665 + const Elf_Internal_Rela *relocs)
666 +{
667 + Elf_Internal_Shdr *symtab_hdr;
668 + struct elf_avr32_link_hash_table *htab;
669 + struct elf_link_hash_entry **sym_hashes;
670 + const Elf_Internal_Rela *rel, *rel_end;
671 + struct got_entry **local_got_ents;
672 + struct got_entry *got;
673 + const struct elf_backend_data *bed = get_elf_backend_data (abfd);
674 + asection *sgot;
675 + bfd *dynobj;
676 +
677 + pr_debug("(2) check relocs for %s:<%s> (size 0x%lx)\n",
678 + abfd->filename, sec->name, sec->size);
679 +
680 + if (info->relocatable)
681 + return TRUE;
682 +
683 + dynobj = elf_hash_table(info)->dynobj;
684 + symtab_hdr = &elf_tdata(abfd)->symtab_hdr;
685 + sym_hashes = elf_sym_hashes(abfd);
686 + htab = avr32_elf_hash_table(info);
687 + local_got_ents = elf_local_got_ents(abfd);
688 + sgot = htab->sgot;
689 +
690 + rel_end = relocs + sec->reloc_count;
691 + for (rel = relocs; rel < rel_end; rel++)
692 + {
693 + unsigned long r_symndx, r_type;
694 + struct elf_avr32_link_hash_entry *h;
695 +
696 + r_symndx = ELF32_R_SYM(rel->r_info);
697 + r_type = ELF32_R_TYPE(rel->r_info);
698 +
699 + /* Local symbols use local_got_ents, while others store the same
700 + information in the hash entry */
701 + if (r_symndx < symtab_hdr->sh_info)
702 + {
703 + pr_debug(" (2a) processing local symbol %lu\n", r_symndx);
704 + h = NULL;
705 + }
706 + else
707 + {
708 + h = (struct elf_avr32_link_hash_entry *)
709 + sym_hashes[r_symndx - symtab_hdr->sh_info];
710 + while (h->root.type == bfd_link_hash_indirect
711 + || h->root.type == bfd_link_hash_warning)
712 + h = (struct elf_avr32_link_hash_entry *)h->root.root.u.i.link;
713 + pr_debug(" (2a) processing symbol %s\n", h->root.root.root.string);
714 + }
715 +
716 + /* Some relocs require special sections to be created. */
717 + switch (r_type)
718 + {
719 + case R_AVR32_GOT32:
720 + case R_AVR32_GOT16:
721 + case R_AVR32_GOT8:
722 + case R_AVR32_GOT21S:
723 + case R_AVR32_GOT18SW:
724 + case R_AVR32_GOT16S:
725 + case R_AVR32_GOT7UW:
726 + case R_AVR32_LDA_GOT:
727 + case R_AVR32_GOTCALL:
728 + if (rel->r_addend)
729 + {
730 + if (info->callbacks->reloc_dangerous
731 + (info, _("Non-zero addend on GOT-relative relocation"),
732 + abfd, sec, rel->r_offset) == FALSE)
733 + return FALSE;
734 + }
735 + /* fall through */
736 + case R_AVR32_GOTPC:
737 + if (dynobj == NULL)
738 + elf_hash_table(info)->dynobj = dynobj = abfd;
739 + if (sgot == NULL && !avr32_elf_create_got_section(dynobj, info))
740 + return FALSE;
741 + break;
742 + case R_AVR32_32:
743 + /* We may need to create .rela.dyn later on. */
744 + if (dynobj == NULL
745 + && (info->shared || h != NULL)
746 + && (sec->flags & SEC_ALLOC))
747 + elf_hash_table(info)->dynobj = dynobj = abfd;
748 + break;
749 + }
750 +
751 + if (h != NULL && r_type != R_AVR32_GOT18SW)
752 + h->no_fn_stub = TRUE;
753 +
754 + switch (r_type)
755 + {
756 + case R_AVR32_GOT32:
757 + case R_AVR32_GOT16:
758 + case R_AVR32_GOT8:
759 + case R_AVR32_GOT21S:
760 + case R_AVR32_GOT18SW:
761 + case R_AVR32_GOT16S:
762 + case R_AVR32_GOT7UW:
763 + case R_AVR32_LDA_GOT:
764 + case R_AVR32_GOTCALL:
765 + if (h != NULL)
766 + {
767 + got = h->root.got.glist;
768 + if (!got)
769 + {
770 + got = bfd_zalloc(abfd, sizeof(struct got_entry));
771 + if (!got)
772 + return FALSE;
773 + h->root.got.glist = got;
774 + }
775 + }
776 + else
777 + {
778 + if (!local_got_ents)
779 + {
780 + bfd_size_type size;
781 + bfd_size_type i;
782 + struct got_entry *tmp_entry;
783 +
784 + size = symtab_hdr->sh_info;
785 + size *= sizeof(struct got_entry *) + sizeof(struct got_entry);
786 + local_got_ents = bfd_zalloc(abfd, size);
787 + if (!local_got_ents)
788 + return FALSE;
789 +
790 + elf_local_got_ents(abfd) = local_got_ents;
791 +
792 + tmp_entry = (struct got_entry *)(local_got_ents
793 + + symtab_hdr->sh_info);
794 + for (i = 0; i < symtab_hdr->sh_info; i++)
795 + local_got_ents[i] = &tmp_entry[i];
796 + }
797 +
798 + got = local_got_ents[r_symndx];
799 + }
800 +
801 + got->refcount++;
802 + if (got->refcount > htab->nr_got_holes)
803 + htab->nr_got_holes = got->refcount;
804 + break;
805 +
806 + case R_AVR32_32:
807 + if ((info->shared || h != NULL)
808 + && (sec->flags & SEC_ALLOC))
809 + {
810 + if (htab->srelgot == NULL)
811 + {
812 + htab->srelgot = create_dynamic_section(dynobj, ".rela.got",
813 + bed->dynamic_sec_flags
814 + | SEC_READONLY, 2);
815 + if (htab->srelgot == NULL)
816 + return FALSE;
817 + }
818 +
819 + if (sec->flags & SEC_READONLY
820 + && !h->readonly_reloc_sec)
821 + {
822 + h->readonly_reloc_sec = sec;
823 + h->readonly_reloc_offset = rel->r_offset;
824 + }
825 +
826 + if (h != NULL)
827 + {
828 + pr_debug("Non-GOT reference to symbol %s\n",
829 + h->root.root.root.string);
830 + h->possibly_dynamic_relocs++;
831 + }
832 + else
833 + {
834 + pr_debug("Non-GOT reference to local symbol %lu\n",
835 + r_symndx);
836 + htab->local_dynamic_relocs++;
837 + }
838 + }
839 +
840 + break;
841 +
842 + /* TODO: GNU_VTINHERIT and GNU_VTENTRY */
843 + }
844 + }
845 +
846 + return TRUE;
847 +}
848 +
849 +/* (3) Adjust a symbol defined by a dynamic object and referenced by a
850 + regular object. The current definition is in some section of the
851 + dynamic object, but we're not including those sections. We have to
852 + change the definition to something the rest of the link can
853 + understand. */
854 +
855 +static bfd_boolean
856 +avr32_elf_adjust_dynamic_symbol(struct bfd_link_info *info,
857 + struct elf_link_hash_entry *h)
858 +{
859 + struct elf_avr32_link_hash_table *htab;
860 + struct elf_avr32_link_hash_entry *havr;
861 + bfd *dynobj;
862 +
863 + pr_debug("(3) adjust dynamic symbol %s\n", h->root.root.string);
864 +
865 + htab = avr32_elf_hash_table(info);
866 + havr = (struct elf_avr32_link_hash_entry *)h;
867 + dynobj = elf_hash_table(info)->dynobj;
868 +
869 + /* Make sure we know what is going on here. */
870 + BFD_ASSERT (dynobj != NULL
871 + && (h->u.weakdef != NULL
872 + || (h->def_dynamic
873 + && h->ref_regular
874 + && !h->def_regular)));
875 +
876 + /* We don't want dynamic relocations in read-only sections. */
877 + if (havr->readonly_reloc_sec)
878 + {
879 + if (info->callbacks->reloc_dangerous
880 + (info, _("dynamic relocation in read-only section"),
881 + havr->readonly_reloc_sec->owner, havr->readonly_reloc_sec,
882 + havr->readonly_reloc_offset) == FALSE)
883 + return FALSE;
884 + }
885 +
886 + /* If this is a function, create a stub if possible and set the
887 + symbol to the stub location. */
888 + if (0 && !havr->no_fn_stub)
889 + {
890 + if (!h->def_regular)
891 + {
892 + asection *s = htab->sstub;
893 +
894 + BFD_ASSERT(s != NULL);
895 +
896 + h->root.u.def.section = s;
897 + h->root.u.def.value = s->size;
898 + h->plt.offset = s->size;
899 + s->size += AVR32_FUNCTION_STUB_SIZE;
900 +
901 + return TRUE;
902 + }
903 + }
904 + else if (h->type == STT_FUNC)
905 + {
906 + /* This will set the entry for this symbol in the GOT to 0, and
907 + the dynamic linker will take care of this. */
908 + h->root.u.def.value = 0;
909 + return TRUE;
910 + }
911 +
912 + /* If this is a weak symbol, and there is a real definition, the
913 + processor independent code will have arranged for us to see the
914 + real definition first, and we can just use the same value. */
915 + if (h->u.weakdef != NULL)
916 + {
917 + BFD_ASSERT(h->u.weakdef->root.type == bfd_link_hash_defined
918 + || h->u.weakdef->root.type == bfd_link_hash_defweak);
919 + h->root.u.def.section = h->u.weakdef->root.u.def.section;
920 + h->root.u.def.value = h->u.weakdef->root.u.def.value;
921 + return TRUE;
922 + }
923 +
924 + /* This is a reference to a symbol defined by a dynamic object which
925 + is not a function. */
926 +
927 + return TRUE;
928 +}
929 +
930 +
931 +/* Garbage-collection of unused sections */
932 +
933 +static asection *
934 +avr32_elf_gc_mark_hook(asection *sec,
935 + struct bfd_link_info *info ATTRIBUTE_UNUSED,
936 + Elf_Internal_Rela *rel,
937 + struct elf_link_hash_entry *h,
938 + Elf_Internal_Sym *sym)
939 +{
940 + if (h)
941 + {
942 + switch (ELF32_R_TYPE(rel->r_info))
943 + {
944 + /* TODO: VTINHERIT/VTENTRY */
945 + default:
946 + switch (h->root.type)
947 + {
948 + case bfd_link_hash_defined:
949 + case bfd_link_hash_defweak:
950 + return h->root.u.def.section;
951 +
952 + case bfd_link_hash_common:
953 + return h->root.u.c.p->section;
954 +
955 + default:
956 + break;
957 + }
958 + }
959 + }
960 + else
961 + return bfd_section_from_elf_index(sec->owner, sym->st_shndx);
962 +
963 + return NULL;
964 +}
965 +
966 +/* Update the GOT entry reference counts for the section being removed. */
967 +static bfd_boolean
968 +avr32_elf_gc_sweep_hook(bfd *abfd,
969 + struct bfd_link_info *info ATTRIBUTE_UNUSED,
970 + asection *sec,
971 + const Elf_Internal_Rela *relocs)
972 +{
973 + Elf_Internal_Shdr *symtab_hdr;
974 + struct elf_avr32_link_hash_entry **sym_hashes;
975 + struct got_entry **local_got_ents;
976 + const Elf_Internal_Rela *rel, *relend;
977 +
978 + if (!(sec->flags & SEC_ALLOC))
979 + return TRUE;
980 +
981 + symtab_hdr = &elf_tdata(abfd)->symtab_hdr;
982 + sym_hashes = (struct elf_avr32_link_hash_entry **)elf_sym_hashes(abfd);
983 + local_got_ents = elf_local_got_ents(abfd);
984 +
985 + relend = relocs + sec->reloc_count;
986 + for (rel = relocs; rel < relend; rel++)
987 + {
988 + unsigned long r_symndx;
989 + unsigned int r_type;
990 + struct elf_avr32_link_hash_entry *h = NULL;
991 +
992 + r_symndx = ELF32_R_SYM(rel->r_info);
993 + if (r_symndx >= symtab_hdr->sh_info)
994 + {
995 + h = sym_hashes[r_symndx - symtab_hdr->sh_info];
996 + while (h->root.root.type == bfd_link_hash_indirect
997 + || h->root.root.type == bfd_link_hash_warning)
998 + h = (struct elf_avr32_link_hash_entry *)h->root.root.u.i.link;
999 + }
1000 +
1001 + r_type = ELF32_R_TYPE(rel->r_info);
1002 +
1003 + switch (r_type)
1004 + {
1005 + case R_AVR32_GOT32:
1006 + case R_AVR32_GOT16:
1007 + case R_AVR32_GOT8:
1008 + case R_AVR32_GOT21S:
1009 + case R_AVR32_GOT18SW:
1010 + case R_AVR32_GOT16S:
1011 + case R_AVR32_GOT7UW:
1012 + case R_AVR32_LDA_GOT:
1013 + case R_AVR32_GOTCALL:
1014 + if (h)
1015 + h->root.got.glist->refcount--;
1016 + else
1017 + local_got_ents[r_symndx]->refcount--;
1018 + break;
1019 +
1020 + case R_AVR32_32:
1021 + if (info->shared || h)
1022 + {
1023 + if (h)
1024 + h->possibly_dynamic_relocs--;
1025 + else
1026 + avr32_elf_hash_table(info)->local_dynamic_relocs--;
1027 + }
1028 +
1029 + default:
1030 + break;
1031 + }
1032 + }
1033 +
1034 + return TRUE;
1035 +}
1036 +
1037 +/* Sizing and refcounting of dynamic sections */
1038 +
1039 +static void
1040 +insert_got_entry(struct elf_avr32_link_hash_table *htab, struct got_entry *got);
1041 +static void
1042 +unref_got_entry(struct elf_avr32_link_hash_table *htab, struct got_entry *got);
1043 +static void
1044 +ref_got_entry(struct elf_avr32_link_hash_table *htab, struct got_entry *got);
1045 +static bfd_boolean
1046 +assign_got_offsets(struct elf_avr32_link_hash_table *htab);
1047 +static bfd_boolean
1048 +allocate_dynrelocs(struct elf_link_hash_entry *h, void *_info);
1049 +static bfd_boolean
1050 +avr32_elf_size_dynamic_sections (bfd *output_bfd,
1051 + struct bfd_link_info *info);
1052 +
1053 +static void
1054 +insert_got_entry(struct elf_avr32_link_hash_table *htab, struct got_entry *got)
1055 +{
1056 + /* Any entries with got_refcount > htab->nr_got_holes end up in the
1057 + * last pigeonhole without any sorting. We expect the number of such
1058 + * entries to be small, so it is very unlikely to affect
1059 + * performance. */
1060 + int entry = got->refcount;
1061 +
1062 + if (entry > htab->nr_got_holes)
1063 + entry = htab->nr_got_holes;
1064 +
1065 + got->pprev = &htab->got_hole[entry];
1066 + got->next = htab->got_hole[entry];
1067 +
1068 + if (got->next)
1069 + got->next->pprev = &got->next;
1070 +
1071 + htab->got_hole[entry] = got;
1072 +}
1073 +
1074 +/* Decrement the refcount of a GOT entry and update its position in
1075 + the pigeonhole array. */
1076 +static void
1077 +unref_got_entry(struct elf_avr32_link_hash_table *htab, struct got_entry *got)
1078 +{
1079 + BFD_ASSERT(got->refcount > 0);
1080 +
1081 + if (got->next)
1082 + got->next->pprev = got->pprev;
1083 +
1084 + *(got->pprev) = got->next;
1085 + got->refcount--;
1086 + insert_got_entry(htab, got);
1087 +}
1088 +
1089 +static void
1090 +ref_got_entry(struct elf_avr32_link_hash_table *htab, struct got_entry *got)
1091 +{
1092 + if (got->next)
1093 + got->next->pprev = got->pprev;
1094 +
1095 + *(got->pprev) = got->next;
1096 + got->refcount++;
1097 + insert_got_entry(htab, got);
1098 +
1099 + BFD_ASSERT(got->refcount > 0);
1100 +}
1101 +
1102 +/* Assign offsets to all GOT entries we intend to keep. The entries
1103 + that are referenced most often are placed at low offsets so that we
1104 + can use compact instructions as much as possible.
1105 +
1106 + Returns TRUE if any offsets or the total size of the GOT changed. */
1107 +
1108 +static bfd_boolean
1109 +assign_got_offsets(struct elf_avr32_link_hash_table *htab)
1110 +{
1111 + struct got_entry *got;
1112 + bfd_size_type got_size = 0;
1113 + bfd_boolean changed = FALSE;
1114 + bfd_signed_vma offset;
1115 + int i;
1116 +
1117 + /* The GOT header provides the address of the DYNAMIC segment, so
1118 + we need that even if the GOT is otherwise empty. */
1119 + if (htab->root.dynamic_sections_created)
1120 + got_size = AVR32_GOT_HEADER_SIZE;
1121 +
1122 + for (i = htab->nr_got_holes; i > 0; i--)
1123 + {
1124 + got = htab->got_hole[i];
1125 + while (got)
1126 + {
1127 + if (got->refcount > 0)
1128 + {
1129 + offset = got_size;
1130 + if (got->offset != offset)
1131 + {
1132 + RDBG("GOT offset changed: %ld -> %ld\n",
1133 + got->offset, offset);
1134 + changed = TRUE;
1135 + }
1136 + got->offset = offset;
1137 + got_size += 4;
1138 + }
1139 + got = got->next;
1140 + }
1141 + }
1142 +
1143 + if (htab->sgot->size != got_size)
1144 + {
1145 + RDBG("GOT size changed: %lu -> %lu\n", htab->sgot->size,
1146 + got_size);
1147 + changed = TRUE;
1148 + }
1149 + htab->sgot->size = got_size;
1150 +
1151 + RDBG("assign_got_offsets: total size %lu (%s)\n",
1152 + got_size, changed ? "changed" : "no change");
1153 +
1154 + return changed;
1155 +}
1156 +
1157 +static bfd_boolean
1158 +allocate_dynrelocs(struct elf_link_hash_entry *h, void *_info)
1159 +{
1160 + struct bfd_link_info *info = _info;
1161 + struct elf_avr32_link_hash_table *htab;
1162 + struct elf_avr32_link_hash_entry *havr;
1163 + struct got_entry *got;
1164 +
1165 + pr_debug(" (4b) allocate_dynrelocs: %s\n", h->root.root.string);
1166 +
1167 + if (h->root.type == bfd_link_hash_indirect)
1168 + return TRUE;
1169 +
1170 + if (h->root.type == bfd_link_hash_warning)
1171 + /* When warning symbols are created, they **replace** the "real"
1172 + entry in the hash table, thus we never get to see the real
1173 + symbol in a hash traversal. So look at it now. */
1174 + h = (struct elf_link_hash_entry *) h->root.u.i.link;
1175 +
1176 + htab = avr32_elf_hash_table(info);
1177 + havr = (struct elf_avr32_link_hash_entry *)h;
1178 +
1179 + got = h->got.glist;
1180 +
1181 + /* If got is NULL, the symbol is never referenced through the GOT */
1182 + if (got && got->refcount > 0)
1183 + {
1184 + insert_got_entry(htab, got);
1185 +
1186 + /* Shared libraries need relocs for all GOT entries unless the
1187 + symbol is forced local or -Bsymbolic is used. Others need
1188 + relocs for everything that is not guaranteed to be defined in
1189 + a regular object. */
1190 + if ((info->shared
1191 + && !info->symbolic
1192 + && h->dynindx != -1)
1193 + || (htab->root.dynamic_sections_created
1194 + && h->def_dynamic
1195 + && !h->def_regular))
1196 + htab->srelgot->size += sizeof(Elf32_External_Rela);
1197 + }
1198 +
1199 + if (havr->possibly_dynamic_relocs
1200 + && (info->shared
1201 + || (elf_hash_table(info)->dynamic_sections_created
1202 + && h->def_dynamic
1203 + && !h->def_regular)))
1204 + {
1205 + pr_debug("Allocating %d dynamic reloc against symbol %s...\n",
1206 + havr->possibly_dynamic_relocs, h->root.root.string);
1207 + htab->srelgot->size += (havr->possibly_dynamic_relocs
1208 + * sizeof(Elf32_External_Rela));
1209 + }
1210 +
1211 + return TRUE;
1212 +}
1213 +
1214 +/* (4) Calculate the sizes of the linker-generated sections and
1215 + allocate memory for them. */
1216 +
1217 +static bfd_boolean
1218 +avr32_elf_size_dynamic_sections (bfd *output_bfd,
1219 + struct bfd_link_info *info)
1220 +{
1221 + struct elf_avr32_link_hash_table *htab;
1222 + bfd *dynobj;
1223 + asection *s;
1224 + bfd *ibfd;
1225 + bfd_boolean relocs;
1226 +
1227 + pr_debug("(4) size dynamic sections\n");
1228 +
1229 + htab = avr32_elf_hash_table(info);
1230 + dynobj = htab->root.dynobj;
1231 + BFD_ASSERT(dynobj != NULL);
1232 +
1233 + if (htab->root.dynamic_sections_created)
1234 + {
1235 + /* Initialize the contents of the .interp section to the name of
1236 + the dynamic loader */
1237 + if (info->executable)
1238 + {
1239 + s = bfd_get_section_by_name(dynobj, ".interp");
1240 + BFD_ASSERT(s != NULL);
1241 + s->size = sizeof(ELF_DYNAMIC_INTERPRETER);
1242 + s->contents = (unsigned char *)ELF_DYNAMIC_INTERPRETER;
1243 + }
1244 + }
1245 +
1246 + if (htab->nr_got_holes > 0)
1247 + {
1248 + /* Allocate holes for the pigeonhole sort algorithm */
1249 + pr_debug("Highest GOT refcount: %d\n", htab->nr_got_holes);
1250 +
1251 + /* Limit the memory usage by clipping the number of pigeonholes
1252 + * at a predefined maximum. All entries with a higher refcount
1253 + * will end up in the last pigeonhole. */
1254 + if (htab->nr_got_holes >= MAX_NR_GOT_HOLES)
1255 + {
1256 + htab->nr_got_holes = MAX_NR_GOT_HOLES - 1;
1257 +
1258 + pr_debug("Limiting maximum number of GOT pigeonholes to %u\n",
1259 + htab->nr_got_holes);
1260 + }
1261 + htab->got_hole = bfd_zalloc(output_bfd,
1262 + sizeof(struct got_entry *)
1263 + * (htab->nr_got_holes + 1));
1264 + if (!htab->got_hole)
1265 + return FALSE;
1266 +
1267 + /* Set up .got offsets for local syms. */
1268 + for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link_next)
1269 + {
1270 + struct got_entry **local_got;
1271 + struct got_entry **end_local_got;
1272 + Elf_Internal_Shdr *symtab_hdr;
1273 + bfd_size_type locsymcount;
1274 +
1275 + pr_debug(" (4a) processing file %s...\n", ibfd->filename);
1276 +
1277 + BFD_ASSERT(bfd_get_flavour(ibfd) == bfd_target_elf_flavour);
1278 +
1279 + local_got = elf_local_got_ents(ibfd);
1280 + if (!local_got)
1281 + continue;
1282 +
1283 + symtab_hdr = &elf_tdata(ibfd)->symtab_hdr;
1284 + locsymcount = symtab_hdr->sh_info;
1285 + end_local_got = local_got + locsymcount;
1286 +
1287 + for (; local_got < end_local_got; ++local_got)
1288 + insert_got_entry(htab, *local_got);
1289 + }
1290 + }
1291 +
1292 + /* Allocate global sym .got entries and space for global sym
1293 + dynamic relocs */
1294 + elf_link_hash_traverse(&htab->root, allocate_dynrelocs, info);
1295 +
1296 + /* Now that we have sorted the GOT entries, we are ready to
1297 + assign offsets and determine the initial size of the GOT. */
1298 + if (htab->sgot)
1299 + assign_got_offsets(htab);
1300 +
1301 + /* Allocate space for local sym dynamic relocs */
1302 + BFD_ASSERT(htab->local_dynamic_relocs == 0 || info->shared);
1303 + if (htab->local_dynamic_relocs)
1304 + htab->srelgot->size += (htab->local_dynamic_relocs
1305 + * sizeof(Elf32_External_Rela));
1306 +
1307 + /* We now have determined the sizes of the various dynamic
1308 + sections. Allocate memory for them. */
1309 + relocs = FALSE;
1310 + for (s = dynobj->sections; s; s = s->next)
1311 + {
1312 + if ((s->flags & SEC_LINKER_CREATED) == 0)
1313 + continue;
1314 +
1315 + if (s == htab->sgot
1316 + || s == htab->sstub)
1317 + {
1318 + /* Strip this section if we don't need it */
1319 + }
1320 + else if (strncmp (bfd_get_section_name(dynobj, s), ".rela", 5) == 0)
1321 + {
1322 + if (s->size != 0)
1323 + relocs = TRUE;
1324 +
1325 + s->reloc_count = 0;
1326 + }
1327 + else
1328 + {
1329 + /* It's not one of our sections */
1330 + continue;
1331 + }
1332 +
1333 + if (s->size == 0)
1334 + {
1335 + /* Strip unneeded sections */
1336 + pr_debug("Stripping section %s from output...\n", s->name);
1337 + /* deleted function in 2.17
1338 + _bfd_strip_section_from_output(info, s);
1339 + */
1340 + continue;
1341 + }
1342 +
1343 + s->contents = bfd_zalloc(dynobj, s->size);
1344 + if (s->contents == NULL)
1345 + return FALSE;
1346 + }
1347 +
1348 + if (htab->root.dynamic_sections_created)
1349 + {
1350 + /* Add some entries to the .dynamic section. We fill in the
1351 + values later, in sh_elf_finish_dynamic_sections, but we
1352 + must add the entries now so that we get the correct size for
1353 + the .dynamic section. The DT_DEBUG entry is filled in by the
1354 + dynamic linker and used by the debugger. */
1355 +#define add_dynamic_entry(TAG, VAL) _bfd_elf_add_dynamic_entry(info, TAG, VAL)
1356 +
1357 + if (!add_dynamic_entry(DT_PLTGOT, 0))
1358 + return FALSE;
1359 + if (!add_dynamic_entry(DT_AVR32_GOTSZ, 0))
1360 + return FALSE;
1361 +
1362 + if (info->executable)
1363 + {
1364 + if (!add_dynamic_entry(DT_DEBUG, 0))
1365 + return FALSE;
1366 + }
1367 + if (relocs)
1368 + {
1369 + if (!add_dynamic_entry(DT_RELA, 0)
1370 + || !add_dynamic_entry(DT_RELASZ, 0)
1371 + || !add_dynamic_entry(DT_RELAENT,
1372 + sizeof(Elf32_External_Rela)))
1373 + return FALSE;
1374 + }
1375 + }
1376 +#undef add_dynamic_entry
1377 +
1378 + return TRUE;
1379 +}
1380 +
1381 +
1382 +/* Access to internal relocations, section contents and symbols.
1383 + (stolen from the xtensa port) */
1384 +
1385 +static Elf_Internal_Rela *
1386 +retrieve_internal_relocs (bfd *abfd, asection *sec, bfd_boolean keep_memory);
1387 +static void
1388 +pin_internal_relocs (asection *sec, Elf_Internal_Rela *internal_relocs);
1389 +static void
1390 +release_internal_relocs (asection *sec, Elf_Internal_Rela *internal_relocs);
1391 +static bfd_byte *
1392 +retrieve_contents (bfd *abfd, asection *sec, bfd_boolean keep_memory);
1393 +/*
1394 +static void
1395 +pin_contents (asection *sec, bfd_byte *contents);
1396 +*/
1397 +static void
1398 +release_contents (asection *sec, bfd_byte *contents);
1399 +static Elf_Internal_Sym *
1400 +retrieve_local_syms (bfd *input_bfd, bfd_boolean keep_memory);
1401 +/*
1402 +static void
1403 +pin_local_syms (bfd *input_bfd, Elf_Internal_Sym *isymbuf);
1404 +*/
1405 +static void
1406 +release_local_syms (bfd *input_bfd, Elf_Internal_Sym *isymbuf);
1407 +
1408 +/* During relaxation, we need to modify relocations, section contents,
1409 + and symbol definitions, and we need to keep the original values from
1410 + being reloaded from the input files, i.e., we need to "pin" the
1411 + modified values in memory. We also want to continue to observe the
1412 + setting of the "keep-memory" flag. The following functions wrap the
1413 + standard BFD functions to take care of this for us. */
1414 +
1415 +static Elf_Internal_Rela *
1416 +retrieve_internal_relocs (bfd *abfd, asection *sec, bfd_boolean keep_memory)
1417 +{
1418 + /* _bfd_elf_link_read_relocs knows about caching, so no need for us
1419 + to be clever here. */
1420 + return _bfd_elf_link_read_relocs(abfd, sec, NULL, NULL, keep_memory);
1421 +}
1422 +
1423 +static void
1424 +pin_internal_relocs (asection *sec, Elf_Internal_Rela *internal_relocs)
1425 +{
1426 + elf_section_data (sec)->relocs = internal_relocs;
1427 +}
1428 +
1429 +static void
1430 +release_internal_relocs (asection *sec, Elf_Internal_Rela *internal_relocs)
1431 +{
1432 + if (internal_relocs
1433 + && elf_section_data (sec)->relocs != internal_relocs)
1434 + free (internal_relocs);
1435 +}
1436 +
1437 +static bfd_byte *
1438 +retrieve_contents (bfd *abfd, asection *sec, bfd_boolean keep_memory)
1439 +{
1440 + bfd_byte *contents;
1441 + bfd_size_type sec_size;
1442 +
1443 + sec_size = bfd_get_section_limit (abfd, sec);
1444 + contents = elf_section_data (sec)->this_hdr.contents;
1445 +
1446 + if (contents == NULL && sec_size != 0)
1447 + {
1448 + if (!bfd_malloc_and_get_section (abfd, sec, &contents))
1449 + {
1450 + if (contents)
1451 + free (contents);
1452 + return NULL;
1453 + }
1454 + if (keep_memory)
1455 + elf_section_data (sec)->this_hdr.contents = contents;
1456 + }
1457 + return contents;
1458 +}
1459 +
1460 +/*
1461 +static void
1462 +pin_contents (asection *sec, bfd_byte *contents)
1463 +{
1464 + elf_section_data (sec)->this_hdr.contents = contents;
1465 +}
1466 +*/
1467 +static void
1468 +release_contents (asection *sec, bfd_byte *contents)
1469 +{
1470 + if (contents && elf_section_data (sec)->this_hdr.contents != contents)
1471 + free (contents);
1472 +}
1473 +
1474 +static Elf_Internal_Sym *
1475 +retrieve_local_syms (bfd *input_bfd, bfd_boolean keep_memory)
1476 +{
1477 + Elf_Internal_Shdr *symtab_hdr;
1478 + Elf_Internal_Sym *isymbuf;
1479 + size_t locsymcount;
1480 +
1481 + symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
1482 + locsymcount = symtab_hdr->sh_info;
1483 +
1484 + isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
1485 + if (isymbuf == NULL && locsymcount != 0)
1486 + {
1487 + isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr, locsymcount, 0,
1488 + NULL, NULL, NULL);
1489 + if (isymbuf && keep_memory)
1490 + symtab_hdr->contents = (unsigned char *) isymbuf;
1491 + }
1492 +
1493 + return isymbuf;
1494 +}
1495 +
1496 +/*
1497 +static void
1498 +pin_local_syms (bfd *input_bfd, Elf_Internal_Sym *isymbuf)
1499 +{
1500 + elf_tdata (input_bfd)->symtab_hdr.contents = (unsigned char *)isymbuf;
1501 +}
1502 +
1503 +*/
1504 +static void
1505 +release_local_syms (bfd *input_bfd, Elf_Internal_Sym *isymbuf)
1506 +{
1507 + if (isymbuf && (elf_tdata (input_bfd)->symtab_hdr.contents
1508 + != (unsigned char *)isymbuf))
1509 + free (isymbuf);
1510 +}
1511 +
1512 +\f/* Data structures used during relaxation. */
1513 +
1514 +enum relax_state_id {
1515 + RS_ERROR = -1,
1516 + RS_NONE = 0,
1517 + RS_ALIGN,
1518 + RS_CPENT,
1519 + RS_PIC_CALL,
1520 + RS_PIC_MCALL,
1521 + RS_PIC_RCALL2,
1522 + RS_PIC_RCALL1,
1523 + RS_PIC_LDA,
1524 + RS_PIC_LDW4,
1525 + RS_PIC_LDW3,
1526 + RS_PIC_SUB5,
1527 + RS_NOPIC_MCALL,
1528 + RS_NOPIC_RCALL2,
1529 + RS_NOPIC_RCALL1,
1530 + RS_NOPIC_LDW4,
1531 + RS_NOPIC_LDDPC,
1532 + RS_NOPIC_SUB5,
1533 + RS_NOPIC_MOV2,
1534 + RS_NOPIC_MOV1,
1535 + RS_RCALL2,
1536 + RS_RCALL1,
1537 + RS_BRC2,
1538 + RS_BRC1,
1539 + RS_BRAL,
1540 + RS_RJMP,
1541 + RS_MAX,
1542 +};
1543 +
1544 +enum reference_type {
1545 + REF_ABSOLUTE,
1546 + REF_PCREL,
1547 + REF_CPOOL,
1548 + REF_GOT,
1549 +};
1550 +
1551 +struct relax_state
1552 +{
1553 + const char *name;
1554 + enum relax_state_id id;
1555 + enum relax_state_id direct;
1556 + enum relax_state_id next;
1557 + enum relax_state_id prev;
1558 +
1559 + enum reference_type reftype;
1560 +
1561 + unsigned int r_type;
1562 +
1563 + bfd_vma opcode;
1564 + bfd_vma opcode_mask;
1565 +
1566 + bfd_signed_vma range_min;
1567 + bfd_signed_vma range_max;
1568 +
1569 + bfd_size_type size;
1570 +};
1571 +
1572 +/*
1573 + * This is for relocs that
1574 + * a) has an addend or is of type R_AVR32_DIFF32, and
1575 + * b) references a different section than it's in, and
1576 + * c) references a section that is relaxable
1577 + *
1578 + * as well as relocs that references the constant pool, in which case
1579 + * the add_frag member points to the frag containing the constant pool
1580 + * entry.
1581 + *
1582 + * Such relocs must be fixed up whenever we delete any code. Sections
1583 + * that don't have any relocs with all of the above properties don't
1584 + * have any additional reloc data, but sections that do will have
1585 + * additional data for all its relocs.
1586 + */
1587 +struct avr32_reloc_data
1588 +{
1589 + struct fragment *add_frag;
1590 + struct fragment *sub_frag;
1591 +};
1592 +
1593 +/*
1594 + * A 'fragment' is a relaxable entity, that is, code may be added or
1595 + * deleted at the end of a fragment. When this happens, all subsequent
1596 + * fragments in the list will have their offsets updated.
1597 + */
1598 +struct fragment
1599 +{
1600 + enum relax_state_id state;
1601 + enum relax_state_id initial_state;
1602 +
1603 + Elf_Internal_Rela *rela;
1604 + bfd_size_type size;
1605 + bfd_vma offset;
1606 + int size_adjust;
1607 + int offset_adjust;
1608 + bfd_boolean has_grown;
1609 +
1610 + /* Only used by constant pool entries. When this drops to zero, the
1611 + frag is discarded (i.e. size_adjust is set to -4.) */
1612 + int refcount;
1613 +};
1614 +
1615 +struct avr32_relax_data
1616 +{
1617 + unsigned int frag_count;
1618 + struct fragment *frag;
1619 + struct avr32_reloc_data *reloc_data;
1620 +
1621 + /* TRUE if this section has one or more relaxable relocations */
1622 + bfd_boolean is_relaxable;
1623 + unsigned int iteration;
1624 +};
1625 +
1626 +struct avr32_section_data
1627 +{
1628 + struct bfd_elf_section_data elf;
1629 + struct avr32_relax_data relax_data;
1630 +};
1631 +
1632 +\f/* Relax state definitions */
1633 +
1634 +#define PIC_MOV2_OPCODE 0xe0600000
1635 +#define PIC_MOV2_MASK 0xe1e00000
1636 +#define PIC_MOV2_RANGE_MIN (-1048576 * 4)
1637 +#define PIC_MOV2_RANGE_MAX (1048575 * 4)
1638 +#define PIC_MCALL_OPCODE 0xf0160000
1639 +#define PIC_MCALL_MASK 0xffff0000
1640 +#define PIC_MCALL_RANGE_MIN (-131072)
1641 +#define PIC_MCALL_RANGE_MAX (131068)
1642 +#define RCALL2_OPCODE 0xe0a00000
1643 +#define RCALL2_MASK 0xe1ef0000
1644 +#define RCALL2_RANGE_MIN (-2097152)
1645 +#define RCALL2_RANGE_MAX (2097150)
1646 +#define RCALL1_OPCODE 0xc00c0000
1647 +#define RCALL1_MASK 0xf00c0000
1648 +#define RCALL1_RANGE_MIN (-1024)
1649 +#define RCALL1_RANGE_MAX (1022)
1650 +#define PIC_LDW4_OPCODE 0xecf00000
1651 +#define PIC_LDW4_MASK 0xfff00000
1652 +#define PIC_LDW4_RANGE_MIN (-32768)
1653 +#define PIC_LDW4_RANGE_MAX (32767)
1654 +#define PIC_LDW3_OPCODE 0x6c000000
1655 +#define PIC_LDW3_MASK 0xfe000000
1656 +#define PIC_LDW3_RANGE_MIN (0)
1657 +#define PIC_LDW3_RANGE_MAX (124)
1658 +#define SUB5_PC_OPCODE 0xfec00000
1659 +#define SUB5_PC_MASK 0xfff00000
1660 +#define SUB5_PC_RANGE_MIN (-32768)
1661 +#define SUB5_PC_RANGE_MAX (32767)
1662 +#define NOPIC_MCALL_OPCODE 0xf01f0000
1663 +#define NOPIC_MCALL_MASK 0xffff0000
1664 +#define NOPIC_MCALL_RANGE_MIN PIC_MCALL_RANGE_MIN
1665 +#define NOPIC_MCALL_RANGE_MAX PIC_MCALL_RANGE_MAX
1666 +#define NOPIC_LDW4_OPCODE 0xfef00000
1667 +#define NOPIC_LDW4_MASK 0xfff00000
1668 +#define NOPIC_LDW4_RANGE_MIN PIC_LDW4_RANGE_MIN
1669 +#define NOPIC_LDW4_RANGE_MAX PIC_LDW4_RANGE_MAX
1670 +#define LDDPC_OPCODE 0x48000000
1671 +#define LDDPC_MASK 0xf8000000
1672 +#define LDDPC_RANGE_MIN 0
1673 +#define LDDPC_RANGE_MAX 508
1674 +
1675 +#define NOPIC_MOV2_OPCODE 0xe0600000
1676 +#define NOPIC_MOV2_MASK 0xe1e00000
1677 +#define NOPIC_MOV2_RANGE_MIN (-1048576)
1678 +#define NOPIC_MOV2_RANGE_MAX (1048575)
1679 +#define NOPIC_MOV1_OPCODE 0x30000000
1680 +#define NOPIC_MOV1_MASK 0xf0000000
1681 +#define NOPIC_MOV1_RANGE_MIN (-128)
1682 +#define NOPIC_MOV1_RANGE_MAX (127)
1683 +
1684 +/* Only brc2 variants with cond[3] == 0 is considered, since the
1685 + others are not relaxable. bral is a special case and is handled
1686 + separately. */
1687 +#define BRC2_OPCODE 0xe0800000
1688 +#define BRC2_MASK 0xe1e80000
1689 +#define BRC2_RANGE_MIN (-2097152)
1690 +#define BRC2_RANGE_MAX (2097150)
1691 +#define BRC1_OPCODE 0xc0000000
1692 +#define BRC1_MASK 0xf0080000
1693 +#define BRC1_RANGE_MIN (-256)
1694 +#define BRC1_RANGE_MAX (254)
1695 +#define BRAL_OPCODE 0xe08f0000
1696 +#define BRAL_MASK 0xe1ef0000
1697 +#define BRAL_RANGE_MIN BRC2_RANGE_MIN
1698 +#define BRAL_RANGE_MAX BRC2_RANGE_MAX
1699 +#define RJMP_OPCODE 0xc0080000
1700 +#define RJMP_MASK 0xf00c0000
1701 +#define RJMP_RANGE_MIN (-1024)
1702 +#define RJMP_RANGE_MAX (1022)
1703 +
1704 +/* Define a relax state using the GOT */
1705 +#define RG(id, dir, next, prev, r_type, opc, size) \
1706 + { "RS_"#id, RS_##id, RS_##dir, RS_##next, RS_##prev, REF_GOT, \
1707 + R_AVR32_##r_type, opc##_OPCODE, opc##_MASK, \
1708 + opc##_RANGE_MIN, opc##_RANGE_MAX, size }
1709 +/* Define a relax state using the Constant Pool */
1710 +#define RC(id, dir, next, prev, r_type, opc, size) \
1711 + { "RS_"#id, RS_##id, RS_##dir, RS_##next, RS_##prev, REF_CPOOL, \
1712 + R_AVR32_##r_type, opc##_OPCODE, opc##_MASK, \
1713 + opc##_RANGE_MIN, opc##_RANGE_MAX, size }
1714 +
1715 +/* Define a relax state using pc-relative direct reference */
1716 +#define RP(id, dir, next, prev, r_type, opc, size) \
1717 + { "RS_"#id, RS_##id, RS_##dir, RS_##next, RS_##prev, REF_PCREL, \
1718 + R_AVR32_##r_type, opc##_OPCODE, opc##_MASK, \
1719 + opc##_RANGE_MIN, opc##_RANGE_MAX, size }
1720 +
1721 +/* Define a relax state using non-pc-relative direct reference */
1722 +#define RD(id, dir, next, prev, r_type, opc, size) \
1723 + { "RS_"#id, RS_##id, RS_##dir, RS_##next, RS_##prev, REF_ABSOLUTE, \
1724 + R_AVR32_##r_type, opc##_OPCODE, opc##_MASK, \
1725 + opc##_RANGE_MIN, opc##_RANGE_MAX, size }
1726 +
1727 +/* Define a relax state that will be handled specially */
1728 +#define RS(id, r_type, size) \
1729 + { "RS_"#id, RS_##id, RS_NONE, RS_NONE, RS_NONE, REF_ABSOLUTE, \
1730 + R_AVR32_##r_type, 0, 0, 0, 0, size }
1731 +
1732 +const struct relax_state relax_state[RS_MAX] = {
1733 + RS(NONE, NONE, 0),
1734 + RS(ALIGN, ALIGN, 0),
1735 + RS(CPENT, 32_CPENT, 4),
1736 +
1737 + RG(PIC_CALL, PIC_RCALL1, PIC_MCALL, NONE, GOTCALL, PIC_MOV2, 10),
1738 + RG(PIC_MCALL, PIC_RCALL1, NONE, PIC_CALL, GOT18SW, PIC_MCALL, 4),
1739 + RP(PIC_RCALL2, NONE, PIC_RCALL1, PIC_MCALL, 22H_PCREL, RCALL2, 4),
1740 + RP(PIC_RCALL1, NONE, NONE, PIC_RCALL2, 11H_PCREL, RCALL1, 2),
1741 +
1742 + RG(PIC_LDA, PIC_SUB5, PIC_LDW4, NONE, LDA_GOT, PIC_MOV2, 8),
1743 + RG(PIC_LDW4, PIC_SUB5, PIC_LDW3, PIC_LDA, GOT16S, PIC_LDW4, 4),
1744 + RG(PIC_LDW3, PIC_SUB5, NONE, PIC_LDW4, GOT7UW, PIC_LDW3, 2),
1745 + RP(PIC_SUB5, NONE, NONE, PIC_LDW3, 16N_PCREL, SUB5_PC, 4),
1746 +
1747 + RC(NOPIC_MCALL, NOPIC_RCALL1, NONE, NONE, CPCALL, NOPIC_MCALL, 4),
1748 + RP(NOPIC_RCALL2, NONE, NOPIC_RCALL1, NOPIC_MCALL, 22H_PCREL, RCALL2, 4),
1749 + RP(NOPIC_RCALL1, NONE, NONE, NOPIC_RCALL2, 11H_PCREL, RCALL1, 2),
1750 +
1751 + RC(NOPIC_LDW4, NOPIC_MOV1, NOPIC_LDDPC, NONE, 16_CP, NOPIC_LDW4, 4),
1752 + RC(NOPIC_LDDPC, NOPIC_MOV1, NONE, NOPIC_LDW4, 9W_CP, LDDPC, 2),
1753 + RP(NOPIC_SUB5, NOPIC_MOV1, NONE, NOPIC_LDDPC, 16N_PCREL, SUB5_PC, 4),
1754 + RD(NOPIC_MOV2, NONE, NOPIC_MOV1, NOPIC_SUB5, 21S, NOPIC_MOV2, 4),
1755 + RD(NOPIC_MOV1, NONE, NONE, NOPIC_MOV2, 8S, NOPIC_MOV1, 2),
1756 +
1757 + RP(RCALL2, NONE, RCALL1, NONE, 22H_PCREL, RCALL2, 4),
1758 + RP(RCALL1, NONE, NONE, RCALL2, 11H_PCREL, RCALL1, 2),
1759 + RP(BRC2, NONE, BRC1, NONE, 22H_PCREL, BRC2, 4),
1760 + RP(BRC1, NONE, NONE, BRC2, 9H_PCREL, BRC1, 2),
1761 + RP(BRAL, NONE, RJMP, NONE, 22H_PCREL, BRAL, 4),
1762 + RP(RJMP, NONE, NONE, BRAL, 11H_PCREL, RJMP, 2),
1763 +};
1764 +
1765 +static bfd_boolean
1766 +avr32_elf_new_section_hook(bfd *abfd, asection *sec)
1767 +{
1768 + struct avr32_section_data *sdata;
1769 +
1770 + sdata = bfd_zalloc(abfd, sizeof(struct avr32_section_data));
1771 + if (!sdata)
1772 + return FALSE;
1773 +
1774 + sec->used_by_bfd = sdata;
1775 + return _bfd_elf_new_section_hook(abfd, sec);
1776 +}
1777 +
1778 +static struct avr32_relax_data *
1779 +avr32_relax_data(asection *sec)
1780 +{
1781 + struct avr32_section_data *sdata;
1782 +
1783 + BFD_ASSERT(sec->used_by_bfd);
1784 +
1785 + sdata = (struct avr32_section_data *)elf_section_data(sec);
1786 + return &sdata->relax_data;
1787 +}
1788 +
1789 +\f/* Link-time relaxation */
1790 +
1791 +static bfd_boolean
1792 +avr32_elf_relax_section(bfd *abfd, asection *sec,
1793 + struct bfd_link_info *info, bfd_boolean *again);
1794 +
1795 +enum relax_pass_id {
1796 + RELAX_PASS_SIZE_FRAGS,
1797 + RELAX_PASS_MOVE_DATA,
1798 +};
1799 +
1800 +/* Stolen from the xtensa port */
1801 +static int
1802 +internal_reloc_compare (const void *ap, const void *bp)
1803 +{
1804 + const Elf_Internal_Rela *a = (const Elf_Internal_Rela *) ap;
1805 + const Elf_Internal_Rela *b = (const Elf_Internal_Rela *) bp;
1806 +
1807 + if (a->r_offset != b->r_offset)
1808 + return (a->r_offset - b->r_offset);
1809 +
1810 + /* We don't need to sort on these criteria for correctness,
1811 + but enforcing a more strict ordering prevents unstable qsort
1812 + from behaving differently with different implementations.
1813 + Without the code below we get correct but different results
1814 + on Solaris 2.7 and 2.8. We would like to always produce the
1815 + same results no matter the host. */
1816 +
1817 + if (a->r_info != b->r_info)
1818 + return (a->r_info - b->r_info);
1819 +
1820 + return (a->r_addend - b->r_addend);
1821 +}
1822 +
1823 +static enum relax_state_id
1824 +get_pcrel22_relax_state(bfd *abfd, asection *sec, struct bfd_link_info *info,
1825 + const Elf_Internal_Rela *rela)
1826 +{
1827 + bfd_byte *contents;
1828 + bfd_vma insn;
1829 + enum relax_state_id rs = RS_NONE;
1830 +
1831 + contents = retrieve_contents(abfd, sec, info->keep_memory);
1832 + if (!contents)
1833 + return RS_ERROR;
1834 +
1835 + insn = bfd_get_32(abfd, contents + rela->r_offset);
1836 + if ((insn & RCALL2_MASK) == RCALL2_OPCODE)
1837 + rs = RS_RCALL2;
1838 + else if ((insn & BRAL_MASK) == BRAL_OPCODE)
1839 + /* Optimizing bral -> rjmp gets us into all kinds of
1840 + trouble with jump tables. Better not do it. */
1841 + rs = RS_NONE;
1842 + else if ((insn & BRC2_MASK) == BRC2_OPCODE)
1843 + rs = RS_BRC2;
1844 +
1845 + release_contents(sec, contents);
1846 +
1847 + return rs;
1848 +}
1849 +
1850 +static enum relax_state_id
1851 +get_initial_relax_state(bfd *abfd, asection *sec, struct bfd_link_info *info,
1852 + const Elf_Internal_Rela *rela)
1853 +{
1854 + switch (ELF_R_TYPE(rela->r_info))
1855 + {
1856 + case R_AVR32_GOTCALL:
1857 + return RS_PIC_CALL;
1858 + case R_AVR32_GOT18SW:
1859 + return RS_PIC_MCALL;
1860 + case R_AVR32_LDA_GOT:
1861 + return RS_PIC_LDA;
1862 + case R_AVR32_GOT16S:
1863 + return RS_PIC_LDW4;
1864 + case R_AVR32_CPCALL:
1865 + return RS_NOPIC_MCALL;
1866 + case R_AVR32_16_CP:
1867 + return RS_NOPIC_LDW4;
1868 + case R_AVR32_9W_CP:
1869 + return RS_NOPIC_LDDPC;
1870 + case R_AVR32_ALIGN:
1871 + return RS_ALIGN;
1872 + case R_AVR32_32_CPENT:
1873 + return RS_CPENT;
1874 + case R_AVR32_22H_PCREL:
1875 + return get_pcrel22_relax_state(abfd, sec, info, rela);
1876 + case R_AVR32_9H_PCREL:
1877 + return RS_BRC1;
1878 + default:
1879 + return RS_NONE;
1880 + }
1881 +}
1882 +
1883 +static bfd_boolean
1884 +reloc_is_cpool_ref(const Elf_Internal_Rela *rela)
1885 +{
1886 + switch (ELF_R_TYPE(rela->r_info))
1887 + {
1888 + case R_AVR32_CPCALL:
1889 + case R_AVR32_16_CP:
1890 + case R_AVR32_9W_CP:
1891 + return TRUE;
1892 + default:
1893 + return FALSE;
1894 + }
1895 +}
1896 +
1897 +static struct fragment *
1898 +new_frag(bfd *abfd ATTRIBUTE_UNUSED, asection *sec,
1899 + struct avr32_relax_data *rd, enum relax_state_id state,
1900 + Elf_Internal_Rela *rela)
1901 +{
1902 + struct fragment *frag;
1903 + bfd_size_type r_size;
1904 + bfd_vma r_offset;
1905 + unsigned int i = rd->frag_count;
1906 +
1907 + BFD_ASSERT(state >= RS_NONE && state < RS_MAX);
1908 +
1909 + rd->frag_count++;
1910 + frag = bfd_realloc(rd->frag, sizeof(struct fragment) * rd->frag_count);
1911 + if (!frag)
1912 + return NULL;
1913 + rd->frag = frag;
1914 +
1915 + frag += i;
1916 + memset(frag, 0, sizeof(struct fragment));
1917 +
1918 + if (state == RS_ALIGN)
1919 + r_size = (((rela->r_offset + (1 << rela->r_addend) - 1)
1920 + & ~((1 << rela->r_addend) - 1)) - rela->r_offset);
1921 + else
1922 + r_size = relax_state[state].size;
1923 +
1924 + if (rela)
1925 + r_offset = rela->r_offset;
1926 + else
1927 + r_offset = sec->size;
1928 +
1929 + if (i == 0)
1930 + {
1931 + frag->offset = 0;
1932 + frag->size = r_offset + r_size;
1933 + }
1934 + else
1935 + {
1936 + frag->offset = rd->frag[i - 1].offset + rd->frag[i - 1].size;
1937 + frag->size = r_offset + r_size - frag->offset;
1938 + }
1939 +
1940 + if (state != RS_CPENT)
1941 + /* Make sure we don't discard this frag */
1942 + frag->refcount = 1;
1943 +
1944 + frag->initial_state = frag->state = state;
1945 + frag->rela = rela;
1946 +
1947 + return frag;
1948 +}
1949 +
1950 +static struct fragment *
1951 +find_frag(asection *sec, bfd_vma offset)
1952 +{
1953 + struct fragment *first, *last;
1954 + struct avr32_relax_data *rd = avr32_relax_data(sec);
1955 +
1956 + if (rd->frag_count == 0)
1957 + return NULL;
1958 +
1959 + first = &rd->frag[0];
1960 + last = &rd->frag[rd->frag_count - 1];
1961 +
1962 + /* This may be a reloc referencing the end of a section. The last
1963 + frag will never have a reloc associated with it, so its size will
1964 + never change, thus the offset adjustment of the last frag will
1965 + always be the same as the offset adjustment of the end of the
1966 + section. */
1967 + if (offset == sec->size)
1968 + {
1969 + BFD_ASSERT(last->offset + last->size == sec->size);
1970 + BFD_ASSERT(!last->rela);
1971 + return last;
1972 + }
1973 +
1974 + while (first <= last)
1975 + {
1976 + struct fragment *mid;
1977 +
1978 + mid = (last - first) / 2 + first;
1979 + if ((mid->offset + mid->size) <= offset)
1980 + first = mid + 1;
1981 + else if (mid->offset > offset)
1982 + last = mid - 1;
1983 + else
1984 + return mid;
1985 + }
1986 +
1987 + return NULL;
1988 +}
1989 +
1990 +/* Look through all relocs in a section and determine if any relocs
1991 + may be affected by relaxation in other sections. If so, allocate
1992 + an array of additional relocation data which links the affected
1993 + relocations to the frag(s) where the relaxation may occur.
1994 +
1995 + This function also links cpool references to cpool entries and
1996 + increments the refcount of the latter when this happens. */
1997 +
1998 +static bfd_boolean
1999 +allocate_reloc_data(bfd *abfd, asection *sec, Elf_Internal_Rela *relocs,
2000 + struct bfd_link_info *info)
2001 +{
2002 + Elf_Internal_Shdr *symtab_hdr;
2003 + Elf_Internal_Sym *isymbuf = NULL;
2004 + struct avr32_relax_data *rd;
2005 + unsigned int i;
2006 + bfd_boolean ret = FALSE;
2007 +
2008 + symtab_hdr = &elf_tdata(abfd)->symtab_hdr;
2009 + rd = avr32_relax_data(sec);
2010 +
2011 + RDBG("%s<%s>: allocate_reloc_data\n", abfd->filename, sec->name);
2012 +
2013 + for (i = 0; i < sec->reloc_count; i++)
2014 + {
2015 + Elf_Internal_Rela *rel = &relocs[i];
2016 + asection *sym_sec;
2017 + unsigned long r_symndx;
2018 + bfd_vma sym_value;
2019 +
2020 + if (!rel->r_addend && ELF_R_TYPE(rel->r_info) != R_AVR32_DIFF32
2021 + && !reloc_is_cpool_ref(rel))
2022 + continue;
2023 +
2024 + r_symndx = ELF_R_SYM(rel->r_info);
2025 +
2026 + if (r_symndx < symtab_hdr->sh_info)
2027 + {
2028 + Elf_Internal_Sym *isym;
2029 +
2030 + if (!isymbuf)
2031 + isymbuf = retrieve_local_syms(abfd, info->keep_memory);
2032 + if (!isymbuf)
2033 + return FALSE;
2034 +
2035 + isym = &isymbuf[r_symndx];
2036 + sym_sec = bfd_section_from_elf_index(abfd, isym->st_shndx);
2037 + sym_value = isym->st_value;
2038 + }
2039 + else
2040 + {
2041 + struct elf_link_hash_entry *h;
2042 +
2043 + h = elf_sym_hashes(abfd)[r_symndx - symtab_hdr->sh_info];
2044 +
2045 + while (h->root.type == bfd_link_hash_indirect
2046 + || h->root.type == bfd_link_hash_warning)
2047 + h = (struct elf_link_hash_entry *)h->root.u.i.link;
2048 +
2049 + if (h->root.type != bfd_link_hash_defined
2050 + && h->root.type != bfd_link_hash_defweak)
2051 + continue;
2052 +
2053 + sym_sec = h->root.u.def.section;
2054 + sym_value = h->root.u.def.value;
2055 + }
2056 +
2057 + if (sym_sec && avr32_relax_data(sym_sec)->is_relaxable)
2058 + {
2059 + bfd_size_type size;
2060 + struct fragment *frag;
2061 +
2062 + if (!rd->reloc_data)
2063 + {
2064 + size = sizeof(struct avr32_reloc_data) * sec->reloc_count;
2065 + rd->reloc_data = bfd_zalloc(abfd, size);
2066 + if (!rd->reloc_data)
2067 + goto out;
2068 + }
2069 +
2070 + RDBG("[%3d] 0x%04lx: target: 0x%lx + 0x%lx",
2071 + i, rel->r_offset, sym_value, rel->r_addend);
2072 +
2073 + frag = find_frag(sym_sec, sym_value + rel->r_addend);
2074 + BFD_ASSERT(frag);
2075 + rd->reloc_data[i].add_frag = frag;
2076 +
2077 + RDBG(" -> %s<%s>:%04lx\n", sym_sec->owner->filename, sym_sec->name,
2078 + frag->rela ? frag->rela->r_offset : sym_sec->size);
2079 +
2080 + if (reloc_is_cpool_ref(rel))
2081 + {
2082 + BFD_ASSERT(ELF_R_TYPE(frag->rela->r_info) == R_AVR32_32_CPENT);
2083 + frag->refcount++;
2084 + }
2085 +
2086 + if (ELF_R_TYPE(rel->r_info) == R_AVR32_DIFF32)
2087 + {
2088 + bfd_byte *contents;
2089 + bfd_signed_vma diff;
2090 +
2091 + contents = retrieve_contents(abfd, sec, info->keep_memory);
2092 + if (!contents)
2093 + goto out;
2094 +
2095 + diff = bfd_get_signed_32(abfd, contents + rel->r_offset);
2096 + frag = find_frag(sym_sec, sym_value + rel->r_addend + diff);
2097 + BFD_ASSERT(frag);
2098 + rd->reloc_data[i].sub_frag = frag;
2099 +
2100 + release_contents(sec, contents);
2101 + }
2102 + }
2103 + }
2104 +
2105 + ret = TRUE;
2106 +
2107 + out:
2108 + release_local_syms(abfd, isymbuf);
2109 + return ret;
2110 +}
2111 +
2112 +static bfd_boolean
2113 +global_sym_set_frag(struct elf_avr32_link_hash_entry *havr,
2114 + struct bfd_link_info *info ATTRIBUTE_UNUSED)
2115 +{
2116 + struct fragment *frag;
2117 + asection *sec;
2118 +
2119 + if (havr->root.root.type != bfd_link_hash_defined
2120 + && havr->root.root.type != bfd_link_hash_defweak)
2121 + return TRUE;
2122 +
2123 + sec = havr->root.root.u.def.section;
2124 + if (bfd_is_const_section(sec)
2125 + || !avr32_relax_data(sec)->is_relaxable)
2126 + return TRUE;
2127 +
2128 + frag = find_frag(sec, havr->root.root.u.def.value);
2129 + if (!frag)
2130 + {
2131 + unsigned int i;
2132 + struct avr32_relax_data *rd = avr32_relax_data(sec);
2133 +
2134 + RDBG("In %s: No frag for %s <%s+%lu> (limit %lu)\n",
2135 + sec->owner->filename, havr->root.root.root.string,
2136 + sec->name, havr->root.root.u.def.value, sec->size);
2137 + for (i = 0; i < rd->frag_count; i++)
2138 + RDBG(" %8lu - %8lu\n", rd->frag[i].offset,
2139 + rd->frag[i].offset + rd->frag[i].size);
2140 + }
2141 + BFD_ASSERT(frag);
2142 +
2143 + havr->sym_frag = frag;
2144 + return TRUE;
2145 +}
2146 +
2147 +static bfd_boolean
2148 +analyze_relocations(struct bfd_link_info *info)
2149 +{
2150 + bfd *abfd;
2151 + asection *sec;
2152 +
2153 + /* Divide all relaxable sections into fragments */
2154 + for (abfd = info->input_bfds; abfd; abfd = abfd->link_next)
2155 + {
2156 + if (!(elf_elfheader(abfd)->e_flags & EF_AVR32_LINKRELAX))
2157 + {
2158 + if (!(*info->callbacks->warning)
2159 + (info, _("input is not relaxable"), NULL, abfd, NULL, 0))
2160 + return FALSE;
2161 + continue;
2162 + }
2163 +
2164 + for (sec = abfd->sections; sec; sec = sec->next)
2165 + {
2166 + struct avr32_relax_data *rd;
2167 + struct fragment *frag;
2168 + Elf_Internal_Rela *relocs;
2169 + unsigned int i;
2170 + bfd_boolean ret = TRUE;
2171 +
2172 + if (!(sec->flags & SEC_RELOC) || sec->reloc_count == 0)
2173 + continue;
2174 +
2175 + rd = avr32_relax_data(sec);
2176 +
2177 + relocs = retrieve_internal_relocs(abfd, sec, info->keep_memory);
2178 + if (!relocs)
2179 + return FALSE;
2180 +
2181 + qsort(relocs, sec->reloc_count, sizeof(Elf_Internal_Rela),
2182 + internal_reloc_compare);
2183 +
2184 + for (i = 0; i < sec->reloc_count; i++)
2185 + {
2186 + enum relax_state_id state;
2187 +
2188 + ret = FALSE;
2189 + state = get_initial_relax_state(abfd, sec, info, &relocs[i]);
2190 + if (state == RS_ERROR)
2191 + break;
2192 +
2193 + if (state)
2194 + {
2195 + frag = new_frag(abfd, sec, rd, state, &relocs[i]);
2196 + if (!frag)
2197 + break;
2198 +
2199 + pin_internal_relocs(sec, relocs);
2200 + rd->is_relaxable = TRUE;
2201 + }
2202 +
2203 + ret = TRUE;
2204 + }
2205 +
2206 + release_internal_relocs(sec, relocs);
2207 + if (!ret)
2208 + return ret;
2209 +
2210 + if (rd->is_relaxable)
2211 + {
2212 + frag = new_frag(abfd, sec, rd, RS_NONE, NULL);
2213 + if (!frag)
2214 + return FALSE;
2215 + }
2216 + }
2217 + }
2218 +
2219 + /* Link each global symbol to the fragment where it's defined. */
2220 + elf_link_hash_traverse(elf_hash_table(info), global_sym_set_frag, info);
2221 +
2222 + /* Do the same for local symbols. */
2223 + for (abfd = info->input_bfds; abfd; abfd = abfd->link_next)
2224 + {
2225 + Elf_Internal_Sym *isymbuf, *isym;
2226 + struct fragment **local_sym_frag;
2227 + unsigned int i, sym_count;
2228 +
2229 + sym_count = elf_tdata(abfd)->symtab_hdr.sh_info;
2230 + if (sym_count == 0)
2231 + continue;
2232 +
2233 + local_sym_frag = bfd_zalloc(abfd, sym_count * sizeof(struct fragment *));
2234 + if (!local_sym_frag)
2235 + return FALSE;
2236 + elf_tdata(abfd)->local_sym_frag = local_sym_frag;
2237 +
2238 + isymbuf = retrieve_local_syms(abfd, info->keep_memory);
2239 + if (!isymbuf)
2240 + return FALSE;
2241 +
2242 + for (i = 0; i < sym_count; i++)
2243 + {
2244 + struct avr32_relax_data *rd;
2245 + struct fragment *frag;
2246 + asection *sec;
2247 +
2248 + isym = &isymbuf[i];
2249 +
2250 + sec = bfd_section_from_elf_index(abfd, isym->st_shndx);
2251 + if (!sec)
2252 + continue;
2253 +
2254 + rd = avr32_relax_data(sec);
2255 + if (!rd->is_relaxable)
2256 + continue;
2257 +
2258 + frag = find_frag(sec, isym->st_value);
2259 + BFD_ASSERT(frag);
2260 +
2261 + local_sym_frag[i] = frag;
2262 + }
2263 +
2264 + release_local_syms(abfd, isymbuf);
2265 + }
2266 +
2267 + /* And again for relocs with addends and constant pool references */
2268 + for (abfd = info->input_bfds; abfd; abfd = abfd->link_next)
2269 + for (sec = abfd->sections; sec; sec = sec->next)
2270 + {
2271 + Elf_Internal_Rela *relocs;
2272 + bfd_boolean ret;
2273 +
2274 + if (!(sec->flags & SEC_RELOC) || sec->reloc_count == 0)
2275 + continue;
2276 +
2277 + relocs = retrieve_internal_relocs(abfd, sec, info->keep_memory);
2278 + if (!relocs)
2279 + return FALSE;
2280 +
2281 + ret = allocate_reloc_data(abfd, sec, relocs, info);
2282 +
2283 + release_internal_relocs(sec, relocs);
2284 + if (ret == FALSE)
2285 + return ret;
2286 + }
2287 +
2288 + return TRUE;
2289 +}
2290 +
2291 +static bfd_boolean
2292 +rs_is_good_enough(const struct relax_state *rs, struct fragment *frag,
2293 + bfd_vma symval, bfd_vma addr, struct got_entry *got,
2294 + struct avr32_reloc_data *ind_data,
2295 + bfd_signed_vma offset_adjust)
2296 +{
2297 + bfd_signed_vma target = 0;
2298 +
2299 + switch (rs->reftype)
2300 + {
2301 + case REF_ABSOLUTE:
2302 + target = symval;
2303 + break;
2304 + case REF_PCREL:
2305 + target = symval - addr;
2306 + break;
2307 + case REF_CPOOL:
2308 + /* cpool frags are always in the same section and always after
2309 + all frags referring to it. So it's always correct to add in
2310 + offset_adjust here. */
2311 + target = (ind_data->add_frag->offset + ind_data->add_frag->offset_adjust
2312 + + offset_adjust - frag->offset - frag->offset_adjust);
2313 + break;
2314 + case REF_GOT:
2315 + target = got->offset;
2316 + break;
2317 + default:
2318 + abort();
2319 + }
2320 +
2321 + if (target >= rs->range_min && target <= rs->range_max)
2322 + return TRUE;
2323 + else
2324 + return FALSE;
2325 +}
2326 +
2327 +static bfd_boolean
2328 +avr32_size_frags(bfd *abfd, asection *sec, struct bfd_link_info *info)
2329 +{
2330 + struct elf_avr32_link_hash_table *htab;
2331 + struct avr32_relax_data *rd;
2332 + Elf_Internal_Shdr *symtab_hdr;
2333 + Elf_Internal_Rela *relocs = NULL;
2334 + Elf_Internal_Sym *isymbuf = NULL;
2335 + struct got_entry **local_got_ents;
2336 + struct fragment **local_sym_frag;
2337 + bfd_boolean ret = FALSE;
2338 + bfd_signed_vma delta = 0;
2339 + unsigned int i;
2340 +
2341 + htab = avr32_elf_hash_table(info);
2342 + rd = avr32_relax_data(sec);
2343 +
2344 + if (sec == htab->sgot)
2345 + {
2346 + RDBG("Relaxing GOT section (vma: 0x%lx)\n",
2347 + sec->output_section->vma + sec->output_offset);
2348 + if (assign_got_offsets(htab))
2349 + htab->repeat_pass = TRUE;
2350 + return TRUE;
2351 + }
2352 +
2353 + if (!rd->is_relaxable)
2354 + return TRUE;
2355 +
2356 + if (!sec->rawsize)
2357 + sec->rawsize = sec->size;
2358 +
2359 + symtab_hdr = &elf_tdata(abfd)->symtab_hdr;
2360 + relocs = retrieve_internal_relocs(abfd, sec, info->keep_memory);
2361 + if (!relocs)
2362 + goto out;
2363 +
2364 + isymbuf = retrieve_local_syms(abfd, info->keep_memory);
2365 + if (!isymbuf)
2366 + goto out;
2367 +
2368 + local_got_ents = elf_local_got_ents(abfd);
2369 + local_sym_frag = elf_tdata(abfd)->local_sym_frag;
2370 +
2371 + RDBG("size_frags: %s<%s>\n vma: 0x%08lx, size: 0x%08lx\n",
2372 + abfd->filename, sec->name,
2373 + sec->output_section->vma + sec->output_offset, sec->size);
2374 +
2375 + for (i = 0; i < rd->frag_count; i++)
2376 + {
2377 + struct fragment *frag = &rd->frag[i];
2378 + struct avr32_reloc_data *r_data = NULL, *ind_data = NULL;
2379 + const struct relax_state *state, *next_state;
2380 + struct fragment *target_frag = NULL;
2381 + asection *sym_sec = NULL;
2382 + Elf_Internal_Rela *rela;
2383 + struct got_entry *got;
2384 + bfd_vma symval, r_offset, addend, addr;
2385 + bfd_signed_vma size_adjust = 0, distance;
2386 + unsigned long r_symndx;
2387 + bfd_boolean defined = TRUE, dynamic = FALSE;
2388 + unsigned char sym_type;
2389 +
2390 + frag->offset_adjust += delta;
2391 + state = next_state = &relax_state[frag->state];
2392 + rela = frag->rela;
2393 +
2394 + BFD_ASSERT(state->id == frag->state);
2395 +
2396 + RDBG(" 0x%04lx%c%d: %s [size %ld]", rela ? rela->r_offset : sec->rawsize,
2397 + (frag->offset_adjust < 0)?'-':'+',
2398 + abs(frag->offset_adjust), state->name, state->size);
2399 +
2400 + if (!rela)
2401 + {
2402 + RDBG(": no reloc, ignoring\n");
2403 + continue;
2404 + }
2405 +
2406 + BFD_ASSERT((unsigned int)(rela - relocs) < sec->reloc_count);
2407 + BFD_ASSERT(state != RS_NONE);
2408 +
2409 + r_offset = rela->r_offset + frag->offset_adjust;
2410 + addr = sec->output_section->vma + sec->output_offset + r_offset;
2411 +
2412 + switch (frag->state)
2413 + {
2414 + case RS_ALIGN:
2415 + size_adjust = ((addr + (1 << rela->r_addend) - 1)
2416 + & ~((1 << rela->r_addend) - 1));
2417 + size_adjust -= (sec->output_section->vma + sec->output_offset
2418 + + frag->offset + frag->offset_adjust
2419 + + frag->size + frag->size_adjust);
2420 +
2421 + RDBG(": adjusting size %lu -> %lu\n", frag->size + frag->size_adjust,
2422 + frag->size + frag->size_adjust + size_adjust);
2423 + break;
2424 +
2425 + case RS_CPENT:
2426 + if (frag->refcount == 0 && frag->size_adjust == 0)
2427 + {
2428 + RDBG(": discarding frag\n");
2429 + size_adjust = -4;
2430 + }
2431 + else if (frag->refcount > 0 && frag->size_adjust < 0)
2432 + {
2433 + RDBG(": un-discarding frag\n");
2434 + size_adjust = 4;
2435 + }
2436 + break;
2437 +
2438 + default:
2439 + if (rd->reloc_data)
2440 + r_data = &rd->reloc_data[frag->rela - relocs];
2441 +
2442 + /* If this is a cpool reference, we want the symbol that the
2443 + cpool entry refers to, not the symbol for the cpool entry
2444 + itself, as we already know what frag it's in. */
2445 + if (relax_state[frag->initial_state].reftype == REF_CPOOL)
2446 + {
2447 + Elf_Internal_Rela *irela = r_data->add_frag->rela;
2448 +
2449 + r_symndx = ELF_R_SYM(irela->r_info);
2450 + addend = irela->r_addend;
2451 +
2452 + /* The constant pool must be in the same section as the
2453 + reloc referring to it. */
2454 + BFD_ASSERT((unsigned long)(irela - relocs) < sec->reloc_count);
2455 +
2456 + ind_data = r_data;
2457 + r_data = &rd->reloc_data[irela - relocs];
2458 + }
2459 + else
2460 + {
2461 + r_symndx = ELF_R_SYM(rela->r_info);
2462 + addend = rela->r_addend;
2463 + }
2464 +
2465 + /* Get the value of the symbol referred to by the reloc. */
2466 + if (r_symndx < symtab_hdr->sh_info)
2467 + {
2468 + Elf_Internal_Sym *isym;
2469 +
2470 + isym = isymbuf + r_symndx;
2471 + symval = 0;
2472 +
2473 + RDBG(" local sym %lu: ", r_symndx);
2474 +
2475 + if (isym->st_shndx == SHN_UNDEF)
2476 + defined = FALSE;
2477 + else if (isym->st_shndx == SHN_ABS)
2478 + sym_sec = bfd_abs_section_ptr;
2479 + else if (isym->st_shndx == SHN_COMMON)
2480 + sym_sec = bfd_com_section_ptr;
2481 + else
2482 + sym_sec = bfd_section_from_elf_index(abfd, isym->st_shndx);
2483 +
2484 + symval = isym->st_value;
2485 + sym_type = ELF_ST_TYPE(isym->st_info);
2486 + target_frag = local_sym_frag[r_symndx];
2487 +
2488 + if (local_got_ents)
2489 + got = local_got_ents[r_symndx];
2490 + else
2491 + got = NULL;
2492 + }
2493 + else
2494 + {
2495 + /* Global symbol */
2496 + unsigned long index;
2497 + struct elf_link_hash_entry *h;
2498 + struct elf_avr32_link_hash_entry *havr;
2499 +
2500 + index = r_symndx - symtab_hdr->sh_info;
2501 + h = elf_sym_hashes(abfd)[index];
2502 + BFD_ASSERT(h != NULL);
2503 +
2504 + while (h->root.type == bfd_link_hash_indirect
2505 + || h->root.type == bfd_link_hash_warning)
2506 + h = (struct elf_link_hash_entry *)h->root.u.i.link;
2507 +
2508 + havr = (struct elf_avr32_link_hash_entry *)h;
2509 + got = h->got.glist;
2510 +
2511 + symval = 0;
2512 +
2513 + RDBG(" %s: ", h->root.root.string);
2514 +
2515 + if (h->root.type != bfd_link_hash_defined
2516 + && h->root.type != bfd_link_hash_defweak)
2517 + {
2518 + RDBG("(undef)");
2519 + defined = FALSE;
2520 + }
2521 + else if ((info->shared && !info->symbolic && h->dynindx != -1)
2522 + || (htab->root.dynamic_sections_created
2523 + && h->def_dynamic && !h->def_regular))
2524 + {
2525 + RDBG("(dynamic)");
2526 + dynamic = TRUE;
2527 + sym_sec = h->root.u.def.section;
2528 + }
2529 + else
2530 + {
2531 + sym_sec = h->root.u.def.section;
2532 + symval = h->root.u.def.value;
2533 + target_frag = havr->sym_frag;
2534 + }
2535 +
2536 + sym_type = h->type;
2537 + }
2538 +
2539 + /* Thanks to elf32-ppc for this one. */
2540 + if (sym_sec && sym_sec->sec_info_type == ELF_INFO_TYPE_MERGE)
2541 + {
2542 + /* At this stage in linking, no SEC_MERGE symbol has been
2543 + adjusted, so all references to such symbols need to be
2544 + passed through _bfd_merged_section_offset. (Later, in
2545 + relocate_section, all SEC_MERGE symbols *except* for
2546 + section symbols have been adjusted.)
2547 +
2548 + SEC_MERGE sections are not relaxed by us, as they
2549 + shouldn't contain any code. */
2550 +
2551 + BFD_ASSERT(!target_frag && !(r_data && r_data->add_frag));
2552 +
2553 + /* gas may reduce relocations against symbols in SEC_MERGE
2554 + sections to a relocation against the section symbol when
2555 + the original addend was zero. When the reloc is against
2556 + a section symbol we should include the addend in the
2557 + offset passed to _bfd_merged_section_offset, since the
2558 + location of interest is the original symbol. On the
2559 + other hand, an access to "sym+addend" where "sym" is not
2560 + a section symbol should not include the addend; Such an
2561 + access is presumed to be an offset from "sym"; The
2562 + location of interest is just "sym". */
2563 + RDBG("\n MERGE: %s: 0x%lx+0x%lx+0x%lx -> ",
2564 + (sym_type == STT_SECTION)?"section":"not section",
2565 + sym_sec->output_section->vma + sym_sec->output_offset,
2566 + symval, addend);
2567 +
2568 + if (sym_type == STT_SECTION)
2569 + symval += addend;
2570 +
2571 + symval = (_bfd_merged_section_offset
2572 + (abfd, &sym_sec,
2573 + elf_section_data(sym_sec)->sec_info, symval));
2574 +
2575 + if (sym_type != STT_SECTION)
2576 + symval += addend;
2577 + }
2578 + else
2579 + symval += addend;
2580 +
2581 + if (defined && !dynamic)
2582 + {
2583 + RDBG("0x%lx+0x%lx",
2584 + sym_sec->output_section->vma + sym_sec->output_offset,
2585 + symval);
2586 + symval += sym_sec->output_section->vma + sym_sec->output_offset;
2587 + }
2588 +
2589 + if (r_data && r_data->add_frag)
2590 + /* If the add_frag pointer is set, it means that this reloc
2591 + has an addend that may be affected by relaxation. */
2592 + target_frag = r_data->add_frag;
2593 +
2594 + if (target_frag)
2595 + {
2596 + symval += target_frag->offset_adjust;
2597 +
2598 + /* If target_frag comes after this frag in the same
2599 + section, we should assume that it will be moved by
2600 + the same amount we are. */
2601 + if ((target_frag - rd->frag) < (int)rd->frag_count
2602 + && target_frag > frag)
2603 + symval += delta;
2604 + }
2605 +
2606 + distance = symval - addr;
2607 +
2608 + /* First, try to make a direct reference. If the symbol is
2609 + dynamic or undefined, we must take care not to change its
2610 + reference type, that is, we can't make it direct.
2611 +
2612 + Also, it seems like some sections may actually be resized
2613 + after the relaxation code is done, so we can't really
2614 + trust that our "distance" is correct. There's really no
2615 + easy solution to this problem, so we'll just disallow
2616 + direct references to SEC_DATA sections.
2617 +
2618 + Oh, and .bss isn't actually SEC_DATA, so we disallow
2619 + !SEC_HAS_CONTENTS as well. */
2620 + if (!dynamic && defined
2621 + && (htab->direct_data_refs
2622 + || (!(sym_sec->flags & SEC_DATA)
2623 + && (sym_sec->flags & SEC_HAS_CONTENTS)))
2624 + && next_state->direct)
2625 + {
2626 + next_state = &relax_state[next_state->direct];
2627 + RDBG(" D-> %s", next_state->name);
2628 + }
2629 +
2630 + /* Iterate backwards until we find a state that fits. */
2631 + while (next_state->prev
2632 + && !rs_is_good_enough(next_state, frag, symval, addr,
2633 + got, ind_data, delta))
2634 + {
2635 + next_state = &relax_state[next_state->prev];
2636 + RDBG(" P-> %s", next_state->name);
2637 + }
2638 +
2639 + /* Then try to find the best possible state. */
2640 + while (next_state->next)
2641 + {
2642 + const struct relax_state *candidate;
2643 +
2644 + candidate = &relax_state[next_state->next];
2645 + if (!rs_is_good_enough(candidate, frag, symval, addr, got,
2646 + ind_data, delta))
2647 + break;
2648 +
2649 + next_state = candidate;
2650 + RDBG(" N-> %s", next_state->name);
2651 + }
2652 +
2653 + RDBG(" [size %ld]\n", next_state->size);
2654 +
2655 + BFD_ASSERT(next_state->id);
2656 + BFD_ASSERT(!dynamic || next_state->reftype == REF_GOT);
2657 +
2658 + size_adjust = next_state->size - state->size;
2659 +
2660 + /* There's a theoretical possibility that shrinking one frag
2661 + may cause another to grow, which may cause the first one to
2662 + grow as well, and we're back where we started. Avoid this
2663 + scenario by disallowing a frag that has grown to ever
2664 + shrink again. */
2665 + if (state->reftype == REF_GOT && next_state->reftype != REF_GOT)
2666 + {
2667 + if (frag->has_grown)
2668 + next_state = state;
2669 + else
2670 + unref_got_entry(htab, got);
2671 + }
2672 + else if (state->reftype != REF_GOT && next_state->reftype == REF_GOT)
2673 + {
2674 + ref_got_entry(htab, got);
2675 + frag->has_grown = TRUE;
2676 + }
2677 + else if (state->reftype == REF_CPOOL
2678 + && next_state->reftype != REF_CPOOL)
2679 + {
2680 + if (frag->has_grown)
2681 + next_state = state;
2682 + else
2683 + ind_data->add_frag->refcount--;
2684 + }
2685 + else if (state->reftype != REF_CPOOL
2686 + && next_state->reftype == REF_CPOOL)
2687 + {
2688 + ind_data->add_frag->refcount++;
2689 + frag->has_grown = TRUE;
2690 + }
2691 + else
2692 + {
2693 + if (frag->has_grown && size_adjust < 0)
2694 + next_state = state;
2695 + else if (size_adjust > 0)
2696 + frag->has_grown = TRUE;
2697 + }
2698 +
2699 + size_adjust = next_state->size - state->size;
2700 + frag->state = next_state->id;
2701 +
2702 + break;
2703 + }
2704 +
2705 + if (size_adjust)
2706 + htab->repeat_pass = TRUE;
2707 +
2708 + frag->size_adjust += size_adjust;
2709 + sec->size += size_adjust;
2710 + delta += size_adjust;
2711 +
2712 + BFD_ASSERT((frag->offset + frag->offset_adjust
2713 + + frag->size + frag->size_adjust)
2714 + == (frag[1].offset + frag[1].offset_adjust + delta));
2715 + }
2716 +
2717 + ret = TRUE;
2718 +
2719 + out:
2720 + release_local_syms(abfd, isymbuf);
2721 + release_internal_relocs(sec, relocs);
2722 + return ret;
2723 +}
2724 +
2725 +static bfd_boolean
2726 +adjust_global_symbol(struct elf_avr32_link_hash_entry *havr,
2727 + struct bfd_link_info *info ATTRIBUTE_UNUSED)
2728 +{
2729 + struct elf_link_hash_entry *h = &havr->root;
2730 +
2731 + if (havr->sym_frag && (h->root.type == bfd_link_hash_defined
2732 + || h->root.type == bfd_link_hash_defweak))
2733 + {
2734 + RDBG("adjust_global_symbol: %s 0x%08lx -> 0x%08lx\n",
2735 + h->root.root.string, h->root.u.def.value,
2736 + h->root.u.def.value + havr->sym_frag->offset_adjust);
2737 + h->root.u.def.value += havr->sym_frag->offset_adjust;
2738 + }
2739 + return TRUE;
2740 +}
2741 +
2742 +static bfd_boolean
2743 +adjust_syms(struct bfd_link_info *info)
2744 +{
2745 + struct elf_avr32_link_hash_table *htab;
2746 + bfd *abfd;
2747 +
2748 + htab = avr32_elf_hash_table(info);
2749 + elf_link_hash_traverse(&htab->root, adjust_global_symbol, info);
2750 +
2751 + for (abfd = info->input_bfds; abfd; abfd = abfd->link_next)
2752 + {
2753 + Elf_Internal_Sym *isymbuf;
2754 + struct fragment **local_sym_frag, *frag;
2755 + unsigned int i, sym_count;
2756 +
2757 + sym_count = elf_tdata(abfd)->symtab_hdr.sh_info;
2758 + if (sym_count == 0)
2759 + continue;
2760 +
2761 + isymbuf = retrieve_local_syms(abfd, info->keep_memory);
2762 + if (!isymbuf)
2763 + return FALSE;
2764 +
2765 + local_sym_frag = elf_tdata(abfd)->local_sym_frag;
2766 +
2767 + for (i = 0; i < sym_count; i++)
2768 + {
2769 + frag = local_sym_frag[i];
2770 + if (frag)
2771 + {
2772 + RDBG("adjust_local_symbol: %s[%u] 0x%08lx -> 0x%08lx\n",
2773 + abfd->filename, i, isymbuf[i].st_value,
2774 + isymbuf[i].st_value + frag->offset_adjust);
2775 + isymbuf[i].st_value += frag->offset_adjust;
2776 + }
2777 + }
2778 +
2779 + release_local_syms(abfd, isymbuf);
2780 + }
2781 +
2782 + htab->symbols_adjusted = TRUE;
2783 + return TRUE;
2784 +}
2785 +
2786 +static bfd_boolean
2787 +adjust_relocs(bfd *abfd, asection *sec, struct bfd_link_info *info)
2788 +{
2789 + struct avr32_relax_data *rd;
2790 + Elf_Internal_Rela *relocs;
2791 + Elf_Internal_Shdr *symtab_hdr;
2792 + unsigned int i;
2793 + bfd_boolean ret = FALSE;
2794 +
2795 + rd = avr32_relax_data(sec);
2796 + if (!rd->reloc_data)
2797 + return TRUE;
2798 +
2799 + RDBG("adjust_relocs: %s<%s> (count: %u)\n", abfd->filename, sec->name,
2800 + sec->reloc_count);
2801 +
2802 + relocs = retrieve_internal_relocs(abfd, sec, info->keep_memory);
2803 + if (!relocs)
2804 + return FALSE;
2805 +
2806 + symtab_hdr = &elf_tdata(abfd)->symtab_hdr;
2807 +
2808 + for (i = 0; i < sec->reloc_count; i++)
2809 + {
2810 + Elf_Internal_Rela *rela = &relocs[i];
2811 + struct avr32_reloc_data *r_data = &rd->reloc_data[i];
2812 + struct fragment *sym_frag;
2813 + unsigned long r_symndx;
2814 +
2815 + if (r_data->add_frag)
2816 + {
2817 + r_symndx = ELF_R_SYM(rela->r_info);
2818 +
2819 + if (r_symndx < symtab_hdr->sh_info)
2820 + sym_frag = elf_tdata(abfd)->local_sym_frag[r_symndx];
2821 + else
2822 + {
2823 + struct elf_link_hash_entry *h;
2824 +
2825 + h = elf_sym_hashes(abfd)[r_symndx - symtab_hdr->sh_info];
2826 +
2827 + while (h->root.type == bfd_link_hash_indirect
2828 + || h->root.type == bfd_link_hash_warning)
2829 + h = (struct elf_link_hash_entry *)h->root.u.i.link;
2830 +
2831 + BFD_ASSERT(h->root.type == bfd_link_hash_defined
2832 + || h->root.type == bfd_link_hash_defweak);
2833 +
2834 + sym_frag = ((struct elf_avr32_link_hash_entry *)h)->sym_frag;
2835 + }
2836 +
2837 + RDBG(" addend: 0x%08lx -> 0x%08lx\n",
2838 + rela->r_addend,
2839 + rela->r_addend + r_data->add_frag->offset_adjust
2840 + - (sym_frag ? sym_frag->offset_adjust : 0));
2841 +
2842 + /* If this is against a section symbol, we won't find any
2843 + sym_frag, so we'll just adjust the addend. */
2844 + rela->r_addend += r_data->add_frag->offset_adjust;
2845 + if (sym_frag)
2846 + rela->r_addend -= sym_frag->offset_adjust;
2847 +
2848 + if (r_data->sub_frag)
2849 + {
2850 + bfd_byte *contents;
2851 + bfd_signed_vma diff;
2852 +
2853 + contents = retrieve_contents(abfd, sec, info->keep_memory);
2854 + if (!contents)
2855 + goto out;
2856 +
2857 + /* I realize now that sub_frag is misnamed. It's
2858 + actually add_frag which is subtracted in this
2859 + case... */
2860 + diff = bfd_get_signed_32(abfd, contents + rela->r_offset);
2861 + diff += (r_data->sub_frag->offset_adjust
2862 + - r_data->add_frag->offset_adjust);
2863 + bfd_put_32(abfd, diff, contents + rela->r_offset);
2864 +
2865 + RDBG(" 0x%lx: DIFF32 updated: 0x%lx\n", rela->r_offset, diff);
2866 +
2867 + release_contents(sec, contents);
2868 + }
2869 + }
2870 + else
2871 + BFD_ASSERT(!r_data->sub_frag);
2872 + }
2873 +
2874 + ret = TRUE;
2875 +
2876 + out:
2877 + release_internal_relocs(sec, relocs);
2878 + return ret;
2879 +}
2880 +
2881 +static bfd_boolean
2882 +avr32_move_data(bfd *abfd, asection *sec, struct bfd_link_info *info)
2883 +{
2884 + struct elf_avr32_link_hash_table *htab;
2885 + struct avr32_relax_data *rd;
2886 + struct fragment *frag, *fragend;
2887 + Elf_Internal_Rela *relocs = NULL;
2888 + bfd_byte *contents = NULL;
2889 + unsigned int i;
2890 + bfd_boolean ret = FALSE;
2891 +
2892 + htab = avr32_elf_hash_table(info);
2893 + rd = avr32_relax_data(sec);
2894 +
2895 + if (!htab->symbols_adjusted)
2896 + if (!adjust_syms(info))
2897 + return FALSE;
2898 +
2899 + if (rd->is_relaxable)
2900 + {
2901 + /* Resize the section first, so that we can be sure that enough
2902 + memory is allocated in case the section has grown. */
2903 + if (sec->size > sec->rawsize
2904 + && elf_section_data(sec)->this_hdr.contents)
2905 + {
2906 + /* We must not use cached data if the section has grown. */
2907 + free(elf_section_data(sec)->this_hdr.contents);
2908 + elf_section_data(sec)->this_hdr.contents = NULL;
2909 + }
2910 +
2911 + relocs = retrieve_internal_relocs(abfd, sec, info->keep_memory);
2912 + if (!relocs)
2913 + goto out;
2914 + contents = retrieve_contents(abfd, sec, info->keep_memory);
2915 + if (!contents)
2916 + goto out;
2917 +
2918 + fragend = rd->frag + rd->frag_count;
2919 +
2920 + RDBG("move_data: %s<%s>: relocs=%p, contents=%p\n",
2921 + abfd->filename, sec->name, relocs, contents);
2922 +
2923 + /* First, move the data into place. We must take care to move
2924 + frags in the right order so that we don't accidentally
2925 + overwrite parts of the next frag. */
2926 + for (frag = rd->frag; frag < fragend; frag++)
2927 + {
2928 + RDBG(" 0x%08lx%c0x%x: size 0x%lx%c0x%x\n",
2929 + frag->offset, frag->offset_adjust >= 0 ? '+' : '-',
2930 + abs(frag->offset_adjust),
2931 + frag->size, frag->size_adjust >= 0 ? '+' : '-',
2932 + abs(frag->size_adjust));
2933 + if (frag->offset_adjust > 0)
2934 + {
2935 + struct fragment *prev = frag - 1;
2936 + struct fragment *last;
2937 +
2938 + for (last = frag; last < fragend && last->offset_adjust > 0;
2939 + last++) ;
2940 +
2941 + if (last == fragend)
2942 + last--;
2943 +
2944 + for (frag = last; frag != prev; frag--)
2945 + {
2946 + if (frag->offset_adjust
2947 + && frag->size + frag->size_adjust > 0)
2948 + {
2949 + RDBG("memmove 0x%lx -> 0x%lx (size %lu)\n",
2950 + frag->offset, frag->offset + frag->offset_adjust,
2951 + frag->size + frag->size_adjust);
2952 + memmove(contents + frag->offset + frag->offset_adjust,
2953 + contents + frag->offset,
2954 + frag->size + frag->size_adjust);
2955 + }
2956 + }
2957 + frag = last;
2958 + }
2959 + else if (frag->offset_adjust && frag->size + frag->size_adjust > 0)
2960 + {
2961 + RDBG("memmove 0x%lx -> 0x%lx (size %lu)\n",
2962 + frag->offset, frag->offset + frag->offset_adjust,
2963 + frag->size + frag->size_adjust);
2964 + memmove(contents + frag->offset + frag->offset_adjust,
2965 + contents + frag->offset,
2966 + frag->size + frag->size_adjust);
2967 + }
2968 + }
2969 +
2970 + i = 0;
2971 +
2972 + for (frag = rd->frag; frag < fragend; frag++)
2973 + {
2974 + const struct relax_state *state, *istate;
2975 + struct avr32_reloc_data *r_data = NULL;
2976 +
2977 + istate = &relax_state[frag->initial_state];
2978 + state = &relax_state[frag->state];
2979 +
2980 + if (rd->reloc_data)
2981 + r_data = &rd->reloc_data[frag->rela - relocs];
2982 +
2983 + BFD_ASSERT((long)(frag->size + frag->size_adjust) >= 0);
2984 + BFD_ASSERT(state->reftype != REF_CPOOL
2985 + || r_data->add_frag->refcount > 0);
2986 +
2987 + if (istate->reftype == REF_CPOOL && state->reftype != REF_CPOOL)
2988 + {
2989 + struct fragment *ifrag;
2990 +
2991 + /* An indirect reference through the cpool has been
2992 + converted to a direct reference. We must update the
2993 + reloc to point to the symbol itself instead of the
2994 + constant pool entry. The reloc type will be updated
2995 + later. */
2996 + ifrag = r_data->add_frag;
2997 + frag->rela->r_info = ifrag->rela->r_info;
2998 + frag->rela->r_addend = ifrag->rela->r_addend;
2999 +
3000 + /* Copy the reloc data so the addend will be adjusted
3001 + correctly later. */
3002 + *r_data = rd->reloc_data[ifrag->rela - relocs];
3003 + }
3004 +
3005 + /* Move all relocs covered by this frag. */
3006 + if (frag->rela)
3007 + BFD_ASSERT(&relocs[i] <= frag->rela);
3008 + else
3009 + BFD_ASSERT((frag + 1) == fragend && frag->state == RS_NONE);
3010 +
3011 + if (frag == rd->frag)
3012 + BFD_ASSERT(i == 0);
3013 + else
3014 + BFD_ASSERT(&relocs[i] > frag[-1].rela);
3015 +
3016 + /* If non-null, frag->rela is the last relocation in the
3017 + fragment. frag->rela can only be null in the last
3018 + fragment, so in that case, we'll just do the rest. */
3019 + for (; (i < sec->reloc_count
3020 + && (!frag->rela || &relocs[i] <= frag->rela)); i++)
3021 + {
3022 + RDBG("[%4u] r_offset 0x%08lx -> 0x%08lx\n", i, relocs[i].r_offset,
3023 + relocs[i].r_offset + frag->offset_adjust);
3024 + relocs[i].r_offset += frag->offset_adjust;
3025 + }
3026 +
3027 + if (frag->refcount == 0)
3028 + {
3029 + /* If this frag is to be discarded, make sure we won't
3030 + relocate it later on. */
3031 + BFD_ASSERT(frag->state == RS_CPENT);
3032 + frag->rela->r_info = ELF_R_INFO(ELF_R_SYM(frag->rela->r_info),
3033 + R_AVR32_NONE);
3034 + }
3035 + else if (frag->state == RS_ALIGN)
3036 + {
3037 + bfd_vma addr, addr_end;
3038 +
3039 + addr = frag->rela->r_offset;
3040 + addr_end = (frag->offset + frag->offset_adjust
3041 + + frag->size + frag->size_adjust);
3042 +
3043 + /* If the section is executable, insert NOPs.
3044 + Otherwise, insert zeroes. */
3045 + if (sec->flags & SEC_CODE)
3046 + {
3047 + if (addr & 1)
3048 + {
3049 + bfd_put_8(abfd, 0, contents + addr);
3050 + addr++;
3051 + }
3052 +
3053 + BFD_ASSERT(!((addr_end - addr) & 1));
3054 +
3055 + while (addr < addr_end)
3056 + {
3057 + bfd_put_16(abfd, NOP_OPCODE, contents + addr);
3058 + addr += 2;
3059 + }
3060 + }
3061 + else
3062 + memset(contents + addr, 0, addr_end - addr);
3063 + }
3064 + else if (state->opcode_mask)
3065 + {
3066 + bfd_vma insn;
3067 +
3068 + /* Update the opcode and the relocation type unless it's a
3069 + "special" relax state (i.e. RS_NONE, RS_ALIGN or
3070 + RS_CPENT.), in which case the opcode mask is zero. */
3071 + insn = bfd_get_32(abfd, contents + frag->rela->r_offset);
3072 + insn &= ~state->opcode_mask;
3073 + insn |= state->opcode;
3074 + RDBG(" 0x%lx: inserting insn %08lx\n",
3075 + frag->rela->r_offset, insn);
3076 + bfd_put_32(abfd, insn, contents + frag->rela->r_offset);
3077 +
3078 + frag->rela->r_info = ELF_R_INFO(ELF_R_SYM(frag->rela->r_info),
3079 + state->r_type);
3080 + }
3081 +
3082 + if ((frag + 1) == fragend)
3083 + BFD_ASSERT((frag->offset + frag->size + frag->offset_adjust
3084 + + frag->size_adjust) == sec->size);
3085 + else
3086 + BFD_ASSERT((frag->offset + frag->size + frag->offset_adjust
3087 + + frag->size_adjust)
3088 + == (frag[1].offset + frag[1].offset_adjust));
3089 + }
3090 + }
3091 +
3092 + /* Adjust reloc addends and DIFF32 differences */
3093 + if (!adjust_relocs(abfd, sec, info))
3094 + return FALSE;
3095 +
3096 + ret = TRUE;
3097 +
3098 + out:
3099 + release_contents(sec, contents);
3100 + release_internal_relocs(sec, relocs);
3101 + return ret;
3102 +}
3103 +
3104 +static bfd_boolean
3105 +avr32_elf_relax_section(bfd *abfd, asection *sec,
3106 + struct bfd_link_info *info, bfd_boolean *again)
3107 +{
3108 + struct elf_avr32_link_hash_table *htab;
3109 + struct avr32_relax_data *rd;
3110 +
3111 + *again = FALSE;
3112 + if (info->relocatable)
3113 + return TRUE;
3114 +
3115 + htab = avr32_elf_hash_table(info);
3116 + if ((!(sec->flags & SEC_RELOC) || sec->reloc_count == 0)
3117 + && sec != htab->sgot)
3118 + return TRUE;
3119 +
3120 + if (!htab->relocations_analyzed)
3121 + {
3122 + if (!analyze_relocations(info))
3123 + return FALSE;
3124 + htab->relocations_analyzed = TRUE;
3125 + }
3126 +
3127 + rd = avr32_relax_data(sec);
3128 +
3129 + if (rd->iteration != htab->relax_iteration)
3130 + {
3131 + if (!htab->repeat_pass)
3132 + htab->relax_pass++;
3133 + htab->relax_iteration++;
3134 + htab->repeat_pass = FALSE;
3135 + }
3136 +
3137 + rd->iteration++;
3138 +
3139 + switch (htab->relax_pass)
3140 + {
3141 + case RELAX_PASS_SIZE_FRAGS:
3142 + if (!avr32_size_frags(abfd, sec, info))
3143 + return FALSE;
3144 + *again = TRUE;
3145 + break;
3146 + case RELAX_PASS_MOVE_DATA:
3147 + if (!avr32_move_data(abfd, sec, info))
3148 + return FALSE;
3149 + break;
3150 + }
3151 +
3152 + return TRUE;
3153 +}
3154 +
3155 +
3156 +/* Relocation */
3157 +
3158 +static bfd_reloc_status_type
3159 +avr32_check_reloc_value(asection *sec, Elf_Internal_Rela *rela,
3160 + bfd_signed_vma relocation, reloc_howto_type *howto);
3161 +static bfd_reloc_status_type
3162 +avr32_final_link_relocate(reloc_howto_type *howto, bfd *input_bfd,
3163 + asection *input_section, bfd_byte *contents,
3164 + Elf_Internal_Rela *rel, bfd_vma value);
3165 +static bfd_boolean
3166 +avr32_elf_relocate_section(bfd *output_bfd, struct bfd_link_info *info,
3167 + bfd *input_bfd, asection *input_section,
3168 + bfd_byte *contents, Elf_Internal_Rela *relocs,
3169 + Elf_Internal_Sym *local_syms,
3170 + asection **local_sections);
3171 +
3172 +
3173 +#define symbol_address(symbol) \
3174 + symbol->value + symbol->section->output_section->vma \
3175 + + symbol->section->output_offset
3176 +
3177 +#define avr32_elf_insert_field(size, field, abfd, reloc_entry, data) \
3178 + do \
3179 + { \
3180 + unsigned long x; \
3181 + x = bfd_get_##size (abfd, data + reloc_entry->address); \
3182 + x &= ~reloc_entry->howto->dst_mask; \
3183 + x |= field & reloc_entry->howto->dst_mask; \
3184 + bfd_put_##size (abfd, (bfd_vma) x, data + reloc_entry->address); \
3185 + } \
3186 + while(0)
3187 +
3188 +static bfd_reloc_status_type
3189 +avr32_check_reloc_value(asection *sec ATTRIBUTE_UNUSED,
3190 + Elf_Internal_Rela *rela ATTRIBUTE_UNUSED,
3191 + bfd_signed_vma relocation,
3192 + reloc_howto_type *howto)
3193 +{
3194 + bfd_vma reloc_u;
3195 +
3196 + /* We take "complain_overflow_dont" to mean "don't complain on
3197 + alignment either". This way, we don't have to special-case
3198 + R_AVR32_HI16 */
3199 + if (howto->complain_on_overflow == complain_overflow_dont)
3200 + return bfd_reloc_ok;
3201 +
3202 + /* Check if the value is correctly aligned */
3203 + if (relocation & ((1 << howto->rightshift) - 1))
3204 + {
3205 + RDBG("misaligned: %s<%s+%lx>: %s: 0x%lx (align %u)\n",
3206 + sec->owner->filename, sec->name, rela->r_offset,
3207 + howto->name, relocation, howto->rightshift);
3208 + return bfd_reloc_overflow;
3209 + }
3210 +
3211 + /* Now, get rid of the unnecessary bits */
3212 + relocation >>= howto->rightshift;
3213 + reloc_u = (bfd_vma)relocation;
3214 +
3215 + switch (howto->complain_on_overflow)
3216 + {
3217 + case complain_overflow_unsigned:
3218 + case complain_overflow_bitfield:
3219 + if (reloc_u > (unsigned long)((1 << howto->bitsize) - 1))
3220 + {
3221 + RDBG("unsigned overflow: %s<%s+%lx>: %s: 0x%lx (size %u)\n",
3222 + sec->owner->filename, sec->name, rela->r_offset,
3223 + howto->name, reloc_u, howto->bitsize);
3224 + RDBG("reloc vma: 0x%lx\n",
3225 + sec->output_section->vma + sec->output_offset + rela->r_offset);
3226 +
3227 + return bfd_reloc_overflow;
3228 + }
3229 + break;
3230 + case complain_overflow_signed:
3231 + if (relocation > (1 << (howto->bitsize - 1)) - 1)
3232 + {
3233 + RDBG("signed overflow: %s<%s+%lx>: %s: 0x%lx (size %u)\n",
3234 + sec->owner->filename, sec->name, rela->r_offset,
3235 + howto->name, reloc_u, howto->bitsize);
3236 + RDBG("reloc vma: 0x%lx\n",
3237 + sec->output_section->vma + sec->output_offset + rela->r_offset);
3238 +
3239 + return bfd_reloc_overflow;
3240 + }
3241 + if (relocation < -(1 << (howto->bitsize - 1)))
3242 + {
3243 + RDBG("signed overflow: %s<%s+%lx>: %s: -0x%lx (size %u)\n",
3244 + sec->owner->filename, sec->name, rela->r_offset,
3245 + howto->name, -relocation, howto->bitsize);
3246 + RDBG("reloc vma: 0x%lx\n",
3247 + sec->output_section->vma + sec->output_offset + rela->r_offset);
3248 +
3249 + return bfd_reloc_overflow;
3250 + }
3251 + break;
3252 + default:
3253 + abort();
3254 + }
3255 +
3256 + return bfd_reloc_ok;
3257 +}
3258 +
3259 +
3260 +static bfd_reloc_status_type
3261 +avr32_final_link_relocate(reloc_howto_type *howto,
3262 + bfd *input_bfd,
3263 + asection *input_section,
3264 + bfd_byte *contents,
3265 + Elf_Internal_Rela *rel,
3266 + bfd_vma value)
3267 +{
3268 + bfd_vma field;
3269 + bfd_vma relocation;
3270 + bfd_reloc_status_type status;
3271 + bfd_byte *p = contents + rel->r_offset;
3272 + unsigned long x;
3273 +
3274 + pr_debug(" (6b) final link relocate\n");
3275 +
3276 + /* Sanity check the address */
3277 + if (rel->r_offset > input_section->size)
3278 + {
3279 + (*_bfd_error_handler)
3280 + ("%B: %A+0x%lx: offset out of range (section size: 0x%lx)",
3281 + input_bfd, input_section, rel->r_offset, input_section->size);
3282 + return bfd_reloc_outofrange;
3283 + }
3284 +
3285 + relocation = value + rel->r_addend;
3286 +
3287 + if (howto->pc_relative)
3288 + {
3289 + bfd_vma addr;
3290 +
3291 + addr = input_section->output_section->vma
3292 + + input_section->output_offset + rel->r_offset;
3293 + addr &= ~0UL << howto->rightshift;
3294 + relocation -= addr;
3295 + }
3296 +
3297 + switch (ELF32_R_TYPE(rel->r_info))
3298 + {
3299 + case R_AVR32_16N_PCREL:
3300 + /* sub reg, pc, . - (sym + addend) */
3301 + relocation = -relocation;
3302 + break;
3303 + }
3304 +
3305 + status = avr32_check_reloc_value(input_section, rel, relocation, howto);
3306 +
3307 + relocation >>= howto->rightshift;
3308 + if (howto->bitsize == 21)
3309 + field = (relocation & 0xffff)
3310 + | ((relocation & 0x10000) << 4)
3311 + | ((relocation & 0x1e0000) << 8);
3312 + else if (howto->bitsize == 12)
3313 + field = (relocation & 0xff) | ((relocation & 0xf00) << 4);
3314 + else if (howto->bitsize == 10)
3315 + field = ((relocation & 0xff) << 4)
3316 + | ((relocation & 0x300) >> 8);
3317 + else
3318 + field = relocation << howto->bitpos;
3319 +
3320 + switch (howto->size)
3321 + {
3322 + case 0:
3323 + x = bfd_get_8 (input_bfd, p);
3324 + x &= ~howto->dst_mask;
3325 + x |= field & howto->dst_mask;
3326 + bfd_put_8 (input_bfd, (bfd_vma) x, p);
3327 + break;
3328 + case 1:
3329 + x = bfd_get_16 (input_bfd, p);
3330 + x &= ~howto->dst_mask;
3331 + x |= field & howto->dst_mask;
3332 + bfd_put_16 (input_bfd, (bfd_vma) x, p);
3333 + break;
3334 + case 2:
3335 + x = bfd_get_32 (input_bfd, p);
3336 + x &= ~howto->dst_mask;
3337 + x |= field & howto->dst_mask;
3338 + bfd_put_32 (input_bfd, (bfd_vma) x, p);
3339 + break;
3340 + default:
3341 + abort();
3342 + }
3343 +
3344 + return status;
3345 +}
3346 +
3347 +/* (6) Apply relocations to the normal (non-dynamic) sections */
3348 +
3349 +static bfd_boolean
3350 +avr32_elf_relocate_section(bfd *output_bfd, struct bfd_link_info *info,
3351 + bfd *input_bfd, asection *input_section,
3352 + bfd_byte *contents, Elf_Internal_Rela *relocs,
3353 + Elf_Internal_Sym *local_syms,
3354 + asection **local_sections)
3355 +{
3356 + struct elf_avr32_link_hash_table *htab;
3357 + Elf_Internal_Shdr *symtab_hdr;
3358 + Elf_Internal_Rela *rel, *relend;
3359 + struct elf_link_hash_entry **sym_hashes;
3360 + struct got_entry **local_got_ents;
3361 + asection *sgot;
3362 + asection *srelgot;
3363 +
3364 + pr_debug("(6) relocate section %s:<%s> (size 0x%lx)\n",
3365 + input_bfd->filename, input_section->name, input_section->size);
3366 +
3367 + /* If we're doing a partial link, we don't have to do anything since
3368 + we're using RELA relocations */
3369 + if (info->relocatable)
3370 + return TRUE;
3371 +
3372 + htab = avr32_elf_hash_table(info);
3373 + symtab_hdr = &elf_tdata(input_bfd)->symtab_hdr;
3374 + sym_hashes = elf_sym_hashes(input_bfd);
3375 + local_got_ents = elf_local_got_ents(input_bfd);
3376 + sgot = htab->sgot;
3377 + srelgot = htab->srelgot;
3378 +
3379 + relend = relocs + input_section->reloc_count;
3380 + for (rel = relocs; rel < relend; rel++)
3381 + {
3382 + unsigned long r_type, r_symndx;
3383 + reloc_howto_type *howto;
3384 + Elf_Internal_Sym *sym = NULL;
3385 + struct elf_link_hash_entry *h = NULL;
3386 + asection *sec = NULL;
3387 + bfd_vma value;
3388 + bfd_vma offset;
3389 + bfd_reloc_status_type status;
3390 +
3391 + r_type = ELF32_R_TYPE(rel->r_info);
3392 + r_symndx = ELF32_R_SYM(rel->r_info);
3393 +
3394 + if (r_type == R_AVR32_NONE
3395 + || r_type == R_AVR32_ALIGN
3396 + || r_type == R_AVR32_DIFF32
3397 + || r_type == R_AVR32_DIFF16
3398 + || r_type == R_AVR32_DIFF8)
3399 + continue;
3400 +
3401 + /* Sanity check */
3402 + if (r_type > R_AVR32_max)
3403 + {
3404 + bfd_set_error(bfd_error_bad_value);
3405 + return FALSE;
3406 + }
3407 +
3408 + howto = &elf_avr32_howto_table[r_type];
3409 +
3410 + if (r_symndx < symtab_hdr->sh_info)
3411 + {
3412 + sym = local_syms + r_symndx;
3413 + sec = local_sections[r_symndx];
3414 +
3415 + pr_debug(" (6a) processing %s against local symbol %lu\n",
3416 + howto->name, r_symndx);
3417 +
3418 + /* The following function changes rel->r_addend behind our back. */
3419 + value = _bfd_elf_rela_local_sym(output_bfd, sym, &sec, rel);
3420 + pr_debug(" => value: %lx, addend: %lx\n", value, rel->r_addend);
3421 + }
3422 + else
3423 + {
3424 + if (sym_hashes == NULL)
3425 + return FALSE;
3426 +
3427 + h = sym_hashes[r_symndx - symtab_hdr->sh_info];
3428 + while (h->root.type == bfd_link_hash_indirect
3429 + || h->root.type == bfd_link_hash_warning)
3430 + h = (struct elf_link_hash_entry *)h->root.u.i.link;
3431 +
3432 + pr_debug(" (6a) processing %s against symbol %s\n",
3433 + howto->name, h->root.root.string);
3434 +
3435 + if (h->root.type == bfd_link_hash_defined
3436 + || h->root.type == bfd_link_hash_defweak)
3437 + {
3438 + bfd_boolean dyn;
3439 +
3440 + dyn = htab->root.dynamic_sections_created;
3441 + sec = h->root.u.def.section;
3442 +
3443 + if (sec->output_section)
3444 + value = (h->root.u.def.value
3445 + + sec->output_section->vma
3446 + + sec->output_offset);
3447 + else
3448 + value = h->root.u.def.value;
3449 + }
3450 + else if (h->root.type == bfd_link_hash_undefweak)
3451 + value = 0;
3452 + else if (info->unresolved_syms_in_objects == RM_IGNORE
3453 + && ELF_ST_VISIBILITY(h->other) == STV_DEFAULT)
3454 + value = 0;
3455 + else
3456 + {
3457 + bfd_boolean err;
3458 + err = (info->unresolved_syms_in_objects == RM_GENERATE_ERROR
3459 + || ELF_ST_VISIBILITY(h->other) != STV_DEFAULT);
3460 + if (!info->callbacks->undefined_symbol
3461 + (info, h->root.root.string, input_bfd,
3462 + input_section, rel->r_offset, err))
3463 + return FALSE;
3464 + value = 0;
3465 + }
3466 +
3467 + pr_debug(" => value: %lx, addend: %lx\n", value, rel->r_addend);
3468 + }
3469 +
3470 + switch (r_type)
3471 + {
3472 + case R_AVR32_GOT32:
3473 + case R_AVR32_GOT16:
3474 + case R_AVR32_GOT8:
3475 + case R_AVR32_GOT21S:
3476 + case R_AVR32_GOT18SW:
3477 + case R_AVR32_GOT16S:
3478 + case R_AVR32_GOT7UW:
3479 + case R_AVR32_LDA_GOT:
3480 + case R_AVR32_GOTCALL:
3481 + BFD_ASSERT(sgot != NULL);
3482 +
3483 + if (h != NULL)
3484 + {
3485 + BFD_ASSERT(h->got.glist->refcount > 0);
3486 + offset = h->got.glist->offset;
3487 +
3488 + BFD_ASSERT(offset < sgot->size);
3489 + if (!elf_hash_table(info)->dynamic_sections_created
3490 + || (h->def_regular
3491 + && (!info->shared
3492 + || info->symbolic
3493 + || h->dynindx == -1)))
3494 + {
3495 + /* This is actually a static link, or it is a
3496 + -Bsymbolic link and the symbol is defined
3497 + locally, or the symbol was forced to be local. */
3498 + bfd_put_32(output_bfd, value, sgot->contents + offset);
3499 + }
3500 + }
3501 + else
3502 + {
3503 + BFD_ASSERT(local_got_ents &&
3504 + local_got_ents[r_symndx]->refcount > 0);
3505 + offset = local_got_ents[r_symndx]->offset;
3506 +
3507 + /* Local GOT entries don't have relocs. If this is a
3508 + shared library, the dynamic linker will add the load
3509 + address to the initial value at startup. */
3510 + BFD_ASSERT(offset < sgot->size);
3511 + pr_debug("Initializing GOT entry at offset %lu: 0x%lx\n",
3512 + offset, value);
3513 + bfd_put_32 (output_bfd, value, sgot->contents + offset);
3514 + }
3515 +
3516 + value = sgot->output_offset + offset;
3517 + pr_debug("GOT reference: New value %lx\n", value);
3518 + break;
3519 +
3520 + case R_AVR32_GOTPC:
3521 + /* This relocation type is for constant pool entries used in
3522 + the calculation "Rd = PC - (PC - GOT)", where the
3523 + constant pool supplies the constant (PC - GOT)
3524 + offset. The symbol value + addend indicates where the
3525 + value of PC is taken. */
3526 + value -= sgot->output_section->vma;
3527 + break;
3528 +
3529 + case R_AVR32_32_PCREL:
3530 + /* We must adjust r_offset to account for discarded data in
3531 + the .eh_frame section. This is probably not the right
3532 + way to do this, since AFAICS all other architectures do
3533 + it some other way. I just can't figure out how... */
3534 + {
3535 + bfd_vma r_offset;
3536 +
3537 + r_offset = _bfd_elf_section_offset(output_bfd, info,
3538 + input_section,
3539 + rel->r_offset);
3540 + if (r_offset == (bfd_vma)-1
3541 + || r_offset == (bfd_vma)-2)
3542 + continue;
3543 + rel->r_offset = r_offset;
3544 + }
3545 + break;
3546 +
3547 + case R_AVR32_32:
3548 + /* We need to emit a run-time relocation in the following cases:
3549 + - we're creating a shared library
3550 + - the symbol is not defined in any regular objects
3551 +
3552 + Of course, sections that aren't going to be part of the
3553 + run-time image will not get any relocs, and undefined
3554 + symbols won't have any either (only weak undefined
3555 + symbols should get this far). */
3556 + if ((info->shared
3557 + || (elf_hash_table(info)->dynamic_sections_created
3558 + && h != NULL
3559 + && h->def_dynamic
3560 + && !h->def_regular))
3561 + && r_symndx != 0
3562 + && (input_section->flags & SEC_ALLOC))
3563 + {
3564 + Elf_Internal_Rela outrel;
3565 + bfd_byte *loc;
3566 + bfd_boolean skip, relocate;
3567 + struct elf_avr32_link_hash_entry *avrh;
3568 +
3569 + pr_debug("Going to generate dynamic reloc...\n");
3570 +
3571 + skip = FALSE;
3572 + relocate = FALSE;
3573 +
3574 + outrel.r_offset = _bfd_elf_section_offset(output_bfd, info,
3575 + input_section,
3576 + rel->r_offset);
3577 + if (outrel.r_offset == (bfd_vma)-1)
3578 + skip = TRUE;
3579 + else if (outrel.r_offset == (bfd_vma)-2)
3580 + skip = TRUE, relocate = TRUE;
3581 +
3582 + outrel.r_offset += (input_section->output_section->vma
3583 + + input_section->output_offset);
3584 +
3585 + pr_debug(" ... offset %lx, dynindx %ld\n",
3586 + outrel.r_offset, h ? h->dynindx : -1);
3587 +
3588 + if (skip)
3589 + memset(&outrel, 0, sizeof(outrel));
3590 + else
3591 + {
3592 + avrh = (struct elf_avr32_link_hash_entry *)h;
3593 + /* h->dynindx may be -1 if this symbol was marked to
3594 + become local. */
3595 + if (h == NULL
3596 + || ((info->symbolic || h->dynindx == -1)
3597 + && h->def_regular))
3598 + {
3599 + relocate = TRUE;
3600 + outrel.r_info = ELF32_R_INFO(0, R_AVR32_RELATIVE);
3601 + outrel.r_addend = value + rel->r_addend;
3602 + pr_debug(" ... R_AVR32_RELATIVE\n");
3603 + }
3604 + else
3605 + {
3606 + BFD_ASSERT(h->dynindx != -1);
3607 + relocate = TRUE;
3608 + outrel.r_info = ELF32_R_INFO(h->dynindx, R_AVR32_GLOB_DAT);
3609 + outrel.r_addend = rel->r_addend;
3610 + pr_debug(" ... R_AVR32_GLOB_DAT\n");
3611 + }
3612 + }
3613 +
3614 + pr_debug("srelgot reloc_count: %d, size %lu\n",
3615 + srelgot->reloc_count, srelgot->size);
3616 +
3617 + loc = srelgot->contents;
3618 + loc += srelgot->reloc_count++ * sizeof(Elf32_External_Rela);
3619 + bfd_elf32_swap_reloca_out(output_bfd, &outrel, loc);
3620 +
3621 + BFD_ASSERT(srelgot->reloc_count * sizeof(Elf32_External_Rela)
3622 + <= srelgot->size);
3623 +
3624 + if (!relocate)
3625 + continue;
3626 + }
3627 + break;
3628 + }
3629 +
3630 + status = avr32_final_link_relocate(howto, input_bfd, input_section,
3631 + contents, rel, value);
3632 +
3633 + switch (status)
3634 + {
3635 + case bfd_reloc_ok:
3636 + break;
3637 +
3638 + case bfd_reloc_overflow:
3639 + {
3640 + const char *name;
3641 +
3642 + if (h != NULL)
3643 + name = h->root.root.string;
3644 + else
3645 + {
3646 + name = bfd_elf_string_from_elf_section(input_bfd,
3647 + symtab_hdr->sh_link,
3648 + sym->st_name);
3649 + if (name == NULL)
3650 + return FALSE;
3651 + if (*name == '\0')
3652 + name = bfd_section_name(input_bfd, sec);
3653 + }
3654 + if (!((*info->callbacks->reloc_overflow)
3655 + (info, (h ? &h->root : NULL), name, howto->name,
3656 + rel->r_addend, input_bfd, input_section, rel->r_offset)))
3657 + return FALSE;
3658 + }
3659 + break;
3660 +
3661 + case bfd_reloc_outofrange:
3662 + default:
3663 + abort();
3664 + }
3665 + }
3666 +
3667 + return TRUE;
3668 +}
3669 +
3670 +
3671 +/* Additional processing of dynamic sections after relocation */
3672 +
3673 +static bfd_boolean
3674 +avr32_elf_finish_dynamic_symbol(bfd *output_bfd, struct bfd_link_info *info,
3675 + struct elf_link_hash_entry *h,
3676 + Elf_Internal_Sym *sym);
3677 +static bfd_boolean
3678 +avr32_elf_finish_dynamic_sections(bfd *output_bfd, struct bfd_link_info *info);
3679 +
3680 +
3681 +/* (7) Initialize the contents of a dynamic symbol and/or emit
3682 + relocations for it */
3683 +
3684 +static bfd_boolean
3685 +avr32_elf_finish_dynamic_symbol(bfd *output_bfd, struct bfd_link_info *info,
3686 + struct elf_link_hash_entry *h,
3687 + Elf_Internal_Sym *sym)
3688 +{
3689 + struct elf_avr32_link_hash_table *htab;
3690 + struct got_entry *got;
3691 +
3692 + pr_debug("(7) finish dynamic symbol: %s\n", h->root.root.string);
3693 +
3694 + htab = avr32_elf_hash_table(info);
3695 + got = h->got.glist;
3696 +
3697 + if (got && got->refcount > 0)
3698 + {
3699 + asection *sgot;
3700 + asection *srelgot;
3701 + Elf_Internal_Rela rel;
3702 + bfd_byte *loc;
3703 +
3704 + /* This symbol has an entry in the GOT. Set it up. */
3705 + sgot = htab->sgot;
3706 + srelgot = htab->srelgot;
3707 + BFD_ASSERT(sgot && srelgot);
3708 +
3709 + rel.r_offset = (sgot->output_section->vma
3710 + + sgot->output_offset
3711 + + got->offset);
3712 +
3713 + /* If this is a static link, or it is a -Bsymbolic link and the
3714 + symbol is defined locally or was forced to be local because
3715 + of a version file, we just want to emit a RELATIVE reloc. The
3716 + entry in the global offset table will already have been
3717 + initialized in the relocate_section function. */
3718 + if ((info->shared
3719 + && !info->symbolic
3720 + && h->dynindx != -1)
3721 + || (htab->root.dynamic_sections_created
3722 + && h->def_dynamic
3723 + && !h->def_regular))
3724 + {
3725 + bfd_put_32(output_bfd, 0, sgot->contents + got->offset);
3726 + rel.r_info = ELF32_R_INFO(h->dynindx, R_AVR32_GLOB_DAT);
3727 + rel.r_addend = 0;
3728 +
3729 + pr_debug("GOT reloc R_AVR32_GLOB_DAT, dynindx: %ld\n", h->dynindx);
3730 + pr_debug(" srelgot reloc_count: %d, size: %lu\n",
3731 + srelgot->reloc_count, srelgot->size);
3732 +
3733 + loc = (srelgot->contents
3734 + + srelgot->reloc_count++ * sizeof(Elf32_External_Rela));
3735 + bfd_elf32_swap_reloca_out(output_bfd, &rel, loc);
3736 +
3737 + BFD_ASSERT(srelgot->reloc_count * sizeof(Elf32_External_Rela)
3738 + <= srelgot->size);
3739 + }
3740 + }
3741 +
3742 + /* Mark _DYNAMIC and _GLOBAL_OFFSET_TABLE_ as absolute */
3743 + if (strcmp(h->root.root.string, "_DYNAMIC") == 0
3744 + || strcmp(h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
3745 + sym->st_shndx = SHN_ABS;
3746 +
3747 + return TRUE;
3748 +}
3749 +
3750 +/* (8) Do any remaining initialization of the dynamic sections */
3751 +
3752 +static bfd_boolean
3753 +avr32_elf_finish_dynamic_sections(bfd *output_bfd, struct bfd_link_info *info)
3754 +{
3755 + struct elf_avr32_link_hash_table *htab;
3756 + asection *sgot, *sdyn;
3757 +
3758 + pr_debug("(8) finish dynamic sections\n");
3759 +
3760 + htab = avr32_elf_hash_table(info);
3761 + sgot = htab->sgot;
3762 + sdyn = bfd_get_section_by_name(htab->root.dynobj, ".dynamic");
3763 +
3764 + if (htab->root.dynamic_sections_created)
3765 + {
3766 + Elf32_External_Dyn *dyncon, *dynconend;
3767 +
3768 + BFD_ASSERT(sdyn && sgot && sgot->size >= AVR32_GOT_HEADER_SIZE);
3769 +
3770 + dyncon = (Elf32_External_Dyn *)sdyn->contents;
3771 + dynconend = (Elf32_External_Dyn *)(sdyn->contents + sdyn->size);
3772 + for (; dyncon < dynconend; dyncon++)
3773 + {
3774 + Elf_Internal_Dyn dyn;
3775 + asection *s;
3776 +
3777 + bfd_elf32_swap_dyn_in(htab->root.dynobj, dyncon, &dyn);
3778 +
3779 + switch (dyn.d_tag)
3780 + {
3781 + default:
3782 + break;
3783 +
3784 + case DT_PLTGOT:
3785 + s = sgot->output_section;
3786 + BFD_ASSERT(s != NULL);
3787 + dyn.d_un.d_ptr = s->vma;
3788 + bfd_elf32_swap_dyn_out(output_bfd, &dyn, dyncon);
3789 + break;
3790 +
3791 + case DT_AVR32_GOTSZ:
3792 + s = sgot->output_section;
3793 + BFD_ASSERT(s != NULL);
3794 + dyn.d_un.d_val = s->size;
3795 + bfd_elf32_swap_dyn_out(output_bfd, &dyn, dyncon);
3796 + break;
3797 + }
3798 + }
3799 +
3800 + /* Fill in the first two entries in the global offset table */
3801 + bfd_put_32(output_bfd,
3802 + sdyn->output_section->vma + sdyn->output_offset,
3803 + sgot->contents);
3804 +
3805 + /* The runtime linker will fill this one in with the address of
3806 + the run-time link map */
3807 + bfd_put_32(output_bfd, 0, sgot->contents + 4);
3808 + }
3809 +
3810 + if (sgot)
3811 + elf_section_data(sgot->output_section)->this_hdr.sh_entsize = 4;
3812 +
3813 + return TRUE;
3814 +}
3815 +
3816 +
3817 +/* AVR32-specific private ELF data */
3818 +
3819 +static bfd_boolean
3820 +avr32_elf_set_private_flags(bfd *abfd, flagword flags);
3821 +static bfd_boolean
3822 +avr32_elf_copy_private_bfd_data(bfd *ibfd, bfd *obfd);
3823 +static bfd_boolean
3824 +avr32_elf_merge_private_bfd_data(bfd *ibfd, bfd *obfd);
3825 +static bfd_boolean
3826 +avr32_elf_print_private_bfd_data(bfd *abfd, void *ptr);
3827 +
3828 +static bfd_boolean
3829 +avr32_elf_set_private_flags(bfd *abfd, flagword flags)
3830 +{
3831 + elf_elfheader(abfd)->e_flags = flags;
3832 + elf_flags_init(abfd) = TRUE;
3833 +
3834 + return TRUE;
3835 +}
3836 +
3837 +/* Copy backend specific data from one object module to another. */
3838 +
3839 +static bfd_boolean
3840 +avr32_elf_copy_private_bfd_data(bfd *ibfd, bfd *obfd)
3841 +{
3842 + elf_elfheader(obfd)->e_flags = elf_elfheader(ibfd)->e_flags;
3843 + return TRUE;
3844 +}
3845 +
3846 +/* Merge backend specific data from an object file to the output
3847 + object file when linking. */
3848 +
3849 +static bfd_boolean
3850 +avr32_elf_merge_private_bfd_data(bfd *ibfd, bfd *obfd)
3851 +{
3852 + flagword out_flags, in_flags;
3853 +
3854 + pr_debug("(0) merge_private_bfd_data: %s -> %s\n",
3855 + ibfd->filename, obfd->filename);
3856 +
3857 + in_flags = elf_elfheader(ibfd)->e_flags;
3858 + out_flags = elf_elfheader(obfd)->e_flags;
3859 +
3860 + if (elf_flags_init(obfd))
3861 + {
3862 + /* If one of the inputs are non-PIC, the output must be
3863 + considered non-PIC. The same applies to linkrelax. */
3864 + if (!(in_flags & EF_AVR32_PIC))
3865 + out_flags &= ~EF_AVR32_PIC;
3866 + if (!(in_flags & EF_AVR32_LINKRELAX))
3867 + out_flags &= ~EF_AVR32_LINKRELAX;
3868 + }
3869 + else
3870 + {
3871 + elf_flags_init(obfd) = TRUE;
3872 + out_flags = in_flags;
3873 + }
3874 +
3875 + elf_elfheader(obfd)->e_flags = out_flags;
3876 +
3877 + return TRUE;
3878 +}
3879 +
3880 +static bfd_boolean
3881 +avr32_elf_print_private_bfd_data(bfd *abfd, void *ptr)
3882 +{
3883 + FILE *file = (FILE *)ptr;
3884 + unsigned long flags;
3885 +
3886 + BFD_ASSERT(abfd != NULL && ptr != NULL);
3887 +
3888 + _bfd_elf_print_private_bfd_data(abfd, ptr);
3889 +
3890 + flags = elf_elfheader(abfd)->e_flags;
3891 +
3892 + fprintf(file, _("private flags = %lx:"), elf_elfheader(abfd)->e_flags);
3893 +
3894 + if (flags & EF_AVR32_PIC)
3895 + fprintf(file, " [PIC]");
3896 + if (flags & EF_AVR32_LINKRELAX)
3897 + fprintf(file, " [linker relaxable]");
3898 +
3899 + flags &= ~(EF_AVR32_PIC | EF_AVR32_LINKRELAX);
3900 +
3901 + if (flags)
3902 + fprintf(file, _("<Unrecognized flag bits set>"));
3903 +
3904 + fputc('\n', file);
3905 +
3906 + return TRUE;
3907 +}
3908 +
3909 +/* Set avr32-specific linker options. */
3910 +void bfd_elf32_avr32_set_options(struct bfd_link_info *info,
3911 + int direct_data_refs)
3912 +{
3913 + struct elf_avr32_link_hash_table *htab;
3914 +
3915 + htab = avr32_elf_hash_table (info);
3916 + htab->direct_data_refs = !!direct_data_refs;
3917 +}
3918 +
3919 +
3920 +
3921 +/* Understanding core dumps */
3922 +
3923 +static bfd_boolean
3924 +avr32_elf_grok_prstatus(bfd *abfd, Elf_Internal_Note *note);
3925 +static bfd_boolean
3926 +avr32_elf_grok_psinfo(bfd *abfd, Elf_Internal_Note *note);
3927 +
3928 +static bfd_boolean
3929 +avr32_elf_grok_prstatus(bfd *abfd, Elf_Internal_Note *note)
3930 +{
3931 + /* Linux/AVR32B elf_prstatus */
3932 + if (note->descsz != 148)
3933 + return FALSE;
3934 +
3935 + /* pr_cursig */
3936 + elf_tdata(abfd)->core_signal = bfd_get_16(abfd, note->descdata + 12);
3937 +
3938 + /* pr_pid */
3939 + elf_tdata(abfd)->core_pid = bfd_get_32(abfd, note->descdata + 24);
3940 +
3941 + /* Make a ".reg/999" section for pr_reg. The size is for 16
3942 + general-purpose registers, SR and r12_orig (18 * 4 = 72). */
3943 + return _bfd_elfcore_make_pseudosection(abfd, ".reg", 72,
3944 + note->descpos + 72);
3945 +}
3946 +
3947 +static bfd_boolean
3948 +avr32_elf_grok_psinfo(bfd *abfd, Elf_Internal_Note *note)
3949 +{
3950 + /* Linux/AVR32B elf_prpsinfo */
3951 + if (note->descsz != 128)
3952 + return FALSE;
3953 +
3954 + elf_tdata(abfd)->core_program
3955 + = _bfd_elfcore_strndup(abfd, note->descdata + 32, 16);
3956 + elf_tdata(abfd)->core_command
3957 + = _bfd_elfcore_strndup(abfd, note->descdata + 48, 80);
3958 +
3959 + /* Note that for some reason, a spurious space is tacked
3960 + onto the end of the args in some (at least one anyway)
3961 + implementations, so strip it off if it exists. */
3962 +
3963 + {
3964 + char *command = elf_tdata (abfd)->core_command;
3965 + int n = strlen (command);
3966 +
3967 + if (0 < n && command[n - 1] == ' ')
3968 + command[n - 1] = '\0';
3969 + }
3970 +
3971 + return TRUE;
3972 +}
3973 +
3974 +
3975 +#define ELF_ARCH bfd_arch_avr32
3976 +#define ELF_MACHINE_CODE EM_AVR32
3977 +#define ELF_MAXPAGESIZE 0x1000
3978 +
3979 +#define TARGET_BIG_SYM bfd_elf32_avr32_vec
3980 +#define TARGET_BIG_NAME "elf32-avr32"
3981 +
3982 +#define elf_backend_grok_prstatus avr32_elf_grok_prstatus
3983 +#define elf_backend_grok_psinfo avr32_elf_grok_psinfo
3984 +
3985 +/* Only RELA relocations are used */
3986 +#define elf_backend_may_use_rel_p 0
3987 +#define elf_backend_may_use_rela_p 1
3988 +#define elf_backend_default_use_rela_p 1
3989 +#define elf_backend_rela_normal 1
3990 +#define elf_info_to_howto_rel NULL
3991 +#define elf_info_to_howto avr32_info_to_howto
3992 +
3993 +#define bfd_elf32_bfd_copy_private_bfd_data avr32_elf_copy_private_bfd_data
3994 +#define bfd_elf32_bfd_merge_private_bfd_data avr32_elf_merge_private_bfd_data
3995 +#define bfd_elf32_bfd_set_private_flags avr32_elf_set_private_flags
3996 +#define bfd_elf32_bfd_print_private_bfd_data avr32_elf_print_private_bfd_data
3997 +#define bfd_elf32_new_section_hook avr32_elf_new_section_hook
3998 +
3999 +#define elf_backend_gc_mark_hook avr32_elf_gc_mark_hook
4000 +#define elf_backend_gc_sweep_hook avr32_elf_gc_sweep_hook
4001 +#define elf_backend_relocate_section avr32_elf_relocate_section
4002 +#define elf_backend_copy_indirect_symbol avr32_elf_copy_indirect_symbol
4003 +#define elf_backend_create_dynamic_sections avr32_elf_create_dynamic_sections
4004 +#define bfd_elf32_bfd_link_hash_table_create avr32_elf_link_hash_table_create
4005 +#define elf_backend_adjust_dynamic_symbol avr32_elf_adjust_dynamic_symbol
4006 +#define elf_backend_size_dynamic_sections avr32_elf_size_dynamic_sections
4007 +#define elf_backend_finish_dynamic_symbol avr32_elf_finish_dynamic_symbol
4008 +#define elf_backend_finish_dynamic_sections avr32_elf_finish_dynamic_sections
4009 +
4010 +#define bfd_elf32_bfd_relax_section avr32_elf_relax_section
4011 +
4012 +/* Find out which symbols need an entry in .got. */
4013 +#define elf_backend_check_relocs avr32_check_relocs
4014 +#define elf_backend_can_refcount 1
4015 +#define elf_backend_can_gc_sections 1
4016 +#define elf_backend_plt_readonly 1
4017 +#define elf_backend_plt_not_loaded 1
4018 +#define elf_backend_want_plt_sym 0
4019 +#define elf_backend_plt_alignment 2
4020 +#define elf_backend_want_dynbss 0
4021 +#define elf_backend_want_got_plt 0
4022 +#define elf_backend_want_got_sym 1
4023 +#define elf_backend_got_header_size AVR32_GOT_HEADER_SIZE
4024 +
4025 +#include "elf32-target.h"
4026 --- /dev/null
4027 +++ b/bfd/elf32-avr32.h
4028 @@ -0,0 +1,23 @@
4029 +/* AVR32-specific support for 32-bit ELF.
4030 + Copyright 2007 Atmel Corporation.
4031 +
4032 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
4033 +
4034 + This file is part of BFD, the Binary File Descriptor library.
4035 +
4036 + This program is free software; you can redistribute it and/or modify
4037 + it under the terms of the GNU General Public License as published by
4038 + the Free Software Foundation; either version 2 of the License, or
4039 + (at your option) any later version.
4040 +
4041 + This program is distributed in the hope that it will be useful,
4042 + but WITHOUT ANY WARRANTY; without even the implied warranty of
4043 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
4044 + GNU General Public License for more details.
4045 +
4046 + You should have received a copy of the GNU General Public License
4047 + along with this program; if not, write to the Free Software
4048 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
4049 +
4050 +void bfd_elf32_avr32_set_options(struct bfd_link_info *info,
4051 + int direct_data_refs);
4052 --- a/bfd/elf-bfd.h
4053 +++ b/bfd/elf-bfd.h
4054 @@ -1400,6 +1400,10 @@ struct elf_obj_tdata
4055 find_nearest_line. */
4056 struct mips_elf_find_line *find_line_info;
4057
4058 + /* Used by AVR32 ELF relaxation code. Contains an array of pointers
4059 + for each local symbol to the fragment where it is defined. */
4060 + struct fragment **local_sym_frag;
4061 +
4062 /* A place to stash dwarf1 info for this bfd. */
4063 struct dwarf1_debug *dwarf1_find_line_info;
4064
4065 --- a/bfd/Makefile.am
4066 +++ b/bfd/Makefile.am
4067 @@ -63,6 +63,7 @@ ALL_MACHINES = \
4068 cpu-arc.lo \
4069 cpu-arm.lo \
4070 cpu-avr.lo \
4071 + cpu-avr32.lo \
4072 cpu-bfin.lo \
4073 cpu-cr16.lo \
4074 cpu-cr16c.lo \
4075 @@ -243,6 +244,7 @@ BFD32_BACKENDS = \
4076 elf32-arc.lo \
4077 elf32-arm.lo \
4078 elf32-avr.lo \
4079 + elf32-avr32.lo \
4080 elf32-bfin.lo \
4081 elf32-cr16.lo \
4082 elf32-cr16c.lo \
4083 @@ -1328,6 +1330,10 @@ elf32-cr16.lo: elf32-cr16.c $(INCDIR)/fi
4084 $(INCDIR)/hashtab.h $(INCDIR)/libiberty.h elf-bfd.h \
4085 $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
4086 $(INCDIR)/elf/cr16.h $(INCDIR)/elf/reloc-macros.h elf32-target.h
4087 +elf32-avr32.lo: elf32-avr32.c $(INCDIR)/filenames.h elf-bfd.h \
4088 + $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
4089 + $(INCDIR)/bfdlink.h $(INCDIR)/elf/avr32.h $(INCDIR)/elf/reloc-macros.h \
4090 + elf32-target.h
4091 elf32-cr16c.lo: elf32-cr16c.c $(INCDIR)/filenames.h \
4092 $(INCDIR)/hashtab.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/cr16c.h \
4093 $(INCDIR)/elf/reloc-macros.h elf-bfd.h $(INCDIR)/elf/common.h \
4094 --- a/bfd/reloc.c
4095 +++ b/bfd/reloc.c
4096 @@ -3948,6 +3948,131 @@ ENUMDOC
4097 instructions
4098
4099 ENUM
4100 + BFD_RELOC_AVR32_DIFF32
4101 +ENUMX
4102 + BFD_RELOC_AVR32_DIFF16
4103 +ENUMX
4104 + BFD_RELOC_AVR32_DIFF8
4105 +ENUMDOC
4106 + Difference between two labels: L2 - L1. The value of L1 is encoded
4107 + as sym + addend, while the initial difference after assembly is
4108 + inserted into the object file by the assembler.
4109 +ENUM
4110 + BFD_RELOC_AVR32_GOT32
4111 +ENUMX
4112 + BFD_RELOC_AVR32_GOT16
4113 +ENUMX
4114 + BFD_RELOC_AVR32_GOT8
4115 +ENUMDOC
4116 + Reference to a symbol through the Global Offset Table. The linker
4117 + will allocate an entry for symbol in the GOT and insert the offset
4118 + of this entry as the relocation value.
4119 +ENUM
4120 + BFD_RELOC_AVR32_21S
4121 +ENUMX
4122 + BFD_RELOC_AVR32_16U
4123 +ENUMX
4124 + BFD_RELOC_AVR32_16S
4125 +ENUMX
4126 + BFD_RELOC_AVR32_SUB5
4127 +ENUMX
4128 + BFD_RELOC_AVR32_8S_EXT
4129 +ENUMX
4130 + BFD_RELOC_AVR32_8S
4131 +ENUMX
4132 + BFD_RELOC_AVR32_15S
4133 +ENUMDOC
4134 + Normal (non-pc-relative) code relocations. Alignment and signedness
4135 + is indicated by the suffixes. S means signed, U means unsigned. W
4136 + means word-aligned, H means halfword-aligned, neither means
4137 + byte-aligned (no alignment.) SUB5 is the same relocation as 16S.
4138 +ENUM
4139 + BFD_RELOC_AVR32_22H_PCREL
4140 +ENUMX
4141 + BFD_RELOC_AVR32_18W_PCREL
4142 +ENUMX
4143 + BFD_RELOC_AVR32_16B_PCREL
4144 +ENUMX
4145 + BFD_RELOC_AVR32_16N_PCREL
4146 +ENUMX
4147 + BFD_RELOC_AVR32_14UW_PCREL
4148 +ENUMX
4149 + BFD_RELOC_AVR32_11H_PCREL
4150 +ENUMX
4151 + BFD_RELOC_AVR32_10UW_PCREL
4152 +ENUMX
4153 + BFD_RELOC_AVR32_9H_PCREL
4154 +ENUMX
4155 + BFD_RELOC_AVR32_9UW_PCREL
4156 +ENUMDOC
4157 + PC-relative relocations are signed if neither 'U' nor 'S' is
4158 + specified. However, we explicitly tack on a 'B' to indicate no
4159 + alignment, to avoid confusion with data relocs. All of these resolve
4160 + to sym + addend - offset, except the one with 'N' (negated) suffix.
4161 + This particular one resolves to offset - sym - addend.
4162 +ENUM
4163 + BFD_RELOC_AVR32_GOTPC
4164 +ENUMDOC
4165 + Subtract the link-time address of the GOT from (symbol + addend)
4166 + and insert the result.
4167 +ENUM
4168 + BFD_RELOC_AVR32_GOTCALL
4169 +ENUMX
4170 + BFD_RELOC_AVR32_LDA_GOT
4171 +ENUMX
4172 + BFD_RELOC_AVR32_GOT21S
4173 +ENUMX
4174 + BFD_RELOC_AVR32_GOT18SW
4175 +ENUMX
4176 + BFD_RELOC_AVR32_GOT16S
4177 +ENUMDOC
4178 + Reference to a symbol through the GOT. The linker will allocate an
4179 + entry for symbol in the GOT and insert the offset of this entry as
4180 + the relocation value. addend must be zero. As usual, 'S' means
4181 + signed, 'W' means word-aligned, etc.
4182 +ENUM
4183 + BFD_RELOC_AVR32_32_CPENT
4184 +ENUMDOC
4185 + 32-bit constant pool entry. I don't think 8- and 16-bit entries make
4186 + a whole lot of sense.
4187 +ENUM
4188 + BFD_RELOC_AVR32_CPCALL
4189 +ENUMX
4190 + BFD_RELOC_AVR32_16_CP
4191 +ENUMX
4192 + BFD_RELOC_AVR32_9W_CP
4193 +ENUMDOC
4194 + Constant pool references. Some of these relocations are signed,
4195 + others are unsigned. It doesn't really matter, since the constant
4196 + pool always comes after the code that references it.
4197 +ENUM
4198 + BFD_RELOC_AVR32_ALIGN
4199 +ENUMDOC
4200 + sym must be the absolute symbol. The addend specifies the alignment
4201 + order, e.g. if addend is 2, the linker must add padding so that the
4202 + next address is aligned to a 4-byte boundary.
4203 +ENUM
4204 + BFD_RELOC_AVR32_14UW
4205 +ENUMX
4206 + BFD_RELOC_AVR32_10UW
4207 +ENUMX
4208 + BFD_RELOC_AVR32_10SW
4209 +ENUMX
4210 + BFD_RELOC_AVR32_STHH_W
4211 +ENUMX
4212 + BFD_RELOC_AVR32_7UW
4213 +ENUMX
4214 + BFD_RELOC_AVR32_6S
4215 +ENUMX
4216 + BFD_RELOC_AVR32_6UW
4217 +ENUMX
4218 + BFD_RELOC_AVR32_4UH
4219 +ENUMX
4220 + BFD_RELOC_AVR32_3U
4221 +ENUMDOC
4222 + Code relocations that will never make it to the output file.
4223 +
4224 +ENUM
4225 BFD_RELOC_390_12
4226 ENUMDOC
4227 Direct 12 bit.
4228 --- a/bfd/targets.c
4229 +++ b/bfd/targets.c
4230 @@ -564,6 +564,7 @@ extern const bfd_target bfd_efi_app_ia32
4231 extern const bfd_target bfd_efi_app_x86_64_vec;
4232 extern const bfd_target bfd_efi_app_ia64_vec;
4233 extern const bfd_target bfd_elf32_avr_vec;
4234 +extern const bfd_target bfd_elf32_avr32_vec;
4235 extern const bfd_target bfd_elf32_bfin_vec;
4236 extern const bfd_target bfd_elf32_bfinfdpic_vec;
4237 extern const bfd_target bfd_elf32_big_generic_vec;
4238 @@ -884,6 +885,7 @@ static const bfd_target * const _bfd_tar
4239 &bfd_efi_app_ia64_vec,
4240 #endif
4241 &bfd_elf32_avr_vec,
4242 + &bfd_elf32_avr32_vec,
4243 &bfd_elf32_bfin_vec,
4244 &bfd_elf32_bfinfdpic_vec,
4245
4246 --- a/binutils/Makefile.am
4247 +++ b/binutils/Makefile.am
4248 @@ -577,7 +577,7 @@ readelf.o: readelf.c sysdep.h $(INCDIR)/
4249 $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h bucomm.h dwarf.h \
4250 $(INCDIR)/elf/common.h $(INCDIR)/elf/external.h $(INCDIR)/elf/internal.h \
4251 $(INCDIR)/elf/h8.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/elf/alpha.h \
4252 - $(INCDIR)/elf/arc.h $(INCDIR)/elf/arm.h $(INCDIR)/elf/avr.h \
4253 + $(INCDIR)/elf/arc.h $(INCDIR)/elf/arm.h $(INCDIR)/elf/avr.h $(INCDIR)/elf/avr32.h\
4254 $(INCDIR)/elf/bfin.h $(INCDIR)/elf/cris.h $(INCDIR)/elf/crx.h \
4255 $(INCDIR)/elf/d10v.h $(INCDIR)/elf/d30v.h $(INCDIR)/elf/dlx.h \
4256 $(INCDIR)/elf/fr30.h $(INCDIR)/elf/frv.h $(INCDIR)/elf/hppa.h \
4257 --- a/binutils/readelf.c
4258 +++ b/binutils/readelf.c
4259 @@ -21,7 +21,7 @@
4260 along with this program; if not, write to the Free Software
4261 Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
4262 02110-1301, USA. */
4263 -\f
4264 +
4265 /* The difference between readelf and objdump:
4266
4267 Both programs are capable of displaying the contents of ELF format files,
4268 @@ -40,7 +40,7 @@
4269 There is also the case that readelf can provide more information about an
4270 ELF file than is provided by objdump. In particular it can display DWARF
4271 debugging information which (at the moment) objdump cannot. */
4272 -\f
4273 +
4274 #include "sysdep.h"
4275 #include <assert.h>
4276 #include <sys/stat.h>
4277 @@ -109,6 +109,7 @@
4278 #include "elf/arc.h"
4279 #include "elf/arm.h"
4280 #include "elf/avr.h"
4281 +#include "elf/avr32.h"
4282 #include "elf/bfin.h"
4283 #include "elf/cr16.h"
4284 #include "elf/cris.h"
4285 @@ -303,7 +304,7 @@ static void (*byte_put) (unsigned char *
4286 #define streq(a,b) (strcmp ((a), (b)) == 0)
4287 #define strneq(a,b,n) (strncmp ((a), (b), (n)) == 0)
4288 #define const_strneq(a,b) (strncmp ((a), (b), sizeof (b) - 1) == 0)
4289 -\f
4290 +
4291 static void *
4292 get_data (void *var, FILE *file, long offset, size_t size, size_t nmemb,
4293 const char *reason)
4294 @@ -614,6 +615,7 @@ guess_is_rela (unsigned long e_machine)
4295 case EM_ALPHA:
4296 case EM_ALTERA_NIOS2:
4297 case EM_AVR:
4298 + case EM_AVR32:
4299 case EM_AVR_OLD:
4300 case EM_BLACKFIN:
4301 case EM_CR16:
4302 @@ -1006,6 +1008,10 @@ dump_relocations (FILE *file,
4303 rtype = elf_avr_reloc_type (type);
4304 break;
4305
4306 + case EM_AVR32:
4307 + rtype = elf_avr32_reloc_type (type);
4308 + break;
4309 +
4310 case EM_OLD_SPARCV9:
4311 case EM_SPARC32PLUS:
4312 case EM_SPARCV9:
4313 @@ -1763,6 +1769,7 @@ get_machine_name (unsigned e_machine)
4314 case EM_VAX: return "Digital VAX";
4315 case EM_AVR_OLD:
4316 case EM_AVR: return "Atmel AVR 8-bit microcontroller";
4317 + case EM_AVR32: return "Atmel AVR32";
4318 case EM_CRIS: return "Axis Communications 32-bit embedded processor";
4319 case EM_JAVELIN: return "Infineon Technologies 32-bit embedded cpu";
4320 case EM_FIREPATH: return "Element 14 64-bit DSP processor";
4321 --- a/gas/as.c
4322 +++ b/gas/as.c
4323 @@ -441,10 +441,10 @@ parse_args (int * pargc, char *** pargv)
4324 the end of the preceeding line so that it is simpler to
4325 selectively add and remove lines from this list. */
4326 {"alternate", no_argument, NULL, OPTION_ALTERNATE}
4327 - /* The entry for "a" is here to prevent getopt_long_only() from
4328 - considering that -a is an abbreviation for --alternate. This is
4329 - necessary because -a=<FILE> is a valid switch but getopt would
4330 - normally reject it since --alternate does not take an argument. */
4331 + /* The next two entries are here to prevent getopt_long_only() from
4332 + considering that -a or -al is an abbreviation for --alternate.
4333 + This is necessary because -a=<FILE> is a valid switch but getopt
4334 + would normally reject it since --alternate does not take an argument. */
4335 ,{"a", optional_argument, NULL, 'a'}
4336 /* Handle -al=<FILE>. */
4337 ,{"al", optional_argument, NULL, OPTION_AL}
4338 @@ -803,8 +803,15 @@ This program has absolutely no warranty.
4339 case 'a':
4340 if (optarg)
4341 {
4342 - if (optarg != old_argv[optind] && optarg[-1] == '=')
4343 - --optarg;
4344 + /* If optarg is part of the -a switch and not a separate argument
4345 + in its own right, then scan backwards to the just after the -a.
4346 + This means skipping over both '=' and 'l' which might have been
4347 + taken to be part of the -a switch itself. */
4348 + if (optarg != old_argv[optind])
4349 + {
4350 + while (optarg[-1] == '=' || optarg[-1] == 'l')
4351 + --optarg;
4352 + }
4353
4354 if (md_parse_option (optc, optarg) != 0)
4355 break;
4356 @@ -1234,7 +1241,7 @@ main (int argc, char ** argv)
4357 keep_it = 0;
4358
4359 if (!keep_it)
4360 - unlink_if_ordinary (out_file_name);
4361 + unlink (out_file_name);
4362
4363 input_scrub_end ();
4364
4365 --- /dev/null
4366 +++ b/gas/config/tc-avr32.c
4367 @@ -0,0 +1,4806 @@
4368 +/* Assembler implementation for AVR32.
4369 + Copyright 2003-2006 Atmel Corporation.
4370 +
4371 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
4372 +
4373 + This file is part of GAS, the GNU Assembler.
4374 +
4375 + GAS is free software; you can redistribute it and/or modify it
4376 + under the terms of the GNU General Public License as published by
4377 + the Free Software Foundation; either version 2, or (at your option)
4378 + any later version.
4379 +
4380 + GAS is distributed in the hope that it will be useful, but WITHOUT
4381 + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
4382 + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
4383 + License for more details.
4384 +
4385 + You should have received a copy of the GNU General Public License
4386 + along with GAS; see the file COPYING. If not, write to the Free
4387 + Software Foundation, 59 Temple Place - Suite 330, Boston, MA
4388 + 02111-1307, USA. */
4389 +
4390 +#include <stdio.h>
4391 +#include "as.h"
4392 +#include "safe-ctype.h"
4393 +#include "subsegs.h"
4394 +#include "symcat.h"
4395 +#include "opcodes/avr32-opc.h"
4396 +#include "opcodes/avr32-asm.h"
4397 +#include "elf/avr32.h"
4398 +#include "dwarf2dbg.h"
4399 +
4400 +#define xDEBUG
4401 +#define xOPC_CONSISTENCY_CHECK
4402 +
4403 +#ifdef DEBUG
4404 +# define pr_debug(fmt, args...) fprintf(stderr, fmt, ##args)
4405 +#else
4406 +# define pr_debug(fmt, args...)
4407 +#endif
4408 +
4409 +/* 3 MSB of instruction word indicate group. Group 7 -> extended */
4410 +#define AVR32_COMPACT_P(opcode) ((opcode[0] & 0xe0) != 0xe0)
4411 +
4412 +#define streq(a, b) (strcmp(a, b) == 0)
4413 +#define skip_whitespace(str) do { while(*(str) == ' ') ++(str); } while(0)
4414 +
4415 +/* Flags given on the command line */
4416 +static int avr32_pic = FALSE;
4417 +int linkrelax = FALSE;
4418 +int avr32_iarcompat = FALSE;
4419 +
4420 +/* This array holds the chars that always start a comment. */
4421 +const char comment_chars[] = "#";
4422 +
4423 +/* This array holds the chars that only start a comment at the
4424 + beginning of a line. We must include '#' here because the compiler
4425 + may produce #APP and #NO_APP in its output. */
4426 +const char line_comment_chars[] = "#";
4427 +
4428 +/* These may be used instead of newline (same as ';' in C). */
4429 +const char line_separator_chars[] = ";";
4430 +
4431 +/* Chars that can be used to separate mantissa from exponent in
4432 + floating point numbers. */
4433 +const char EXP_CHARS[] = "eE";
4434 +
4435 +/* Chars that mean this number is a floating point constant. */
4436 +const char FLT_CHARS[] = "dD";
4437 +
4438 +/* Pre-defined "_GLOBAL_OFFSET_TABLE_" */
4439 +symbolS *GOT_symbol;
4440 +
4441 +static struct hash_control *avr32_mnemonic_htab;
4442 +
4443 +struct avr32_ifield_data
4444 +{
4445 + bfd_vma value;
4446 + /* FIXME: Get rid of align_order and complain. complain is never
4447 + used, align_order is used in one place. Try to use the relax
4448 + table instead. */
4449 + unsigned int align_order;
4450 +};
4451 +
4452 +struct avr32_insn
4453 +{
4454 + const struct avr32_syntax *syntax;
4455 + expressionS immediate;
4456 + int pcrel;
4457 + int force_extended;
4458 + unsigned int next_slot;
4459 + bfd_reloc_code_real_type r_type;
4460 + struct avr32_ifield_data field_value[AVR32_MAX_FIELDS];
4461 +};
4462 +
4463 +static struct avr32_insn current_insn;
4464 +
4465 +/* The target specific pseudo-ops we support. */
4466 +static void s_rseg (int);
4467 +static void s_cpool(int);
4468 +
4469 +const pseudo_typeS md_pseudo_table[] =
4470 +{
4471 + /* Make sure that .word is 32 bits */
4472 + { "word", cons, 4 },
4473 + { "file", (void (*) PARAMS ((int))) dwarf2_directive_file, 0 },
4474 + { "loc", dwarf2_directive_loc, 0 },
4475 +
4476 + /* .lcomm requires an explicit alignment parameter */
4477 + { "lcomm", s_lcomm, 1 },
4478 +
4479 + /* AVR32-specific pseudo-ops */
4480 + { "cpool", s_cpool, 0},
4481 +
4482 + /* IAR compatible pseudo-ops */
4483 + { "program", s_ignore, 0 },
4484 + { "public", s_globl, 0 },
4485 + { "extern", s_ignore, 0 },
4486 + { "module", s_ignore, 0 },
4487 + { "rseg", s_rseg, 0 },
4488 + { "dc8", cons, 1 },
4489 + { "dc16", cons, 2 },
4490 + { "dc32", cons, 4 },
4491 +
4492 + { NULL, NULL, 0 }
4493 +};
4494 +
4495 +/* Questionable stuff starts here */
4496 +
4497 +enum avr32_opinfo {
4498 + AVR32_OPINFO_NONE = BFD_RELOC_NONE,
4499 + AVR32_OPINFO_GOT,
4500 + AVR32_OPINFO_TLSGD,
4501 + AVR32_OPINFO_HI,
4502 + AVR32_OPINFO_LO,
4503 +};
4504 +
4505 +enum avr32_arch {
4506 + ARCH_TYPE_AP,
4507 + ARCH_TYPE_UCR1,
4508 + ARCH_TYPE_UCR2,
4509 +};
4510 +
4511 +struct arch_type_s
4512 +{
4513 + /* Architecture name */
4514 + char *name;
4515 + /* Instruction Set Architecture Flags */
4516 + unsigned long isa_flags;
4517 +};
4518 +
4519 +struct part_type_s
4520 +{
4521 + /* Part name */
4522 + char *name;
4523 + /* Architecture type */
4524 + unsigned int arch;
4525 +};
4526 +
4527 +static struct arch_type_s arch_types[] =
4528 +{
4529 + {"ap", AVR32_V1 | AVR32_SIMD | AVR32_DSP | AVR32_PICO},
4530 + {"ucr1", AVR32_V1 | AVR32_DSP | AVR32_RMW},
4531 + {"ucr2", AVR32_V1 | AVR32_V2 | AVR32_DSP | AVR32_RMW},
4532 + {"all-insn", AVR32_V1 | AVR32_V2 | AVR32_SIMD | AVR32_DSP | AVR32_RMW | AVR32_FP | AVR32_PICO},
4533 + {NULL, 0}
4534 +};
4535 +
4536 +static struct part_type_s part_types[] = {
4537 + {"ap7000", ARCH_TYPE_AP},
4538 + {"ap7001", ARCH_TYPE_AP},
4539 + {"ap7002", ARCH_TYPE_AP},
4540 + {"ap7200", ARCH_TYPE_AP},
4541 + {"uc3a0128", ARCH_TYPE_UCR2},
4542 + {"uc3a0256", ARCH_TYPE_UCR2},
4543 + {"uc3a0512es", ARCH_TYPE_UCR1},
4544 + {"uc3a0512", ARCH_TYPE_UCR2},
4545 + {"uc3a1128", ARCH_TYPE_UCR2},
4546 + {"uc3a1256es", ARCH_TYPE_UCR1},
4547 + {"uc3a1256", ARCH_TYPE_UCR2},
4548 + {"uc3a1512es", ARCH_TYPE_UCR1},
4549 + {"uc3a1512", ARCH_TYPE_UCR2},
4550 + {"uc3a364", ARCH_TYPE_UCR2},
4551 + {"uc3a364s", ARCH_TYPE_UCR2},
4552 + {"uc3a3128", ARCH_TYPE_UCR2},
4553 + {"uc3a3128s", ARCH_TYPE_UCR2},
4554 + {"uc3a3256", ARCH_TYPE_UCR2},
4555 + {"uc3a3256s", ARCH_TYPE_UCR2},
4556 + {"uc3b064", ARCH_TYPE_UCR1},
4557 + {"uc3b0128", ARCH_TYPE_UCR1},
4558 + {"uc3b0256es", ARCH_TYPE_UCR1},
4559 + {"uc3b0256", ARCH_TYPE_UCR1},
4560 + {"uc3b164", ARCH_TYPE_UCR1},
4561 + {"uc3b1128", ARCH_TYPE_UCR1},
4562 + {"uc3b1256es", ARCH_TYPE_UCR1},
4563 + {"uc3b1256", ARCH_TYPE_UCR1},
4564 + {NULL, 0}
4565 +};
4566 +
4567 +/* Current architecture type. */
4568 +static struct arch_type_s default_arch = {"all-insn", AVR32_V1 | AVR32_V2 | AVR32_SIMD | AVR32_DSP | AVR32_RMW | AVR32_FP | AVR32_PICO };
4569 +static struct arch_type_s *avr32_arch = &default_arch;
4570 +
4571 +/* Display nicely formatted list of known part- and architecture names. */
4572 +
4573 +static void
4574 +show_arch_list (FILE *stream)
4575 +{
4576 + int i, x;
4577 +
4578 + fprintf (stream, _("Known architecture names:"));
4579 + x = 1000;
4580 +
4581 + for (i = 0; arch_types[i].name; i++)
4582 + {
4583 + int len = strlen (arch_types[i].name);
4584 +
4585 + x += len + 1;
4586 +
4587 + if (x < 75)
4588 + fprintf (stream, " %s", arch_types[i].name);
4589 + else
4590 + {
4591 + fprintf (stream, "\n %s", arch_types[i].name);
4592 + x = len + 2;
4593 + }
4594 + }
4595 +
4596 + fprintf (stream, "\n");
4597 +}
4598 +
4599 +static void
4600 +show_part_list (FILE *stream)
4601 +{
4602 + int i, x;
4603 +
4604 + fprintf (stream, _("Known part names:"));
4605 + x = 1000;
4606 +
4607 + for (i = 0; part_types[i].name; i++)
4608 + {
4609 + int len = strlen(part_types[i].name);
4610 +
4611 + x += len + 1;
4612 +
4613 + if (x < 75)
4614 + fprintf (stream, " %s", part_types[i].name);
4615 + else
4616 + {
4617 + fprintf(stream, "\n %s", part_types[i].name);
4618 + x = len + 2;
4619 + }
4620 + }
4621 +
4622 + fprintf (stream, "\n");
4623 +}
4624 +
4625 +const char *md_shortopts = "";
4626 +struct option md_longopts[] =
4627 +{
4628 +#define OPTION_ARCH (OPTION_MD_BASE)
4629 +#define OPTION_PART (OPTION_ARCH + 1)
4630 +#define OPTION_IAR (OPTION_PART + 1)
4631 +#define OPTION_PIC (OPTION_IAR + 1)
4632 +#define OPTION_NOPIC (OPTION_PIC + 1)
4633 +#define OPTION_LINKRELAX (OPTION_NOPIC + 1)
4634 +#define OPTION_NOLINKRELAX (OPTION_LINKRELAX + 1)
4635 +#define OPTION_DIRECT_DATA_REFS (OPTION_NOLINKRELAX + 1)
4636 + {"march", required_argument, NULL, OPTION_ARCH},
4637 + {"mpart", required_argument, NULL, OPTION_PART},
4638 + {"iar", no_argument, NULL, OPTION_IAR},
4639 + {"pic", no_argument, NULL, OPTION_PIC},
4640 + {"no-pic", no_argument, NULL, OPTION_NOPIC},
4641 + {"linkrelax", no_argument, NULL, OPTION_LINKRELAX},
4642 + {"no-linkrelax", no_argument, NULL, OPTION_NOLINKRELAX},
4643 + /* deprecated alias for -mpart=xxx */
4644 + {"mcpu", required_argument, NULL, OPTION_PART},
4645 + {NULL, no_argument, NULL, 0}
4646 +};
4647 +
4648 +size_t md_longopts_size = sizeof (md_longopts);
4649 +
4650 +void
4651 +md_show_usage (FILE *stream)
4652 +{
4653 + fprintf (stream, _("\
4654 +AVR32 options:\n\
4655 + -march=[arch-name] Select cpu architecture. [Default `all-insn']\n\
4656 + -mpart=[part-name] Select specific part. [Default `none']\n\
4657 + --pic Produce Position-Independent Code\n\
4658 + --no-pic Don't produce Position-Independent Code\n\
4659 + --linkrelax Produce output suitable for linker relaxing\n\
4660 + --no-linkrelax Don't produce output suitable for linker relaxing\n"));
4661 + show_arch_list(stream);
4662 +}
4663 +
4664 +int
4665 +md_parse_option (int c, char *arg ATTRIBUTE_UNUSED)
4666 +{
4667 + switch (c)
4668 + {
4669 + case OPTION_ARCH:
4670 + {
4671 + int i;
4672 + char *s = alloca (strlen (arg) + 1);
4673 +
4674 + {
4675 + char *t = s;
4676 + char *arg1 = arg;
4677 +
4678 + do
4679 + *t = TOLOWER (*arg1++);
4680 + while (*t++);
4681 + }
4682 +
4683 + /* Add backward compability */
4684 + if (strcmp ("uc", s)== 0)
4685 + {
4686 + as_warn("Deprecated arch `%s' specified. "
4687 + "Please use '-march=ucr1' instead. "
4688 + "Converting to arch 'ucr1'\n",
4689 + s);
4690 + s="ucr1";
4691 + }
4692 +
4693 + for (i = 0; arch_types[i].name; ++i)
4694 + if (strcmp (arch_types[i].name, s) == 0)
4695 + break;
4696 +
4697 + if (!arch_types[i].name)
4698 + {
4699 + show_arch_list (stderr);
4700 + as_fatal (_("unknown architecture: %s\n"), arg);
4701 + }
4702 +
4703 + avr32_arch = &arch_types[i];
4704 + break;
4705 + }
4706 + case OPTION_PART:
4707 + {
4708 + int i;
4709 + char *s = alloca (strlen (arg) + 1);
4710 + char *t = s;
4711 + char *p = arg;
4712 +
4713 + /* If arch type has already been set, don't bother.
4714 + -march= always overrides -mpart= */
4715 + if (avr32_arch != &default_arch)
4716 + break;
4717 +
4718 + do
4719 + *t = TOLOWER (*p++);
4720 + while (*t++);
4721 +
4722 + for (i = 0; part_types[i].name; ++i)
4723 + if (strcmp (part_types[i].name, s) == 0)
4724 + break;
4725 +
4726 + if (!part_types[i].name)
4727 + {
4728 + show_part_list (stderr);
4729 + as_fatal (_("unknown part: %s\n"), arg);
4730 + }
4731 +
4732 + avr32_arch = &arch_types[part_types[i].arch];
4733 + break;
4734 + }
4735 + case OPTION_IAR:
4736 + avr32_iarcompat = 1;
4737 + break;
4738 + case OPTION_PIC:
4739 + avr32_pic = 1;
4740 + break;
4741 + case OPTION_NOPIC:
4742 + avr32_pic = 0;
4743 + break;
4744 + case OPTION_LINKRELAX:
4745 + linkrelax = 1;
4746 + break;
4747 + case OPTION_NOLINKRELAX:
4748 + linkrelax = 0;
4749 + break;
4750 + default:
4751 + return 0;
4752 + }
4753 + return 1;
4754 +}
4755 +
4756 +/* Can't use symbol_new here, so have to create a symbol and then at
4757 + a later date assign it a value. Thats what these functions do.
4758 +
4759 + Shamelessly stolen from ARM. */
4760 +
4761 +static void
4762 +symbol_locate (symbolS * symbolP,
4763 + const char * name, /* It is copied, the caller can modify. */
4764 + segT segment, /* Segment identifier (SEG_<something>). */
4765 + valueT valu, /* Symbol value. */
4766 + fragS * frag) /* Associated fragment. */
4767 +{
4768 + unsigned int name_length;
4769 + char * preserved_copy_of_name;
4770 +
4771 + name_length = strlen (name) + 1; /* +1 for \0. */
4772 + obstack_grow (&notes, name, name_length);
4773 + preserved_copy_of_name = obstack_finish (&notes);
4774 +#ifdef STRIP_UNDERSCORE
4775 + if (preserved_copy_of_name[0] == '_')
4776 + preserved_copy_of_name++;
4777 +#endif
4778 +
4779 +#ifdef tc_canonicalize_symbol_name
4780 + preserved_copy_of_name =
4781 + tc_canonicalize_symbol_name (preserved_copy_of_name);
4782 +#endif
4783 +
4784 + S_SET_NAME (symbolP, preserved_copy_of_name);
4785 +
4786 + S_SET_SEGMENT (symbolP, segment);
4787 + S_SET_VALUE (symbolP, valu);
4788 + symbol_clear_list_pointers (symbolP);
4789 +
4790 + symbol_set_frag (symbolP, frag);
4791 +
4792 + /* Link to end of symbol chain. */
4793 + {
4794 + extern int symbol_table_frozen;
4795 +
4796 + if (symbol_table_frozen)
4797 + abort ();
4798 + }
4799 +
4800 + symbol_append (symbolP, symbol_lastP, & symbol_rootP, & symbol_lastP);
4801 +
4802 + obj_symbol_new_hook (symbolP);
4803 +
4804 +#ifdef tc_symbol_new_hook
4805 + tc_symbol_new_hook (symbolP);
4806 +#endif
4807 +
4808 +#ifdef DEBUG_SYMS
4809 + verify_symbol_chain (symbol_rootP, symbol_lastP);
4810 +#endif /* DEBUG_SYMS */
4811 +}
4812 +
4813 +struct cpool_entry
4814 +{
4815 + int refcount;
4816 + offsetT offset;
4817 + expressionS exp;
4818 +};
4819 +
4820 +struct cpool
4821 +{
4822 + struct cpool *next;
4823 + int used;
4824 + struct cpool_entry *literals;
4825 + unsigned int padding;
4826 + unsigned int next_free_entry;
4827 + unsigned int id;
4828 + symbolS *symbol;
4829 + segT section;
4830 + subsegT sub_section;
4831 +};
4832 +
4833 +struct cpool *cpool_list = NULL;
4834 +
4835 +static struct cpool *
4836 +find_cpool(segT section, subsegT sub_section)
4837 +{
4838 + struct cpool *pool;
4839 +
4840 + for (pool = cpool_list; pool != NULL; pool = pool->next)
4841 + {
4842 + if (!pool->used
4843 + && pool->section == section
4844 + && pool->sub_section == sub_section)
4845 + break;
4846 + }
4847 +
4848 + return pool;
4849 +}
4850 +
4851 +static struct cpool *
4852 +find_or_make_cpool(segT section, subsegT sub_section)
4853 +{
4854 + static unsigned int next_cpool_id = 0;
4855 + struct cpool *pool;
4856 +
4857 + pool = find_cpool(section, sub_section);
4858 +
4859 + if (!pool)
4860 + {
4861 + pool = xmalloc(sizeof(*pool));
4862 + if (!pool)
4863 + return NULL;
4864 +
4865 + pool->used = 0;
4866 + pool->literals = NULL;
4867 + pool->padding = 0;
4868 + pool->next_free_entry = 0;
4869 + pool->section = section;
4870 + pool->sub_section = sub_section;
4871 + pool->next = cpool_list;
4872 + pool->symbol = NULL;
4873 +
4874 + cpool_list = pool;
4875 + }
4876 +
4877 + /* NULL symbol means that the pool is new or has just been emptied. */
4878 + if (!pool->symbol)
4879 + {
4880 + pool->symbol = symbol_create(FAKE_LABEL_NAME, undefined_section,
4881 + 0, &zero_address_frag);
4882 + pool->id = next_cpool_id++;
4883 + }
4884 +
4885 + return pool;
4886 +}
4887 +
4888 +static struct cpool *
4889 +add_to_cpool(expressionS *exp, unsigned int *index, int ref)
4890 +{
4891 + struct cpool *pool;
4892 + unsigned int entry;
4893 +
4894 + pool = find_or_make_cpool(now_seg, now_subseg);
4895 +
4896 + /* Check if this constant is already in the pool. */
4897 + for (entry = 0; entry < pool->next_free_entry; entry++)
4898 + {
4899 + if ((pool->literals[entry].exp.X_op == exp->X_op)
4900 + && (exp->X_op == O_constant)
4901 + && (pool->literals[entry].exp.X_add_number
4902 + == exp->X_add_number)
4903 + && (pool->literals[entry].exp.X_unsigned
4904 + == exp->X_unsigned))
4905 + break;
4906 +
4907 + if ((pool->literals[entry].exp.X_op == exp->X_op)
4908 + && (exp->X_op == O_symbol)
4909 + && (pool->literals[entry].exp.X_add_number
4910 + == exp->X_add_number)
4911 + && (pool->literals[entry].exp.X_add_symbol
4912 + == exp->X_add_symbol)
4913 + && (pool->literals[entry].exp.X_op_symbol
4914 + == exp->X_op_symbol))
4915 + break;
4916 + }
4917 +
4918 + /* Create an entry if we didn't find a match */
4919 + if (entry == pool->next_free_entry)
4920 + {
4921 + pool->literals = xrealloc(pool->literals,
4922 + sizeof(struct cpool_entry) * (entry + 1));
4923 + pool->literals[entry].exp = *exp;
4924 + pool->literals[entry].refcount = 0;
4925 + pool->next_free_entry++;
4926 + }
4927 +
4928 + if (index)
4929 + *index = entry;
4930 + if (ref)
4931 + pool->literals[entry].refcount++;
4932 +
4933 + return pool;
4934 +}
4935 +
4936 +struct avr32_operand
4937 +{
4938 + int id;
4939 + int is_signed;
4940 + int is_pcrel;
4941 + int align_order;
4942 + int (*match)(char *str);
4943 + void (*parse)(const struct avr32_operand *op, char *str, int opindex);
4944 +};
4945 +
4946 +static int
4947 +match_anything(char *str ATTRIBUTE_UNUSED)
4948 +{
4949 + return 1;
4950 +}
4951 +
4952 +static int
4953 +match_intreg(char *str)
4954 +{
4955 + int regid, ret = 1;
4956 +
4957 + regid = avr32_parse_intreg(str);
4958 + if (regid < 0)
4959 + ret = 0;
4960 +
4961 + pr_debug("match_intreg: `%s': %d\n", str, ret);
4962 +
4963 + return ret;
4964 +}
4965 +
4966 +static int
4967 +match_intreg_predec(char *str)
4968 +{
4969 + int regid;
4970 +
4971 + if (str[0] != '-' || str[1] != '-')
4972 + return 0;
4973 +
4974 + regid = avr32_parse_intreg(str + 2);
4975 + if (regid < 0)
4976 + return 0;
4977 +
4978 + return 1;
4979 +}
4980 +
4981 +static int
4982 +match_intreg_postinc(char *str)
4983 +{
4984 + int regid, ret = 1;
4985 + char *p, c;
4986 +
4987 + for (p = str; *p; p++)
4988 + if (*p == '+')
4989 + break;
4990 +
4991 + if (p[0] != '+' || p[1] != '+')
4992 + return 0;
4993 +
4994 + c = *p, *p = 0;
4995 + regid = avr32_parse_intreg(str);
4996 + if (regid < 0)
4997 + ret = 0;
4998 +
4999 + *p = c;
5000 + return ret;
5001 +}
5002 +
5003 +static int
5004 +match_intreg_lsl(char *str)
5005 +{
5006 + int regid, ret = 1;
5007 + char *p, c;
5008 +
5009 + for (p = str; *p; p++)
5010 + if (*p == '<')
5011 + break;
5012 +
5013 + if (p[0] && p[1] != '<')
5014 + return 0;
5015 +
5016 + c = *p, *p = 0;
5017 + regid = avr32_parse_intreg(str);
5018 + if (regid < 0)
5019 + ret = 0;
5020 +
5021 + *p = c;
5022 + return ret;
5023 +}
5024 +
5025 +static int
5026 +match_intreg_lsr(char *str)
5027 +{
5028 + int regid, ret = 1;
5029 + char *p, c;
5030 +
5031 + for (p = str; *p; p++)
5032 + if (*p == '>')
5033 + break;
5034 +
5035 + if (p[0] && p[1] != '>')
5036 + return 0;
5037 +
5038 + c = *p, *p = 0;
5039 +
5040 + regid = avr32_parse_intreg(str);
5041 + if (regid < 0)
5042 + ret = 0;
5043 +
5044 + *p = c;
5045 + return ret;
5046 +}
5047 +
5048 +static int
5049 +match_intreg_part(char *str)
5050 +{
5051 + int regid, ret = 1;
5052 + char *p, c;
5053 +
5054 + for (p = str; *p; p++)
5055 + if (*p == ':')
5056 + break;
5057 +
5058 + if (p[0] != ':' || !ISPRINT(p[1]) || p[2] != '\0')
5059 + return 0;
5060 +
5061 + c = *p, *p = 0;
5062 + regid = avr32_parse_intreg(str);
5063 + if (regid < 0)
5064 + ret = 0;
5065 +
5066 + *p = c;
5067 +
5068 + return ret;
5069 +}
5070 +
5071 +#define match_intreg_disp match_anything
5072 +
5073 +static int
5074 +match_intreg_index(char *str)
5075 +{
5076 + int regid, ret = 1;
5077 + char *p, *end, c;
5078 +
5079 + for (p = str; *p; p++)
5080 + if (*p == '[')
5081 + break;
5082 +
5083 + /* don't allow empty displacement here (it makes no sense) */
5084 + if (p[0] != '[')
5085 + return 0;
5086 +
5087 + for (end = p + 1; *end; end++) ;
5088 + if (*(--end) != ']')
5089 + return 0;
5090 +
5091 + c = *end, *end = 0;
5092 + if (!match_intreg_lsl(p + 1))
5093 + ret = 0;
5094 + *end = c;
5095 +
5096 + if (ret)
5097 + {
5098 + c = *p, *p = 0;
5099 + regid = avr32_parse_intreg(str);
5100 + if (regid < 0)
5101 + ret = 0;
5102 + *p = c;
5103 + }
5104 +
5105 + return ret;
5106 +}
5107 +
5108 +static int
5109 +match_intreg_xindex(char *str)
5110 +{
5111 + int regid, ret = 1;
5112 + char *p, *end, c;
5113 +
5114 + for (p = str; *p; p++)
5115 + if (*p == '[')
5116 + break;
5117 +
5118 + /* empty displacement makes no sense here either */
5119 + if (p[0] != '[')
5120 + return 0;
5121 +
5122 + for (end = p + 1; *end; end++)
5123 + if (*end == '<')
5124 + break;
5125 +
5126 + if (!streq(end, "<<2]"))
5127 + return 0;
5128 +
5129 + c = *end, *end = 0;
5130 + if (!match_intreg_part(p + 1))
5131 + ret = 0;
5132 + *end = c;
5133 +
5134 + if (ret)
5135 + {
5136 + c = *p, *p = 0;
5137 + regid = avr32_parse_intreg(str);
5138 + if (regid < 0)
5139 + ret = 0;
5140 + *p = c;
5141 + }
5142 +
5143 + return ret;
5144 +}
5145 +
5146 +/* The PC_UDISP_W operator may show up as a label or as a pc[disp]
5147 + expression. So there's no point in attempting to match this... */
5148 +#define match_pc_disp match_anything
5149 +
5150 +static int
5151 +match_sp(char *str)
5152 +{
5153 + /* SP in any form will do */
5154 + return avr32_parse_intreg(str) == AVR32_REG_SP;
5155 +}
5156 +
5157 +static int
5158 +match_sp_disp(char *str)
5159 +{
5160 + int regid, ret = 1;
5161 + char *p, c;
5162 +
5163 + for (p = str; *p; p++)
5164 + if (*p == '[')
5165 + break;
5166 +
5167 + /* allow empty displacement, meaning zero */
5168 + if (p[0] == '[')
5169 + {
5170 + char *end;
5171 + for (end = p + 1; *end; end++) ;
5172 + if (end[-1] != ']')
5173 + return 0;
5174 + }
5175 +
5176 + c = *p, *p = 0;
5177 + regid = avr32_parse_intreg(str);
5178 + if (regid != AVR32_REG_SP)
5179 + ret = 0;
5180 +
5181 + *p = c;
5182 + return ret;
5183 +}
5184 +
5185 +static int
5186 +match_cpno(char *str)
5187 +{
5188 + if (strncasecmp(str, "cp", 2) != 0)
5189 + return 0;
5190 + return 1;
5191 +}
5192 +
5193 +static int
5194 +match_cpreg(char *str)
5195 +{
5196 + if (strncasecmp(str, "cr", 2) != 0)
5197 + return 0;
5198 + return 1;
5199 +}
5200 +
5201 +/* We allow complex expressions, and register names may show up as
5202 + symbols. Just make sure immediate expressions are always matched
5203 + last. */
5204 +#define match_const match_anything
5205 +#define match_jmplabel match_anything
5206 +#define match_number match_anything
5207 +
5208 +/* Mnemonics that take reglists never accept anything else */
5209 +#define match_reglist8 match_anything
5210 +#define match_reglist9 match_anything
5211 +#define match_reglist16 match_anything
5212 +#define match_reglist_ldm match_anything
5213 +#define match_reglist_cp8 match_anything
5214 +#define match_reglist_cpd8 match_anything
5215 +
5216 +/* Ditto for retval, jospinc and mcall */
5217 +#define match_retval match_anything
5218 +#define match_jospinc match_anything
5219 +#define match_mcall match_anything
5220 +
5221 +/* COH is used to select between two different syntaxes */
5222 +static int
5223 +match_coh(char *str)
5224 +{
5225 + return strcasecmp(str, "coh") == 0;
5226 +}
5227 +
5228 +static int
5229 +match_fpreg(char *str)
5230 +{
5231 + unsigned long regid;
5232 + char *endptr;
5233 +
5234 + if ((str[0] != 'f' && str[0] != 'F')
5235 + || (str[1] != 'r' && str[1] != 'R'))
5236 + return 0;
5237 +
5238 + str += 2;
5239 + regid = strtoul(str, &endptr, 10);
5240 + if (!*str || *endptr)
5241 + return 0;
5242 +
5243 + return 1;
5244 +}
5245 +
5246 +static int
5247 +match_picoreg(char *str)
5248 +{
5249 + int regid;
5250 +
5251 + regid = avr32_parse_picoreg(str);
5252 + if (regid < 0)
5253 + return 0;
5254 + return 1;
5255 +}
5256 +
5257 +#define match_pico_reglist_w match_anything
5258 +#define match_pico_reglist_d match_anything
5259 +
5260 +static int
5261 +match_pico_in(char *str)
5262 +{
5263 + unsigned long regid;
5264 + char *end;
5265 +
5266 + if (strncasecmp(str, "in", 2) != 0)
5267 + return 0;
5268 +
5269 + str += 2;
5270 + regid = strtoul(str, &end, 10);
5271 + if (!*str || *end)
5272 + return 0;
5273 +
5274 + return 1;
5275 +}
5276 +
5277 +static int
5278 +match_pico_out0(char *str)
5279 +{
5280 + if (strcasecmp(str, "out0") != 0)
5281 + return 0;
5282 + return 1;
5283 +}
5284 +
5285 +static int
5286 +match_pico_out1(char *str)
5287 +{
5288 + if (strcasecmp(str, "out1") != 0)
5289 + return 0;
5290 + return 1;
5291 +}
5292 +
5293 +static int
5294 +match_pico_out2(char *str)
5295 +{
5296 + if (strcasecmp(str, "out2") != 0)
5297 + return 0;
5298 + return 1;
5299 +}
5300 +
5301 +static int
5302 +match_pico_out3(char *str)
5303 +{
5304 + if (strcasecmp(str, "out3") != 0)
5305 + return 0;
5306 + return 1;
5307 +}
5308 +
5309 +static void parse_nothing(const struct avr32_operand *op ATTRIBUTE_UNUSED,
5310 + char *str ATTRIBUTE_UNUSED,
5311 + int opindex ATTRIBUTE_UNUSED)
5312 +{
5313 + /* Do nothing (this is used for "match-only" operands like COH) */
5314 +}
5315 +
5316 +static void
5317 +parse_const(const struct avr32_operand *op, char *str,
5318 + int opindex ATTRIBUTE_UNUSED)
5319 +{
5320 + expressionS *exp = &current_insn.immediate;
5321 + expressionS *sym_exp;
5322 + int slot;
5323 + char *save;
5324 +
5325 + pr_debug("parse_const: `%s' (signed: %d, pcrel: %d, align: %d)\n",
5326 + str, op->is_signed, op->is_pcrel, op->align_order);
5327 +
5328 + save = input_line_pointer;
5329 + input_line_pointer = str;
5330 +
5331 + expression(exp);
5332 +
5333 + slot = current_insn.next_slot++;
5334 + current_insn.field_value[slot].align_order = op->align_order;
5335 + current_insn.pcrel = op->is_pcrel;
5336 +
5337 + switch (exp->X_op)
5338 + {
5339 + case O_illegal:
5340 + as_bad(_("illegal operand"));
5341 + break;
5342 + case O_absent:
5343 + as_bad(_("missing operand"));
5344 + break;
5345 + case O_constant:
5346 + pr_debug(" -> constant: %ld\n", (long)exp->X_add_number);
5347 + current_insn.field_value[slot].value = exp->X_add_number;
5348 + break;
5349 + case O_uminus:
5350 + pr_debug(" -> uminus\n");
5351 + sym_exp = symbol_get_value_expression(exp->X_add_symbol);
5352 + switch (sym_exp->X_op) {
5353 + case O_subtract:
5354 + pr_debug(" -> subtract: switching operands\n");
5355 + exp->X_op_symbol = sym_exp->X_add_symbol;
5356 + exp->X_add_symbol = sym_exp->X_op_symbol;
5357 + exp->X_op = O_subtract;
5358 + /* TODO: Remove the old X_add_symbol */
5359 + break;
5360 + default:
5361 + as_bad(_("Expression too complex\n"));
5362 + break;
5363 + }
5364 + break;
5365 +#if 0
5366 + case O_subtract:
5367 + /* Any expression subtracting a symbol from the current section
5368 + can be made PC-relative by adding the right offset. */
5369 + if (S_GET_SEGMENT(exp->X_op_symbol) == now_seg)
5370 + current_insn.pcrel = TRUE;
5371 + pr_debug(" -> subtract: pcrel? %s\n",
5372 + current_insn.pcrel ? "yes" : "no");
5373 + /* fall through */
5374 +#endif
5375 + default:
5376 + pr_debug(" -> (%p <%d> %p + %d)\n",
5377 + exp->X_add_symbol, exp->X_op, exp->X_op_symbol,
5378 + exp->X_add_number);
5379 + current_insn.field_value[slot].value = 0;
5380 + break;
5381 + }
5382 +
5383 + input_line_pointer = save;
5384 +}
5385 +
5386 +static void
5387 +parse_jmplabel(const struct avr32_operand *op, char *str,
5388 + int opindex ATTRIBUTE_UNUSED)
5389 +{
5390 + expressionS *exp = &current_insn.immediate;
5391 + int slot;
5392 + char *save;
5393 +
5394 + pr_debug("parse_jmplabel: `%s' (signed: %d, pcrel: %d, align: %d)\n",
5395 + str, op->is_signed, op->is_pcrel, op->align_order);
5396 +
5397 + save = input_line_pointer;
5398 + input_line_pointer = str;
5399 +
5400 + expression(exp);
5401 +
5402 + slot = current_insn.next_slot++;
5403 + current_insn.field_value[slot].align_order = op->align_order;
5404 + current_insn.pcrel = TRUE;
5405 +
5406 + switch (exp->X_op)
5407 + {
5408 + case O_illegal:
5409 + as_bad(_("illegal operand"));
5410 + break;
5411 + case O_absent:
5412 + as_bad(_("missing operand"));
5413 + break;
5414 + case O_constant:
5415 + pr_debug(" -> constant: %ld\n", (long)exp->X_add_number);
5416 + current_insn.field_value[slot].value = exp->X_add_number;
5417 + current_insn.pcrel = 0;
5418 + break;
5419 + default:
5420 + pr_debug(" -> (%p <%d> %p + %d)\n",
5421 + exp->X_add_symbol, exp->X_op, exp->X_op_symbol,
5422 + exp->X_add_number);
5423 + current_insn.field_value[slot].value = 0;
5424 + break;
5425 + }
5426 +
5427 + input_line_pointer = save;
5428 +}
5429 +
5430 +static void
5431 +parse_intreg(const struct avr32_operand *op ATTRIBUTE_UNUSED,
5432 + char *str, int opindex ATTRIBUTE_UNUSED)
5433 +{
5434 + int regid, slot;
5435 +
5436 + pr_debug("parse_intreg: `%s'\n", str);
5437 +
5438 + regid = avr32_parse_intreg(str);
5439 + assert(regid >= 0);
5440 +
5441 + slot = current_insn.next_slot++;
5442 + current_insn.field_value[slot].value = regid;
5443 + current_insn.field_value[slot].align_order = op->align_order;
5444 +}
5445 +
5446 +static void
5447 +parse_intreg_predec(const struct avr32_operand *op, char *str, int opindex)
5448 +{
5449 + parse_intreg(op, str + 2, opindex);
5450 +}
5451 +
5452 +static void
5453 +parse_intreg_postinc(const struct avr32_operand *op, char *str, int opindex)
5454 +{
5455 + char *p, c;
5456 +
5457 + pr_debug("parse_intreg_postinc: `%s'\n", str);
5458 +
5459 + for (p = str; *p != '+'; p++) ;
5460 +
5461 + c = *p, *p = 0;
5462 + parse_intreg(op, str, opindex);
5463 + *p = c;
5464 +}
5465 +
5466 +static void
5467 +parse_intreg_shift(const struct avr32_operand *op ATTRIBUTE_UNUSED,
5468 + char *str, int opindex ATTRIBUTE_UNUSED)
5469 +{
5470 + int regid, slot, shift = 0;
5471 + char *p, c;
5472 + char shiftop;
5473 +
5474 + pr_debug("parse Ry<<sa: `%s'\n", str);
5475 +
5476 + for (p = str; *p; p++)
5477 + if (*p == '<' || *p == '>')
5478 + break;
5479 +
5480 + shiftop = *p;
5481 +
5482 + c = *p, *p = 0;
5483 + regid = avr32_parse_intreg(str);
5484 + assert(regid >= 0);
5485 + *p = c;
5486 +
5487 + if (c)
5488 + {
5489 + if (p[0] != shiftop || p[1] != shiftop)
5490 + as_bad(_("expected shift operator in `%s'"), p);
5491 + else
5492 + {
5493 + expressionS exp;
5494 + char *saved;
5495 +
5496 + saved = input_line_pointer;
5497 + input_line_pointer = p + 2;
5498 + expression(&exp);
5499 + input_line_pointer = saved;
5500 +
5501 + if (exp.X_op != O_constant)
5502 + as_bad(_("shift amount must be a numeric constant"));
5503 + else
5504 + shift = exp.X_add_number;
5505 + }
5506 + }
5507 +
5508 + slot = current_insn.next_slot++;
5509 + current_insn.field_value[slot].value = regid;
5510 + slot = current_insn.next_slot++;
5511 + current_insn.field_value[slot].value = shift;
5512 +}
5513 +
5514 +/* The match() function selected the right opcode, so it doesn't
5515 + matter which way we shift any more. */
5516 +#define parse_intreg_lsl parse_intreg_shift
5517 +#define parse_intreg_lsr parse_intreg_shift
5518 +
5519 +static void
5520 +parse_intreg_part(const struct avr32_operand *op, char *str,
5521 + int opindex ATTRIBUTE_UNUSED)
5522 +{
5523 + static const char bparts[] = { 'b', 'l', 'u', 't' };
5524 + static const char hparts[] = { 'b', 't' };
5525 + unsigned int slot, sel;
5526 + int regid;
5527 + char *p, c;
5528 +
5529 + pr_debug("parse reg:part `%s'\n", str);
5530 +
5531 + for (p = str; *p; p++)
5532 + if (*p == ':')
5533 + break;
5534 +
5535 + c = *p, *p = 0;
5536 + regid = avr32_parse_intreg(str);
5537 + assert(regid >= 0);
5538 + *p = c;
5539 +
5540 + assert(c == ':');
5541 +
5542 + if (op->align_order)
5543 + {
5544 + for (sel = 0; sel < sizeof(hparts); sel++)
5545 + if (TOLOWER(p[1]) == hparts[sel])
5546 + break;
5547 +
5548 + if (sel >= sizeof(hparts))
5549 + {
5550 + as_bad(_("invalid halfword selector `%c' (must be either b or t)"),
5551 + p[1]);
5552 + sel = 0;
5553 + }
5554 + }
5555 + else
5556 + {
5557 + for (sel = 0; sel < sizeof(bparts); sel++)
5558 + if (TOLOWER(p[1]) == bparts[sel])
5559 + break;
5560 +
5561 + if (sel >= sizeof(bparts))
5562 + {
5563 + as_bad(_("invalid byte selector `%c' (must be one of b,l,u,t)"),
5564 + p[1]);
5565 + sel = 0;
5566 + }
5567 + }
5568 +
5569 + slot = current_insn.next_slot++;
5570 + current_insn.field_value[slot].value = regid;
5571 + slot = current_insn.next_slot++;
5572 + current_insn.field_value[slot].value = sel;
5573 +}
5574 +
5575 +/* This is the parser for "Rp[displacement]" expressions. In addition
5576 + to the "official" syntax, we accept a label as a replacement for
5577 + the register expression. This syntax implies Rp=PC and the
5578 + displacement is the pc-relative distance to the label. */
5579 +static void
5580 +parse_intreg_disp(const struct avr32_operand *op, char *str, int opindex)
5581 +{
5582 + expressionS *exp = &current_insn.immediate;
5583 + int slot, regid;
5584 + char *save, *p, c;
5585 +
5586 + pr_debug("parse_intreg_disp: `%s' (signed: %d, pcrel: %d, align: %d)\n",
5587 + str, op->is_signed, op->is_pcrel, op->align_order);
5588 +
5589 + for (p = str; *p; p++)
5590 + if (*p == '[')
5591 + break;
5592 +
5593 + slot = current_insn.next_slot++;
5594 +
5595 + /* First, check if we have a valid register either before '[' or as
5596 + the sole expression. If so, we use the Rp[disp] syntax. */
5597 + c = *p, *p = 0;
5598 + regid = avr32_parse_intreg(str);
5599 + *p = c;
5600 +
5601 + if (regid >= 0)
5602 + {
5603 + current_insn.field_value[slot].value = regid;
5604 +
5605 + slot = current_insn.next_slot++;
5606 + current_insn.field_value[slot].align_order = op->align_order;
5607 +
5608 + if (c == '[')
5609 + {
5610 + save = input_line_pointer;
5611 + input_line_pointer = p + 1;
5612 +
5613 + expression(exp);
5614 +
5615 + if (*input_line_pointer != ']')
5616 + as_bad(_("junk after displacement expression"));
5617 +
5618 + input_line_pointer = save;
5619 +
5620 + switch (exp->X_op)
5621 + {
5622 + case O_illegal:
5623 + as_bad(_("illegal displacement expression"));
5624 + break;
5625 + case O_absent:
5626 + as_bad(_("missing displacement expression"));
5627 + break;
5628 + case O_constant:
5629 + pr_debug(" -> constant: %ld\n", exp->X_add_number);
5630 + current_insn.field_value[slot].value = exp->X_add_number;
5631 + break;
5632 +#if 0
5633 + case O_subtract:
5634 + if (S_GET_SEGMENT(exp->X_op_symbol) == now_seg)
5635 + current_insn.pcrel = TRUE;
5636 + pr_debug(" -> subtract: pcrel? %s\n",
5637 + current_insn.pcrel ? "yes" : "no");
5638 + /* fall through */
5639 +#endif
5640 + default:
5641 + pr_debug(" -> (%p <%d> %p + %d)\n",
5642 + exp->X_add_symbol, exp->X_op, exp->X_op_symbol,
5643 + exp->X_add_number);
5644 + current_insn.field_value[slot].value = 0;
5645 + }
5646 + }
5647 + else
5648 + {
5649 + exp->X_op = O_constant;
5650 + exp->X_add_number = 0;
5651 + current_insn.field_value[slot].value = 0;
5652 + }
5653 + }
5654 + else
5655 + {
5656 + /* Didn't find a valid register. Try parsing it as a label. */
5657 + current_insn.field_value[slot].value = AVR32_REG_PC;
5658 + parse_jmplabel(op, str, opindex);
5659 + }
5660 +}
5661 +
5662 +static void
5663 +parse_intreg_index(const struct avr32_operand *op ATTRIBUTE_UNUSED,
5664 + char *str, int opindex ATTRIBUTE_UNUSED)
5665 +{
5666 + int slot, regid;
5667 + char *p, *end, c;
5668 +
5669 + for (p = str; *p; p++)
5670 + if (*p == '[')
5671 + break;
5672 +
5673 + assert(*p);
5674 +
5675 + c = *p, *p = 0;
5676 + regid = avr32_parse_intreg(str);
5677 + assert(regid >= 0);
5678 + *p = c;
5679 +
5680 + slot = current_insn.next_slot++;
5681 + current_insn.field_value[slot].value = regid;
5682 +
5683 + p++;
5684 + for (end = p; *end; end++)
5685 + if (*end == ']' || *end == '<')
5686 + break;
5687 +
5688 + assert(*end);
5689 +
5690 + c = *end, *end = 0;
5691 + regid = avr32_parse_intreg(p);
5692 + assert(regid >= 0);
5693 + *end = c;
5694 +
5695 + slot = current_insn.next_slot++;
5696 + current_insn.field_value[slot].value = regid;
5697 +
5698 + slot = current_insn.next_slot++;
5699 + current_insn.field_value[slot].value = 0;
5700 +
5701 + if (*end == '<')
5702 + {
5703 + expressionS exp;
5704 + char *save;
5705 +
5706 + p = end + 2;
5707 + for (end = p; *end; end++)
5708 + if (*end == ']')
5709 + break;
5710 +
5711 + assert(*end == ']');
5712 +
5713 + c = *end, *end = 0;
5714 + save = input_line_pointer;
5715 + input_line_pointer = p;
5716 + expression(&exp);
5717 +
5718 + if (*input_line_pointer)
5719 + as_bad(_("junk after shift expression"));
5720 +
5721 + *end = c;
5722 + input_line_pointer = save;
5723 +
5724 + if (exp.X_op == O_constant)
5725 + current_insn.field_value[slot].value = exp.X_add_number;
5726 + else
5727 + as_bad(_("shift expression too complex"));
5728 + }
5729 +}
5730 +
5731 +static void
5732 +parse_intreg_xindex(const struct avr32_operand *op, char *str, int opindex)
5733 +{
5734 + int slot, regid;
5735 + char *p, *end, c;
5736 +
5737 + for (p = str; *p; p++)
5738 + if (*p == '[')
5739 + break;
5740 +
5741 + assert(*p);
5742 +
5743 + c = *p, *p = 0;
5744 + regid = avr32_parse_intreg(str);
5745 + assert(regid >= 0);
5746 + *p = c;
5747 +
5748 + slot = current_insn.next_slot++;
5749 + current_insn.field_value[slot].value = regid;
5750 +
5751 + p++;
5752 + for (end = p; *end; end++)
5753 + if (*end == '<')
5754 + break;
5755 +
5756 + assert(*end);
5757 +
5758 + c = *end, *end = 0;
5759 + parse_intreg_part(op, p, opindex);
5760 + *end = c;
5761 +}
5762 +
5763 +static void
5764 +parse_pc_disp(const struct avr32_operand *op, char *str, int opindex)
5765 +{
5766 + char *p, c;
5767 +
5768 + for (p = str; *p; p++)
5769 + if (*p == '[')
5770 + break;
5771 +
5772 + /* The lddpc instruction comes in two different syntax variants:
5773 + lddpc reg, expression
5774 + lddpc reg, pc[disp]
5775 + If the operand contains a '[', we use the second form. */
5776 + if (*p)
5777 + {
5778 + int regid;
5779 +
5780 + c = *p, *p = 0;
5781 + regid = avr32_parse_intreg(str);
5782 + *p = c;
5783 + if (regid == AVR32_REG_PC)
5784 + {
5785 + char *end;
5786 +
5787 + for (end = ++p; *end; end++) ;
5788 + if (*(--end) != ']')
5789 + as_bad(_("unrecognized form of instruction: `%s'"), str);
5790 + else
5791 + {
5792 + c = *end, *end = 0;
5793 + parse_const(op, p, opindex);
5794 + *end = c;
5795 + current_insn.pcrel = 0;
5796 + }
5797 + }
5798 + else
5799 + as_bad(_("unrecognized form of instruction: `%s'"), str);
5800 + }
5801 + else
5802 + {
5803 + parse_jmplabel(op, str, opindex);
5804 + }
5805 +}
5806 +
5807 +static void parse_sp(const struct avr32_operand *op ATTRIBUTE_UNUSED,
5808 + char *str ATTRIBUTE_UNUSED,
5809 + int opindex ATTRIBUTE_UNUSED)
5810 +{
5811 + int slot;
5812 +
5813 + slot = current_insn.next_slot++;
5814 + current_insn.field_value[slot].value = AVR32_REG_SP;
5815 +}
5816 +
5817 +static void
5818 +parse_sp_disp(const struct avr32_operand *op, char *str, int opindex)
5819 +{
5820 + char *p, c;
5821 +
5822 + for (; *str; str++)
5823 + if (*str == '[')
5824 + break;
5825 +
5826 + assert(*str);
5827 +
5828 + for (p = ++str; *p; p++)
5829 + if (*p == ']')
5830 + break;
5831 +
5832 + c = *p, *p = 0;
5833 + parse_const(op, str, opindex);
5834 + *p = c;
5835 +}
5836 +
5837 +static void
5838 +parse_cpno(const struct avr32_operand *op ATTRIBUTE_UNUSED, char *str,
5839 + int opindex ATTRIBUTE_UNUSED)
5840 +{
5841 + int slot;
5842 +
5843 + str += 2;
5844 + if (*str == '#')
5845 + str++;
5846 + if (*str < '0' || *str > '7' || str[1])
5847 + as_bad(_("invalid coprocessor `%s'"), str);
5848 +
5849 + slot = current_insn.next_slot++;
5850 + current_insn.field_value[slot].value = *str - '0';
5851 +}
5852 +
5853 +static void
5854 +parse_cpreg(const struct avr32_operand *op, char *str,
5855 + int opindex ATTRIBUTE_UNUSED)
5856 +{
5857 + unsigned int crid;
5858 + int slot;
5859 + char *endptr;
5860 +
5861 + str += 2;
5862 + crid = strtoul(str, &endptr, 10);
5863 + if (*endptr || crid > 15 || crid & ((1 << op->align_order) - 1))
5864 + as_bad(_("invalid coprocessor register `%s'"), str);
5865 +
5866 + crid >>= op->align_order;
5867 +
5868 + slot = current_insn.next_slot++;
5869 + current_insn.field_value[slot].value = crid;
5870 +}
5871 +
5872 +static void
5873 +parse_number(const struct avr32_operand *op, char *str,
5874 + int opindex ATTRIBUTE_UNUSED)
5875 +{
5876 + expressionS exp;
5877 + int slot;
5878 + char *save;
5879 +
5880 + save = input_line_pointer;
5881 + input_line_pointer = str;
5882 + expression(&exp);
5883 + input_line_pointer = save;
5884 +
5885 + slot = current_insn.next_slot++;
5886 + current_insn.field_value[slot].align_order = op->align_order;
5887 +
5888 + if (exp.X_op == O_constant)
5889 + current_insn.field_value[slot].value = exp.X_add_number;
5890 + else
5891 + as_bad(_("invalid numeric expression `%s'"), str);
5892 +}
5893 +
5894 +static void
5895 +parse_reglist8(const struct avr32_operand *op ATTRIBUTE_UNUSED,
5896 + char *str, int opindex ATTRIBUTE_UNUSED)
5897 +{
5898 + unsigned long regmask;
5899 + unsigned long value = 0;
5900 + int slot;
5901 + char *tail;
5902 +
5903 + regmask = avr32_parse_reglist(str, &tail);
5904 + if (*tail)
5905 + as_bad(_("invalid register list `%s'"), str);
5906 + else
5907 + {
5908 + if (avr32_make_regmask8(regmask, &value))
5909 + as_bad(_("register list `%s' doesn't fit"), str);
5910 + }
5911 +
5912 + slot = current_insn.next_slot++;
5913 + current_insn.field_value[slot].value = value;
5914 +}
5915 +
5916 +static int
5917 +parse_reglist_tail(char *str, unsigned long regmask)
5918 +{
5919 + expressionS exp;
5920 + char *save, *p, c;
5921 + int regid;
5922 +
5923 + for (p = str + 1; *p; p++)
5924 + if (*p == '=')
5925 + break;
5926 +
5927 + if (!*p)
5928 + {
5929 + as_bad(_("invalid register list `%s'"), str);
5930 + return -2;
5931 + }
5932 +
5933 + c = *p, *p = 0;
5934 + regid = avr32_parse_intreg(str);
5935 + *p = c;
5936 +
5937 + if (regid != 12)
5938 + {
5939 + as_bad(_("invalid register list `%s'"), str);
5940 + return -2;
5941 + }
5942 +
5943 + /* If we have an assignment, we must pop PC and we must _not_
5944 + pop LR or R12 */
5945 + if (!(regmask & (1 << AVR32_REG_PC)))
5946 + {
5947 + as_bad(_("return value specified for non-return instruction"));
5948 + return -2;
5949 + }
5950 + else if (regmask & ((1 << AVR32_REG_R12) | (1 << AVR32_REG_LR)))
5951 + {
5952 + as_bad(_("can't pop LR or R12 when specifying return value"));
5953 + return -2;
5954 + }
5955 +
5956 + save = input_line_pointer;
5957 + input_line_pointer = p + 1;
5958 + expression(&exp);
5959 + input_line_pointer = save;
5960 +
5961 + if (exp.X_op != O_constant
5962 + || exp.X_add_number < -1
5963 + || exp.X_add_number > 1)
5964 + {
5965 + as_bad(_("invalid return value `%s'"), str);
5966 + return -2;
5967 + }
5968 +
5969 + return exp.X_add_number;
5970 +}
5971 +
5972 +static void
5973 +parse_reglist9(const struct avr32_operand *op ATTRIBUTE_UNUSED,
5974 + char *str, int opindex ATTRIBUTE_UNUSED)
5975 +{
5976 + unsigned long regmask;
5977 + unsigned long value = 0, kbit = 0;
5978 + int slot;
5979 + char *tail;
5980 +
5981 + regmask = avr32_parse_reglist(str, &tail);
5982 + /* printf("parsed reglist16: %04lx, tail: `%s'\n", regmask, tail); */
5983 + if (*tail)
5984 + {
5985 + int retval;
5986 +
5987 + retval = parse_reglist_tail(tail, regmask);
5988 +
5989 + switch (retval)
5990 + {
5991 + case -1:
5992 + regmask |= 1 << AVR32_REG_LR;
5993 + break;
5994 + case 0:
5995 + break;
5996 + case 1:
5997 + regmask |= 1 << AVR32_REG_R12;
5998 + break;
5999 + default:
6000 + break;
6001 + }
6002 +
6003 + kbit = 1;
6004 + }
6005 +
6006 + if (avr32_make_regmask8(regmask, &value))
6007 + as_bad(_("register list `%s' doesn't fit"), str);
6008 +
6009 +
6010 + slot = current_insn.next_slot++;
6011 + current_insn.field_value[slot].value = (value << 1) | kbit;
6012 +}
6013 +
6014 +static void
6015 +parse_reglist16(const struct avr32_operand *op ATTRIBUTE_UNUSED,
6016 + char *str, int opindex ATTRIBUTE_UNUSED)
6017 +{
6018 + unsigned long regmask;
6019 + int slot;
6020 + char *tail;
6021 +
6022 + regmask = avr32_parse_reglist(str, &tail);
6023 + if (*tail)
6024 + as_bad(_("invalid register list `%s'"), str);
6025 +
6026 + slot = current_insn.next_slot++;
6027 + current_insn.field_value[slot].value = regmask;
6028 +}
6029 +
6030 +static void
6031 +parse_reglist_ldm(const struct avr32_operand *op ATTRIBUTE_UNUSED,
6032 + char *str, int opindex ATTRIBUTE_UNUSED)
6033 +{
6034 + unsigned long regmask;
6035 + int slot, rp, w_bit = 0;
6036 + char *tail, *p, c;
6037 +
6038 + for (p = str; *p && *p != ','; p++)
6039 + if (*p == '+')
6040 + break;
6041 +
6042 + c = *p, *p = 0;
6043 + rp = avr32_parse_intreg(str);
6044 + *p = c;
6045 + if (rp < 0)
6046 + {
6047 + as_bad(_("invalid destination register in `%s'"), str);
6048 + return;
6049 + }
6050 +
6051 + if (p[0] == '+' && p[1] == '+')
6052 + {
6053 + w_bit = 1;
6054 + p += 2;
6055 + }
6056 +
6057 + if (*p != ',')
6058 + {
6059 + as_bad(_("expected `,' after destination register in `%s'"), str);
6060 + return;
6061 + }
6062 +
6063 + str = p + 1;
6064 + regmask = avr32_parse_reglist(str, &tail);
6065 + if (*tail)
6066 + {
6067 + int retval;
6068 +
6069 + if (rp != AVR32_REG_SP)
6070 + {
6071 + as_bad(_("junk at end of line: `%s'"), tail);
6072 + return;
6073 + }
6074 +
6075 + rp = AVR32_REG_PC;
6076 +
6077 + retval = parse_reglist_tail(tail, regmask);
6078 +
6079 + switch (retval)
6080 + {
6081 + case -1:
6082 + regmask |= 1 << AVR32_REG_LR;
6083 + break;
6084 + case 0:
6085 + break;
6086 + case 1:
6087 + regmask |= 1 << AVR32_REG_R12;
6088 + break;
6089 + default:
6090 + return;
6091 + }
6092 + }
6093 +
6094 + slot = current_insn.next_slot++;
6095 + current_insn.field_value[slot].value = rp;
6096 + slot = current_insn.next_slot++;
6097 + current_insn.field_value[slot].value = w_bit;
6098 + slot = current_insn.next_slot++;
6099 + current_insn.field_value[slot].value = regmask;
6100 +}
6101 +
6102 +static void
6103 +parse_reglist_cp8(const struct avr32_operand *op ATTRIBUTE_UNUSED,
6104 + char *str, int opindex ATTRIBUTE_UNUSED)
6105 +{
6106 + unsigned long regmask;
6107 + int slot, h_bit = 0;
6108 + char *tail;
6109 +
6110 + regmask = avr32_parse_cpreglist(str, &tail);
6111 + if (*tail)
6112 + as_bad(_("junk at end of line: `%s'"), tail);
6113 + else if (regmask & 0xffUL)
6114 + {
6115 + if (regmask & 0xff00UL)
6116 + as_bad(_("register list `%s' doesn't fit"), str);
6117 + regmask &= 0xff;
6118 + }
6119 + else if (regmask & 0xff00UL)
6120 + {
6121 + regmask >>= 8;
6122 + h_bit = 1;
6123 + }
6124 + else
6125 + as_warn(_("register list is empty"));
6126 +
6127 + slot = current_insn.next_slot++;
6128 + current_insn.field_value[slot].value = regmask;
6129 + slot = current_insn.next_slot++;
6130 + current_insn.field_value[slot].value = h_bit;
6131 +}
6132 +
6133 +static void
6134 +parse_reglist_cpd8(const struct avr32_operand *op ATTRIBUTE_UNUSED,
6135 + char *str, int opindex ATTRIBUTE_UNUSED)
6136 +{
6137 + unsigned long regmask, regmask_d = 0;
6138 + int slot, i;
6139 + char *tail;
6140 +
6141 + regmask = avr32_parse_cpreglist(str, &tail);
6142 + if (*tail)
6143 + as_bad(_("junk at end of line: `%s'"), tail);
6144 +
6145 + for (i = 0; i < 8; i++)
6146 + {
6147 + if (regmask & 1)
6148 + {
6149 + if (!(regmask & 2))
6150 + {
6151 + as_bad(_("register list `%s' doesn't fit"), str);
6152 + break;
6153 + }
6154 + regmask_d |= 1 << i;
6155 + }
6156 + else if (regmask & 2)
6157 + {
6158 + as_bad(_("register list `%s' doesn't fit"), str);
6159 + break;
6160 + }
6161 +
6162 + regmask >>= 2;
6163 + }
6164 +
6165 + slot = current_insn.next_slot++;
6166 + current_insn.field_value[slot].value = regmask_d;
6167 +}
6168 +
6169 +static void
6170 +parse_retval(const struct avr32_operand *op ATTRIBUTE_UNUSED,
6171 + char *str, int opindex ATTRIBUTE_UNUSED)
6172 +{
6173 + int regid, slot;
6174 +
6175 + regid = avr32_parse_intreg(str);
6176 + if (regid < 0)
6177 + {
6178 + expressionS exp;
6179 + char *save;
6180 +
6181 + regid = 0;
6182 +
6183 + save = input_line_pointer;
6184 + input_line_pointer = str;
6185 + expression(&exp);
6186 + input_line_pointer = save;
6187 +
6188 + if (exp.X_op != O_constant)
6189 + as_bad(_("invalid return value `%s'"), str);
6190 + else
6191 + switch (exp.X_add_number)
6192 + {
6193 + case -1:
6194 + regid = AVR32_REG_LR;
6195 + break;
6196 + case 0:
6197 + regid = AVR32_REG_SP;
6198 + break;
6199 + case 1:
6200 + regid = AVR32_REG_PC;
6201 + break;
6202 + default:
6203 + as_bad(_("invalid return value `%s'"), str);
6204 + break;
6205 + }
6206 + }
6207 +
6208 + slot = current_insn.next_slot++;
6209 + current_insn.field_value[slot].value = regid;
6210 +}
6211 +
6212 +#define parse_mcall parse_intreg_disp
6213 +
6214 +static void
6215 +parse_jospinc(const struct avr32_operand *op ATTRIBUTE_UNUSED,
6216 + char *str, int opindex ATTRIBUTE_UNUSED)
6217 +{
6218 + expressionS exp;
6219 + int slot;
6220 + char *save;
6221 +
6222 + save = input_line_pointer;
6223 + input_line_pointer = str;
6224 + expression(&exp);
6225 + input_line_pointer = save;
6226 +
6227 + slot = current_insn.next_slot++;
6228 +
6229 + if (exp.X_op == O_constant)
6230 + {
6231 + if (exp.X_add_number > 0)
6232 + exp.X_add_number--;
6233 + current_insn.field_value[slot].value = exp.X_add_number;
6234 + }
6235 + else
6236 + as_bad(_("invalid numeric expression `%s'"), str);
6237 +}
6238 +
6239 +#define parse_coh parse_nothing
6240 +
6241 +static void
6242 +parse_fpreg(const struct avr32_operand *op,
6243 + char *str, int opindex ATTRIBUTE_UNUSED)
6244 +{
6245 + unsigned long regid;
6246 + int slot;
6247 +
6248 + regid = strtoul(str + 2, NULL, 10);
6249 +
6250 + if ((regid >= 16) || (regid & ((1 << op->align_order) - 1)))
6251 + as_bad(_("invalid floating-point register `%s'"), str);
6252 +
6253 + slot = current_insn.next_slot++;
6254 + current_insn.field_value[slot].value = regid;
6255 + current_insn.field_value[slot].align_order = op->align_order;
6256 +}
6257 +
6258 +static void
6259 +parse_picoreg(const struct avr32_operand *op,
6260 + char *str, int opindex ATTRIBUTE_UNUSED)
6261 +{
6262 + unsigned long regid;
6263 + int slot;
6264 +
6265 + regid = avr32_parse_picoreg(str);
6266 + if (regid & ((1 << op->align_order) - 1))
6267 + as_bad(_("invalid double-word PiCo register `%s'"), str);
6268 +
6269 + slot = current_insn.next_slot++;
6270 + current_insn.field_value[slot].value = regid;
6271 + current_insn.field_value[slot].align_order = op->align_order;
6272 +}
6273 +
6274 +static void
6275 +parse_pico_reglist_w(const struct avr32_operand *op ATTRIBUTE_UNUSED,
6276 + char *str, int opindex ATTRIBUTE_UNUSED)
6277 +{
6278 + unsigned long regmask;
6279 + int slot, h_bit = 0;
6280 + char *tail;
6281 +
6282 + regmask = avr32_parse_pico_reglist(str, &tail);
6283 + if (*tail)
6284 + as_bad(_("junk at end of line: `%s'"), tail);
6285 +
6286 + if (regmask & 0x00ffUL)
6287 + {
6288 + if (regmask & 0xff00UL)
6289 + as_bad(_("register list `%s' doesn't fit"), str);
6290 + regmask &= 0x00ffUL;
6291 + }
6292 + else if (regmask & 0xff00UL)
6293 + {
6294 + regmask >>= 8;
6295 + h_bit = 1;
6296 + }
6297 + else
6298 + as_warn(_("register list is empty"));
6299 +
6300 + slot = current_insn.next_slot++;
6301 + current_insn.field_value[slot].value = regmask;
6302 + slot = current_insn.next_slot++;
6303 + current_insn.field_value[slot].value = h_bit;
6304 +}
6305 +
6306 +static void
6307 +parse_pico_reglist_d(const struct avr32_operand *op ATTRIBUTE_UNUSED,
6308 + char *str, int opindex ATTRIBUTE_UNUSED)
6309 +{
6310 + unsigned long regmask, regmask_d = 0;
6311 + int slot, i;
6312 + char *tail;
6313 +
6314 + regmask = avr32_parse_pico_reglist(str, &tail);
6315 + if (*tail)
6316 + as_bad(_("junk at end of line: `%s'"), tail);
6317 +
6318 + for (i = 0; i < 8; i++)
6319 + {
6320 + if (regmask & 1)
6321 + {
6322 + if (!(regmask & 2))
6323 + {
6324 + as_bad(_("register list `%s' doesn't fit"), str);
6325 + break;
6326 + }
6327 + regmask_d |= 1 << i;
6328 + }
6329 + else if (regmask & 2)
6330 + {
6331 + as_bad(_("register list `%s' doesn't fit"), str);
6332 + break;
6333 + }
6334 +
6335 + regmask >>= 2;
6336 + }
6337 +
6338 + slot = current_insn.next_slot++;
6339 + current_insn.field_value[slot].value = regmask_d;
6340 +}
6341 +
6342 +static void
6343 +parse_pico_in(const struct avr32_operand *op ATTRIBUTE_UNUSED,
6344 + char *str, int opindex ATTRIBUTE_UNUSED)
6345 +{
6346 + unsigned long regid;
6347 + int slot;
6348 +
6349 + regid = strtoul(str + 2, NULL, 10);
6350 +
6351 + if (regid >= 12)
6352 + as_bad(_("invalid PiCo IN register `%s'"), str);
6353 +
6354 + slot = current_insn.next_slot++;
6355 + current_insn.field_value[slot].value = regid;
6356 + current_insn.field_value[slot].align_order = 0;
6357 +}
6358 +
6359 +#define parse_pico_out0 parse_nothing
6360 +#define parse_pico_out1 parse_nothing
6361 +#define parse_pico_out2 parse_nothing
6362 +#define parse_pico_out3 parse_nothing
6363 +
6364 +#define OP(name, sgn, pcrel, align, func) \
6365 + { AVR32_OPERAND_##name, sgn, pcrel, align, match_##func, parse_##func }
6366 +
6367 +struct avr32_operand avr32_operand_table[] = {
6368 + OP(INTREG, 0, 0, 0, intreg),
6369 + OP(INTREG_PREDEC, 0, 0, 0, intreg_predec),
6370 + OP(INTREG_POSTINC, 0, 0, 0, intreg_postinc),
6371 + OP(INTREG_LSL, 0, 0, 0, intreg_lsl),
6372 + OP(INTREG_LSR, 0, 0, 0, intreg_lsr),
6373 + OP(INTREG_BSEL, 0, 0, 0, intreg_part),
6374 + OP(INTREG_HSEL, 0, 0, 1, intreg_part),
6375 + OP(INTREG_SDISP, 1, 0, 0, intreg_disp),
6376 + OP(INTREG_SDISP_H, 1, 0, 1, intreg_disp),
6377 + OP(INTREG_SDISP_W, 1, 0, 2, intreg_disp),
6378 + OP(INTREG_UDISP, 0, 0, 0, intreg_disp),
6379 + OP(INTREG_UDISP_H, 0, 0, 1, intreg_disp),
6380 + OP(INTREG_UDISP_W, 0, 0, 2, intreg_disp),
6381 + OP(INTREG_INDEX, 0, 0, 0, intreg_index),
6382 + OP(INTREG_XINDEX, 0, 0, 0, intreg_xindex),
6383 + OP(DWREG, 0, 0, 1, intreg),
6384 + OP(PC_UDISP_W, 0, 1, 2, pc_disp),
6385 + OP(SP, 0, 0, 0, sp),
6386 + OP(SP_UDISP_W, 0, 0, 2, sp_disp),
6387 + OP(CPNO, 0, 0, 0, cpno),
6388 + OP(CPREG, 0, 0, 0, cpreg),
6389 + OP(CPREG_D, 0, 0, 1, cpreg),
6390 + OP(UNSIGNED_CONST, 0, 0, 0, const),
6391 + OP(UNSIGNED_CONST_W, 0, 0, 2, const),
6392 + OP(SIGNED_CONST, 1, 0, 0, const),
6393 + OP(SIGNED_CONST_W, 1, 0, 2, const),
6394 + OP(JMPLABEL, 1, 1, 1, jmplabel),
6395 + OP(UNSIGNED_NUMBER, 0, 0, 0, number),
6396 + OP(UNSIGNED_NUMBER_W, 0, 0, 2, number),
6397 + OP(REGLIST8, 0, 0, 0, reglist8),
6398 + OP(REGLIST9, 0, 0, 0, reglist9),
6399 + OP(REGLIST16, 0, 0, 0, reglist16),
6400 + OP(REGLIST_LDM, 0, 0, 0, reglist_ldm),
6401 + OP(REGLIST_CP8, 0, 0, 0, reglist_cp8),
6402 + OP(REGLIST_CPD8, 0, 0, 0, reglist_cpd8),
6403 + OP(RETVAL, 0, 0, 0, retval),
6404 + OP(MCALL, 1, 0, 2, mcall),
6405 + OP(JOSPINC, 0, 0, 0, jospinc),
6406 + OP(COH, 0, 0, 0, coh),
6407 + OP(FPREG_S, 0, 0, 0, fpreg),
6408 + OP(FPREG_D, 0, 0, 1, fpreg),
6409 + OP(PICO_REG_W, 0, 0, 0, picoreg),
6410 + OP(PICO_REG_D, 0, 0, 1, picoreg),
6411 + OP(PICO_REGLIST_W, 0, 0, 0, pico_reglist_w),
6412 + OP(PICO_REGLIST_D, 0, 0, 0, pico_reglist_d),
6413 + OP(PICO_IN, 0, 0, 0, pico_in),
6414 + OP(PICO_OUT0, 0, 0, 0, pico_out0),
6415 + OP(PICO_OUT1, 0, 0, 0, pico_out1),
6416 + OP(PICO_OUT2, 0, 0, 0, pico_out2),
6417 + OP(PICO_OUT3, 0, 0, 0, pico_out3),
6418 +};
6419 +
6420 +symbolS *
6421 +md_undefined_symbol (char *name ATTRIBUTE_UNUSED)
6422 +{
6423 + pr_debug("md_undefined_symbol: %s\n", name);
6424 + return 0;
6425 +}
6426 +
6427 +struct avr32_relax_type
6428 +{
6429 + long lower_bound;
6430 + long upper_bound;
6431 + unsigned char align;
6432 + unsigned char length;
6433 + signed short next;
6434 +};
6435 +
6436 +#define EMPTY { 0, 0, 0, 0, -1 }
6437 +#define C(lower, upper, align, next) \
6438 + { (lower), (upper), (align), 2, AVR32_OPC_##next }
6439 +#define E(lower, upper, align) \
6440 + { (lower), (upper), (align), 4, -1 }
6441 +
6442 +static const struct avr32_relax_type avr32_relax_table[] =
6443 + {
6444 + /* 0 */
6445 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6446 + EMPTY, EMPTY, EMPTY,
6447 + E(0, 65535, 0), E(0, 65535, 0), E(0, 65535, 0), E(0, 65535, 0),
6448 + EMPTY,
6449 + /* 16 */
6450 + EMPTY, EMPTY, EMPTY, EMPTY,
6451 +
6452 + C(-256, 254, 1, BREQ2), C(-256, 254, 1, BRNE2),
6453 + C(-256, 254, 1, BRCC2), C(-256, 254, 1, BRCS2),
6454 + C(-256, 254, 1, BRGE2), C(-256, 254, 1, BRLT2),
6455 + C(-256, 254, 1, BRMI2), C(-256, 254, 1, BRPL2),
6456 + E(-2097152, 2097150, 1), E(-2097152, 2097150, 1),
6457 + E(-2097152, 2097150, 1), E(-2097152, 2097150, 1),
6458 + /* 32 */
6459 + E(-2097152, 2097150, 1), E(-2097152, 2097150, 1),
6460 + E(-2097152, 2097150, 1), E(-2097152, 2097150, 1),
6461 + E(-2097152, 2097150, 1), E(-2097152, 2097150, 1),
6462 + E(-2097152, 2097150, 1), E(-2097152, 2097150, 1),
6463 + E(-2097152, 2097150, 1), E(-2097152, 2097150, 1),
6464 + E(-2097152, 2097150, 1), E(-2097152, 2097150, 1),
6465 +
6466 + EMPTY, EMPTY, EMPTY, EMPTY,
6467 + /* 48 */
6468 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6469 + EMPTY, EMPTY, EMPTY,
6470 +
6471 + C(-32, 31, 0, CP_W3), E(-1048576, 1048575, 0),
6472 +
6473 + EMPTY, EMPTY, EMPTY,
6474 + /* 64: csrfcz */
6475 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6476 + E(0, 65535, 0), E(0, 65535, 0),
6477 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6478 + E(-32768, 32767, 0),
6479 + /* 80: LD_SB2 */
6480 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6481 +
6482 + C(0, 7, 0, LD_UB4), E(-32768, 32767, 0),
6483 +
6484 + EMPTY,
6485 + EMPTY, EMPTY,
6486 +
6487 + C(0, 14, 1, LD_SH4), E(-32768, 32767, 0),
6488 +
6489 + EMPTY, EMPTY, EMPTY,
6490 +
6491 + C(0, 14, 1, LD_UH4),
6492 +
6493 + /* 96: LD_UH4 */
6494 + E(-32768, 32767, 0),
6495 +
6496 + EMPTY, EMPTY, EMPTY, EMPTY,
6497 +
6498 + C(0, 124, 2, LD_W4), E(-32768, 32767, 0),
6499 +
6500 + E(0, 1020, 2), /* LDC_D1 */
6501 + EMPTY, EMPTY,
6502 + E(0, 1020, 2), /* LDC_W1 */
6503 + EMPTY, EMPTY,
6504 + E(0, 16380, 2), /* LDC0_D */
6505 + E(0, 16380, 2), /* LDC0_W */
6506 + EMPTY,
6507 +
6508 + /* 112: LDCM_D_PU */
6509 + EMPTY, EMPTY, EMPTY,
6510 +
6511 + C(0, 508, 2, LDDPC_EXT), E(-32768, 32767, 0),
6512 +
6513 + EMPTY,EMPTY, EMPTY,
6514 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6515 +
6516 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6517 + /* 134: MACHH_W */
6518 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6519 + E(-131072, 131068, 2), /* MCALL */
6520 + E(0, 1020, 2), /* MFDR */
6521 + E(0, 1020, 2), /* MFSR */
6522 + EMPTY, EMPTY,
6523 +
6524 + C(-128, 127, 0, MOV2), E(-1048576, 1048575, 0),
6525 +
6526 + EMPTY, EMPTY, EMPTY,
6527 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6528 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6529 +
6530 + E(-128, 127, 0), /* MOVEQ2 */
6531 + E(-128, 127, 0), /* MOVNE2 */
6532 + E(-128, 127, 0), /* MOVCC2 */
6533 + E(-128, 127, 0), /* 166: MOVCS2 */
6534 + E(-128, 127, 0), /* MOVGE2 */
6535 + E(-128, 127, 0), /* MOVLT2 */
6536 + E(-128, 127, 0), /* MOVMI2 */
6537 + E(-128, 127, 0), /* MOVPL2 */
6538 + E(-128, 127, 0), /* MOVLS2 */
6539 + E(-128, 127, 0), /* MOVGT2 */
6540 + E(-128, 127, 0), /* MOVLE2 */
6541 + E(-128, 127, 0), /* MOVHI2 */
6542 + E(-128, 127, 0), /* MOVVS2 */
6543 + E(-128, 127, 0), /* MOVVC2 */
6544 + E(-128, 127, 0), /* MOVQS2 */
6545 + E(-128, 127, 0), /* MOVAL2 */
6546 +
6547 + E(0, 1020, 2), /* MTDR */
6548 + E(0, 1020, 2), /* MTSR */
6549 + EMPTY,
6550 + EMPTY,
6551 + E(-128, 127, 0), /* MUL3 */
6552 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6553 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6554 + /* 198: MVCR_W */
6555 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6556 + E(0, 65535, 0), E(0, 65535, 0),
6557 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6558 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6559 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6560 + /* 230: PASR_H */
6561 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6562 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6563 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6564 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6565 + /* 262: PUNPCKSB_H */
6566 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6567 +
6568 + C(-1024, 1022, 1, RCALL2), E(-2097152, 2097150, 1),
6569 +
6570 + EMPTY,
6571 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6572 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6573 + EMPTY, EMPTY, EMPTY,
6574 +
6575 + C(-1024, 1022, 1, BRAL),
6576 +
6577 + EMPTY, EMPTY, EMPTY,
6578 + E(-128, 127, 0), /* RSUB2 */
6579 + /* 294: SATADD_H */
6580 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6581 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6582 + E(0, 255, 0), /* SLEEP */
6583 + EMPTY, EMPTY,
6584 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6585 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6586 + /* 326: ST_B2 */
6587 + EMPTY, EMPTY,
6588 + C(0, 7, 0, ST_B4), E(-32768, 32767, 0),
6589 + EMPTY, EMPTY, EMPTY, EMPTY,
6590 + E(-32768, 32767, 0),
6591 + EMPTY, EMPTY, EMPTY,
6592 + C(0, 14, 1, ST_H4), E(-32768, 32767, 0),
6593 + EMPTY, EMPTY,
6594 + EMPTY,
6595 + C(0, 60, 2, ST_W4), E(-32768, 32767, 0),
6596 + E(0, 1020, 2), /* STC_D1 */
6597 + EMPTY, EMPTY,
6598 + E(0, 1020, 2), /* STC_W1 */
6599 + EMPTY, EMPTY,
6600 + E(0, 16380, 2), /* STC0_D */
6601 + E(0, 16380, 2), /* STC0_W */
6602 +
6603 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6604 + /* 358: STDSP */
6605 + EMPTY, EMPTY,
6606 + E(0, 1020, 2), /* STHH_W1 */
6607 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6608 + EMPTY, EMPTY, EMPTY,
6609 + E(-32768, 32767, 0),
6610 + C(-512, 508, 2, SUB4),
6611 + C(-128, 127, 0, SUB4), E(-1048576, 1048576, 0),
6612 + /* SUB{cond} */
6613 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6614 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6615 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6616 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6617 + /* SUBF{cond} */
6618 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6619 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6620 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6621 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6622 + EMPTY,
6623 +
6624 + /* 406: SWAP_B */
6625 + EMPTY, EMPTY, EMPTY,
6626 + E(0, 255, 0), /* SYNC */
6627 + EMPTY, EMPTY, EMPTY, EMPTY,
6628 + /* 414: TST */
6629 + EMPTY, EMPTY, E(-65536, 65535, 2), E(-65536, 65535, 2), E(-65536, 65535, 2), EMPTY, EMPTY, EMPTY,
6630 + /* 422: RSUB{cond} */
6631 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6632 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6633 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6634 + E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0), E(-128, 127, 0),
6635 + /* 436: ADD{cond} */
6636 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6637 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6638 + /* 454: SUB{cond} */
6639 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6640 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6641 + /* 472: AND{cond} */
6642 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6643 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6644 + /* 486: OR{cond} */
6645 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6646 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6647 + /* 502: EOR{cond} */
6648 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6649 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6650 + /* 518: LD.w{cond} */
6651 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6652 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6653 + /* 534: LD.sh{cond} */
6654 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6655 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6656 + /* 550: LD.uh{cond} */
6657 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6658 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6659 + /* 566: LD.sb{cond} */
6660 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6661 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6662 + /* 582: LD.ub{cond} */
6663 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6664 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6665 + /* 596: ST.w{cond} */
6666 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6667 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6668 + /* 614: ST.h{cond} */
6669 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6670 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6671 + /* 630: ST.b{cond} */
6672 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6673 + EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY, EMPTY,
6674 + /* 646: movh */
6675 + E(0, 65535, 0)
6676 + };
6677 +
6678 +#undef E
6679 +#undef C
6680 +#undef EMPTY
6681 +
6682 +#define AVR32_RS_NONE (-1)
6683 +
6684 +#define avr32_rs_size(state) (avr32_relax_table[(state)].length)
6685 +#define avr32_rs_align(state) (avr32_relax_table[(state)].align)
6686 +#define relax_more(state) (avr32_relax_table[(state)].next)
6687 +
6688 +#define opc_initial_substate(opc) ((opc)->id)
6689 +
6690 +static int need_relax(int subtype, offsetT distance)
6691 +{
6692 + offsetT upper_bound, lower_bound;
6693 +
6694 + upper_bound = avr32_relax_table[subtype].upper_bound;
6695 + lower_bound = avr32_relax_table[subtype].lower_bound;
6696 +
6697 + if (distance & ((1 << avr32_rs_align(subtype)) - 1))
6698 + return 1;
6699 + if ((distance > upper_bound) || (distance < lower_bound))
6700 + return 1;
6701 +
6702 + return 0;
6703 +}
6704 +
6705 +enum {
6706 + LDA_SUBTYPE_MOV1,
6707 + LDA_SUBTYPE_MOV2,
6708 + LDA_SUBTYPE_SUB,
6709 + LDA_SUBTYPE_LDDPC,
6710 + LDA_SUBTYPE_LDW,
6711 + LDA_SUBTYPE_GOTLOAD,
6712 + LDA_SUBTYPE_GOTLOAD_LARGE,
6713 +};
6714 +
6715 +enum {
6716 + CALL_SUBTYPE_RCALL1,
6717 + CALL_SUBTYPE_RCALL2,
6718 + CALL_SUBTYPE_MCALL_CP,
6719 + CALL_SUBTYPE_MCALL_GOT,
6720 + CALL_SUBTYPE_MCALL_LARGE,
6721 +};
6722 +
6723 +#define LDA_INITIAL_SIZE (avr32_pic ? 4 : 2)
6724 +#define CALL_INITIAL_SIZE 2
6725 +
6726 +#define need_reloc(sym, seg, pcrel) \
6727 + (!(S_IS_DEFINED(sym) \
6728 + && ((pcrel && S_GET_SEGMENT(sym) == seg) \
6729 + || (!pcrel && S_GET_SEGMENT(sym) == absolute_section))) \
6730 + || S_FORCE_RELOC(sym, 1))
6731 +
6732 +/* Return an initial guess of the length by which a fragment must grow to
6733 + hold a branch to reach its destination.
6734 + Also updates fr_type/fr_subtype as necessary.
6735 +
6736 + Called just before doing relaxation.
6737 + Any symbol that is now undefined will not become defined.
6738 + The guess for fr_var is ACTUALLY the growth beyond fr_fix.
6739 + Whatever we do to grow fr_fix or fr_var contributes to our returned value.
6740 + Although it may not be explicit in the frag, pretend fr_var starts with a
6741 + 0 value. */
6742 +
6743 +static int
6744 +avr32_default_estimate_size_before_relax (fragS *fragP, segT segment)
6745 +{
6746 + int growth = 0;
6747 +
6748 + assert(fragP);
6749 + assert(fragP->fr_symbol);
6750 +
6751 + if (fragP->tc_frag_data.force_extended
6752 + || need_reloc(fragP->fr_symbol, segment, fragP->tc_frag_data.pcrel))
6753 + {
6754 + int largest_state = fragP->fr_subtype;
6755 + while (relax_more(largest_state) != AVR32_RS_NONE)
6756 + largest_state = relax_more(largest_state);
6757 + growth = avr32_rs_size(largest_state) - fragP->fr_var;
6758 + }
6759 + else
6760 + {
6761 + growth = avr32_rs_size(fragP->fr_subtype) - fragP->fr_var;
6762 + }
6763 +
6764 + pr_debug("%s:%d: md_estimate_size_before_relax: %d\n",
6765 + fragP->fr_file, fragP->fr_line, growth);
6766 +
6767 + return growth;
6768 +}
6769 +
6770 +static int
6771 +avr32_lda_estimate_size_before_relax(fragS *fragP, segT segment ATTRIBUTE_UNUSED)
6772 +{
6773 + return fragP->fr_var - LDA_INITIAL_SIZE;
6774 +}
6775 +
6776 +static int
6777 +avr32_call_estimate_size_before_relax(fragS *fragP, segT segment ATTRIBUTE_UNUSED)
6778 +{
6779 + return fragP->fr_var - CALL_INITIAL_SIZE;
6780 +}
6781 +
6782 +static int
6783 +avr32_cpool_estimate_size_before_relax(fragS *fragP,
6784 + segT segment ATTRIBUTE_UNUSED)
6785 +{
6786 + return fragP->fr_var;
6787 +}
6788 +
6789 +/* This macro may be defined to relax a frag. GAS will call this with the
6790 + * segment, the frag, and the change in size of all previous frags;
6791 + * md_relax_frag should return the change in size of the frag. */
6792 +static long
6793 +avr32_default_relax_frag (segT segment, fragS *fragP, long stretch)
6794 +{
6795 + int state, next_state;
6796 + symbolS *symbolP; /* The target symbol */
6797 + long growth = 0;
6798 +
6799 + state = next_state = fragP->fr_subtype;
6800 +
6801 + symbolP = fragP->fr_symbol;
6802 +
6803 + if (fragP->tc_frag_data.force_extended
6804 + || need_reloc(symbolP, segment, fragP->tc_frag_data.pcrel))
6805 + {
6806 + /* Symbol must be resolved by the linker. Emit the largest
6807 + possible opcode. */
6808 + while (relax_more(next_state) != AVR32_RS_NONE)
6809 + next_state = relax_more(next_state);
6810 + }
6811 + else
6812 + {
6813 + addressT address; /* The address of fragP */
6814 + addressT target; /* The address of the target symbol */
6815 + offsetT distance; /* The distance between the insn and the symbol */
6816 + fragS *sym_frag;
6817 +
6818 + address = fragP->fr_address;
6819 + target = fragP->fr_offset;
6820 + symbolP = fragP->fr_symbol;
6821 + sym_frag = symbol_get_frag(symbolP);
6822 +
6823 + address += fragP->fr_fix - fragP->fr_var;
6824 + target += S_GET_VALUE(symbolP);
6825 +
6826 + if (stretch != 0
6827 + && sym_frag->relax_marker != fragP->relax_marker
6828 + && S_GET_SEGMENT(symbolP) == segment)
6829 + /* if it was correctly aligned before, make sure it stays aligned */
6830 + target += stretch & (~0UL << avr32_rs_align(state));
6831 +
6832 + if (fragP->tc_frag_data.pcrel)
6833 + distance = target - (address & (~0UL << avr32_rs_align(state)));
6834 + else
6835 + distance = target;
6836 +
6837 + pr_debug("%s:%d: relax more? 0x%x - 0x%x = 0x%x (%d), align %d\n",
6838 + fragP->fr_file, fragP->fr_line, target, address,
6839 + distance, distance, avr32_rs_align(state));
6840 +
6841 + if (need_relax(state, distance))
6842 + {
6843 + if (relax_more(state) != AVR32_RS_NONE)
6844 + next_state = relax_more(state);
6845 + pr_debug("%s:%d: relax more %d -> %d (%d - %d, align %d)\n",
6846 + fragP->fr_file, fragP->fr_line, state, next_state,
6847 + target, address, avr32_rs_align(state));
6848 + }
6849 + }
6850 +
6851 + growth = avr32_rs_size(next_state) - avr32_rs_size(state);
6852 + fragP->fr_subtype = next_state;
6853 +
6854 + pr_debug("%s:%d: md_relax_frag: growth=%d, subtype=%d, opc=0x%08lx\n",
6855 + fragP->fr_file, fragP->fr_line, growth, fragP->fr_subtype,
6856 + avr32_opc_table[next_state].value);
6857 +
6858 + return growth;
6859 +}
6860 +
6861 +static long
6862 +avr32_lda_relax_frag(segT segment, fragS *fragP, long stretch)
6863 +{
6864 + struct cpool *pool= NULL;
6865 + unsigned int entry = 0;
6866 + addressT address, target;
6867 + offsetT distance;
6868 + symbolS *symbolP;
6869 + fragS *sym_frag;
6870 + long old_size, new_size;
6871 +
6872 + symbolP = fragP->fr_symbol;
6873 + old_size = fragP->fr_var;
6874 + if (!avr32_pic)
6875 + {
6876 + pool = fragP->tc_frag_data.pool;
6877 + entry = fragP->tc_frag_data.pool_entry;
6878 + }
6879 +
6880 + address = fragP->fr_address;
6881 + address += fragP->fr_fix - LDA_INITIAL_SIZE;
6882 +
6883 + if (!S_IS_DEFINED(symbolP) || S_FORCE_RELOC(symbolP, 1))
6884 + goto relax_max;
6885 +
6886 + target = fragP->fr_offset;
6887 + sym_frag = symbol_get_frag(symbolP);
6888 + target += S_GET_VALUE(symbolP);
6889 +
6890 + if (sym_frag->relax_marker != fragP->relax_marker
6891 + && S_GET_SEGMENT(symbolP) == segment)
6892 + target += stretch;
6893 +
6894 + distance = target - address;
6895 +
6896 + pr_debug("lda_relax_frag: target: %d, address: %d, var: %d\n",
6897 + target, address, fragP->fr_var);
6898 +
6899 + if (!avr32_pic && S_GET_SEGMENT(symbolP) == absolute_section
6900 + && target <= 127 && (offsetT)target >= -128)
6901 + {
6902 + if (fragP->fr_subtype == LDA_SUBTYPE_LDDPC
6903 + || fragP->fr_subtype == LDA_SUBTYPE_LDW)
6904 + pool->literals[entry].refcount--;
6905 + new_size = 2;
6906 + fragP->fr_subtype = LDA_SUBTYPE_MOV1;
6907 + }
6908 + else if (!avr32_pic && S_GET_SEGMENT(symbolP) == absolute_section
6909 + && target <= 1048575 && (offsetT)target >= -1048576)
6910 + {
6911 + if (fragP->fr_subtype == LDA_SUBTYPE_LDDPC
6912 + || fragP->fr_subtype == LDA_SUBTYPE_LDW)
6913 + pool->literals[entry].refcount--;
6914 + new_size = 4;
6915 + fragP->fr_subtype = LDA_SUBTYPE_MOV2;
6916 + }
6917 + else if (!linkrelax && S_GET_SEGMENT(symbolP) == segment
6918 + /* the field will be negated, so this is really -(-32768)
6919 + and -(32767) */
6920 + && distance <= 32768 && distance >= -32767)
6921 + {
6922 + if (!avr32_pic
6923 + && (fragP->fr_subtype == LDA_SUBTYPE_LDDPC
6924 + || fragP->fr_subtype == LDA_SUBTYPE_LDW))
6925 + pool->literals[entry].refcount--;
6926 + new_size = 4;
6927 + fragP->fr_subtype = LDA_SUBTYPE_SUB;
6928 + }
6929 + else
6930 + {
6931 + relax_max:
6932 + if (avr32_pic)
6933 + {
6934 + if (linkrelax)
6935 + {
6936 + new_size = 8;
6937 + fragP->fr_subtype = LDA_SUBTYPE_GOTLOAD_LARGE;
6938 + }
6939 + else
6940 + {
6941 + new_size = 4;
6942 + fragP->fr_subtype = LDA_SUBTYPE_GOTLOAD;
6943 + }
6944 + }
6945 + else
6946 + {
6947 + if (fragP->fr_subtype != LDA_SUBTYPE_LDDPC
6948 + && fragP->fr_subtype != LDA_SUBTYPE_LDW)
6949 + pool->literals[entry].refcount++;
6950 +
6951 + sym_frag = symbol_get_frag(pool->symbol);
6952 + target = (sym_frag->fr_address + sym_frag->fr_fix
6953 + + pool->padding + pool->literals[entry].offset);
6954 +
6955 + pr_debug("cpool sym address: 0x%lx\n",
6956 + sym_frag->fr_address + sym_frag->fr_fix);
6957 +
6958 + know(pool->section == segment);
6959 +
6960 + if (sym_frag->relax_marker != fragP->relax_marker)
6961 + target += stretch;
6962 +
6963 + distance = target - address;
6964 + if (distance <= 508 && distance >= 0)
6965 + {
6966 + new_size = 2;
6967 + fragP->fr_subtype = LDA_SUBTYPE_LDDPC;
6968 + }
6969 + else
6970 + {
6971 + new_size = 4;
6972 + fragP->fr_subtype = LDA_SUBTYPE_LDW;
6973 + }
6974 +
6975 + pr_debug("lda_relax_frag (cpool): target=0x%lx, address=0x%lx, refcount=%d\n",
6976 + target, address, pool->literals[entry].refcount);
6977 + }
6978 + }
6979 +
6980 + fragP->fr_var = new_size;
6981 +
6982 + pr_debug("%s:%d: lda: relax pass done. subtype: %d, growth: %ld\n",
6983 + fragP->fr_file, fragP->fr_line,
6984 + fragP->fr_subtype, new_size - old_size);
6985 +
6986 + return new_size - old_size;
6987 +}
6988 +
6989 +static long
6990 +avr32_call_relax_frag(segT segment, fragS *fragP, long stretch)
6991 +{
6992 + struct cpool *pool = NULL;
6993 + unsigned int entry = 0;
6994 + addressT address, target;
6995 + offsetT distance;
6996 + symbolS *symbolP;
6997 + fragS *sym_frag;
6998 + long old_size, new_size;
6999 +
7000 + symbolP = fragP->fr_symbol;
7001 + old_size = fragP->fr_var;
7002 + if (!avr32_pic)
7003 + {
7004 + pool = fragP->tc_frag_data.pool;
7005 + entry = fragP->tc_frag_data.pool_entry;
7006 + }
7007 +
7008 + address = fragP->fr_address;
7009 + address += fragP->fr_fix - CALL_INITIAL_SIZE;
7010 +
7011 + if (need_reloc(symbolP, segment, 1))
7012 + {
7013 + pr_debug("call: must emit reloc\n");
7014 + goto relax_max;
7015 + }
7016 +
7017 + target = fragP->fr_offset;
7018 + sym_frag = symbol_get_frag(symbolP);
7019 + target += S_GET_VALUE(symbolP);
7020 +
7021 + if (sym_frag->relax_marker != fragP->relax_marker
7022 + && S_GET_SEGMENT(symbolP) == segment)
7023 + target += stretch;
7024 +
7025 + distance = target - address;
7026 +
7027 + if (distance <= 1022 && distance >= -1024)
7028 + {
7029 + pr_debug("call: distance is %d, emitting short rcall\n", distance);
7030 + if (!avr32_pic && fragP->fr_subtype == CALL_SUBTYPE_MCALL_CP)
7031 + pool->literals[entry].refcount--;
7032 + new_size = 2;
7033 + fragP->fr_subtype = CALL_SUBTYPE_RCALL1;
7034 + }
7035 + else if (distance <= 2097150 && distance >= -2097152)
7036 + {
7037 + pr_debug("call: distance is %d, emitting long rcall\n", distance);
7038 + if (!avr32_pic && fragP->fr_subtype == CALL_SUBTYPE_MCALL_CP)
7039 + pool->literals[entry].refcount--;
7040 + new_size = 4;
7041 + fragP->fr_subtype = CALL_SUBTYPE_RCALL2;
7042 + }
7043 + else
7044 + {
7045 + pr_debug("call: distance %d too far, emitting something big\n", distance);
7046 +
7047 + relax_max:
7048 + if (avr32_pic)
7049 + {
7050 + if (linkrelax)
7051 + {
7052 + new_size = 10;
7053 + fragP->fr_subtype = CALL_SUBTYPE_MCALL_LARGE;
7054 + }
7055 + else
7056 + {
7057 + new_size = 4;
7058 + fragP->fr_subtype = CALL_SUBTYPE_MCALL_GOT;
7059 + }
7060 + }
7061 + else
7062 + {
7063 + if (fragP->fr_subtype != CALL_SUBTYPE_MCALL_CP)
7064 + pool->literals[entry].refcount++;
7065 +
7066 + new_size = 4;
7067 + fragP->fr_subtype = CALL_SUBTYPE_MCALL_CP;
7068 + }
7069 + }
7070 +
7071 + fragP->fr_var = new_size;
7072 +
7073 + pr_debug("%s:%d: call: relax pass done, growth: %d, fr_var: %d\n",
7074 + fragP->fr_file, fragP->fr_line,
7075 + new_size - old_size, fragP->fr_var);
7076 +
7077 + return new_size - old_size;
7078 +}
7079 +
7080 +static long
7081 +avr32_cpool_relax_frag(segT segment ATTRIBUTE_UNUSED,
7082 + fragS *fragP,
7083 + long stretch ATTRIBUTE_UNUSED)
7084 +{
7085 + struct cpool *pool;
7086 + addressT address;
7087 + long old_size, new_size;
7088 + unsigned int entry;
7089 +
7090 + pool = fragP->tc_frag_data.pool;
7091 + address = fragP->fr_address + fragP->fr_fix;
7092 + old_size = fragP->fr_var;
7093 + new_size = 0;
7094 +
7095 + for (entry = 0; entry < pool->next_free_entry; entry++)
7096 + {
7097 + if (pool->literals[entry].refcount > 0)
7098 + {
7099 + pool->literals[entry].offset = new_size;
7100 + new_size += 4;
7101 + }
7102 + }
7103 +
7104 + fragP->fr_var = new_size;
7105 +
7106 + return new_size - old_size;
7107 +}
7108 +
7109 +/* *fragP has been relaxed to its final size, and now needs to have
7110 + the bytes inside it modified to conform to the new size.
7111 +
7112 + Called after relaxation is finished.
7113 + fragP->fr_type == rs_machine_dependent.
7114 + fragP->fr_subtype is the subtype of what the address relaxed to. */
7115 +
7116 +static void
7117 +avr32_default_convert_frag (bfd *abfd ATTRIBUTE_UNUSED,
7118 + segT segment ATTRIBUTE_UNUSED,
7119 + fragS *fragP)
7120 +{
7121 + const struct avr32_opcode *opc;
7122 + const struct avr32_ifield *ifield;
7123 + bfd_reloc_code_real_type r_type;
7124 + symbolS *symbolP;
7125 + fixS *fixP;
7126 + bfd_vma value;
7127 + int subtype;
7128 +
7129 + opc = &avr32_opc_table[fragP->fr_subtype];
7130 + ifield = opc->fields[opc->var_field];
7131 + symbolP = fragP->fr_symbol;
7132 + subtype = fragP->fr_subtype;
7133 + r_type = opc->reloc_type;
7134 +
7135 + /* Clear the opcode bits and the bits belonging to the relaxed
7136 + field. We assume all other fields stay the same. */
7137 + value = bfd_getb32(fragP->fr_opcode);
7138 + value &= ~(opc->mask | ifield->mask);
7139 +
7140 + /* Insert the new opcode */
7141 + value |= opc->value;
7142 + bfd_putb32(value, fragP->fr_opcode);
7143 +
7144 + fragP->fr_fix += opc->size - fragP->fr_var;
7145 +
7146 + if (fragP->tc_frag_data.reloc_info != AVR32_OPINFO_NONE)
7147 + {
7148 + switch (fragP->tc_frag_data.reloc_info)
7149 + {
7150 + case AVR32_OPINFO_HI:
7151 + r_type = BFD_RELOC_HI16;
7152 + break;
7153 + case AVR32_OPINFO_LO:
7154 + r_type = BFD_RELOC_LO16;
7155 + break;
7156 + case AVR32_OPINFO_GOT:
7157 + switch (r_type)
7158 + {
7159 + case BFD_RELOC_AVR32_18W_PCREL:
7160 + r_type = BFD_RELOC_AVR32_GOT18SW;
7161 + break;
7162 + case BFD_RELOC_AVR32_16S:
7163 + r_type = BFD_RELOC_AVR32_GOT16S;
7164 + break;
7165 + default:
7166 + BAD_CASE(r_type);
7167 + break;
7168 + }
7169 + break;
7170 + default:
7171 + BAD_CASE(fragP->tc_frag_data.reloc_info);
7172 + break;
7173 + }
7174 + }
7175 +
7176 + pr_debug("%s:%d: convert_frag: new %s fixup\n",
7177 + fragP->fr_file, fragP->fr_line,
7178 + bfd_get_reloc_code_name(r_type));
7179 +
7180 +#if 1
7181 + fixP = fix_new_exp(fragP, fragP->fr_fix - opc->size, opc->size,
7182 + &fragP->tc_frag_data.exp,
7183 + fragP->tc_frag_data.pcrel, r_type);
7184 +#else
7185 + fixP = fix_new(fragP, fragP->fr_fix - opc->size, opc->size, symbolP,
7186 + fragP->fr_offset, fragP->tc_frag_data.pcrel, r_type);
7187 +#endif
7188 +
7189 + /* Revert fix_new brain damage. "dot_value" is the value of PC at
7190 + the point of the fixup, relative to the frag address. fix_new()
7191 + and friends think they are only being called during the assembly
7192 + pass, not during relaxation or similar, so fx_dot_value, fx_file
7193 + and fx_line are all initialized to the wrong value. But we don't
7194 + know the size of the fixup until now, so we really can't live up
7195 + to the assumptions these functions make about the target. What
7196 + do these functions think the "where" and "frag" argument mean
7197 + anyway? */
7198 + fixP->fx_dot_value = fragP->fr_fix - opc->size;
7199 + fixP->fx_file = fragP->fr_file;
7200 + fixP->fx_line = fragP->fr_line;
7201 +
7202 + fixP->tc_fix_data.ifield = ifield;
7203 + fixP->tc_fix_data.align = avr32_rs_align(subtype);
7204 + fixP->tc_fix_data.min = avr32_relax_table[subtype].lower_bound;
7205 + fixP->tc_fix_data.max = avr32_relax_table[subtype].upper_bound;
7206 +}
7207 +
7208 +static void
7209 +avr32_lda_convert_frag(bfd *abfd ATTRIBUTE_UNUSED,
7210 + segT segment ATTRIBUTE_UNUSED,
7211 + fragS *fragP)
7212 +{
7213 + const struct avr32_opcode *opc;
7214 + const struct avr32_ifield *ifield;
7215 + bfd_reloc_code_real_type r_type;
7216 + expressionS exp;
7217 + struct cpool *pool;
7218 + fixS *fixP;
7219 + bfd_vma value;
7220 + int regid, pcrel = 0, align = 0;
7221 + char *p;
7222 +
7223 + r_type = BFD_RELOC_NONE;
7224 + regid = fragP->tc_frag_data.reloc_info;
7225 + p = fragP->fr_opcode;
7226 + exp.X_add_symbol = fragP->fr_symbol;
7227 + exp.X_add_number = fragP->fr_offset;
7228 + exp.X_op = O_symbol;
7229 +
7230 + pr_debug("%s:%d: lda_convert_frag, subtype: %d, fix: %d, var: %d, regid: %d\n",
7231 + fragP->fr_file, fragP->fr_line,
7232 + fragP->fr_subtype, fragP->fr_fix, fragP->fr_var, regid);
7233 +
7234 + switch (fragP->fr_subtype)
7235 + {
7236 + case LDA_SUBTYPE_MOV1:
7237 + opc = &avr32_opc_table[AVR32_OPC_MOV1];
7238 + opc->fields[0]->insert(opc->fields[0], p, regid);
7239 + ifield = opc->fields[1];
7240 + r_type = opc->reloc_type;
7241 + break;
7242 + case LDA_SUBTYPE_MOV2:
7243 + opc = &avr32_opc_table[AVR32_OPC_MOV2];
7244 + opc->fields[0]->insert(opc->fields[0], p, regid);
7245 + ifield = opc->fields[1];
7246 + r_type = opc->reloc_type;
7247 + break;
7248 + case LDA_SUBTYPE_SUB:
7249 + opc = &avr32_opc_table[AVR32_OPC_SUB5];
7250 + opc->fields[0]->insert(opc->fields[0], p, regid);
7251 + opc->fields[1]->insert(opc->fields[1], p, AVR32_REG_PC);
7252 + ifield = opc->fields[2];
7253 + r_type = BFD_RELOC_AVR32_16N_PCREL;
7254 +
7255 + /* Pretend that SUB5 isn't a "negated" pcrel expression for now.
7256 + We'll have to fix it up later when we know whether to
7257 + generate a reloc for it (in which case the linker will negate
7258 + it, so we shouldn't). */
7259 + pcrel = 1;
7260 + break;
7261 + case LDA_SUBTYPE_LDDPC:
7262 + opc = &avr32_opc_table[AVR32_OPC_LDDPC];
7263 + align = 2;
7264 + r_type = BFD_RELOC_AVR32_9W_CP;
7265 + goto cpool_common;
7266 + case LDA_SUBTYPE_LDW:
7267 + opc = &avr32_opc_table[AVR32_OPC_LDDPC_EXT];
7268 + r_type = BFD_RELOC_AVR32_16_CP;
7269 + cpool_common:
7270 + opc->fields[0]->insert(opc->fields[0], p, regid);
7271 + ifield = opc->fields[1];
7272 + pool = fragP->tc_frag_data.pool;
7273 + exp.X_add_symbol = pool->symbol;
7274 + exp.X_add_number = pool->literals[fragP->tc_frag_data.pool_entry].offset;
7275 + pcrel = 1;
7276 + break;
7277 + case LDA_SUBTYPE_GOTLOAD_LARGE:
7278 + /* ld.w Rd, r6[Rd << 2] (last) */
7279 + opc = &avr32_opc_table[AVR32_OPC_LD_W5];
7280 + bfd_putb32(opc->value, p + 4);
7281 + opc->fields[0]->insert(opc->fields[0], p + 4, regid);
7282 + opc->fields[1]->insert(opc->fields[1], p + 4, 6);
7283 + opc->fields[2]->insert(opc->fields[2], p + 4, regid);
7284 + opc->fields[3]->insert(opc->fields[3], p + 4, 2);
7285 +
7286 + /* mov Rd, (got_offset / 4) */
7287 + opc = &avr32_opc_table[AVR32_OPC_MOV2];
7288 + opc->fields[0]->insert(opc->fields[0], p, regid);
7289 + ifield = opc->fields[1];
7290 + r_type = BFD_RELOC_AVR32_LDA_GOT;
7291 + break;
7292 + case LDA_SUBTYPE_GOTLOAD:
7293 + opc = &avr32_opc_table[AVR32_OPC_LD_W4];
7294 + opc->fields[0]->insert(opc->fields[0], p, regid);
7295 + opc->fields[1]->insert(opc->fields[1], p, 6);
7296 + ifield = opc->fields[2];
7297 + if (r_type == BFD_RELOC_NONE)
7298 + r_type = BFD_RELOC_AVR32_GOT16S;
7299 + break;
7300 + default:
7301 + BAD_CASE(fragP->fr_subtype);
7302 + }
7303 +
7304 + value = bfd_getb32(p);
7305 + value &= ~(opc->mask | ifield->mask);
7306 + value |= opc->value;
7307 + bfd_putb32(value, p);
7308 +
7309 + fragP->fr_fix += fragP->fr_var - LDA_INITIAL_SIZE;
7310 +
7311 + if (fragP->fr_next
7312 + && ((offsetT)(fragP->fr_next->fr_address - fragP->fr_address)
7313 + != fragP->fr_fix))
7314 + {
7315 + fprintf(stderr, "LDA frag: fr_fix is wrong! fragP->fr_var = %ld, r_type = %s\n",
7316 + fragP->fr_var, bfd_get_reloc_code_name(r_type));
7317 + abort();
7318 + }
7319 +
7320 + fixP = fix_new_exp(fragP, fragP->fr_fix - fragP->fr_var, fragP->fr_var,
7321 + &exp, pcrel, r_type);
7322 +
7323 + /* Revert fix_new brain damage. "dot_value" is the value of PC at
7324 + the point of the fixup, relative to the frag address. fix_new()
7325 + and friends think they are only being called during the assembly
7326 + pass, not during relaxation or similar, so fx_dot_value, fx_file
7327 + and fx_line are all initialized to the wrong value. But we don't
7328 + know the size of the fixup until now, so we really can't live up
7329 + to the assumptions these functions make about the target. What
7330 + do these functions think the "where" and "frag" argument mean
7331 + anyway? */
7332 + fixP->fx_dot_value = fragP->fr_fix - opc->size;
7333 + fixP->fx_file = fragP->fr_file;
7334 + fixP->fx_line = fragP->fr_line;
7335 +
7336 + fixP->tc_fix_data.ifield = ifield;
7337 + fixP->tc_fix_data.align = align;
7338 + /* these are only used if the fixup can actually be resolved */
7339 + fixP->tc_fix_data.min = -32768;
7340 + fixP->tc_fix_data.max = 32767;
7341 +}
7342 +
7343 +static void
7344 +avr32_call_convert_frag(bfd *abfd ATTRIBUTE_UNUSED,
7345 + segT segment ATTRIBUTE_UNUSED,
7346 + fragS *fragP)
7347 +{
7348 + const struct avr32_opcode *opc = NULL;
7349 + const struct avr32_ifield *ifield;
7350 + bfd_reloc_code_real_type r_type;
7351 + symbolS *symbol;
7352 + offsetT offset;
7353 + fixS *fixP;
7354 + bfd_vma value;
7355 + int pcrel = 0, align = 0;
7356 + char *p;
7357 +
7358 + symbol = fragP->fr_symbol;
7359 + offset = fragP->fr_offset;
7360 + r_type = BFD_RELOC_NONE;
7361 + p = fragP->fr_opcode;
7362 +
7363 + pr_debug("%s:%d: call_convert_frag, subtype: %d, fix: %d, var: %d\n",
7364 + fragP->fr_file, fragP->fr_line,
7365 + fragP->fr_subtype, fragP->fr_fix, fragP->fr_var);
7366 +
7367 + switch (fragP->fr_subtype)
7368 + {
7369 + case CALL_SUBTYPE_RCALL1:
7370 + opc = &avr32_opc_table[AVR32_OPC_RCALL1];
7371 + /* fall through */
7372 + case CALL_SUBTYPE_RCALL2:
7373 + if (!opc)
7374 + opc = &avr32_opc_table[AVR32_OPC_RCALL2];
7375 + ifield = opc->fields[0];
7376 + r_type = opc->reloc_type;
7377 + pcrel = 1;
7378 + align = 1;
7379 + break;
7380 + case CALL_SUBTYPE_MCALL_CP:
7381 + opc = &avr32_opc_table[AVR32_OPC_MCALL];
7382 + opc->fields[0]->insert(opc->fields[0], p, AVR32_REG_PC);
7383 + ifield = opc->fields[1];
7384 + r_type = BFD_RELOC_AVR32_CPCALL;
7385 + symbol = fragP->tc_frag_data.pool->symbol;
7386 + offset = fragP->tc_frag_data.pool->literals[fragP->tc_frag_data.pool_entry].offset;
7387 + assert(fragP->tc_frag_data.pool->literals[fragP->tc_frag_data.pool_entry].refcount > 0);
7388 + pcrel = 1;
7389 + align = 2;
7390 + break;
7391 + case CALL_SUBTYPE_MCALL_GOT:
7392 + opc = &avr32_opc_table[AVR32_OPC_MCALL];
7393 + opc->fields[0]->insert(opc->fields[0], p, 6);
7394 + ifield = opc->fields[1];
7395 + r_type = BFD_RELOC_AVR32_GOT18SW;
7396 + break;
7397 + case CALL_SUBTYPE_MCALL_LARGE:
7398 + assert(fragP->fr_var == 10);
7399 + /* ld.w lr, r6[lr << 2] */
7400 + opc = &avr32_opc_table[AVR32_OPC_LD_W5];
7401 + bfd_putb32(opc->value, p + 4);
7402 + opc->fields[0]->insert(opc->fields[0], p + 4, AVR32_REG_LR);
7403 + opc->fields[1]->insert(opc->fields[1], p + 4, 6);
7404 + opc->fields[2]->insert(opc->fields[2], p + 4, AVR32_REG_LR);
7405 + opc->fields[3]->insert(opc->fields[3], p + 4, 2);
7406 +
7407 + /* icall lr */
7408 + opc = &avr32_opc_table[AVR32_OPC_ICALL];
7409 + bfd_putb16(opc->value >> 16, p + 8);
7410 + opc->fields[0]->insert(opc->fields[0], p + 8, AVR32_REG_LR);
7411 +
7412 + /* mov lr, (got_offset / 4) */
7413 + opc = &avr32_opc_table[AVR32_OPC_MOV2];
7414 + opc->fields[0]->insert(opc->fields[0], p, AVR32_REG_LR);
7415 + ifield = opc->fields[1];
7416 + r_type = BFD_RELOC_AVR32_GOTCALL;
7417 + break;
7418 + default:
7419 + BAD_CASE(fragP->fr_subtype);
7420 + }
7421 +
7422 + /* Insert the opcode and clear the variable ifield */
7423 + value = bfd_getb32(p);
7424 + value &= ~(opc->mask | ifield->mask);
7425 + value |= opc->value;
7426 + bfd_putb32(value, p);
7427 +
7428 + fragP->fr_fix += fragP->fr_var - CALL_INITIAL_SIZE;
7429 +
7430 + if (fragP->fr_next
7431 + && ((offsetT)(fragP->fr_next->fr_address - fragP->fr_address)
7432 + != fragP->fr_fix))
7433 + {
7434 + fprintf(stderr, "%s:%d: fr_fix %lu is wrong! fr_var=%lu, r_type=%s\n",
7435 + fragP->fr_file, fragP->fr_line,
7436 + fragP->fr_fix, fragP->fr_var, bfd_get_reloc_code_name(r_type));
7437 + fprintf(stderr, "fr_fix should be %ld. next frag is %s:%d\n",
7438 + (offsetT)(fragP->fr_next->fr_address - fragP->fr_address),
7439 + fragP->fr_next->fr_file, fragP->fr_next->fr_line);
7440 + }
7441 +
7442 + fixP = fix_new(fragP, fragP->fr_fix - fragP->fr_var, fragP->fr_var,
7443 + symbol, offset, pcrel, r_type);
7444 +
7445 + /* Revert fix_new brain damage. "dot_value" is the value of PC at
7446 + the point of the fixup, relative to the frag address. fix_new()
7447 + and friends think they are only being called during the assembly
7448 + pass, not during relaxation or similar, so fx_dot_value, fx_file
7449 + and fx_line are all initialized to the wrong value. But we don't
7450 + know the size of the fixup until now, so we really can't live up
7451 + to the assumptions these functions make about the target. What
7452 + do these functions think the "where" and "frag" argument mean
7453 + anyway? */
7454 + fixP->fx_dot_value = fragP->fr_fix - opc->size;
7455 + fixP->fx_file = fragP->fr_file;
7456 + fixP->fx_line = fragP->fr_line;
7457 +
7458 + fixP->tc_fix_data.ifield = ifield;
7459 + fixP->tc_fix_data.align = align;
7460 + /* these are only used if the fixup can actually be resolved */
7461 + fixP->tc_fix_data.min = -2097152;
7462 + fixP->tc_fix_data.max = 2097150;
7463 +}
7464 +
7465 +static void
7466 +avr32_cpool_convert_frag(bfd *abfd ATTRIBUTE_UNUSED,
7467 + segT segment ATTRIBUTE_UNUSED,
7468 + fragS *fragP)
7469 +{
7470 + struct cpool *pool;
7471 + addressT address;
7472 + unsigned int entry;
7473 + char *p;
7474 + char sym_name[20];
7475 +
7476 + /* Did we get rid of the frag altogether? */
7477 + if (!fragP->fr_var)
7478 + return;
7479 +
7480 + pool = fragP->tc_frag_data.pool;
7481 + address = fragP->fr_address + fragP->fr_fix;
7482 + p = fragP->fr_literal + fragP->fr_fix;
7483 +
7484 + sprintf(sym_name, "$$cp_\002%x", pool->id);
7485 + symbol_locate(pool->symbol, sym_name, pool->section, fragP->fr_fix, fragP);
7486 + symbol_table_insert(pool->symbol);
7487 +
7488 + for (entry = 0; entry < pool->next_free_entry; entry++)
7489 + {
7490 + if (pool->literals[entry].refcount > 0)
7491 + {
7492 + fix_new_exp(fragP, fragP->fr_fix, 4, &pool->literals[entry].exp,
7493 + FALSE, BFD_RELOC_AVR32_32_CPENT);
7494 + fragP->fr_fix += 4;
7495 + }
7496 + }
7497 +}
7498 +
7499 +static struct avr32_relaxer avr32_default_relaxer = {
7500 + .estimate_size = avr32_default_estimate_size_before_relax,
7501 + .relax_frag = avr32_default_relax_frag,
7502 + .convert_frag = avr32_default_convert_frag,
7503 +};
7504 +static struct avr32_relaxer avr32_lda_relaxer = {
7505 + .estimate_size = avr32_lda_estimate_size_before_relax,
7506 + .relax_frag = avr32_lda_relax_frag,
7507 + .convert_frag = avr32_lda_convert_frag,
7508 +};
7509 +static struct avr32_relaxer avr32_call_relaxer = {
7510 + .estimate_size = avr32_call_estimate_size_before_relax,
7511 + .relax_frag = avr32_call_relax_frag,
7512 + .convert_frag = avr32_call_convert_frag,
7513 +};
7514 +static struct avr32_relaxer avr32_cpool_relaxer = {
7515 + .estimate_size = avr32_cpool_estimate_size_before_relax,
7516 + .relax_frag = avr32_cpool_relax_frag,
7517 + .convert_frag = avr32_cpool_convert_frag,
7518 +};
7519 +
7520 +static void s_cpool(int arg ATTRIBUTE_UNUSED)
7521 +{
7522 + struct cpool *pool;
7523 + unsigned int max_size;
7524 + char *buf;
7525 +
7526 + pool = find_cpool(now_seg, now_subseg);
7527 + if (!pool || !pool->symbol || pool->next_free_entry == 0)
7528 + return;
7529 +
7530 + /* Make sure the constant pool is properly aligned */
7531 + frag_align_code(2, 0);
7532 + if (bfd_get_section_alignment(stdoutput, pool->section) < 2)
7533 + bfd_set_section_alignment(stdoutput, pool->section, 2);
7534 +
7535 + /* Assume none of the entries are discarded, and that we need the
7536 + maximum amount of alignment. But we're not going to allocate
7537 + anything up front. */
7538 + max_size = pool->next_free_entry * 4 + 2;
7539 + frag_grow(max_size);
7540 + buf = frag_more(0);
7541 +
7542 + frag_now->tc_frag_data.relaxer = &avr32_cpool_relaxer;
7543 + frag_now->tc_frag_data.pool = pool;
7544 +
7545 + symbol_set_frag(pool->symbol, frag_now);
7546 +
7547 + /* Assume zero initial size, allowing other relaxers to be
7548 + optimistic about things. */
7549 + frag_var(rs_machine_dependent, max_size, 0,
7550 + 0, pool->symbol, 0, NULL);
7551 +
7552 + /* Mark the pool as empty. */
7553 + pool->used = 1;
7554 +}
7555 +
7556 +/* The location from which a PC relative jump should be calculated,
7557 + given a PC relative reloc. */
7558 +
7559 +long
7560 +md_pcrel_from_section (fixS *fixP, segT sec)
7561 +{
7562 + pr_debug("pcrel_from_section, fx_offset = %d\n", fixP->fx_offset);
7563 +
7564 + if (fixP->fx_addsy != NULL
7565 + && (! S_IS_DEFINED (fixP->fx_addsy)
7566 + || S_GET_SEGMENT (fixP->fx_addsy) != sec
7567 + || S_FORCE_RELOC(fixP->fx_addsy, 1)))
7568 + {
7569 + pr_debug("Unknown pcrel symbol: %s\n", S_GET_NAME(fixP->fx_addsy));
7570 +
7571 + /* The symbol is undefined (or is defined but not in this section).
7572 + Let the linker figure it out. */
7573 + return 0;
7574 + }
7575 +
7576 + pr_debug("pcrel from %x + %x, symbol: %s (%x)\n",
7577 + fixP->fx_frag->fr_address, fixP->fx_where,
7578 + fixP->fx_addsy?S_GET_NAME(fixP->fx_addsy):"(null)",
7579 + fixP->fx_addsy?S_GET_VALUE(fixP->fx_addsy):0);
7580 +
7581 + return ((fixP->fx_frag->fr_address + fixP->fx_where)
7582 + & (~0UL << fixP->tc_fix_data.align));
7583 +}
7584 +
7585 +valueT
7586 +md_section_align (segT segment, valueT size)
7587 +{
7588 + int align = bfd_get_section_alignment (stdoutput, segment);
7589 + return ((size + (1 << align) - 1) & (-1 << align));
7590 +}
7591 +
7592 +static int syntax_matches(const struct avr32_syntax *syntax,
7593 + char *str)
7594 +{
7595 + int i;
7596 +
7597 + pr_debug("syntax %d matches `%s'?\n", syntax->id, str);
7598 +
7599 + if (syntax->nr_operands < 0)
7600 + {
7601 + struct avr32_operand *op;
7602 + int optype;
7603 +
7604 + for (i = 0; i < (-syntax->nr_operands - 1); i++)
7605 + {
7606 + char *p;
7607 + char c;
7608 +
7609 + optype = syntax->operand[i];
7610 + assert(optype < AVR32_NR_OPERANDS);
7611 + op = &avr32_operand_table[optype];
7612 +
7613 + for (p = str; *p; p++)
7614 + if (*p == ',')
7615 + break;
7616 +
7617 + if (p == str)
7618 + return 0;
7619 +
7620 + c = *p;
7621 + *p = 0;
7622 +
7623 + if (!op->match(str))
7624 + {
7625 + *p = c;
7626 + return 0;
7627 + }
7628 +
7629 + str = p;
7630 + *p = c;
7631 + if (c)
7632 + str++;
7633 + }
7634 +
7635 + optype = syntax->operand[i];
7636 + assert(optype < AVR32_NR_OPERANDS);
7637 + op = &avr32_operand_table[optype];
7638 +
7639 + if (!op->match(str))
7640 + return 0;
7641 + return 1;
7642 + }
7643 +
7644 + for (i = 0; i < syntax->nr_operands; i++)
7645 + {
7646 + struct avr32_operand *op;
7647 + int optype = syntax->operand[i];
7648 + char *p;
7649 + char c;
7650 +
7651 + assert(optype < AVR32_NR_OPERANDS);
7652 + op = &avr32_operand_table[optype];
7653 +
7654 + for (p = str; *p; p++)
7655 + if (*p == ',')
7656 + break;
7657 +
7658 + if (p == str)
7659 + return 0;
7660 +
7661 + c = *p;
7662 + *p = 0;
7663 +
7664 + if (!op->match(str))
7665 + {
7666 + *p = c;
7667 + return 0;
7668 + }
7669 +
7670 + str = p;
7671 + *p = c;
7672 + if (c)
7673 + str++;
7674 + }
7675 +
7676 + if (*str == '\0')
7677 + return 1;
7678 +
7679 + if ((*str == 'e' || *str == 'E') && !str[1])
7680 + return 1;
7681 +
7682 + return 0;
7683 +}
7684 +
7685 +static int parse_operands(char *str)
7686 +{
7687 + int i;
7688 +
7689 + if (current_insn.syntax->nr_operands < 0)
7690 + {
7691 + int optype;
7692 + struct avr32_operand *op;
7693 +
7694 + for (i = 0; i < (-current_insn.syntax->nr_operands - 1); i++)
7695 + {
7696 + char *p;
7697 + char c;
7698 +
7699 + optype = current_insn.syntax->operand[i];
7700 + op = &avr32_operand_table[optype];
7701 +
7702 + for (p = str; *p; p++)
7703 + if (*p == ',')
7704 + break;
7705 +
7706 + assert(p != str);
7707 +
7708 + c = *p, *p = 0;
7709 + op->parse(op, str, i);
7710 + *p = c;
7711 +
7712 + str = p;
7713 + if (c) str++;
7714 + }
7715 +
7716 + /* give the rest of the line to the last operand */
7717 + optype = current_insn.syntax->operand[i];
7718 + op = &avr32_operand_table[optype];
7719 + op->parse(op, str, i);
7720 + }
7721 + else
7722 + {
7723 + for (i = 0; i < current_insn.syntax->nr_operands; i++)
7724 + {
7725 + int optype = current_insn.syntax->operand[i];
7726 + struct avr32_operand *op = &avr32_operand_table[optype];
7727 + char *p;
7728 + char c;
7729 +
7730 + skip_whitespace(str);
7731 +
7732 + for (p = str; *p; p++)
7733 + if (*p == ',')
7734 + break;
7735 +
7736 + assert(p != str);
7737 +
7738 + c = *p, *p = 0;
7739 + op->parse(op, str, i);
7740 + *p = c;
7741 +
7742 + str = p;
7743 + if (c) str++;
7744 + }
7745 +
7746 + if (*str == 'E' || *str == 'e')
7747 + current_insn.force_extended = 1;
7748 + }
7749 +
7750 + return 0;
7751 +}
7752 +
7753 +static const char *
7754 +finish_insn(const struct avr32_opcode *opc)
7755 +{
7756 + expressionS *exp = &current_insn.immediate;
7757 + unsigned int i;
7758 + int will_relax = 0;
7759 + char *buf;
7760 +
7761 + assert(current_insn.next_slot == opc->nr_fields);
7762 +
7763 + pr_debug("%s:%d: finish_insn: trying opcode %d\n",
7764 + frag_now->fr_file, frag_now->fr_line, opc->id);
7765 +
7766 + /* Go through the relaxation stage for all instructions that can
7767 + possibly take a symbolic immediate. The relax code will take
7768 + care of range checking and alignment. */
7769 + if (opc->var_field != -1)
7770 + {
7771 + int substate, largest_substate;
7772 + symbolS *sym;
7773 + offsetT off;
7774 +
7775 + will_relax = 1;
7776 + substate = largest_substate = opc_initial_substate(opc);
7777 +
7778 + while (relax_more(largest_substate) != AVR32_RS_NONE)
7779 + largest_substate = relax_more(largest_substate);
7780 +
7781 + pr_debug("will relax. initial substate: %d (size %d), largest substate: %d (size %d)\n",
7782 + substate, avr32_rs_size(substate),
7783 + largest_substate, avr32_rs_size(largest_substate));
7784 +
7785 + /* make sure we have enough room for the largest possible opcode */
7786 + frag_grow(avr32_rs_size(largest_substate));
7787 + buf = frag_more(opc->size);
7788 +
7789 + dwarf2_emit_insn(opc->size);
7790 +
7791 + frag_now->tc_frag_data.reloc_info = AVR32_OPINFO_NONE;
7792 + frag_now->tc_frag_data.pcrel = current_insn.pcrel;
7793 + frag_now->tc_frag_data.force_extended = current_insn.force_extended;
7794 + frag_now->tc_frag_data.relaxer = &avr32_default_relaxer;
7795 +
7796 + if (exp->X_op == O_hi)
7797 + {
7798 + frag_now->tc_frag_data.reloc_info = AVR32_OPINFO_HI;
7799 + exp->X_op = exp->X_md;
7800 + }
7801 + else if (exp->X_op == O_lo)
7802 + {
7803 + frag_now->tc_frag_data.reloc_info = AVR32_OPINFO_LO;
7804 + exp->X_op = exp->X_md;
7805 + }
7806 + else if (exp->X_op == O_got)
7807 + {
7808 + frag_now->tc_frag_data.reloc_info = AVR32_OPINFO_GOT;
7809 + exp->X_op = O_symbol;
7810 + }
7811 +
7812 +#if 0
7813 + if ((opc->reloc_type == BFD_RELOC_AVR32_SUB5)
7814 + && exp->X_op == O_subtract)
7815 + {
7816 + symbolS *tmp;
7817 + tmp = exp->X_add_symbol;
7818 + exp->X_add_symbol = exp->X_op_symbol;
7819 + exp->X_op_symbol = tmp;
7820 + }
7821 +#endif
7822 +
7823 + frag_now->tc_frag_data.exp = current_insn.immediate;
7824 +
7825 + sym = exp->X_add_symbol;
7826 + off = exp->X_add_number;
7827 + if (exp->X_op != O_symbol)
7828 + {
7829 + sym = make_expr_symbol(exp);
7830 + off = 0;
7831 + }
7832 +
7833 + frag_var(rs_machine_dependent,
7834 + avr32_rs_size(largest_substate) - opc->size,
7835 + opc->size,
7836 + substate, sym, off, buf);
7837 + }
7838 + else
7839 + {
7840 + assert(avr32_rs_size(opc_initial_substate(opc)) == 0);
7841 +
7842 + /* Make sure we always have room for another whole word, as the ifield
7843 + inserters can only write words. */
7844 + frag_grow(4);
7845 + buf = frag_more(opc->size);
7846 + dwarf2_emit_insn(opc->size);
7847 + }
7848 +
7849 + assert(!(opc->value & ~opc->mask));
7850 +
7851 + pr_debug("inserting opcode: 0x%lx\n", opc->value);
7852 + bfd_putb32(opc->value, buf);
7853 +
7854 + for (i = 0; i < opc->nr_fields; i++)
7855 + {
7856 + const struct avr32_ifield *f = opc->fields[i];
7857 + const struct avr32_ifield_data *fd = &current_insn.field_value[i];
7858 +
7859 + pr_debug("inserting field: 0x%lx & 0x%lx\n",
7860 + fd->value >> fd->align_order, f->mask);
7861 +
7862 + f->insert(f, buf, fd->value >> fd->align_order);
7863 + }
7864 +
7865 + assert(will_relax || !current_insn.immediate.X_add_symbol);
7866 + return NULL;
7867 +}
7868 +
7869 +static const char *
7870 +finish_alias(const struct avr32_alias *alias)
7871 +{
7872 + const struct avr32_opcode *opc;
7873 + struct {
7874 + unsigned long value;
7875 + unsigned long align;
7876 + } mapped_operand[AVR32_MAX_OPERANDS];
7877 + unsigned int i;
7878 +
7879 + opc = alias->opc;
7880 +
7881 + /* Remap the operands from the alias to the real opcode */
7882 + for (i = 0; i < opc->nr_fields; i++)
7883 + {
7884 + if (alias->operand_map[i].is_opindex)
7885 + {
7886 + struct avr32_ifield_data *fd;
7887 + fd = &current_insn.field_value[alias->operand_map[i].value];
7888 + mapped_operand[i].value = fd->value;
7889 + mapped_operand[i].align = fd->align_order;
7890 + }
7891 + else
7892 + {
7893 + mapped_operand[i].value = alias->operand_map[i].value;
7894 + mapped_operand[i].align = 0;
7895 + }
7896 + }
7897 +
7898 + for (i = 0; i < opc->nr_fields; i++)
7899 + {
7900 + current_insn.field_value[i].value = mapped_operand[i].value;
7901 + if (opc->id == AVR32_OPC_COP)
7902 + current_insn.field_value[i].align_order = 0;
7903 + else
7904 + current_insn.field_value[i].align_order
7905 + = mapped_operand[i].align;
7906 + }
7907 +
7908 + current_insn.next_slot = opc->nr_fields;
7909 +
7910 + return finish_insn(opc);
7911 +}
7912 +
7913 +static const char *
7914 +finish_lda(const struct avr32_syntax *syntax ATTRIBUTE_UNUSED)
7915 +{
7916 + expressionS *exp = &current_insn.immediate;
7917 + relax_substateT initial_subtype;
7918 + symbolS *sym;
7919 + offsetT off;
7920 + int initial_size, max_size;
7921 + char *buf;
7922 +
7923 + initial_size = LDA_INITIAL_SIZE;
7924 +
7925 + if (avr32_pic)
7926 + {
7927 + initial_subtype = LDA_SUBTYPE_SUB;
7928 + if (linkrelax)
7929 + max_size = 8;
7930 + else
7931 + max_size = 4;
7932 + }
7933 + else
7934 + {
7935 + initial_subtype = LDA_SUBTYPE_MOV1;
7936 + max_size = 4;
7937 + }
7938 +
7939 + frag_grow(max_size);
7940 + buf = frag_more(initial_size);
7941 + dwarf2_emit_insn(initial_size);
7942 +
7943 + if (exp->X_op == O_symbol)
7944 + {
7945 + sym = exp->X_add_symbol;
7946 + off = exp->X_add_number;
7947 + }
7948 + else
7949 + {
7950 + sym = make_expr_symbol(exp);
7951 + off = 0;
7952 + }
7953 +
7954 + frag_now->tc_frag_data.reloc_info = current_insn.field_value[0].value;
7955 + frag_now->tc_frag_data.relaxer = &avr32_lda_relaxer;
7956 +
7957 + if (!avr32_pic)
7958 + {
7959 + /* The relaxer will bump the refcount if necessary */
7960 + frag_now->tc_frag_data.pool
7961 + = add_to_cpool(exp, &frag_now->tc_frag_data.pool_entry, 0);
7962 + }
7963 +
7964 + frag_var(rs_machine_dependent, max_size - initial_size,
7965 + initial_size, initial_subtype, sym, off, buf);
7966 +
7967 + return NULL;
7968 +}
7969 +
7970 +static const char *
7971 +finish_call(const struct avr32_syntax *syntax ATTRIBUTE_UNUSED)
7972 +{
7973 + expressionS *exp = &current_insn.immediate;
7974 + symbolS *sym;
7975 + offsetT off;
7976 + int initial_size, max_size;
7977 + char *buf;
7978 +
7979 + initial_size = CALL_INITIAL_SIZE;
7980 +
7981 + if (avr32_pic)
7982 + {
7983 + if (linkrelax)
7984 + max_size = 10;
7985 + else
7986 + max_size = 4;
7987 + }
7988 + else
7989 + max_size = 4;
7990 +
7991 + frag_grow(max_size);
7992 + buf = frag_more(initial_size);
7993 + dwarf2_emit_insn(initial_size);
7994 +
7995 + frag_now->tc_frag_data.relaxer = &avr32_call_relaxer;
7996 +
7997 + if (exp->X_op == O_symbol)
7998 + {
7999 + sym = exp->X_add_symbol;
8000 + off = exp->X_add_number;
8001 + }
8002 + else
8003 + {
8004 + sym = make_expr_symbol(exp);
8005 + off = 0;
8006 + }
8007 +
8008 + if (!avr32_pic)
8009 + {
8010 + /* The relaxer will bump the refcount if necessary */
8011 + frag_now->tc_frag_data.pool
8012 + = add_to_cpool(exp, &frag_now->tc_frag_data.pool_entry, 0);
8013 + }
8014 +
8015 + frag_var(rs_machine_dependent, max_size - initial_size,
8016 + initial_size, CALL_SUBTYPE_RCALL1, sym, off, buf);
8017 +
8018 + return NULL;
8019 +}
8020 +
8021 +void
8022 +md_begin (void)
8023 +{
8024 + unsigned long flags = 0;
8025 + int i;
8026 +
8027 + avr32_mnemonic_htab = hash_new();
8028 +
8029 + if (!avr32_mnemonic_htab)
8030 + as_fatal(_("virtual memory exhausted"));
8031 +
8032 + for (i = 0; i < AVR32_NR_MNEMONICS; i++)
8033 + {
8034 + hash_insert(avr32_mnemonic_htab, avr32_mnemonic_table[i].name,
8035 + (void *)&avr32_mnemonic_table[i]);
8036 + }
8037 +
8038 + if (linkrelax)
8039 + flags |= EF_AVR32_LINKRELAX;
8040 + if (avr32_pic)
8041 + flags |= EF_AVR32_PIC;
8042 +
8043 + bfd_set_private_flags(stdoutput, flags);
8044 +
8045 +#ifdef OPC_CONSISTENCY_CHECK
8046 + if (sizeof(avr32_operand_table)/sizeof(avr32_operand_table[0])
8047 + < AVR32_NR_OPERANDS)
8048 + as_fatal(_("operand table is incomplete"));
8049 +
8050 + for (i = 0; i < AVR32_NR_OPERANDS; i++)
8051 + if (avr32_operand_table[i].id != i)
8052 + as_fatal(_("operand table inconsistency found at index %d\n"), i);
8053 + pr_debug("%d operands verified\n", AVR32_NR_OPERANDS);
8054 +
8055 + for (i = 0; i < AVR32_NR_IFIELDS; i++)
8056 + if (avr32_ifield_table[i].id != i)
8057 + as_fatal(_("ifield table inconsistency found at index %d\n"), i);
8058 + pr_debug("%d instruction fields verified\n", AVR32_NR_IFIELDS);
8059 +
8060 + for (i = 0; i < AVR32_NR_OPCODES; i++)
8061 + {
8062 + if (avr32_opc_table[i].id != i)
8063 + as_fatal(_("opcode table inconsistency found at index %d\n"), i);
8064 + if ((avr32_opc_table[i].var_field == -1
8065 + && avr32_relax_table[i].length != 0)
8066 + || (avr32_opc_table[i].var_field != -1
8067 + && avr32_relax_table[i].length == 0))
8068 + as_fatal(_("relax table inconsistency found at index %d\n"), i);
8069 + }
8070 + pr_debug("%d opcodes verified\n", AVR32_NR_OPCODES);
8071 +
8072 + for (i = 0; i < AVR32_NR_SYNTAX; i++)
8073 + if (avr32_syntax_table[i].id != i)
8074 + as_fatal(_("syntax table inconsistency found at index %d\n"), i);
8075 + pr_debug("%d syntax variants verified\n", AVR32_NR_SYNTAX);
8076 +
8077 + for (i = 0; i < AVR32_NR_ALIAS; i++)
8078 + if (avr32_alias_table[i].id != i)
8079 + as_fatal(_("alias table inconsistency found at index %d\n"), i);
8080 + pr_debug("%d aliases verified\n", AVR32_NR_ALIAS);
8081 +
8082 + for (i = 0; i < AVR32_NR_MNEMONICS; i++)
8083 + if (avr32_mnemonic_table[i].id != i)
8084 + as_fatal(_("mnemonic table inconsistency found at index %d\n"), i);
8085 + pr_debug("%d mnemonics verified\n", AVR32_NR_MNEMONICS);
8086 +#endif
8087 +}
8088 +
8089 +void
8090 +md_assemble (char *str)
8091 +{
8092 + struct avr32_mnemonic *mnemonic;
8093 + char *p, c;
8094 +
8095 + memset(&current_insn, 0, sizeof(current_insn));
8096 + current_insn.immediate.X_op = O_constant;
8097 +
8098 + skip_whitespace(str);
8099 + for (p = str; *p; p++)
8100 + if (*p == ' ')
8101 + break;
8102 + c = *p;
8103 + *p = 0;
8104 +
8105 + mnemonic = hash_find(avr32_mnemonic_htab, str);
8106 + *p = c;
8107 + if (c) p++;
8108 +
8109 + if (mnemonic)
8110 + {
8111 + const struct avr32_syntax *syntax;
8112 +
8113 + for (syntax = mnemonic->syntax; syntax; syntax = syntax->next)
8114 + {
8115 + const char *errmsg = NULL;
8116 +
8117 + if (syntax_matches(syntax, p))
8118 + {
8119 + if (!(syntax->isa_flags & avr32_arch->isa_flags))
8120 + {
8121 + as_bad(_("Selected architecture `%s' does not support `%s'"),
8122 + avr32_arch->name, str);
8123 + return;
8124 + }
8125 +
8126 + current_insn.syntax = syntax;
8127 + parse_operands(p);
8128 +
8129 + switch (syntax->type)
8130 + {
8131 + case AVR32_PARSER_NORMAL:
8132 + errmsg = finish_insn(syntax->u.opc);
8133 + break;
8134 + case AVR32_PARSER_ALIAS:
8135 + errmsg = finish_alias(syntax->u.alias);
8136 + break;
8137 + case AVR32_PARSER_LDA:
8138 + errmsg = finish_lda(syntax);
8139 + break;
8140 + case AVR32_PARSER_CALL:
8141 + errmsg = finish_call(syntax);
8142 + break;
8143 + default:
8144 + BAD_CASE(syntax->type);
8145 + break;
8146 + }
8147 +
8148 + if (errmsg)
8149 + as_bad("%s in `%s'", errmsg, str);
8150 +
8151 + return;
8152 + }
8153 + }
8154 +
8155 + as_bad(_("unrecognized form of instruction: `%s'"), str);
8156 + }
8157 + else
8158 + as_bad(_("unrecognized instruction `%s'"), str);
8159 +}
8160 +
8161 +void avr32_cleanup(void)
8162 +{
8163 + struct cpool *pool;
8164 +
8165 + /* Emit any constant pools that haven't been explicitly flushed with
8166 + a .cpool directive. */
8167 + for (pool = cpool_list; pool; pool = pool->next)
8168 + {
8169 + subseg_set(pool->section, pool->sub_section);
8170 + s_cpool(0);
8171 + }
8172 +}
8173 +
8174 +/* Handle any PIC-related operands in data allocation pseudo-ops */
8175 +void
8176 +avr32_cons_fix_new (fragS *frag, int off, int size, expressionS *exp)
8177 +{
8178 + bfd_reloc_code_real_type r_type = BFD_RELOC_UNUSED;
8179 + int pcrel = 0;
8180 +
8181 + pr_debug("%s:%u: cons_fix_new, add_sym: %s, op_sym: %s, op: %d, add_num: %d\n",
8182 + frag->fr_file, frag->fr_line,
8183 + exp->X_add_symbol?S_GET_NAME(exp->X_add_symbol):"(none)",
8184 + exp->X_op_symbol?S_GET_NAME(exp->X_op_symbol):"(none)",
8185 + exp->X_op, exp->X_add_number);
8186 +
8187 + if (exp->X_op == O_subtract && exp->X_op_symbol)
8188 + {
8189 + if (exp->X_op_symbol == GOT_symbol)
8190 + {
8191 + if (size != 4)
8192 + goto bad_size;
8193 + r_type = BFD_RELOC_AVR32_GOTPC;
8194 + exp->X_op = O_symbol;
8195 + exp->X_op_symbol = NULL;
8196 + }
8197 + }
8198 + else if (exp->X_op == O_got)
8199 + {
8200 + switch (size)
8201 + {
8202 + case 1:
8203 + r_type = BFD_RELOC_AVR32_GOT8;
8204 + break;
8205 + case 2:
8206 + r_type = BFD_RELOC_AVR32_GOT16;
8207 + break;
8208 + case 4:
8209 + r_type = BFD_RELOC_AVR32_GOT32;
8210 + break;
8211 + default:
8212 + goto bad_size;
8213 + }
8214 +
8215 + exp->X_op = O_symbol;
8216 + }
8217 +
8218 + if (r_type == BFD_RELOC_UNUSED)
8219 + switch (size)
8220 + {
8221 + case 1:
8222 + r_type = BFD_RELOC_8;
8223 + break;
8224 + case 2:
8225 + r_type = BFD_RELOC_16;
8226 + break;
8227 + case 4:
8228 + r_type = BFD_RELOC_32;
8229 + break;
8230 + default:
8231 + goto bad_size;
8232 + }
8233 + else if (size != 4)
8234 + {
8235 + bad_size:
8236 + as_bad(_("unsupported BFD relocation size %u"), size);
8237 + r_type = BFD_RELOC_UNUSED;
8238 + }
8239 +
8240 + fix_new_exp (frag, off, size, exp, pcrel, r_type);
8241 +}
8242 +
8243 +static void
8244 +avr32_frob_section(bfd *abfd ATTRIBUTE_UNUSED, segT sec,
8245 + void *ignore ATTRIBUTE_UNUSED)
8246 +{
8247 + segment_info_type *seginfo;
8248 + fixS *fix;
8249 +
8250 + seginfo = seg_info(sec);
8251 + if (!seginfo)
8252 + return;
8253 +
8254 + for (fix = seginfo->fix_root; fix; fix = fix->fx_next)
8255 + {
8256 + if (fix->fx_done)
8257 + continue;
8258 +
8259 + if (fix->fx_r_type == BFD_RELOC_AVR32_SUB5
8260 + && fix->fx_addsy && fix->fx_subsy)
8261 + {
8262 + if (S_GET_SEGMENT(fix->fx_addsy) != S_GET_SEGMENT(fix->fx_subsy)
8263 + || linkrelax)
8264 + {
8265 + symbolS *tmp;
8266 +#ifdef DEBUG
8267 + fprintf(stderr, "Swapping symbols in fixup:\n");
8268 + print_fixup(fix);
8269 +#endif
8270 + tmp = fix->fx_addsy;
8271 + fix->fx_addsy = fix->fx_subsy;
8272 + fix->fx_subsy = tmp;
8273 + fix->fx_offset = -fix->fx_offset;
8274 + }
8275 + }
8276 + }
8277 +}
8278 +
8279 +/* We need to look for SUB5 instructions with expressions that will be
8280 + made PC-relative and switch fx_addsy with fx_subsy. This has to be
8281 + done before adjustment or the wrong symbol might be adjusted.
8282 +
8283 + This applies to fixups that are a result of expressions like -(sym
8284 + - .) and that will make it all the way to md_apply_fix3(). LDA
8285 + does the right thing in convert_frag, so we must not convert
8286 + those. */
8287 +void
8288 +avr32_frob_file(void)
8289 +{
8290 + /* if (1 || !linkrelax)
8291 + return; */
8292 +
8293 + bfd_map_over_sections(stdoutput, avr32_frob_section, NULL);
8294 +}
8295 +
8296 +static bfd_boolean
8297 +convert_to_diff_reloc(fixS *fixP)
8298 +{
8299 + switch (fixP->fx_r_type)
8300 + {
8301 + case BFD_RELOC_32:
8302 + fixP->fx_r_type = BFD_RELOC_AVR32_DIFF32;
8303 + break;
8304 + case BFD_RELOC_16:
8305 + fixP->fx_r_type = BFD_RELOC_AVR32_DIFF16;
8306 + break;
8307 + case BFD_RELOC_8:
8308 + fixP->fx_r_type = BFD_RELOC_AVR32_DIFF8;
8309 + break;
8310 + default:
8311 + return FALSE;
8312 + }
8313 +
8314 + return TRUE;
8315 +}
8316 +
8317 +/* Simplify a fixup. If possible, the fixup is reduced to a single
8318 + constant which is written to the output file. Otherwise, a
8319 + relocation is generated so that the linker can take care of the
8320 + rest.
8321 +
8322 + ELF relocations have certain constraints: They can only take a
8323 + single symbol and a single addend. This means that for difference
8324 + expressions, we _must_ get rid of the fx_subsy symbol somehow.
8325 +
8326 + The difference between two labels in the same section can be
8327 + calculated directly unless 'linkrelax' is set, or a relocation is
8328 + forced. If so, we must emit a R_AVR32_DIFFxx relocation. If there
8329 + are addends involved at this point, we must be especially careful
8330 + as the relocation must point exactly to the symbol being
8331 + subtracted.
8332 +
8333 + When subtracting a symbol defined in the same section as the fixup,
8334 + we might be able to convert it to a PC-relative expression, unless
8335 + linkrelax is set. If this is the case, there's no way we can make
8336 + sure that the difference between the fixup and fx_subsy stays
8337 + constant. So for now, we're just going to disallow that.
8338 + */
8339 +void
8340 +avr32_process_fixup(fixS *fixP, segT this_segment)
8341 +{
8342 + segT add_symbol_segment = absolute_section;
8343 + segT sub_symbol_segment = absolute_section;
8344 + symbolS *fx_addsy, *fx_subsy;
8345 + offsetT value = 0, fx_offset;
8346 + bfd_boolean apply = FALSE;
8347 +
8348 + assert(this_segment != absolute_section);
8349 +
8350 + if (fixP->fx_r_type >= BFD_RELOC_UNUSED)
8351 + {
8352 + as_bad_where(fixP->fx_file, fixP->fx_line,
8353 + _("Bad relocation type %d\n"), fixP->fx_r_type);
8354 + return;
8355 + }
8356 +
8357 + /* BFD_RELOC_AVR32_SUB5 fixups have been swapped by avr32_frob_section() */
8358 + fx_addsy = fixP->fx_addsy;
8359 + fx_subsy = fixP->fx_subsy;
8360 + fx_offset = fixP->fx_offset;
8361 +
8362 + if (fx_addsy)
8363 + add_symbol_segment = S_GET_SEGMENT(fx_addsy);
8364 +
8365 + if (fx_subsy)
8366 + {
8367 + resolve_symbol_value(fx_subsy);
8368 + sub_symbol_segment = S_GET_SEGMENT(fx_subsy);
8369 +
8370 + if (sub_symbol_segment == this_segment
8371 + && (!linkrelax
8372 + || S_GET_VALUE(fx_subsy) == (fixP->fx_frag->fr_address
8373 + + fixP->fx_where)))
8374 + {
8375 + fixP->fx_pcrel = TRUE;
8376 + fx_offset += (fixP->fx_frag->fr_address + fixP->fx_where
8377 + - S_GET_VALUE(fx_subsy));
8378 + fx_subsy = NULL;
8379 + }
8380 + else if (sub_symbol_segment == absolute_section)
8381 + {
8382 + /* The symbol is really a constant. */
8383 + fx_offset -= S_GET_VALUE(fx_subsy);
8384 + fx_subsy = NULL;
8385 + }
8386 + else if (SEG_NORMAL(add_symbol_segment)
8387 + && sub_symbol_segment == add_symbol_segment
8388 + && (!linkrelax || convert_to_diff_reloc(fixP)))
8389 + {
8390 + /* Difference between two labels in the same section. */
8391 + if (linkrelax)
8392 + {
8393 + /* convert_to_diff() has ensured that the reloc type is
8394 + either DIFF32, DIFF16 or DIFF8. */
8395 + value = (S_GET_VALUE(fx_addsy) + fixP->fx_offset
8396 + - S_GET_VALUE(fx_subsy));
8397 +
8398 + /* Try to convert it to a section symbol if possible */
8399 + if (!S_FORCE_RELOC(fx_addsy, 1)
8400 + && !(sub_symbol_segment->flags & SEC_THREAD_LOCAL))
8401 + {
8402 + fx_offset = S_GET_VALUE(fx_subsy);
8403 + fx_addsy = section_symbol(sub_symbol_segment);
8404 + }
8405 + else
8406 + {
8407 + fx_addsy = fx_subsy;
8408 + fx_offset = 0;
8409 + }
8410 +
8411 + fx_subsy = NULL;
8412 + apply = TRUE;
8413 + }
8414 + else
8415 + {
8416 + fx_offset += S_GET_VALUE(fx_addsy);
8417 + fx_offset -= S_GET_VALUE(fx_subsy);
8418 + fx_addsy = NULL;
8419 + fx_subsy = NULL;
8420 + }
8421 + }
8422 + else
8423 + {
8424 + as_bad_where(fixP->fx_file, fixP->fx_line,
8425 + _("can't resolve `%s' {%s section} - `%s' {%s section}"),
8426 + fx_addsy ? S_GET_NAME (fx_addsy) : "0",
8427 + segment_name (add_symbol_segment),
8428 + S_GET_NAME (fx_subsy),
8429 + segment_name (sub_symbol_segment));
8430 + return;
8431 + }
8432 + }
8433 +
8434 + if (fx_addsy && !TC_FORCE_RELOCATION(fixP))
8435 + {
8436 + if (add_symbol_segment == this_segment
8437 + && fixP->fx_pcrel)
8438 + {
8439 + value += S_GET_VALUE(fx_addsy);
8440 + value -= md_pcrel_from_section(fixP, this_segment);
8441 + fx_addsy = NULL;
8442 + fixP->fx_pcrel = FALSE;
8443 + }
8444 + else if (add_symbol_segment == absolute_section)
8445 + {
8446 + fx_offset += S_GET_VALUE(fixP->fx_addsy);
8447 + fx_addsy = NULL;
8448 + }
8449 + }
8450 +
8451 + if (!fx_addsy)
8452 + fixP->fx_done = TRUE;
8453 +
8454 + if (fixP->fx_pcrel)
8455 + {
8456 + if (fx_addsy != NULL
8457 + && S_IS_DEFINED(fx_addsy)
8458 + && S_GET_SEGMENT(fx_addsy) != this_segment)
8459 + value += md_pcrel_from_section(fixP, this_segment);
8460 +
8461 + switch (fixP->fx_r_type)
8462 + {
8463 + case BFD_RELOC_32:
8464 + fixP->fx_r_type = BFD_RELOC_32_PCREL;
8465 + break;
8466 + case BFD_RELOC_16:
8467 + fixP->fx_r_type = BFD_RELOC_16_PCREL;
8468 + break;
8469 + case BFD_RELOC_8:
8470 + fixP->fx_r_type = BFD_RELOC_8_PCREL;
8471 + break;
8472 + case BFD_RELOC_AVR32_SUB5:
8473 + fixP->fx_r_type = BFD_RELOC_AVR32_16N_PCREL;
8474 + break;
8475 + case BFD_RELOC_AVR32_16S:
8476 + fixP->fx_r_type = BFD_RELOC_AVR32_16B_PCREL;
8477 + break;
8478 + case BFD_RELOC_AVR32_14UW:
8479 + fixP->fx_r_type = BFD_RELOC_AVR32_14UW_PCREL;
8480 + break;
8481 + case BFD_RELOC_AVR32_10UW:
8482 + fixP->fx_r_type = BFD_RELOC_AVR32_10UW_PCREL;
8483 + break;
8484 + default:
8485 + /* Should have been taken care of already */
8486 + break;
8487 + }
8488 + }
8489 +
8490 + if (fixP->fx_done || apply)
8491 + {
8492 + const struct avr32_ifield *ifield;
8493 + char *buf = fixP->fx_where + fixP->fx_frag->fr_literal;
8494 +
8495 + if (fixP->fx_done)
8496 + value += fx_offset;
8497 +
8498 + /* For hosts with longs bigger than 32-bits make sure that the top
8499 + bits of a 32-bit negative value read in by the parser are set,
8500 + so that the correct comparisons are made. */
8501 + if (value & 0x80000000)
8502 + value |= (-1L << 31);
8503 +
8504 + switch (fixP->fx_r_type)
8505 + {
8506 + case BFD_RELOC_32:
8507 + case BFD_RELOC_16:
8508 + case BFD_RELOC_8:
8509 + case BFD_RELOC_AVR32_DIFF32:
8510 + case BFD_RELOC_AVR32_DIFF16:
8511 + case BFD_RELOC_AVR32_DIFF8:
8512 + md_number_to_chars(buf, value, fixP->fx_size);
8513 + break;
8514 + case BFD_RELOC_HI16:
8515 + value >>= 16;
8516 + case BFD_RELOC_LO16:
8517 + value &= 0xffff;
8518 + md_number_to_chars(buf + 2, value, 2);
8519 + break;
8520 + case BFD_RELOC_AVR32_16N_PCREL:
8521 + value = -value;
8522 + /* fall through */
8523 + case BFD_RELOC_AVR32_22H_PCREL:
8524 + case BFD_RELOC_AVR32_18W_PCREL:
8525 + case BFD_RELOC_AVR32_16B_PCREL:
8526 + case BFD_RELOC_AVR32_11H_PCREL:
8527 + case BFD_RELOC_AVR32_9H_PCREL:
8528 + case BFD_RELOC_AVR32_9UW_PCREL:
8529 + case BFD_RELOC_AVR32_3U:
8530 + case BFD_RELOC_AVR32_4UH:
8531 + case BFD_RELOC_AVR32_6UW:
8532 + case BFD_RELOC_AVR32_6S:
8533 + case BFD_RELOC_AVR32_7UW:
8534 + case BFD_RELOC_AVR32_8S_EXT:
8535 + case BFD_RELOC_AVR32_8S:
8536 + case BFD_RELOC_AVR32_10UW:
8537 + case BFD_RELOC_AVR32_10SW:
8538 + case BFD_RELOC_AVR32_STHH_W:
8539 + case BFD_RELOC_AVR32_14UW:
8540 + case BFD_RELOC_AVR32_16S:
8541 + case BFD_RELOC_AVR32_16U:
8542 + case BFD_RELOC_AVR32_21S:
8543 + case BFD_RELOC_AVR32_SUB5:
8544 + case BFD_RELOC_AVR32_CPCALL:
8545 + case BFD_RELOC_AVR32_16_CP:
8546 + case BFD_RELOC_AVR32_9W_CP:
8547 + case BFD_RELOC_AVR32_15S:
8548 + ifield = fixP->tc_fix_data.ifield;
8549 + pr_debug("insert field: %ld <= %ld <= %ld (align %u)\n",
8550 + fixP->tc_fix_data.min, value, fixP->tc_fix_data.max,
8551 + fixP->tc_fix_data.align);
8552 + if (value < fixP->tc_fix_data.min || value > fixP->tc_fix_data.max)
8553 + as_bad_where(fixP->fx_file, fixP->fx_line,
8554 + _("operand out of range (%ld not between %ld and %ld)"),
8555 + value, fixP->tc_fix_data.min, fixP->tc_fix_data.max);
8556 + if (value & ((1 << fixP->tc_fix_data.align) - 1))
8557 + as_bad_where(fixP->fx_file, fixP->fx_line,
8558 + _("misaligned operand (required alignment: %d)"),
8559 + 1 << fixP->tc_fix_data.align);
8560 + ifield->insert(ifield, buf, value >> fixP->tc_fix_data.align);
8561 + break;
8562 + case BFD_RELOC_AVR32_ALIGN:
8563 + /* Nothing to do */
8564 + fixP->fx_done = FALSE;
8565 + break;
8566 + default:
8567 + as_fatal("reloc type %s not handled\n",
8568 + bfd_get_reloc_code_name(fixP->fx_r_type));
8569 + }
8570 + }
8571 +
8572 + fixP->fx_addsy = fx_addsy;
8573 + fixP->fx_subsy = fx_subsy;
8574 + fixP->fx_offset = fx_offset;
8575 +
8576 + if (!fixP->fx_done)
8577 + {
8578 + if (!fixP->fx_addsy)
8579 + fixP->fx_addsy = abs_section_sym;
8580 +
8581 + symbol_mark_used_in_reloc(fixP->fx_addsy);
8582 + if (fixP->fx_subsy)
8583 + abort();
8584 + }
8585 +}
8586 +
8587 +#if 0
8588 +void
8589 +md_apply_fix3 (fixS *fixP, valueT *valP, segT seg)
8590 +{
8591 + const struct avr32_ifield *ifield;
8592 + offsetT value = *valP;
8593 + char *buf = fixP->fx_where + fixP->fx_frag->fr_literal;
8594 + bfd_boolean apply;
8595 +
8596 + pr_debug("%s:%u: apply_fix3: r_type=%d value=%lx offset=%lx\n",
8597 + fixP->fx_file, fixP->fx_line, fixP->fx_r_type, *valP,
8598 + fixP->fx_offset);
8599 +
8600 + if (fixP->fx_r_type >= BFD_RELOC_UNUSED)
8601 + {
8602 + as_bad_where(fixP->fx_file, fixP->fx_line,
8603 + _("Bad relocation type %d\n"), fixP->fx_r_type);
8604 + return;
8605 + }
8606 +
8607 + if (!fixP->fx_addsy && !fixP->fx_subsy)
8608 + fixP->fx_done = 1;
8609 +
8610 + if (fixP->fx_pcrel)
8611 + {
8612 + if (fixP->fx_addsy != NULL
8613 + && S_IS_DEFINED(fixP->fx_addsy)
8614 + && S_GET_SEGMENT(fixP->fx_addsy) != seg)
8615 + value += md_pcrel_from_section(fixP, seg);
8616 +
8617 + switch (fixP->fx_r_type)
8618 + {
8619 + case BFD_RELOC_32:
8620 + fixP->fx_r_type = BFD_RELOC_32_PCREL;
8621 + break;
8622 + case BFD_RELOC_16:
8623 + case BFD_RELOC_8:
8624 + as_bad_where (fixP->fx_file, fixP->fx_line,
8625 + _("8- and 16-bit PC-relative relocations not supported"));
8626 + break;
8627 + case BFD_RELOC_AVR32_SUB5:
8628 + fixP->fx_r_type = BFD_RELOC_AVR32_PCREL_SUB5;
8629 + break;
8630 + case BFD_RELOC_AVR32_16S:
8631 + fixP->fx_r_type = BFD_RELOC_AVR32_16_PCREL;
8632 + break;
8633 + default:
8634 + /* Should have been taken care of already */
8635 + break;
8636 + }
8637 + }
8638 +
8639 + if (fixP->fx_r_type == BFD_RELOC_32
8640 + && fixP->fx_subsy)
8641 + {
8642 + fixP->fx_r_type = BFD_RELOC_AVR32_DIFF32;
8643 +
8644 + /* Offsets are only allowed if it's a result of adjusting a
8645 + local symbol into a section-relative offset.
8646 + tc_fix_adjustable() should prevent any adjustment if there
8647 + was an offset involved before. */
8648 + if (fixP->fx_offset && !symbol_section_p(fixP->fx_addsy))
8649 + as_bad_where(fixP->fx_file, fixP->fx_line,
8650 + _("cannot represent symbol difference with an offset"));
8651 +
8652 + value = (S_GET_VALUE(fixP->fx_addsy) + fixP->fx_offset
8653 + - S_GET_VALUE(fixP->fx_subsy));
8654 +
8655 + /* The difference before any relaxing takes place is written
8656 + out, and the DIFF32 reloc identifies the address of the first
8657 + symbol (i.e. the on that's subtracted.) */
8658 + *valP = value;
8659 + fixP->fx_offset -= value;
8660 + fixP->fx_subsy = NULL;
8661 +
8662 + md_number_to_chars(buf, value, fixP->fx_size);
8663 + }
8664 +
8665 + if (fixP->fx_done)
8666 + {
8667 + switch (fixP->fx_r_type)
8668 + {
8669 + case BFD_RELOC_8:
8670 + case BFD_RELOC_16:
8671 + case BFD_RELOC_32:
8672 + md_number_to_chars(buf, value, fixP->fx_size);
8673 + break;
8674 + case BFD_RELOC_HI16:
8675 + value >>= 16;
8676 + case BFD_RELOC_LO16:
8677 + value &= 0xffff;
8678 + *valP = value;
8679 + md_number_to_chars(buf + 2, value, 2);
8680 + break;
8681 + case BFD_RELOC_AVR32_PCREL_SUB5:
8682 + value = -value;
8683 + /* fall through */
8684 + case BFD_RELOC_AVR32_9_PCREL:
8685 + case BFD_RELOC_AVR32_11_PCREL:
8686 + case BFD_RELOC_AVR32_16_PCREL:
8687 + case BFD_RELOC_AVR32_18_PCREL:
8688 + case BFD_RELOC_AVR32_22_PCREL:
8689 + case BFD_RELOC_AVR32_3U:
8690 + case BFD_RELOC_AVR32_4UH:
8691 + case BFD_RELOC_AVR32_6UW:
8692 + case BFD_RELOC_AVR32_6S:
8693 + case BFD_RELOC_AVR32_7UW:
8694 + case BFD_RELOC_AVR32_8S:
8695 + case BFD_RELOC_AVR32_10UW:
8696 + case BFD_RELOC_AVR32_10SW:
8697 + case BFD_RELOC_AVR32_14UW:
8698 + case BFD_RELOC_AVR32_16S:
8699 + case BFD_RELOC_AVR32_16U:
8700 + case BFD_RELOC_AVR32_21S:
8701 + case BFD_RELOC_AVR32_BRC1:
8702 + case BFD_RELOC_AVR32_SUB5:
8703 + case BFD_RELOC_AVR32_CPCALL:
8704 + case BFD_RELOC_AVR32_16_CP:
8705 + case BFD_RELOC_AVR32_9_CP:
8706 + case BFD_RELOC_AVR32_15S:
8707 + ifield = fixP->tc_fix_data.ifield;
8708 + pr_debug("insert field: %ld <= %ld <= %ld (align %u)\n",
8709 + fixP->tc_fix_data.min, value, fixP->tc_fix_data.max,
8710 + fixP->tc_fix_data.align);
8711 + if (value < fixP->tc_fix_data.min || value > fixP->tc_fix_data.max)
8712 + as_bad_where(fixP->fx_file, fixP->fx_line,
8713 + _("operand out of range (%ld not between %ld and %ld)"),
8714 + value, fixP->tc_fix_data.min, fixP->tc_fix_data.max);
8715 + if (value & ((1 << fixP->tc_fix_data.align) - 1))
8716 + as_bad_where(fixP->fx_file, fixP->fx_line,
8717 + _("misaligned operand (required alignment: %d)"),
8718 + 1 << fixP->tc_fix_data.align);
8719 + ifield->insert(ifield, buf, value >> fixP->tc_fix_data.align);
8720 + break;
8721 + case BFD_RELOC_AVR32_ALIGN:
8722 + /* Nothing to do */
8723 + fixP->fx_done = FALSE;
8724 + break;
8725 + default:
8726 + as_fatal("reloc type %s not handled\n",
8727 + bfd_get_reloc_code_name(fixP->fx_r_type));
8728 + }
8729 + }
8730 +}
8731 +#endif
8732 +
8733 +arelent *
8734 +tc_gen_reloc (asection *section ATTRIBUTE_UNUSED,
8735 + fixS *fixp)
8736 +{
8737 + arelent *reloc;
8738 + bfd_reloc_code_real_type code;
8739 +
8740 + reloc = xmalloc (sizeof (arelent));
8741 +
8742 + reloc->sym_ptr_ptr = xmalloc (sizeof (asymbol *));
8743 + *reloc->sym_ptr_ptr = symbol_get_bfdsym (fixp->fx_addsy);
8744 + reloc->address = fixp->fx_frag->fr_address + fixp->fx_where;
8745 + reloc->addend = fixp->fx_offset;
8746 + code = fixp->fx_r_type;
8747 +
8748 + reloc->howto = bfd_reloc_type_lookup (stdoutput, code);
8749 +
8750 + if (reloc->howto == NULL)
8751 + {
8752 + as_bad_where (fixp->fx_file, fixp->fx_line,
8753 + _("cannot represent relocation %s in this object file format"),
8754 + bfd_get_reloc_code_name (code));
8755 + return NULL;
8756 + }
8757 +
8758 + return reloc;
8759 +}
8760 +
8761 +bfd_boolean
8762 +avr32_force_reloc(fixS *fixP)
8763 +{
8764 + if (linkrelax && fixP->fx_addsy
8765 + && !(S_GET_SEGMENT(fixP->fx_addsy)->flags & SEC_DEBUGGING)
8766 + && S_GET_SEGMENT(fixP->fx_addsy) != absolute_section)
8767 + {
8768 + pr_debug(stderr, "force reloc: addsy=%p, r_type=%d, sec=%s\n",
8769 + fixP->fx_addsy, fixP->fx_r_type, S_GET_SEGMENT(fixP->fx_addsy)->name);
8770 + return 1;
8771 + }
8772 +
8773 + return generic_force_reloc(fixP);
8774 +}
8775 +
8776 +bfd_boolean
8777 +avr32_fix_adjustable(fixS *fixP)
8778 +{
8779 + switch (fixP->fx_r_type)
8780 + {
8781 + /* GOT relocations can't have addends since BFD treats all
8782 + references to a given symbol the same. This means that we
8783 + must avoid section-relative references to local symbols when
8784 + dealing with these kinds of relocs */
8785 + case BFD_RELOC_AVR32_GOT32:
8786 + case BFD_RELOC_AVR32_GOT16:
8787 + case BFD_RELOC_AVR32_GOT8:
8788 + case BFD_RELOC_AVR32_GOT21S:
8789 + case BFD_RELOC_AVR32_GOT18SW:
8790 + case BFD_RELOC_AVR32_GOT16S:
8791 + case BFD_RELOC_AVR32_LDA_GOT:
8792 + case BFD_RELOC_AVR32_GOTCALL:
8793 + pr_debug("fix not adjustable\n");
8794 + return 0;
8795 +
8796 + default:
8797 + break;
8798 + }
8799 +
8800 + return 1;
8801 +}
8802 +
8803 +/* When we want the linker to be able to relax the code, we need to
8804 + output a reloc for every .align directive requesting an alignment
8805 + to a four byte boundary or larger. If we don't do this, the linker
8806 + can't guarantee that the alignment is actually maintained in the
8807 + linker output.
8808 +
8809 + TODO: Might as well insert proper NOPs while we're at it... */
8810 +void
8811 +avr32_handle_align(fragS *frag)
8812 +{
8813 + if (linkrelax
8814 + && frag->fr_type == rs_align_code
8815 + && frag->fr_address + frag->fr_fix > 0
8816 + && frag->fr_offset > 0)
8817 + {
8818 + /* The alignment order (fr_offset) is stored in the addend. */
8819 + fix_new(frag, frag->fr_fix, 2, &abs_symbol, frag->fr_offset,
8820 + FALSE, BFD_RELOC_AVR32_ALIGN);
8821 + }
8822 +}
8823 +
8824 +/* Relax_align. Advance location counter to next address that has 'alignment'
8825 + lowest order bits all 0s, return size of adjustment made. */
8826 +relax_addressT
8827 +avr32_relax_align(segT segment ATTRIBUTE_UNUSED,
8828 + fragS *fragP,
8829 + relax_addressT address)
8830 +{
8831 + relax_addressT mask;
8832 + relax_addressT new_address;
8833 + int alignment;
8834 +
8835 + alignment = fragP->fr_offset;
8836 + mask = ~((~0) << alignment);
8837 + new_address = (address + mask) & (~mask);
8838 +
8839 + return new_address - address;
8840 +}
8841 +
8842 +/* Turn a string in input_line_pointer into a floating point constant
8843 + of type type, and store the appropriate bytes in *litP. The number
8844 + of LITTLENUMS emitted is stored in *sizeP . An error message is
8845 + returned, or NULL on OK. */
8846 +
8847 +/* Equal to MAX_PRECISION in atof-ieee.c */
8848 +#define MAX_LITTLENUMS 6
8849 +
8850 +char *
8851 +md_atof (type, litP, sizeP)
8852 +char type;
8853 +char * litP;
8854 +int * sizeP;
8855 +{
8856 + int i;
8857 + int prec;
8858 + LITTLENUM_TYPE words [MAX_LITTLENUMS];
8859 + char * t;
8860 +
8861 + switch (type)
8862 + {
8863 + case 'f':
8864 + case 'F':
8865 + case 's':
8866 + case 'S':
8867 + prec = 2;
8868 + break;
8869 +
8870 + case 'd':
8871 + case 'D':
8872 + case 'r':
8873 + case 'R':
8874 + prec = 4;
8875 + break;
8876 +
8877 + /* FIXME: Some targets allow other format chars for bigger sizes here. */
8878 +
8879 + default:
8880 + * sizeP = 0;
8881 + return _("Bad call to md_atof()");
8882 + }
8883 +
8884 + t = atof_ieee (input_line_pointer, type, words);
8885 + if (t)
8886 + input_line_pointer = t;
8887 + * sizeP = prec * sizeof (LITTLENUM_TYPE);
8888 +
8889 + for (i = 0; i < prec; i++)
8890 + {
8891 + md_number_to_chars (litP, (valueT) words[i],
8892 + sizeof (LITTLENUM_TYPE));
8893 + litP += sizeof (LITTLENUM_TYPE);
8894 + }
8895 +
8896 + return 0;
8897 +}
8898 +
8899 +static char *avr32_end_of_match(char *cont, char *what)
8900 +{
8901 + int len = strlen (what);
8902 +
8903 + if (! is_part_of_name (cont[len])
8904 + && strncasecmp (cont, what, len) == 0)
8905 + return cont + len;
8906 +
8907 + return NULL;
8908 +}
8909 +
8910 +int
8911 +avr32_parse_name (char const *name, expressionS *exp, char *nextchar)
8912 +{
8913 + char *next = input_line_pointer;
8914 + char *next_end;
8915 +
8916 + pr_debug("parse_name: %s, nextchar=%c (%02x)\n", name, *nextchar, *nextchar);
8917 +
8918 + if (*nextchar == '(')
8919 + {
8920 + if (strcasecmp(name, "hi") == 0)
8921 + {
8922 + *next = *nextchar;
8923 +
8924 + expression(exp);
8925 +
8926 + if (exp->X_op == O_constant)
8927 + {
8928 + pr_debug(" -> constant hi(0x%08lx) -> 0x%04lx\n",
8929 + exp->X_add_number, exp->X_add_number >> 16);
8930 + exp->X_add_number = (exp->X_add_number >> 16) & 0xffff;
8931 + }
8932 + else
8933 + {
8934 + exp->X_md = exp->X_op;
8935 + exp->X_op = O_hi;
8936 + }
8937 +
8938 + return 1;
8939 + }
8940 + else if (strcasecmp(name, "lo") == 0)
8941 + {
8942 + *next = *nextchar;
8943 +
8944 + expression(exp);
8945 +
8946 + if (exp->X_op == O_constant)
8947 + exp->X_add_number &= 0xffff;
8948 + else
8949 + {
8950 + exp->X_md = exp->X_op;
8951 + exp->X_op = O_lo;
8952 + }
8953 +
8954 + return 1;
8955 + }
8956 + }
8957 + else if (*nextchar == '@')
8958 + {
8959 + exp->X_md = exp->X_op;
8960 +
8961 + if ((next_end = avr32_end_of_match (next + 1, "got")))
8962 + exp->X_op = O_got;
8963 + else if ((next_end = avr32_end_of_match (next + 1, "tlsgd")))
8964 + exp->X_op = O_tlsgd;
8965 + /* Add more as needed */
8966 + else
8967 + {
8968 + char c;
8969 + input_line_pointer++;
8970 + c = get_symbol_end();
8971 + as_bad (_("unknown relocation override `%s'"), next + 1);
8972 + *input_line_pointer = c;
8973 + input_line_pointer = next;
8974 + return 0;
8975 + }
8976 +
8977 + exp->X_op_symbol = NULL;
8978 + exp->X_add_symbol = symbol_find_or_make (name);
8979 + exp->X_add_number = 0;
8980 +
8981 + *input_line_pointer = *nextchar;
8982 + input_line_pointer = next_end;
8983 + *nextchar = *input_line_pointer;
8984 + *input_line_pointer = '\0';
8985 + return 1;
8986 + }
8987 + else if (strcmp (name, "_GLOBAL_OFFSET_TABLE_") == 0)
8988 + {
8989 + if (!GOT_symbol)
8990 + GOT_symbol = symbol_find_or_make(name);
8991 +
8992 + exp->X_add_symbol = GOT_symbol;
8993 + exp->X_op = O_symbol;
8994 + exp->X_add_number = 0;
8995 + return 1;
8996 + }
8997 +
8998 + return 0;
8999 +}
9000 +
9001 +static void
9002 +s_rseg (int value ATTRIBUTE_UNUSED)
9003 +{
9004 + /* Syntax: RSEG segment_name [:type] [NOROOT|ROOT] [(align)]
9005 + * Defaults:
9006 + * - type: undocumented ("typically CODE or DATA")
9007 + * - ROOT
9008 + * - align: 1 for code, 0 for others
9009 + *
9010 + * TODO: NOROOT is ignored. If gas supports discardable segments, it should
9011 + * be implemented.
9012 + */
9013 + char *name, *end;
9014 + int length, type, attr;
9015 + int align = 0;
9016 +
9017 + SKIP_WHITESPACE();
9018 +
9019 + end = input_line_pointer;
9020 + while (0 == strchr ("\n\t;:( ", *end))
9021 + end++;
9022 + if (end == input_line_pointer)
9023 + {
9024 + as_warn (_("missing name"));
9025 + ignore_rest_of_line();
9026 + return;
9027 + }
9028 +
9029 + name = xmalloc (end - input_line_pointer + 1);
9030 + memcpy (name, input_line_pointer, end - input_line_pointer);
9031 + name[end - input_line_pointer] = '\0';
9032 + input_line_pointer = end;
9033 +
9034 + SKIP_WHITESPACE();
9035 +
9036 + type = SHT_NULL;
9037 + attr = 0;
9038 +
9039 + if (*input_line_pointer == ':')
9040 + {
9041 + /* Skip the colon */
9042 + ++input_line_pointer;
9043 + SKIP_WHITESPACE();
9044 +
9045 + /* Possible options at this point:
9046 + * - flag (ROOT or NOROOT)
9047 + * - a segment type
9048 + */
9049 + end = input_line_pointer;
9050 + while (0 == strchr ("\n\t;:( ", *end))
9051 + end++;
9052 + length = end - input_line_pointer;
9053 + if (((length == 4) && (0 == strncasecmp( input_line_pointer, "ROOT", 4))) ||
9054 + ((length == 6) && (0 == strncasecmp( input_line_pointer, "NOROOT", 6))))
9055 + {
9056 + /* Ignore ROOT/NOROOT */
9057 + input_line_pointer = end;
9058 + }
9059 + else
9060 + {
9061 + /* Must be a segment type */
9062 + switch (*input_line_pointer)
9063 + {
9064 + case 'C':
9065 + case 'c':
9066 + if ((length == 4) &&
9067 + (0 == strncasecmp (input_line_pointer, "CODE", 4)))
9068 + {
9069 + attr |= SHF_ALLOC | SHF_EXECINSTR;
9070 + type = SHT_PROGBITS;
9071 + align = 1;
9072 + break;
9073 + }
9074 + if ((length == 5) &&
9075 + (0 == strncasecmp (input_line_pointer, "CONST", 5)))
9076 + {
9077 + attr |= SHF_ALLOC;
9078 + type = SHT_PROGBITS;
9079 + break;
9080 + }
9081 + goto de_fault;
9082 +
9083 + case 'D':
9084 + case 'd':
9085 + if ((length == 4) &&
9086 + (0 == strncasecmp (input_line_pointer, "DATA", 4)))
9087 + {
9088 + attr |= SHF_ALLOC | SHF_WRITE;
9089 + type = SHT_PROGBITS;
9090 + break;
9091 + }
9092 + goto de_fault;
9093 +
9094 + /* TODO: Add FAR*, HUGE*, IDATA and NEAR* if necessary */
9095 +
9096 + case 'U':
9097 + case 'u':
9098 + if ((length == 7) &&
9099 + (0 == strncasecmp (input_line_pointer, "UNTYPED", 7)))
9100 + break;
9101 + goto de_fault;
9102 +
9103 + /* TODO: Add XDATA and ZPAGE if necessary */
9104 +
9105 + de_fault:
9106 + default:
9107 + as_warn (_("unrecognized segment type"));
9108 + }
9109 +
9110 + input_line_pointer = end;
9111 + SKIP_WHITESPACE();
9112 +
9113 + if (*input_line_pointer == ':')
9114 + {
9115 + /* ROOT/NOROOT */
9116 + ++input_line_pointer;
9117 + SKIP_WHITESPACE();
9118 +
9119 + end = input_line_pointer;
9120 + while (0 == strchr ("\n\t;:( ", *end))
9121 + end++;
9122 + length = end - input_line_pointer;
9123 + if (! ((length == 4) &&
9124 + (0 == strncasecmp( input_line_pointer, "ROOT", 4))) &&
9125 + ! ((length == 6) &&
9126 + (0 == strncasecmp( input_line_pointer, "NOROOT", 6))))
9127 + {
9128 + as_warn (_("unrecognized segment flag"));
9129 + }
9130 +
9131 + input_line_pointer = end;
9132 + SKIP_WHITESPACE();
9133 + }
9134 + }
9135 + }
9136 +
9137 + if (*input_line_pointer == '(')
9138 + {
9139 + align = get_absolute_expression ();
9140 + }
9141 +
9142 + demand_empty_rest_of_line();
9143 +
9144 + obj_elf_change_section (name, type, attr, 0, NULL, 0, 0);
9145 +#ifdef AVR32_DEBUG
9146 + fprintf( stderr, "RSEG: Changed section to %s, type: 0x%x, attr: 0x%x\n",
9147 + name, type, attr );
9148 + fprintf( stderr, "RSEG: Aligning to 2**%d\n", align );
9149 +#endif
9150 +
9151 + if (align > 15)
9152 + {
9153 + align = 15;
9154 + as_warn (_("alignment too large: %u assumed"), align);
9155 + }
9156 +
9157 + /* Hope not, that is */
9158 + assert (now_seg != absolute_section);
9159 +
9160 + /* Only make a frag if we HAVE to... */
9161 + if (align != 0 && !need_pass_2)
9162 + {
9163 + if (subseg_text_p (now_seg))
9164 + frag_align_code (align, 0);
9165 + else
9166 + frag_align (align, 0, 0);
9167 + }
9168 +
9169 + record_alignment (now_seg, align - OCTETS_PER_BYTE_POWER);
9170 +}
9171 +
9172 +/* vim: syntax=c sw=2
9173 + */
9174 --- /dev/null
9175 +++ b/gas/config/tc-avr32.h
9176 @@ -0,0 +1,325 @@
9177 +/* Assembler definitions for AVR32.
9178 + Copyright 2003-2006 Atmel Corporation.
9179 +
9180 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
9181 +
9182 + This file is part of GAS, the GNU Assembler.
9183 +
9184 + GAS is free software; you can redistribute it and/or modify it
9185 + under the terms of the GNU General Public License as published by
9186 + the Free Software Foundation; either version 2, or (at your option)
9187 + any later version.
9188 +
9189 + GAS is distributed in the hope that it will be useful, but WITHOUT
9190 + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
9191 + or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
9192 + License for more details.
9193 +
9194 + You should have received a copy of the GNU General Public License
9195 + along with GAS; see the file COPYING. If not, write to the Free
9196 + Software Foundation, 59 Temple Place - Suite 330, Boston, MA
9197 + 02111-1307, USA. */
9198 +
9199 +#if 0
9200 +#define DEBUG
9201 +#define DEBUG1
9202 +#define DEBUG2
9203 +#define DEBUG3
9204 +#define DEBUG4
9205 +#define DEBUG5
9206 +#endif
9207 +
9208 +/* Are we trying to be compatible with the IAR assembler? (--iar) */
9209 +extern int avr32_iarcompat;
9210 +
9211 +/* By convention, you should define this macro in the `.h' file. For
9212 + example, `tc-m68k.h' defines `TC_M68K'. You might have to use this
9213 + if it is necessary to add CPU specific code to the object format
9214 + file. */
9215 +#define TC_AVR32
9216 +
9217 +/* This macro is the BFD target name to use when creating the output
9218 + file. This will normally depend upon the `OBJ_FMT' macro. */
9219 +#define TARGET_FORMAT "elf32-avr32"
9220 +
9221 +/* This macro is the BFD architecture to pass to `bfd_set_arch_mach'. */
9222 +#define TARGET_ARCH bfd_arch_avr32
9223 +
9224 +/* This macro is the BFD machine number to pass to
9225 + `bfd_set_arch_mach'. If it is not defined, GAS will use 0. */
9226 +#define TARGET_MACH 0
9227 +
9228 +/* UNDOCUMENTED: Allow //-style comments */
9229 +#define DOUBLESLASH_LINE_COMMENTS
9230 +
9231 +/* You should define this macro to be non-zero if the target is big
9232 + endian, and zero if the target is little endian. */
9233 +#define TARGET_BYTES_BIG_ENDIAN 1
9234 +
9235 +/* FIXME: It seems that GAS only expects a one-byte opcode...
9236 + #define NOP_OPCODE 0xd703 */
9237 +
9238 +/* If you define this macro, GAS will warn about the use of
9239 + nonstandard escape sequences in a string. */
9240 +#undef ONLY_STANDARD_ESCAPES
9241 +
9242 +#define DWARF2_FORMAT() dwarf2_format_32bit
9243 +
9244 +/* Instructions are either 2 or 4 bytes long */
9245 +/* #define DWARF2_LINE_MIN_INSN_LENGTH 2 */
9246 +
9247 +/* GAS will call this function for any expression that can not be
9248 + recognized. When the function is called, `input_line_pointer'
9249 + will point to the start of the expression. */
9250 +#define md_operand(x)
9251 +
9252 +#define md_parse_name(name, expr, mode, c) avr32_parse_name(name, expr, c)
9253 +extern int avr32_parse_name(const char *, struct expressionS *, char *);
9254 +
9255 +/* You may define this macro to generate a fixup for a data
9256 + allocation pseudo-op. */
9257 +#define TC_CONS_FIX_NEW(FRAG, OFF, LEN, EXP) \
9258 + avr32_cons_fix_new(FRAG, OFF, LEN, EXP)
9259 +void avr32_cons_fix_new (fragS *, int, int, expressionS *);
9260 +
9261 +/* `extsym - .' expressions can be emitted using PC-relative relocs */
9262 +#define DIFF_EXPR_OK
9263 +
9264 +/* This is used to construct expressions out of @gotoff, etc. The
9265 + relocation type is stored in X_md */
9266 +#define O_got O_md1
9267 +#define O_hi O_md2
9268 +#define O_lo O_md3
9269 +#define O_tlsgd O_md4
9270 +
9271 +/* You may define this macro to parse an expression used in a data
9272 + allocation pseudo-op such as `.word'. You can use this to
9273 + recognize relocation directives that may appear in such directives. */
9274 +/* #define TC_PARSE_CONS_EXPRESSION(EXPR,N) avr_parse_cons_expression (EXPR,N)
9275 + void avr_parse_cons_expression (expressionS *exp, int nbytes); */
9276 +
9277 +/* This should just call either `number_to_chars_bigendian' or
9278 + `number_to_chars_littleendian', whichever is appropriate. On
9279 + targets like the MIPS which support options to change the
9280 + endianness, which function to call is a runtime decision. On
9281 + other targets, `md_number_to_chars' can be a simple macro. */
9282 +#define md_number_to_chars number_to_chars_bigendian
9283 +
9284 +/* `md_short_jump_size'
9285 + `md_long_jump_size'
9286 + `md_create_short_jump'
9287 + `md_create_long_jump'
9288 + If `WORKING_DOT_WORD' is defined, GAS will not do broken word
9289 + processing (*note Broken words::.). Otherwise, you should set
9290 + `md_short_jump_size' to the size of a short jump (a jump that is
9291 + just long enough to jump around a long jmp) and
9292 + `md_long_jump_size' to the size of a long jump (a jump that can go
9293 + anywhere in the function), You should define
9294 + `md_create_short_jump' to create a short jump around a long jump,
9295 + and define `md_create_long_jump' to create a long jump. */
9296 +#define WORKING_DOT_WORD
9297 +
9298 +/* If you define this macro, it means that `tc_gen_reloc' may return
9299 + multiple relocation entries for a single fixup. In this case, the
9300 + return value of `tc_gen_reloc' is a pointer to a null terminated
9301 + array. */
9302 +#undef RELOC_EXPANSION_POSSIBLE
9303 +
9304 +/* If you define this macro, GAS will not require pseudo-ops to start with a .
9305 + character. */
9306 +#define NO_PSEUDO_DOT (avr32_iarcompat)
9307 +
9308 +/* The IAR assembler uses $ as the location counter. Unfortunately, we
9309 + can't make this dependent on avr32_iarcompat... */
9310 +#define DOLLAR_DOT
9311 +
9312 +/* Values passed to md_apply_fix3 don't include the symbol value. */
9313 +#define MD_APPLY_SYM_VALUE(FIX) 0
9314 +
9315 +/* The number of bytes to put into a word in a listing. This affects
9316 + the way the bytes are clumped together in the listing. For
9317 + example, a value of 2 might print `1234 5678' where a value of 1
9318 + would print `12 34 56 78'. The default value is 4. */
9319 +#define LISTING_WORD_SIZE 4
9320 +
9321 +/* extern const struct relax_type md_relax_table[];
9322 +#define TC_GENERIC_RELAX_TABLE md_relax_table */
9323 +
9324 +/*
9325 + An `.lcomm' directive with no explicit alignment parameter will use
9326 + this macro to set P2VAR to the alignment that a request for SIZE
9327 + bytes will have. The alignment is expressed as a power of two. If
9328 + no alignment should take place, the macro definition should do
9329 + nothing. Some targets define a `.bss' directive that is also
9330 + affected by this macro. The default definition will set P2VAR to
9331 + the truncated power of two of sizes up to eight bytes.
9332 +
9333 + We want doublewords to be word-aligned, so we're going to modify the
9334 + default definition a tiny bit.
9335 +*/
9336 +#define TC_IMPLICIT_LCOMM_ALIGNMENT(SIZE, P2VAR) \
9337 + do \
9338 + { \
9339 + if ((SIZE) >= 4) \
9340 + (P2VAR) = 2; \
9341 + else if ((SIZE) >= 2) \
9342 + (P2VAR) = 1; \
9343 + else \
9344 + (P2VAR) = 0; \
9345 + } \
9346 + while (0)
9347 +
9348 +/* When relaxing, we need to generate relocations for alignment
9349 + directives. */
9350 +#define HANDLE_ALIGN(frag) avr32_handle_align(frag)
9351 +extern void avr32_handle_align(fragS *);
9352 +
9353 +/* See internals doc for explanation. Oh wait...
9354 + Now, can you guess where "alignment" comes from? ;-) */
9355 +#define MAX_MEM_FOR_RS_ALIGN_CODE ((1 << alignment) - 1)
9356 +
9357 +/* We need to stop gas from reducing certain expressions (e.g. GOT
9358 + references) */
9359 +#define tc_fix_adjustable(fix) avr32_fix_adjustable(fix)
9360 +extern bfd_boolean avr32_fix_adjustable(struct fix *);
9361 +
9362 +/* The linker needs to be passed a little more information when relaxing. */
9363 +#define TC_FORCE_RELOCATION(fix) avr32_force_reloc(fix)
9364 +extern bfd_boolean avr32_force_reloc(struct fix *);
9365 +
9366 +/* I'm tired of working around all the madness in fixup_segment().
9367 + This hook will do basically the same things as the generic code,
9368 + and then it will "goto" right past it. */
9369 +#define TC_VALIDATE_FIX(FIX, SEG, SKIP) \
9370 + do \
9371 + { \
9372 + avr32_process_fixup(FIX, SEG); \
9373 + if (!(FIX)->fx_done) \
9374 + ++seg_reloc_count; \
9375 + goto SKIP; \
9376 + } \
9377 + while (0)
9378 +extern void avr32_process_fixup(struct fix *fixP, segT this_segment);
9379 +
9380 +/* Positive values of TC_FX_SIZE_SLACK allow a target to define
9381 + fixups that far past the end of a frag. Having such fixups
9382 + is of course most most likely a bug in setting fx_size correctly.
9383 + A negative value disables the fixup check entirely, which is
9384 + appropriate for something like the Renesas / SuperH SH_COUNT
9385 + reloc. */
9386 +/* This target is buggy, and sets fix size too large. */
9387 +#define TC_FX_SIZE_SLACK(FIX) -1
9388 +
9389 +/* We don't want the gas core to make any assumptions about our way of
9390 + doing linkrelaxing. */
9391 +#define TC_LINKRELAX_FIXUP(SEG) 0
9392 +
9393 +/* ... but we do want it to insert lots of padding. */
9394 +#define LINKER_RELAXING_SHRINKS_ONLY
9395 +
9396 +/* Better do it ourselves, really... */
9397 +#define TC_RELAX_ALIGN(SEG, FRAG, ADDR) avr32_relax_align(SEG, FRAG, ADDR)
9398 +extern relax_addressT
9399 +avr32_relax_align(segT segment, fragS *fragP, relax_addressT address);
9400 +
9401 +/* Use line number format that is amenable to linker relaxation. */
9402 +#define DWARF2_USE_FIXED_ADVANCE_PC (linkrelax != 0)
9403 +
9404 +/* This is called by write_object_file() just before symbols are
9405 + attempted converted into section symbols. */
9406 +#define tc_frob_file_before_adjust() avr32_frob_file()
9407 +extern void avr32_frob_file(void);
9408 +
9409 +/* If you define this macro, GAS will call it at the end of each input
9410 + file. */
9411 +#define md_cleanup() avr32_cleanup()
9412 +extern void avr32_cleanup(void);
9413 +
9414 +/* There's an AVR32-specific hack in operand() which creates O_md
9415 + expressions when encountering HWRD or LWRD. We need to generate
9416 + proper relocs for them */
9417 +/* #define md_cgen_record_fixup_exp avr32_cgen_record_fixup_exp */
9418 +
9419 +/* I needed to add an extra hook in gas_cgen_finish_insn() for
9420 + conversion of O_md* operands because md_cgen_record_fixup_exp()
9421 + isn't called for relaxable insns */
9422 +/* #define md_cgen_convert_expr(exp, opinfo) avr32_cgen_convert_expr(exp, opinfo)
9423 + int avr32_cgen_convert_expr(expressionS *, int); */
9424 +
9425 +/* #define tc_gen_reloc gas_cgen_tc_gen_reloc */
9426 +
9427 +/* If you define this macro, it should return the position from which
9428 + the PC relative adjustment for a PC relative fixup should be
9429 + made. On many processors, the base of a PC relative instruction is
9430 + the next instruction, so this macro would return the length of an
9431 + instruction, plus the address of the PC relative fixup. The latter
9432 + can be calculated as fixp->fx_where + fixp->fx_frag->fr_address. */
9433 +extern long md_pcrel_from_section (struct fix *, segT);
9434 +#define MD_PCREL_FROM_SECTION(FIX, SEC) md_pcrel_from_section (FIX, SEC)
9435 +
9436 +#define LOCAL_LABEL(name) (name[0] == '.' && (name[1] == 'L'))
9437 +#define LOCAL_LABELS_FB 1
9438 +
9439 +struct avr32_relaxer
9440 +{
9441 + int (*estimate_size)(fragS *, segT);
9442 + long (*relax_frag)(segT, fragS *, long);
9443 + void (*convert_frag)(bfd *, segT, fragS *);
9444 +};
9445 +
9446 +/* AVR32 has quite complex instruction coding, which means we need
9447 + * lots of information in order to do the right thing during relaxing
9448 + * (basically, we need to be able to reconstruct a whole new opcode if
9449 + * necessary) */
9450 +#define TC_FRAG_TYPE struct avr32_frag_data
9451 +
9452 +struct cpool;
9453 +
9454 +struct avr32_frag_data
9455 +{
9456 + /* TODO: Maybe add an expression object here so that we can use
9457 + fix_new_exp() in md_convert_frag? We may have to decide
9458 + pcrel-ness in md_estimate_size_before_relax() as well...or we
9459 + might do it when parsing. Doing it while parsing may fail
9460 + because the sub_symbol is undefined then... */
9461 + int pcrel;
9462 + int force_extended;
9463 + int reloc_info;
9464 + struct avr32_relaxer *relaxer;
9465 + expressionS exp;
9466 +
9467 + /* Points to associated constant pool, for use by LDA and CALL in
9468 + non-pic mode, and when relaxing the .cpool directive */
9469 + struct cpool *pool;
9470 + unsigned int pool_entry;
9471 +};
9472 +
9473 +/* We will have to initialize the fields explicitly when needed */
9474 +#define TC_FRAG_INIT(fragP)
9475 +
9476 +#define md_estimate_size_before_relax(fragP, segT) \
9477 + ((fragP)->tc_frag_data.relaxer->estimate_size(fragP, segT))
9478 +#define md_relax_frag(segment, fragP, stretch) \
9479 + ((fragP)->tc_frag_data.relaxer->relax_frag(segment, fragP, stretch))
9480 +#define md_convert_frag(abfd, segment, fragP) \
9481 + ((fragP)->tc_frag_data.relaxer->convert_frag(abfd, segment, fragP))
9482 +
9483 +#define TC_FIX_TYPE struct avr32_fix_data
9484 +
9485 +struct avr32_fix_data
9486 +{
9487 + const struct avr32_ifield *ifield;
9488 + unsigned int align;
9489 + long min;
9490 + long max;
9491 +};
9492 +
9493 +#define TC_INIT_FIX_DATA(fixP) \
9494 + do \
9495 + { \
9496 + (fixP)->tc_fix_data.ifield = NULL; \
9497 + (fixP)->tc_fix_data.align = 0; \
9498 + (fixP)->tc_fix_data.min = 0; \
9499 + (fixP)->tc_fix_data.max = 0; \
9500 + } \
9501 + while (0)
9502 --- a/gas/configure.tgt
9503 +++ b/gas/configure.tgt
9504 @@ -33,6 +33,7 @@ case ${cpu} in
9505 am33_2.0) cpu_type=mn10300 endian=little ;;
9506 arm*be|arm*b) cpu_type=arm endian=big ;;
9507 arm*) cpu_type=arm endian=little ;;
9508 + avr32*) cpu_type=avr32 endian=big ;;
9509 bfin*) cpu_type=bfin endian=little ;;
9510 c4x*) cpu_type=tic4x ;;
9511 cr16*) cpu_type=cr16 endian=little ;;
9512 @@ -129,6 +130,9 @@ case ${generic_target} in
9513 bfin-*elf) fmt=elf ;;
9514 cr16-*-elf*) fmt=elf ;;
9515
9516 + avr32-*-linux*) fmt=elf em=linux bfd_gas=yes ;;
9517 + avr32*) fmt=elf bfd_gas=yes ;;
9518 +
9519 cris-*-linux-* | crisv32-*-linux-*)
9520 fmt=multi em=linux ;;
9521 cris-*-* | crisv32-*-*) fmt=multi ;;
9522 --- a/gas/doc/all.texi
9523 +++ b/gas/doc/all.texi
9524 @@ -30,6 +30,7 @@
9525 @set ARC
9526 @set ARM
9527 @set AVR
9528 +@set AVR32
9529 @set BFIN
9530 @set CR16
9531 @set CRIS
9532 --- a/gas/doc/as.texinfo
9533 +++ b/gas/doc/as.texinfo
9534 @@ -6353,6 +6353,9 @@ subject, see the hardware manufacturer's
9535 @ifset AVR
9536 * AVR-Dependent:: AVR Dependent Features
9537 @end ifset
9538 +@ifset AVR32
9539 +* AVR32-Dependent:: AVR32 Dependent Features
9540 +@end ifset
9541 @ifset BFIN
9542 * BFIN-Dependent:: BFIN Dependent Features
9543 @end ifset
9544 @@ -6476,6 +6479,10 @@ subject, see the hardware manufacturer's
9545 @include c-avr.texi
9546 @end ifset
9547
9548 +@ifset AVR32
9549 +@include c-avr32.texi
9550 +@end ifset
9551 +
9552 @ifset BFIN
9553 @include c-bfin.texi
9554 @end ifset
9555 --- /dev/null
9556 +++ b/gas/doc/c-avr32.texi
9557 @@ -0,0 +1,247 @@
9558 +@c Copyright 2005, 2006
9559 +@c Atmel Corporation
9560 +@c This is part of the GAS manual.
9561 +@c For copying conditions, see the file as.texinfo.
9562 +
9563 +@ifset GENERIC
9564 +@page
9565 +@node AVR32-Dependent
9566 +@chapter AVR32 Dependent Features
9567 +@end ifset
9568 +
9569 +@ifclear GENERIC
9570 +@node Machine Dependencies
9571 +@chapter AVR32 Dependent Features
9572 +@end ifclear
9573 +
9574 +@cindex AVR32 support
9575 +@menu
9576 +* AVR32 Options:: Options
9577 +* AVR32 Syntax:: Syntax
9578 +* AVR32 Directives:: Directives
9579 +* AVR32 Opcodes:: Opcodes
9580 +@end menu
9581 +
9582 +@node AVR32 Options
9583 +@section Options
9584 +@cindex AVR32 options
9585 +@cindex options for AVR32
9586 +
9587 +There are currently no AVR32-specific options. However, the following
9588 +options are planned:
9589 +
9590 +@table @code
9591 +
9592 +@cindex @code{--pic} command line option, AVR32
9593 +@cindex PIC code generation for AVR32
9594 +@item --pic
9595 +This option specifies that the output of the assembler should be marked
9596 +as position-independent code (PIC). It will also ensure that
9597 +pseudo-instructions that deal with address calculation are output as
9598 +PIC, and that all absolute address references in the code are marked as
9599 +such.
9600 +
9601 +@cindex @code{--linkrelax} command line option, AVR32
9602 +@item --linkrelax
9603 +This option specifies that the output of the assembler should be marked
9604 +as linker-relaxable. It will also ensure that all PC-relative operands
9605 +that may change during linker relaxation get appropriate relocations.
9606 +
9607 +@end table
9608 +
9609 +
9610 +@node AVR32 Syntax
9611 +@section Syntax
9612 +@menu
9613 +* AVR32-Chars:: Special Characters
9614 +* AVR32-Symrefs:: Symbol references
9615 +@end menu
9616 +
9617 +@node AVR32-Chars
9618 +@subsection Special Characters
9619 +
9620 +@cindex line comment character, AVR32
9621 +@cindex AVR32 line comment character
9622 +The presence of a @samp{//} on a line indicates the start of a comment
9623 +that extends to the end of the current line. If a @samp{#} appears as
9624 +the first character of a line, the whole line is treated as a comment.
9625 +
9626 +@cindex line separator, AVR32
9627 +@cindex statement separator, AVR32
9628 +@cindex AVR32 line separator
9629 +The @samp{;} character can be used instead of a newline to separate
9630 +statements.
9631 +
9632 +@node AVR32-Symrefs
9633 +@subsection Symbol references
9634 +
9635 +The absolute value of a symbol can be obtained by simply naming the
9636 +symbol. However, as AVR32 symbols have 32-bit values, most symbols have
9637 +values that are outside the range of any instructions.
9638 +
9639 +Instructions that take a PC-relative offset, e.g. @code{lddpc} or
9640 +@code{rcall}, can also reference a symbol by simply naming the symbol
9641 +(no explicit calculations necessary). In this case, the assembler or
9642 +linker subtracts the address of the instruction from the symbol's value
9643 +and inserts the result into the instruction. Note that even though an
9644 +overflow is less likely to happen for a relative reference than for an
9645 +absolute reference, the assembler or linker will generate an error if
9646 +the referenced symbol is too far away from the current location.
9647 +
9648 +Relative references can be used for data as well. For example:
9649 +
9650 +@smallexample
9651 + lddpc r0, 2f
9652 +1: add r0, pc
9653 + ...
9654 + .align 2
9655 +2: .int @var{some_symbol} - 1b
9656 +@end smallexample
9657 +
9658 +Here, r0 will end up with the run-time address of @var{some_symbol} even
9659 +if the program was loaded at a different address than it was linked
9660 +(position-independent code).
9661 +
9662 +@subsubsection Symbol modifiers
9663 +
9664 +@table @code
9665 +
9666 +@item @code{hi(@var{symbol})}
9667 +Evaluates to the value of the symbol shifted right 16 bits. This will
9668 +work even if @var{symbol} is defined in a different module.
9669 +
9670 +@item @code{lo(@var{symbol})}
9671 +Evaluates to the low 16 bits of the symbol's value. This will work even
9672 +if @var{symbol} is defined in a different module.
9673 +
9674 +@item @code{@var{symbol}@@got}
9675 +Create a GOT entry for @var{symbol} and return the offset of that entry
9676 +relative to the GOT base.
9677 +
9678 +@end table
9679 +
9680 +
9681 +@node AVR32 Directives
9682 +@section Directives
9683 +@cindex machine directives, AVR32
9684 +@cindex AVR32 directives
9685 +
9686 +@table @code
9687 +
9688 +@cindex @code{.cpool} directive, AVR32
9689 +@item .cpool
9690 +This directive causes the current contents of the constant pool to be
9691 +dumped into the current section at the current location (aligned to a
9692 +word boundary). @code{GAS} maintains a separate constant pool for each
9693 +section and each sub-section. The @code{.cpool} directive will only
9694 +affect the constant pool of the current section and sub-section. At the
9695 +end of assembly, all remaining, non-empty constant pools will
9696 +automatically be dumped.
9697 +
9698 +@end table
9699 +
9700 +
9701 +@node AVR32 Opcodes
9702 +@section Opcodes
9703 +@cindex AVR32 opcodes
9704 +@cindex opcodes for AVR32
9705 +
9706 +@code{@value{AS}} implements all the standard AVR32 opcodes. It also
9707 +implements several pseudo-opcodes, which are recommended to use wherever
9708 +possible because they give the tool chain better freedom to generate
9709 +optimal code.
9710 +
9711 +@table @code
9712 +
9713 +@cindex @code{LDA.W reg, symbol} pseudo op, AVR32
9714 +@item LDA.W
9715 +@smallexample
9716 + lda.w @var{reg}, @var{symbol}
9717 +@end smallexample
9718 +
9719 +This instruction will load the address of @var{symbol} into
9720 +@var{reg}. The instruction will evaluate to one of the following,
9721 +depending on the relative distance to the symbol, the relative distance
9722 +to the constant pool and whether the @code{--pic} option has been
9723 +specified. If the @code{--pic} option has not been specified, the
9724 +alternatives are as follows:
9725 +@smallexample
9726 + /* @var{symbol} evaluates to a small enough value */
9727 + mov @var{reg}, @var{symbol}
9728 +
9729 + /* (. - @var{symbol}) evaluates to a small enough value */
9730 + sub @var{reg}, pc, . - @var{symbol}
9731 +
9732 + /* Constant pool is close enough */
9733 + lddpc @var{reg}, @var{cpent}
9734 + ...
9735 +@var{cpent}:
9736 + .long @var{symbol}
9737 +
9738 + /* Otherwise (not implemented yet, probably not necessary) */
9739 + mov @var{reg}, lo(@var{symbol})
9740 + orh @var{reg}, hi(@var{symbol})
9741 +@end smallexample
9742 +
9743 +If the @code{--pic} option has been specified, the alternatives are as
9744 +follows:
9745 +@smallexample
9746 + /* (. - @var{symbol}) evaluates to a small enough value */
9747 + sub @var{reg}, pc, . - @var{symbol}
9748 +
9749 + /* If @code{--linkrelax} not specified */
9750 + ld.w @var{reg}, r6[@var{symbol}@@got]
9751 +
9752 + /* Otherwise */
9753 + mov @var{reg}, @var{symbol}@@got / 4
9754 + ld.w @var{reg}, r6[@var{reg} << 2]
9755 +@end smallexample
9756 +
9757 +If @var{symbol} is not defined in the same file and section as the
9758 +@code{LDA.W} instruction, the most pessimistic alternative of the
9759 +above is selected. The linker may convert it back into the most
9760 +optimal alternative when the final value of all symbols is known.
9761 +
9762 +@cindex @code{CALL symbol} pseudo op, AVR32
9763 +@item CALL
9764 +@smallexample
9765 + call @var{symbol}
9766 +@end smallexample
9767 +
9768 +This instruction will insert code to call the subroutine identified by
9769 +@var{symbol}. It will evaluate to one of the following, depending on
9770 +the relative distance to the symbol as well as the @code{--linkrelax}
9771 +and @code{--pic} command-line options.
9772 +
9773 +If @var{symbol} is defined in the same section and input file, and the
9774 +distance is small enough, an @code{rcall} instruction is inserted:
9775 +@smallexample
9776 + rcall @var{symbol}
9777 +@end smallexample
9778 +
9779 +Otherwise, if the @code{--pic} option has not been specified:
9780 +@smallexample
9781 + mcall @var{cpent}
9782 + ...
9783 +@var{cpent}:
9784 + .long @var{symbol}
9785 +@end smallexample
9786 +
9787 +Finally, if nothing else fits and the @code{--pic} option has been
9788 +specified, the assembler will indirect the call through the Global
9789 +Offset Table:
9790 +@smallexample
9791 + /* If @code{--linkrelax} not specified */
9792 + mcall r6[@var{symbol}@@got]
9793 +
9794 + /* If @code{--linkrelax} specified */
9795 + mov lr, @var{symbol}@@got / 4
9796 + ld.w lr, r6[lr << 2]
9797 + icall lr
9798 +@end smallexample
9799 +
9800 +The linker, after determining the final value of @var{symbol}, may
9801 +convert any of these into more optimal alternatives. This includes
9802 +deleting any superfluous constant pool- and GOT-entries.
9803 +
9804 +@end table
9805 --- a/gas/doc/Makefile.am
9806 +++ b/gas/doc/Makefile.am
9807 @@ -33,6 +33,7 @@ CPU_DOCS = \
9808 c-arc.texi \
9809 c-arm.texi \
9810 c-avr.texi \
9811 + c-avr32.texi \
9812 c-bfin.texi \
9813 c-cr16.texi \
9814 c-d10v.texi \
9815 --- a/gas/Makefile.am
9816 +++ b/gas/Makefile.am
9817 @@ -47,6 +47,7 @@ CPU_TYPES = \
9818 arc \
9819 arm \
9820 avr \
9821 + avr32 \
9822 bfin \
9823 cr16 \
9824 cris \
9825 @@ -241,6 +242,7 @@ TARGET_CPU_CFILES = \
9826 config/tc-arc.c \
9827 config/tc-arm.c \
9828 config/tc-avr.c \
9829 + config/tc-avr32.c \
9830 config/tc-bfin.c \
9831 config/tc-cr16.c \
9832 config/tc-cris.c \
9833 @@ -296,6 +298,7 @@ TARGET_CPU_HFILES = \
9834 config/tc-arc.h \
9835 config/tc-arm.h \
9836 config/tc-avr.h \
9837 + config/tc-avr32.h \
9838 config/tc-bfin.h \
9839 config/tc-cr16.h \
9840 config/tc-cris.h \
9841 @@ -1050,6 +1053,11 @@ DEPTC_avr_elf = $(srcdir)/config/obj-elf
9842 $(INCDIR)/bfdlink.h $(srcdir)/config/tc-avr.h dwarf2dbg.h \
9843 $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
9844 $(INCDIR)/opcode/avr.h
9845 +DEPTC_avr32_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
9846 + $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
9847 + $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-avr32.h \
9848 + $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
9849 + $(srcdir)/../opcodes/avr32-opc.h $(srcdir)/../opcodes/avr32-asm.h
9850 DEPTC_bfin_elf = $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h \
9851 $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
9852 $(INCDIR)/bfdlink.h $(srcdir)/config/tc-bfin.h dwarf2dbg.h \
9853 @@ -1487,6 +1495,11 @@ DEPOBJ_avr_elf = $(srcdir)/config/obj-el
9854 $(INCDIR)/bfdlink.h $(srcdir)/config/tc-avr.h dwarf2dbg.h \
9855 $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
9856 $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
9857 +DEPOBJ_avr32_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
9858 + $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
9859 + $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-avr32.h \
9860 + $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
9861 + struc-symbol.h dwarf2dbg.h
9862 DEPOBJ_bfin_elf = $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h \
9863 $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
9864 $(INCDIR)/bfdlink.h $(srcdir)/config/tc-bfin.h dwarf2dbg.h \
9865 @@ -1858,6 +1871,9 @@ DEP_cr16_elf = $(srcdir)/config/obj-elf.
9866 $(INCDIR)/bfdlink.h $(srcdir)/config/tc-cr16.h dwarf2dbg.h \
9867 $(srcdir)/config/obj-coff.h $(INCDIR)/coff/internal.h \
9868 $(BFDDIR)/libcoff.h
9869 +DEP_avr32_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
9870 + $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
9871 + $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-avr32.h
9872 DEP_cris_aout = $(srcdir)/config/obj-aout.h $(srcdir)/config/tc-cris.h \
9873 $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h
9874 DEP_cris_elf = $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h \
9875 --- /dev/null
9876 +++ b/gas/testsuite/gas/avr32/aliases.d
9877 @@ -0,0 +1,19 @@
9878 +#as:
9879 +#objdump: -dr
9880 +#name: aliases
9881 +
9882 +.*: +file format .*
9883 +
9884 +Disassembly of section \.text:
9885 +
9886 +00000000 <ld_nodisp>:
9887 + 0: 19 80 [ \t]+ld\.ub r0,r12\[0x0\]
9888 + 2: f9 20 00 00[ \t]+ld\.sb r0,r12\[0\]
9889 + 6: 98 80 [ \t]+ld\.uh r0,r12\[0x0\]
9890 + 8: 98 00 [ \t]+ld\.sh r0,r12\[0x0\]
9891 + a: 78 00 [ \t]+ld\.w r0,r12\[0x0\]
9892 +
9893 +0000000c <st_nodisp>:
9894 + c: b8 80 [ \t]+st\.b r12\[0x0\],r0
9895 + e: b8 00 [ \t]+st\.h r12\[0x0\],r0
9896 + 10: 99 00 [ \t]+st\.w r12\[0x0\],r0
9897 --- /dev/null
9898 +++ b/gas/testsuite/gas/avr32/aliases.s
9899 @@ -0,0 +1,14 @@
9900 + .text
9901 + .global ld_nodisp
9902 +ld_nodisp:
9903 + ld.ub r0, r12
9904 + ld.sb r0, r12
9905 + ld.uh r0, r12
9906 + ld.sh r0, r12
9907 + ld.w r0, r12
9908 +
9909 + .global st_nodisp
9910 +st_nodisp:
9911 + st.b r12, r0
9912 + st.h r12, r0
9913 + st.w r12, r0
9914 --- /dev/null
9915 +++ b/gas/testsuite/gas/avr32/allinsn.d
9916 @@ -0,0 +1,2987 @@
9917 +#as:
9918 +#objdump: -dr
9919 +#name: allinsn
9920 +
9921 +.*: +file format .*
9922 +
9923 +Disassembly of section \.text:
9924 +
9925 +[0-9a-f]* <ld_d5>:
9926 + *[0-9a-f]*: fe 0f 02 3e ld\.d lr,pc\[pc<<0x3\]
9927 + *[0-9a-f]*: e0 00 02 00 ld\.d r0,r0\[r0\]
9928 + *[0-9a-f]*: ea 05 02 26 ld\.d r6,r5\[r5<<0x2\]
9929 + *[0-9a-f]*: e8 04 02 14 ld\.d r4,r4\[r4<<0x1\]
9930 + *[0-9a-f]*: fc 0e 02 1e ld\.d lr,lr\[lr<<0x1\]
9931 + *[0-9a-f]*: e6 0d 02 2a ld\.d r10,r3\[sp<<0x2\]
9932 + *[0-9a-f]*: f4 06 02 28 ld\.d r8,r10\[r6<<0x2\]
9933 + *[0-9a-f]*: ee 09 02 02 ld\.d r2,r7\[r9\]
9934 +
9935 +[0-9a-f]* <ld_w5>:
9936 + *[0-9a-f]*: fe 0f 03 0f ld\.w pc,pc\[pc\]
9937 + *[0-9a-f]*: f8 0c 03 3c ld\.w r12,r12\[r12<<0x3\]
9938 + *[0-9a-f]*: ea 05 03 25 ld\.w r5,r5\[r5<<0x2\]
9939 + *[0-9a-f]*: e8 04 03 14 ld\.w r4,r4\[r4<<0x1\]
9940 + *[0-9a-f]*: fc 0e 03 1e ld\.w lr,lr\[lr<<0x1\]
9941 + *[0-9a-f]*: f2 09 03 02 ld\.w r2,r9\[r9\]
9942 + *[0-9a-f]*: e4 06 03 0b ld\.w r11,r2\[r6\]
9943 + *[0-9a-f]*: e4 0d 03 30 ld\.w r0,r2\[sp<<0x3\]
9944 +
9945 +[0-9a-f]* <ld_sh5>:
9946 + *[0-9a-f]*: fe 0f 04 0f ld\.sh pc,pc\[pc\]
9947 + *[0-9a-f]*: f8 0c 04 3c ld\.sh r12,r12\[r12<<0x3\]
9948 + *[0-9a-f]*: ea 05 04 25 ld\.sh r5,r5\[r5<<0x2\]
9949 + *[0-9a-f]*: e8 04 04 14 ld\.sh r4,r4\[r4<<0x1\]
9950 + *[0-9a-f]*: fc 0e 04 1e ld\.sh lr,lr\[lr<<0x1\]
9951 + *[0-9a-f]*: e0 0f 04 2b ld\.sh r11,r0\[pc<<0x2\]
9952 + *[0-9a-f]*: fa 06 04 2a ld\.sh r10,sp\[r6<<0x2\]
9953 + *[0-9a-f]*: e4 02 04 0c ld\.sh r12,r2\[r2\]
9954 +
9955 +[0-9a-f]* <ld_uh5>:
9956 + *[0-9a-f]*: fe 0f 05 0f ld\.uh pc,pc\[pc\]
9957 + *[0-9a-f]*: f8 0c 05 3c ld\.uh r12,r12\[r12<<0x3\]
9958 + *[0-9a-f]*: ea 05 05 25 ld\.uh r5,r5\[r5<<0x2\]
9959 + *[0-9a-f]*: e8 04 05 14 ld\.uh r4,r4\[r4<<0x1\]
9960 + *[0-9a-f]*: fc 0e 05 1e ld\.uh lr,lr\[lr<<0x1\]
9961 + *[0-9a-f]*: fe 0e 05 38 ld\.uh r8,pc\[lr<<0x3\]
9962 + *[0-9a-f]*: e2 0f 05 16 ld\.uh r6,r1\[pc<<0x1\]
9963 + *[0-9a-f]*: fc 0d 05 16 ld\.uh r6,lr\[sp<<0x1\]
9964 +
9965 +[0-9a-f]* <ld_sb2>:
9966 + *[0-9a-f]*: fe 0f 06 0f ld\.sb pc,pc\[pc\]
9967 + *[0-9a-f]*: f8 0c 06 3c ld\.sb r12,r12\[r12<<0x3\]
9968 + *[0-9a-f]*: ea 05 06 25 ld\.sb r5,r5\[r5<<0x2\]
9969 + *[0-9a-f]*: e8 04 06 14 ld\.sb r4,r4\[r4<<0x1\]
9970 + *[0-9a-f]*: fc 0e 06 1e ld\.sb lr,lr\[lr<<0x1\]
9971 + *[0-9a-f]*: e2 0f 06 39 ld\.sb r9,r1\[pc<<0x3\]
9972 + *[0-9a-f]*: e6 0b 06 10 ld\.sb r0,r3\[r11<<0x1\]
9973 + *[0-9a-f]*: ea 05 06 1a ld\.sb r10,r5\[r5<<0x1\]
9974 +
9975 +[0-9a-f]* <ld_ub5>:
9976 + *[0-9a-f]*: fe 0f 07 0f ld\.ub pc,pc\[pc\]
9977 + *[0-9a-f]*: f8 0c 07 3c ld\.ub r12,r12\[r12<<0x3\]
9978 + *[0-9a-f]*: ea 05 07 25 ld\.ub r5,r5\[r5<<0x2\]
9979 + *[0-9a-f]*: e8 04 07 14 ld\.ub r4,r4\[r4<<0x1\]
9980 + *[0-9a-f]*: fc 0e 07 1e ld\.ub lr,lr\[lr<<0x1\]
9981 + *[0-9a-f]*: f8 07 07 36 ld\.ub r6,r12\[r7<<0x3\]
9982 + *[0-9a-f]*: ec 0c 07 02 ld\.ub r2,r6\[r12\]
9983 + *[0-9a-f]*: ee 0b 07 10 ld\.ub r0,r7\[r11<<0x1\]
9984 +
9985 +[0-9a-f]* <st_d5>:
9986 + *[0-9a-f]*: fe 0f 08 0e st\.d pc\[pc\],lr
9987 + *[0-9a-f]*: f8 0c 08 3c st\.d r12\[r12<<0x3\],r12
9988 + *[0-9a-f]*: ea 05 08 26 st\.d r5\[r5<<0x2\],r6
9989 + *[0-9a-f]*: e8 04 08 14 st\.d r4\[r4<<0x1\],r4
9990 + *[0-9a-f]*: fc 0e 08 1e st\.d lr\[lr<<0x1\],lr
9991 + *[0-9a-f]*: e2 09 08 14 st\.d r1\[r9<<0x1\],r4
9992 + *[0-9a-f]*: f4 02 08 14 st\.d r10\[r2<<0x1\],r4
9993 + *[0-9a-f]*: f8 06 08 0e st\.d r12\[r6\],lr
9994 +
9995 +[0-9a-f]* <st_w5>:
9996 + *[0-9a-f]*: fe 0f 09 0f st\.w pc\[pc\],pc
9997 + *[0-9a-f]*: f8 0c 09 3c st\.w r12\[r12<<0x3\],r12
9998 + *[0-9a-f]*: ea 05 09 25 st\.w r5\[r5<<0x2\],r5
9999 + *[0-9a-f]*: e8 04 09 14 st\.w r4\[r4<<0x1\],r4
10000 + *[0-9a-f]*: fc 0e 09 1e st\.w lr\[lr<<0x1\],lr
10001 + *[0-9a-f]*: e2 0a 09 03 st\.w r1\[r10\],r3
10002 + *[0-9a-f]*: e0 0a 09 19 st\.w r0\[r10<<0x1\],r9
10003 + *[0-9a-f]*: e8 05 09 3f st\.w r4\[r5<<0x3\],pc
10004 +
10005 +[0-9a-f]* <st_h5>:
10006 + *[0-9a-f]*: fe 0f 0a 0f st\.h pc\[pc\],pc
10007 + *[0-9a-f]*: f8 0c 0a 3c st\.h r12\[r12<<0x3\],r12
10008 + *[0-9a-f]*: ea 05 0a 25 st\.h r5\[r5<<0x2\],r5
10009 + *[0-9a-f]*: e8 04 0a 14 st\.h r4\[r4<<0x1\],r4
10010 + *[0-9a-f]*: fc 0e 0a 1e st\.h lr\[lr<<0x1\],lr
10011 + *[0-9a-f]*: e4 09 0a 0b st\.h r2\[r9\],r11
10012 + *[0-9a-f]*: ea 01 0a 2c st\.h r5\[r1<<0x2\],r12
10013 + *[0-9a-f]*: fe 08 0a 23 st\.h pc\[r8<<0x2\],r3
10014 +
10015 +[0-9a-f]* <st_b5>:
10016 + *[0-9a-f]*: fe 0f 0b 0f st\.b pc\[pc\],pc
10017 + *[0-9a-f]*: f8 0c 0b 3c st\.b r12\[r12<<0x3\],r12
10018 + *[0-9a-f]*: ea 05 0b 25 st\.b r5\[r5<<0x2\],r5
10019 + *[0-9a-f]*: e8 04 0b 14 st\.b r4\[r4<<0x1\],r4
10020 + *[0-9a-f]*: fc 0e 0b 1e st\.b lr\[lr<<0x1\],lr
10021 + *[0-9a-f]*: e2 08 0b 16 st\.b r1\[r8<<0x1\],r6
10022 + *[0-9a-f]*: fc 0e 0b 31 st\.b lr\[lr<<0x3\],r1
10023 + *[0-9a-f]*: ea 00 0b 2f st\.b r5\[r0<<0x2\],pc
10024 +
10025 +[0-9a-f]* <divs>:
10026 + *[0-9a-f]*: fe 0f 0c 0f divs pc,pc,pc
10027 + *[0-9a-f]*: f8 0c 0c 0c divs r12,r12,r12
10028 + *[0-9a-f]*: ea 05 0c 05 divs r5,r5,r5
10029 + *[0-9a-f]*: e8 04 0c 04 divs r4,r4,r4
10030 + *[0-9a-f]*: fc 0e 0c 0e divs lr,lr,lr
10031 + *[0-9a-f]*: fe 0f 0c 03 divs r3,pc,pc
10032 + *[0-9a-f]*: f8 02 0c 09 divs r9,r12,r2
10033 + *[0-9a-f]*: e8 01 0c 07 divs r7,r4,r1
10034 +
10035 +[0-9a-f]* <add1>:
10036 + *[0-9a-f]*: 1e 0f add pc,pc
10037 + *[0-9a-f]*: 18 0c add r12,r12
10038 + *[0-9a-f]*: 0a 05 add r5,r5
10039 + *[0-9a-f]*: 08 04 add r4,r4
10040 + *[0-9a-f]*: 1c 0e add lr,lr
10041 + *[0-9a-f]*: 12 0c add r12,r9
10042 + *[0-9a-f]*: 06 06 add r6,r3
10043 + *[0-9a-f]*: 18 0a add r10,r12
10044 +
10045 +[0-9a-f]* <sub1>:
10046 + *[0-9a-f]*: 1e 1f sub pc,pc
10047 + *[0-9a-f]*: 18 1c sub r12,r12
10048 + *[0-9a-f]*: 0a 15 sub r5,r5
10049 + *[0-9a-f]*: 08 14 sub r4,r4
10050 + *[0-9a-f]*: 1c 1e sub lr,lr
10051 + *[0-9a-f]*: 0c 1e sub lr,r6
10052 + *[0-9a-f]*: 1a 10 sub r0,sp
10053 + *[0-9a-f]*: 18 16 sub r6,r12
10054 +
10055 +[0-9a-f]* <rsub1>:
10056 + *[0-9a-f]*: 1e 2f rsub pc,pc
10057 + *[0-9a-f]*: 18 2c rsub r12,r12
10058 + *[0-9a-f]*: 0a 25 rsub r5,r5
10059 + *[0-9a-f]*: 08 24 rsub r4,r4
10060 + *[0-9a-f]*: 1c 2e rsub lr,lr
10061 + *[0-9a-f]*: 1a 2b rsub r11,sp
10062 + *[0-9a-f]*: 08 27 rsub r7,r4
10063 + *[0-9a-f]*: 02 29 rsub r9,r1
10064 +
10065 +[0-9a-f]* <cp1>:
10066 + *[0-9a-f]*: 1e 3f cp\.w pc,pc
10067 + *[0-9a-f]*: 18 3c cp\.w r12,r12
10068 + *[0-9a-f]*: 0a 35 cp\.w r5,r5
10069 + *[0-9a-f]*: 08 34 cp\.w r4,r4
10070 + *[0-9a-f]*: 1c 3e cp\.w lr,lr
10071 + *[0-9a-f]*: 04 36 cp\.w r6,r2
10072 + *[0-9a-f]*: 12 30 cp\.w r0,r9
10073 + *[0-9a-f]*: 1a 33 cp\.w r3,sp
10074 +
10075 +[0-9a-f]* <or1>:
10076 + *[0-9a-f]*: 1e 4f or pc,pc
10077 + *[0-9a-f]*: 18 4c or r12,r12
10078 + *[0-9a-f]*: 0a 45 or r5,r5
10079 + *[0-9a-f]*: 08 44 or r4,r4
10080 + *[0-9a-f]*: 1c 4e or lr,lr
10081 + *[0-9a-f]*: 12 44 or r4,r9
10082 + *[0-9a-f]*: 08 4b or r11,r4
10083 + *[0-9a-f]*: 00 44 or r4,r0
10084 +
10085 +[0-9a-f]* <eor1>:
10086 + *[0-9a-f]*: 1e 5f eor pc,pc
10087 + *[0-9a-f]*: 18 5c eor r12,r12
10088 + *[0-9a-f]*: 0a 55 eor r5,r5
10089 + *[0-9a-f]*: 08 54 eor r4,r4
10090 + *[0-9a-f]*: 1c 5e eor lr,lr
10091 + *[0-9a-f]*: 16 5c eor r12,r11
10092 + *[0-9a-f]*: 02 50 eor r0,r1
10093 + *[0-9a-f]*: 1e 55 eor r5,pc
10094 +
10095 +[0-9a-f]* <and1>:
10096 + *[0-9a-f]*: 1e 6f and pc,pc
10097 + *[0-9a-f]*: 18 6c and r12,r12
10098 + *[0-9a-f]*: 0a 65 and r5,r5
10099 + *[0-9a-f]*: 08 64 and r4,r4
10100 + *[0-9a-f]*: 1c 6e and lr,lr
10101 + *[0-9a-f]*: 02 68 and r8,r1
10102 + *[0-9a-f]*: 1a 60 and r0,sp
10103 + *[0-9a-f]*: 0a 6a and r10,r5
10104 +
10105 +[0-9a-f]* <tst>:
10106 + *[0-9a-f]*: 1e 7f tst pc,pc
10107 + *[0-9a-f]*: 18 7c tst r12,r12
10108 + *[0-9a-f]*: 0a 75 tst r5,r5
10109 + *[0-9a-f]*: 08 74 tst r4,r4
10110 + *[0-9a-f]*: 1c 7e tst lr,lr
10111 + *[0-9a-f]*: 18 70 tst r0,r12
10112 + *[0-9a-f]*: 0c 7a tst r10,r6
10113 + *[0-9a-f]*: 08 7d tst sp,r4
10114 +
10115 +[0-9a-f]* <andn>:
10116 + *[0-9a-f]*: 1e 8f andn pc,pc
10117 + *[0-9a-f]*: 18 8c andn r12,r12
10118 + *[0-9a-f]*: 0a 85 andn r5,r5
10119 + *[0-9a-f]*: 08 84 andn r4,r4
10120 + *[0-9a-f]*: 1c 8e andn lr,lr
10121 + *[0-9a-f]*: 18 89 andn r9,r12
10122 + *[0-9a-f]*: 1a 8b andn r11,sp
10123 + *[0-9a-f]*: 0a 8c andn r12,r5
10124 +
10125 +[0-9a-f]* <mov3>:
10126 + *[0-9a-f]*: 1e 9f mov pc,pc
10127 + *[0-9a-f]*: 18 9c mov r12,r12
10128 + *[0-9a-f]*: 0a 95 mov r5,r5
10129 + *[0-9a-f]*: 08 94 mov r4,r4
10130 + *[0-9a-f]*: 1c 9e mov lr,lr
10131 + *[0-9a-f]*: 12 95 mov r5,r9
10132 + *[0-9a-f]*: 16 9b mov r11,r11
10133 + *[0-9a-f]*: 1c 92 mov r2,lr
10134 +
10135 +[0-9a-f]* <st_w1>:
10136 + *[0-9a-f]*: 1e af st\.w pc\+\+,pc
10137 + *[0-9a-f]*: 18 ac st\.w r12\+\+,r12
10138 + *[0-9a-f]*: 0a a5 st\.w r5\+\+,r5
10139 + *[0-9a-f]*: 08 a4 st\.w r4\+\+,r4
10140 + *[0-9a-f]*: 1c ae st\.w lr\+\+,lr
10141 + *[0-9a-f]*: 02 ab st\.w r1\+\+,r11
10142 + *[0-9a-f]*: 1a a0 st\.w sp\+\+,r0
10143 + *[0-9a-f]*: 1a a1 st\.w sp\+\+,r1
10144 +
10145 +[0-9a-f]* <st_h1>:
10146 + *[0-9a-f]*: 1e bf st\.h pc\+\+,pc
10147 + *[0-9a-f]*: 18 bc st\.h r12\+\+,r12
10148 + *[0-9a-f]*: 0a b5 st\.h r5\+\+,r5
10149 + *[0-9a-f]*: 08 b4 st\.h r4\+\+,r4
10150 + *[0-9a-f]*: 1c be st\.h lr\+\+,lr
10151 + *[0-9a-f]*: 18 bd st\.h r12\+\+,sp
10152 + *[0-9a-f]*: 0e be st\.h r7\+\+,lr
10153 + *[0-9a-f]*: 0e b4 st\.h r7\+\+,r4
10154 +
10155 +[0-9a-f]* <st_b1>:
10156 + *[0-9a-f]*: 1e cf st\.b pc\+\+,pc
10157 + *[0-9a-f]*: 18 cc st\.b r12\+\+,r12
10158 + *[0-9a-f]*: 0a c5 st\.b r5\+\+,r5
10159 + *[0-9a-f]*: 08 c4 st\.b r4\+\+,r4
10160 + *[0-9a-f]*: 1c ce st\.b lr\+\+,lr
10161 + *[0-9a-f]*: 12 cd st\.b r9\+\+,sp
10162 + *[0-9a-f]*: 02 cd st\.b r1\+\+,sp
10163 + *[0-9a-f]*: 00 c4 st\.b r0\+\+,r4
10164 +
10165 +[0-9a-f]* <st_w2>:
10166 + *[0-9a-f]*: 1e df st\.w --pc,pc
10167 + *[0-9a-f]*: 18 dc st\.w --r12,r12
10168 + *[0-9a-f]*: 0a d5 st\.w --r5,r5
10169 + *[0-9a-f]*: 08 d4 st\.w --r4,r4
10170 + *[0-9a-f]*: 1c de st\.w --lr,lr
10171 + *[0-9a-f]*: 02 d7 st\.w --r1,r7
10172 + *[0-9a-f]*: 06 d9 st\.w --r3,r9
10173 + *[0-9a-f]*: 0a d5 st\.w --r5,r5
10174 +
10175 +[0-9a-f]* <st_h2>:
10176 + *[0-9a-f]*: 1e ef st\.h --pc,pc
10177 + *[0-9a-f]*: 18 ec st\.h --r12,r12
10178 + *[0-9a-f]*: 0a e5 st\.h --r5,r5
10179 + *[0-9a-f]*: 08 e4 st\.h --r4,r4
10180 + *[0-9a-f]*: 1c ee st\.h --lr,lr
10181 + *[0-9a-f]*: 0a e7 st\.h --r5,r7
10182 + *[0-9a-f]*: 10 e8 st\.h --r8,r8
10183 + *[0-9a-f]*: 0e e2 st\.h --r7,r2
10184 +
10185 +[0-9a-f]* <st_b2>:
10186 + *[0-9a-f]*: 1e ff st\.b --pc,pc
10187 + *[0-9a-f]*: 18 fc st\.b --r12,r12
10188 + *[0-9a-f]*: 0a f5 st\.b --r5,r5
10189 + *[0-9a-f]*: 08 f4 st\.b --r4,r4
10190 + *[0-9a-f]*: 1c fe st\.b --lr,lr
10191 + *[0-9a-f]*: 1a fd st\.b --sp,sp
10192 + *[0-9a-f]*: 1a fb st\.b --sp,r11
10193 + *[0-9a-f]*: 08 f5 st\.b --r4,r5
10194 +
10195 +[0-9a-f]* <ld_w1>:
10196 + *[0-9a-f]*: 1f 0f ld\.w pc,pc\+\+
10197 + *[0-9a-f]*: 19 0c ld\.w r12,r12\+\+
10198 + *[0-9a-f]*: 0b 05 ld\.w r5,r5\+\+
10199 + *[0-9a-f]*: 09 04 ld\.w r4,r4\+\+
10200 + *[0-9a-f]*: 1d 0e ld\.w lr,lr\+\+
10201 + *[0-9a-f]*: 0f 03 ld\.w r3,r7\+\+
10202 + *[0-9a-f]*: 1d 03 ld\.w r3,lr\+\+
10203 + *[0-9a-f]*: 0b 0c ld\.w r12,r5\+\+
10204 +
10205 +[0-9a-f]* <ld_sh1>:
10206 + *[0-9a-f]*: 1f 1f ld\.sh pc,pc\+\+
10207 + *[0-9a-f]*: 19 1c ld\.sh r12,r12\+\+
10208 + *[0-9a-f]*: 0b 15 ld\.sh r5,r5\+\+
10209 + *[0-9a-f]*: 09 14 ld\.sh r4,r4\+\+
10210 + *[0-9a-f]*: 1d 1e ld\.sh lr,lr\+\+
10211 + *[0-9a-f]*: 05 1b ld\.sh r11,r2\+\+
10212 + *[0-9a-f]*: 11 12 ld\.sh r2,r8\+\+
10213 + *[0-9a-f]*: 0d 17 ld\.sh r7,r6\+\+
10214 +
10215 +[0-9a-f]* <ld_uh1>:
10216 + *[0-9a-f]*: 1f 2f ld\.uh pc,pc\+\+
10217 + *[0-9a-f]*: 19 2c ld\.uh r12,r12\+\+
10218 + *[0-9a-f]*: 0b 25 ld\.uh r5,r5\+\+
10219 + *[0-9a-f]*: 09 24 ld\.uh r4,r4\+\+
10220 + *[0-9a-f]*: 1d 2e ld\.uh lr,lr\+\+
10221 + *[0-9a-f]*: 0f 26 ld\.uh r6,r7\+\+
10222 + *[0-9a-f]*: 17 2a ld\.uh r10,r11\+\+
10223 + *[0-9a-f]*: 09 2e ld\.uh lr,r4\+\+
10224 +
10225 +[0-9a-f]* <ld_ub1>:
10226 + *[0-9a-f]*: 1f 3f ld\.ub pc,pc\+\+
10227 + *[0-9a-f]*: 19 3c ld\.ub r12,r12\+\+
10228 + *[0-9a-f]*: 0b 35 ld\.ub r5,r5\+\+
10229 + *[0-9a-f]*: 09 34 ld\.ub r4,r4\+\+
10230 + *[0-9a-f]*: 1d 3e ld\.ub lr,lr\+\+
10231 + *[0-9a-f]*: 1d 38 ld\.ub r8,lr\+\+
10232 + *[0-9a-f]*: 19 3c ld\.ub r12,r12\+\+
10233 + *[0-9a-f]*: 15 3b ld\.ub r11,r10\+\+
10234 +
10235 +[0-9a-f]* <ld_w2>:
10236 + *[0-9a-f]*: 1f 4f ld\.w pc,--pc
10237 + *[0-9a-f]*: 19 4c ld\.w r12,--r12
10238 + *[0-9a-f]*: 0b 45 ld\.w r5,--r5
10239 + *[0-9a-f]*: 09 44 ld\.w r4,--r4
10240 + *[0-9a-f]*: 1d 4e ld\.w lr,--lr
10241 + *[0-9a-f]*: 1d 4a ld\.w r10,--lr
10242 + *[0-9a-f]*: 13 4c ld\.w r12,--r9
10243 + *[0-9a-f]*: 0b 46 ld\.w r6,--r5
10244 +
10245 +[0-9a-f]* <ld_sh2>:
10246 + *[0-9a-f]*: 1f 5f ld\.sh pc,--pc
10247 + *[0-9a-f]*: 19 5c ld\.sh r12,--r12
10248 + *[0-9a-f]*: 0b 55 ld\.sh r5,--r5
10249 + *[0-9a-f]*: 09 54 ld\.sh r4,--r4
10250 + *[0-9a-f]*: 1d 5e ld\.sh lr,--lr
10251 + *[0-9a-f]*: 15 5f ld\.sh pc,--r10
10252 + *[0-9a-f]*: 07 56 ld\.sh r6,--r3
10253 + *[0-9a-f]*: 0d 54 ld\.sh r4,--r6
10254 +
10255 +[0-9a-f]* <ld_uh2>:
10256 + *[0-9a-f]*: 1f 6f ld\.uh pc,--pc
10257 + *[0-9a-f]*: 19 6c ld\.uh r12,--r12
10258 + *[0-9a-f]*: 0b 65 ld\.uh r5,--r5
10259 + *[0-9a-f]*: 09 64 ld\.uh r4,--r4
10260 + *[0-9a-f]*: 1d 6e ld\.uh lr,--lr
10261 + *[0-9a-f]*: 05 63 ld\.uh r3,--r2
10262 + *[0-9a-f]*: 01 61 ld\.uh r1,--r0
10263 + *[0-9a-f]*: 13 62 ld\.uh r2,--r9
10264 +
10265 +[0-9a-f]* <ld_ub2>:
10266 + *[0-9a-f]*: 1f 7f ld\.ub pc,--pc
10267 + *[0-9a-f]*: 19 7c ld\.ub r12,--r12
10268 + *[0-9a-f]*: 0b 75 ld\.ub r5,--r5
10269 + *[0-9a-f]*: 09 74 ld\.ub r4,--r4
10270 + *[0-9a-f]*: 1d 7e ld\.ub lr,--lr
10271 + *[0-9a-f]*: 03 71 ld\.ub r1,--r1
10272 + *[0-9a-f]*: 0d 70 ld\.ub r0,--r6
10273 + *[0-9a-f]*: 0f 72 ld\.ub r2,--r7
10274 +
10275 +[0-9a-f]* <ld_ub3>:
10276 + *[0-9a-f]*: 1f 8f ld\.ub pc,pc\[0x0\]
10277 + *[0-9a-f]*: 19 fc ld\.ub r12,r12\[0x7\]
10278 + *[0-9a-f]*: 0b c5 ld\.ub r5,r5\[0x4\]
10279 + *[0-9a-f]*: 09 b4 ld\.ub r4,r4\[0x3\]
10280 + *[0-9a-f]*: 1d 9e ld\.ub lr,lr\[0x1\]
10281 + *[0-9a-f]*: 13 e6 ld\.ub r6,r9\[0x6\]
10282 + *[0-9a-f]*: 1d c2 ld\.ub r2,lr\[0x4\]
10283 + *[0-9a-f]*: 11 81 ld\.ub r1,r8\[0x0\]
10284 +
10285 +[0-9a-f]* <sub3_sp>:
10286 + *[0-9a-f]*: 20 0d sub sp,0
10287 + *[0-9a-f]*: 2f fd sub sp,-4
10288 + *[0-9a-f]*: 28 0d sub sp,-512
10289 + *[0-9a-f]*: 27 fd sub sp,508
10290 + *[0-9a-f]*: 20 1d sub sp,4
10291 + *[0-9a-f]*: 20 bd sub sp,44
10292 + *[0-9a-f]*: 20 2d sub sp,8
10293 + *[0-9a-f]*: 25 7d sub sp,348
10294 +
10295 +[0-9a-f]* <sub3>:
10296 + *[0-9a-f]*: 20 0f sub pc,0
10297 + *[0-9a-f]*: 2f fc sub r12,-1
10298 + *[0-9a-f]*: 28 05 sub r5,-128
10299 + *[0-9a-f]*: 27 f4 sub r4,127
10300 + *[0-9a-f]*: 20 1e sub lr,1
10301 + *[0-9a-f]*: 2d 76 sub r6,-41
10302 + *[0-9a-f]*: 22 54 sub r4,37
10303 + *[0-9a-f]*: 23 8c sub r12,56
10304 +
10305 +[0-9a-f]* <mov1>:
10306 + *[0-9a-f]*: 30 0f mov pc,0
10307 + *[0-9a-f]*: 3f fc mov r12,-1
10308 + *[0-9a-f]*: 38 05 mov r5,-128
10309 + *[0-9a-f]*: 37 f4 mov r4,127
10310 + *[0-9a-f]*: 30 1e mov lr,1
10311 + *[0-9a-f]*: 30 ef mov pc,14
10312 + *[0-9a-f]*: 39 c6 mov r6,-100
10313 + *[0-9a-f]*: 38 6e mov lr,-122
10314 +
10315 +[0-9a-f]* <lddsp>:
10316 + *[0-9a-f]*: 40 0f lddsp pc,sp\[0x0\]
10317 + *[0-9a-f]*: 47 fc lddsp r12,sp\[0x1fc\]
10318 + *[0-9a-f]*: 44 05 lddsp r5,sp\[0x100\]
10319 + *[0-9a-f]*: 43 f4 lddsp r4,sp\[0xfc\]
10320 + *[0-9a-f]*: 40 1e lddsp lr,sp\[0x4\]
10321 + *[0-9a-f]*: 44 0e lddsp lr,sp\[0x100\]
10322 + *[0-9a-f]*: 40 5c lddsp r12,sp\[0x14\]
10323 + *[0-9a-f]*: 47 69 lddsp r9,sp\[0x1d8\]
10324 +
10325 +[0-9a-f]* <lddpc>:
10326 + *[0-9a-f]*: 48 0f lddpc pc,[0-9a-f]* <.*>
10327 + *[0-9a-f]*: 4f f0 lddpc r0,[0-9a-f]* <.*>
10328 + *[0-9a-f]*: 4c 08 lddpc r8,[0-9a-f]* <.*>
10329 + *[0-9a-f]*: 4b f7 lddpc r7,[0-9a-f]* <.*>
10330 + *[0-9a-f]*: 48 1e lddpc lr,[0-9a-f]* <.*>
10331 + *[0-9a-f]*: 4f 6d lddpc sp,[0-9a-f]* <.*>
10332 + *[0-9a-f]*: 49 e6 lddpc r6,[0-9a-f]* <.*>
10333 + *[0-9a-f]*: 48 7b lddpc r11,[0-9a-f]* <.*>
10334 +
10335 +[0-9a-f]* <stdsp>:
10336 + *[0-9a-f]*: 50 0f stdsp sp\[0x0\],pc
10337 + *[0-9a-f]*: 57 fc stdsp sp\[0x1fc\],r12
10338 + *[0-9a-f]*: 54 05 stdsp sp\[0x100\],r5
10339 + *[0-9a-f]*: 53 f4 stdsp sp\[0xfc\],r4
10340 + *[0-9a-f]*: 50 1e stdsp sp\[0x4\],lr
10341 + *[0-9a-f]*: 54 cf stdsp sp\[0x130\],pc
10342 + *[0-9a-f]*: 54 00 stdsp sp\[0x100\],r0
10343 + *[0-9a-f]*: 55 45 stdsp sp\[0x150\],r5
10344 +
10345 +[0-9a-f]* <cp2>:
10346 + *[0-9a-f]*: 58 0f cp.w pc,0
10347 + *[0-9a-f]*: 5b fc cp.w r12,-1
10348 + *[0-9a-f]*: 5a 05 cp.w r5,-32
10349 + *[0-9a-f]*: 59 f4 cp.w r4,31
10350 + *[0-9a-f]*: 58 1e cp.w lr,1
10351 + *[0-9a-f]*: 58 38 cp.w r8,3
10352 + *[0-9a-f]*: 59 0e cp.w lr,16
10353 + *[0-9a-f]*: 5a 67 cp.w r7,-26
10354 +
10355 +[0-9a-f]* <acr>:
10356 + *[0-9a-f]*: 5c 0f acr pc
10357 + *[0-9a-f]*: 5c 0c acr r12
10358 + *[0-9a-f]*: 5c 05 acr r5
10359 + *[0-9a-f]*: 5c 04 acr r4
10360 + *[0-9a-f]*: 5c 0e acr lr
10361 + *[0-9a-f]*: 5c 02 acr r2
10362 + *[0-9a-f]*: 5c 0c acr r12
10363 + *[0-9a-f]*: 5c 0f acr pc
10364 +
10365 +[0-9a-f]* <scr>:
10366 + *[0-9a-f]*: 5c 1f scr pc
10367 + *[0-9a-f]*: 5c 1c scr r12
10368 + *[0-9a-f]*: 5c 15 scr r5
10369 + *[0-9a-f]*: 5c 14 scr r4
10370 + *[0-9a-f]*: 5c 1e scr lr
10371 + *[0-9a-f]*: 5c 1f scr pc
10372 + *[0-9a-f]*: 5c 16 scr r6
10373 + *[0-9a-f]*: 5c 11 scr r1
10374 +
10375 +[0-9a-f]* <cpc0>:
10376 + *[0-9a-f]*: 5c 2f cpc pc
10377 + *[0-9a-f]*: 5c 2c cpc r12
10378 + *[0-9a-f]*: 5c 25 cpc r5
10379 + *[0-9a-f]*: 5c 24 cpc r4
10380 + *[0-9a-f]*: 5c 2e cpc lr
10381 + *[0-9a-f]*: 5c 2f cpc pc
10382 + *[0-9a-f]*: 5c 24 cpc r4
10383 + *[0-9a-f]*: 5c 29 cpc r9
10384 +
10385 +[0-9a-f]* <neg>:
10386 + *[0-9a-f]*: 5c 3f neg pc
10387 + *[0-9a-f]*: 5c 3c neg r12
10388 + *[0-9a-f]*: 5c 35 neg r5
10389 + *[0-9a-f]*: 5c 34 neg r4
10390 + *[0-9a-f]*: 5c 3e neg lr
10391 + *[0-9a-f]*: 5c 37 neg r7
10392 + *[0-9a-f]*: 5c 31 neg r1
10393 + *[0-9a-f]*: 5c 39 neg r9
10394 +
10395 +[0-9a-f]* <abs>:
10396 + *[0-9a-f]*: 5c 4f abs pc
10397 + *[0-9a-f]*: 5c 4c abs r12
10398 + *[0-9a-f]*: 5c 45 abs r5
10399 + *[0-9a-f]*: 5c 44 abs r4
10400 + *[0-9a-f]*: 5c 4e abs lr
10401 + *[0-9a-f]*: 5c 46 abs r6
10402 + *[0-9a-f]*: 5c 46 abs r6
10403 + *[0-9a-f]*: 5c 44 abs r4
10404 +
10405 +[0-9a-f]* <castu_b>:
10406 + *[0-9a-f]*: 5c 5f castu\.b pc
10407 + *[0-9a-f]*: 5c 5c castu\.b r12
10408 + *[0-9a-f]*: 5c 55 castu\.b r5
10409 + *[0-9a-f]*: 5c 54 castu\.b r4
10410 + *[0-9a-f]*: 5c 5e castu\.b lr
10411 + *[0-9a-f]*: 5c 57 castu\.b r7
10412 + *[0-9a-f]*: 5c 5d castu\.b sp
10413 + *[0-9a-f]*: 5c 59 castu\.b r9
10414 +
10415 +[0-9a-f]* <casts_b>:
10416 + *[0-9a-f]*: 5c 6f casts\.b pc
10417 + *[0-9a-f]*: 5c 6c casts\.b r12
10418 + *[0-9a-f]*: 5c 65 casts\.b r5
10419 + *[0-9a-f]*: 5c 64 casts\.b r4
10420 + *[0-9a-f]*: 5c 6e casts\.b lr
10421 + *[0-9a-f]*: 5c 6b casts\.b r11
10422 + *[0-9a-f]*: 5c 61 casts\.b r1
10423 + *[0-9a-f]*: 5c 6a casts\.b r10
10424 +
10425 +[0-9a-f]* <castu_h>:
10426 + *[0-9a-f]*: 5c 7f castu\.h pc
10427 + *[0-9a-f]*: 5c 7c castu\.h r12
10428 + *[0-9a-f]*: 5c 75 castu\.h r5
10429 + *[0-9a-f]*: 5c 74 castu\.h r4
10430 + *[0-9a-f]*: 5c 7e castu\.h lr
10431 + *[0-9a-f]*: 5c 7a castu\.h r10
10432 + *[0-9a-f]*: 5c 7b castu\.h r11
10433 + *[0-9a-f]*: 5c 71 castu\.h r1
10434 +
10435 +[0-9a-f]* <casts_h>:
10436 + *[0-9a-f]*: 5c 8f casts\.h pc
10437 + *[0-9a-f]*: 5c 8c casts\.h r12
10438 + *[0-9a-f]*: 5c 85 casts\.h r5
10439 + *[0-9a-f]*: 5c 84 casts\.h r4
10440 + *[0-9a-f]*: 5c 8e casts\.h lr
10441 + *[0-9a-f]*: 5c 80 casts\.h r0
10442 + *[0-9a-f]*: 5c 85 casts\.h r5
10443 + *[0-9a-f]*: 5c 89 casts\.h r9
10444 +
10445 +[0-9a-f]* <brev>:
10446 + *[0-9a-f]*: 5c 9f brev pc
10447 + *[0-9a-f]*: 5c 9c brev r12
10448 + *[0-9a-f]*: 5c 95 brev r5
10449 + *[0-9a-f]*: 5c 94 brev r4
10450 + *[0-9a-f]*: 5c 9e brev lr
10451 + *[0-9a-f]*: 5c 95 brev r5
10452 + *[0-9a-f]*: 5c 9a brev r10
10453 + *[0-9a-f]*: 5c 98 brev r8
10454 +
10455 +[0-9a-f]* <swap_h>:
10456 + *[0-9a-f]*: 5c af swap\.h pc
10457 + *[0-9a-f]*: 5c ac swap\.h r12
10458 + *[0-9a-f]*: 5c a5 swap\.h r5
10459 + *[0-9a-f]*: 5c a4 swap\.h r4
10460 + *[0-9a-f]*: 5c ae swap\.h lr
10461 + *[0-9a-f]*: 5c a7 swap\.h r7
10462 + *[0-9a-f]*: 5c a0 swap\.h r0
10463 + *[0-9a-f]*: 5c a8 swap\.h r8
10464 +
10465 +[0-9a-f]* <swap_b>:
10466 + *[0-9a-f]*: 5c bf swap\.b pc
10467 + *[0-9a-f]*: 5c bc swap\.b r12
10468 + *[0-9a-f]*: 5c b5 swap\.b r5
10469 + *[0-9a-f]*: 5c b4 swap\.b r4
10470 + *[0-9a-f]*: 5c be swap\.b lr
10471 + *[0-9a-f]*: 5c ba swap\.b r10
10472 + *[0-9a-f]*: 5c bc swap\.b r12
10473 + *[0-9a-f]*: 5c b1 swap\.b r1
10474 +
10475 +[0-9a-f]* <swap_bh>:
10476 + *[0-9a-f]*: 5c cf swap\.bh pc
10477 + *[0-9a-f]*: 5c cc swap\.bh r12
10478 + *[0-9a-f]*: 5c c5 swap\.bh r5
10479 + *[0-9a-f]*: 5c c4 swap\.bh r4
10480 + *[0-9a-f]*: 5c ce swap\.bh lr
10481 + *[0-9a-f]*: 5c c9 swap\.bh r9
10482 + *[0-9a-f]*: 5c c4 swap\.bh r4
10483 + *[0-9a-f]*: 5c c1 swap\.bh r1
10484 +
10485 +[0-9a-f]* <One_s_compliment>:
10486 + *[0-9a-f]*: 5c df com pc
10487 + *[0-9a-f]*: 5c dc com r12
10488 + *[0-9a-f]*: 5c d5 com r5
10489 + *[0-9a-f]*: 5c d4 com r4
10490 + *[0-9a-f]*: 5c de com lr
10491 + *[0-9a-f]*: 5c d2 com r2
10492 + *[0-9a-f]*: 5c d2 com r2
10493 + *[0-9a-f]*: 5c d7 com r7
10494 +
10495 +[0-9a-f]* <tnbz>:
10496 + *[0-9a-f]*: 5c ef tnbz pc
10497 + *[0-9a-f]*: 5c ec tnbz r12
10498 + *[0-9a-f]*: 5c e5 tnbz r5
10499 + *[0-9a-f]*: 5c e4 tnbz r4
10500 + *[0-9a-f]*: 5c ee tnbz lr
10501 + *[0-9a-f]*: 5c e8 tnbz r8
10502 + *[0-9a-f]*: 5c ec tnbz r12
10503 + *[0-9a-f]*: 5c ef tnbz pc
10504 +
10505 +[0-9a-f]* <rol>:
10506 + *[0-9a-f]*: 5c ff rol pc
10507 + *[0-9a-f]*: 5c fc rol r12
10508 + *[0-9a-f]*: 5c f5 rol r5
10509 + *[0-9a-f]*: 5c f4 rol r4
10510 + *[0-9a-f]*: 5c fe rol lr
10511 + *[0-9a-f]*: 5c fa rol r10
10512 + *[0-9a-f]*: 5c f9 rol r9
10513 + *[0-9a-f]*: 5c f5 rol r5
10514 +
10515 +[0-9a-f]* <ror>:
10516 + *[0-9a-f]*: 5d 0f ror pc
10517 + *[0-9a-f]*: 5d 0c ror r12
10518 + *[0-9a-f]*: 5d 05 ror r5
10519 + *[0-9a-f]*: 5d 04 ror r4
10520 + *[0-9a-f]*: 5d 0e ror lr
10521 + *[0-9a-f]*: 5d 08 ror r8
10522 + *[0-9a-f]*: 5d 04 ror r4
10523 + *[0-9a-f]*: 5d 07 ror r7
10524 +
10525 +[0-9a-f]* <icall>:
10526 + *[0-9a-f]*: 5d 1f icall pc
10527 + *[0-9a-f]*: 5d 1c icall r12
10528 + *[0-9a-f]*: 5d 15 icall r5
10529 + *[0-9a-f]*: 5d 14 icall r4
10530 + *[0-9a-f]*: 5d 1e icall lr
10531 + *[0-9a-f]*: 5d 13 icall r3
10532 + *[0-9a-f]*: 5d 11 icall r1
10533 + *[0-9a-f]*: 5d 13 icall r3
10534 +
10535 +[0-9a-f]* <mustr>:
10536 + *[0-9a-f]*: 5d 2f mustr pc
10537 + *[0-9a-f]*: 5d 2c mustr r12
10538 + *[0-9a-f]*: 5d 25 mustr r5
10539 + *[0-9a-f]*: 5d 24 mustr r4
10540 + *[0-9a-f]*: 5d 2e mustr lr
10541 + *[0-9a-f]*: 5d 21 mustr r1
10542 + *[0-9a-f]*: 5d 24 mustr r4
10543 + *[0-9a-f]*: 5d 2c mustr r12
10544 +
10545 +[0-9a-f]* <musfr>:
10546 + *[0-9a-f]*: 5d 3f musfr pc
10547 + *[0-9a-f]*: 5d 3c musfr r12
10548 + *[0-9a-f]*: 5d 35 musfr r5
10549 + *[0-9a-f]*: 5d 34 musfr r4
10550 + *[0-9a-f]*: 5d 3e musfr lr
10551 + *[0-9a-f]*: 5d 3b musfr r11
10552 + *[0-9a-f]*: 5d 3c musfr r12
10553 + *[0-9a-f]*: 5d 32 musfr r2
10554 +
10555 +[0-9a-f]* <ret_cond>:
10556 + *[0-9a-f]*: 5e 0f reteq 1
10557 + *[0-9a-f]*: 5e fc retal r12
10558 + *[0-9a-f]*: 5e 85 retls r5
10559 + *[0-9a-f]*: 5e 74 retpl r4
10560 + *[0-9a-f]*: 5e 1e retne -1
10561 + *[0-9a-f]*: 5e 90 retgt r0
10562 + *[0-9a-f]*: 5e 9c retgt r12
10563 + *[0-9a-f]*: 5e 4a retge r10
10564 +
10565 +[0-9a-f]* <sr_cond>:
10566 + *[0-9a-f]*: 5f 0f sreq pc
10567 + *[0-9a-f]*: 5f fc sral r12
10568 + *[0-9a-f]*: 5f 85 srls r5
10569 + *[0-9a-f]*: 5f 74 srpl r4
10570 + *[0-9a-f]*: 5f 1e srne lr
10571 + *[0-9a-f]*: 5f 50 srlt r0
10572 + *[0-9a-f]*: 5f fd sral sp
10573 + *[0-9a-f]*: 5f 49 srge r9
10574 +
10575 +[0-9a-f]* <ld_w3>:
10576 + *[0-9a-f]*: 7e 0f ld\.w pc,pc\[0x0\]
10577 + *[0-9a-f]*: 79 fc ld\.w r12,r12\[0x7c\]
10578 + *[0-9a-f]*: 6b 05 ld\.w r5,r5\[0x40\]
10579 + *[0-9a-f]*: 68 f4 ld\.w r4,r4\[0x3c\]
10580 + *[0-9a-f]*: 7c 1e ld\.w lr,lr\[0x4\]
10581 + *[0-9a-f]*: 64 dd ld\.w sp,r2\[0x34\]
10582 + *[0-9a-f]*: 62 29 ld\.w r9,r1\[0x8\]
10583 + *[0-9a-f]*: 7a f5 ld\.w r5,sp\[0x3c\]
10584 +
10585 +[0-9a-f]* <ld_sh3>:
10586 + *[0-9a-f]*: 9e 0f ld\.sh pc,pc\[0x0\]
10587 + *[0-9a-f]*: 98 7c ld\.sh r12,r12\[0xe\]
10588 + *[0-9a-f]*: 8a 45 ld\.sh r5,r5\[0x8\]
10589 + *[0-9a-f]*: 88 34 ld\.sh r4,r4\[0x6\]
10590 + *[0-9a-f]*: 9c 1e ld\.sh lr,lr\[0x2\]
10591 + *[0-9a-f]*: 84 44 ld\.sh r4,r2\[0x8\]
10592 + *[0-9a-f]*: 9c 5d ld\.sh sp,lr\[0xa\]
10593 + *[0-9a-f]*: 96 12 ld\.sh r2,r11\[0x2\]
10594 +
10595 +[0-9a-f]* <ld_uh3>:
10596 + *[0-9a-f]*: 9e 8f ld\.uh pc,pc\[0x0\]
10597 + *[0-9a-f]*: 98 fc ld\.uh r12,r12\[0xe\]
10598 + *[0-9a-f]*: 8a c5 ld\.uh r5,r5\[0x8\]
10599 + *[0-9a-f]*: 88 b4 ld\.uh r4,r4\[0x6\]
10600 + *[0-9a-f]*: 9c 9e ld\.uh lr,lr\[0x2\]
10601 + *[0-9a-f]*: 80 da ld\.uh r10,r0\[0xa\]
10602 + *[0-9a-f]*: 96 c8 ld\.uh r8,r11\[0x8\]
10603 + *[0-9a-f]*: 84 ea ld\.uh r10,r2\[0xc\]
10604 +
10605 +[0-9a-f]* <st_w3>:
10606 + *[0-9a-f]*: 9f 0f st\.w pc\[0x0\],pc
10607 + *[0-9a-f]*: 99 fc st\.w r12\[0x3c\],r12
10608 + *[0-9a-f]*: 8b 85 st\.w r5\[0x20\],r5
10609 + *[0-9a-f]*: 89 74 st\.w r4\[0x1c\],r4
10610 + *[0-9a-f]*: 9d 1e st\.w lr\[0x4\],lr
10611 + *[0-9a-f]*: 8f bb st\.w r7\[0x2c\],r11
10612 + *[0-9a-f]*: 85 66 st\.w r2\[0x18\],r6
10613 + *[0-9a-f]*: 89 39 st\.w r4\[0xc\],r9
10614 +
10615 +[0-9a-f]* <st_h3>:
10616 + *[0-9a-f]*: be 0f st\.h pc\[0x0\],pc
10617 + *[0-9a-f]*: b8 7c st\.h r12\[0xe\],r12
10618 + *[0-9a-f]*: aa 45 st\.h r5\[0x8\],r5
10619 + *[0-9a-f]*: a8 34 st\.h r4\[0x6\],r4
10620 + *[0-9a-f]*: bc 1e st\.h lr\[0x2\],lr
10621 + *[0-9a-f]*: bc 5c st\.h lr\[0xa\],r12
10622 + *[0-9a-f]*: ac 20 st\.h r6\[0x4\],r0
10623 + *[0-9a-f]*: aa 6d st\.h r5\[0xc\],sp
10624 +
10625 +[0-9a-f]* <st_b3>:
10626 + *[0-9a-f]*: be 8f st\.b pc\[0x0\],pc
10627 + *[0-9a-f]*: b8 fc st\.b r12\[0x7\],r12
10628 + *[0-9a-f]*: aa c5 st\.b r5\[0x4\],r5
10629 + *[0-9a-f]*: a8 b4 st\.b r4\[0x3\],r4
10630 + *[0-9a-f]*: bc 9e st\.b lr\[0x1\],lr
10631 + *[0-9a-f]*: b8 e9 st\.b r12\[0x6\],r9
10632 + *[0-9a-f]*: a4 be st\.b r2\[0x3\],lr
10633 + *[0-9a-f]*: a2 bb st\.b r1\[0x3\],r11
10634 +
10635 +[0-9a-f]* <ldd>:
10636 + *[0-9a-f]*: bf 00 ld\.d r0,pc
10637 + *[0-9a-f]*: b9 0e ld\.d lr,r12
10638 + *[0-9a-f]*: ab 08 ld\.d r8,r5
10639 + *[0-9a-f]*: a9 06 ld\.d r6,r4
10640 + *[0-9a-f]*: bd 02 ld\.d r2,lr
10641 + *[0-9a-f]*: af 0e ld\.d lr,r7
10642 + *[0-9a-f]*: a9 04 ld\.d r4,r4
10643 + *[0-9a-f]*: bf 0e ld\.d lr,pc
10644 +
10645 +[0-9a-f]* <ldd_postinc>:
10646 + *[0-9a-f]*: bf 01 ld\.d r0,pc\+\+
10647 + *[0-9a-f]*: b9 0f ld\.d lr,r12\+\+
10648 + *[0-9a-f]*: ab 09 ld\.d r8,r5\+\+
10649 + *[0-9a-f]*: a9 07 ld\.d r6,r4\+\+
10650 + *[0-9a-f]*: bd 03 ld\.d r2,lr\+\+
10651 + *[0-9a-f]*: ab 0f ld\.d lr,r5\+\+
10652 + *[0-9a-f]*: b7 0d ld\.d r12,r11\+\+
10653 + *[0-9a-f]*: b9 03 ld\.d r2,r12\+\+
10654 +
10655 +[0-9a-f]* <ldd_predec>:
10656 + *[0-9a-f]*: bf 10 ld\.d r0,--pc
10657 + *[0-9a-f]*: b9 1e ld\.d lr,--r12
10658 + *[0-9a-f]*: ab 18 ld\.d r8,--r5
10659 + *[0-9a-f]*: a9 16 ld\.d r6,--r4
10660 + *[0-9a-f]*: bd 12 ld\.d r2,--lr
10661 + *[0-9a-f]*: a1 18 ld\.d r8,--r0
10662 + *[0-9a-f]*: bf 1a ld\.d r10,--pc
10663 + *[0-9a-f]*: a9 12 ld\.d r2,--r4
10664 +
10665 +[0-9a-f]* <std>:
10666 + *[0-9a-f]*: bf 11 st\.d pc,r0
10667 + *[0-9a-f]*: b9 1f st\.d r12,lr
10668 + *[0-9a-f]*: ab 19 st\.d r5,r8
10669 + *[0-9a-f]*: a9 17 st\.d r4,r6
10670 + *[0-9a-f]*: bd 13 st\.d lr,r2
10671 + *[0-9a-f]*: a1 1d st\.d r0,r12
10672 + *[0-9a-f]*: bb 15 st\.d sp,r4
10673 + *[0-9a-f]*: b9 1d st\.d r12,r12
10674 +
10675 +[0-9a-f]* <std_postinc>:
10676 + *[0-9a-f]*: bf 20 st\.d pc\+\+,r0
10677 + *[0-9a-f]*: b9 2e st\.d r12\+\+,lr
10678 + *[0-9a-f]*: ab 28 st\.d r5\+\+,r8
10679 + *[0-9a-f]*: a9 26 st\.d r4\+\+,r6
10680 + *[0-9a-f]*: bd 22 st\.d lr\+\+,r2
10681 + *[0-9a-f]*: bb 26 st\.d sp\+\+,r6
10682 + *[0-9a-f]*: b5 26 st\.d r10\+\+,r6
10683 + *[0-9a-f]*: af 22 st\.d r7\+\+,r2
10684 +
10685 +[0-9a-f]* <std_predec>:
10686 + *[0-9a-f]*: bf 21 st\.d --pc,r0
10687 + *[0-9a-f]*: b9 2f st\.d --r12,lr
10688 + *[0-9a-f]*: ab 29 st\.d --r5,r8
10689 + *[0-9a-f]*: a9 27 st\.d --r4,r6
10690 + *[0-9a-f]*: bd 23 st\.d --lr,r2
10691 + *[0-9a-f]*: a7 27 st\.d --r3,r6
10692 + *[0-9a-f]*: bd 23 st\.d --lr,r2
10693 + *[0-9a-f]*: a1 25 st\.d --r0,r4
10694 +
10695 +[0-9a-f]* <mul>:
10696 + *[0-9a-f]*: bf 3f mul pc,pc
10697 + *[0-9a-f]*: b9 3c mul r12,r12
10698 + *[0-9a-f]*: ab 35 mul r5,r5
10699 + *[0-9a-f]*: a9 34 mul r4,r4
10700 + *[0-9a-f]*: bd 3e mul lr,lr
10701 + *[0-9a-f]*: bd 3a mul r10,lr
10702 + *[0-9a-f]*: b1 30 mul r0,r8
10703 + *[0-9a-f]*: ab 38 mul r8,r5
10704 +
10705 +[0-9a-f]* <asr_imm5>:
10706 + *[0-9a-f]*: a1 4f asr pc,0x0
10707 + *[0-9a-f]*: bf 5c asr r12,0x1f
10708 + *[0-9a-f]*: b1 45 asr r5,0x10
10709 + *[0-9a-f]*: af 54 asr r4,0xf
10710 + *[0-9a-f]*: a1 5e asr lr,0x1
10711 + *[0-9a-f]*: b7 56 asr r6,0x17
10712 + *[0-9a-f]*: b3 46 asr r6,0x12
10713 + *[0-9a-f]*: a9 45 asr r5,0x8
10714 +
10715 +[0-9a-f]* <lsl_imm5>:
10716 + *[0-9a-f]*: a1 6f lsl pc,0x0
10717 + *[0-9a-f]*: bf 7c lsl r12,0x1f
10718 + *[0-9a-f]*: b1 65 lsl r5,0x10
10719 + *[0-9a-f]*: af 74 lsl r4,0xf
10720 + *[0-9a-f]*: a1 7e lsl lr,0x1
10721 + *[0-9a-f]*: ad 7c lsl r12,0xd
10722 + *[0-9a-f]*: b1 66 lsl r6,0x10
10723 + *[0-9a-f]*: b9 71 lsl r1,0x19
10724 +
10725 +[0-9a-f]* <lsr_imm5>:
10726 + *[0-9a-f]*: a1 8f lsr pc,0x0
10727 + *[0-9a-f]*: bf 9c lsr r12,0x1f
10728 + *[0-9a-f]*: b1 85 lsr r5,0x10
10729 + *[0-9a-f]*: af 94 lsr r4,0xf
10730 + *[0-9a-f]*: a1 9e lsr lr,0x1
10731 + *[0-9a-f]*: a1 90 lsr r0,0x1
10732 + *[0-9a-f]*: ab 88 lsr r8,0xa
10733 + *[0-9a-f]*: bb 87 lsr r7,0x1a
10734 +
10735 +[0-9a-f]* <sbr>:
10736 + *[0-9a-f]*: a1 af sbr pc,0x0
10737 + *[0-9a-f]*: bf bc sbr r12,0x1f
10738 + *[0-9a-f]*: b1 a5 sbr r5,0x10
10739 + *[0-9a-f]*: af b4 sbr r4,0xf
10740 + *[0-9a-f]*: a1 be sbr lr,0x1
10741 + *[0-9a-f]*: bf b8 sbr r8,0x1f
10742 + *[0-9a-f]*: b7 a6 sbr r6,0x16
10743 + *[0-9a-f]*: b7 b1 sbr r1,0x17
10744 +
10745 +[0-9a-f]* <cbr>:
10746 + *[0-9a-f]*: a1 cf cbr pc,0x0
10747 + *[0-9a-f]*: bf dc cbr r12,0x1f
10748 + *[0-9a-f]*: b1 c5 cbr r5,0x10
10749 + *[0-9a-f]*: af d4 cbr r4,0xf
10750 + *[0-9a-f]*: a1 de cbr lr,0x1
10751 + *[0-9a-f]*: ab cc cbr r12,0xa
10752 + *[0-9a-f]*: b7 c7 cbr r7,0x16
10753 + *[0-9a-f]*: a9 d8 cbr r8,0x9
10754 +
10755 +[0-9a-f]* <brc1>:
10756 + *[0-9a-f]*: c0 00 breq [0-9a-f]* <.*>
10757 + *[0-9a-f]*: cf f7 brpl [0-9a-f]* <.*>
10758 + *[0-9a-f]*: c8 04 brge [0-9a-f]* <.*>
10759 + *[0-9a-f]*: c7 f3 brcs [0-9a-f]* <.*>
10760 + *[0-9a-f]*: c0 11 brne [0-9a-f]* <.*>
10761 + *[0-9a-f]*: c7 33 brcs [0-9a-f]* <.*>
10762 + *[0-9a-f]*: cf 70 breq [0-9a-f]* <.*>
10763 + *[0-9a-f]*: c0 60 breq [0-9a-f]* <.*>
10764 +
10765 +[0-9a-f]* <rjmp>:
10766 + *[0-9a-f]*: c0 08 rjmp [0-9a-f]* <.*>
10767 + *[0-9a-f]*: cf fb rjmp [0-9a-f]* <.*>
10768 + *[0-9a-f]*: c0 0a rjmp [0-9a-f]* <.*>
10769 + *[0-9a-f]*: cf f9 rjmp [0-9a-f]* <.*>
10770 + *[0-9a-f]*: c0 18 rjmp [0-9a-f]* <.*>
10771 + *[0-9a-f]*: c1 fa rjmp [0-9a-f]* <.*>
10772 + *[0-9a-f]*: c0 78 rjmp [0-9a-f]* <.*>
10773 + *[0-9a-f]*: cf ea rjmp [0-9a-f]* <.*>
10774 +
10775 +[0-9a-f]* <rcall1>:
10776 + *[0-9a-f]*: c0 0c rcall [0-9a-f]* <.*>
10777 + *[0-9a-f]*: cf ff rcall [0-9a-f]* <.*>
10778 + *[0-9a-f]*: c0 0e rcall [0-9a-f]* <.*>
10779 + *[0-9a-f]*: cf fd rcall [0-9a-f]* <.*>
10780 + *[0-9a-f]*: c0 1c rcall [0-9a-f]* <.*>
10781 + *[0-9a-f]*: c6 cc rcall [0-9a-f]* <.*>
10782 + *[0-9a-f]*: cf 7e rcall [0-9a-f]* <.*>
10783 + *[0-9a-f]*: c1 ae rcall [0-9a-f]* <.*>
10784 +
10785 +[0-9a-f]* <acall>:
10786 + *[0-9a-f]*: d0 00 acall 0x0
10787 + *[0-9a-f]*: df f0 acall 0x3fc
10788 + *[0-9a-f]*: d8 00 acall 0x200
10789 + *[0-9a-f]*: d7 f0 acall 0x1fc
10790 + *[0-9a-f]*: d0 10 acall 0x4
10791 + *[0-9a-f]*: d5 90 acall 0x164
10792 + *[0-9a-f]*: d4 c0 acall 0x130
10793 + *[0-9a-f]*: d2 b0 acall 0xac
10794 +
10795 +[0-9a-f]* <scall>:
10796 + *[0-9a-f]*: d7 33 scall
10797 + *[0-9a-f]*: d7 33 scall
10798 + *[0-9a-f]*: d7 33 scall
10799 + *[0-9a-f]*: d7 33 scall
10800 + *[0-9a-f]*: d7 33 scall
10801 + *[0-9a-f]*: d7 33 scall
10802 + *[0-9a-f]*: d7 33 scall
10803 + *[0-9a-f]*: d7 33 scall
10804 +
10805 +[0-9a-f]* <popm>:
10806 + *[0-9a-f]*: d8 02 popm pc
10807 + *[0-9a-f]*: dd fa popm r0-r11,pc,r12=-1
10808 + *[0-9a-f]*: d4 02 popm lr
10809 + *[0-9a-f]*: db fa popm r0-r11,pc,r12=1
10810 + *[0-9a-f]*: d0 12 popm r0-r3
10811 + *[0-9a-f]*: d8 e2 popm r4-r10,pc
10812 + *[0-9a-f]*: d9 1a popm r0-r3,r11,pc,r12=0
10813 + *[0-9a-f]*: d7 b2 popm r0-r7,r10-r12,lr
10814 +
10815 +[0-9a-f]* <pushm>:
10816 + *[0-9a-f]*: d8 01 pushm pc
10817 + *[0-9a-f]*: df f1 pushm r0-r12,lr-pc
10818 + *[0-9a-f]*: d8 01 pushm pc
10819 + *[0-9a-f]*: d7 f1 pushm r0-r12,lr
10820 + *[0-9a-f]*: d0 11 pushm r0-r3
10821 + *[0-9a-f]*: dc c1 pushm r8-r10,lr-pc
10822 + *[0-9a-f]*: d0 91 pushm r0-r3,r10
10823 + *[0-9a-f]*: d2 41 pushm r8-r9,r12
10824 +
10825 +[0-9a-f]* <popm_n>:
10826 +.*
10827 +.*
10828 +.*
10829 +.*
10830 +.*
10831 +.*
10832 +.*
10833 +.*
10834 +
10835 +[0-9a-f]* <pushm_n>:
10836 +.*
10837 +.*
10838 +.*
10839 +.*
10840 +.*
10841 +.*
10842 +.*
10843 +.*
10844 +
10845 +[0-9a-f]* <csrfcz>:
10846 + *[0-9a-f]*: d0 03 csrfcz 0x0
10847 + *[0-9a-f]*: d1 f3 csrfcz 0x1f
10848 + *[0-9a-f]*: d1 03 csrfcz 0x10
10849 + *[0-9a-f]*: d0 f3 csrfcz 0xf
10850 + *[0-9a-f]*: d0 13 csrfcz 0x1
10851 + *[0-9a-f]*: d0 53 csrfcz 0x5
10852 + *[0-9a-f]*: d0 d3 csrfcz 0xd
10853 + *[0-9a-f]*: d1 73 csrfcz 0x17
10854 +
10855 +[0-9a-f]* <ssrf>:
10856 + *[0-9a-f]*: d2 03 ssrf 0x0
10857 + *[0-9a-f]*: d3 f3 ssrf 0x1f
10858 + *[0-9a-f]*: d3 03 ssrf 0x10
10859 + *[0-9a-f]*: d2 f3 ssrf 0xf
10860 + *[0-9a-f]*: d2 13 ssrf 0x1
10861 + *[0-9a-f]*: d3 d3 ssrf 0x1d
10862 + *[0-9a-f]*: d2 d3 ssrf 0xd
10863 + *[0-9a-f]*: d2 d3 ssrf 0xd
10864 +
10865 +[0-9a-f]* <csrf>:
10866 + *[0-9a-f]*: d4 03 csrf 0x0
10867 + *[0-9a-f]*: d5 f3 csrf 0x1f
10868 + *[0-9a-f]*: d5 03 csrf 0x10
10869 + *[0-9a-f]*: d4 f3 csrf 0xf
10870 + *[0-9a-f]*: d4 13 csrf 0x1
10871 + *[0-9a-f]*: d4 a3 csrf 0xa
10872 + *[0-9a-f]*: d4 f3 csrf 0xf
10873 + *[0-9a-f]*: d4 b3 csrf 0xb
10874 +
10875 +[0-9a-f]* <rete>:
10876 + *[0-9a-f]*: d6 03 rete
10877 +
10878 +[0-9a-f]* <rets>:
10879 + *[0-9a-f]*: d6 13 rets
10880 +
10881 +[0-9a-f]* <retd>:
10882 + *[0-9a-f]*: d6 23 retd
10883 +
10884 +[0-9a-f]* <retj>:
10885 + *[0-9a-f]*: d6 33 retj
10886 +
10887 +[0-9a-f]* <tlbr>:
10888 + *[0-9a-f]*: d6 43 tlbr
10889 +
10890 +[0-9a-f]* <tlbs>:
10891 + *[0-9a-f]*: d6 53 tlbs
10892 +
10893 +[0-9a-f]* <tlbw>:
10894 + *[0-9a-f]*: d6 63 tlbw
10895 +
10896 +[0-9a-f]* <breakpoint>:
10897 + *[0-9a-f]*: d6 73 breakpoint
10898 +
10899 +[0-9a-f]* <incjosp>:
10900 + *[0-9a-f]*: d6 83 incjosp 1
10901 + *[0-9a-f]*: d6 93 incjosp 2
10902 + *[0-9a-f]*: d6 a3 incjosp 3
10903 + *[0-9a-f]*: d6 b3 incjosp 4
10904 + *[0-9a-f]*: d6 c3 incjosp -4
10905 + *[0-9a-f]*: d6 d3 incjosp -3
10906 + *[0-9a-f]*: d6 e3 incjosp -2
10907 + *[0-9a-f]*: d6 f3 incjosp -1
10908 +
10909 +[0-9a-f]* <nop>:
10910 + *[0-9a-f]*: d7 03 nop
10911 +
10912 +[0-9a-f]* <popjc>:
10913 + *[0-9a-f]*: d7 13 popjc
10914 +
10915 +[0-9a-f]* <pushjc>:
10916 + *[0-9a-f]*: d7 23 pushjc
10917 +
10918 +[0-9a-f]* <add2>:
10919 + *[0-9a-f]*: fe 0f 00 0f add pc,pc,pc
10920 + *[0-9a-f]*: f8 0c 00 3c add r12,r12,r12<<0x3
10921 + *[0-9a-f]*: ea 05 00 25 add r5,r5,r5<<0x2
10922 + *[0-9a-f]*: e8 04 00 14 add r4,r4,r4<<0x1
10923 + *[0-9a-f]*: fc 0e 00 1e add lr,lr,lr<<0x1
10924 + *[0-9a-f]*: f8 00 00 10 add r0,r12,r0<<0x1
10925 + *[0-9a-f]*: f8 04 00 09 add r9,r12,r4
10926 + *[0-9a-f]*: f8 07 00 2c add r12,r12,r7<<0x2
10927 +
10928 +[0-9a-f]* <sub2>:
10929 + *[0-9a-f]*: fe 0f 01 0f sub pc,pc,pc
10930 + *[0-9a-f]*: f8 0c 01 3c sub r12,r12,r12<<0x3
10931 + *[0-9a-f]*: ea 05 01 25 sub r5,r5,r5<<0x2
10932 + *[0-9a-f]*: e8 04 01 14 sub r4,r4,r4<<0x1
10933 + *[0-9a-f]*: fc 0e 01 1e sub lr,lr,lr<<0x1
10934 + *[0-9a-f]*: e6 04 01 0d sub sp,r3,r4
10935 + *[0-9a-f]*: ee 03 01 03 sub r3,r7,r3
10936 + *[0-9a-f]*: f4 0d 01 1d sub sp,r10,sp<<0x1
10937 +
10938 +[0-9a-f]* <divu>:
10939 + *[0-9a-f]*: fe 0f 0d 0f divu pc,pc,pc
10940 + *[0-9a-f]*: f8 0c 0d 0c divu r12,r12,r12
10941 + *[0-9a-f]*: ea 05 0d 05 divu r5,r5,r5
10942 + *[0-9a-f]*: e8 04 0d 04 divu r4,r4,r4
10943 + *[0-9a-f]*: fc 0e 0d 0e divu lr,lr,lr
10944 + *[0-9a-f]*: e8 0f 0d 0d divu sp,r4,pc
10945 + *[0-9a-f]*: ea 0d 0d 05 divu r5,r5,sp
10946 + *[0-9a-f]*: fa 00 0d 0a divu r10,sp,r0
10947 +
10948 +[0-9a-f]* <addhh_w>:
10949 + *[0-9a-f]*: fe 0f 0e 0f addhh\.w pc,pc:b,pc:b
10950 + *[0-9a-f]*: f8 0c 0e 3c addhh\.w r12,r12:t,r12:t
10951 + *[0-9a-f]*: ea 05 0e 35 addhh\.w r5,r5:t,r5:t
10952 + *[0-9a-f]*: e8 04 0e 04 addhh\.w r4,r4:b,r4:b
10953 + *[0-9a-f]*: fc 0e 0e 3e addhh\.w lr,lr:t,lr:t
10954 + *[0-9a-f]*: e0 03 0e 00 addhh\.w r0,r0:b,r3:b
10955 + *[0-9a-f]*: f8 07 0e 2e addhh\.w lr,r12:t,r7:b
10956 + *[0-9a-f]*: f4 02 0e 23 addhh\.w r3,r10:t,r2:b
10957 +
10958 +[0-9a-f]* <subhh_w>:
10959 + *[0-9a-f]*: fe 0f 0f 0f subhh\.w pc,pc:b,pc:b
10960 + *[0-9a-f]*: f8 0c 0f 3c subhh\.w r12,r12:t,r12:t
10961 + *[0-9a-f]*: ea 05 0f 35 subhh\.w r5,r5:t,r5:t
10962 + *[0-9a-f]*: e8 04 0f 04 subhh\.w r4,r4:b,r4:b
10963 + *[0-9a-f]*: fc 0e 0f 3e subhh\.w lr,lr:t,lr:t
10964 + *[0-9a-f]*: e2 07 0f 2a subhh\.w r10,r1:t,r7:b
10965 + *[0-9a-f]*: f4 0e 0f 3f subhh\.w pc,r10:t,lr:t
10966 + *[0-9a-f]*: e0 0c 0f 23 subhh\.w r3,r0:t,r12:b
10967 +
10968 +[0-9a-f]* <adc>:
10969 + *[0-9a-f]*: fe 0f 00 4f adc pc,pc,pc
10970 + *[0-9a-f]*: f8 0c 00 4c adc r12,r12,r12
10971 + *[0-9a-f]*: ea 05 00 45 adc r5,r5,r5
10972 + *[0-9a-f]*: e8 04 00 44 adc r4,r4,r4
10973 + *[0-9a-f]*: fc 0e 00 4e adc lr,lr,lr
10974 + *[0-9a-f]*: e0 07 00 44 adc r4,r0,r7
10975 + *[0-9a-f]*: e8 03 00 4d adc sp,r4,r3
10976 + *[0-9a-f]*: f8 00 00 42 adc r2,r12,r0
10977 +
10978 +[0-9a-f]* <sbc>:
10979 + *[0-9a-f]*: fe 0f 01 4f sbc pc,pc,pc
10980 + *[0-9a-f]*: f8 0c 01 4c sbc r12,r12,r12
10981 + *[0-9a-f]*: ea 05 01 45 sbc r5,r5,r5
10982 + *[0-9a-f]*: e8 04 01 44 sbc r4,r4,r4
10983 + *[0-9a-f]*: fc 0e 01 4e sbc lr,lr,lr
10984 + *[0-9a-f]*: ee 09 01 46 sbc r6,r7,r9
10985 + *[0-9a-f]*: f0 05 01 40 sbc r0,r8,r5
10986 + *[0-9a-f]*: e0 04 01 41 sbc r1,r0,r4
10987 +
10988 +[0-9a-f]* <mul_2>:
10989 + *[0-9a-f]*: fe 0f 02 4f mul pc,pc,pc
10990 + *[0-9a-f]*: f8 0c 02 4c mul r12,r12,r12
10991 + *[0-9a-f]*: ea 05 02 45 mul r5,r5,r5
10992 + *[0-9a-f]*: e8 04 02 44 mul r4,r4,r4
10993 + *[0-9a-f]*: fc 0e 02 4e mul lr,lr,lr
10994 + *[0-9a-f]*: e0 00 02 4f mul pc,r0,r0
10995 + *[0-9a-f]*: fe 0e 02 48 mul r8,pc,lr
10996 + *[0-9a-f]*: f8 0f 02 44 mul r4,r12,pc
10997 +
10998 +[0-9a-f]* <mac>:
10999 + *[0-9a-f]*: fe 0f 03 4f mac pc,pc,pc
11000 + *[0-9a-f]*: f8 0c 03 4c mac r12,r12,r12
11001 + *[0-9a-f]*: ea 05 03 45 mac r5,r5,r5
11002 + *[0-9a-f]*: e8 04 03 44 mac r4,r4,r4
11003 + *[0-9a-f]*: fc 0e 03 4e mac lr,lr,lr
11004 + *[0-9a-f]*: e8 00 03 4a mac r10,r4,r0
11005 + *[0-9a-f]*: fc 00 03 47 mac r7,lr,r0
11006 + *[0-9a-f]*: f2 0c 03 42 mac r2,r9,r12
11007 +
11008 +[0-9a-f]* <mulsd>:
11009 + *[0-9a-f]*: fe 0f 04 4f muls\.d pc,pc,pc
11010 + *[0-9a-f]*: f8 0c 04 4c muls\.d r12,r12,r12
11011 + *[0-9a-f]*: ea 05 04 45 muls\.d r5,r5,r5
11012 + *[0-9a-f]*: e8 04 04 44 muls\.d r4,r4,r4
11013 + *[0-9a-f]*: fc 0e 04 4e muls\.d lr,lr,lr
11014 + *[0-9a-f]*: f0 0e 04 42 muls\.d r2,r8,lr
11015 + *[0-9a-f]*: e0 0b 04 44 muls\.d r4,r0,r11
11016 + *[0-9a-f]*: fc 06 04 45 muls\.d r5,lr,r6
11017 +
11018 +[0-9a-f]* <macsd>:
11019 + *[0-9a-f]*: fe 0f 05 40 macs\.d r0,pc,pc
11020 + *[0-9a-f]*: f8 0c 05 4e macs\.d lr,r12,r12
11021 + *[0-9a-f]*: ea 05 05 48 macs\.d r8,r5,r5
11022 + *[0-9a-f]*: e8 04 05 46 macs\.d r6,r4,r4
11023 + *[0-9a-f]*: fc 0e 05 42 macs\.d r2,lr,lr
11024 + *[0-9a-f]*: e2 09 05 48 macs\.d r8,r1,r9
11025 + *[0-9a-f]*: f0 08 05 4e macs\.d lr,r8,r8
11026 + *[0-9a-f]*: e6 0c 05 44 macs\.d r4,r3,r12
11027 +
11028 +[0-9a-f]* <mulud>:
11029 + *[0-9a-f]*: fe 0f 06 40 mulu\.d r0,pc,pc
11030 + *[0-9a-f]*: f8 0c 06 4e mulu\.d lr,r12,r12
11031 + *[0-9a-f]*: ea 05 06 48 mulu\.d r8,r5,r5
11032 + *[0-9a-f]*: e8 04 06 46 mulu\.d r6,r4,r4
11033 + *[0-9a-f]*: fc 0e 06 42 mulu\.d r2,lr,lr
11034 + *[0-9a-f]*: ea 00 06 46 mulu\.d r6,r5,r0
11035 + *[0-9a-f]*: ec 01 06 44 mulu\.d r4,r6,r1
11036 + *[0-9a-f]*: f0 02 06 48 mulu\.d r8,r8,r2
11037 +
11038 +[0-9a-f]* <macud>:
11039 + *[0-9a-f]*: fe 0f 07 40 macu\.d r0,pc,pc
11040 + *[0-9a-f]*: f8 0c 07 4e macu\.d lr,r12,r12
11041 + *[0-9a-f]*: ea 05 07 48 macu\.d r8,r5,r5
11042 + *[0-9a-f]*: e8 04 07 46 macu\.d r6,r4,r4
11043 + *[0-9a-f]*: fc 0e 07 42 macu\.d r2,lr,lr
11044 + *[0-9a-f]*: fa 0b 07 46 macu\.d r6,sp,r11
11045 + *[0-9a-f]*: e8 08 07 42 macu\.d r2,r4,r8
11046 + *[0-9a-f]*: f4 09 07 46 macu\.d r6,r10,r9
11047 +
11048 +[0-9a-f]* <asr_1>:
11049 + *[0-9a-f]*: fe 0f 08 4f asr pc,pc,pc
11050 + *[0-9a-f]*: f8 0c 08 4c asr r12,r12,r12
11051 + *[0-9a-f]*: ea 05 08 45 asr r5,r5,r5
11052 + *[0-9a-f]*: e8 04 08 44 asr r4,r4,r4
11053 + *[0-9a-f]*: fc 0e 08 4e asr lr,lr,lr
11054 + *[0-9a-f]*: ec 0f 08 4f asr pc,r6,pc
11055 + *[0-9a-f]*: ec 0c 08 40 asr r0,r6,r12
11056 + *[0-9a-f]*: fa 00 08 44 asr r4,sp,r0
11057 +
11058 +[0-9a-f]* <lsl_1>:
11059 + *[0-9a-f]*: fe 0f 09 4f lsl pc,pc,pc
11060 + *[0-9a-f]*: f8 0c 09 4c lsl r12,r12,r12
11061 + *[0-9a-f]*: ea 05 09 45 lsl r5,r5,r5
11062 + *[0-9a-f]*: e8 04 09 44 lsl r4,r4,r4
11063 + *[0-9a-f]*: fc 0e 09 4e lsl lr,lr,lr
11064 + *[0-9a-f]*: ea 0e 09 4e lsl lr,r5,lr
11065 + *[0-9a-f]*: fe 03 09 45 lsl r5,pc,r3
11066 + *[0-9a-f]*: fe 09 09 41 lsl r1,pc,r9
11067 +
11068 +[0-9a-f]* <lsr_1>:
11069 + *[0-9a-f]*: fe 0f 0a 4f lsr pc,pc,pc
11070 + *[0-9a-f]*: f8 0c 0a 4c lsr r12,r12,r12
11071 + *[0-9a-f]*: ea 05 0a 45 lsr r5,r5,r5
11072 + *[0-9a-f]*: e8 04 0a 44 lsr r4,r4,r4
11073 + *[0-9a-f]*: fc 0e 0a 4e lsr lr,lr,lr
11074 + *[0-9a-f]*: e8 01 0a 42 lsr r2,r4,r1
11075 + *[0-9a-f]*: e2 06 0a 45 lsr r5,r1,r6
11076 + *[0-9a-f]*: ec 07 0a 4d lsr sp,r6,r7
11077 +
11078 +[0-9a-f]* <xchg>:
11079 + *[0-9a-f]*: fe 0f 0b 4f xchg pc,pc,pc
11080 + *[0-9a-f]*: f8 0c 0b 4c xchg r12,r12,r12
11081 + *[0-9a-f]*: ea 05 0b 45 xchg r5,r5,r5
11082 + *[0-9a-f]*: e8 04 0b 44 xchg r4,r4,r4
11083 + *[0-9a-f]*: fc 0e 0b 4e xchg lr,lr,lr
11084 + *[0-9a-f]*: e8 0d 0b 4e xchg lr,r4,sp
11085 + *[0-9a-f]*: ea 0c 0b 41 xchg r1,r5,r12
11086 + *[0-9a-f]*: f8 00 0b 4e xchg lr,r12,r0
11087 +
11088 +[0-9a-f]* <max>:
11089 + *[0-9a-f]*: fe 0f 0c 4f max pc,pc,pc
11090 + *[0-9a-f]*: f8 0c 0c 4c max r12,r12,r12
11091 + *[0-9a-f]*: ea 05 0c 45 max r5,r5,r5
11092 + *[0-9a-f]*: e8 04 0c 44 max r4,r4,r4
11093 + *[0-9a-f]*: fc 0e 0c 4e max lr,lr,lr
11094 + *[0-9a-f]*: e4 0d 0c 4e max lr,r2,sp
11095 + *[0-9a-f]*: f4 09 0c 44 max r4,r10,r9
11096 + *[0-9a-f]*: f2 0e 0c 4e max lr,r9,lr
11097 +
11098 +[0-9a-f]* <min>:
11099 + *[0-9a-f]*: fe 0f 0d 4f min pc,pc,pc
11100 + *[0-9a-f]*: f8 0c 0d 4c min r12,r12,r12
11101 + *[0-9a-f]*: ea 05 0d 45 min r5,r5,r5
11102 + *[0-9a-f]*: e8 04 0d 44 min r4,r4,r4
11103 + *[0-9a-f]*: fc 0e 0d 4e min lr,lr,lr
11104 + *[0-9a-f]*: ee 08 0d 49 min r9,r7,r8
11105 + *[0-9a-f]*: ea 05 0d 4d min sp,r5,r5
11106 + *[0-9a-f]*: e2 04 0d 44 min r4,r1,r4
11107 +
11108 +[0-9a-f]* <addabs>:
11109 + *[0-9a-f]*: fe 0f 0e 4f addabs pc,pc,pc
11110 + *[0-9a-f]*: f8 0c 0e 4c addabs r12,r12,r12
11111 + *[0-9a-f]*: ea 05 0e 45 addabs r5,r5,r5
11112 + *[0-9a-f]*: e8 04 0e 44 addabs r4,r4,r4
11113 + *[0-9a-f]*: fc 0e 0e 4e addabs lr,lr,lr
11114 + *[0-9a-f]*: f4 00 0e 47 addabs r7,r10,r0
11115 + *[0-9a-f]*: f2 07 0e 49 addabs r9,r9,r7
11116 + *[0-9a-f]*: f0 0c 0e 42 addabs r2,r8,r12
11117 +
11118 +[0-9a-f]* <mulnhh_w>:
11119 + *[0-9a-f]*: fe 0f 01 8f mulnhh\.w pc,pc:b,pc:b
11120 + *[0-9a-f]*: f8 0c 01 bc mulnhh\.w r12,r12:t,r12:t
11121 + *[0-9a-f]*: ea 05 01 b5 mulnhh\.w r5,r5:t,r5:t
11122 + *[0-9a-f]*: e8 04 01 84 mulnhh\.w r4,r4:b,r4:b
11123 + *[0-9a-f]*: fc 0e 01 be mulnhh\.w lr,lr:t,lr:t
11124 + *[0-9a-f]*: fa 09 01 ab mulnhh\.w r11,sp:t,r9:b
11125 + *[0-9a-f]*: e8 0e 01 9d mulnhh\.w sp,r4:b,lr:t
11126 + *[0-9a-f]*: e4 0b 01 ac mulnhh\.w r12,r2:t,r11:b
11127 +
11128 +[0-9a-f]* <mulnwh_d>:
11129 + *[0-9a-f]*: fe 0f 02 80 mulnwh\.d r0,pc,pc:b
11130 + *[0-9a-f]*: f8 0c 02 9e mulnwh\.d lr,r12,r12:t
11131 + *[0-9a-f]*: ea 05 02 98 mulnwh\.d r8,r5,r5:t
11132 + *[0-9a-f]*: e8 04 02 86 mulnwh\.d r6,r4,r4:b
11133 + *[0-9a-f]*: fc 0e 02 92 mulnwh\.d r2,lr,lr:t
11134 + *[0-9a-f]*: e6 02 02 9e mulnwh\.d lr,r3,r2:t
11135 + *[0-9a-f]*: ea 09 02 84 mulnwh\.d r4,r5,r9:b
11136 + *[0-9a-f]*: e8 04 02 9c mulnwh\.d r12,r4,r4:t
11137 +
11138 +[0-9a-f]* <machh_w>:
11139 + *[0-9a-f]*: fe 0f 04 8f machh\.w pc,pc:b,pc:b
11140 + *[0-9a-f]*: f8 0c 04 bc machh\.w r12,r12:t,r12:t
11141 + *[0-9a-f]*: ea 05 04 b5 machh\.w r5,r5:t,r5:t
11142 + *[0-9a-f]*: e8 04 04 84 machh\.w r4,r4:b,r4:b
11143 + *[0-9a-f]*: fc 0e 04 be machh\.w lr,lr:t,lr:t
11144 + *[0-9a-f]*: ea 01 04 9e machh\.w lr,r5:b,r1:t
11145 + *[0-9a-f]*: ec 07 04 89 machh\.w r9,r6:b,r7:b
11146 + *[0-9a-f]*: fc 0c 04 a5 machh\.w r5,lr:t,r12:b
11147 +
11148 +[0-9a-f]* <machh_d>:
11149 + *[0-9a-f]*: fe 0f 05 80 machh\.d r0,pc:b,pc:b
11150 + *[0-9a-f]*: f8 0c 05 be machh\.d lr,r12:t,r12:t
11151 + *[0-9a-f]*: ea 05 05 b8 machh\.d r8,r5:t,r5:t
11152 + *[0-9a-f]*: e8 04 05 86 machh\.d r6,r4:b,r4:b
11153 + *[0-9a-f]*: fc 0e 05 b2 machh\.d r2,lr:t,lr:t
11154 + *[0-9a-f]*: e0 08 05 8a machh\.d r10,r0:b,r8:b
11155 + *[0-9a-f]*: e8 05 05 9e machh\.d lr,r4:b,r5:t
11156 + *[0-9a-f]*: e0 04 05 98 machh\.d r8,r0:b,r4:t
11157 +
11158 +[0-9a-f]* <macsathh_w>:
11159 + *[0-9a-f]*: fe 0f 06 8f macsathh\.w pc,pc:b,pc:b
11160 + *[0-9a-f]*: f8 0c 06 bc macsathh\.w r12,r12:t,r12:t
11161 + *[0-9a-f]*: ea 05 06 b5 macsathh\.w r5,r5:t,r5:t
11162 + *[0-9a-f]*: e8 04 06 84 macsathh\.w r4,r4:b,r4:b
11163 + *[0-9a-f]*: fc 0e 06 be macsathh\.w lr,lr:t,lr:t
11164 + *[0-9a-f]*: ee 0f 06 b7 macsathh\.w r7,r7:t,pc:t
11165 + *[0-9a-f]*: e4 04 06 a4 macsathh\.w r4,r2:t,r4:b
11166 + *[0-9a-f]*: f0 03 06 b4 macsathh\.w r4,r8:t,r3:t
11167 +
11168 +[0-9a-f]* <mulhh_w>:
11169 + *[0-9a-f]*: fe 0f 07 8f mulhh\.w pc,pc:b,pc:b
11170 + *[0-9a-f]*: f8 0c 07 bc mulhh\.w r12,r12:t,r12:t
11171 + *[0-9a-f]*: ea 05 07 b5 mulhh\.w r5,r5:t,r5:t
11172 + *[0-9a-f]*: e8 04 07 84 mulhh\.w r4,r4:b,r4:b
11173 + *[0-9a-f]*: fc 0e 07 be mulhh\.w lr,lr:t,lr:t
11174 + *[0-9a-f]*: e8 09 07 a7 mulhh\.w r7,r4:t,r9:b
11175 + *[0-9a-f]*: e6 07 07 bf mulhh\.w pc,r3:t,r7:t
11176 + *[0-9a-f]*: e8 09 07 9f mulhh\.w pc,r4:b,r9:t
11177 +
11178 +[0-9a-f]* <mulsathh_h>:
11179 + *[0-9a-f]*: fe 0f 08 8f mulsathh\.h pc,pc:b,pc:b
11180 + *[0-9a-f]*: f8 0c 08 bc mulsathh\.h r12,r12:t,r12:t
11181 + *[0-9a-f]*: ea 05 08 b5 mulsathh\.h r5,r5:t,r5:t
11182 + *[0-9a-f]*: e8 04 08 84 mulsathh\.h r4,r4:b,r4:b
11183 + *[0-9a-f]*: fc 0e 08 be mulsathh\.h lr,lr:t,lr:t
11184 + *[0-9a-f]*: e2 0d 08 83 mulsathh\.h r3,r1:b,sp:b
11185 + *[0-9a-f]*: fc 0b 08 ab mulsathh\.h r11,lr:t,r11:b
11186 + *[0-9a-f]*: f0 0b 08 98 mulsathh\.h r8,r8:b,r11:t
11187 +
11188 +[0-9a-f]* <mulsathh_w>:
11189 + *[0-9a-f]*: fe 0f 09 8f mulsathh\.w pc,pc:b,pc:b
11190 + *[0-9a-f]*: f8 0c 09 bc mulsathh\.w r12,r12:t,r12:t
11191 + *[0-9a-f]*: ea 05 09 b5 mulsathh\.w r5,r5:t,r5:t
11192 + *[0-9a-f]*: e8 04 09 84 mulsathh\.w r4,r4:b,r4:b
11193 + *[0-9a-f]*: fc 0e 09 be mulsathh\.w lr,lr:t,lr:t
11194 + *[0-9a-f]*: f6 06 09 ae mulsathh\.w lr,r11:t,r6:b
11195 + *[0-9a-f]*: ec 07 09 96 mulsathh\.w r6,r6:b,r7:t
11196 + *[0-9a-f]*: e4 03 09 8a mulsathh\.w r10,r2:b,r3:b
11197 +
11198 +[0-9a-f]* <mulsatrndhh_h>:
11199 + *[0-9a-f]*: fe 0f 0a 8f mulsatrndhh\.h pc,pc:b,pc:b
11200 + *[0-9a-f]*: f8 0c 0a bc mulsatrndhh\.h r12,r12:t,r12:t
11201 + *[0-9a-f]*: ea 05 0a b5 mulsatrndhh\.h r5,r5:t,r5:t
11202 + *[0-9a-f]*: e8 04 0a 84 mulsatrndhh\.h r4,r4:b,r4:b
11203 + *[0-9a-f]*: fc 0e 0a be mulsatrndhh\.h lr,lr:t,lr:t
11204 + *[0-9a-f]*: ec 09 0a 8b mulsatrndhh\.h r11,r6:b,r9:b
11205 + *[0-9a-f]*: e6 08 0a 9b mulsatrndhh\.h r11,r3:b,r8:t
11206 + *[0-9a-f]*: fa 07 0a b5 mulsatrndhh\.h r5,sp:t,r7:t
11207 +
11208 +[0-9a-f]* <mulsatrndwh_w>:
11209 + *[0-9a-f]*: fe 0f 0b 8f mulsatrndwh\.w pc,pc,pc:b
11210 + *[0-9a-f]*: f8 0c 0b 9c mulsatrndwh\.w r12,r12,r12:t
11211 + *[0-9a-f]*: ea 05 0b 95 mulsatrndwh\.w r5,r5,r5:t
11212 + *[0-9a-f]*: e8 04 0b 84 mulsatrndwh\.w r4,r4,r4:b
11213 + *[0-9a-f]*: fc 0e 0b 9e mulsatrndwh\.w lr,lr,lr:t
11214 + *[0-9a-f]*: f8 00 0b 85 mulsatrndwh\.w r5,r12,r0:b
11215 + *[0-9a-f]*: f4 0f 0b 87 mulsatrndwh\.w r7,r10,pc:b
11216 + *[0-9a-f]*: f0 05 0b 9a mulsatrndwh\.w r10,r8,r5:t
11217 +
11218 +[0-9a-f]* <macwh_d>:
11219 + *[0-9a-f]*: fe 0f 0c 80 macwh\.d r0,pc,pc:b
11220 + *[0-9a-f]*: f8 0c 0c 9e macwh\.d lr,r12,r12:t
11221 + *[0-9a-f]*: ea 05 0c 98 macwh\.d r8,r5,r5:t
11222 + *[0-9a-f]*: e8 04 0c 86 macwh\.d r6,r4,r4:b
11223 + *[0-9a-f]*: fc 0e 0c 92 macwh\.d r2,lr,lr:t
11224 + *[0-9a-f]*: f4 0c 0c 94 macwh\.d r4,r10,r12:t
11225 + *[0-9a-f]*: ee 0d 0c 84 macwh\.d r4,r7,sp:b
11226 + *[0-9a-f]*: f2 0b 0c 8e macwh\.d lr,r9,r11:b
11227 +
11228 +[0-9a-f]* <mulwh_d>:
11229 + *[0-9a-f]*: fe 0f 0d 80 mulwh\.d r0,pc,pc:b
11230 + *[0-9a-f]*: f8 0c 0d 9e mulwh\.d lr,r12,r12:t
11231 + *[0-9a-f]*: ea 05 0d 98 mulwh\.d r8,r5,r5:t
11232 + *[0-9a-f]*: e8 04 0d 86 mulwh\.d r6,r4,r4:b
11233 + *[0-9a-f]*: fc 0e 0d 92 mulwh\.d r2,lr,lr:t
11234 + *[0-9a-f]*: ea 01 0d 8c mulwh\.d r12,r5,r1:b
11235 + *[0-9a-f]*: e2 03 0d 90 mulwh\.d r0,r1,r3:t
11236 + *[0-9a-f]*: f2 02 0d 80 mulwh\.d r0,r9,r2:b
11237 +
11238 +[0-9a-f]* <mulsatwh_w>:
11239 + *[0-9a-f]*: fe 0f 0e 8f mulsatwh\.w pc,pc,pc:b
11240 + *[0-9a-f]*: f8 0c 0e 9c mulsatwh\.w r12,r12,r12:t
11241 + *[0-9a-f]*: ea 05 0e 95 mulsatwh\.w r5,r5,r5:t
11242 + *[0-9a-f]*: e8 04 0e 84 mulsatwh\.w r4,r4,r4:b
11243 + *[0-9a-f]*: fc 0e 0e 9e mulsatwh\.w lr,lr,lr:t
11244 + *[0-9a-f]*: fe 0a 0e 9b mulsatwh\.w r11,pc,r10:t
11245 + *[0-9a-f]*: f8 09 0e 9d mulsatwh\.w sp,r12,r9:t
11246 + *[0-9a-f]*: e6 02 0e 90 mulsatwh\.w r0,r3,r2:t
11247 +
11248 +[0-9a-f]* <ldw7>:
11249 + *[0-9a-f]*: fe 0f 0f 8f ld\.w pc,pc\[pc:b<<2\]
11250 + *[0-9a-f]*: f8 0c 0f bc ld\.w r12,r12\[r12:t<<2\]
11251 + *[0-9a-f]*: ea 05 0f a5 ld\.w r5,r5\[r5:u<<2\]
11252 + *[0-9a-f]*: e8 04 0f 94 ld\.w r4,r4\[r4:l<<2\]
11253 + *[0-9a-f]*: fc 0e 0f 9e ld\.w lr,lr\[lr:l<<2\]
11254 + *[0-9a-f]*: f4 06 0f 99 ld\.w r9,r10\[r6:l<<2\]
11255 + *[0-9a-f]*: f4 0a 0f 82 ld\.w r2,r10\[r10:b<<2\]
11256 + *[0-9a-f]*: ea 0f 0f 8b ld\.w r11,r5\[pc:b<<2\]
11257 +
11258 +[0-9a-f]* <satadd_w>:
11259 + *[0-9a-f]*: fe 0f 00 cf satadd\.w pc,pc,pc
11260 + *[0-9a-f]*: f8 0c 00 cc satadd\.w r12,r12,r12
11261 + *[0-9a-f]*: ea 05 00 c5 satadd\.w r5,r5,r5
11262 + *[0-9a-f]*: e8 04 00 c4 satadd\.w r4,r4,r4
11263 + *[0-9a-f]*: fc 0e 00 ce satadd\.w lr,lr,lr
11264 + *[0-9a-f]*: f0 0b 00 c4 satadd\.w r4,r8,r11
11265 + *[0-9a-f]*: f8 06 00 c3 satadd\.w r3,r12,r6
11266 + *[0-9a-f]*: fc 09 00 c3 satadd\.w r3,lr,r9
11267 +
11268 +[0-9a-f]* <satsub_w1>:
11269 + *[0-9a-f]*: fe 0f 01 cf satsub\.w pc,pc,pc
11270 + *[0-9a-f]*: f8 0c 01 cc satsub\.w r12,r12,r12
11271 + *[0-9a-f]*: ea 05 01 c5 satsub\.w r5,r5,r5
11272 + *[0-9a-f]*: e8 04 01 c4 satsub\.w r4,r4,r4
11273 + *[0-9a-f]*: fc 0e 01 ce satsub\.w lr,lr,lr
11274 + *[0-9a-f]*: fa 00 01 c8 satsub\.w r8,sp,r0
11275 + *[0-9a-f]*: f0 04 01 c9 satsub\.w r9,r8,r4
11276 + *[0-9a-f]*: fc 02 01 cf satsub\.w pc,lr,r2
11277 +
11278 +[0-9a-f]* <satadd_h>:
11279 + *[0-9a-f]*: fe 0f 02 cf satadd\.h pc,pc,pc
11280 + *[0-9a-f]*: f8 0c 02 cc satadd\.h r12,r12,r12
11281 + *[0-9a-f]*: ea 05 02 c5 satadd\.h r5,r5,r5
11282 + *[0-9a-f]*: e8 04 02 c4 satadd\.h r4,r4,r4
11283 + *[0-9a-f]*: fc 0e 02 ce satadd\.h lr,lr,lr
11284 + *[0-9a-f]*: e6 09 02 c7 satadd\.h r7,r3,r9
11285 + *[0-9a-f]*: e0 02 02 c1 satadd\.h r1,r0,r2
11286 + *[0-9a-f]*: e8 0e 02 c1 satadd\.h r1,r4,lr
11287 +
11288 +[0-9a-f]* <satsub_h>:
11289 + *[0-9a-f]*: fe 0f 03 cf satsub\.h pc,pc,pc
11290 + *[0-9a-f]*: f8 0c 03 cc satsub\.h r12,r12,r12
11291 + *[0-9a-f]*: ea 05 03 c5 satsub\.h r5,r5,r5
11292 + *[0-9a-f]*: e8 04 03 c4 satsub\.h r4,r4,r4
11293 + *[0-9a-f]*: fc 0e 03 ce satsub\.h lr,lr,lr
11294 + *[0-9a-f]*: fc 03 03 ce satsub\.h lr,lr,r3
11295 + *[0-9a-f]*: ec 05 03 cb satsub\.h r11,r6,r5
11296 + *[0-9a-f]*: fa 00 03 c3 satsub\.h r3,sp,r0
11297 +
11298 +[0-9a-f]* <mul3>:
11299 + *[0-9a-f]*: fe 0f 10 00 mul pc,pc,0
11300 + *[0-9a-f]*: f8 0c 10 ff mul r12,r12,-1
11301 + *[0-9a-f]*: ea 05 10 80 mul r5,r5,-128
11302 + *[0-9a-f]*: e8 04 10 7f mul r4,r4,127
11303 + *[0-9a-f]*: fc 0e 10 01 mul lr,lr,1
11304 + *[0-9a-f]*: e4 0c 10 f9 mul r12,r2,-7
11305 + *[0-9a-f]*: fe 01 10 5f mul r1,pc,95
11306 + *[0-9a-f]*: ec 04 10 13 mul r4,r6,19
11307 +
11308 +[0-9a-f]* <rsub2>:
11309 + *[0-9a-f]*: fe 0f 11 00 rsub pc,pc,0
11310 + *[0-9a-f]*: f8 0c 11 ff rsub r12,r12,-1
11311 + *[0-9a-f]*: ea 05 11 80 rsub r5,r5,-128
11312 + *[0-9a-f]*: e8 04 11 7f rsub r4,r4,127
11313 + *[0-9a-f]*: fc 0e 11 01 rsub lr,lr,1
11314 + *[0-9a-f]*: fc 09 11 60 rsub r9,lr,96
11315 + *[0-9a-f]*: e2 0b 11 38 rsub r11,r1,56
11316 + *[0-9a-f]*: ee 00 11 a9 rsub r0,r7,-87
11317 +
11318 +[0-9a-f]* <clz>:
11319 + *[0-9a-f]*: fe 0f 12 00 clz pc,pc
11320 + *[0-9a-f]*: f8 0c 12 00 clz r12,r12
11321 + *[0-9a-f]*: ea 05 12 00 clz r5,r5
11322 + *[0-9a-f]*: e8 04 12 00 clz r4,r4
11323 + *[0-9a-f]*: fc 0e 12 00 clz lr,lr
11324 + *[0-9a-f]*: e6 02 12 00 clz r2,r3
11325 + *[0-9a-f]*: f6 05 12 00 clz r5,r11
11326 + *[0-9a-f]*: e6 0f 12 00 clz pc,r3
11327 +
11328 +[0-9a-f]* <cpc1>:
11329 + *[0-9a-f]*: fe 0f 13 00 cpc pc,pc
11330 + *[0-9a-f]*: f8 0c 13 00 cpc r12,r12
11331 + *[0-9a-f]*: ea 05 13 00 cpc r5,r5
11332 + *[0-9a-f]*: e8 04 13 00 cpc r4,r4
11333 + *[0-9a-f]*: fc 0e 13 00 cpc lr,lr
11334 + *[0-9a-f]*: e8 0f 13 00 cpc pc,r4
11335 + *[0-9a-f]*: f2 05 13 00 cpc r5,r9
11336 + *[0-9a-f]*: ee 06 13 00 cpc r6,r7
11337 +
11338 +[0-9a-f]* <asr3>:
11339 + *[0-9a-f]*: fe 0f 14 00 asr pc,pc,0x0
11340 + *[0-9a-f]*: f8 0c 14 1f asr r12,r12,0x1f
11341 + *[0-9a-f]*: ea 05 14 10 asr r5,r5,0x10
11342 + *[0-9a-f]*: e8 04 14 0f asr r4,r4,0xf
11343 + *[0-9a-f]*: fc 0e 14 01 asr lr,lr,0x1
11344 + *[0-9a-f]*: f6 04 14 13 asr r4,r11,0x13
11345 + *[0-9a-f]*: fe 0d 14 1a asr sp,pc,0x1a
11346 + *[0-9a-f]*: fa 0b 14 08 asr r11,sp,0x8
11347 +
11348 +[0-9a-f]* <lsl3>:
11349 + *[0-9a-f]*: fe 0f 15 00 lsl pc,pc,0x0
11350 + *[0-9a-f]*: f8 0c 15 1f lsl r12,r12,0x1f
11351 + *[0-9a-f]*: ea 05 15 10 lsl r5,r5,0x10
11352 + *[0-9a-f]*: e8 04 15 0f lsl r4,r4,0xf
11353 + *[0-9a-f]*: fc 0e 15 01 lsl lr,lr,0x1
11354 + *[0-9a-f]*: f4 08 15 11 lsl r8,r10,0x11
11355 + *[0-9a-f]*: fc 02 15 03 lsl r2,lr,0x3
11356 + *[0-9a-f]*: f6 0e 15 0e lsl lr,r11,0xe
11357 +
11358 +[0-9a-f]* <lsr3>:
11359 + *[0-9a-f]*: fe 0f 16 00 lsr pc,pc,0x0
11360 + *[0-9a-f]*: f8 0c 16 1f lsr r12,r12,0x1f
11361 + *[0-9a-f]*: ea 05 16 10 lsr r5,r5,0x10
11362 + *[0-9a-f]*: e8 04 16 0f lsr r4,r4,0xf
11363 + *[0-9a-f]*: fc 0e 16 01 lsr lr,lr,0x1
11364 + *[0-9a-f]*: e6 04 16 1f lsr r4,r3,0x1f
11365 + *[0-9a-f]*: f2 0f 16 0e lsr pc,r9,0xe
11366 + *[0-9a-f]*: e0 03 16 06 lsr r3,r0,0x6
11367 +
11368 +[0-9a-f]* <movc1>:
11369 + *[0-9a-f]*: fe 0f 17 00 moveq pc,pc
11370 + *[0-9a-f]*: f8 0c 17 f0 moval r12,r12
11371 + *[0-9a-f]*: ea 05 17 80 movls r5,r5
11372 + *[0-9a-f]*: e8 04 17 70 movpl r4,r4
11373 + *[0-9a-f]*: fc 0e 17 10 movne lr,lr
11374 + *[0-9a-f]*: f6 0f 17 10 movne pc,r11
11375 + *[0-9a-f]*: e4 0a 17 60 movmi r10,r2
11376 + *[0-9a-f]*: f8 08 17 80 movls r8,r12
11377 +
11378 +[0-9a-f]* <padd_h>:
11379 + *[0-9a-f]*: fe 0f 20 0f padd\.h pc,pc,pc
11380 + *[0-9a-f]*: f8 0c 20 0c padd\.h r12,r12,r12
11381 + *[0-9a-f]*: ea 05 20 05 padd\.h r5,r5,r5
11382 + *[0-9a-f]*: e8 04 20 04 padd\.h r4,r4,r4
11383 + *[0-9a-f]*: fc 0e 20 0e padd\.h lr,lr,lr
11384 + *[0-9a-f]*: e4 07 20 08 padd\.h r8,r2,r7
11385 + *[0-9a-f]*: e0 03 20 00 padd\.h r0,r0,r3
11386 + *[0-9a-f]*: f6 06 20 0d padd\.h sp,r11,r6
11387 +
11388 +[0-9a-f]* <psub_h>:
11389 + *[0-9a-f]*: fe 0f 20 1f psub\.h pc,pc,pc
11390 + *[0-9a-f]*: f8 0c 20 1c psub\.h r12,r12,r12
11391 + *[0-9a-f]*: ea 05 20 15 psub\.h r5,r5,r5
11392 + *[0-9a-f]*: e8 04 20 14 psub\.h r4,r4,r4
11393 + *[0-9a-f]*: fc 0e 20 1e psub\.h lr,lr,lr
11394 + *[0-9a-f]*: ec 08 20 1e psub\.h lr,r6,r8
11395 + *[0-9a-f]*: e2 0d 20 10 psub\.h r0,r1,sp
11396 + *[0-9a-f]*: fe 0d 20 1f psub\.h pc,pc,sp
11397 +
11398 +[0-9a-f]* <paddx_h>:
11399 + *[0-9a-f]*: fe 0f 20 2f paddx\.h pc,pc,pc
11400 + *[0-9a-f]*: f8 0c 20 2c paddx\.h r12,r12,r12
11401 + *[0-9a-f]*: ea 05 20 25 paddx\.h r5,r5,r5
11402 + *[0-9a-f]*: e8 04 20 24 paddx\.h r4,r4,r4
11403 + *[0-9a-f]*: fc 0e 20 2e paddx\.h lr,lr,lr
11404 + *[0-9a-f]*: fe 01 20 2f paddx\.h pc,pc,r1
11405 + *[0-9a-f]*: e8 05 20 2a paddx\.h r10,r4,r5
11406 + *[0-9a-f]*: fe 02 20 25 paddx\.h r5,pc,r2
11407 +
11408 +[0-9a-f]* <psubx_h>:
11409 + *[0-9a-f]*: fe 0f 20 3f psubx\.h pc,pc,pc
11410 + *[0-9a-f]*: f8 0c 20 3c psubx\.h r12,r12,r12
11411 + *[0-9a-f]*: ea 05 20 35 psubx\.h r5,r5,r5
11412 + *[0-9a-f]*: e8 04 20 34 psubx\.h r4,r4,r4
11413 + *[0-9a-f]*: fc 0e 20 3e psubx\.h lr,lr,lr
11414 + *[0-9a-f]*: f8 05 20 35 psubx\.h r5,r12,r5
11415 + *[0-9a-f]*: f0 03 20 33 psubx\.h r3,r8,r3
11416 + *[0-9a-f]*: e4 03 20 35 psubx\.h r5,r2,r3
11417 +
11418 +[0-9a-f]* <padds_sh>:
11419 + *[0-9a-f]*: fe 0f 20 4f padds\.sh pc,pc,pc
11420 + *[0-9a-f]*: f8 0c 20 4c padds\.sh r12,r12,r12
11421 + *[0-9a-f]*: ea 05 20 45 padds\.sh r5,r5,r5
11422 + *[0-9a-f]*: e8 04 20 44 padds\.sh r4,r4,r4
11423 + *[0-9a-f]*: fc 0e 20 4e padds\.sh lr,lr,lr
11424 + *[0-9a-f]*: fc 02 20 49 padds\.sh r9,lr,r2
11425 + *[0-9a-f]*: f0 01 20 46 padds\.sh r6,r8,r1
11426 + *[0-9a-f]*: e8 0a 20 46 padds\.sh r6,r4,r10
11427 +
11428 +[0-9a-f]* <psubs_sh>:
11429 + *[0-9a-f]*: fe 0f 20 5f psubs\.sh pc,pc,pc
11430 + *[0-9a-f]*: f8 0c 20 5c psubs\.sh r12,r12,r12
11431 + *[0-9a-f]*: ea 05 20 55 psubs\.sh r5,r5,r5
11432 + *[0-9a-f]*: e8 04 20 54 psubs\.sh r4,r4,r4
11433 + *[0-9a-f]*: fc 0e 20 5e psubs\.sh lr,lr,lr
11434 + *[0-9a-f]*: fc 0b 20 56 psubs\.sh r6,lr,r11
11435 + *[0-9a-f]*: f8 04 20 52 psubs\.sh r2,r12,r4
11436 + *[0-9a-f]*: f2 00 20 50 psubs\.sh r0,r9,r0
11437 +
11438 +[0-9a-f]* <paddxs_sh>:
11439 + *[0-9a-f]*: fe 0f 20 6f paddxs\.sh pc,pc,pc
11440 + *[0-9a-f]*: f8 0c 20 6c paddxs\.sh r12,r12,r12
11441 + *[0-9a-f]*: ea 05 20 65 paddxs\.sh r5,r5,r5
11442 + *[0-9a-f]*: e8 04 20 64 paddxs\.sh r4,r4,r4
11443 + *[0-9a-f]*: fc 0e 20 6e paddxs\.sh lr,lr,lr
11444 + *[0-9a-f]*: e6 09 20 60 paddxs\.sh r0,r3,r9
11445 + *[0-9a-f]*: f4 0b 20 6f paddxs\.sh pc,r10,r11
11446 + *[0-9a-f]*: f4 0f 20 6f paddxs\.sh pc,r10,pc
11447 +
11448 +[0-9a-f]* <psubxs_sh>:
11449 + *[0-9a-f]*: fe 0f 20 7f psubxs\.sh pc,pc,pc
11450 + *[0-9a-f]*: f8 0c 20 7c psubxs\.sh r12,r12,r12
11451 + *[0-9a-f]*: ea 05 20 75 psubxs\.sh r5,r5,r5
11452 + *[0-9a-f]*: e8 04 20 74 psubxs\.sh r4,r4,r4
11453 + *[0-9a-f]*: fc 0e 20 7e psubxs\.sh lr,lr,lr
11454 + *[0-9a-f]*: e8 04 20 77 psubxs\.sh r7,r4,r4
11455 + *[0-9a-f]*: f0 03 20 77 psubxs\.sh r7,r8,r3
11456 + *[0-9a-f]*: ec 05 20 7f psubxs\.sh pc,r6,r5
11457 +
11458 +[0-9a-f]* <padds_uh>:
11459 + *[0-9a-f]*: fe 0f 20 8f padds\.uh pc,pc,pc
11460 + *[0-9a-f]*: f8 0c 20 8c padds\.uh r12,r12,r12
11461 + *[0-9a-f]*: ea 05 20 85 padds\.uh r5,r5,r5
11462 + *[0-9a-f]*: e8 04 20 84 padds\.uh r4,r4,r4
11463 + *[0-9a-f]*: fc 0e 20 8e padds\.uh lr,lr,lr
11464 + *[0-9a-f]*: f6 07 20 8c padds\.uh r12,r11,r7
11465 + *[0-9a-f]*: f0 0e 20 87 padds\.uh r7,r8,lr
11466 + *[0-9a-f]*: f2 07 20 86 padds\.uh r6,r9,r7
11467 +
11468 +[0-9a-f]* <psubs_uh>:
11469 + *[0-9a-f]*: fe 0f 20 9f psubs\.uh pc,pc,pc
11470 + *[0-9a-f]*: f8 0c 20 9c psubs\.uh r12,r12,r12
11471 + *[0-9a-f]*: ea 05 20 95 psubs\.uh r5,r5,r5
11472 + *[0-9a-f]*: e8 04 20 94 psubs\.uh r4,r4,r4
11473 + *[0-9a-f]*: fc 0e 20 9e psubs\.uh lr,lr,lr
11474 + *[0-9a-f]*: f4 06 20 9e psubs\.uh lr,r10,r6
11475 + *[0-9a-f]*: e4 0f 20 9d psubs\.uh sp,r2,pc
11476 + *[0-9a-f]*: f2 02 20 92 psubs\.uh r2,r9,r2
11477 +
11478 +[0-9a-f]* <paddxs_uh>:
11479 + *[0-9a-f]*: fe 0f 20 af paddxs\.uh pc,pc,pc
11480 + *[0-9a-f]*: f8 0c 20 ac paddxs\.uh r12,r12,r12
11481 + *[0-9a-f]*: ea 05 20 a5 paddxs\.uh r5,r5,r5
11482 + *[0-9a-f]*: e8 04 20 a4 paddxs\.uh r4,r4,r4
11483 + *[0-9a-f]*: fc 0e 20 ae paddxs\.uh lr,lr,lr
11484 + *[0-9a-f]*: f2 05 20 a7 paddxs\.uh r7,r9,r5
11485 + *[0-9a-f]*: e2 04 20 a9 paddxs\.uh r9,r1,r4
11486 + *[0-9a-f]*: e4 03 20 a5 paddxs\.uh r5,r2,r3
11487 +
11488 +[0-9a-f]* <psubxs_uh>:
11489 + *[0-9a-f]*: fe 0f 20 bf psubxs\.uh pc,pc,pc
11490 + *[0-9a-f]*: f8 0c 20 bc psubxs\.uh r12,r12,r12
11491 + *[0-9a-f]*: ea 05 20 b5 psubxs\.uh r5,r5,r5
11492 + *[0-9a-f]*: e8 04 20 b4 psubxs\.uh r4,r4,r4
11493 + *[0-9a-f]*: fc 0e 20 be psubxs\.uh lr,lr,lr
11494 + *[0-9a-f]*: ea 0d 20 bd psubxs\.uh sp,r5,sp
11495 + *[0-9a-f]*: ec 06 20 bd psubxs\.uh sp,r6,r6
11496 + *[0-9a-f]*: f6 08 20 b3 psubxs\.uh r3,r11,r8
11497 +
11498 +[0-9a-f]* <paddh_sh>:
11499 + *[0-9a-f]*: fe 0f 20 cf paddh\.sh pc,pc,pc
11500 + *[0-9a-f]*: f8 0c 20 cc paddh\.sh r12,r12,r12
11501 + *[0-9a-f]*: ea 05 20 c5 paddh\.sh r5,r5,r5
11502 + *[0-9a-f]*: e8 04 20 c4 paddh\.sh r4,r4,r4
11503 + *[0-9a-f]*: fc 0e 20 ce paddh\.sh lr,lr,lr
11504 + *[0-9a-f]*: fa 03 20 cc paddh\.sh r12,sp,r3
11505 + *[0-9a-f]*: ea 03 20 cf paddh\.sh pc,r5,r3
11506 + *[0-9a-f]*: f0 0d 20 c8 paddh\.sh r8,r8,sp
11507 +
11508 +[0-9a-f]* <psubh_sh>:
11509 + *[0-9a-f]*: fe 0f 20 df psubh\.sh pc,pc,pc
11510 + *[0-9a-f]*: f8 0c 20 dc psubh\.sh r12,r12,r12
11511 + *[0-9a-f]*: ea 05 20 d5 psubh\.sh r5,r5,r5
11512 + *[0-9a-f]*: e8 04 20 d4 psubh\.sh r4,r4,r4
11513 + *[0-9a-f]*: fc 0e 20 de psubh\.sh lr,lr,lr
11514 + *[0-9a-f]*: ea 08 20 d1 psubh\.sh r1,r5,r8
11515 + *[0-9a-f]*: e6 06 20 d7 psubh\.sh r7,r3,r6
11516 + *[0-9a-f]*: e6 03 20 d4 psubh\.sh r4,r3,r3
11517 +
11518 +[0-9a-f]* <paddxh_sh>:
11519 + *[0-9a-f]*: fe 0f 20 ef paddxh\.sh pc,pc,pc
11520 + *[0-9a-f]*: f8 0c 20 ec paddxh\.sh r12,r12,r12
11521 + *[0-9a-f]*: ea 05 20 e5 paddxh\.sh r5,r5,r5
11522 + *[0-9a-f]*: e8 04 20 e4 paddxh\.sh r4,r4,r4
11523 + *[0-9a-f]*: fc 0e 20 ee paddxh\.sh lr,lr,lr
11524 + *[0-9a-f]*: e0 04 20 e6 paddxh\.sh r6,r0,r4
11525 + *[0-9a-f]*: f0 09 20 e9 paddxh\.sh r9,r8,r9
11526 + *[0-9a-f]*: e0 0d 20 e3 paddxh\.sh r3,r0,sp
11527 +
11528 +[0-9a-f]* <psubxh_sh>:
11529 + *[0-9a-f]*: fe 0f 20 ff psubxh\.sh pc,pc,pc
11530 + *[0-9a-f]*: f8 0c 20 fc psubxh\.sh r12,r12,r12
11531 + *[0-9a-f]*: ea 05 20 f5 psubxh\.sh r5,r5,r5
11532 + *[0-9a-f]*: e8 04 20 f4 psubxh\.sh r4,r4,r4
11533 + *[0-9a-f]*: fc 0e 20 fe psubxh\.sh lr,lr,lr
11534 + *[0-9a-f]*: fe 0c 20 f4 psubxh\.sh r4,pc,r12
11535 + *[0-9a-f]*: e8 06 20 f8 psubxh\.sh r8,r4,r6
11536 + *[0-9a-f]*: f2 04 20 fc psubxh\.sh r12,r9,r4
11537 +
11538 +[0-9a-f]* <paddsub_h>:
11539 + *[0-9a-f]*: fe 0f 21 0f paddsub\.h pc,pc:b,pc:b
11540 + *[0-9a-f]*: f8 0c 21 3c paddsub\.h r12,r12:t,r12:t
11541 + *[0-9a-f]*: ea 05 21 35 paddsub\.h r5,r5:t,r5:t
11542 + *[0-9a-f]*: e8 04 21 04 paddsub\.h r4,r4:b,r4:b
11543 + *[0-9a-f]*: fc 0e 21 3e paddsub\.h lr,lr:t,lr:t
11544 + *[0-9a-f]*: e4 0e 21 25 paddsub\.h r5,r2:t,lr:b
11545 + *[0-9a-f]*: e2 08 21 07 paddsub\.h r7,r1:b,r8:b
11546 + *[0-9a-f]*: f4 05 21 36 paddsub\.h r6,r10:t,r5:t
11547 +
11548 +[0-9a-f]* <psubadd_h>:
11549 + *[0-9a-f]*: fe 0f 21 4f psubadd\.h pc,pc:b,pc:b
11550 + *[0-9a-f]*: f8 0c 21 7c psubadd\.h r12,r12:t,r12:t
11551 + *[0-9a-f]*: ea 05 21 75 psubadd\.h r5,r5:t,r5:t
11552 + *[0-9a-f]*: e8 04 21 44 psubadd\.h r4,r4:b,r4:b
11553 + *[0-9a-f]*: fc 0e 21 7e psubadd\.h lr,lr:t,lr:t
11554 + *[0-9a-f]*: f6 08 21 79 psubadd\.h r9,r11:t,r8:t
11555 + *[0-9a-f]*: ee 0e 21 7a psubadd\.h r10,r7:t,lr:t
11556 + *[0-9a-f]*: fe 0f 21 66 psubadd\.h r6,pc:t,pc:b
11557 +
11558 +[0-9a-f]* <paddsubs_sh>:
11559 + *[0-9a-f]*: fe 0f 21 8f paddsubs\.sh pc,pc:b,pc:b
11560 + *[0-9a-f]*: f8 0c 21 bc paddsubs\.sh r12,r12:t,r12:t
11561 + *[0-9a-f]*: ea 05 21 b5 paddsubs\.sh r5,r5:t,r5:t
11562 + *[0-9a-f]*: e8 04 21 84 paddsubs\.sh r4,r4:b,r4:b
11563 + *[0-9a-f]*: fc 0e 21 be paddsubs\.sh lr,lr:t,lr:t
11564 + *[0-9a-f]*: fc 00 21 a0 paddsubs\.sh r0,lr:t,r0:b
11565 + *[0-9a-f]*: e4 04 21 b9 paddsubs\.sh r9,r2:t,r4:t
11566 + *[0-9a-f]*: f2 0d 21 bc paddsubs\.sh r12,r9:t,sp:t
11567 +
11568 +[0-9a-f]* <psubadds_sh>:
11569 + *[0-9a-f]*: fe 0f 21 cf psubadds\.sh pc,pc:b,pc:b
11570 + *[0-9a-f]*: f8 0c 21 fc psubadds\.sh r12,r12:t,r12:t
11571 + *[0-9a-f]*: ea 05 21 f5 psubadds\.sh r5,r5:t,r5:t
11572 + *[0-9a-f]*: e8 04 21 c4 psubadds\.sh r4,r4:b,r4:b
11573 + *[0-9a-f]*: fc 0e 21 fe psubadds\.sh lr,lr:t,lr:t
11574 + *[0-9a-f]*: fc 01 21 df psubadds\.sh pc,lr:b,r1:t
11575 + *[0-9a-f]*: e6 0c 21 cb psubadds\.sh r11,r3:b,r12:b
11576 + *[0-9a-f]*: e4 08 21 fa psubadds\.sh r10,r2:t,r8:t
11577 +
11578 +[0-9a-f]* <paddsubs_uh>:
11579 + *[0-9a-f]*: fe 0f 22 0f paddsubs\.uh pc,pc:b,pc:b
11580 + *[0-9a-f]*: f8 0c 22 3c paddsubs\.uh r12,r12:t,r12:t
11581 + *[0-9a-f]*: ea 05 22 35 paddsubs\.uh r5,r5:t,r5:t
11582 + *[0-9a-f]*: e8 04 22 04 paddsubs\.uh r4,r4:b,r4:b
11583 + *[0-9a-f]*: fc 0e 22 3e paddsubs\.uh lr,lr:t,lr:t
11584 + *[0-9a-f]*: e4 03 22 09 paddsubs\.uh r9,r2:b,r3:b
11585 + *[0-9a-f]*: fa 07 22 1d paddsubs\.uh sp,sp:b,r7:t
11586 + *[0-9a-f]*: e0 0a 22 1e paddsubs\.uh lr,r0:b,r10:t
11587 +
11588 +[0-9a-f]* <psubadds_uh>:
11589 + *[0-9a-f]*: fe 0f 22 4f psubadds\.uh pc,pc:b,pc:b
11590 + *[0-9a-f]*: f8 0c 22 7c psubadds\.uh r12,r12:t,r12:t
11591 + *[0-9a-f]*: ea 05 22 75 psubadds\.uh r5,r5:t,r5:t
11592 + *[0-9a-f]*: e8 04 22 44 psubadds\.uh r4,r4:b,r4:b
11593 + *[0-9a-f]*: fc 0e 22 7e psubadds\.uh lr,lr:t,lr:t
11594 + *[0-9a-f]*: f2 0f 22 7c psubadds\.uh r12,r9:t,pc:t
11595 + *[0-9a-f]*: ec 08 22 48 psubadds\.uh r8,r6:b,r8:b
11596 + *[0-9a-f]*: f0 04 22 48 psubadds\.uh r8,r8:b,r4:b
11597 +
11598 +[0-9a-f]* <paddsubh_sh>:
11599 + *[0-9a-f]*: fe 0f 22 8f paddsubh\.sh pc,pc:b,pc:b
11600 + *[0-9a-f]*: f8 0c 22 bc paddsubh\.sh r12,r12:t,r12:t
11601 + *[0-9a-f]*: ea 05 22 b5 paddsubh\.sh r5,r5:t,r5:t
11602 + *[0-9a-f]*: e8 04 22 84 paddsubh\.sh r4,r4:b,r4:b
11603 + *[0-9a-f]*: fc 0e 22 be paddsubh\.sh lr,lr:t,lr:t
11604 + *[0-9a-f]*: f2 09 22 a8 paddsubh\.sh r8,r9:t,r9:b
11605 + *[0-9a-f]*: fa 01 22 b0 paddsubh\.sh r0,sp:t,r1:t
11606 + *[0-9a-f]*: e2 00 22 93 paddsubh\.sh r3,r1:b,r0:t
11607 +
11608 +[0-9a-f]* <psubaddh_sh>:
11609 + *[0-9a-f]*: fe 0f 22 cf psubaddh\.sh pc,pc:b,pc:b
11610 + *[0-9a-f]*: f8 0c 22 fc psubaddh\.sh r12,r12:t,r12:t
11611 + *[0-9a-f]*: ea 05 22 f5 psubaddh\.sh r5,r5:t,r5:t
11612 + *[0-9a-f]*: e8 04 22 c4 psubaddh\.sh r4,r4:b,r4:b
11613 + *[0-9a-f]*: fc 0e 22 fe psubaddh\.sh lr,lr:t,lr:t
11614 + *[0-9a-f]*: e6 0a 22 e7 psubaddh\.sh r7,r3:t,r10:b
11615 + *[0-9a-f]*: e4 01 22 f7 psubaddh\.sh r7,r2:t,r1:t
11616 + *[0-9a-f]*: e6 06 22 cb psubaddh\.sh r11,r3:b,r6:b
11617 +
11618 +[0-9a-f]* <padd_b>:
11619 + *[0-9a-f]*: fe 0f 23 0f padd\.b pc,pc,pc
11620 + *[0-9a-f]*: f8 0c 23 0c padd\.b r12,r12,r12
11621 + *[0-9a-f]*: ea 05 23 05 padd\.b r5,r5,r5
11622 + *[0-9a-f]*: e8 04 23 04 padd\.b r4,r4,r4
11623 + *[0-9a-f]*: fc 0e 23 0e padd\.b lr,lr,lr
11624 + *[0-9a-f]*: ec 0f 23 02 padd\.b r2,r6,pc
11625 + *[0-9a-f]*: f2 0c 23 08 padd\.b r8,r9,r12
11626 + *[0-9a-f]*: f8 03 23 05 padd\.b r5,r12,r3
11627 +
11628 +[0-9a-f]* <psub_b>:
11629 + *[0-9a-f]*: fe 0f 23 1f psub\.b pc,pc,pc
11630 + *[0-9a-f]*: f8 0c 23 1c psub\.b r12,r12,r12
11631 + *[0-9a-f]*: ea 05 23 15 psub\.b r5,r5,r5
11632 + *[0-9a-f]*: e8 04 23 14 psub\.b r4,r4,r4
11633 + *[0-9a-f]*: fc 0e 23 1e psub\.b lr,lr,lr
11634 + *[0-9a-f]*: f8 0f 23 10 psub\.b r0,r12,pc
11635 + *[0-9a-f]*: fa 0a 23 17 psub\.b r7,sp,r10
11636 + *[0-9a-f]*: fa 0c 23 15 psub\.b r5,sp,r12
11637 +
11638 +[0-9a-f]* <padds_sb>:
11639 + *[0-9a-f]*: fe 0f 23 2f padds\.sb pc,pc,pc
11640 + *[0-9a-f]*: f8 0c 23 2c padds\.sb r12,r12,r12
11641 + *[0-9a-f]*: ea 05 23 25 padds\.sb r5,r5,r5
11642 + *[0-9a-f]*: e8 04 23 24 padds\.sb r4,r4,r4
11643 + *[0-9a-f]*: fc 0e 23 2e padds\.sb lr,lr,lr
11644 + *[0-9a-f]*: f6 04 23 2d padds\.sb sp,r11,r4
11645 + *[0-9a-f]*: f4 0b 23 2b padds\.sb r11,r10,r11
11646 + *[0-9a-f]*: f8 06 23 25 padds\.sb r5,r12,r6
11647 +
11648 +[0-9a-f]* <psubs_sb>:
11649 + *[0-9a-f]*: fe 0f 23 3f psubs\.sb pc,pc,pc
11650 + *[0-9a-f]*: f8 0c 23 3c psubs\.sb r12,r12,r12
11651 + *[0-9a-f]*: ea 05 23 35 psubs\.sb r5,r5,r5
11652 + *[0-9a-f]*: e8 04 23 34 psubs\.sb r4,r4,r4
11653 + *[0-9a-f]*: fc 0e 23 3e psubs\.sb lr,lr,lr
11654 + *[0-9a-f]*: ec 08 23 37 psubs\.sb r7,r6,r8
11655 + *[0-9a-f]*: f4 09 23 3c psubs\.sb r12,r10,r9
11656 + *[0-9a-f]*: f6 00 23 3f psubs\.sb pc,r11,r0
11657 +
11658 +[0-9a-f]* <padds_ub>:
11659 + *[0-9a-f]*: fe 0f 23 4f padds\.ub pc,pc,pc
11660 + *[0-9a-f]*: f8 0c 23 4c padds\.ub r12,r12,r12
11661 + *[0-9a-f]*: ea 05 23 45 padds\.ub r5,r5,r5
11662 + *[0-9a-f]*: e8 04 23 44 padds\.ub r4,r4,r4
11663 + *[0-9a-f]*: fc 0e 23 4e padds\.ub lr,lr,lr
11664 + *[0-9a-f]*: e4 0b 23 43 padds\.ub r3,r2,r11
11665 + *[0-9a-f]*: f0 01 23 4a padds\.ub r10,r8,r1
11666 + *[0-9a-f]*: f0 0a 23 4b padds\.ub r11,r8,r10
11667 +
11668 +[0-9a-f]* <psubs_ub>:
11669 + *[0-9a-f]*: fe 0f 23 5f psubs\.ub pc,pc,pc
11670 + *[0-9a-f]*: f8 0c 23 5c psubs\.ub r12,r12,r12
11671 + *[0-9a-f]*: ea 05 23 55 psubs\.ub r5,r5,r5
11672 + *[0-9a-f]*: e8 04 23 54 psubs\.ub r4,r4,r4
11673 + *[0-9a-f]*: fc 0e 23 5e psubs\.ub lr,lr,lr
11674 + *[0-9a-f]*: e4 07 23 50 psubs\.ub r0,r2,r7
11675 + *[0-9a-f]*: ea 03 23 5e psubs\.ub lr,r5,r3
11676 + *[0-9a-f]*: ee 09 23 56 psubs\.ub r6,r7,r9
11677 +
11678 +[0-9a-f]* <paddh_ub>:
11679 + *[0-9a-f]*: fe 0f 23 6f paddh\.ub pc,pc,pc
11680 + *[0-9a-f]*: f8 0c 23 6c paddh\.ub r12,r12,r12
11681 + *[0-9a-f]*: ea 05 23 65 paddh\.ub r5,r5,r5
11682 + *[0-9a-f]*: e8 04 23 64 paddh\.ub r4,r4,r4
11683 + *[0-9a-f]*: fc 0e 23 6e paddh\.ub lr,lr,lr
11684 + *[0-9a-f]*: e2 00 23 6e paddh\.ub lr,r1,r0
11685 + *[0-9a-f]*: ee 07 23 62 paddh\.ub r2,r7,r7
11686 + *[0-9a-f]*: e2 02 23 62 paddh\.ub r2,r1,r2
11687 +
11688 +[0-9a-f]* <psubh_ub>:
11689 + *[0-9a-f]*: fe 0f 23 7f psubh\.ub pc,pc,pc
11690 + *[0-9a-f]*: f8 0c 23 7c psubh\.ub r12,r12,r12
11691 + *[0-9a-f]*: ea 05 23 75 psubh\.ub r5,r5,r5
11692 + *[0-9a-f]*: e8 04 23 74 psubh\.ub r4,r4,r4
11693 + *[0-9a-f]*: fc 0e 23 7e psubh\.ub lr,lr,lr
11694 + *[0-9a-f]*: e2 06 23 70 psubh\.ub r0,r1,r6
11695 + *[0-9a-f]*: fc 0a 23 74 psubh\.ub r4,lr,r10
11696 + *[0-9a-f]*: f0 01 23 79 psubh\.ub r9,r8,r1
11697 +
11698 +[0-9a-f]* <pmax_ub>:
11699 + *[0-9a-f]*: fe 0f 23 8f pmax\.ub pc,pc,pc
11700 + *[0-9a-f]*: f8 0c 23 8c pmax\.ub r12,r12,r12
11701 + *[0-9a-f]*: ea 05 23 85 pmax\.ub r5,r5,r5
11702 + *[0-9a-f]*: e8 04 23 84 pmax\.ub r4,r4,r4
11703 + *[0-9a-f]*: fc 0e 23 8e pmax\.ub lr,lr,lr
11704 + *[0-9a-f]*: e4 0b 23 8f pmax\.ub pc,r2,r11
11705 + *[0-9a-f]*: e2 01 23 8c pmax\.ub r12,r1,r1
11706 + *[0-9a-f]*: e4 00 23 85 pmax\.ub r5,r2,r0
11707 +
11708 +[0-9a-f]* <pmax_sh>:
11709 + *[0-9a-f]*: fe 0f 23 9f pmax\.sh pc,pc,pc
11710 + *[0-9a-f]*: f8 0c 23 9c pmax\.sh r12,r12,r12
11711 + *[0-9a-f]*: ea 05 23 95 pmax\.sh r5,r5,r5
11712 + *[0-9a-f]*: e8 04 23 94 pmax\.sh r4,r4,r4
11713 + *[0-9a-f]*: fc 0e 23 9e pmax\.sh lr,lr,lr
11714 + *[0-9a-f]*: ec 0c 23 9e pmax\.sh lr,r6,r12
11715 + *[0-9a-f]*: fe 05 23 92 pmax\.sh r2,pc,r5
11716 + *[0-9a-f]*: e4 07 23 9f pmax\.sh pc,r2,r7
11717 +
11718 +[0-9a-f]* <pmin_ub>:
11719 + *[0-9a-f]*: fe 0f 23 af pmin\.ub pc,pc,pc
11720 + *[0-9a-f]*: f8 0c 23 ac pmin\.ub r12,r12,r12
11721 + *[0-9a-f]*: ea 05 23 a5 pmin\.ub r5,r5,r5
11722 + *[0-9a-f]*: e8 04 23 a4 pmin\.ub r4,r4,r4
11723 + *[0-9a-f]*: fc 0e 23 ae pmin\.ub lr,lr,lr
11724 + *[0-9a-f]*: e2 05 23 a8 pmin\.ub r8,r1,r5
11725 + *[0-9a-f]*: f0 03 23 a1 pmin\.ub r1,r8,r3
11726 + *[0-9a-f]*: e4 07 23 a0 pmin\.ub r0,r2,r7
11727 +
11728 +[0-9a-f]* <pmin_sh>:
11729 + *[0-9a-f]*: fe 0f 23 bf pmin\.sh pc,pc,pc
11730 + *[0-9a-f]*: f8 0c 23 bc pmin\.sh r12,r12,r12
11731 + *[0-9a-f]*: ea 05 23 b5 pmin\.sh r5,r5,r5
11732 + *[0-9a-f]*: e8 04 23 b4 pmin\.sh r4,r4,r4
11733 + *[0-9a-f]*: fc 0e 23 be pmin\.sh lr,lr,lr
11734 + *[0-9a-f]*: e8 0a 23 b8 pmin\.sh r8,r4,r10
11735 + *[0-9a-f]*: f4 0c 23 be pmin\.sh lr,r10,r12
11736 + *[0-9a-f]*: ec 02 23 b2 pmin\.sh r2,r6,r2
11737 +
11738 +[0-9a-f]* <pavg_ub>:
11739 + *[0-9a-f]*: fe 0f 23 cf pavg\.ub pc,pc,pc
11740 + *[0-9a-f]*: f8 0c 23 cc pavg\.ub r12,r12,r12
11741 + *[0-9a-f]*: ea 05 23 c5 pavg\.ub r5,r5,r5
11742 + *[0-9a-f]*: e8 04 23 c4 pavg\.ub r4,r4,r4
11743 + *[0-9a-f]*: fc 0e 23 ce pavg\.ub lr,lr,lr
11744 + *[0-9a-f]*: e2 06 23 c0 pavg\.ub r0,r1,r6
11745 + *[0-9a-f]*: e6 06 23 c8 pavg\.ub r8,r3,r6
11746 + *[0-9a-f]*: f8 0a 23 cf pavg\.ub pc,r12,r10
11747 +
11748 +[0-9a-f]* <pavg_sh>:
11749 + *[0-9a-f]*: fe 0f 23 df pavg\.sh pc,pc,pc
11750 + *[0-9a-f]*: f8 0c 23 dc pavg\.sh r12,r12,r12
11751 + *[0-9a-f]*: ea 05 23 d5 pavg\.sh r5,r5,r5
11752 + *[0-9a-f]*: e8 04 23 d4 pavg\.sh r4,r4,r4
11753 + *[0-9a-f]*: fc 0e 23 de pavg\.sh lr,lr,lr
11754 + *[0-9a-f]*: fe 0d 23 d9 pavg\.sh r9,pc,sp
11755 + *[0-9a-f]*: fa 03 23 df pavg\.sh pc,sp,r3
11756 + *[0-9a-f]*: e2 09 23 d6 pavg\.sh r6,r1,r9
11757 +
11758 +[0-9a-f]* <pabs_sb>:
11759 + *[0-9a-f]*: e0 0f 23 ef pabs\.sb pc,pc
11760 + *[0-9a-f]*: e0 0c 23 ec pabs\.sb r12,r12
11761 + *[0-9a-f]*: e0 05 23 e5 pabs\.sb r5,r5
11762 + *[0-9a-f]*: e0 04 23 e4 pabs\.sb r4,r4
11763 + *[0-9a-f]*: e0 0e 23 ee pabs\.sb lr,lr
11764 + *[0-9a-f]*: e0 06 23 eb pabs\.sb r11,r6
11765 + *[0-9a-f]*: e0 09 23 ee pabs\.sb lr,r9
11766 + *[0-9a-f]*: e0 07 23 ed pabs\.sb sp,r7
11767 +
11768 +[0-9a-f]* <pabs_sh>:
11769 + *[0-9a-f]*: e0 0f 23 ff pabs\.sh pc,pc
11770 + *[0-9a-f]*: e0 0c 23 fc pabs\.sh r12,r12
11771 + *[0-9a-f]*: e0 05 23 f5 pabs\.sh r5,r5
11772 + *[0-9a-f]*: e0 04 23 f4 pabs\.sh r4,r4
11773 + *[0-9a-f]*: e0 0e 23 fe pabs\.sh lr,lr
11774 + *[0-9a-f]*: e0 03 23 ff pabs\.sh pc,r3
11775 + *[0-9a-f]*: e0 07 23 f5 pabs\.sh r5,r7
11776 + *[0-9a-f]*: e0 00 23 f4 pabs\.sh r4,r0
11777 +
11778 +[0-9a-f]* <psad>:
11779 + *[0-9a-f]*: fe 0f 24 0f psad pc,pc,pc
11780 + *[0-9a-f]*: f8 0c 24 0c psad r12,r12,r12
11781 + *[0-9a-f]*: ea 05 24 05 psad r5,r5,r5
11782 + *[0-9a-f]*: e8 04 24 04 psad r4,r4,r4
11783 + *[0-9a-f]*: fc 0e 24 0e psad lr,lr,lr
11784 + *[0-9a-f]*: f6 0b 24 09 psad r9,r11,r11
11785 + *[0-9a-f]*: e8 0d 24 0e psad lr,r4,sp
11786 + *[0-9a-f]*: e8 05 24 0e psad lr,r4,r5
11787 +
11788 +[0-9a-f]* <pasr_b>:
11789 + *[0-9a-f]*: fe 00 24 1f pasr\.b pc,pc,0x0
11790 + *[0-9a-f]*: f8 07 24 1c pasr\.b r12,r12,0x7
11791 + *[0-9a-f]*: ea 04 24 15 pasr\.b r5,r5,0x4
11792 + *[0-9a-f]*: e8 03 24 14 pasr\.b r4,r4,0x3
11793 + *[0-9a-f]*: fc 01 24 1e pasr\.b lr,lr,0x1
11794 + *[0-9a-f]*: ee 01 24 1f pasr\.b pc,r7,0x1
11795 + *[0-9a-f]*: fc 06 24 1d pasr\.b sp,lr,0x6
11796 + *[0-9a-f]*: e6 02 24 1d pasr\.b sp,r3,0x2
11797 +
11798 +[0-9a-f]* <plsl_b>:
11799 + *[0-9a-f]*: fe 00 24 2f plsl\.b pc,pc,0x0
11800 + *[0-9a-f]*: f8 07 24 2c plsl\.b r12,r12,0x7
11801 + *[0-9a-f]*: ea 04 24 25 plsl\.b r5,r5,0x4
11802 + *[0-9a-f]*: e8 03 24 24 plsl\.b r4,r4,0x3
11803 + *[0-9a-f]*: fc 01 24 2e plsl\.b lr,lr,0x1
11804 + *[0-9a-f]*: f6 04 24 22 plsl\.b r2,r11,0x4
11805 + *[0-9a-f]*: ea 07 24 28 plsl\.b r8,r5,0x7
11806 + *[0-9a-f]*: e0 02 24 2f plsl\.b pc,r0,0x2
11807 +
11808 +[0-9a-f]* <plsr_b>:
11809 + *[0-9a-f]*: fe 00 24 3f plsr\.b pc,pc,0x0
11810 + *[0-9a-f]*: f8 07 24 3c plsr\.b r12,r12,0x7
11811 + *[0-9a-f]*: ea 04 24 35 plsr\.b r5,r5,0x4
11812 + *[0-9a-f]*: e8 03 24 34 plsr\.b r4,r4,0x3
11813 + *[0-9a-f]*: fc 01 24 3e plsr\.b lr,lr,0x1
11814 + *[0-9a-f]*: e2 02 24 3c plsr\.b r12,r1,0x2
11815 + *[0-9a-f]*: fe 07 24 36 plsr\.b r6,pc,0x7
11816 + *[0-9a-f]*: f6 02 24 3c plsr\.b r12,r11,0x2
11817 +
11818 +[0-9a-f]* <pasr_h>:
11819 + *[0-9a-f]*: fe 00 24 4f pasr\.h pc,pc,0x0
11820 + *[0-9a-f]*: f8 0f 24 4c pasr\.h r12,r12,0xf
11821 + *[0-9a-f]*: ea 08 24 45 pasr\.h r5,r5,0x8
11822 + *[0-9a-f]*: e8 07 24 44 pasr\.h r4,r4,0x7
11823 + *[0-9a-f]*: fc 01 24 4e pasr\.h lr,lr,0x1
11824 + *[0-9a-f]*: f6 0a 24 40 pasr\.h r0,r11,0xa
11825 + *[0-9a-f]*: ec 08 24 44 pasr\.h r4,r6,0x8
11826 + *[0-9a-f]*: e4 04 24 46 pasr\.h r6,r2,0x4
11827 +
11828 +[0-9a-f]* <plsl_h>:
11829 + *[0-9a-f]*: fe 00 24 5f plsl\.h pc,pc,0x0
11830 + *[0-9a-f]*: f8 0f 24 5c plsl\.h r12,r12,0xf
11831 + *[0-9a-f]*: ea 08 24 55 plsl\.h r5,r5,0x8
11832 + *[0-9a-f]*: e8 07 24 54 plsl\.h r4,r4,0x7
11833 + *[0-9a-f]*: fc 01 24 5e plsl\.h lr,lr,0x1
11834 + *[0-9a-f]*: f4 09 24 55 plsl\.h r5,r10,0x9
11835 + *[0-9a-f]*: fc 08 24 5d plsl\.h sp,lr,0x8
11836 + *[0-9a-f]*: fc 07 24 50 plsl\.h r0,lr,0x7
11837 +
11838 +[0-9a-f]* <plsr_h>:
11839 + *[0-9a-f]*: fe 00 24 6f plsr\.h pc,pc,0x0
11840 + *[0-9a-f]*: f8 0f 24 6c plsr\.h r12,r12,0xf
11841 + *[0-9a-f]*: ea 08 24 65 plsr\.h r5,r5,0x8
11842 + *[0-9a-f]*: e8 07 24 64 plsr\.h r4,r4,0x7
11843 + *[0-9a-f]*: fc 01 24 6e plsr\.h lr,lr,0x1
11844 + *[0-9a-f]*: e0 0f 24 6b plsr\.h r11,r0,0xf
11845 + *[0-9a-f]*: e6 03 24 6e plsr\.h lr,r3,0x3
11846 + *[0-9a-f]*: fc 0a 24 68 plsr\.h r8,lr,0xa
11847 +
11848 +[0-9a-f]* <packw_sh>:
11849 + *[0-9a-f]*: fe 0f 24 7f packw\.sh pc,pc,pc
11850 + *[0-9a-f]*: f8 0c 24 7c packw\.sh r12,r12,r12
11851 + *[0-9a-f]*: ea 05 24 75 packw\.sh r5,r5,r5
11852 + *[0-9a-f]*: e8 04 24 74 packw\.sh r4,r4,r4
11853 + *[0-9a-f]*: fc 0e 24 7e packw\.sh lr,lr,lr
11854 + *[0-9a-f]*: f6 0a 24 7d packw\.sh sp,r11,r10
11855 + *[0-9a-f]*: e4 0c 24 78 packw\.sh r8,r2,r12
11856 + *[0-9a-f]*: e2 05 24 78 packw\.sh r8,r1,r5
11857 +
11858 +[0-9a-f]* <punpckub_h>:
11859 + *[0-9a-f]*: fe 00 24 8f punpckub\.h pc,pc:b
11860 + *[0-9a-f]*: f8 00 24 9c punpckub\.h r12,r12:t
11861 + *[0-9a-f]*: ea 00 24 95 punpckub\.h r5,r5:t
11862 + *[0-9a-f]*: e8 00 24 84 punpckub\.h r4,r4:b
11863 + *[0-9a-f]*: fc 00 24 9e punpckub\.h lr,lr:t
11864 + *[0-9a-f]*: e2 00 24 96 punpckub\.h r6,r1:t
11865 + *[0-9a-f]*: ea 00 24 8e punpckub\.h lr,r5:b
11866 + *[0-9a-f]*: e4 00 24 9e punpckub\.h lr,r2:t
11867 +
11868 +[0-9a-f]* <punpcksb_h>:
11869 + *[0-9a-f]*: fe 00 24 af punpcksb\.h pc,pc:b
11870 + *[0-9a-f]*: f8 00 24 bc punpcksb\.h r12,r12:t
11871 + *[0-9a-f]*: ea 00 24 b5 punpcksb\.h r5,r5:t
11872 + *[0-9a-f]*: e8 00 24 a4 punpcksb\.h r4,r4:b
11873 + *[0-9a-f]*: fc 00 24 be punpcksb\.h lr,lr:t
11874 + *[0-9a-f]*: ee 00 24 b4 punpcksb\.h r4,r7:t
11875 + *[0-9a-f]*: fc 00 24 a6 punpcksb\.h r6,lr:b
11876 + *[0-9a-f]*: f8 00 24 bc punpcksb\.h r12,r12:t
11877 +
11878 +[0-9a-f]* <packsh_ub>:
11879 + *[0-9a-f]*: fe 0f 24 cf packsh\.ub pc,pc,pc
11880 + *[0-9a-f]*: f8 0c 24 cc packsh\.ub r12,r12,r12
11881 + *[0-9a-f]*: ea 05 24 c5 packsh\.ub r5,r5,r5
11882 + *[0-9a-f]*: e8 04 24 c4 packsh\.ub r4,r4,r4
11883 + *[0-9a-f]*: fc 0e 24 ce packsh\.ub lr,lr,lr
11884 + *[0-9a-f]*: ec 03 24 c3 packsh\.ub r3,r6,r3
11885 + *[0-9a-f]*: e0 03 24 c8 packsh\.ub r8,r0,r3
11886 + *[0-9a-f]*: e6 0e 24 c9 packsh\.ub r9,r3,lr
11887 +
11888 +[0-9a-f]* <packsh_sb>:
11889 + *[0-9a-f]*: fe 0f 24 df packsh\.sb pc,pc,pc
11890 + *[0-9a-f]*: f8 0c 24 dc packsh\.sb r12,r12,r12
11891 + *[0-9a-f]*: ea 05 24 d5 packsh\.sb r5,r5,r5
11892 + *[0-9a-f]*: e8 04 24 d4 packsh\.sb r4,r4,r4
11893 + *[0-9a-f]*: fc 0e 24 de packsh\.sb lr,lr,lr
11894 + *[0-9a-f]*: f0 01 24 d6 packsh\.sb r6,r8,r1
11895 + *[0-9a-f]*: f2 08 24 de packsh\.sb lr,r9,r8
11896 + *[0-9a-f]*: ec 06 24 dd packsh\.sb sp,r6,r6
11897 +
11898 +[0-9a-f]* <andl>:
11899 + *[0-9a-f]*: e0 1f 00 00 andl pc,0x0
11900 + *[0-9a-f]*: e0 1c ff ff andl r12,0xffff
11901 + *[0-9a-f]*: e0 15 80 00 andl r5,0x8000
11902 + *[0-9a-f]*: e0 14 7f ff andl r4,0x7fff
11903 + *[0-9a-f]*: e0 1e 00 01 andl lr,0x1
11904 + *[0-9a-f]*: e0 1f 5a 58 andl pc,0x5a58
11905 + *[0-9a-f]*: e0 18 b8 9e andl r8,0xb89e
11906 + *[0-9a-f]*: e0 17 35 97 andl r7,0x3597
11907 +
11908 +[0-9a-f]* <andl_coh>:
11909 + *[0-9a-f]*: e2 1f 00 00 andl pc,0x0,COH
11910 + *[0-9a-f]*: e2 1c ff ff andl r12,0xffff,COH
11911 + *[0-9a-f]*: e2 15 80 00 andl r5,0x8000,COH
11912 + *[0-9a-f]*: e2 14 7f ff andl r4,0x7fff,COH
11913 + *[0-9a-f]*: e2 1e 00 01 andl lr,0x1,COH
11914 + *[0-9a-f]*: e2 16 58 e1 andl r6,0x58e1,COH
11915 + *[0-9a-f]*: e2 10 9e cd andl r0,0x9ecd,COH
11916 + *[0-9a-f]*: e2 14 bd c4 andl r4,0xbdc4,COH
11917 +
11918 +[0-9a-f]* <andh>:
11919 + *[0-9a-f]*: e4 1f 00 00 andh pc,0x0
11920 + *[0-9a-f]*: e4 1c ff ff andh r12,0xffff
11921 + *[0-9a-f]*: e4 15 80 00 andh r5,0x8000
11922 + *[0-9a-f]*: e4 14 7f ff andh r4,0x7fff
11923 + *[0-9a-f]*: e4 1e 00 01 andh lr,0x1
11924 + *[0-9a-f]*: e4 1c cc 58 andh r12,0xcc58
11925 + *[0-9a-f]*: e4 13 21 e3 andh r3,0x21e3
11926 + *[0-9a-f]*: e4 12 a7 eb andh r2,0xa7eb
11927 +
11928 +[0-9a-f]* <andh_coh>:
11929 + *[0-9a-f]*: e6 1f 00 00 andh pc,0x0,COH
11930 + *[0-9a-f]*: e6 1c ff ff andh r12,0xffff,COH
11931 + *[0-9a-f]*: e6 15 80 00 andh r5,0x8000,COH
11932 + *[0-9a-f]*: e6 14 7f ff andh r4,0x7fff,COH
11933 + *[0-9a-f]*: e6 1e 00 01 andh lr,0x1,COH
11934 + *[0-9a-f]*: e6 1b 86 0d andh r11,0x860d,COH
11935 + *[0-9a-f]*: e6 18 ce f6 andh r8,0xcef6,COH
11936 + *[0-9a-f]*: e6 1a 5c 83 andh r10,0x5c83,COH
11937 +
11938 +[0-9a-f]* <orl>:
11939 + *[0-9a-f]*: e8 1f 00 00 orl pc,0x0
11940 + *[0-9a-f]*: e8 1c ff ff orl r12,0xffff
11941 + *[0-9a-f]*: e8 15 80 00 orl r5,0x8000
11942 + *[0-9a-f]*: e8 14 7f ff orl r4,0x7fff
11943 + *[0-9a-f]*: e8 1e 00 01 orl lr,0x1
11944 + *[0-9a-f]*: e8 1d 41 7e orl sp,0x417e
11945 + *[0-9a-f]*: e8 10 52 bd orl r0,0x52bd
11946 + *[0-9a-f]*: e8 1f ac 47 orl pc,0xac47
11947 +
11948 +[0-9a-f]* <orh>:
11949 + *[0-9a-f]*: ea 1f 00 00 orh pc,0x0
11950 + *[0-9a-f]*: ea 1c ff ff orh r12,0xffff
11951 + *[0-9a-f]*: ea 15 80 00 orh r5,0x8000
11952 + *[0-9a-f]*: ea 14 7f ff orh r4,0x7fff
11953 + *[0-9a-f]*: ea 1e 00 01 orh lr,0x1
11954 + *[0-9a-f]*: ea 18 6e 7d orh r8,0x6e7d
11955 + *[0-9a-f]*: ea 1c 77 1c orh r12,0x771c
11956 + *[0-9a-f]*: ea 11 ea 1a orh r1,0xea1a
11957 +
11958 +[0-9a-f]* <eorl>:
11959 + *[0-9a-f]*: ec 1f 00 00 eorl pc,0x0
11960 + *[0-9a-f]*: ec 1c ff ff eorl r12,0xffff
11961 + *[0-9a-f]*: ec 15 80 00 eorl r5,0x8000
11962 + *[0-9a-f]*: ec 14 7f ff eorl r4,0x7fff
11963 + *[0-9a-f]*: ec 1e 00 01 eorl lr,0x1
11964 + *[0-9a-f]*: ec 14 c7 b9 eorl r4,0xc7b9
11965 + *[0-9a-f]*: ec 16 fb dd eorl r6,0xfbdd
11966 + *[0-9a-f]*: ec 11 51 b1 eorl r1,0x51b1
11967 +
11968 +[0-9a-f]* <eorh>:
11969 + *[0-9a-f]*: ee 1f 00 00 eorh pc,0x0
11970 + *[0-9a-f]*: ee 1c ff ff eorh r12,0xffff
11971 + *[0-9a-f]*: ee 15 80 00 eorh r5,0x8000
11972 + *[0-9a-f]*: ee 14 7f ff eorh r4,0x7fff
11973 + *[0-9a-f]*: ee 1e 00 01 eorh lr,0x1
11974 + *[0-9a-f]*: ee 10 2d d4 eorh r0,0x2dd4
11975 + *[0-9a-f]*: ee 1a 94 b5 eorh r10,0x94b5
11976 + *[0-9a-f]*: ee 19 df 2a eorh r9,0xdf2a
11977 +
11978 +[0-9a-f]* <mcall>:
11979 + *[0-9a-f]*: f0 1f 00 00 mcall [0-9a-f]* <.*>
11980 + *[0-9a-f]*: f0 1c ff ff mcall r12\[-4\]
11981 + *[0-9a-f]*: f0 15 80 00 mcall r5\[-131072\]
11982 + *[0-9a-f]*: f0 14 7f ff mcall r4\[131068\]
11983 + *[0-9a-f]*: f0 1e 00 01 mcall lr\[4\]
11984 + *[0-9a-f]*: f0 1d 3b bf mcall sp\[61180\]
11985 + *[0-9a-f]*: f0 14 dd d2 mcall r4\[-35000\]
11986 + *[0-9a-f]*: f0 10 09 b1 mcall r0\[9924\]
11987 +
11988 +[0-9a-f]* <pref>:
11989 + *[0-9a-f]*: f2 1f 00 00 pref pc\[0\]
11990 + *[0-9a-f]*: f2 1c ff ff pref r12\[-1\]
11991 + *[0-9a-f]*: f2 15 80 00 pref r5\[-32768\]
11992 + *[0-9a-f]*: f2 14 7f ff pref r4\[32767\]
11993 + *[0-9a-f]*: f2 1e 00 01 pref lr\[1\]
11994 + *[0-9a-f]*: f2 17 1e 44 pref r7\[7748\]
11995 + *[0-9a-f]*: f2 17 e1 ed pref r7\[-7699\]
11996 + *[0-9a-f]*: f2 12 9a dc pref r2\[-25892\]
11997 +
11998 +[0-9a-f]* <cache>:
11999 + *[0-9a-f]*: f4 1f 00 00 cache pc\[0\],0x0
12000 + *[0-9a-f]*: f4 1c ff ff cache r12\[-1\],0x1f
12001 + *[0-9a-f]*: f4 15 84 00 cache r5\[-1024\],0x10
12002 + *[0-9a-f]*: f4 14 7b ff cache r4\[1023\],0xf
12003 + *[0-9a-f]*: f4 1e 08 01 cache lr\[1\],0x1
12004 + *[0-9a-f]*: f4 13 8c 3c cache r3\[-964\],0x11
12005 + *[0-9a-f]*: f4 14 b6 89 cache r4\[-375\],0x16
12006 + *[0-9a-f]*: f4 13 8c 88 cache r3\[-888\],0x11
12007 +
12008 +[0-9a-f]* <sub4>:
12009 + *[0-9a-f]*: 20 0f sub pc,0
12010 + *[0-9a-f]*: 2f fc sub r12,-1
12011 + *[0-9a-f]*: f0 25 00 00 sub r5,-1048576
12012 + *[0-9a-f]*: ee 34 ff ff sub r4,1048575
12013 + *[0-9a-f]*: 20 1e sub lr,1
12014 + *[0-9a-f]*: f6 22 8d 6c sub r2,-619156
12015 + *[0-9a-f]*: e6 3e 0a cd sub lr,461517
12016 + *[0-9a-f]*: fc 38 2d 25 sub r8,-185051
12017 +
12018 +[0-9a-f]* <cp3>:
12019 + *[0-9a-f]*: 58 0f cp.w pc,0
12020 + *[0-9a-f]*: 5b fc cp.w r12,-1
12021 + *[0-9a-f]*: f0 45 00 00 cp.w r5,-1048576
12022 + *[0-9a-f]*: ee 54 ff ff cp.w r4,1048575
12023 + *[0-9a-f]*: 58 1e cp.w lr,1
12024 + *[0-9a-f]*: e0 51 e4 ae cp.w r1,124078
12025 + *[0-9a-f]*: fa 40 37 e3 cp.w r0,-378909
12026 + *[0-9a-f]*: fc 44 4a 14 cp.w r4,-243180
12027 +
12028 +[0-9a-f]* <mov2>:
12029 + *[0-9a-f]*: 30 0f mov pc,0
12030 + *[0-9a-f]*: 3f fc mov r12,-1
12031 + *[0-9a-f]*: f0 65 00 00 mov r5,-1048576
12032 + *[0-9a-f]*: ee 74 ff ff mov r4,1048575
12033 + *[0-9a-f]*: 30 1e mov lr,1
12034 + *[0-9a-f]*: fa 75 29 a3 mov r5,-317021
12035 + *[0-9a-f]*: f4 6d 91 94 mov sp,-749164
12036 + *[0-9a-f]*: ee 65 58 93 mov r5,940179
12037 +
12038 +[0-9a-f]* <brc2>:
12039 + *[0-9a-f]*: c0 00 breq [0-9a-f]* <.*>
12040 + *[0-9a-f]*: fe 9f ff ff bral [0-9a-f]* <.*>
12041 + *[0-9a-f]*: f0 88 00 00 brls [0-9a-f]* <.*>
12042 + *[0-9a-f]*: ee 97 ff ff brpl [0-9a-f]* <.*>
12043 + *[0-9a-f]*: c0 11 brne [0-9a-f]* <.*>
12044 + *[0-9a-f]*: f2 8b 4a 4d brhi [0-9a-f]* <.*>
12045 + *[0-9a-f]*: ea 8e 14 cc brqs [0-9a-f]* <.*>
12046 + *[0-9a-f]*: fa 98 98 33 brls [0-9a-f]* <.*>
12047 +
12048 +[0-9a-f]* <rcall2>:
12049 + *[0-9a-f]*: c0 0c rcall [0-9a-f]* <.*>
12050 + *[0-9a-f]*: cf ff rcall [0-9a-f]* <.*>
12051 + *[0-9a-f]*: f0 a0 00 00 rcall [0-9a-f]* <.*>
12052 + *[0-9a-f]*: ee b0 ff ff rcall [0-9a-f]* <.*>
12053 + *[0-9a-f]*: c0 1c rcall [0-9a-f]* <.*>
12054 + *[0-9a-f]*: e2 b0 ca 5a rcall [0-9a-f]* <.*>
12055 + *[0-9a-f]*: e8 a0 47 52 rcall [0-9a-f]* <.*>
12056 + *[0-9a-f]*: fe b0 fd ef rcall [0-9a-f]* <.*>
12057 +
12058 +[0-9a-f]* <sub5>:
12059 + *[0-9a-f]*: fe cf 00 00 sub pc,pc,0
12060 + *[0-9a-f]*: f8 cc ff ff sub r12,r12,-1
12061 + *[0-9a-f]*: ea c5 80 00 sub r5,r5,-32768
12062 + *[0-9a-f]*: e8 c4 7f ff sub r4,r4,32767
12063 + *[0-9a-f]*: fc ce 00 01 sub lr,lr,1
12064 + *[0-9a-f]*: fe cf ce 38 sub pc,pc,-12744
12065 + *[0-9a-f]*: ee c7 95 1b sub r7,r7,-27365
12066 + *[0-9a-f]*: f2 c2 bc 32 sub r2,r9,-17358
12067 +
12068 +[0-9a-f]* <satsub_w2>:
12069 + *[0-9a-f]*: fe df 00 00 satsub\.w pc,pc,0
12070 + *[0-9a-f]*: f8 dc ff ff satsub\.w r12,r12,-1
12071 + *[0-9a-f]*: ea d5 80 00 satsub\.w r5,r5,-32768
12072 + *[0-9a-f]*: e8 d4 7f ff satsub\.w r4,r4,32767
12073 + *[0-9a-f]*: fc de 00 01 satsub\.w lr,lr,1
12074 + *[0-9a-f]*: fc d2 f8 29 satsub\.w r2,lr,-2007
12075 + *[0-9a-f]*: f8 d7 fc f0 satsub\.w r7,r12,-784
12076 + *[0-9a-f]*: ee d4 5a 8c satsub\.w r4,r7,23180
12077 +
12078 +[0-9a-f]* <ld_d4>:
12079 + *[0-9a-f]*: fe e0 00 00 ld\.d r0,pc\[0\]
12080 + *[0-9a-f]*: f8 ee ff ff ld\.d lr,r12\[-1\]
12081 + *[0-9a-f]*: ea e8 80 00 ld\.d r8,r5\[-32768\]
12082 + *[0-9a-f]*: e8 e6 7f ff ld\.d r6,r4\[32767\]
12083 + *[0-9a-f]*: fc e2 00 01 ld\.d r2,lr\[1\]
12084 + *[0-9a-f]*: f6 ee 39 c0 ld\.d lr,r11\[14784\]
12085 + *[0-9a-f]*: f2 e6 b6 27 ld\.d r6,r9\[-18905\]
12086 + *[0-9a-f]*: e6 e2 e7 2d ld\.d r2,r3\[-6355\]
12087 +
12088 +[0-9a-f]* <ld_w4>:
12089 + *[0-9a-f]*: 7e 0f ld\.w pc,pc\[0x0\]
12090 + *[0-9a-f]*: f8 fc ff ff ld\.w r12,r12\[-1\]
12091 + *[0-9a-f]*: ea f5 80 00 ld\.w r5,r5\[-32768\]
12092 + *[0-9a-f]*: e8 f4 7f ff ld\.w r4,r4\[32767\]
12093 + *[0-9a-f]*: fc fe 00 01 ld\.w lr,lr\[1\]
12094 + *[0-9a-f]*: f8 f0 a9 8b ld\.w r0,r12\[-22133\]
12095 + *[0-9a-f]*: fe fd af d7 ld\.w sp,pc\[-20521\]
12096 + *[0-9a-f]*: d7 03 nop
12097 +
12098 +[0-9a-f]* <ld_sh4>:
12099 + *[0-9a-f]*: 9e 0f ld\.sh pc,pc\[0x0\]
12100 + *[0-9a-f]*: f9 0c ff ff ld\.sh r12,r12\[-1\]
12101 + *[0-9a-f]*: eb 05 80 00 ld\.sh r5,r5\[-32768\]
12102 + *[0-9a-f]*: e9 04 7f ff ld\.sh r4,r4\[32767\]
12103 + *[0-9a-f]*: fd 0e 00 01 ld\.sh lr,lr\[1\]
12104 + *[0-9a-f]*: f5 06 78 d2 ld\.sh r6,r10\[30930\]
12105 + *[0-9a-f]*: f5 06 55 d5 ld\.sh r6,r10\[21973\]
12106 + *[0-9a-f]*: d7 03 nop
12107 +
12108 +[0-9a-f]* <ld_uh4>:
12109 + *[0-9a-f]*: 9e 8f ld\.uh pc,pc\[0x0\]
12110 + *[0-9a-f]*: f9 1c ff ff ld\.uh r12,r12\[-1\]
12111 + *[0-9a-f]*: eb 15 80 00 ld\.uh r5,r5\[-32768\]
12112 + *[0-9a-f]*: e9 14 7f ff ld\.uh r4,r4\[32767\]
12113 + *[0-9a-f]*: fd 1e 00 01 ld\.uh lr,lr\[1\]
12114 + *[0-9a-f]*: f3 11 cb d6 ld\.uh r1,r9\[-13354\]
12115 + *[0-9a-f]*: f7 1e 53 59 ld\.uh lr,r11\[21337\]
12116 + *[0-9a-f]*: d7 03 nop
12117 +
12118 +[0-9a-f]* <ld_sb1>:
12119 + *[0-9a-f]*: ff 2f 00 00 ld\.sb pc,pc\[0\]
12120 + *[0-9a-f]*: f9 2c ff ff ld\.sb r12,r12\[-1\]
12121 + *[0-9a-f]*: eb 25 80 00 ld\.sb r5,r5\[-32768\]
12122 + *[0-9a-f]*: e9 24 7f ff ld\.sb r4,r4\[32767\]
12123 + *[0-9a-f]*: fd 2e 00 01 ld\.sb lr,lr\[1\]
12124 + *[0-9a-f]*: fb 27 90 09 ld\.sb r7,sp\[-28663\]
12125 + *[0-9a-f]*: e3 22 e9 09 ld\.sb r2,r1\[-5879\]
12126 + *[0-9a-f]*: e7 2c 49 2e ld\.sb r12,r3\[18734\]
12127 +
12128 +[0-9a-f]* <ld_ub4>:
12129 + *[0-9a-f]*: 1f 8f ld\.ub pc,pc\[0x0\]
12130 + *[0-9a-f]*: f9 3c ff ff ld\.ub r12,r12\[-1\]
12131 + *[0-9a-f]*: eb 35 80 00 ld\.ub r5,r5\[-32768\]
12132 + *[0-9a-f]*: e9 34 7f ff ld\.ub r4,r4\[32767\]
12133 + *[0-9a-f]*: 1d 9e ld\.ub lr,lr\[0x1\]
12134 + *[0-9a-f]*: e9 3f 20 55 ld\.ub pc,r4\[8277\]
12135 + *[0-9a-f]*: f9 35 4a e4 ld\.ub r5,r12\[19172\]
12136 + *[0-9a-f]*: fd 3a 66 eb ld\.ub r10,lr\[26347\]
12137 +
12138 +[0-9a-f]* <st_d4>:
12139 + *[0-9a-f]*: fe e1 00 00 st\.d pc\[0\],r0
12140 + *[0-9a-f]*: f8 ef ff ff st\.d r12\[-1\],lr
12141 + *[0-9a-f]*: ea e9 80 00 st\.d r5\[-32768\],r8
12142 + *[0-9a-f]*: e8 e7 7f ff st\.d r4\[32767\],r6
12143 + *[0-9a-f]*: fc e3 00 01 st\.d lr\[1\],r2
12144 + *[0-9a-f]*: ea eb 33 90 st\.d r5\[13200\],r10
12145 + *[0-9a-f]*: ea eb 24 88 st\.d r5\[9352\],r10
12146 + *[0-9a-f]*: ea e5 7e 75 st\.d r5\[32373\],r4
12147 +
12148 +[0-9a-f]* <st_w4>:
12149 + *[0-9a-f]*: 9f 0f st\.w pc\[0x0\],pc
12150 + *[0-9a-f]*: f9 4c ff ff st\.w r12\[-1\],r12
12151 + *[0-9a-f]*: eb 45 80 00 st\.w r5\[-32768\],r5
12152 + *[0-9a-f]*: e9 44 7f ff st\.w r4\[32767\],r4
12153 + *[0-9a-f]*: fd 4e 00 01 st\.w lr\[1\],lr
12154 + *[0-9a-f]*: fb 47 17 f8 st\.w sp\[6136\],r7
12155 + *[0-9a-f]*: ed 4c 69 cf st\.w r6\[27087\],r12
12156 + *[0-9a-f]*: d7 03 nop
12157 +
12158 +[0-9a-f]* <st_h4>:
12159 + *[0-9a-f]*: be 0f st\.h pc\[0x0\],pc
12160 + *[0-9a-f]*: f9 5c ff ff st\.h r12\[-1\],r12
12161 + *[0-9a-f]*: eb 55 80 00 st\.h r5\[-32768\],r5
12162 + *[0-9a-f]*: e9 54 7f ff st\.h r4\[32767\],r4
12163 + *[0-9a-f]*: fd 5e 00 01 st\.h lr\[1\],lr
12164 + *[0-9a-f]*: e9 57 d9 16 st\.h r4\[-9962\],r7
12165 + *[0-9a-f]*: f3 53 c0 86 st\.h r9\[-16250\],r3
12166 + *[0-9a-f]*: d7 03 nop
12167 +
12168 +[0-9a-f]* <st_b4>:
12169 + *[0-9a-f]*: be 8f st\.b pc\[0x0\],pc
12170 + *[0-9a-f]*: f9 6c ff ff st\.b r12\[-1\],r12
12171 + *[0-9a-f]*: eb 65 80 00 st\.b r5\[-32768\],r5
12172 + *[0-9a-f]*: e9 64 7f ff st\.b r4\[32767\],r4
12173 + *[0-9a-f]*: bc 9e st\.b lr\[0x1\],lr
12174 + *[0-9a-f]*: f9 66 75 96 st\.b r12\[30102\],r6
12175 + *[0-9a-f]*: eb 61 71 31 st\.b r5\[28977\],r1
12176 + *[0-9a-f]*: e1 61 15 5e st\.b r0\[5470\],r1
12177 +
12178 +[0-9a-f]* <mfsr>:
12179 + *[0-9a-f]*: e1 bf 00 00 mfsr pc,0x0
12180 + *[0-9a-f]*: e1 bc 00 ff mfsr r12,0x3fc
12181 + *[0-9a-f]*: e1 b5 00 80 mfsr r5,0x200
12182 + *[0-9a-f]*: e1 b4 00 7f mfsr r4,0x1fc
12183 + *[0-9a-f]*: e1 be 00 01 mfsr lr,0x4
12184 + *[0-9a-f]*: e1 b2 00 ae mfsr r2,0x2b8
12185 + *[0-9a-f]*: e1 b4 00 41 mfsr r4,0x104
12186 + *[0-9a-f]*: e1 ba 00 fe mfsr r10,0x3f8
12187 +
12188 +[0-9a-f]* <mtsr>:
12189 + *[0-9a-f]*: e3 bf 00 00 mtsr 0x0,pc
12190 + *[0-9a-f]*: e3 bc 00 ff mtsr 0x3fc,r12
12191 + *[0-9a-f]*: e3 b5 00 80 mtsr 0x200,r5
12192 + *[0-9a-f]*: e3 b4 00 7f mtsr 0x1fc,r4
12193 + *[0-9a-f]*: e3 be 00 01 mtsr 0x4,lr
12194 + *[0-9a-f]*: e3 ba 00 38 mtsr 0xe0,r10
12195 + *[0-9a-f]*: e3 bc 00 d1 mtsr 0x344,r12
12196 + *[0-9a-f]*: e3 b9 00 4c mtsr 0x130,r9
12197 +
12198 +[0-9a-f]* <mfdr>:
12199 + *[0-9a-f]*: e5 bf 00 00 mfdr pc,0x0
12200 + *[0-9a-f]*: e5 bc 00 ff mfdr r12,0x3fc
12201 + *[0-9a-f]*: e5 b5 00 80 mfdr r5,0x200
12202 + *[0-9a-f]*: e5 b4 00 7f mfdr r4,0x1fc
12203 + *[0-9a-f]*: e5 be 00 01 mfdr lr,0x4
12204 + *[0-9a-f]*: e5 b6 00 e9 mfdr r6,0x3a4
12205 + *[0-9a-f]*: e5 b5 00 09 mfdr r5,0x24
12206 + *[0-9a-f]*: e5 b9 00 4b mfdr r9,0x12c
12207 +
12208 +[0-9a-f]* <mtdr>:
12209 + *[0-9a-f]*: e7 bf 00 00 mtdr 0x0,pc
12210 + *[0-9a-f]*: e7 bc 00 ff mtdr 0x3fc,r12
12211 + *[0-9a-f]*: e7 b5 00 80 mtdr 0x200,r5
12212 + *[0-9a-f]*: e7 b4 00 7f mtdr 0x1fc,r4
12213 + *[0-9a-f]*: e7 be 00 01 mtdr 0x4,lr
12214 + *[0-9a-f]*: e7 b8 00 2d mtdr 0xb4,r8
12215 + *[0-9a-f]*: e7 ba 00 b4 mtdr 0x2d0,r10
12216 + *[0-9a-f]*: e7 be 00 66 mtdr 0x198,lr
12217 +
12218 +[0-9a-f]* <sleep>:
12219 + *[0-9a-f]*: e9 b0 00 00 sleep 0x0
12220 + *[0-9a-f]*: e9 b0 00 ff sleep 0xff
12221 + *[0-9a-f]*: e9 b0 00 80 sleep 0x80
12222 + *[0-9a-f]*: e9 b0 00 7f sleep 0x7f
12223 + *[0-9a-f]*: e9 b0 00 01 sleep 0x1
12224 + *[0-9a-f]*: e9 b0 00 fe sleep 0xfe
12225 + *[0-9a-f]*: e9 b0 00 0f sleep 0xf
12226 + *[0-9a-f]*: e9 b0 00 2b sleep 0x2b
12227 +
12228 +[0-9a-f]* <sync>:
12229 + *[0-9a-f]*: eb b0 00 00 sync 0x0
12230 + *[0-9a-f]*: eb b0 00 ff sync 0xff
12231 + *[0-9a-f]*: eb b0 00 80 sync 0x80
12232 + *[0-9a-f]*: eb b0 00 7f sync 0x7f
12233 + *[0-9a-f]*: eb b0 00 01 sync 0x1
12234 + *[0-9a-f]*: eb b0 00 a6 sync 0xa6
12235 + *[0-9a-f]*: eb b0 00 e6 sync 0xe6
12236 + *[0-9a-f]*: eb b0 00 b4 sync 0xb4
12237 +
12238 +[0-9a-f]* <bld>:
12239 + *[0-9a-f]*: ed bf 00 00 bld pc,0x0
12240 + *[0-9a-f]*: ed bc 00 1f bld r12,0x1f
12241 + *[0-9a-f]*: ed b5 00 10 bld r5,0x10
12242 + *[0-9a-f]*: ed b4 00 0f bld r4,0xf
12243 + *[0-9a-f]*: ed be 00 01 bld lr,0x1
12244 + *[0-9a-f]*: ed b9 00 0f bld r9,0xf
12245 + *[0-9a-f]*: ed b0 00 04 bld r0,0x4
12246 + *[0-9a-f]*: ed be 00 1a bld lr,0x1a
12247 +
12248 +[0-9a-f]* <bst>:
12249 + *[0-9a-f]*: ef bf 00 00 bst pc,0x0
12250 + *[0-9a-f]*: ef bc 00 1f bst r12,0x1f
12251 + *[0-9a-f]*: ef b5 00 10 bst r5,0x10
12252 + *[0-9a-f]*: ef b4 00 0f bst r4,0xf
12253 + *[0-9a-f]*: ef be 00 01 bst lr,0x1
12254 + *[0-9a-f]*: ef ba 00 1c bst r10,0x1c
12255 + *[0-9a-f]*: ef b0 00 03 bst r0,0x3
12256 + *[0-9a-f]*: ef bd 00 02 bst sp,0x2
12257 +
12258 +[0-9a-f]* <sats>:
12259 + *[0-9a-f]*: f1 bf 00 00 sats pc,0x0
12260 + *[0-9a-f]*: f1 bc 03 ff sats r12>>0x1f,0x1f
12261 + *[0-9a-f]*: f1 b5 02 10 sats r5>>0x10,0x10
12262 + *[0-9a-f]*: f1 b4 01 ef sats r4>>0xf,0xf
12263 + *[0-9a-f]*: f1 be 00 21 sats lr>>0x1,0x1
12264 + *[0-9a-f]*: f1 ba 02 63 sats r10>>0x3,0x13
12265 + *[0-9a-f]*: f1 ba 03 42 sats r10>>0x2,0x1a
12266 + *[0-9a-f]*: f1 b1 00 34 sats r1>>0x14,0x1
12267 +
12268 +[0-9a-f]* <satu>:
12269 + *[0-9a-f]*: f1 bf 04 00 satu pc,0x0
12270 + *[0-9a-f]*: f1 bc 07 ff satu r12>>0x1f,0x1f
12271 + *[0-9a-f]*: f1 b5 06 10 satu r5>>0x10,0x10
12272 + *[0-9a-f]*: f1 b4 05 ef satu r4>>0xf,0xf
12273 + *[0-9a-f]*: f1 be 04 21 satu lr>>0x1,0x1
12274 + *[0-9a-f]*: f1 bf 04 e5 satu pc>>0x5,0x7
12275 + *[0-9a-f]*: f1 b7 04 a5 satu r7>>0x5,0x5
12276 + *[0-9a-f]*: f1 b2 06 7a satu r2>>0x1a,0x13
12277 +
12278 +[0-9a-f]* <satrnds>:
12279 + *[0-9a-f]*: f3 bf 00 00 satrnds pc,0x0
12280 + *[0-9a-f]*: f3 bc 03 ff satrnds r12>>0x1f,0x1f
12281 + *[0-9a-f]*: f3 b5 02 10 satrnds r5>>0x10,0x10
12282 + *[0-9a-f]*: f3 b4 01 ef satrnds r4>>0xf,0xf
12283 + *[0-9a-f]*: f3 be 00 21 satrnds lr>>0x1,0x1
12284 + *[0-9a-f]*: f3 b0 02 75 satrnds r0>>0x15,0x13
12285 + *[0-9a-f]*: f3 bd 00 40 satrnds sp,0x2
12286 + *[0-9a-f]*: f3 b7 03 a6 satrnds r7>>0x6,0x1d
12287 +
12288 +[0-9a-f]* <satrndu>:
12289 + *[0-9a-f]*: f3 bf 04 00 satrndu pc,0x0
12290 + *[0-9a-f]*: f3 bc 07 ff satrndu r12>>0x1f,0x1f
12291 + *[0-9a-f]*: f3 b5 06 10 satrndu r5>>0x10,0x10
12292 + *[0-9a-f]*: f3 b4 05 ef satrndu r4>>0xf,0xf
12293 + *[0-9a-f]*: f3 be 04 21 satrndu lr>>0x1,0x1
12294 + *[0-9a-f]*: f3 bc 07 40 satrndu r12,0x1a
12295 + *[0-9a-f]*: f3 b4 04 75 satrndu r4>>0x15,0x3
12296 + *[0-9a-f]*: f3 ba 06 03 satrndu r10>>0x3,0x10
12297 +
12298 +[0-9a-f]* <subfc>:
12299 + *[0-9a-f]*: f5 bf 00 00 subfeq pc,0
12300 + *[0-9a-f]*: f5 bc 0f ff subfal r12,-1
12301 + *[0-9a-f]*: f5 b5 08 80 subfls r5,-128
12302 + *[0-9a-f]*: f5 b4 07 7f subfpl r4,127
12303 + *[0-9a-f]*: f5 be 01 01 subfne lr,1
12304 + *[0-9a-f]*: f5 ba 08 08 subfls r10,8
12305 + *[0-9a-f]*: f5 bb 0d 63 subfvc r11,99
12306 + *[0-9a-f]*: f5 b2 0c 49 subfvs r2,73
12307 +
12308 +[0-9a-f]* <subc>:
12309 + *[0-9a-f]*: f7 bf 00 00 subeq pc,0
12310 + *[0-9a-f]*: f7 bc 0f ff subal r12,-1
12311 + *[0-9a-f]*: f7 b5 08 80 subls r5,-128
12312 + *[0-9a-f]*: f7 b4 07 7f subpl r4,127
12313 + *[0-9a-f]*: f7 be 01 01 subne lr,1
12314 + *[0-9a-f]*: f7 bc 08 76 subls r12,118
12315 + *[0-9a-f]*: f7 be 0d f4 subvc lr,-12
12316 + *[0-9a-f]*: f7 b4 06 f3 submi r4,-13
12317 +
12318 +[0-9a-f]* <movc2>:
12319 + *[0-9a-f]*: f9 bf 00 00 moveq pc,0
12320 + *[0-9a-f]*: f9 bc 0f ff moval r12,-1
12321 + *[0-9a-f]*: f9 b5 08 80 movls r5,-128
12322 + *[0-9a-f]*: f9 b4 07 7f movpl r4,127
12323 + *[0-9a-f]*: f9 be 01 01 movne lr,1
12324 + *[0-9a-f]*: f9 b3 05 86 movlt r3,-122
12325 + *[0-9a-f]*: f9 b8 0d 02 movvc r8,2
12326 + *[0-9a-f]*: f9 b7 01 91 movne r7,-111
12327 +
12328 +[0-9a-f]* <cp_b>:
12329 + *[0-9a-f]*: e0 0f 18 00 cp\.b pc,r0
12330 + *[0-9a-f]*: fe 00 18 00 cp\.b r0,pc
12331 + *[0-9a-f]*: f0 07 18 00 cp\.b r7,r8
12332 + *[0-9a-f]*: ee 08 18 00 cp\.b r8,r7
12333 +
12334 +[0-9a-f]* <cp_h>:
12335 + *[0-9a-f]*: e0 0f 19 00 cp\.h pc,r0
12336 + *[0-9a-f]*: fe 00 19 00 cp\.h r0,pc
12337 + *[0-9a-f]*: f0 07 19 00 cp\.h r7,r8
12338 + *[0-9a-f]*: ee 08 19 00 cp\.h r8,r7
12339 +
12340 +[0-9a-f]* <ldm>:
12341 + *[0-9a-f]*: e1 cf 00 7e ldm pc,r1-r6
12342 + *[0-9a-f]*: e1 cc ff ff ldm r12,r0-pc
12343 + *[0-9a-f]*: e1 c5 80 00 ldm r5,pc
12344 + *[0-9a-f]*: e1 c4 7f ff ldm r4,r0-lr
12345 + *[0-9a-f]*: e1 ce 00 01 ldm lr,r0
12346 + *[0-9a-f]*: e1 c9 40 22 ldm r9,r1,r5,lr
12347 + *[0-9a-f]*: e1 cb 81 ec ldm r11,r2-r3,r5-r8,pc
12348 + *[0-9a-f]*: e1 c6 a2 09 ldm r6,r0,r3,r9,sp,pc
12349 +
12350 +[0-9a-f]* <ldm_pu>:
12351 + *[0-9a-f]*: e3 cf 03 c0 ldm pc\+\+,r6-r9
12352 + *[0-9a-f]*: e3 cc ff ff ldm r12\+\+,r0-pc
12353 + *[0-9a-f]*: e3 c5 80 00 ldm r5\+\+,pc
12354 + *[0-9a-f]*: e3 c4 7f ff ldm r4\+\+,r0-lr
12355 + *[0-9a-f]*: e3 ce 00 01 ldm lr\+\+,r0
12356 + *[0-9a-f]*: e3 cc d5 38 ldm r12\+\+,r3-r5,r8,r10,r12,lr-pc
12357 + *[0-9a-f]*: e3 ca c0 74 ldm r10\+\+,r2,r4-r6,lr-pc
12358 + *[0-9a-f]*: e3 c6 7e 1a ldm r6\+\+,r1,r3-r4,r9-lr
12359 +
12360 +[0-9a-f]* <ldmts>:
12361 + *[0-9a-f]*: e5 cf 01 80 ldmts pc,r7-r8
12362 + *[0-9a-f]*: e5 cc ff ff ldmts r12,r0-pc
12363 + *[0-9a-f]*: e5 c5 80 00 ldmts r5,pc
12364 + *[0-9a-f]*: e5 c4 7f ff ldmts r4,r0-lr
12365 + *[0-9a-f]*: e5 ce 00 01 ldmts lr,r0
12366 + *[0-9a-f]*: e5 c0 18 06 ldmts r0,r1-r2,r11-r12
12367 + *[0-9a-f]*: e5 ce 61 97 ldmts lr,r0-r2,r4,r7-r8,sp-lr
12368 + *[0-9a-f]*: e5 cc c2 3b ldmts r12,r0-r1,r3-r5,r9,lr-pc
12369 +
12370 +[0-9a-f]* <ldmts_pu>:
12371 + *[0-9a-f]*: e7 cf 02 00 ldmts pc\+\+,r9
12372 + *[0-9a-f]*: e7 cc ff ff ldmts r12\+\+,r0-pc
12373 + *[0-9a-f]*: e7 c5 80 00 ldmts r5\+\+,pc
12374 + *[0-9a-f]*: e7 c4 7f ff ldmts r4\+\+,r0-lr
12375 + *[0-9a-f]*: e7 ce 00 01 ldmts lr\+\+,r0
12376 + *[0-9a-f]*: e7 cd 0a bd ldmts sp\+\+,r0,r2-r5,r7,r9,r11
12377 + *[0-9a-f]*: e7 c5 0c 8e ldmts r5\+\+,r1-r3,r7,r10-r11
12378 + *[0-9a-f]*: e7 c8 a1 9c ldmts r8\+\+,r2-r4,r7-r8,sp,pc
12379 +
12380 +[0-9a-f]* <stm>:
12381 + *[0-9a-f]*: e9 cf 00 80 stm pc,r7
12382 + *[0-9a-f]*: e9 cc ff ff stm r12,r0-pc
12383 + *[0-9a-f]*: e9 c5 80 00 stm r5,pc
12384 + *[0-9a-f]*: e9 c4 7f ff stm r4,r0-lr
12385 + *[0-9a-f]*: e9 ce 00 01 stm lr,r0
12386 + *[0-9a-f]*: e9 cd 49 2c stm sp,r2-r3,r5,r8,r11,lr
12387 + *[0-9a-f]*: e9 c4 4c 5f stm r4,r0-r4,r6,r10-r11,lr
12388 + *[0-9a-f]*: e9 c9 f2 22 stm r9,r1,r5,r9,r12-pc
12389 +
12390 +[0-9a-f]* <stm_pu>:
12391 + *[0-9a-f]*: eb cf 00 70 stm --pc,r4-r6
12392 + *[0-9a-f]*: eb cc ff ff stm --r12,r0-pc
12393 + *[0-9a-f]*: eb c5 80 00 stm --r5,pc
12394 + *[0-9a-f]*: eb c4 7f ff stm --r4,r0-lr
12395 + *[0-9a-f]*: eb ce 00 01 stm --lr,r0
12396 + *[0-9a-f]*: eb cb fb f1 stm --r11,r0,r4-r9,r11-pc
12397 + *[0-9a-f]*: eb cb 56 09 stm --r11,r0,r3,r9-r10,r12,lr
12398 + *[0-9a-f]*: eb c6 63 04 stm --r6,r2,r8-r9,sp-lr
12399 +
12400 +[0-9a-f]* <stmts>:
12401 + *[0-9a-f]*: ed cf 01 00 stmts pc,r8
12402 + *[0-9a-f]*: ed cc ff ff stmts r12,r0-pc
12403 + *[0-9a-f]*: ed c5 80 00 stmts r5,pc
12404 + *[0-9a-f]*: ed c4 7f ff stmts r4,r0-lr
12405 + *[0-9a-f]*: ed ce 00 01 stmts lr,r0
12406 + *[0-9a-f]*: ed c1 c6 5b stmts r1,r0-r1,r3-r4,r6,r9-r10,lr-pc
12407 + *[0-9a-f]*: ed c3 1d c1 stmts r3,r0,r6-r8,r10-r12
12408 + *[0-9a-f]*: ed cb d6 d1 stmts r11,r0,r4,r6-r7,r9-r10,r12,lr-pc
12409 +
12410 +[0-9a-f]* <stmts_pu>:
12411 + *[0-9a-f]*: ef cf 01 c0 stmts --pc,r6-r8
12412 + *[0-9a-f]*: ef cc ff ff stmts --r12,r0-pc
12413 + *[0-9a-f]*: ef c5 80 00 stmts --r5,pc
12414 + *[0-9a-f]*: ef c4 7f ff stmts --r4,r0-lr
12415 + *[0-9a-f]*: ef ce 00 01 stmts --lr,r0
12416 + *[0-9a-f]*: ef c2 36 19 stmts --r2,r0,r3-r4,r9-r10,r12-sp
12417 + *[0-9a-f]*: ef c3 c0 03 stmts --r3,r0-r1,lr-pc
12418 + *[0-9a-f]*: ef c0 44 7d stmts --r0,r0,r2-r6,r10,lr
12419 +
12420 +[0-9a-f]* <ldins_h>:
12421 + *[0-9a-f]*: ff df 00 00 ldins\.h pc:b,pc\[0\]
12422 + *[0-9a-f]*: f9 dc 1f ff ldins\.h r12:t,r12\[-2\]
12423 + *[0-9a-f]*: eb d5 18 00 ldins\.h r5:t,r5\[-4096\]
12424 + *[0-9a-f]*: e9 d4 07 ff ldins\.h r4:b,r4\[4094\]
12425 + *[0-9a-f]*: fd de 10 01 ldins\.h lr:t,lr\[2\]
12426 + *[0-9a-f]*: fd d0 13 c5 ldins\.h r0:t,lr\[1930\]
12427 + *[0-9a-f]*: ef d3 0e f5 ldins\.h r3:b,r7\[-534\]
12428 + *[0-9a-f]*: f9 d2 0b 9a ldins\.h r2:b,r12\[-2252\]
12429 +
12430 +[0-9a-f]* <ldins_b>:
12431 + *[0-9a-f]*: ff df 40 00 ldins\.b pc:b,pc\[0\]
12432 + *[0-9a-f]*: f9 dc 7f ff ldins\.b r12:t,r12\[-1\]
12433 + *[0-9a-f]*: eb d5 68 00 ldins\.b r5:u,r5\[-2048\]
12434 + *[0-9a-f]*: e9 d4 57 ff ldins\.b r4:l,r4\[2047\]
12435 + *[0-9a-f]*: fd de 50 01 ldins\.b lr:l,lr\[1\]
12436 + *[0-9a-f]*: e9 d6 7d 6a ldins\.b r6:t,r4\[-662\]
12437 + *[0-9a-f]*: e3 d5 4f 69 ldins\.b r5:b,r1\[-151\]
12438 + *[0-9a-f]*: f7 da 78 7d ldins\.b r10:t,r11\[-1923\]
12439 +
12440 +[0-9a-f]* <ldswp_sh>:
12441 + *[0-9a-f]*: ff df 20 00 ldswp\.sh pc,pc\[0\]
12442 + *[0-9a-f]*: f9 dc 2f ff ldswp\.sh r12,r12\[-2\]
12443 + *[0-9a-f]*: eb d5 28 00 ldswp\.sh r5,r5\[-4096\]
12444 + *[0-9a-f]*: e9 d4 27 ff ldswp\.sh r4,r4\[4094\]
12445 + *[0-9a-f]*: fd de 20 01 ldswp\.sh lr,lr\[2\]
12446 + *[0-9a-f]*: f5 d9 27 84 ldswp\.sh r9,r10\[3848\]
12447 + *[0-9a-f]*: f9 d4 2c 04 ldswp\.sh r4,r12\[-2040\]
12448 + *[0-9a-f]*: e5 da 26 08 ldswp\.sh r10,r2\[3088\]
12449 +
12450 +[0-9a-f]* <ldswp_uh>:
12451 + *[0-9a-f]*: ff df 30 00 ldswp\.uh pc,pc\[0\]
12452 + *[0-9a-f]*: f9 dc 3f ff ldswp\.uh r12,r12\[-2\]
12453 + *[0-9a-f]*: eb d5 38 00 ldswp\.uh r5,r5\[-4096\]
12454 + *[0-9a-f]*: e9 d4 37 ff ldswp\.uh r4,r4\[4094\]
12455 + *[0-9a-f]*: fd de 30 01 ldswp\.uh lr,lr\[2\]
12456 + *[0-9a-f]*: f3 d4 37 46 ldswp\.uh r4,r9\[3724\]
12457 + *[0-9a-f]*: fb de 3c bc ldswp\.uh lr,sp\[-1672\]
12458 + *[0-9a-f]*: f9 d8 38 7d ldswp\.uh r8,r12\[-3846\]
12459 +
12460 +[0-9a-f]* <ldswp_w>:
12461 + *[0-9a-f]*: ff df 80 00 ldswp\.w pc,pc\[0\]
12462 + *[0-9a-f]*: f9 dc 8f ff ldswp\.w r12,r12\[-4\]
12463 + *[0-9a-f]*: eb d5 88 00 ldswp\.w r5,r5\[-8192\]
12464 + *[0-9a-f]*: e9 d4 87 ff ldswp\.w r4,r4\[8188\]
12465 + *[0-9a-f]*: fd de 80 01 ldswp\.w lr,lr\[4\]
12466 + *[0-9a-f]*: ef dd 81 d1 ldswp\.w sp,r7\[1860\]
12467 + *[0-9a-f]*: eb df 8c c1 ldswp\.w pc,r5\[-3324\]
12468 + *[0-9a-f]*: f5 dc 8c c8 ldswp\.w r12,r10\[-3296\]
12469 +
12470 +[0-9a-f]* <stswp_h>:
12471 + *[0-9a-f]*: ff df 90 00 stswp\.h pc\[0\],pc
12472 + *[0-9a-f]*: f9 dc 9f ff stswp\.h r12\[-2\],r12
12473 + *[0-9a-f]*: eb d5 98 00 stswp\.h r5\[-4096\],r5
12474 + *[0-9a-f]*: e9 d4 97 ff stswp\.h r4\[4094\],r4
12475 + *[0-9a-f]*: fd de 90 01 stswp\.h lr\[2\],lr
12476 + *[0-9a-f]*: ef da 90 20 stswp\.h r7\[64\],r10
12477 + *[0-9a-f]*: f5 d2 95 e8 stswp\.h r10\[3024\],r2
12478 + *[0-9a-f]*: e1 da 9b 74 stswp\.h r0\[-2328\],r10
12479 +
12480 +[0-9a-f]* <stswp_w>:
12481 + *[0-9a-f]*: ff df a0 00 stswp\.w pc\[0\],pc
12482 + *[0-9a-f]*: f9 dc af ff stswp\.w r12\[-4\],r12
12483 + *[0-9a-f]*: eb d5 a8 00 stswp\.w r5\[-8192\],r5
12484 + *[0-9a-f]*: e9 d4 a7 ff stswp\.w r4\[8188\],r4
12485 + *[0-9a-f]*: fd de a0 01 stswp\.w lr\[4\],lr
12486 + *[0-9a-f]*: ff d8 a1 21 stswp\.w pc\[1156\],r8
12487 + *[0-9a-f]*: fb da a7 ce stswp\.w sp\[7992\],r10
12488 + *[0-9a-f]*: f1 d5 ae db stswp\.w r8\[-1172\],r5
12489 +
12490 +[0-9a-f]* <and2>:
12491 + *[0-9a-f]*: ff ef 00 0f and pc,pc,pc
12492 + *[0-9a-f]*: f9 ec 01 fc and r12,r12,r12<<0x1f
12493 + *[0-9a-f]*: eb e5 01 05 and r5,r5,r5<<0x10
12494 + *[0-9a-f]*: e9 e4 00 f4 and r4,r4,r4<<0xf
12495 + *[0-9a-f]*: fd ee 00 1e and lr,lr,lr<<0x1
12496 + *[0-9a-f]*: e5 e1 00 1a and r10,r2,r1<<0x1
12497 + *[0-9a-f]*: f1 eb 01 bc and r12,r8,r11<<0x1b
12498 + *[0-9a-f]*: ef e0 00 3a and r10,r7,r0<<0x3
12499 +
12500 +[0-9a-f]* <and3>:
12501 + *[0-9a-f]*: ff ef 02 0f and pc,pc,pc
12502 + *[0-9a-f]*: f9 ec 03 fc and r12,r12,r12>>0x1f
12503 + *[0-9a-f]*: eb e5 03 05 and r5,r5,r5>>0x10
12504 + *[0-9a-f]*: e9 e4 02 f4 and r4,r4,r4>>0xf
12505 + *[0-9a-f]*: fd ee 02 1e and lr,lr,lr>>0x1
12506 + *[0-9a-f]*: f1 e7 03 1c and r12,r8,r7>>0x11
12507 + *[0-9a-f]*: e9 e9 03 4f and pc,r4,r9>>0x14
12508 + *[0-9a-f]*: f3 ea 02 ca and r10,r9,r10>>0xc
12509 +
12510 +[0-9a-f]* <or2>:
12511 + *[0-9a-f]*: ff ef 10 0f or pc,pc,pc
12512 + *[0-9a-f]*: f9 ec 11 fc or r12,r12,r12<<0x1f
12513 + *[0-9a-f]*: eb e5 11 05 or r5,r5,r5<<0x10
12514 + *[0-9a-f]*: e9 e4 10 f4 or r4,r4,r4<<0xf
12515 + *[0-9a-f]*: fd ee 10 1e or lr,lr,lr<<0x1
12516 + *[0-9a-f]*: fb eb 11 d8 or r8,sp,r11<<0x1d
12517 + *[0-9a-f]*: f3 e2 11 cf or pc,r9,r2<<0x1c
12518 + *[0-9a-f]*: e3 e2 10 35 or r5,r1,r2<<0x3
12519 +
12520 +[0-9a-f]* <or3>:
12521 + *[0-9a-f]*: ff ef 12 0f or pc,pc,pc
12522 + *[0-9a-f]*: f9 ec 13 fc or r12,r12,r12>>0x1f
12523 + *[0-9a-f]*: eb e5 13 05 or r5,r5,r5>>0x10
12524 + *[0-9a-f]*: e9 e4 12 f4 or r4,r4,r4>>0xf
12525 + *[0-9a-f]*: fd ee 12 1e or lr,lr,lr>>0x1
12526 + *[0-9a-f]*: fb ed 12 21 or r1,sp,sp>>0x2
12527 + *[0-9a-f]*: e3 e1 13 d0 or r0,r1,r1>>0x1d
12528 + *[0-9a-f]*: f9 e8 12 84 or r4,r12,r8>>0x8
12529 +
12530 +[0-9a-f]* <eor2>:
12531 + *[0-9a-f]*: ff ef 20 0f eor pc,pc,pc
12532 + *[0-9a-f]*: f9 ec 21 fc eor r12,r12,r12<<0x1f
12533 + *[0-9a-f]*: eb e5 21 05 eor r5,r5,r5<<0x10
12534 + *[0-9a-f]*: e9 e4 20 f4 eor r4,r4,r4<<0xf
12535 + *[0-9a-f]*: fd ee 20 1e eor lr,lr,lr<<0x1
12536 + *[0-9a-f]*: f3 e4 20 ba eor r10,r9,r4<<0xb
12537 + *[0-9a-f]*: e1 e1 21 f4 eor r4,r0,r1<<0x1f
12538 + *[0-9a-f]*: e5 ec 20 d6 eor r6,r2,r12<<0xd
12539 +
12540 +[0-9a-f]* <eor3>:
12541 + *[0-9a-f]*: ff ef 22 0f eor pc,pc,pc
12542 + *[0-9a-f]*: f9 ec 23 fc eor r12,r12,r12>>0x1f
12543 + *[0-9a-f]*: eb e5 23 05 eor r5,r5,r5>>0x10
12544 + *[0-9a-f]*: e9 e4 22 f4 eor r4,r4,r4>>0xf
12545 + *[0-9a-f]*: fd ee 22 1e eor lr,lr,lr>>0x1
12546 + *[0-9a-f]*: eb e5 23 65 eor r5,r5,r5>>0x16
12547 + *[0-9a-f]*: e3 ee 22 3a eor r10,r1,lr>>0x3
12548 + *[0-9a-f]*: fd ed 23 a7 eor r7,lr,sp>>0x1a
12549 +
12550 +[0-9a-f]* <sthh_w2>:
12551 + *[0-9a-f]*: ff ef 8f 0f sthh\.w pc\[pc\],pc:b,pc:b
12552 + *[0-9a-f]*: f9 ec bc 3c sthh\.w r12\[r12<<0x3\],r12:t,r12:t
12553 + *[0-9a-f]*: eb e5 b5 25 sthh\.w r5\[r5<<0x2\],r5:t,r5:t
12554 + *[0-9a-f]*: e9 e4 84 14 sthh\.w r4\[r4<<0x1\],r4:b,r4:b
12555 + *[0-9a-f]*: fd ee be 1e sthh\.w lr\[lr<<0x1\],lr:t,lr:t
12556 + *[0-9a-f]*: e3 ec b6 3d sthh\.w sp\[r6<<0x3\],r1:t,r12:t
12557 + *[0-9a-f]*: f3 e9 b6 06 sthh\.w r6\[r6\],r9:t,r9:t
12558 + *[0-9a-f]*: e1 eb 93 0a sthh\.w r10\[r3\],r0:b,r11:t
12559 +
12560 +[0-9a-f]* <sthh_w1>:
12561 + *[0-9a-f]*: ff ef c0 0f sthh\.w pc\[0x0\],pc:b,pc:b
12562 + *[0-9a-f]*: f9 ec ff fc sthh\.w r12\[0x3fc\],r12:t,r12:t
12563 + *[0-9a-f]*: eb e5 f8 05 sthh\.w r5\[0x200\],r5:t,r5:t
12564 + *[0-9a-f]*: e9 e4 c7 f4 sthh\.w r4\[0x1fc\],r4:b,r4:b
12565 + *[0-9a-f]*: fd ee f0 1e sthh\.w lr\[0x4\],lr:t,lr:t
12566 + *[0-9a-f]*: f3 e0 e6 54 sthh\.w r4\[0x194\],r9:t,r0:b
12567 + *[0-9a-f]*: e5 ea e5 78 sthh\.w r8\[0x15c\],r2:t,r10:b
12568 + *[0-9a-f]*: f3 e2 c2 bd sthh\.w sp\[0xac\],r9:b,r2:b
12569 +
12570 +[0-9a-f]* <cop>:
12571 + *[0-9a-f]*: e1 a0 00 00 cop cp0,cr0,cr0,cr0,0x0
12572 + *[0-9a-f]*: e7 af ff ff cop cp7,cr15,cr15,cr15,0x7f
12573 + *[0-9a-f]*: e3 a8 75 55 cop cp3,cr5,cr5,cr5,0x31
12574 + *[0-9a-f]*: e3 a8 44 44 cop cp2,cr4,cr4,cr4,0x30
12575 + *[0-9a-f]*: e5 ad a8 37 cop cp5,cr8,cr3,cr7,0x5a
12576 +
12577 +[0-9a-f]* <ldc_w1>:
12578 + *[0-9a-f]*: e9 a0 00 00 ldc\.w cp0,cr0,r0\[0x0\]
12579 + *[0-9a-f]*: e9 af ef ff ldc\.w cp7,cr15,pc\[0x3fc\]
12580 + *[0-9a-f]*: e9 a5 65 80 ldc\.w cp3,cr5,r5\[0x200\]
12581 + *[0-9a-f]*: e9 a4 44 7f ldc\.w cp2,cr4,r4\[0x1fc\]
12582 + *[0-9a-f]*: e9 ad 89 24 ldc\.w cp4,cr9,sp\[0x90\]
12583 +
12584 +[0-9a-f]* <ldc_w2>:
12585 + *[0-9a-f]*: ef a0 00 40 ldc\.w cp0,cr0,--r0
12586 + *[0-9a-f]*: ef af ef 40 ldc\.w cp7,cr15,--pc
12587 + *[0-9a-f]*: ef a5 65 40 ldc\.w cp3,cr5,--r5
12588 + *[0-9a-f]*: ef a4 44 40 ldc\.w cp2,cr4,--r4
12589 + *[0-9a-f]*: ef ad 89 40 ldc\.w cp4,cr9,--sp
12590 +
12591 +[0-9a-f]* <ldc_w3>:
12592 + *[0-9a-f]*: ef a0 10 00 ldc\.w cp0,cr0,r0\[r0\]
12593 + *[0-9a-f]*: ef af ff 3f ldc\.w cp7,cr15,pc\[pc<<0x3\]
12594 + *[0-9a-f]*: ef a5 75 24 ldc\.w cp3,cr5,r5\[r4<<0x2\]
12595 + *[0-9a-f]*: ef a4 54 13 ldc\.w cp2,cr4,r4\[r3<<0x1\]
12596 + *[0-9a-f]*: ef ad 99 0c ldc\.w cp4,cr9,sp\[r12\]
12597 +
12598 +[0-9a-f]* <ldc_d1>:
12599 + *[0-9a-f]*: e9 a0 10 00 ldc\.d cp0,cr0,r0\[0x0\]
12600 + *[0-9a-f]*: e9 af fe ff ldc\.d cp7,cr14,pc\[0x3fc\]
12601 + *[0-9a-f]*: e9 a5 76 80 ldc\.d cp3,cr6,r5\[0x200\]
12602 + *[0-9a-f]*: e9 a4 54 7f ldc\.d cp2,cr4,r4\[0x1fc\]
12603 + *[0-9a-f]*: e9 ad 98 24 ldc\.d cp4,cr8,sp\[0x90\]
12604 +
12605 +[0-9a-f]* <ldc_d2>:
12606 + *[0-9a-f]*: ef a0 00 50 ldc\.d cp0,cr0,--r0
12607 + *[0-9a-f]*: ef af ee 50 ldc\.d cp7,cr14,--pc
12608 + *[0-9a-f]*: ef a5 66 50 ldc\.d cp3,cr6,--r5
12609 + *[0-9a-f]*: ef a4 44 50 ldc\.d cp2,cr4,--r4
12610 + *[0-9a-f]*: ef ad 88 50 ldc\.d cp4,cr8,--sp
12611 +
12612 +[0-9a-f]* <ldc_d3>:
12613 + *[0-9a-f]*: ef a0 10 40 ldc\.d cp0,cr0,r0\[r0\]
12614 + *[0-9a-f]*: ef af fe 7f ldc\.d cp7,cr14,pc\[pc<<0x3\]
12615 + *[0-9a-f]*: ef a5 76 64 ldc\.d cp3,cr6,r5\[r4<<0x2\]
12616 + *[0-9a-f]*: ef a4 54 53 ldc\.d cp2,cr4,r4\[r3<<0x1\]
12617 + *[0-9a-f]*: ef ad 98 4c ldc\.d cp4,cr8,sp\[r12\]
12618 +
12619 +[0-9a-f]* <stc_w1>:
12620 + *[0-9a-f]*: eb a0 00 00 stc\.w cp0,r0\[0x0\],cr0
12621 + *[0-9a-f]*: eb af ef ff stc\.w cp7,pc\[0x3fc\],cr15
12622 + *[0-9a-f]*: eb a5 65 80 stc\.w cp3,r5\[0x200\],cr5
12623 + *[0-9a-f]*: eb a4 44 7f stc\.w cp2,r4\[0x1fc\],cr4
12624 + *[0-9a-f]*: eb ad 89 24 stc\.w cp4,sp\[0x90\],cr9
12625 +
12626 +[0-9a-f]* <stc_w2>:
12627 + *[0-9a-f]*: ef a0 00 60 stc\.w cp0,r0\+\+,cr0
12628 + *[0-9a-f]*: ef af ef 60 stc\.w cp7,pc\+\+,cr15
12629 + *[0-9a-f]*: ef a5 65 60 stc\.w cp3,r5\+\+,cr5
12630 + *[0-9a-f]*: ef a4 44 60 stc\.w cp2,r4\+\+,cr4
12631 + *[0-9a-f]*: ef ad 89 60 stc\.w cp4,sp\+\+,cr9
12632 +
12633 +[0-9a-f]* <stc_w3>:
12634 + *[0-9a-f]*: ef a0 10 80 stc\.w cp0,r0\[r0\],cr0
12635 + *[0-9a-f]*: ef af ff bf stc\.w cp7,pc\[pc<<0x3\],cr15
12636 + *[0-9a-f]*: ef a5 75 a4 stc\.w cp3,r5\[r4<<0x2\],cr5
12637 + *[0-9a-f]*: ef a4 54 93 stc\.w cp2,r4\[r3<<0x1\],cr4
12638 + *[0-9a-f]*: ef ad 99 8c stc\.w cp4,sp\[r12\],cr9
12639 +
12640 +[0-9a-f]* <stc_d1>:
12641 + *[0-9a-f]*: eb a0 10 00 stc\.d cp0,r0\[0x0\],cr0
12642 + *[0-9a-f]*: eb af fe ff stc\.d cp7,pc\[0x3fc\],cr14
12643 + *[0-9a-f]*: eb a5 76 80 stc\.d cp3,r5\[0x200\],cr6
12644 + *[0-9a-f]*: eb a4 54 7f stc\.d cp2,r4\[0x1fc\],cr4
12645 + *[0-9a-f]*: eb ad 98 24 stc\.d cp4,sp\[0x90\],cr8
12646 +
12647 +[0-9a-f]* <stc_d2>:
12648 + *[0-9a-f]*: ef a0 00 70 stc\.d cp0,r0\+\+,cr0
12649 + *[0-9a-f]*: ef af ee 70 stc\.d cp7,pc\+\+,cr14
12650 + *[0-9a-f]*: ef a5 66 70 stc\.d cp3,r5\+\+,cr6
12651 + *[0-9a-f]*: ef a4 44 70 stc\.d cp2,r4\+\+,cr4
12652 + *[0-9a-f]*: ef ad 88 70 stc\.d cp4,sp\+\+,cr8
12653 +
12654 +[0-9a-f]* <stc_d3>:
12655 + *[0-9a-f]*: ef a0 10 c0 stc\.d cp0,r0\[r0\],cr0
12656 + *[0-9a-f]*: ef af fe ff stc\.d cp7,pc\[pc<<0x3\],cr14
12657 + *[0-9a-f]*: ef a5 76 e4 stc\.d cp3,r5\[r4<<0x2\],cr6
12658 + *[0-9a-f]*: ef a4 54 d3 stc\.d cp2,r4\[r3<<0x1\],cr4
12659 + *[0-9a-f]*: ef ad 98 cc stc\.d cp4,sp\[r12\],cr8
12660 +
12661 +[0-9a-f]* <ldc0_w>:
12662 + *[0-9a-f]*: f1 a0 00 00 ldc0\.w cr0,r0\[0x0\]
12663 + *[0-9a-f]*: f1 af ff ff ldc0\.w cr15,pc\[0x3ffc\]
12664 + *[0-9a-f]*: f1 a5 85 00 ldc0\.w cr5,r5\[0x2000\]
12665 + *[0-9a-f]*: f1 a4 74 ff ldc0\.w cr4,r4\[0x1ffc\]
12666 + *[0-9a-f]*: f1 ad 09 93 ldc0\.w cr9,sp\[0x24c\]
12667 +
12668 +[0-9a-f]* <ldc0_d>:
12669 + *[0-9a-f]*: f3 a0 00 00 ldc0\.d cr0,r0\[0x0\]
12670 + *[0-9a-f]*: f3 af fe ff ldc0\.d cr14,pc\[0x3ffc\]
12671 + *[0-9a-f]*: f3 a5 86 00 ldc0\.d cr6,r5\[0x2000\]
12672 + *[0-9a-f]*: f3 a4 74 ff ldc0\.d cr4,r4\[0x1ffc\]
12673 + *[0-9a-f]*: f3 ad 08 93 ldc0\.d cr8,sp\[0x24c\]
12674 +
12675 +[0-9a-f]* <stc0_w>:
12676 + *[0-9a-f]*: f5 a0 00 00 stc0\.w r0\[0x0\],cr0
12677 + *[0-9a-f]*: f5 af ff ff stc0\.w pc\[0x3ffc\],cr15
12678 + *[0-9a-f]*: f5 a5 85 00 stc0\.w r5\[0x2000\],cr5
12679 + *[0-9a-f]*: f5 a4 74 ff stc0\.w r4\[0x1ffc\],cr4
12680 + *[0-9a-f]*: f5 ad 09 93 stc0\.w sp\[0x24c\],cr9
12681 +
12682 +[0-9a-f]* <stc0_d>:
12683 + *[0-9a-f]*: f7 a0 00 00 stc0\.d r0\[0x0\],cr0
12684 + *[0-9a-f]*: f7 af fe ff stc0\.d pc\[0x3ffc\],cr14
12685 + *[0-9a-f]*: f7 a5 86 00 stc0\.d r5\[0x2000\],cr6
12686 + *[0-9a-f]*: f7 a4 74 ff stc0\.d r4\[0x1ffc\],cr4
12687 + *[0-9a-f]*: f7 ad 08 93 stc0\.d sp\[0x24c\],cr8
12688 +
12689 +[0-9a-f]* <memc>:
12690 + *[0-9a-f]*: f6 10 00 00 memc 0,0x0
12691 + *[0-9a-f]*: f6 1f ff ff memc -4,0x1f
12692 + *[0-9a-f]*: f6 18 40 00 memc -65536,0x10
12693 + *[0-9a-f]*: f6 17 bf ff memc 65532,0xf
12694 +
12695 +[0-9a-f]* <mems>:
12696 + *[0-9a-f]*: f8 10 00 00 mems 0,0x0
12697 + *[0-9a-f]*: f8 1f ff ff mems -4,0x1f
12698 + *[0-9a-f]*: f8 18 40 00 mems -65536,0x10
12699 + *[0-9a-f]*: f8 17 bf ff mems 65532,0xf
12700 +
12701 +[0-9a-f]* <memt>:
12702 + *[0-9a-f]*: fa 10 00 00 memt 0,0x0
12703 + *[0-9a-f]*: fa 1f ff ff memt -4,0x1f
12704 + *[0-9a-f]*: fa 18 40 00 memt -65536,0x10
12705 + *[0-9a-f]*: fa 17 bf ff memt 65532,0xf
12706 +
12707 +[0-9a-f]* <stcond>:
12708 + *[0-9a-f]*: e1 70 00 00 stcond r0\[0\],r0
12709 + *[0-9a-f]*: ff 7f ff ff stcond pc\[-1\],pc
12710 + *[0-9a-f]*: f1 77 80 00 stcond r8\[-32768\],r7
12711 + *[0-9a-f]*: ef 78 7f ff stcond r7\[32767\],r8
12712 + *[0-9a-f]*: eb 7a 12 34 stcond r5\[4660\],r10
12713 +
12714 +[0-9a-f]* <ldcm_w>:
12715 + *[0-9a-f]*: ed af 00 ff ldcm\.w cp0,pc,cr0-cr7
12716 + *[0-9a-f]*: ed a0 e0 01 ldcm\.w cp7,r0,cr0
12717 + *[0-9a-f]*: ed a4 90 7f ldcm\.w cp4,r4\+\+,cr0-cr6
12718 + *[0-9a-f]*: ed a7 60 80 ldcm\.w cp3,r7,cr7
12719 + *[0-9a-f]*: ed ac 30 72 ldcm\.w cp1,r12\+\+,cr1,cr4-cr6
12720 + *[0-9a-f]*: ed af 01 ff ldcm\.w cp0,pc,cr8-cr15
12721 + *[0-9a-f]*: ed a0 e1 01 ldcm\.w cp7,r0,cr8
12722 + *[0-9a-f]*: ed a4 91 7f ldcm\.w cp4,r4\+\+,cr8-cr14
12723 + *[0-9a-f]*: ed a7 61 80 ldcm\.w cp3,r7,cr15
12724 + *[0-9a-f]*: ed ac 31 72 ldcm\.w cp1,r12\+\+,cr9,cr12-cr14
12725 +
12726 +[0-9a-f]* <ldcm_d>:
12727 + *[0-9a-f]*: ed af 04 ff ldcm\.d cp0,pc,cr0-cr15
12728 + *[0-9a-f]*: ed a0 e4 01 ldcm\.d cp7,r0,cr0-cr1
12729 + *[0-9a-f]*: ed a4 94 7f ldcm\.d cp4,r4\+\+,cr0-cr13
12730 + *[0-9a-f]*: ed a7 64 80 ldcm\.d cp3,r7,cr14-cr15
12731 + *[0-9a-f]*: ed ac 54 93 ldcm\.d cp2,r12\+\+,cr0-cr3,cr8-cr9,cr14-cr15
12732 +
12733 +[0-9a-f]* <stcm_w>:
12734 + *[0-9a-f]*: ed af 02 ff stcm\.w cp0,pc,cr0-cr7
12735 + *[0-9a-f]*: ed a0 e2 01 stcm\.w cp7,r0,cr0
12736 + *[0-9a-f]*: ed a4 92 7f stcm\.w cp4,--r4,cr0-cr6
12737 + *[0-9a-f]*: ed a7 62 80 stcm\.w cp3,r7,cr7
12738 + *[0-9a-f]*: ed ac 32 72 stcm\.w cp1,--r12,cr1,cr4-cr6
12739 + *[0-9a-f]*: ed af 03 ff stcm\.w cp0,pc,cr8-cr15
12740 + *[0-9a-f]*: ed a0 e3 01 stcm\.w cp7,r0,cr8
12741 + *[0-9a-f]*: ed a4 93 7f stcm\.w cp4,--r4,cr8-cr14
12742 + *[0-9a-f]*: ed a7 63 80 stcm\.w cp3,r7,cr15
12743 + *[0-9a-f]*: ed ac 33 72 stcm\.w cp1,--r12,cr9,cr12-cr14
12744 +
12745 +[0-9a-f]* <stcm_d>:
12746 + *[0-9a-f]*: ed af 05 ff stcm\.d cp0,pc,cr0-cr15
12747 + *[0-9a-f]*: ed a0 e5 01 stcm\.d cp7,r0,cr0-cr1
12748 + *[0-9a-f]*: ed a4 95 7f stcm\.d cp4,--r4,cr0-cr13
12749 + *[0-9a-f]*: ed a7 65 80 stcm\.d cp3,r7,cr14-cr15
12750 + *[0-9a-f]*: ed ac 55 93 stcm\.d cp2,--r12,cr0-cr3,cr8-cr9,cr14-cr15
12751 +
12752 +[0-9a-f]* <mvcr_w>:
12753 + *[0-9a-f]*: ef af ef 00 mvcr\.w cp7,pc,cr15
12754 + *[0-9a-f]*: ef a0 00 00 mvcr\.w cp0,r0,cr0
12755 + *[0-9a-f]*: ef af 0f 00 mvcr\.w cp0,pc,cr15
12756 + *[0-9a-f]*: ef a0 ef 00 mvcr\.w cp7,r0,cr15
12757 + *[0-9a-f]*: ef af e0 00 mvcr\.w cp7,pc,cr0
12758 + *[0-9a-f]*: ef a7 88 00 mvcr\.w cp4,r7,cr8
12759 + *[0-9a-f]*: ef a8 67 00 mvcr\.w cp3,r8,cr7
12760 +
12761 +[0-9a-f]* <mvcr_d>:
12762 + *[0-9a-f]*: ef ae ee 10 mvcr\.d cp7,lr,cr14
12763 + *[0-9a-f]*: ef a0 00 10 mvcr\.d cp0,r0,cr0
12764 + *[0-9a-f]*: ef ae 0e 10 mvcr\.d cp0,lr,cr14
12765 + *[0-9a-f]*: ef a0 ee 10 mvcr\.d cp7,r0,cr14
12766 + *[0-9a-f]*: ef ae e0 10 mvcr\.d cp7,lr,cr0
12767 + *[0-9a-f]*: ef a6 88 10 mvcr\.d cp4,r6,cr8
12768 + *[0-9a-f]*: ef a8 66 10 mvcr\.d cp3,r8,cr6
12769 +
12770 +[0-9a-f]* <mvrc_w>:
12771 + *[0-9a-f]*: ef af ef 20 mvrc\.w cp7,cr15,pc
12772 + *[0-9a-f]*: ef a0 00 20 mvrc\.w cp0,cr0,r0
12773 + *[0-9a-f]*: ef af 0f 20 mvrc\.w cp0,cr15,pc
12774 + *[0-9a-f]*: ef a0 ef 20 mvrc\.w cp7,cr15,r0
12775 + *[0-9a-f]*: ef af e0 20 mvrc\.w cp7,cr0,pc
12776 + *[0-9a-f]*: ef a7 88 20 mvrc\.w cp4,cr8,r7
12777 + *[0-9a-f]*: ef a8 67 20 mvrc\.w cp3,cr7,r8
12778 +
12779 +[0-9a-f]* <mvrc_d>:
12780 + *[0-9a-f]*: ef ae ee 30 mvrc\.d cp7,cr14,lr
12781 + *[0-9a-f]*: ef a0 00 30 mvrc\.d cp0,cr0,r0
12782 + *[0-9a-f]*: ef ae 0e 30 mvrc\.d cp0,cr14,lr
12783 + *[0-9a-f]*: ef a0 ee 30 mvrc\.d cp7,cr14,r0
12784 + *[0-9a-f]*: ef ae e0 30 mvrc\.d cp7,cr0,lr
12785 + *[0-9a-f]*: ef a6 88 30 mvrc\.d cp4,cr8,r6
12786 + *[0-9a-f]*: ef a8 66 30 mvrc\.d cp3,cr6,r8
12787 +
12788 +[0-9a-f]* <bfexts>:
12789 + *[0-9a-f]*: ff df b3 ff bfexts pc,pc,0x1f,0x1f
12790 + *[0-9a-f]*: e1 d0 b0 00 bfexts r0,r0,0x0,0x0
12791 + *[0-9a-f]*: e1 df b3 ff bfexts r0,pc,0x1f,0x1f
12792 + *[0-9a-f]*: ff d0 b3 ff bfexts pc,r0,0x1f,0x1f
12793 + *[0-9a-f]*: ff df b0 1f bfexts pc,pc,0x0,0x1f
12794 + *[0-9a-f]*: ff df b3 e0 bfexts pc,pc,0x1f,0x0
12795 + *[0-9a-f]*: ef d8 b1 f0 bfexts r7,r8,0xf,0x10
12796 + *[0-9a-f]*: f1 d7 b2 0f bfexts r8,r7,0x10,0xf
12797 +
12798 +[0-9a-f]* <bfextu>:
12799 + *[0-9a-f]*: ff df c3 ff bfextu pc,pc,0x1f,0x1f
12800 + *[0-9a-f]*: e1 d0 c0 00 bfextu r0,r0,0x0,0x0
12801 + *[0-9a-f]*: e1 df c3 ff bfextu r0,pc,0x1f,0x1f
12802 + *[0-9a-f]*: ff d0 c3 ff bfextu pc,r0,0x1f,0x1f
12803 + *[0-9a-f]*: ff df c0 1f bfextu pc,pc,0x0,0x1f
12804 + *[0-9a-f]*: ff df c3 e0 bfextu pc,pc,0x1f,0x0
12805 + *[0-9a-f]*: ef d8 c1 f0 bfextu r7,r8,0xf,0x10
12806 + *[0-9a-f]*: f1 d7 c2 0f bfextu r8,r7,0x10,0xf
12807 +
12808 +[0-9a-f]* <bfins>:
12809 + *[0-9a-f]*: ff df d3 ff bfins pc,pc,0x1f,0x1f
12810 + *[0-9a-f]*: e1 d0 d0 00 bfins r0,r0,0x0,0x0
12811 + *[0-9a-f]*: e1 df d3 ff bfins r0,pc,0x1f,0x1f
12812 + *[0-9a-f]*: ff d0 d3 ff bfins pc,r0,0x1f,0x1f
12813 + *[0-9a-f]*: ff df d0 1f bfins pc,pc,0x0,0x1f
12814 + *[0-9a-f]*: ff df d3 e0 bfins pc,pc,0x1f,0x0
12815 + *[0-9a-f]*: ef d8 d1 f0 bfins r7,r8,0xf,0x10
12816 + *[0-9a-f]*: f1 d7 d2 0f bfins r8,r7,0x10,0xf
12817 +
12818 +[0-9a-f]* <rsubc>:
12819 + *[0-9a-f]*: fb bf 00 00 rsubeq pc,0
12820 + *[0-9a-f]*: fb bc 0f ff rsubal r12,-1
12821 + *[0-9a-f]*: fb b5 08 80 rsubls r5,-128
12822 + *[0-9a-f]*: fb b4 07 7f rsubpl r4,127
12823 + *[0-9a-f]*: fb be 01 01 rsubne lr,1
12824 + *[0-9a-f]*: fb bc 08 76 rsubls r12,118
12825 + *[0-9a-f]*: fb be 0d f4 rsubvc lr,-12
12826 + *[0-9a-f]*: fb b4 06 f3 rsubmi r4,-13
12827 +
12828 +[0-9a-f]* <addc>:
12829 + *[0-9a-f]*: ff df e0 0f addeq pc,pc,pc
12830 + *[0-9a-f]*: f9 dc ef 0c addal r12,r12,r12
12831 + *[0-9a-f]*: eb d5 e8 05 addls r5,r5,r5
12832 + *[0-9a-f]*: e9 d4 e7 04 addpl r4,r4,r4
12833 + *[0-9a-f]*: fd de e1 0e addne lr,lr,lr
12834 + *[0-9a-f]*: e5 d1 e8 0a addls r10,r2,r1
12835 + *[0-9a-f]*: f1 db ed 0c addvc r12,r8,r11
12836 + *[0-9a-f]*: ef d0 e6 0a addmi r10,r7,r0
12837 +
12838 +[0-9a-f]* <subc2>:
12839 + *[0-9a-f]*: ff df e0 1f subeq pc,pc,pc
12840 + *[0-9a-f]*: f9 dc ef 1c subal r12,r12,r12
12841 + *[0-9a-f]*: eb d5 e8 15 subls r5,r5,r5
12842 + *[0-9a-f]*: e9 d4 e7 14 subpl r4,r4,r4
12843 + *[0-9a-f]*: fd de e1 1e subne lr,lr,lr
12844 + *[0-9a-f]*: e5 d1 e8 1a subls r10,r2,r1
12845 + *[0-9a-f]*: f1 db ed 1c subvc r12,r8,r11
12846 + *[0-9a-f]*: ef d0 e6 1a submi r10,r7,r0
12847 +
12848 +[0-9a-f]* <andc>:
12849 + *[0-9a-f]*: ff df e0 2f andeq pc,pc,pc
12850 + *[0-9a-f]*: f9 dc ef 2c andal r12,r12,r12
12851 + *[0-9a-f]*: eb d5 e8 25 andls r5,r5,r5
12852 + *[0-9a-f]*: e9 d4 e7 24 andpl r4,r4,r4
12853 + *[0-9a-f]*: fd de e1 2e andne lr,lr,lr
12854 + *[0-9a-f]*: e5 d1 e8 2a andls r10,r2,r1
12855 + *[0-9a-f]*: f1 db ed 2c andvc r12,r8,r11
12856 + *[0-9a-f]*: ef d0 e6 2a andmi r10,r7,r0
12857 +
12858 +[0-9a-f]* <orc>:
12859 + *[0-9a-f]*: ff df e0 3f oreq pc,pc,pc
12860 + *[0-9a-f]*: f9 dc ef 3c oral r12,r12,r12
12861 + *[0-9a-f]*: eb d5 e8 35 orls r5,r5,r5
12862 + *[0-9a-f]*: e9 d4 e7 34 orpl r4,r4,r4
12863 + *[0-9a-f]*: fd de e1 3e orne lr,lr,lr
12864 + *[0-9a-f]*: e5 d1 e8 3a orls r10,r2,r1
12865 + *[0-9a-f]*: f1 db ed 3c orvc r12,r8,r11
12866 + *[0-9a-f]*: ef d0 e6 3a ormi r10,r7,r0
12867 +
12868 +[0-9a-f]* <eorc>:
12869 + *[0-9a-f]*: ff df e0 4f eoreq pc,pc,pc
12870 + *[0-9a-f]*: f9 dc ef 4c eoral r12,r12,r12
12871 + *[0-9a-f]*: eb d5 e8 45 eorls r5,r5,r5
12872 + *[0-9a-f]*: e9 d4 e7 44 eorpl r4,r4,r4
12873 + *[0-9a-f]*: fd de e1 4e eorne lr,lr,lr
12874 + *[0-9a-f]*: e5 d1 e8 4a eorls r10,r2,r1
12875 + *[0-9a-f]*: f1 db ed 4c eorvc r12,r8,r11
12876 + *[0-9a-f]*: ef d0 e6 4a eormi r10,r7,r0
12877 +
12878 +[0-9a-f]* <ldcond>:
12879 + *[0-9a-f]*: ff ff 01 ff ld.weq pc,pc[0x7fc]
12880 + *[0-9a-f]*: f9 fc f3 ff ld.shal r12,r12[0x3fe]
12881 + *[0-9a-f]*: eb f5 84 00 ld.shls r5,r5[0x0]
12882 + *[0-9a-f]*: e9 f4 79 ff ld.ubpl r4,r4[0x1ff]
12883 + *[0-9a-f]*: fd fe 16 00 ld.sbne lr,lr[0x0]
12884 + *[0-9a-f]*: e5 fa 80 00 ld.wls r10,r2[0x0]
12885 + *[0-9a-f]*: f1 fc d3 ff ld.shvc r12,r8[0x3fe]
12886 + *[0-9a-f]*: ef fa 68 01 ld.ubmi r10,r7[0x1]
12887 +
12888 +[0-9a-f]* <stcond2>:
12889 + *[0-9a-f]*: ff ff 0b ff st.weq pc[0x7fc],pc
12890 + *[0-9a-f]*: f9 fc fd ff st.hal r12[0x3fe],r12
12891 + *[0-9a-f]*: eb f5 8c 00 st.hls r5[0x0],r5
12892 + *[0-9a-f]*: e9 f4 7f ff st.bpl r4[0x1ff],r4
12893 + *[0-9a-f]*: fd fe 1e 00 st.bne lr[0x0],lr
12894 + *[0-9a-f]*: e5 fa 8a 00 st.wls r2[0x0],r10
12895 + *[0-9a-f]*: f1 fc dd ff st.hvc r8[0x3fe],r12
12896 + *[0-9a-f]*: ef fa 6e 01 st.bmi r7[0x1],r10
12897 +
12898 +[0-9a-f]* <movh>:
12899 + *[0-9a-f]*: fc 1f ff ff movh pc,0xffff
12900 + *[0-9a-f]*: fc 10 00 00 movh r0,0x0
12901 + *[0-9a-f]*: fc 15 00 01 movh r5,0x1
12902 + *[0-9a-f]*: fc 1c 7f ff movh r12,0x7fff
12903 +
12904 --- /dev/null
12905 +++ b/gas/testsuite/gas/avr32/allinsn.exp
12906 @@ -0,0 +1,5 @@
12907 +# AVR32 assembler testsuite. -*- Tcl -*-
12908 +
12909 +if [istarget avr32-*-*] {
12910 + run_dump_test "allinsn"
12911 +}
12912 --- /dev/null
12913 +++ b/gas/testsuite/gas/avr32/allinsn.s
12914 @@ -0,0 +1,3330 @@
12915 + .data
12916 +foodata: .word 42
12917 + .text
12918 +footext:
12919 + .text
12920 + .global ld_d5
12921 +ld_d5:
12922 + ld.d lr,pc[pc<<3]
12923 + ld.d r0,r0[r0<<0]
12924 + ld.d r6,r5[r5<<2]
12925 + ld.d r4,r4[r4<<1]
12926 + ld.d lr,lr[lr<<1]
12927 + ld.d r10,r3[sp<<2]
12928 + ld.d r8,r10[r6<<2]
12929 + ld.d r2,r7[r9<<0]
12930 + .text
12931 + .global ld_w5
12932 +ld_w5:
12933 + ld.w pc,pc[pc<<0]
12934 + ld.w r12,r12[r12<<3]
12935 + ld.w r5,r5[r5<<2]
12936 + ld.w r4,r4[r4<<1]
12937 + ld.w lr,lr[lr<<1]
12938 + ld.w r2,r9[r9<<0]
12939 + ld.w r11,r2[r6<<0]
12940 + ld.w r0,r2[sp<<3]
12941 + .text
12942 + .global ld_sh5
12943 +ld_sh5:
12944 + ld.sh pc,pc[pc<<0]
12945 + ld.sh r12,r12[r12<<3]
12946 + ld.sh r5,r5[r5<<2]
12947 + ld.sh r4,r4[r4<<1]
12948 + ld.sh lr,lr[lr<<1]
12949 + ld.sh r11,r0[pc<<2]
12950 + ld.sh r10,sp[r6<<2]
12951 + ld.sh r12,r2[r2<<0]
12952 + .text
12953 + .global ld_uh5
12954 +ld_uh5:
12955 + ld.uh pc,pc[pc<<0]
12956 + ld.uh r12,r12[r12<<3]
12957 + ld.uh r5,r5[r5<<2]
12958 + ld.uh r4,r4[r4<<1]
12959 + ld.uh lr,lr[lr<<1]
12960 + ld.uh r8,pc[lr<<3]
12961 + ld.uh r6,r1[pc<<1]
12962 + ld.uh r6,lr[sp<<1]
12963 + .text
12964 + .global ld_sb2
12965 +ld_sb2:
12966 + ld.sb pc,pc[pc<<0]
12967 + ld.sb r12,r12[r12<<3]
12968 + ld.sb r5,r5[r5<<2]
12969 + ld.sb r4,r4[r4<<1]
12970 + ld.sb lr,lr[lr<<1]
12971 + ld.sb r9,r1[pc<<3]
12972 + ld.sb r0,r3[r11<<1]
12973 + ld.sb r10,r5[r5<<1]
12974 + .text
12975 + .global ld_ub5
12976 +ld_ub5:
12977 + ld.ub pc,pc[pc<<0]
12978 + ld.ub r12,r12[r12<<3]
12979 + ld.ub r5,r5[r5<<2]
12980 + ld.ub r4,r4[r4<<1]
12981 + ld.ub lr,lr[lr<<1]
12982 + ld.ub r6,r12[r7<<3]
12983 + ld.ub r2,r6[r12<<0]
12984 + ld.ub r0,r7[r11<<1]
12985 + .text
12986 + .global st_d5
12987 +st_d5:
12988 + st.d pc[pc<<0],r14
12989 + st.d r12[r12<<3],r12
12990 + st.d r5[r5<<2],r6
12991 + st.d r4[r4<<1],r4
12992 + st.d lr[lr<<1],lr
12993 + st.d r1[r9<<1],r4
12994 + st.d r10[r2<<1],r4
12995 + st.d r12[r6<<0],lr
12996 + .text
12997 + .global st_w5
12998 +st_w5:
12999 + st.w pc[pc<<0],pc
13000 + st.w r12[r12<<3],r12
13001 + st.w r5[r5<<2],r5
13002 + st.w r4[r4<<1],r4
13003 + st.w lr[lr<<1],lr
13004 + st.w r1[r10<<0],r3
13005 + st.w r0[r10<<1],r9
13006 + st.w r4[r5<<3],pc
13007 + .text
13008 + .global st_h5
13009 +st_h5:
13010 + st.h pc[pc<<0],pc
13011 + st.h r12[r12<<3],r12
13012 + st.h r5[r5<<2],r5
13013 + st.h r4[r4<<1],r4
13014 + st.h lr[lr<<1],lr
13015 + st.h r2[r9<<0],r11
13016 + st.h r5[r1<<2],r12
13017 + st.h pc[r8<<2],r3
13018 + .text
13019 + .global st_b5
13020 +st_b5:
13021 + st.b pc[pc<<0],pc
13022 + st.b r12[r12<<3],r12
13023 + st.b r5[r5<<2],r5
13024 + st.b r4[r4<<1],r4
13025 + st.b lr[lr<<1],lr
13026 + st.b r1[r8<<1],r6
13027 + st.b lr[lr<<3],r1
13028 + st.b r5[r0<<2],pc
13029 + .text
13030 + .global divs
13031 +divs:
13032 + divs pc,pc,pc
13033 + divs r12,r12,r12
13034 + divs r5,r5,r5
13035 + divs r4,r4,r4
13036 + divs lr,lr,lr
13037 + divs r3,pc,pc
13038 + divs r9,r12,r2
13039 + divs r7,r4,r1
13040 + .text
13041 + .global add1
13042 +add1:
13043 + add pc,pc
13044 + add r12,r12
13045 + add r5,r5
13046 + add r4,r4
13047 + add lr,lr
13048 + add r12,r9
13049 + add r6,r3
13050 + add r10,r12
13051 + .text
13052 + .global sub1
13053 +sub1:
13054 + sub pc,pc
13055 + sub r12,r12
13056 + sub r5,r5
13057 + sub r4,r4
13058 + sub lr,lr
13059 + sub lr,r6
13060 + sub r0,sp
13061 + sub r6,r12
13062 + .text
13063 + .global rsub1
13064 +rsub1:
13065 + rsub pc,pc
13066 + rsub r12,r12
13067 + rsub r5,r5
13068 + rsub r4,r4
13069 + rsub lr,lr
13070 + rsub r11,sp
13071 + rsub r7,r4
13072 + rsub r9,r1
13073 + .text
13074 + .global cp1
13075 +cp1:
13076 + cp pc,pc
13077 + cp r12,r12
13078 + cp r5,r5
13079 + cp r4,r4
13080 + cp lr,lr
13081 + cp r6,r2
13082 + cp r0,r9
13083 + cp r3,sp
13084 + .text
13085 + .global or1
13086 +or1:
13087 + or pc,pc
13088 + or r12,r12
13089 + or r5,r5
13090 + or r4,r4
13091 + or lr,lr
13092 + or r4,r9
13093 + or r11,r4
13094 + or r4,r0
13095 + .text
13096 + .global eor1
13097 +eor1:
13098 + eor pc,pc
13099 + eor r12,r12
13100 + eor r5,r5
13101 + eor r4,r4
13102 + eor lr,lr
13103 + eor r12,r11
13104 + eor r0,r1
13105 + eor r5,pc
13106 + .text
13107 + .global and1
13108 +and1:
13109 + and pc,pc
13110 + and r12,r12
13111 + and r5,r5
13112 + and r4,r4
13113 + and lr,lr
13114 + and r8,r1
13115 + and r0,sp
13116 + and r10,r5
13117 + .text
13118 + .global tst
13119 +tst:
13120 + tst pc,pc
13121 + tst r12,r12
13122 + tst r5,r5
13123 + tst r4,r4
13124 + tst lr,lr
13125 + tst r0,r12
13126 + tst r10,r6
13127 + tst sp,r4
13128 + .text
13129 + .global andn
13130 +andn:
13131 + andn pc,pc
13132 + andn r12,r12
13133 + andn r5,r5
13134 + andn r4,r4
13135 + andn lr,lr
13136 + andn r9,r12
13137 + andn r11,sp
13138 + andn r12,r5
13139 + .text
13140 + .global mov3
13141 +mov3:
13142 + mov pc,pc
13143 + mov r12,r12
13144 + mov r5,r5
13145 + mov r4,r4
13146 + mov lr,lr
13147 + mov r5,r9
13148 + mov r11,r11
13149 + mov r2,lr
13150 + .text
13151 + .global st_w1
13152 +st_w1:
13153 + st.w pc++,pc
13154 + st.w r12++,r12
13155 + st.w r5++,r5
13156 + st.w r4++,r4
13157 + st.w lr++,lr
13158 + st.w r1++,r11
13159 + st.w sp++,r0
13160 + st.w sp++,r1
13161 + .text
13162 + .global st_h1
13163 +st_h1:
13164 + st.h pc++,pc
13165 + st.h r12++,r12
13166 + st.h r5++,r5
13167 + st.h r4++,r4
13168 + st.h lr++,lr
13169 + st.h r12++,sp
13170 + st.h r7++,lr
13171 + st.h r7++,r4
13172 + .text
13173 + .global st_b1
13174 +st_b1:
13175 + st.b pc++,pc
13176 + st.b r12++,r12
13177 + st.b r5++,r5
13178 + st.b r4++,r4
13179 + st.b lr++,lr
13180 + st.b r9++,sp
13181 + st.b r1++,sp
13182 + st.b r0++,r4
13183 + .text
13184 + .global st_w2
13185 +st_w2:
13186 + st.w --pc,pc
13187 + st.w --r12,r12
13188 + st.w --r5,r5
13189 + st.w --r4,r4
13190 + st.w --lr,lr
13191 + st.w --r1,r7
13192 + st.w --r3,r9
13193 + st.w --r5,r5
13194 + .text
13195 + .global st_h2
13196 +st_h2:
13197 + st.h --pc,pc
13198 + st.h --r12,r12
13199 + st.h --r5,r5
13200 + st.h --r4,r4
13201 + st.h --lr,lr
13202 + st.h --r5,r7
13203 + st.h --r8,r8
13204 + st.h --r7,r2
13205 + .text
13206 + .global st_b2
13207 +st_b2:
13208 + st.b --pc,pc
13209 + st.b --r12,r12
13210 + st.b --r5,r5
13211 + st.b --r4,r4
13212 + st.b --lr,lr
13213 + st.b --sp,sp
13214 + st.b --sp,r11
13215 + st.b --r4,r5
13216 + .text
13217 + .global ld_w1
13218 +ld_w1:
13219 + ld.w pc,pc++
13220 + ld.w r12,r12++
13221 + ld.w r5,r5++
13222 + ld.w r4,r4++
13223 + ld.w lr,lr++
13224 + ld.w r3,r7++
13225 + ld.w r3,lr++
13226 + ld.w r12,r5++
13227 + .text
13228 + .global ld_sh1
13229 +ld_sh1:
13230 + ld.sh pc,pc++
13231 + ld.sh r12,r12++
13232 + ld.sh r5,r5++
13233 + ld.sh r4,r4++
13234 + ld.sh lr,lr++
13235 + ld.sh r11,r2++
13236 + ld.sh r2,r8++
13237 + ld.sh r7,r6++
13238 + .text
13239 + .global ld_uh1
13240 +ld_uh1:
13241 + ld.uh pc,pc++
13242 + ld.uh r12,r12++
13243 + ld.uh r5,r5++
13244 + ld.uh r4,r4++
13245 + ld.uh lr,lr++
13246 + ld.uh r6,r7++
13247 + ld.uh r10,r11++
13248 + ld.uh lr,r4++
13249 + .text
13250 + .global ld_ub1
13251 +ld_ub1:
13252 + ld.ub pc,pc++
13253 + ld.ub r12,r12++
13254 + ld.ub r5,r5++
13255 + ld.ub r4,r4++
13256 + ld.ub lr,lr++
13257 + ld.ub r8,lr++
13258 + ld.ub r12,r12++
13259 + ld.ub r11,r10++
13260 + .text
13261 + .global ld_w2
13262 +ld_w2:
13263 + ld.w pc,--pc
13264 + ld.w r12,--r12
13265 + ld.w r5,--r5
13266 + ld.w r4,--r4
13267 + ld.w lr,--lr
13268 + ld.w r10,--lr
13269 + ld.w r12,--r9
13270 + ld.w r6,--r5
13271 + .text
13272 + .global ld_sh2
13273 +ld_sh2:
13274 + ld.sh pc,--pc
13275 + ld.sh r12,--r12
13276 + ld.sh r5,--r5
13277 + ld.sh r4,--r4
13278 + ld.sh lr,--lr
13279 + ld.sh pc,--r10
13280 + ld.sh r6,--r3
13281 + ld.sh r4,--r6
13282 + .text
13283 + .global ld_uh2
13284 +ld_uh2:
13285 + ld.uh pc,--pc
13286 + ld.uh r12,--r12
13287 + ld.uh r5,--r5
13288 + ld.uh r4,--r4
13289 + ld.uh lr,--lr
13290 + ld.uh r3,--r2
13291 + ld.uh r1,--r0
13292 + ld.uh r2,--r9
13293 + .text
13294 + .global ld_ub2
13295 +ld_ub2:
13296 + ld.ub pc,--pc
13297 + ld.ub r12,--r12
13298 + ld.ub r5,--r5
13299 + ld.ub r4,--r4
13300 + ld.ub lr,--lr
13301 + ld.ub r1,--r1
13302 + ld.ub r0,--r6
13303 + ld.ub r2,--r7
13304 + .text
13305 + .global ld_ub3
13306 +ld_ub3:
13307 + ld.ub pc,pc[0]
13308 + ld.ub r12,r12[7]
13309 + ld.ub r5,r5[4]
13310 + ld.ub r4,r4[3]
13311 + ld.ub lr,lr[1]
13312 + ld.ub r6,r9[6]
13313 + ld.ub r2,lr[4]
13314 + ld.ub r1,r8[0]
13315 + .text
13316 + .global sub3_sp
13317 +sub3_sp:
13318 + sub sp,0
13319 + sub sp,-4
13320 + sub sp,-512
13321 + sub sp,508
13322 + sub sp,4
13323 + sub sp,44
13324 + sub sp,8
13325 + sub sp,348
13326 + .text
13327 + .global sub3
13328 +sub3:
13329 + sub pc,0
13330 + sub r12,-1
13331 + sub r5,-128
13332 + sub r4,127
13333 + sub lr,1
13334 + sub r6,-41
13335 + sub r4,37
13336 + sub r12,56
13337 + .text
13338 + .global mov1
13339 +mov1:
13340 + mov pc,0
13341 + mov r12,-1
13342 + mov r5,-128
13343 + mov r4,127
13344 + mov lr,1
13345 + mov pc,14
13346 + mov r6,-100
13347 + mov lr,-122
13348 + .text
13349 + .global lddsp
13350 +lddsp:
13351 + lddsp pc,sp[0]
13352 + lddsp r12,sp[508]
13353 + lddsp r5,sp[256]
13354 + lddsp r4,sp[252]
13355 + lddsp lr,sp[4]
13356 + lddsp lr,sp[256]
13357 + lddsp r12,sp[20]
13358 + lddsp r9,sp[472]
13359 + .text
13360 + .global lddpc
13361 +lddpc:
13362 + lddpc pc,pc[0]
13363 + lddpc r0,pc[508]
13364 + lddpc r8,pc[256]
13365 + lddpc r7,pc[252]
13366 + lddpc lr,pc[4]
13367 + lddpc sp,pc[472]
13368 + lddpc r6,pc[120]
13369 + lddpc r11,pc[28]
13370 + .text
13371 + .global stdsp
13372 +stdsp:
13373 + stdsp sp[0],pc
13374 + stdsp sp[508],r12
13375 + stdsp sp[256],r5
13376 + stdsp sp[252],r4
13377 + stdsp sp[4],lr
13378 + stdsp sp[304],pc
13379 + stdsp sp[256],r0
13380 + stdsp sp[336],r5
13381 + .text
13382 + .global cp2
13383 +cp2:
13384 + cp pc,0
13385 + cp r12,-1
13386 + cp r5,-32
13387 + cp r4,31
13388 + cp lr,1
13389 + cp r8,3
13390 + cp lr,16
13391 + cp r7,-26
13392 + .text
13393 + .global acr
13394 +acr:
13395 + acr pc
13396 + acr r12
13397 + acr r5
13398 + acr r4
13399 + acr lr
13400 + acr r2
13401 + acr r12
13402 + acr pc
13403 + .text
13404 + .global scr
13405 +scr:
13406 + scr pc
13407 + scr r12
13408 + scr r5
13409 + scr r4
13410 + scr lr
13411 + scr pc
13412 + scr r6
13413 + scr r1
13414 + .text
13415 + .global cpc0
13416 +cpc0:
13417 + cpc pc
13418 + cpc r12
13419 + cpc r5
13420 + cpc r4
13421 + cpc lr
13422 + cpc pc
13423 + cpc r4
13424 + cpc r9
13425 + .text
13426 + .global neg
13427 +neg:
13428 + neg pc
13429 + neg r12
13430 + neg r5
13431 + neg r4
13432 + neg lr
13433 + neg r7
13434 + neg r1
13435 + neg r9
13436 + .text
13437 + .global abs
13438 +abs:
13439 + abs pc
13440 + abs r12
13441 + abs r5
13442 + abs r4
13443 + abs lr
13444 + abs r6
13445 + abs r6
13446 + abs r4
13447 + .text
13448 + .global castu_b
13449 +castu_b:
13450 + castu.b pc
13451 + castu.b r12
13452 + castu.b r5
13453 + castu.b r4
13454 + castu.b lr
13455 + castu.b r7
13456 + castu.b sp
13457 + castu.b r9
13458 + .text
13459 + .global casts_b
13460 +casts_b:
13461 + casts.b pc
13462 + casts.b r12
13463 + casts.b r5
13464 + casts.b r4
13465 + casts.b lr
13466 + casts.b r11
13467 + casts.b r1
13468 + casts.b r10
13469 + .text
13470 + .global castu_h
13471 +castu_h:
13472 + castu.h pc
13473 + castu.h r12
13474 + castu.h r5
13475 + castu.h r4
13476 + castu.h lr
13477 + castu.h r10
13478 + castu.h r11
13479 + castu.h r1
13480 + .text
13481 + .global casts_h
13482 +casts_h:
13483 + casts.h pc
13484 + casts.h r12
13485 + casts.h r5
13486 + casts.h r4
13487 + casts.h lr
13488 + casts.h r0
13489 + casts.h r5
13490 + casts.h r9
13491 + .text
13492 + .global brev
13493 +brev:
13494 + brev pc
13495 + brev r12
13496 + brev r5
13497 + brev r4
13498 + brev lr
13499 + brev r5
13500 + brev r10
13501 + brev r8
13502 + .text
13503 + .global swap_h
13504 +swap_h:
13505 + swap.h pc
13506 + swap.h r12
13507 + swap.h r5
13508 + swap.h r4
13509 + swap.h lr
13510 + swap.h r7
13511 + swap.h r0
13512 + swap.h r8
13513 + .text
13514 + .global swap_b
13515 +swap_b:
13516 + swap.b pc
13517 + swap.b r12
13518 + swap.b r5
13519 + swap.b r4
13520 + swap.b lr
13521 + swap.b r10
13522 + swap.b r12
13523 + swap.b r1
13524 + .text
13525 + .global swap_bh
13526 +swap_bh:
13527 + swap.bh pc
13528 + swap.bh r12
13529 + swap.bh r5
13530 + swap.bh r4
13531 + swap.bh lr
13532 + swap.bh r9
13533 + swap.bh r4
13534 + swap.bh r1
13535 + .text
13536 + .global One_s_compliment
13537 +One_s_compliment:
13538 + com pc
13539 + com r12
13540 + com r5
13541 + com r4
13542 + com lr
13543 + com r2
13544 + com r2
13545 + com r7
13546 + .text
13547 + .global tnbz
13548 +tnbz:
13549 + tnbz pc
13550 + tnbz r12
13551 + tnbz r5
13552 + tnbz r4
13553 + tnbz lr
13554 + tnbz r8
13555 + tnbz r12
13556 + tnbz pc
13557 + .text
13558 + .global rol
13559 +rol:
13560 + rol pc
13561 + rol r12
13562 + rol r5
13563 + rol r4
13564 + rol lr
13565 + rol r10
13566 + rol r9
13567 + rol r5
13568 + .text
13569 + .global ror
13570 +ror:
13571 + ror pc
13572 + ror r12
13573 + ror r5
13574 + ror r4
13575 + ror lr
13576 + ror r8
13577 + ror r4
13578 + ror r7
13579 + .text
13580 + .global icall
13581 +icall:
13582 + icall pc
13583 + icall r12
13584 + icall r5
13585 + icall r4
13586 + icall lr
13587 + icall r3
13588 + icall r1
13589 + icall r3
13590 + .text
13591 + .global mustr
13592 +mustr:
13593 + mustr pc
13594 + mustr r12
13595 + mustr r5
13596 + mustr r4
13597 + mustr lr
13598 + mustr r1
13599 + mustr r4
13600 + mustr r12
13601 + .text
13602 + .global musfr
13603 +musfr:
13604 + musfr pc
13605 + musfr r12
13606 + musfr r5
13607 + musfr r4
13608 + musfr lr
13609 + musfr r11
13610 + musfr r12
13611 + musfr r2
13612 + .text
13613 + .global ret_cond
13614 +ret_cond:
13615 + reteq pc
13616 + retal r12
13617 + retls r5
13618 + retpl r4
13619 + retne lr
13620 + retgt r0
13621 + retgt r12
13622 + retge r10
13623 + .text
13624 + .global sr_cond
13625 +sr_cond:
13626 + sreq pc
13627 + sral r12
13628 + srls r5
13629 + srpl r4
13630 + srne lr
13631 + srlt r0
13632 + sral sp
13633 + srge r9
13634 + .text
13635 + .global ld_w3
13636 +ld_w3:
13637 + ld.w pc,pc[0]
13638 + ld.w r12,r12[124]
13639 + ld.w r5,r5[64]
13640 + ld.w r4,r4[60]
13641 + ld.w lr,lr[4]
13642 + ld.w sp,r2[52]
13643 + ld.w r9,r1[8]
13644 + ld.w r5,sp[60]
13645 + .text
13646 + .global ld_sh3
13647 +ld_sh3:
13648 + ld.sh pc,pc[0]
13649 + ld.sh r12,r12[14]
13650 + ld.sh r5,r5[8]
13651 + ld.sh r4,r4[6]
13652 + ld.sh lr,lr[2]
13653 + ld.sh r4,r2[8]
13654 + ld.sh sp,lr[10]
13655 + ld.sh r2,r11[2]
13656 + .text
13657 + .global ld_uh3
13658 +ld_uh3:
13659 + ld.uh pc,pc[0]
13660 + ld.uh r12,r12[14]
13661 + ld.uh r5,r5[8]
13662 + ld.uh r4,r4[6]
13663 + ld.uh lr,lr[2]
13664 + ld.uh r10,r0[10]
13665 + ld.uh r8,r11[8]
13666 + ld.uh r10,r2[12]
13667 + .text
13668 + .global st_w3
13669 +st_w3:
13670 + st.w pc[0],pc
13671 + st.w r12[60],r12
13672 + st.w r5[32],r5
13673 + st.w r4[28],r4
13674 + st.w lr[4],lr
13675 + st.w r7[44],r11
13676 + st.w r2[24],r6
13677 + st.w r4[12],r9
13678 + .text
13679 + .global st_h3
13680 +st_h3:
13681 + st.h pc[0],pc
13682 + st.h r12[14],r12
13683 + st.h r5[8],r5
13684 + st.h r4[6],r4
13685 + st.h lr[2],lr
13686 + st.h lr[10],r12
13687 + st.h r6[4],r0
13688 + st.h r5[12],sp
13689 + .text
13690 + .global st_b3
13691 +st_b3:
13692 + st.b pc[0],pc
13693 + st.b r12[7],r12
13694 + st.b r5[4],r5
13695 + st.b r4[3],r4
13696 + st.b lr[1],lr
13697 + st.b r12[6],r9
13698 + st.b r2[3],lr
13699 + st.b r1[3],r11
13700 + .text
13701 + .global ldd
13702 +ldd:
13703 + ld.d r0,pc
13704 + ld.d r14,r12
13705 + ld.d r8,r5
13706 + ld.d r6,r4
13707 + ld.d r2,lr
13708 + ld.d r14,r7
13709 + ld.d r4,r4
13710 + ld.d r14,pc
13711 + .text
13712 + .global ldd_postinc
13713 +ldd_postinc:
13714 + ld.d r0,pc++
13715 + ld.d r14,r12++
13716 + ld.d r8,r5++
13717 + ld.d r6,r4++
13718 + ld.d r2,lr++
13719 + ld.d r14,r5++
13720 + ld.d r12,r11++
13721 + ld.d r2,r12++
13722 + .text
13723 + .global ldd_predec
13724 +ldd_predec:
13725 + ld.d r0,--pc
13726 + ld.d r14,--r12
13727 + ld.d r8,--r5
13728 + ld.d r6,--r4
13729 + ld.d r2,--lr
13730 + ld.d r8,--r0
13731 + ld.d r10,--pc
13732 + ld.d r2,--r4
13733 + .text
13734 + .global std
13735 +std:
13736 + st.d pc,r0
13737 + st.d r12,r14
13738 + st.d r5,r8
13739 + st.d r4,r6
13740 + st.d lr,r2
13741 + st.d r0,r12
13742 + st.d sp,r4
13743 + st.d r12,r12
13744 + .text
13745 + .global std_postinc
13746 +std_postinc:
13747 + st.d pc++,r0
13748 + st.d r12++,r14
13749 + st.d r5++,r8
13750 + st.d r4++,r6
13751 + st.d lr++,r2
13752 + st.d sp++,r6
13753 + st.d r10++,r6
13754 + st.d r7++,r2
13755 + .text
13756 + .global std_predec
13757 +std_predec:
13758 + st.d --pc,r0
13759 + st.d --r12,r14
13760 + st.d --r5,r8
13761 + st.d --r4,r6
13762 + st.d --lr,r2
13763 + st.d --r3,r6
13764 + st.d --lr,r2
13765 + st.d --r0,r4
13766 + .text
13767 + .global mul
13768 +mul:
13769 + mul pc,pc
13770 + mul r12,r12
13771 + mul r5,r5
13772 + mul r4,r4
13773 + mul lr,lr
13774 + mul r10,lr
13775 + mul r0,r8
13776 + mul r8,r5
13777 + .text
13778 + .global asr_imm5
13779 +asr_imm5:
13780 + asr pc,0
13781 + asr r12,31
13782 + asr r5,16
13783 + asr r4,15
13784 + asr lr,1
13785 + asr r6,23
13786 + asr r6,18
13787 + asr r5,8
13788 + .text
13789 + .global lsl_imm5
13790 +lsl_imm5:
13791 + lsl pc,0
13792 + lsl r12,31
13793 + lsl r5,16
13794 + lsl r4,15
13795 + lsl lr,1
13796 + lsl r12,13
13797 + lsl r6,16
13798 + lsl r1,25
13799 + .text
13800 + .global lsr_imm5
13801 +lsr_imm5:
13802 + lsr pc,0
13803 + lsr r12,31
13804 + lsr r5,16
13805 + lsr r4,15
13806 + lsr lr,1
13807 + lsr r0,1
13808 + lsr r8,10
13809 + lsr r7,26
13810 + .text
13811 + .global sbr
13812 +sbr:
13813 + sbr pc,0
13814 + sbr r12,31
13815 + sbr r5,16
13816 + sbr r4,15
13817 + sbr lr,1
13818 + sbr r8,31
13819 + sbr r6,22
13820 + sbr r1,23
13821 + .text
13822 + .global cbr
13823 +cbr:
13824 + cbr pc,0
13825 + cbr r12,31
13826 + cbr r5,16
13827 + cbr r4,15
13828 + cbr lr,1
13829 + cbr r12,10
13830 + cbr r7,22
13831 + cbr r8,9
13832 + .text
13833 + .global brc1
13834 +brc1:
13835 + breq 0
13836 + brpl -2
13837 + brge -256
13838 + brcs 254
13839 + brne 2
13840 + brcs 230
13841 + breq -18
13842 + breq 12
13843 + .text
13844 + .global rjmp
13845 +rjmp:
13846 + rjmp 0
13847 + rjmp -2
13848 + rjmp -1024
13849 + rjmp 1022
13850 + rjmp 2
13851 + rjmp -962
13852 + rjmp 14
13853 + rjmp -516
13854 + .text
13855 + .global rcall1
13856 +rcall1:
13857 + rcall 0
13858 + rcall -2
13859 + rcall -1024
13860 + rcall 1022
13861 + rcall 2
13862 + rcall 216
13863 + rcall -530
13864 + rcall -972
13865 + .text
13866 + .global acall
13867 +acall:
13868 + acall 0
13869 + acall 1020
13870 + acall 512
13871 + acall 508
13872 + acall 4
13873 + acall 356
13874 + acall 304
13875 + acall 172
13876 + .text
13877 + .global scall
13878 +scall:
13879 + scall
13880 + scall
13881 + scall
13882 + scall
13883 + scall
13884 + scall
13885 + scall
13886 + scall
13887 + .text
13888 + .global popm
13889 +popm:
13890 + /* popm with no argument fails currently */
13891 + popm pc
13892 + popm r0-r11,pc,r12=-1
13893 + popm lr
13894 + popm r0-r11,pc,r12=1
13895 + popm r0-r3
13896 + popm r4-r10,pc
13897 + popm r0-r3,r11,pc,r12=0
13898 + popm r0-r7,r10-r12,lr
13899 + .text
13900 + .global pushm
13901 +pushm:
13902 + pushm pc
13903 + pushm r0-r12,lr,pc
13904 + pushm pc
13905 + pushm r0-r12,lr
13906 + pushm r0-r3
13907 + pushm r8-r10,lr,pc
13908 + pushm r0-r3,r10
13909 + pushm r8-r9,r12
13910 + .text
13911 + .global popm_n
13912 +popm_n:
13913 + popm pc
13914 + popm r0-r11,pc,r12=-1
13915 + popm lr
13916 + popm r0-r11,pc,r12=1
13917 + popm r0-r3
13918 + popm r4-r10,pc
13919 + popm r0-r3,r11,pc,r12=0
13920 + popm r0-r7,r10-r12,lr
13921 + .text
13922 + .global pushm_n
13923 +pushm_n:
13924 + pushm pc
13925 + pushm r0-r12,lr,pc
13926 + pushm pc
13927 + pushm r0-r12,lr
13928 + pushm r0-r3
13929 + pushm r8-r10,lr,pc
13930 + pushm r0-r3,r10
13931 + pushm r8-r9,r12
13932 + .text
13933 + .global csrfcz
13934 +csrfcz:
13935 + csrfcz 0
13936 + csrfcz 31
13937 + csrfcz 16
13938 + csrfcz 15
13939 + csrfcz 1
13940 + csrfcz 5
13941 + csrfcz 13
13942 + csrfcz 23
13943 + .text
13944 + .global ssrf
13945 +ssrf:
13946 + ssrf 0
13947 + ssrf 31
13948 + ssrf 16
13949 + ssrf 15
13950 + ssrf 1
13951 + ssrf 29
13952 + ssrf 13
13953 + ssrf 13
13954 + .text
13955 + .global csrf
13956 +csrf:
13957 + csrf 0
13958 + csrf 31
13959 + csrf 16
13960 + csrf 15
13961 + csrf 1
13962 + csrf 10
13963 + csrf 15
13964 + csrf 11
13965 + .text
13966 + .global rete
13967 +rete:
13968 + rete
13969 + .text
13970 + .global rets
13971 +rets:
13972 + rets
13973 + .text
13974 + .global retd
13975 +retd:
13976 + retd
13977 + .text
13978 + .global retj
13979 +retj:
13980 + retj
13981 + .text
13982 + .global tlbr
13983 +tlbr:
13984 + tlbr
13985 + .text
13986 + .global tlbs
13987 +tlbs:
13988 + tlbs
13989 + .text
13990 + .global tlbw
13991 +tlbw:
13992 + tlbw
13993 + .text
13994 + .global breakpoint
13995 +breakpoint:
13996 + breakpoint
13997 + .text
13998 + .global incjosp
13999 +incjosp:
14000 + incjosp 1
14001 + incjosp 2
14002 + incjosp 3
14003 + incjosp 4
14004 + incjosp -4
14005 + incjosp -3
14006 + incjosp -2
14007 + incjosp -1
14008 + .text
14009 + .global nop
14010 +nop:
14011 + nop
14012 + .text
14013 + .global popjc
14014 +popjc:
14015 + popjc
14016 + .text
14017 + .global pushjc
14018 +pushjc:
14019 + pushjc
14020 + .text
14021 + .global add2
14022 +add2:
14023 + add pc,pc,pc<<0
14024 + add r12,r12,r12<<3
14025 + add r5,r5,r5<<2
14026 + add r4,r4,r4<<1
14027 + add lr,lr,lr<<1
14028 + add r0,r12,r0<<1
14029 + add r9,r12,r4<<0
14030 + add r12,r12,r7<<2
14031 + .text
14032 + .global sub2
14033 +sub2:
14034 + sub pc,pc,pc<<0
14035 + sub r12,r12,r12<<3
14036 + sub r5,r5,r5<<2
14037 + sub r4,r4,r4<<1
14038 + sub lr,lr,lr<<1
14039 + sub sp,r3,r4<<0
14040 + sub r3,r7,r3<<0
14041 + sub sp,r10,sp<<1
14042 + .text
14043 + .global divu
14044 +divu:
14045 + divu pc,pc,pc
14046 + divu r12,r12,r12
14047 + divu r5,r5,r5
14048 + divu r4,r4,r4
14049 + divu lr,lr,lr
14050 + divu sp,r4,pc
14051 + divu r5,r5,sp
14052 + divu r10,sp,r0
14053 + .text
14054 + .global addhh_w
14055 +addhh_w:
14056 + addhh.w pc,pc:b,pc:b
14057 + addhh.w r12,r12:t,r12:t
14058 + addhh.w r5,r5:t,r5:t
14059 + addhh.w r4,r4:b,r4:b
14060 + addhh.w lr,lr:t,lr:t
14061 + addhh.w r0,r0:b,r3:b
14062 + addhh.w lr,r12:t,r7:b
14063 + addhh.w r3,r10:t,r2:b
14064 + .text
14065 + .global subhh_w
14066 +subhh_w:
14067 + subhh.w pc,pc:b,pc:b
14068 + subhh.w r12,r12:t,r12:t
14069 + subhh.w r5,r5:t,r5:t
14070 + subhh.w r4,r4:b,r4:b
14071 + subhh.w lr,lr:t,lr:t
14072 + subhh.w r10,r1:t,r7:b
14073 + subhh.w pc,r10:t,lr:t
14074 + subhh.w r3,r0:t,r12:b
14075 + .text
14076 + .global adc
14077 +adc:
14078 + adc pc,pc,pc
14079 + adc r12,r12,r12
14080 + adc r5,r5,r5
14081 + adc r4,r4,r4
14082 + adc lr,lr,lr
14083 + adc r4,r0,r7
14084 + adc sp,r4,r3
14085 + adc r2,r12,r0
14086 + .text
14087 + .global sbc
14088 +sbc:
14089 + sbc pc,pc,pc
14090 + sbc r12,r12,r12
14091 + sbc r5,r5,r5
14092 + sbc r4,r4,r4
14093 + sbc lr,lr,lr
14094 + sbc r6,r7,r9
14095 + sbc r0,r8,r5
14096 + sbc r1,r0,r4
14097 + .text
14098 + .global mul_2
14099 +mul_2:
14100 + mul pc,pc,pc
14101 + mul r12,r12,r12
14102 + mul r5,r5,r5
14103 + mul r4,r4,r4
14104 + mul lr,lr,lr
14105 + mul pc,r0,r0
14106 + mul r8,pc,lr
14107 + mul r4,r12,pc
14108 + .text
14109 + .global mac
14110 +mac:
14111 + mac pc,pc,pc
14112 + mac r12,r12,r12
14113 + mac r5,r5,r5
14114 + mac r4,r4,r4
14115 + mac lr,lr,lr
14116 + mac r10,r4,r0
14117 + mac r7,lr,r0
14118 + mac r2,r9,r12
14119 + .text
14120 + .global mulsd
14121 +mulsd:
14122 + muls.d pc,pc,pc
14123 + muls.d r12,r12,r12
14124 + muls.d r5,r5,r5
14125 + muls.d r4,r4,r4
14126 + muls.d lr,lr,lr
14127 + muls.d r2,r8,lr
14128 + muls.d r4,r0,r11
14129 + muls.d r5,lr,r6
14130 + .text
14131 + .global macsd
14132 +macsd:
14133 + macs.d r0,pc,pc
14134 + macs.d r14,r12,r12
14135 + macs.d r8,r5,r5
14136 + macs.d r6,r4,r4
14137 + macs.d r2,lr,lr
14138 + macs.d r8,r1,r9
14139 + macs.d r14,r8,r8
14140 + macs.d r4,r3,r12
14141 + .text
14142 + .global mulud
14143 +mulud:
14144 + mulu.d r0,pc,pc
14145 + mulu.d r14,r12,r12
14146 + mulu.d r8,r5,r5
14147 + mulu.d r6,r4,r4
14148 + mulu.d r2,lr,lr
14149 + mulu.d r6,r5,r0
14150 + mulu.d r4,r6,r1
14151 + mulu.d r8,r8,r2
14152 + .text
14153 + .global macud
14154 +macud:
14155 + macu.d r0,pc,pc
14156 + macu.d r14,r12,r12
14157 + macu.d r8,r5,r5
14158 + macu.d r6,r4,r4
14159 + macu.d r2,lr,lr
14160 + macu.d r6,sp,r11
14161 + macu.d r2,r4,r8
14162 + macu.d r6,r10,r9
14163 + .text
14164 + .global asr_1
14165 +asr_1:
14166 + asr pc,pc,pc
14167 + asr r12,r12,r12
14168 + asr r5,r5,r5
14169 + asr r4,r4,r4
14170 + asr lr,lr,lr
14171 + asr pc,r6,pc
14172 + asr r0,r6,r12
14173 + asr r4,sp,r0
14174 + .text
14175 + .global lsl_1
14176 +lsl_1:
14177 + lsl pc,pc,pc
14178 + lsl r12,r12,r12
14179 + lsl r5,r5,r5
14180 + lsl r4,r4,r4
14181 + lsl lr,lr,lr
14182 + lsl lr,r5,lr
14183 + lsl r5,pc,r3
14184 + lsl r1,pc,r9
14185 + .text
14186 + .global lsr_1
14187 +lsr_1:
14188 + lsr pc,pc,pc
14189 + lsr r12,r12,r12
14190 + lsr r5,r5,r5
14191 + lsr r4,r4,r4
14192 + lsr lr,lr,lr
14193 + lsr r2,r4,r1
14194 + lsr r5,r1,r6
14195 + lsr sp,r6,r7
14196 + .text
14197 + .global xchg
14198 +xchg:
14199 + xchg pc,pc,pc
14200 + xchg r12,r12,r12
14201 + xchg r5,r5,r5
14202 + xchg r4,r4,r4
14203 + xchg lr,lr,lr
14204 + xchg lr,r4,sp
14205 + xchg r1,r5,r12
14206 + xchg lr,r12,r0
14207 + .text
14208 + .global max
14209 +max:
14210 + max pc,pc,pc
14211 + max r12,r12,r12
14212 + max r5,r5,r5
14213 + max r4,r4,r4
14214 + max lr,lr,lr
14215 + max lr,r2,sp
14216 + max r4,r10,r9
14217 + max lr,r9,lr
14218 + .text
14219 + .global min
14220 +min:
14221 + min pc,pc,pc
14222 + min r12,r12,r12
14223 + min r5,r5,r5
14224 + min r4,r4,r4
14225 + min lr,lr,lr
14226 + min r9,r7,r8
14227 + min sp,r5,r5
14228 + min r4,r1,r4
14229 + .text
14230 + .global addabs
14231 +addabs:
14232 + addabs pc,pc,pc
14233 + addabs r12,r12,r12
14234 + addabs r5,r5,r5
14235 + addabs r4,r4,r4
14236 + addabs lr,lr,lr
14237 + addabs r7,r10,r0
14238 + addabs r9,r9,r7
14239 + addabs r2,r8,r12
14240 + .text
14241 + .global mulnhh_w
14242 +mulnhh_w:
14243 + mulnhh.w pc,pc:b,pc:b
14244 + mulnhh.w r12,r12:t,r12:t
14245 + mulnhh.w r5,r5:t,r5:t
14246 + mulnhh.w r4,r4:b,r4:b
14247 + mulnhh.w lr,lr:t,lr:t
14248 + mulnhh.w r11,sp:t,r9:b
14249 + mulnhh.w sp,r4:b,lr:t
14250 + mulnhh.w r12,r2:t,r11:b
14251 + .text
14252 + .global mulnwh_d
14253 +mulnwh_d:
14254 + mulnwh.d r0,pc,pc:b
14255 + mulnwh.d r14,r12,r12:t
14256 + mulnwh.d r8,r5,r5:t
14257 + mulnwh.d r6,r4,r4:b
14258 + mulnwh.d r2,lr,lr:t
14259 + mulnwh.d r14,r3,r2:t
14260 + mulnwh.d r4,r5,r9:b
14261 + mulnwh.d r12,r4,r4:t
14262 + .text
14263 + .global machh_w
14264 +machh_w:
14265 + machh.w pc,pc:b,pc:b
14266 + machh.w r12,r12:t,r12:t
14267 + machh.w r5,r5:t,r5:t
14268 + machh.w r4,r4:b,r4:b
14269 + machh.w lr,lr:t,lr:t
14270 + machh.w lr,r5:b,r1:t
14271 + machh.w r9,r6:b,r7:b
14272 + machh.w r5,lr:t,r12:b
14273 + .text
14274 + .global machh_d
14275 +machh_d:
14276 + machh.d r0,pc:b,pc:b
14277 + machh.d r14,r12:t,r12:t
14278 + machh.d r8,r5:t,r5:t
14279 + machh.d r6,r4:b,r4:b
14280 + machh.d r2,lr:t,lr:t
14281 + machh.d r10,r0:b,r8:b
14282 + machh.d r14,r4:b,r5:t
14283 + machh.d r8,r0:b,r4:t
14284 + .text
14285 + .global macsathh_w
14286 +macsathh_w:
14287 + macsathh.w pc,pc:b,pc:b
14288 + macsathh.w r12,r12:t,r12:t
14289 + macsathh.w r5,r5:t,r5:t
14290 + macsathh.w r4,r4:b,r4:b
14291 + macsathh.w lr,lr:t,lr:t
14292 + macsathh.w r7,r7:t,pc:t
14293 + macsathh.w r4,r2:t,r4:b
14294 + macsathh.w r4,r8:t,r3:t
14295 + .text
14296 + .global mulhh_w
14297 +mulhh_w:
14298 + mulhh.w pc,pc:b,pc:b
14299 + mulhh.w r12,r12:t,r12:t
14300 + mulhh.w r5,r5:t,r5:t
14301 + mulhh.w r4,r4:b,r4:b
14302 + mulhh.w lr,lr:t,lr:t
14303 + mulhh.w r7,r4:t,r9:b
14304 + mulhh.w pc,r3:t,r7:t
14305 + mulhh.w pc,r4:b,r9:t
14306 + .text
14307 + .global mulsathh_h
14308 +mulsathh_h:
14309 + mulsathh.h pc,pc:b,pc:b
14310 + mulsathh.h r12,r12:t,r12:t
14311 + mulsathh.h r5,r5:t,r5:t
14312 + mulsathh.h r4,r4:b,r4:b
14313 + mulsathh.h lr,lr:t,lr:t
14314 + mulsathh.h r3,r1:b,sp:b
14315 + mulsathh.h r11,lr:t,r11:b
14316 + mulsathh.h r8,r8:b,r11:t
14317 + .text
14318 + .global mulsathh_w
14319 +mulsathh_w:
14320 + mulsathh.w pc,pc:b,pc:b
14321 + mulsathh.w r12,r12:t,r12:t
14322 + mulsathh.w r5,r5:t,r5:t
14323 + mulsathh.w r4,r4:b,r4:b
14324 + mulsathh.w lr,lr:t,lr:t
14325 + mulsathh.w lr,r11:t,r6:b
14326 + mulsathh.w r6,r6:b,r7:t
14327 + mulsathh.w r10,r2:b,r3:b
14328 + .text
14329 + .global mulsatrndhh_h
14330 +mulsatrndhh_h:
14331 + mulsatrndhh.h pc,pc:b,pc:b
14332 + mulsatrndhh.h r12,r12:t,r12:t
14333 + mulsatrndhh.h r5,r5:t,r5:t
14334 + mulsatrndhh.h r4,r4:b,r4:b
14335 + mulsatrndhh.h lr,lr:t,lr:t
14336 + mulsatrndhh.h r11,r6:b,r9:b
14337 + mulsatrndhh.h r11,r3:b,r8:t
14338 + mulsatrndhh.h r5,sp:t,r7:t
14339 + .text
14340 + .global mulsatrndwh_w
14341 +mulsatrndwh_w:
14342 + mulsatrndwh.w pc,pc,pc:b
14343 + mulsatrndwh.w r12,r12,r12:t
14344 + mulsatrndwh.w r5,r5,r5:t
14345 + mulsatrndwh.w r4,r4,r4:b
14346 + mulsatrndwh.w lr,lr,lr:t
14347 + mulsatrndwh.w r5,r12,r0:b
14348 + mulsatrndwh.w r7,r10,pc:b
14349 + mulsatrndwh.w r10,r8,r5:t
14350 + .text
14351 + .global macwh_d
14352 +macwh_d:
14353 + macwh.d r0,pc,pc:b
14354 + macwh.d r14,r12,r12:t
14355 + macwh.d r8,r5,r5:t
14356 + macwh.d r6,r4,r4:b
14357 + macwh.d r2,lr,lr:t
14358 + macwh.d r4,r10,r12:t
14359 + macwh.d r4,r7,sp:b
14360 + macwh.d r14,r9,r11:b
14361 + .text
14362 + .global mulwh_d
14363 +mulwh_d:
14364 + mulwh.d r0,pc,pc:b
14365 + mulwh.d r14,r12,r12:t
14366 + mulwh.d r8,r5,r5:t
14367 + mulwh.d r6,r4,r4:b
14368 + mulwh.d r2,lr,lr:t
14369 + mulwh.d r12,r5,r1:b
14370 + mulwh.d r0,r1,r3:t
14371 + mulwh.d r0,r9,r2:b
14372 + .text
14373 + .global mulsatwh_w
14374 +mulsatwh_w:
14375 + mulsatwh.w pc,pc,pc:b
14376 + mulsatwh.w r12,r12,r12:t
14377 + mulsatwh.w r5,r5,r5:t
14378 + mulsatwh.w r4,r4,r4:b
14379 + mulsatwh.w lr,lr,lr:t
14380 + mulsatwh.w r11,pc,r10:t
14381 + mulsatwh.w sp,r12,r9:t
14382 + mulsatwh.w r0,r3,r2:t
14383 + .text
14384 + .global ldw7
14385 +ldw7:
14386 + ld.w pc,pc[pc:b<<2]
14387 + ld.w r12,r12[r12:t<<2]
14388 + ld.w r5,r5[r5:u<<2]
14389 + ld.w r4,r4[r4:l<<2]
14390 + ld.w lr,lr[lr:l<<2]
14391 + ld.w r9,r10[r6:l<<2]
14392 + ld.w r2,r10[r10:b<<2]
14393 + ld.w r11,r5[pc:b<<2]
14394 + .text
14395 + .global satadd_w
14396 +satadd_w:
14397 + satadd.w pc,pc,pc
14398 + satadd.w r12,r12,r12
14399 + satadd.w r5,r5,r5
14400 + satadd.w r4,r4,r4
14401 + satadd.w lr,lr,lr
14402 + satadd.w r4,r8,r11
14403 + satadd.w r3,r12,r6
14404 + satadd.w r3,lr,r9
14405 + .text
14406 + .global satsub_w1
14407 +satsub_w1:
14408 + satsub.w pc,pc,pc
14409 + satsub.w r12,r12,r12
14410 + satsub.w r5,r5,r5
14411 + satsub.w r4,r4,r4
14412 + satsub.w lr,lr,lr
14413 + satsub.w r8,sp,r0
14414 + satsub.w r9,r8,r4
14415 + satsub.w pc,lr,r2
14416 + .text
14417 + .global satadd_h
14418 +satadd_h:
14419 + satadd.h pc,pc,pc
14420 + satadd.h r12,r12,r12
14421 + satadd.h r5,r5,r5
14422 + satadd.h r4,r4,r4
14423 + satadd.h lr,lr,lr
14424 + satadd.h r7,r3,r9
14425 + satadd.h r1,r0,r2
14426 + satadd.h r1,r4,lr
14427 + .text
14428 + .global satsub_h
14429 +satsub_h:
14430 + satsub.h pc,pc,pc
14431 + satsub.h r12,r12,r12
14432 + satsub.h r5,r5,r5
14433 + satsub.h r4,r4,r4
14434 + satsub.h lr,lr,lr
14435 + satsub.h lr,lr,r3
14436 + satsub.h r11,r6,r5
14437 + satsub.h r3,sp,r0
14438 + .text
14439 + .global mul3
14440 +mul3:
14441 + mul pc,pc,0
14442 + mul r12,r12,-1
14443 + mul r5,r5,-128
14444 + mul r4,r4,127
14445 + mul lr,lr,1
14446 + mul r12,r2,-7
14447 + mul r1,pc,95
14448 + mul r4,r6,19
14449 + .text
14450 + .global rsub2
14451 +rsub2:
14452 + rsub pc,pc,0
14453 + rsub r12,r12,-1
14454 + rsub r5,r5,-128
14455 + rsub r4,r4,127
14456 + rsub lr,lr,1
14457 + rsub r9,lr,96
14458 + rsub r11,r1,56
14459 + rsub r0,r7,-87
14460 + .text
14461 + .global clz
14462 +clz:
14463 + clz pc,pc
14464 + clz r12,r12
14465 + clz r5,r5
14466 + clz r4,r4
14467 + clz lr,lr
14468 + clz r2,r3
14469 + clz r5,r11
14470 + clz pc,r3
14471 + .text
14472 + .global cpc1
14473 +cpc1:
14474 + cpc pc,pc
14475 + cpc r12,r12
14476 + cpc r5,r5
14477 + cpc r4,r4
14478 + cpc lr,lr
14479 + cpc pc,r4
14480 + cpc r5,r9
14481 + cpc r6,r7
14482 + .text
14483 + .global asr3
14484 +asr3:
14485 + asr pc,pc,0
14486 + asr r12,r12,31
14487 + asr r5,r5,16
14488 + asr r4,r4,15
14489 + asr lr,lr,1
14490 + asr r4,r11,19
14491 + asr sp,pc,26
14492 + asr r11,sp,8
14493 + .text
14494 + .global lsl3
14495 +lsl3:
14496 + lsl pc,pc,0
14497 + lsl r12,r12,31
14498 + lsl r5,r5,16
14499 + lsl r4,r4,15
14500 + lsl lr,lr,1
14501 + lsl r8,r10,17
14502 + lsl r2,lr,3
14503 + lsl lr,r11,14
14504 + .text
14505 + .global lsr3
14506 +lsr3:
14507 + lsr pc,pc,0
14508 + lsr r12,r12,31
14509 + lsr r5,r5,16
14510 + lsr r4,r4,15
14511 + lsr lr,lr,1
14512 + lsr r4,r3,31
14513 + lsr pc,r9,14
14514 + lsr r3,r0,6
14515 +/* .text
14516 + .global extract_b
14517 +extract_b:
14518 + extract.b pc,pc:b
14519 + extract.b r12,r12:t
14520 + extract.b r5,r5:u
14521 + extract.b r4,r4:l
14522 + extract.b lr,lr:l
14523 + extract.b r2,r5:l
14524 + extract.b r12,r3:l
14525 + extract.b sp,r3:l
14526 + .text
14527 + .global insert_b
14528 +insert_b:
14529 + insert.b pc:b,pc
14530 + insert.b r12:t,r12
14531 + insert.b r5:u,r5
14532 + insert.b r4:l,r4
14533 + insert.b lr:l,lr
14534 + insert.b r12:u,r3
14535 + insert.b r10:l,lr
14536 + insert.b r11:l,r12
14537 + .text
14538 + .global extract_h
14539 +extract_h:
14540 + extract.h pc,pc:b
14541 + extract.h r12,r12:t
14542 + extract.h r5,r5:t
14543 + extract.h r4,r4:b
14544 + extract.h lr,lr:t
14545 + extract.h r11,lr:b
14546 + extract.h r10,r0:b
14547 + extract.h r11,r12:b
14548 + .text
14549 + .global insert_h
14550 +insert_h:
14551 + insert.h pc:b,pc
14552 + insert.h r12:t,r12
14553 + insert.h r5:t,r5
14554 + insert.h r4:b,r4
14555 + insert.h lr:t,lr
14556 + insert.h r12:t,r11
14557 + insert.h r7:b,r6
14558 + insert.h r1:t,r11 */
14559 + .text
14560 + .global movc1
14561 +movc1:
14562 + moveq pc,pc
14563 + moval r12,r12
14564 + movls r5,r5
14565 + movpl r4,r4
14566 + movne lr,lr
14567 + movne pc,r11
14568 + movmi r10,r2
14569 + movls r8,r12
14570 + .text
14571 + .global padd_h
14572 +padd_h:
14573 + padd.h pc,pc,pc
14574 + padd.h r12,r12,r12
14575 + padd.h r5,r5,r5
14576 + padd.h r4,r4,r4
14577 + padd.h lr,lr,lr
14578 + padd.h r8,r2,r7
14579 + padd.h r0,r0,r3
14580 + padd.h sp,r11,r6
14581 + .text
14582 + .global psub_h
14583 +psub_h:
14584 + psub.h pc,pc,pc
14585 + psub.h r12,r12,r12
14586 + psub.h r5,r5,r5
14587 + psub.h r4,r4,r4
14588 + psub.h lr,lr,lr
14589 + psub.h lr,r6,r8
14590 + psub.h r0,r1,sp
14591 + psub.h pc,pc,sp
14592 + .text
14593 + .global paddx_h
14594 +paddx_h:
14595 + paddx.h pc,pc,pc
14596 + paddx.h r12,r12,r12
14597 + paddx.h r5,r5,r5
14598 + paddx.h r4,r4,r4
14599 + paddx.h lr,lr,lr
14600 + paddx.h pc,pc,r1
14601 + paddx.h r10,r4,r5
14602 + paddx.h r5,pc,r2
14603 + .text
14604 + .global psubx_h
14605 +psubx_h:
14606 + psubx.h pc,pc,pc
14607 + psubx.h r12,r12,r12
14608 + psubx.h r5,r5,r5
14609 + psubx.h r4,r4,r4
14610 + psubx.h lr,lr,lr
14611 + psubx.h r5,r12,r5
14612 + psubx.h r3,r8,r3
14613 + psubx.h r5,r2,r3
14614 + .text
14615 + .global padds_sh
14616 +padds_sh:
14617 + padds.sh pc,pc,pc
14618 + padds.sh r12,r12,r12
14619 + padds.sh r5,r5,r5
14620 + padds.sh r4,r4,r4
14621 + padds.sh lr,lr,lr
14622 + padds.sh r9,lr,r2
14623 + padds.sh r6,r8,r1
14624 + padds.sh r6,r4,r10
14625 + .text
14626 + .global psubs_sh
14627 +psubs_sh:
14628 + psubs.sh pc,pc,pc
14629 + psubs.sh r12,r12,r12
14630 + psubs.sh r5,r5,r5
14631 + psubs.sh r4,r4,r4
14632 + psubs.sh lr,lr,lr
14633 + psubs.sh r6,lr,r11
14634 + psubs.sh r2,r12,r4
14635 + psubs.sh r0,r9,r0
14636 + .text
14637 + .global paddxs_sh
14638 +paddxs_sh:
14639 + paddxs.sh pc,pc,pc
14640 + paddxs.sh r12,r12,r12
14641 + paddxs.sh r5,r5,r5
14642 + paddxs.sh r4,r4,r4
14643 + paddxs.sh lr,lr,lr
14644 + paddxs.sh r0,r3,r9
14645 + paddxs.sh pc,r10,r11
14646 + paddxs.sh pc,r10,pc
14647 + .text
14648 + .global psubxs_sh
14649 +psubxs_sh:
14650 + psubxs.sh pc,pc,pc
14651 + psubxs.sh r12,r12,r12
14652 + psubxs.sh r5,r5,r5
14653 + psubxs.sh r4,r4,r4
14654 + psubxs.sh lr,lr,lr
14655 + psubxs.sh r7,r4,r4
14656 + psubxs.sh r7,r8,r3
14657 + psubxs.sh pc,r6,r5
14658 + .text
14659 + .global padds_uh
14660 +padds_uh:
14661 + padds.uh pc,pc,pc
14662 + padds.uh r12,r12,r12
14663 + padds.uh r5,r5,r5
14664 + padds.uh r4,r4,r4
14665 + padds.uh lr,lr,lr
14666 + padds.uh r12,r11,r7
14667 + padds.uh r7,r8,lr
14668 + padds.uh r6,r9,r7
14669 + .text
14670 + .global psubs_uh
14671 +psubs_uh:
14672 + psubs.uh pc,pc,pc
14673 + psubs.uh r12,r12,r12
14674 + psubs.uh r5,r5,r5
14675 + psubs.uh r4,r4,r4
14676 + psubs.uh lr,lr,lr
14677 + psubs.uh lr,r10,r6
14678 + psubs.uh sp,r2,pc
14679 + psubs.uh r2,r9,r2
14680 + .text
14681 + .global paddxs_uh
14682 +paddxs_uh:
14683 + paddxs.uh pc,pc,pc
14684 + paddxs.uh r12,r12,r12
14685 + paddxs.uh r5,r5,r5
14686 + paddxs.uh r4,r4,r4
14687 + paddxs.uh lr,lr,lr
14688 + paddxs.uh r7,r9,r5
14689 + paddxs.uh r9,r1,r4
14690 + paddxs.uh r5,r2,r3
14691 + .text
14692 + .global psubxs_uh
14693 +psubxs_uh:
14694 + psubxs.uh pc,pc,pc
14695 + psubxs.uh r12,r12,r12
14696 + psubxs.uh r5,r5,r5
14697 + psubxs.uh r4,r4,r4
14698 + psubxs.uh lr,lr,lr
14699 + psubxs.uh sp,r5,sp
14700 + psubxs.uh sp,r6,r6
14701 + psubxs.uh r3,r11,r8
14702 + .text
14703 + .global paddh_sh
14704 +paddh_sh:
14705 + paddh.sh pc,pc,pc
14706 + paddh.sh r12,r12,r12
14707 + paddh.sh r5,r5,r5
14708 + paddh.sh r4,r4,r4
14709 + paddh.sh lr,lr,lr
14710 + paddh.sh r12,sp,r3
14711 + paddh.sh pc,r5,r3
14712 + paddh.sh r8,r8,sp
14713 + .text
14714 + .global psubh_sh
14715 +psubh_sh:
14716 + psubh.sh pc,pc,pc
14717 + psubh.sh r12,r12,r12
14718 + psubh.sh r5,r5,r5
14719 + psubh.sh r4,r4,r4
14720 + psubh.sh lr,lr,lr
14721 + psubh.sh r1,r5,r8
14722 + psubh.sh r7,r3,r6
14723 + psubh.sh r4,r3,r3
14724 + .text
14725 + .global paddxh_sh
14726 +paddxh_sh:
14727 + paddxh.sh pc,pc,pc
14728 + paddxh.sh r12,r12,r12
14729 + paddxh.sh r5,r5,r5
14730 + paddxh.sh r4,r4,r4
14731 + paddxh.sh lr,lr,lr
14732 + paddxh.sh r6,r0,r4
14733 + paddxh.sh r9,r8,r9
14734 + paddxh.sh r3,r0,sp
14735 + .text
14736 + .global psubxh_sh
14737 +psubxh_sh:
14738 + psubxh.sh pc,pc,pc
14739 + psubxh.sh r12,r12,r12
14740 + psubxh.sh r5,r5,r5
14741 + psubxh.sh r4,r4,r4
14742 + psubxh.sh lr,lr,lr
14743 + psubxh.sh r4,pc,r12
14744 + psubxh.sh r8,r4,r6
14745 + psubxh.sh r12,r9,r4
14746 + .text
14747 + .global paddsub_h
14748 +paddsub_h:
14749 + paddsub.h pc,pc:b,pc:b
14750 + paddsub.h r12,r12:t,r12:t
14751 + paddsub.h r5,r5:t,r5:t
14752 + paddsub.h r4,r4:b,r4:b
14753 + paddsub.h lr,lr:t,lr:t
14754 + paddsub.h r5,r2:t,lr:b
14755 + paddsub.h r7,r1:b,r8:b
14756 + paddsub.h r6,r10:t,r5:t
14757 + .text
14758 + .global psubadd_h
14759 +psubadd_h:
14760 + psubadd.h pc,pc:b,pc:b
14761 + psubadd.h r12,r12:t,r12:t
14762 + psubadd.h r5,r5:t,r5:t
14763 + psubadd.h r4,r4:b,r4:b
14764 + psubadd.h lr,lr:t,lr:t
14765 + psubadd.h r9,r11:t,r8:t
14766 + psubadd.h r10,r7:t,lr:t
14767 + psubadd.h r6,pc:t,pc:b
14768 + .text
14769 + .global paddsubs_sh
14770 +paddsubs_sh:
14771 + paddsubs.sh pc,pc:b,pc:b
14772 + paddsubs.sh r12,r12:t,r12:t
14773 + paddsubs.sh r5,r5:t,r5:t
14774 + paddsubs.sh r4,r4:b,r4:b
14775 + paddsubs.sh lr,lr:t,lr:t
14776 + paddsubs.sh r0,lr:t,r0:b
14777 + paddsubs.sh r9,r2:t,r4:t
14778 + paddsubs.sh r12,r9:t,sp:t
14779 + .text
14780 + .global psubadds_sh
14781 +psubadds_sh:
14782 + psubadds.sh pc,pc:b,pc:b
14783 + psubadds.sh r12,r12:t,r12:t
14784 + psubadds.sh r5,r5:t,r5:t
14785 + psubadds.sh r4,r4:b,r4:b
14786 + psubadds.sh lr,lr:t,lr:t
14787 + psubadds.sh pc,lr:b,r1:t
14788 + psubadds.sh r11,r3:b,r12:b
14789 + psubadds.sh r10,r2:t,r8:t
14790 + .text
14791 + .global paddsubs_uh
14792 +paddsubs_uh:
14793 + paddsubs.uh pc,pc:b,pc:b
14794 + paddsubs.uh r12,r12:t,r12:t
14795 + paddsubs.uh r5,r5:t,r5:t
14796 + paddsubs.uh r4,r4:b,r4:b
14797 + paddsubs.uh lr,lr:t,lr:t
14798 + paddsubs.uh r9,r2:b,r3:b
14799 + paddsubs.uh sp,sp:b,r7:t
14800 + paddsubs.uh lr,r0:b,r10:t
14801 + .text
14802 + .global psubadds_uh
14803 +psubadds_uh:
14804 + psubadds.uh pc,pc:b,pc:b
14805 + psubadds.uh r12,r12:t,r12:t
14806 + psubadds.uh r5,r5:t,r5:t
14807 + psubadds.uh r4,r4:b,r4:b
14808 + psubadds.uh lr,lr:t,lr:t
14809 + psubadds.uh r12,r9:t,pc:t
14810 + psubadds.uh r8,r6:b,r8:b
14811 + psubadds.uh r8,r8:b,r4:b
14812 + .text
14813 + .global paddsubh_sh
14814 +paddsubh_sh:
14815 + paddsubh.sh pc,pc:b,pc:b
14816 + paddsubh.sh r12,r12:t,r12:t
14817 + paddsubh.sh r5,r5:t,r5:t
14818 + paddsubh.sh r4,r4:b,r4:b
14819 + paddsubh.sh lr,lr:t,lr:t
14820 + paddsubh.sh r8,r9:t,r9:b
14821 + paddsubh.sh r0,sp:t,r1:t
14822 + paddsubh.sh r3,r1:b,r0:t
14823 + .text
14824 + .global psubaddh_sh
14825 +psubaddh_sh:
14826 + psubaddh.sh pc,pc:b,pc:b
14827 + psubaddh.sh r12,r12:t,r12:t
14828 + psubaddh.sh r5,r5:t,r5:t
14829 + psubaddh.sh r4,r4:b,r4:b
14830 + psubaddh.sh lr,lr:t,lr:t
14831 + psubaddh.sh r7,r3:t,r10:b
14832 + psubaddh.sh r7,r2:t,r1:t
14833 + psubaddh.sh r11,r3:b,r6:b
14834 + .text
14835 + .global padd_b
14836 +padd_b:
14837 + padd.b pc,pc,pc
14838 + padd.b r12,r12,r12
14839 + padd.b r5,r5,r5
14840 + padd.b r4,r4,r4
14841 + padd.b lr,lr,lr
14842 + padd.b r2,r6,pc
14843 + padd.b r8,r9,r12
14844 + padd.b r5,r12,r3
14845 + .text
14846 + .global psub_b
14847 +psub_b:
14848 + psub.b pc,pc,pc
14849 + psub.b r12,r12,r12
14850 + psub.b r5,r5,r5
14851 + psub.b r4,r4,r4
14852 + psub.b lr,lr,lr
14853 + psub.b r0,r12,pc
14854 + psub.b r7,sp,r10
14855 + psub.b r5,sp,r12
14856 + .text
14857 + .global padds_sb
14858 +padds_sb:
14859 + padds.sb pc,pc,pc
14860 + padds.sb r12,r12,r12
14861 + padds.sb r5,r5,r5
14862 + padds.sb r4,r4,r4
14863 + padds.sb lr,lr,lr
14864 + padds.sb sp,r11,r4
14865 + padds.sb r11,r10,r11
14866 + padds.sb r5,r12,r6
14867 + .text
14868 + .global psubs_sb
14869 +psubs_sb:
14870 + psubs.sb pc,pc,pc
14871 + psubs.sb r12,r12,r12
14872 + psubs.sb r5,r5,r5
14873 + psubs.sb r4,r4,r4
14874 + psubs.sb lr,lr,lr
14875 + psubs.sb r7,r6,r8
14876 + psubs.sb r12,r10,r9
14877 + psubs.sb pc,r11,r0
14878 + .text
14879 + .global padds_ub
14880 +padds_ub:
14881 + padds.ub pc,pc,pc
14882 + padds.ub r12,r12,r12
14883 + padds.ub r5,r5,r5
14884 + padds.ub r4,r4,r4
14885 + padds.ub lr,lr,lr
14886 + padds.ub r3,r2,r11
14887 + padds.ub r10,r8,r1
14888 + padds.ub r11,r8,r10
14889 + .text
14890 + .global psubs_ub
14891 +psubs_ub:
14892 + psubs.ub pc,pc,pc
14893 + psubs.ub r12,r12,r12
14894 + psubs.ub r5,r5,r5
14895 + psubs.ub r4,r4,r4
14896 + psubs.ub lr,lr,lr
14897 + psubs.ub r0,r2,r7
14898 + psubs.ub lr,r5,r3
14899 + psubs.ub r6,r7,r9
14900 + .text
14901 + .global paddh_ub
14902 +paddh_ub:
14903 + paddh.ub pc,pc,pc
14904 + paddh.ub r12,r12,r12
14905 + paddh.ub r5,r5,r5
14906 + paddh.ub r4,r4,r4
14907 + paddh.ub lr,lr,lr
14908 + paddh.ub lr,r1,r0
14909 + paddh.ub r2,r7,r7
14910 + paddh.ub r2,r1,r2
14911 + .text
14912 + .global psubh_ub
14913 +psubh_ub:
14914 + psubh.ub pc,pc,pc
14915 + psubh.ub r12,r12,r12
14916 + psubh.ub r5,r5,r5
14917 + psubh.ub r4,r4,r4
14918 + psubh.ub lr,lr,lr
14919 + psubh.ub r0,r1,r6
14920 + psubh.ub r4,lr,r10
14921 + psubh.ub r9,r8,r1
14922 + .text
14923 + .global pmax_ub
14924 +pmax_ub:
14925 + pmax.ub pc,pc,pc
14926 + pmax.ub r12,r12,r12
14927 + pmax.ub r5,r5,r5
14928 + pmax.ub r4,r4,r4
14929 + pmax.ub lr,lr,lr
14930 + pmax.ub pc,r2,r11
14931 + pmax.ub r12,r1,r1
14932 + pmax.ub r5,r2,r0
14933 + .text
14934 + .global pmax_sh
14935 +pmax_sh:
14936 + pmax.sh pc,pc,pc
14937 + pmax.sh r12,r12,r12
14938 + pmax.sh r5,r5,r5
14939 + pmax.sh r4,r4,r4
14940 + pmax.sh lr,lr,lr
14941 + pmax.sh lr,r6,r12
14942 + pmax.sh r2,pc,r5
14943 + pmax.sh pc,r2,r7
14944 + .text
14945 + .global pmin_ub
14946 +pmin_ub:
14947 + pmin.ub pc,pc,pc
14948 + pmin.ub r12,r12,r12
14949 + pmin.ub r5,r5,r5
14950 + pmin.ub r4,r4,r4
14951 + pmin.ub lr,lr,lr
14952 + pmin.ub r8,r1,r5
14953 + pmin.ub r1,r8,r3
14954 + pmin.ub r0,r2,r7
14955 + .text
14956 + .global pmin_sh
14957 +pmin_sh:
14958 + pmin.sh pc,pc,pc
14959 + pmin.sh r12,r12,r12
14960 + pmin.sh r5,r5,r5
14961 + pmin.sh r4,r4,r4
14962 + pmin.sh lr,lr,lr
14963 + pmin.sh r8,r4,r10
14964 + pmin.sh lr,r10,r12
14965 + pmin.sh r2,r6,r2
14966 + .text
14967 + .global pavg_ub
14968 +pavg_ub:
14969 + pavg.ub pc,pc,pc
14970 + pavg.ub r12,r12,r12
14971 + pavg.ub r5,r5,r5
14972 + pavg.ub r4,r4,r4
14973 + pavg.ub lr,lr,lr
14974 + pavg.ub r0,r1,r6
14975 + pavg.ub r8,r3,r6
14976 + pavg.ub pc,r12,r10
14977 + .text
14978 + .global pavg_sh
14979 +pavg_sh:
14980 + pavg.sh pc,pc,pc
14981 + pavg.sh r12,r12,r12
14982 + pavg.sh r5,r5,r5
14983 + pavg.sh r4,r4,r4
14984 + pavg.sh lr,lr,lr
14985 + pavg.sh r9,pc,sp
14986 + pavg.sh pc,sp,r3
14987 + pavg.sh r6,r1,r9
14988 + .text
14989 + .global pabs_sb
14990 +pabs_sb:
14991 + pabs.sb pc,pc
14992 + pabs.sb r12,r12
14993 + pabs.sb r5,r5
14994 + pabs.sb r4,r4
14995 + pabs.sb lr,lr
14996 + pabs.sb r11,r6
14997 + pabs.sb lr,r9
14998 + pabs.sb sp,r7
14999 + .text
15000 + .global pabs_sh
15001 +pabs_sh:
15002 + pabs.sh pc,pc
15003 + pabs.sh r12,r12
15004 + pabs.sh r5,r5
15005 + pabs.sh r4,r4
15006 + pabs.sh lr,lr
15007 + pabs.sh pc,r3
15008 + pabs.sh r5,r7
15009 + pabs.sh r4,r0
15010 + .text
15011 + .global psad
15012 +psad:
15013 + psad pc,pc,pc
15014 + psad r12,r12,r12
15015 + psad r5,r5,r5
15016 + psad r4,r4,r4
15017 + psad lr,lr,lr
15018 + psad r9,r11,r11
15019 + psad lr,r4,sp
15020 + psad lr,r4,r5
15021 + .text
15022 + .global pasr_b
15023 +pasr_b:
15024 + pasr.b pc,pc,0
15025 + pasr.b r12,r12,7
15026 + pasr.b r5,r5,4
15027 + pasr.b r4,r4,3
15028 + pasr.b lr,lr,1
15029 + pasr.b pc,r7,1
15030 + pasr.b sp,lr,6
15031 + pasr.b sp,r3,2
15032 + .text
15033 + .global plsl_b
15034 +plsl_b:
15035 + plsl.b pc,pc,0
15036 + plsl.b r12,r12,7
15037 + plsl.b r5,r5,4
15038 + plsl.b r4,r4,3
15039 + plsl.b lr,lr,1
15040 + plsl.b r2,r11,4
15041 + plsl.b r8,r5,7
15042 + plsl.b pc,r0,2
15043 + .text
15044 + .global plsr_b
15045 +plsr_b:
15046 + plsr.b pc,pc,0
15047 + plsr.b r12,r12,7
15048 + plsr.b r5,r5,4
15049 + plsr.b r4,r4,3
15050 + plsr.b lr,lr,1
15051 + plsr.b r12,r1,2
15052 + plsr.b r6,pc,7
15053 + plsr.b r12,r11,2
15054 + .text
15055 + .global pasr_h
15056 +pasr_h:
15057 + pasr.h pc,pc,0
15058 + pasr.h r12,r12,15
15059 + pasr.h r5,r5,8
15060 + pasr.h r4,r4,7
15061 + pasr.h lr,lr,1
15062 + pasr.h r0,r11,10
15063 + pasr.h r4,r6,8
15064 + pasr.h r6,r2,4
15065 + .text
15066 + .global plsl_h
15067 +plsl_h:
15068 + plsl.h pc,pc,0
15069 + plsl.h r12,r12,15
15070 + plsl.h r5,r5,8
15071 + plsl.h r4,r4,7
15072 + plsl.h lr,lr,1
15073 + plsl.h r5,r10,9
15074 + plsl.h sp,lr,8
15075 + plsl.h r0,lr,7
15076 + .text
15077 + .global plsr_h
15078 +plsr_h:
15079 + plsr.h pc,pc,0
15080 + plsr.h r12,r12,15
15081 + plsr.h r5,r5,8
15082 + plsr.h r4,r4,7
15083 + plsr.h lr,lr,1
15084 + plsr.h r11,r0,15
15085 + plsr.h lr,r3,3
15086 + plsr.h r8,lr,10
15087 + .text
15088 + .global packw_sh
15089 +packw_sh:
15090 + packw.sh pc,pc,pc
15091 + packw.sh r12,r12,r12
15092 + packw.sh r5,r5,r5
15093 + packw.sh r4,r4,r4
15094 + packw.sh lr,lr,lr
15095 + packw.sh sp,r11,r10
15096 + packw.sh r8,r2,r12
15097 + packw.sh r8,r1,r5
15098 + .text
15099 + .global punpckub_h
15100 +punpckub_h:
15101 + punpckub.h pc,pc:b
15102 + punpckub.h r12,r12:t
15103 + punpckub.h r5,r5:t
15104 + punpckub.h r4,r4:b
15105 + punpckub.h lr,lr:t
15106 + punpckub.h r6,r1:t
15107 + punpckub.h lr,r5:b
15108 + punpckub.h lr,r2:t
15109 + .text
15110 + .global punpcksb_h
15111 +punpcksb_h:
15112 + punpcksb.h pc,pc:b
15113 + punpcksb.h r12,r12:t
15114 + punpcksb.h r5,r5:t
15115 + punpcksb.h r4,r4:b
15116 + punpcksb.h lr,lr:t
15117 + punpcksb.h r4,r7:t
15118 + punpcksb.h r6,lr:b
15119 + punpcksb.h r12,r12:t
15120 + .text
15121 + .global packsh_ub
15122 +packsh_ub:
15123 + packsh.ub pc,pc,pc
15124 + packsh.ub r12,r12,r12
15125 + packsh.ub r5,r5,r5
15126 + packsh.ub r4,r4,r4
15127 + packsh.ub lr,lr,lr
15128 + packsh.ub r3,r6,r3
15129 + packsh.ub r8,r0,r3
15130 + packsh.ub r9,r3,lr
15131 + .text
15132 + .global packsh_sb
15133 +packsh_sb:
15134 + packsh.sb pc,pc,pc
15135 + packsh.sb r12,r12,r12
15136 + packsh.sb r5,r5,r5
15137 + packsh.sb r4,r4,r4
15138 + packsh.sb lr,lr,lr
15139 + packsh.sb r6,r8,r1
15140 + packsh.sb lr,r9,r8
15141 + packsh.sb sp,r6,r6
15142 + .text
15143 + .global andl
15144 +andl:
15145 + andl pc,0
15146 + andl r12,65535
15147 + andl r5,32768
15148 + andl r4,32767
15149 + andl lr,1
15150 + andl pc,23128
15151 + andl r8,47262
15152 + andl r7,13719
15153 + .text
15154 + .global andl_coh
15155 +andl_coh:
15156 + andl pc,0,COH
15157 + andl r12,65535,COH
15158 + andl r5,32768,COH
15159 + andl r4,32767,COH
15160 + andl lr,1,COH
15161 + andl r6,22753,COH
15162 + andl r0,40653,COH
15163 + andl r4,48580,COH
15164 + .text
15165 + .global andh
15166 +andh:
15167 + andh pc,0
15168 + andh r12,65535
15169 + andh r5,32768
15170 + andh r4,32767
15171 + andh lr,1
15172 + andh r12,52312
15173 + andh r3,8675
15174 + andh r2,42987
15175 + .text
15176 + .global andh_coh
15177 +andh_coh:
15178 + andh pc,0,COH
15179 + andh r12,65535,COH
15180 + andh r5,32768,COH
15181 + andh r4,32767,COH
15182 + andh lr,1,COH
15183 + andh r11,34317,COH
15184 + andh r8,52982,COH
15185 + andh r10,23683,COH
15186 + .text
15187 + .global orl
15188 +orl:
15189 + orl pc,0
15190 + orl r12,65535
15191 + orl r5,32768
15192 + orl r4,32767
15193 + orl lr,1
15194 + orl sp,16766
15195 + orl r0,21181
15196 + orl pc,44103
15197 + .text
15198 + .global orh
15199 +orh:
15200 + orh pc,0
15201 + orh r12,65535
15202 + orh r5,32768
15203 + orh r4,32767
15204 + orh lr,1
15205 + orh r8,28285
15206 + orh r12,30492
15207 + orh r1,59930
15208 + .text
15209 + .global eorl
15210 +eorl:
15211 + eorl pc,0
15212 + eorl r12,65535
15213 + eorl r5,32768
15214 + eorl r4,32767
15215 + eorl lr,1
15216 + eorl r4,51129
15217 + eorl r6,64477
15218 + eorl r1,20913
15219 + .text
15220 + .global eorh
15221 +eorh:
15222 + eorh pc,0
15223 + eorh r12,65535
15224 + eorh r5,32768
15225 + eorh r4,32767
15226 + eorh lr,1
15227 + eorh r0,11732
15228 + eorh r10,38069
15229 + eorh r9,57130
15230 + .text
15231 + .global mcall
15232 +mcall:
15233 + mcall pc[0]
15234 + mcall r12[-4]
15235 + mcall r5[-131072]
15236 + mcall r4[131068]
15237 + mcall lr[4]
15238 + mcall sp[61180]
15239 + mcall r4[-35000]
15240 + mcall r0[9924]
15241 + .text
15242 + .global pref
15243 +pref:
15244 + pref pc[0]
15245 + pref r12[-1]
15246 + pref r5[-32768]
15247 + pref r4[32767]
15248 + pref lr[1]
15249 + pref r7[7748]
15250 + pref r7[-7699]
15251 + pref r2[-25892]
15252 + .text
15253 + .global cache
15254 +cache:
15255 + cache pc[0],0
15256 + cache r12[-1],31
15257 + cache r5[-1024],16
15258 + cache r4[1023],15
15259 + cache lr[1],1
15260 + cache r3[-964],17
15261 + cache r4[-375],22
15262 + cache r3[-888],17
15263 + .text
15264 + .global sub4
15265 +sub4:
15266 + sub pc,0
15267 + sub r12,-1
15268 + sub r5,-1048576
15269 + sub r4,1048575
15270 + sub lr,1
15271 + sub r2,-619156
15272 + sub lr,461517
15273 + sub r8,-185051
15274 + .text
15275 + .global cp3
15276 +cp3:
15277 + cp pc,0
15278 + cp r12,-1
15279 + cp r5,-1048576
15280 + cp r4,1048575
15281 + cp lr,1
15282 + cp r1,124078
15283 + cp r0,-378909
15284 + cp r4,-243180
15285 + .text
15286 + .global mov2
15287 +mov2:
15288 + mov pc,0
15289 + mov r12,-1
15290 + mov r5,-1048576
15291 + mov r4,1048575
15292 + mov lr,1
15293 + mov r5,-317021
15294 + mov sp,-749164
15295 + mov r5,940179
15296 + .text
15297 + .global brc2
15298 +brc2:
15299 + breq 0
15300 + bral -2
15301 + brls -2097152
15302 + brpl 2097150
15303 + brne 2
15304 + brhi -1796966
15305 + brqs 1321368
15306 + brls -577434
15307 + .text
15308 + .global rcall2
15309 +rcall2:
15310 + rcall 0
15311 + rcall -2
15312 + rcall -2097152
15313 + rcall 2097150
15314 + rcall 2
15315 + rcall 496820
15316 + rcall 1085092
15317 + rcall -1058
15318 + .text
15319 + .global sub5
15320 +sub5:
15321 + sub pc,pc,0
15322 + sub r12,r12,-1
15323 + sub r5,r5,-32768
15324 + sub r4,r4,32767
15325 + sub lr,lr,1
15326 + sub pc,pc,-12744
15327 + sub r7,r7,-27365
15328 + sub r2,r9,-17358
15329 + .text
15330 + .global satsub_w2
15331 +satsub_w2:
15332 + satsub.w pc,pc,0
15333 + satsub.w r12,r12,-1
15334 + satsub.w r5,r5,-32768
15335 + satsub.w r4,r4,32767
15336 + satsub.w lr,lr,1
15337 + satsub.w r2,lr,-2007
15338 + satsub.w r7,r12,-784
15339 + satsub.w r4,r7,23180
15340 + .text
15341 + .global ld_d4
15342 +ld_d4:
15343 + ld.d r0,pc[0]
15344 + ld.d r14,r12[-1]
15345 + ld.d r8,r5[-32768]
15346 + ld.d r6,r4[32767]
15347 + ld.d r2,lr[1]
15348 + ld.d r14,r11[14784]
15349 + ld.d r6,r9[-18905]
15350 + ld.d r2,r3[-6355]
15351 + .text
15352 + .global ld_w4
15353 +ld_w4:
15354 + ld.w pc,pc[0]
15355 + ld.w r12,r12[-1]
15356 + ld.w r5,r5[-32768]
15357 + ld.w r4,r4[32767]
15358 + ld.w lr,lr[1]
15359 + ld.w r0,r12[-22133]
15360 + ld.w sp,pc[-20521]
15361 + /* ld.w r3,r5[29035] */
15362 + nop
15363 + .text
15364 + .global ld_sh4
15365 +ld_sh4:
15366 + ld.sh pc,pc[0]
15367 + ld.sh r12,r12[-1]
15368 + ld.sh r5,r5[-32768]
15369 + ld.sh r4,r4[32767]
15370 + ld.sh lr,lr[1]
15371 + ld.sh r6,r10[30930]
15372 + ld.sh r6,r10[21973]
15373 + /* ld.sh r11,r10[-2058] */
15374 + nop
15375 + .text
15376 + .global ld_uh4
15377 +ld_uh4:
15378 + ld.uh pc,pc[0]
15379 + ld.uh r12,r12[-1]
15380 + ld.uh r5,r5[-32768]
15381 + ld.uh r4,r4[32767]
15382 + ld.uh lr,lr[1]
15383 + ld.uh r1,r9[-13354]
15384 + ld.uh lr,r11[21337]
15385 + /* ld.uh r2,lr[-25370] */
15386 + nop
15387 + .text
15388 + .global ld_sb1
15389 +ld_sb1:
15390 + ld.sb pc,pc[0]
15391 + ld.sb r12,r12[-1]
15392 + ld.sb r5,r5[-32768]
15393 + ld.sb r4,r4[32767]
15394 + ld.sb lr,lr[1]
15395 + ld.sb r7,sp[-28663]
15396 + ld.sb r2,r1[-5879]
15397 + ld.sb r12,r3[18734]
15398 + .text
15399 + .global ld_ub4
15400 +ld_ub4:
15401 + ld.ub pc,pc[0]
15402 + ld.ub r12,r12[-1]
15403 + ld.ub r5,r5[-32768]
15404 + ld.ub r4,r4[32767]
15405 + ld.ub lr,lr[1]
15406 + ld.ub pc,r4[8277]
15407 + ld.ub r5,r12[19172]
15408 + ld.ub r10,lr[26347]
15409 + .text
15410 + .global st_d4
15411 +st_d4:
15412 + st.d pc[0],r0
15413 + st.d r12[-1],r14
15414 + st.d r5[-32768],r8
15415 + st.d r4[32767],r6
15416 + st.d lr[1],r2
15417 + st.d r5[13200],r10
15418 + st.d r5[9352],r10
15419 + st.d r5[32373],r4
15420 + .text
15421 + .global st_w4
15422 +st_w4:
15423 + st.w pc[0],pc
15424 + st.w r12[-1],r12
15425 + st.w r5[-32768],r5
15426 + st.w r4[32767],r4
15427 + st.w lr[1],lr
15428 + st.w sp[6136],r7
15429 + st.w r6[27087],r12
15430 + /* st.w r3[20143],r7 */
15431 + nop
15432 + .text
15433 + .global st_h4
15434 +st_h4:
15435 + st.h pc[0],pc
15436 + st.h r12[-1],r12
15437 + st.h r5[-32768],r5
15438 + st.h r4[32767],r4
15439 + st.h lr[1],lr
15440 + st.h r4[-9962],r7
15441 + st.h r9[-16250],r3
15442 + /* st.h r8[-28810],r7 */
15443 + nop
15444 + .text
15445 + .global st_b4
15446 +st_b4:
15447 + st.b pc[0],pc
15448 + st.b r12[-1],r12
15449 + st.b r5[-32768],r5
15450 + st.b r4[32767],r4
15451 + st.b lr[1],lr
15452 + st.b r12[30102],r6
15453 + st.b r5[28977],r1
15454 + st.b r0[5470],r1
15455 + .text
15456 + .global mfsr
15457 +mfsr:
15458 + mfsr pc,0
15459 + mfsr r12,1020
15460 + mfsr r5,512
15461 + mfsr r4,508
15462 + mfsr lr,4
15463 + mfsr r2,696
15464 + mfsr r4,260
15465 + mfsr r10,1016
15466 + .text
15467 + .global mtsr
15468 +mtsr:
15469 + mtsr 0,pc
15470 + mtsr 1020,r12
15471 + mtsr 512,r5
15472 + mtsr 508,r4
15473 + mtsr 4,lr
15474 + mtsr 224,r10
15475 + mtsr 836,r12
15476 + mtsr 304,r9
15477 + .text
15478 + .global mfdr
15479 +mfdr:
15480 + mfdr pc,0
15481 + mfdr r12,1020
15482 + mfdr r5,512
15483 + mfdr r4,508
15484 + mfdr lr,4
15485 + mfdr r6,932
15486 + mfdr r5,36
15487 + mfdr r9,300
15488 + .text
15489 + .global mtdr
15490 +mtdr:
15491 + mtdr 0,pc
15492 + mtdr 1020,r12
15493 + mtdr 512,r5
15494 + mtdr 508,r4
15495 + mtdr 4,lr
15496 + mtdr 180,r8
15497 + mtdr 720,r10
15498 + mtdr 408,lr
15499 + .text
15500 + .global sleep
15501 +sleep:
15502 + sleep 0
15503 + sleep 255
15504 + sleep 128
15505 + sleep 127
15506 + sleep 1
15507 + sleep 254
15508 + sleep 15
15509 + sleep 43
15510 + .text
15511 + .global sync
15512 +sync:
15513 + sync 0
15514 + sync 255
15515 + sync 128
15516 + sync 127
15517 + sync 1
15518 + sync 166
15519 + sync 230
15520 + sync 180
15521 + .text
15522 + .global bld
15523 +bld:
15524 + bld pc,0
15525 + bld r12,31
15526 + bld r5,16
15527 + bld r4,15
15528 + bld lr,1
15529 + bld r9,15
15530 + bld r0,4
15531 + bld lr,26
15532 + .text
15533 + .global bst
15534 +bst:
15535 + bst pc,0
15536 + bst r12,31
15537 + bst r5,16
15538 + bst r4,15
15539 + bst lr,1
15540 + bst r10,28
15541 + bst r0,3
15542 + bst sp,2
15543 + .text
15544 + .global sats
15545 +sats:
15546 + sats pc>>0,0
15547 + sats r12>>31,31
15548 + sats r5>>16,16
15549 + sats r4>>15,15
15550 + sats lr>>1,1
15551 + sats r10>>3,19
15552 + sats r10>>2,26
15553 + sats r1>>20,1
15554 + .text
15555 + .global satu
15556 +satu:
15557 + satu pc>>0,0
15558 + satu r12>>31,31
15559 + satu r5>>16,16
15560 + satu r4>>15,15
15561 + satu lr>>1,1
15562 + satu pc>>5,7
15563 + satu r7>>5,5
15564 + satu r2>>26,19
15565 + .text
15566 + .global satrnds
15567 +satrnds:
15568 + satrnds pc>>0,0
15569 + satrnds r12>>31,31
15570 + satrnds r5>>16,16
15571 + satrnds r4>>15,15
15572 + satrnds lr>>1,1
15573 + satrnds r0>>21,19
15574 + satrnds sp>>0,2
15575 + satrnds r7>>6,29
15576 + .text
15577 + .global satrndu
15578 +satrndu:
15579 + satrndu pc>>0,0
15580 + satrndu r12>>31,31
15581 + satrndu r5>>16,16
15582 + satrndu r4>>15,15
15583 + satrndu lr>>1,1
15584 + satrndu r12>>0,26
15585 + satrndu r4>>21,3
15586 + satrndu r10>>3,16
15587 + .text
15588 + .global subfc
15589 +subfc:
15590 + subfeq pc,0
15591 + subfal r12,-1
15592 + subfls r5,-128
15593 + subfpl r4,127
15594 + subfne lr,1
15595 + subfls r10,8
15596 + subfvc r11,99
15597 + subfvs r2,73
15598 + .text
15599 + .global subc
15600 +subc:
15601 + subeq pc,0
15602 + subal r12,-1
15603 + subls r5,-128
15604 + subpl r4,127
15605 + subne lr,1
15606 + subls r12,118
15607 + subvc lr,-12
15608 + submi r4,-13
15609 + .text
15610 + .global movc2
15611 +movc2:
15612 + moveq pc,0
15613 + moval r12,-1
15614 + movls r5,-128
15615 + movpl r4,127
15616 + movne lr,1
15617 + movlt r3,-122
15618 + movvc r8,2
15619 + movne r7,-111
15620 + .text
15621 + .global cp_b
15622 +cp_b:
15623 + cp.b pc,r0
15624 + cp.b r0,pc
15625 + cp.b r7,r8
15626 + cp.b r8,r7
15627 + .text
15628 + .global cp_h
15629 +cp_h:
15630 + cp.h pc,r0
15631 + cp.h r0,pc
15632 + cp.h r7,r8
15633 + cp.h r8,r7
15634 + .text
15635 + .global ldm
15636 +ldm:
15637 + ldm pc,r1-r6
15638 + ldm r12,r0-r15
15639 + ldm r5,r15
15640 + ldm r4,r0-r14
15641 + ldm lr,r0
15642 + ldm r9,r1,r5,r14
15643 + ldm r11,r2-r3,r5-r8,r15
15644 + ldm r6,r0,r3,r9,r13,r15
15645 + .text
15646 + .global ldm_pu
15647 +ldm_pu:
15648 + ldm pc++,r6-r9
15649 + ldm r12++,r0-r15
15650 + ldm r5++,r15
15651 + ldm r4++,r0-r14
15652 + ldm lr++,r0
15653 + ldm r12++,r3-r5,r8,r10,r12,r14-r15
15654 + ldm r10++,r2,r4-r6,r14-r15
15655 + ldm r6++,r1,r3-r4,r9-r14
15656 + .text
15657 + .global ldmts
15658 +ldmts:
15659 + ldmts pc,r7-r8
15660 + ldmts r12,r0-r15
15661 + ldmts r5,r15
15662 + ldmts r4,r0-r14
15663 + ldmts lr,r0
15664 + ldmts r0,r1-r2,r11-r12
15665 + ldmts lr,r0-r2,r4,r7-r8,r13-r14
15666 + ldmts r12,r0-r1,r3-r5,r9,r14-r15
15667 + .text
15668 + .global ldmts_pu
15669 +ldmts_pu:
15670 + ldmts pc++,r9
15671 + ldmts r12++,r0-r15
15672 + ldmts r5++,r15
15673 + ldmts r4++,r0-r14
15674 + ldmts lr++,r0
15675 + ldmts sp++,r0,r2-r5,r7,r9,r11
15676 + ldmts r5++,r1-r3,r7,r10-r11
15677 + ldmts r8++,r2-r4,r7-r8,r13,r15
15678 + .text
15679 + .global stm
15680 +stm:
15681 + stm pc,r7
15682 + stm r12,r0-r15
15683 + stm r5,r15
15684 + stm r4,r0-r14
15685 + stm lr,r0
15686 + stm sp,r2-r3,r5,r8,r11,r14
15687 + stm r4,r0-r4,r6,r10-r11,r14
15688 + stm r9,r1,r5,r9,r12-r15
15689 + .text
15690 + .global stm_pu
15691 +stm_pu:
15692 + stm --pc,r4-r6
15693 + stm --r12,r0-r15
15694 + stm --r5,r15
15695 + stm --r4,r0-r14
15696 + stm --lr,r0
15697 + stm --r11,r0,r4-r9,r11-r15
15698 + stm --r11,r0,r3,r9-r10,r12,r14
15699 + stm --r6,r2,r8-r9,r13-r14
15700 + .text
15701 + .global stmts
15702 +stmts:
15703 + stmts pc,r8
15704 + stmts r12,r0-r15
15705 + stmts r5,r15
15706 + stmts r4,r0-r14
15707 + stmts lr,r0
15708 + stmts r1,r0-r1,r3-r4,r6,r9-r10,r14-r15
15709 + stmts r3,r0,r6-r8,r10-r12
15710 + stmts r11,r0,r4,r6-r7,r9-r10,r12,r14-r15
15711 + .text
15712 + .global stmts_pu
15713 +stmts_pu:
15714 + stmts --pc,r6-r8
15715 + stmts --r12,r0-r15
15716 + stmts --r5,r15
15717 + stmts --r4,r0-r14
15718 + stmts --lr,r0
15719 + stmts --r2,r0,r3-r4,r9-r10,r12-r13
15720 + stmts --r3,r0-r1,r14-r15
15721 + stmts --r0,r0,r2-r6,r10,r14
15722 + .text
15723 + .global ldins_h
15724 +ldins_h:
15725 + ldins.h pc:b,pc[0]
15726 + ldins.h r12:t,r12[-2]
15727 + ldins.h r5:t,r5[-4096]
15728 + ldins.h r4:b,r4[4094]
15729 + ldins.h lr:t,lr[2]
15730 + ldins.h r0:t,lr[1930]
15731 + ldins.h r3:b,r7[-534]
15732 + ldins.h r2:b,r12[-2252]
15733 + .text
15734 + .global ldins_b
15735 +ldins_b:
15736 + ldins.b pc:b,pc[0]
15737 + ldins.b r12:t,r12[-1]
15738 + ldins.b r5:u,r5[-2048]
15739 + ldins.b r4:l,r4[2047]
15740 + ldins.b lr:l,lr[1]
15741 + ldins.b r6:t,r4[-662]
15742 + ldins.b r5:b,r1[-151]
15743 + ldins.b r10:t,r11[-1923]
15744 + .text
15745 + .global ldswp_sh
15746 +ldswp_sh:
15747 + ldswp.sh pc,pc[0]
15748 + ldswp.sh r12,r12[-2]
15749 + ldswp.sh r5,r5[-4096]
15750 + ldswp.sh r4,r4[4094]
15751 + ldswp.sh lr,lr[2]
15752 + ldswp.sh r9,r10[3848]
15753 + ldswp.sh r4,r12[-2040]
15754 + ldswp.sh r10,r2[3088]
15755 + .text
15756 + .global ldswp_uh
15757 +ldswp_uh:
15758 + ldswp.uh pc,pc[0]
15759 + ldswp.uh r12,r12[-2]
15760 + ldswp.uh r5,r5[-4096]
15761 + ldswp.uh r4,r4[4094]
15762 + ldswp.uh lr,lr[2]
15763 + ldswp.uh r4,r9[3724]
15764 + ldswp.uh lr,sp[-1672]
15765 + ldswp.uh r8,r12[-3846]
15766 + .text
15767 + .global ldswp_w
15768 +ldswp_w:
15769 + ldswp.w pc,pc[0]
15770 + ldswp.w r12,r12[-4]
15771 + ldswp.w r5,r5[-8192]
15772 + ldswp.w r4,r4[8188]
15773 + ldswp.w lr,lr[4]
15774 + ldswp.w sp,r7[1860]
15775 + ldswp.w pc,r5[-3324]
15776 + ldswp.w r12,r10[-3296]
15777 + .text
15778 + .global stswp_h
15779 +stswp_h:
15780 + stswp.h pc[0],pc
15781 + stswp.h r12[-2],r12
15782 + stswp.h r5[-4096],r5
15783 + stswp.h r4[4094],r4
15784 + stswp.h lr[2],lr
15785 + stswp.h r7[64],r10
15786 + stswp.h r10[3024],r2
15787 + stswp.h r0[-2328],r10
15788 + .text
15789 + .global stswp_w
15790 +stswp_w:
15791 + stswp.w pc[0],pc
15792 + stswp.w r12[-4],r12
15793 + stswp.w r5[-8192],r5
15794 + stswp.w r4[8188],r4
15795 + stswp.w lr[4],lr
15796 + stswp.w pc[1156],r8
15797 + stswp.w sp[7992],r10
15798 + stswp.w r8[-1172],r5
15799 + .text
15800 + .global and2
15801 +and2:
15802 + and pc,pc,pc<<0
15803 + and r12,r12,r12<<31
15804 + and r5,r5,r5<<16
15805 + and r4,r4,r4<<15
15806 + and lr,lr,lr<<1
15807 + and r10,r2,r1<<1
15808 + and r12,r8,r11<<27
15809 + and r10,r7,r0<<3
15810 + .text
15811 + .global and3
15812 +and3:
15813 + and pc,pc,pc>>0
15814 + and r12,r12,r12>>31
15815 + and r5,r5,r5>>16
15816 + and r4,r4,r4>>15
15817 + and lr,lr,lr>>1
15818 + and r12,r8,r7>>17
15819 + and pc,r4,r9>>20
15820 + and r10,r9,r10>>12
15821 + .text
15822 + .global or2
15823 +or2:
15824 + or pc,pc,pc<<0
15825 + or r12,r12,r12<<31
15826 + or r5,r5,r5<<16
15827 + or r4,r4,r4<<15
15828 + or lr,lr,lr<<1
15829 + or r8,sp,r11<<29
15830 + or pc,r9,r2<<28
15831 + or r5,r1,r2<<3
15832 + .text
15833 + .global or3
15834 +or3:
15835 + or pc,pc,pc>>0
15836 + or r12,r12,r12>>31
15837 + or r5,r5,r5>>16
15838 + or r4,r4,r4>>15
15839 + or lr,lr,lr>>1
15840 + or r1,sp,sp>>2
15841 + or r0,r1,r1>>29
15842 + or r4,r12,r8>>8
15843 + .text
15844 + .global eor2
15845 +eor2:
15846 + eor pc,pc,pc<<0
15847 + eor r12,r12,r12<<31
15848 + eor r5,r5,r5<<16
15849 + eor r4,r4,r4<<15
15850 + eor lr,lr,lr<<1
15851 + eor r10,r9,r4<<11
15852 + eor r4,r0,r1<<31
15853 + eor r6,r2,r12<<13
15854 + .text
15855 + .global eor3
15856 +eor3:
15857 + eor pc,pc,pc>>0
15858 + eor r12,r12,r12>>31
15859 + eor r5,r5,r5>>16
15860 + eor r4,r4,r4>>15
15861 + eor lr,lr,lr>>1
15862 + eor r5,r5,r5>>22
15863 + eor r10,r1,lr>>3
15864 + eor r7,lr,sp>>26
15865 + .text
15866 + .global sthh_w2
15867 +sthh_w2:
15868 + sthh.w pc[pc<<0],pc:b,pc:b
15869 + sthh.w r12[r12<<3],r12:t,r12:t
15870 + sthh.w r5[r5<<2],r5:t,r5:t
15871 + sthh.w r4[r4<<1],r4:b,r4:b
15872 + sthh.w lr[lr<<1],lr:t,lr:t
15873 + sthh.w sp[r6<<3],r1:t,r12:t
15874 + sthh.w r6[r6<<0],r9:t,r9:t
15875 + sthh.w r10[r3<<0],r0:b,r11:t
15876 + .text
15877 + .global sthh_w1
15878 +sthh_w1:
15879 + sthh.w pc[0],pc:b,pc:b
15880 + sthh.w r12[1020],r12:t,r12:t
15881 + sthh.w r5[512],r5:t,r5:t
15882 + sthh.w r4[508],r4:b,r4:b
15883 + sthh.w lr[4],lr:t,lr:t
15884 + sthh.w r4[404],r9:t,r0:b
15885 + sthh.w r8[348],r2:t,r10:b
15886 + sthh.w sp[172],r9:b,r2:b
15887 + .text
15888 + .global cop
15889 +cop:
15890 + cop cp0,cr0,cr0,cr0,0
15891 + cop cp7,cr15,cr15,cr15,0x7f
15892 + cop cp3,cr5,cr5,cr5,0x31
15893 + cop cp2,cr4,cr4,cr4,0x30
15894 + cop cp5,cr8,cr3,cr7,0x5a
15895 + .text
15896 + .global ldc_w1
15897 +ldc_w1:
15898 + ldc.w cp0,cr0,r0[0]
15899 + ldc.w cp7,cr15,pc[255<<2]
15900 + ldc.w cp3,cr5,r5[128<<2]
15901 + ldc.w cp2,cr4,r4[127<<2]
15902 + ldc.w cp4,cr9,r13[36<<2]
15903 + .text
15904 + .global ldc_w2
15905 +ldc_w2:
15906 + ldc.w cp0,cr0,--r0
15907 + ldc.w cp7,cr15,--pc
15908 + ldc.w cp3,cr5,--r5
15909 + ldc.w cp2,cr4,--r4
15910 + ldc.w cp4,cr9,--r13
15911 + .text
15912 + .global ldc_w3
15913 +ldc_w3:
15914 + ldc.w cp0,cr0,r0[r0]
15915 + ldc.w cp7,cr15,pc[pc<<3]
15916 + ldc.w cp3,cr5,r5[r4<<2]
15917 + ldc.w cp2,cr4,r4[r3<<1]
15918 + ldc.w cp4,cr9,r13[r12<<0]
15919 + .text
15920 + .global ldc_d1
15921 +ldc_d1:
15922 + ldc.d cp0,cr0,r0[0]
15923 + ldc.d cp7,cr14,pc[255<<2]
15924 + ldc.d cp3,cr6,r5[128<<2]
15925 + ldc.d cp2,cr4,r4[127<<2]
15926 + ldc.d cp4,cr8,r13[36<<2]
15927 + .text
15928 + .global ldc_d2
15929 +ldc_d2:
15930 + ldc.d cp0,cr0,--r0
15931 + ldc.d cp7,cr14,--pc
15932 + ldc.d cp3,cr6,--r5
15933 + ldc.d cp2,cr4,--r4
15934 + ldc.d cp4,cr8,--r13
15935 + .text
15936 + .global ldc_d3
15937 +ldc_d3:
15938 + ldc.d cp0,cr0,r0[r0]
15939 + ldc.d cp7,cr14,pc[pc<<3]
15940 + ldc.d cp3,cr6,r5[r4<<2]
15941 + ldc.d cp2,cr4,r4[r3<<1]
15942 + ldc.d cp4,cr8,r13[r12<<0]
15943 + .text
15944 + .global stc_w1
15945 +stc_w1:
15946 + stc.w cp0,r0[0],cr0
15947 + stc.w cp7,pc[255<<2],cr15
15948 + stc.w cp3,r5[128<<2],cr5
15949 + stc.w cp2,r4[127<<2],cr4
15950 + stc.w cp4,r13[36<<2],cr9
15951 + .text
15952 + .global stc_w2
15953 +stc_w2:
15954 + stc.w cp0,r0++,cr0
15955 + stc.w cp7,pc++,cr15
15956 + stc.w cp3,r5++,cr5
15957 + stc.w cp2,r4++,cr4
15958 + stc.w cp4,r13++,cr9
15959 + .text
15960 + .global stc_w3
15961 +stc_w3:
15962 + stc.w cp0,r0[r0],cr0
15963 + stc.w cp7,pc[pc<<3],cr15
15964 + stc.w cp3,r5[r4<<2],cr5
15965 + stc.w cp2,r4[r3<<1],cr4
15966 + stc.w cp4,r13[r12<<0],cr9
15967 + .text
15968 + .global stc_d1
15969 +stc_d1:
15970 + stc.d cp0,r0[0],cr0
15971 + stc.d cp7,pc[255<<2],cr14
15972 + stc.d cp3,r5[128<<2],cr6
15973 + stc.d cp2,r4[127<<2],cr4
15974 + stc.d cp4,r13[36<<2],cr8
15975 + .text
15976 + .global stc_d2
15977 +stc_d2:
15978 + stc.d cp0,r0++,cr0
15979 + stc.d cp7,pc++,cr14
15980 + stc.d cp3,r5++,cr6
15981 + stc.d cp2,r4++,cr4
15982 + stc.d cp4,r13++,cr8
15983 + .text
15984 + .global stc_d3
15985 +stc_d3:
15986 + stc.d cp0,r0[r0],cr0
15987 + stc.d cp7,pc[pc<<3],cr14
15988 + stc.d cp3,r5[r4<<2],cr6
15989 + stc.d cp2,r4[r3<<1],cr4
15990 + stc.d cp4,r13[r12<<0],cr8
15991 + .text
15992 + .global ldc0_w
15993 +ldc0_w:
15994 + ldc0.w cr0,r0[0]
15995 + ldc0.w cr15,pc[4095<<2]
15996 + ldc0.w cr5,r5[2048<<2]
15997 + ldc0.w cr4,r4[2047<<2]
15998 + ldc0.w cr9,r13[147<<2]
15999 + .text
16000 + .global ldc0_d
16001 +ldc0_d:
16002 + ldc0.d cr0,r0[0]
16003 + ldc0.d cr14,pc[4095<<2]
16004 + ldc0.d cr6,r5[2048<<2]
16005 + ldc0.d cr4,r4[2047<<2]
16006 + ldc0.d cr8,r13[147<<2]
16007 + .text
16008 + .global stc0_w
16009 +stc0_w:
16010 + stc0.w r0[0],cr0
16011 + stc0.w pc[4095<<2],cr15
16012 + stc0.w r5[2048<<2],cr5
16013 + stc0.w r4[2047<<2],cr4
16014 + stc0.w r13[147<<2],cr9
16015 + .text
16016 + .global stc0_d
16017 +stc0_d:
16018 + stc0.d r0[0],cr0
16019 + stc0.d pc[4095<<2],cr14
16020 + stc0.d r5[2048<<2],cr6
16021 + stc0.d r4[2047<<2],cr4
16022 + stc0.d r13[147<<2],cr8
16023 + .text
16024 + .global memc
16025 +memc:
16026 + memc 0, 0
16027 + memc -4, 31
16028 + memc -65536, 16
16029 + memc 65532, 15
16030 + .text
16031 + .global mems
16032 +mems:
16033 + mems 0, 0
16034 + mems -4, 31
16035 + mems -65536, 16
16036 + mems 65532, 15
16037 + .text
16038 + .global memt
16039 +memt:
16040 + memt 0, 0
16041 + memt -4, 31
16042 + memt -65536, 16
16043 + memt 65532, 15
16044 +
16045 + .text
16046 + .global stcond
16047 +stcond:
16048 + stcond r0[0], r0
16049 + stcond pc[-1], pc
16050 + stcond r8[-32768], r7
16051 + stcond r7[32767], r8
16052 + stcond r5[0x1234], r10
16053 +
16054 +ldcm_w:
16055 + ldcm.w cp0,pc,cr0-cr7
16056 + ldcm.w cp7,r0,cr0
16057 + ldcm.w cp4,r4++,cr0-cr6
16058 + ldcm.w cp3,r7,cr7
16059 + ldcm.w cp1,r12++,cr1,cr4-cr6
16060 + ldcm.w cp0,pc,cr8-cr15
16061 + ldcm.w cp7,r0,cr8
16062 + ldcm.w cp4,r4++,cr8-cr14
16063 + ldcm.w cp3,r7,cr15
16064 + ldcm.w cp1,r12++,cr9,cr12-cr14
16065 +
16066 +ldcm_d:
16067 + ldcm.d cp0,pc,cr0-cr15
16068 + ldcm.d cp7,r0,cr0,cr1
16069 + ldcm.d cp4,r4++,cr0-cr13
16070 + ldcm.d cp3,r7,cr14-cr15
16071 + ldcm.d cp2,r12++,cr0-cr3,cr8-cr9,cr14-cr15
16072 +
16073 +stcm_w:
16074 + stcm.w cp0,pc,cr0-cr7
16075 + stcm.w cp7,r0,cr0
16076 + stcm.w cp4,--r4,cr0-cr6
16077 + stcm.w cp3,r7,cr7
16078 + stcm.w cp1,--r12,cr1,cr4-cr6
16079 + stcm.w cp0,pc,cr8-cr15
16080 + stcm.w cp7,r0,cr8
16081 + stcm.w cp4,--r4,cr8-cr14
16082 + stcm.w cp3,r7,cr15
16083 + stcm.w cp1,--r12,cr9,cr12-cr14
16084 +
16085 +stcm_d:
16086 + stcm.d cp0,pc,cr0-cr15
16087 + stcm.d cp7,r0,cr0,cr1
16088 + stcm.d cp4,--r4,cr0-cr13
16089 + stcm.d cp3,r7,cr14-cr15
16090 + stcm.d cp2,--r12,cr0-cr3,cr8-cr9,cr14-cr15
16091 +
16092 +mvcr_w:
16093 + mvcr.w cp7,pc,cr15
16094 + mvcr.w cp0,r0,cr0
16095 + mvcr.w cp0,pc,cr15
16096 + mvcr.w cp7,r0,cr15
16097 + mvcr.w cp7,pc,cr0
16098 + mvcr.w cp4,r7,cr8
16099 + mvcr.w cp3,r8,cr7
16100 +
16101 +mvcr_d:
16102 + mvcr.d cp7,lr,cr14
16103 + mvcr.d cp0,r0,cr0
16104 + mvcr.d cp0,lr,cr14
16105 + mvcr.d cp7,r0,cr14
16106 + mvcr.d cp7,lr,cr0
16107 + mvcr.d cp4,r6,cr8
16108 + mvcr.d cp3,r8,cr6
16109 +
16110 +mvrc_w:
16111 + mvrc.w cp7,cr15,pc
16112 + mvrc.w cp0,cr0,r0
16113 + mvrc.w cp0,cr15,pc
16114 + mvrc.w cp7,cr15,r0
16115 + mvrc.w cp7,cr0,pc
16116 + mvrc.w cp4,cr8,r7
16117 + mvrc.w cp3,cr7,r8
16118 +
16119 +mvrc_d:
16120 + mvrc.d cp7,cr14,lr
16121 + mvrc.d cp0,cr0,r0
16122 + mvrc.d cp0,cr14,lr
16123 + mvrc.d cp7,cr14,r0
16124 + mvrc.d cp7,cr0,lr
16125 + mvrc.d cp4,cr8,r6
16126 + mvrc.d cp3,cr6,r8
16127 +
16128 +bfexts:
16129 + bfexts pc,pc,31,31
16130 + bfexts r0,r0,0,0
16131 + bfexts r0,pc,31,31
16132 + bfexts pc,r0,31,31
16133 + bfexts pc,pc,0,31
16134 + bfexts pc,pc,31,0
16135 + bfexts r7,r8,15,16
16136 + bfexts r8,r7,16,15
16137 +
16138 +bfextu:
16139 + bfextu pc,pc,31,31
16140 + bfextu r0,r0,0,0
16141 + bfextu r0,pc,31,31
16142 + bfextu pc,r0,31,31
16143 + bfextu pc,pc,0,31
16144 + bfextu pc,pc,31,0
16145 + bfextu r7,r8,15,16
16146 + bfextu r8,r7,16,15
16147 +
16148 +bfins:
16149 + bfins pc,pc,31,31
16150 + bfins r0,r0,0,0
16151 + bfins r0,pc,31,31
16152 + bfins pc,r0,31,31
16153 + bfins pc,pc,0,31
16154 + bfins pc,pc,31,0
16155 + bfins r7,r8,15,16
16156 + bfins r8,r7,16,15
16157 +
16158 +rsubc:
16159 + rsubeq pc,0
16160 + rsubal r12,-1
16161 + rsubls r5,-128
16162 + rsubpl r4,127
16163 + rsubne lr,1
16164 + rsubls r12,118
16165 + rsubvc lr,-12
16166 + rsubmi r4,-13
16167 +
16168 +addc:
16169 + addeq pc,pc,pc
16170 + addal r12,r12,r12
16171 + addls r5,r5,r5
16172 + addpl r4,r4,r4
16173 + addne lr,lr,lr
16174 + addls r10,r2,r1
16175 + addvc r12,r8,r11
16176 + addmi r10,r7,r0
16177 +
16178 +subc2:
16179 + subeq pc,pc,pc
16180 + subal r12,r12,r12
16181 + subls r5,r5,r5
16182 + subpl r4,r4,r4
16183 + subne lr,lr,lr
16184 + subls r10,r2,r1
16185 + subvc r12,r8,r11
16186 + submi r10,r7,r0
16187 +
16188 +andc:
16189 + andeq pc,pc,pc
16190 + andal r12,r12,r12
16191 + andls r5,r5,r5
16192 + andpl r4,r4,r4
16193 + andne lr,lr,lr
16194 + andls r10,r2,r1
16195 + andvc r12,r8,r11
16196 + andmi r10,r7,r0
16197 +
16198 +orc:
16199 + oreq pc,pc,pc
16200 + oral r12,r12,r12
16201 + orls r5,r5,r5
16202 + orpl r4,r4,r4
16203 + orne lr,lr,lr
16204 + orls r10,r2,r1
16205 + orvc r12,r8,r11
16206 + ormi r10,r7,r0
16207 +
16208 +eorc:
16209 + eoreq pc,pc,pc
16210 + eoral r12,r12,r12
16211 + eorls r5,r5,r5
16212 + eorpl r4,r4,r4
16213 + eorne lr,lr,lr
16214 + eorls r10,r2,r1
16215 + eorvc r12,r8,r11
16216 + eormi r10,r7,r0
16217 +
16218 +ldcond:
16219 + ld.weq pc,pc[2044]
16220 + ld.shal r12,r12[1022]
16221 + ld.uhls r5,r5[0]
16222 + ld.ubpl r4,r4[511]
16223 + ld.sbne lr,lr[0]
16224 + ld.wls r10,r2[0]
16225 + ld.shvc r12,r8[0x3fe]
16226 + ld.ubmi r10,r7[1]
16227 +
16228 +stcond2:
16229 + st.weq pc[2044],pc
16230 + st.hal r12[1022],r12
16231 + st.hls r5[0],r5
16232 + st.bpl r4[511],r4
16233 + st.bne lr[0],lr
16234 + st.wls r2[0],r10
16235 + st.hvc r8[0x3fe],r12
16236 + st.bmi r7[1],r10
16237 +
16238 +movh:
16239 + movh pc, 65535
16240 + movh r0, 0
16241 + movh r5, 1
16242 + movh r12, 32767
16243 +
16244 +
16245 --- /dev/null
16246 +++ b/gas/testsuite/gas/avr32/avr32.exp
16247 @@ -0,0 +1,23 @@
16248 +# AVR32 assembler testsuite. -*- Tcl -*-
16249 +
16250 +if [istarget avr32-*-*] {
16251 + run_dump_test "hwrd-lwrd"
16252 + run_dump_test "pcrel"
16253 + run_dump_test "aliases"
16254 + run_dump_test "dwarf2"
16255 + run_dump_test "pic_reloc"
16256 + run_dump_test "fpinsn"
16257 + run_dump_test "pico"
16258 + run_dump_test "lda_pic"
16259 + run_dump_test "lda_pic_linkrelax"
16260 + run_dump_test "lda_nopic"
16261 + run_dump_test "lda_nopic_linkrelax"
16262 + run_dump_test "call_pic"
16263 + run_dump_test "call_pic_linkrelax"
16264 + run_dump_test "call_nopic"
16265 + run_dump_test "call_nopic_linkrelax"
16266 + run_dump_test "jmptable"
16267 + run_dump_test "jmptable_linkrelax"
16268 + run_dump_test "symdiff"
16269 + run_dump_test "symdiff_linkrelax"
16270 +}
16271 --- /dev/null
16272 +++ b/gas/testsuite/gas/avr32/call_nopic.d
16273 @@ -0,0 +1,36 @@
16274 +#source: call.s
16275 +#as:
16276 +#objdump: -dr
16277 +#name: call_nopic
16278 +
16279 +.*: +file format .*
16280 +
16281 +Disassembly of section \.text:
16282 +
16283 +00000000 <call_test>:
16284 + 0: d7 03 nop
16285 +
16286 +00000002 <toofar_negative>:
16287 + \.\.\.
16288 + 1ffffe: 00 00 add r0,r0
16289 + 200000: f0 a0 00 00 rcall 0 <call_test>
16290 + 200004: f0 1f 00 0c mcall 200034 <toofar_negative\+0x200032>
16291 + 200008: f0 1f 00 0c mcall 200038 <toofar_negative\+0x200036>
16292 + 20000c: f0 1f 00 0c mcall 20003c <toofar_negative\+0x20003a>
16293 + 200010: f0 1f 00 0c mcall 200040 <toofar_negative\+0x20003e>
16294 + \.\.\.
16295 + 200030: ee b0 ff ff rcall 40002e <far_positive>
16296 + \.\.\.
16297 + 200034: R_AVR32_32_CPENT \.text\+0x2
16298 + 200038: R_AVR32_32_CPENT \.text\.init
16299 + 20003c: R_AVR32_32_CPENT undefined
16300 + 200040: R_AVR32_32_CPENT \.text\+0x40002c
16301 +
16302 +0040002c <toofar_positive>:
16303 + 40002c: d7 03 nop
16304 +0040002e <far_positive>:
16305 + 40002e: d7 03 nop
16306 +Disassembly of section \.text\.init:
16307 +
16308 +00000000 <different_section>:
16309 + 0: e2 c0 00 00 sub r0,r1,0
16310 --- /dev/null
16311 +++ b/gas/testsuite/gas/avr32/call_nopic_linkrelax.d
16312 @@ -0,0 +1,43 @@
16313 +#source: call.s
16314 +#as: --linkrelax
16315 +#objdump: -dr
16316 +#name: call_nopic_linkrelax
16317 +
16318 +.*: +file format .*
16319 +
16320 +Disassembly of section \.text:
16321 +
16322 +00000000 <call_test>:
16323 + 0: d7 03 nop
16324 +
16325 +00000002 <toofar_negative>:
16326 + \.\.\.
16327 + 1ffffe: 00 00 add r0,r0
16328 + 200000: e0 a0 00 00 rcall 200000 <toofar_negative\+0x1ffffe>
16329 + 200000: R_AVR32_22H_PCREL \.text
16330 + 200004: f0 1f 00 00 mcall 200004 <toofar_negative\+0x200002>
16331 + 200004: R_AVR32_CPCALL \.text\+0x200034
16332 + 200008: f0 1f 00 00 mcall 200008 <toofar_negative\+0x200006>
16333 + 200008: R_AVR32_CPCALL \.text\+0x200038
16334 + 20000c: f0 1f 00 00 mcall 20000c <toofar_negative\+0x20000a>
16335 + 20000c: R_AVR32_CPCALL \.text\+0x20003c
16336 + 200010: f0 1f 00 00 mcall 200010 <toofar_negative\+0x20000e>
16337 + 200010: R_AVR32_CPCALL \.text\+0x200040
16338 + \.\.\.
16339 + 200030: e0 a0 00 00 rcall 200030 <toofar_negative\+0x20002e>
16340 + 200030: R_AVR32_22H_PCREL \.text\+0x40002e
16341 + \.\.\.
16342 + 200034: R_AVR32_ALIGN \*ABS\*\+0x2
16343 + 200034: R_AVR32_32_CPENT \.text\+0x2
16344 + 200038: R_AVR32_32_CPENT \.text\.init
16345 + 20003c: R_AVR32_32_CPENT undefined
16346 + 200040: R_AVR32_32_CPENT \.text\+0x40002c
16347 +
16348 +0040002c <toofar_positive>:
16349 + 40002c: d7 03 nop
16350 +0040002e <far_positive>:
16351 + 40002e: d7 03 nop
16352 +Disassembly of section \.text\.init:
16353 +
16354 +00000000 <different_section>:
16355 + 0: e2 c0 00 00 sub r0,r1,0
16356 --- /dev/null
16357 +++ b/gas/testsuite/gas/avr32/call_pic.d
16358 @@ -0,0 +1,36 @@
16359 +#source: call.s
16360 +#as: --pic
16361 +#objdump: -dr
16362 +#name: call_pic
16363 +
16364 +.*: +file format .*
16365 +
16366 +Disassembly of section \.text:
16367 +
16368 +00000000 <call_test>:
16369 + 0: d7 03 nop
16370 +
16371 +00000002 <toofar_negative>:
16372 + \.\.\.
16373 + 1ffffe: 00 00 add r0,r0
16374 + 200000: f0 a0 00 00 rcall 0 <call_test>
16375 + 200004: f0 16 00 00 mcall r6\[0\]
16376 + 200004: R_AVR32_GOT18SW toofar_negative
16377 + 200008: f0 16 00 00 mcall r6\[0\]
16378 + 200008: R_AVR32_GOT18SW different_section
16379 + 20000c: f0 16 00 00 mcall r6\[0\]
16380 + 20000c: R_AVR32_GOT18SW undefined
16381 + 200010: f0 16 00 00 mcall r6\[0\]
16382 + 200010: R_AVR32_GOT18SW toofar_positive
16383 + \.\.\.
16384 + 200030: ee b0 ff ff rcall 40002e <far_positive>
16385 + \.\.\.
16386 +
16387 +0040002c <toofar_positive>:
16388 + 40002c: d7 03 nop
16389 +0040002e <far_positive>:
16390 + 40002e: d7 03 nop
16391 +Disassembly of section \.text\.init:
16392 +
16393 +00000000 <different_section>:
16394 + 0: e2 c0 00 00 sub r0,r1,0
16395 --- /dev/null
16396 +++ b/gas/testsuite/gas/avr32/call_pic_linkrelax.d
16397 @@ -0,0 +1,47 @@
16398 +#source: call.s
16399 +#as: --pic --linkrelax
16400 +#objdump: -dr
16401 +#name: call_pic_linkrelax
16402 +
16403 +.*: +file format .*
16404 +
16405 +Disassembly of section \.text:
16406 +
16407 +00000000 <call_test>:
16408 + 0: d7 03 nop
16409 +
16410 +00000002 <toofar_negative>:
16411 + \.\.\.
16412 + 1ffffe: 00 00 add r0,r0
16413 + 200000: e0 a0 00 00 rcall 200000 <toofar_negative\+0x1ffffe>
16414 + 200000: R_AVR32_22H_PCREL \.text
16415 + 200004: e0 6e 00 00 mov lr,0
16416 + 200004: R_AVR32_GOTCALL toofar_negative
16417 + 200008: ec 0e 03 2e ld\.w lr,r6\[lr<<0x2\]
16418 + 20000c: 5d 1e icall lr
16419 + 20000e: e0 6e 00 00 mov lr,0
16420 + 20000e: R_AVR32_GOTCALL different_section
16421 + 200012: ec 0e 03 2e ld\.w lr,r6\[lr<<0x2\]
16422 + 200016: 5d 1e icall lr
16423 + 200018: e0 6e 00 00 mov lr,0
16424 + 200018: R_AVR32_GOTCALL undefined
16425 + 20001c: ec 0e 03 2e ld\.w lr,r6\[lr<<0x2\]
16426 + 200020: 5d 1e icall lr
16427 + 200022: e0 6e 00 00 mov lr,0
16428 + 200022: R_AVR32_GOTCALL toofar_positive
16429 + 200026: ec 0e 03 2e ld\.w lr,r6\[lr<<0x2\]
16430 + 20002a: 5d 1e icall lr
16431 + 20002c: 00 00 add r0,r0
16432 + 20002e: 00 00 add r0,r0
16433 + 200030: e0 a0 00 00 rcall 200030 <toofar_negative\+0x20002e>
16434 + 200030: R_AVR32_22H_PCREL \.text\+0x40002e
16435 + \.\.\.
16436 +
16437 +0040002c <toofar_positive>:
16438 + 40002c: d7 03 nop
16439 +0040002e <far_positive>:
16440 + 40002e: d7 03 nop
16441 +Disassembly of section \.text\.init:
16442 +
16443 +00000000 <different_section>:
16444 + 0: e2 c0 00 00 sub r0,r1,0
16445 --- /dev/null
16446 +++ b/gas/testsuite/gas/avr32/call.s
16447 @@ -0,0 +1,30 @@
16448 +
16449 + .text
16450 + .global call_test
16451 +call_test:
16452 +far_negative:
16453 + nop
16454 +toofar_negative:
16455 +
16456 + .org 0x200000
16457 +
16458 + call far_negative
16459 + call toofar_negative
16460 + call different_section
16461 + call undefined
16462 + call toofar_positive
16463 + .org 0x200030
16464 + call far_positive
16465 +
16466 + .cpool
16467 +
16468 + .org 0x40002c
16469 +
16470 +toofar_positive:
16471 + nop
16472 +far_positive:
16473 + nop
16474 +
16475 + .section .text.init,"ax",@progbits
16476 +different_section:
16477 + sub r0, r1, 0
16478 --- /dev/null
16479 +++ b/gas/testsuite/gas/avr32/dwarf2.d
16480 @@ -0,0 +1,42 @@
16481 +#readelf: -wl
16482 +#name: dwarf2
16483 +#source: dwarf2.s
16484 +
16485 +Dump of debug contents of section \.debug_line:
16486 +
16487 + Length: 53
16488 + DWARF Version: 2
16489 + Prologue Length: 26
16490 + Minimum Instruction Length: 1
16491 + Initial value of 'is_stmt': 1
16492 + Line Base: -5
16493 + Line Range: 14
16494 + Opcode Base: 10
16495 + \(Pointer size: 4\)
16496 +
16497 + Opcodes:
16498 + Opcode 1 has 0 args
16499 + Opcode 2 has 1 args
16500 + Opcode 3 has 1 args
16501 + Opcode 4 has 1 args
16502 + Opcode 5 has 1 args
16503 + Opcode 6 has 0 args
16504 + Opcode 7 has 0 args
16505 + Opcode 8 has 0 args
16506 + Opcode 9 has 1 args
16507 +
16508 + The Directory Table is empty\.
16509 +
16510 + The File Name Table:
16511 + Entry Dir Time Size Name
16512 + 1 0 0 0 main\.c
16513 +
16514 + Line Number Statements:
16515 + Extended opcode 2: set Address to 0x0
16516 + Advance Line by 87 to 88
16517 + Copy
16518 + Advance Line by 23 to 111
16519 + Special opcode .*: advance Address by 4 to 0x4 and Line by 0 to 111
16520 + Special opcode .*: advance Address by 10 to 0xe and Line by 1 to 112
16521 + Advance PC by 530 to 220
16522 + Extended opcode 1: End of Sequence
16523 --- /dev/null
16524 +++ b/gas/testsuite/gas/avr32/dwarf2.s
16525 @@ -0,0 +1,67 @@
16526 +# Source file used to test DWARF2 information for AVR32.
16527 +
16528 + .file "main.c"
16529 +
16530 + .section .debug_abbrev,"",@progbits
16531 +.Ldebug_abbrev0:
16532 + .section .debug_info,"",@progbits
16533 +.Ldebug_info0:
16534 + .section .debug_line,"",@progbits
16535 +.Ldebug_line0:
16536 +
16537 + .text
16538 + .align 1
16539 + .globl main
16540 + .type main, @function
16541 +.Ltext0:
16542 +main:
16543 + .file 1 "main.c"
16544 + .loc 1 88 0
16545 + pushm r0-r7,lr
16546 + sub sp, 4
16547 + .loc 1 111 0
16548 + lddpc r12, .LC1
16549 + lddpc r7, .LC1
16550 + icall r7
16551 + .loc 1 112 0
16552 + lddpc r6, .LC4
16553 +
16554 + .align 2
16555 +.LC4: .int 0
16556 +
16557 + .fill 256, 2, 0
16558 +
16559 + .align 2
16560 +.LC1:
16561 + .int 0
16562 +.LC2:
16563 + .int 0
16564 +.LC3:
16565 + .int 0
16566 + .size main, . - main
16567 +
16568 +.Letext0:
16569 +
16570 + .section .debug_info
16571 + .int .Ledebug_info0 - .Ldebug_info0 // size
16572 + .short 2 // version
16573 + .int .Ldebug_abbrev0 // abbrev offset
16574 + .byte 4 // bytes per addr
16575 +
16576 + .uleb128 1 // abbrev 1
16577 + .int .Ldebug_line0 // DW_AT_stmt_list
16578 + .int .Letext0 // DW_AT_high_pc
16579 + .int .Ltext0 // DW_AT_low_pc
16580 +
16581 +.Ledebug_info0:
16582 +
16583 + .section .debug_abbrev
16584 + .uleb128 0x01
16585 + .uleb128 0x11 // DW_TAG_compile_unit
16586 + .byte 0 // DW_CHILDREN_no
16587 + .uleb128 0x10, 0x6 // DW_AT_stmt_list
16588 + .uleb128 0x12, 0x1 // DW_AT_high_pc
16589 + .uleb128 0x11, 0x1 // DW_AT_low_pc
16590 + .uleb128 0, 0
16591 +
16592 + .byte 0
16593 --- /dev/null
16594 +++ b/gas/testsuite/gas/avr32/fpinsn.d
16595 @@ -0,0 +1,271 @@
16596 +#as:
16597 +#objdump: -dr
16598 +#name: fpinsn
16599 +
16600 +.*: +file format .*
16601 +
16602 +Disassembly of section \.text:
16603 +
16604 +[0-9a-f]* <fadd_s>:
16605 + *[0-9a-f]*: e1 a2 0f ff cop cp0,cr15,cr15,cr15,0x4
16606 + *[0-9a-f]*: e1 a2 00 00 cop cp0,cr0,cr0,cr0,0x4
16607 + *[0-9a-f]*: e1 a2 00 ff cop cp0,cr0,cr15,cr15,0x4
16608 + *[0-9a-f]*: e1 a2 0f 0f cop cp0,cr15,cr0,cr15,0x4
16609 + *[0-9a-f]*: e1 a2 0f f0 cop cp0,cr15,cr15,cr0,0x4
16610 + *[0-9a-f]*: e1 a2 07 88 cop cp0,cr7,cr8,cr8,0x4
16611 + *[0-9a-f]*: e1 a2 08 78 cop cp0,cr8,cr7,cr8,0x4
16612 + *[0-9a-f]*: e1 a2 08 87 cop cp0,cr8,cr8,cr7,0x4
16613 +
16614 +[0-9a-f]* <fsub_s>:
16615 + *[0-9a-f]*: e1 a2 1f ff cop cp0,cr15,cr15,cr15,0x5
16616 + *[0-9a-f]*: e1 a2 10 00 cop cp0,cr0,cr0,cr0,0x5
16617 + *[0-9a-f]*: e1 a2 10 ff cop cp0,cr0,cr15,cr15,0x5
16618 + *[0-9a-f]*: e1 a2 1f 0f cop cp0,cr15,cr0,cr15,0x5
16619 + *[0-9a-f]*: e1 a2 1f f0 cop cp0,cr15,cr15,cr0,0x5
16620 + *[0-9a-f]*: e1 a2 17 88 cop cp0,cr7,cr8,cr8,0x5
16621 + *[0-9a-f]*: e1 a2 18 78 cop cp0,cr8,cr7,cr8,0x5
16622 + *[0-9a-f]*: e1 a2 18 87 cop cp0,cr8,cr8,cr7,0x5
16623 +
16624 +[0-9a-f]* <fmac_s>:
16625 + *[0-9a-f]*: e1 a0 0f ff cop cp0,cr15,cr15,cr15,0x0
16626 + *[0-9a-f]*: e1 a0 00 00 cop cp0,cr0,cr0,cr0,0x0
16627 + *[0-9a-f]*: e1 a0 00 ff cop cp0,cr0,cr15,cr15,0x0
16628 + *[0-9a-f]*: e1 a0 0f 0f cop cp0,cr15,cr0,cr15,0x0
16629 + *[0-9a-f]*: e1 a0 0f f0 cop cp0,cr15,cr15,cr0,0x0
16630 + *[0-9a-f]*: e1 a0 07 88 cop cp0,cr7,cr8,cr8,0x0
16631 + *[0-9a-f]*: e1 a0 08 78 cop cp0,cr8,cr7,cr8,0x0
16632 + *[0-9a-f]*: e1 a0 08 87 cop cp0,cr8,cr8,cr7,0x0
16633 +
16634 +[0-9a-f]* <fnmac_s>:
16635 + *[0-9a-f]*: e1 a0 1f ff cop cp0,cr15,cr15,cr15,0x1
16636 + *[0-9a-f]*: e1 a0 10 00 cop cp0,cr0,cr0,cr0,0x1
16637 + *[0-9a-f]*: e1 a0 10 ff cop cp0,cr0,cr15,cr15,0x1
16638 + *[0-9a-f]*: e1 a0 1f 0f cop cp0,cr15,cr0,cr15,0x1
16639 + *[0-9a-f]*: e1 a0 1f f0 cop cp0,cr15,cr15,cr0,0x1
16640 + *[0-9a-f]*: e1 a0 17 88 cop cp0,cr7,cr8,cr8,0x1
16641 + *[0-9a-f]*: e1 a0 18 78 cop cp0,cr8,cr7,cr8,0x1
16642 + *[0-9a-f]*: e1 a0 18 87 cop cp0,cr8,cr8,cr7,0x1
16643 +
16644 +[0-9a-f]* <fmsc_s>:
16645 + *[0-9a-f]*: e1 a1 0f ff cop cp0,cr15,cr15,cr15,0x2
16646 + *[0-9a-f]*: e1 a1 00 00 cop cp0,cr0,cr0,cr0,0x2
16647 + *[0-9a-f]*: e1 a1 00 ff cop cp0,cr0,cr15,cr15,0x2
16648 + *[0-9a-f]*: e1 a1 0f 0f cop cp0,cr15,cr0,cr15,0x2
16649 + *[0-9a-f]*: e1 a1 0f f0 cop cp0,cr15,cr15,cr0,0x2
16650 + *[0-9a-f]*: e1 a1 07 88 cop cp0,cr7,cr8,cr8,0x2
16651 + *[0-9a-f]*: e1 a1 08 78 cop cp0,cr8,cr7,cr8,0x2
16652 + *[0-9a-f]*: e1 a1 08 87 cop cp0,cr8,cr8,cr7,0x2
16653 +
16654 +[0-9a-f]* <fnmsc_s>:
16655 + *[0-9a-f]*: e1 a1 1f ff cop cp0,cr15,cr15,cr15,0x3
16656 + *[0-9a-f]*: e1 a1 10 00 cop cp0,cr0,cr0,cr0,0x3
16657 + *[0-9a-f]*: e1 a1 10 ff cop cp0,cr0,cr15,cr15,0x3
16658 + *[0-9a-f]*: e1 a1 1f 0f cop cp0,cr15,cr0,cr15,0x3
16659 + *[0-9a-f]*: e1 a1 1f f0 cop cp0,cr15,cr15,cr0,0x3
16660 + *[0-9a-f]*: e1 a1 17 88 cop cp0,cr7,cr8,cr8,0x3
16661 + *[0-9a-f]*: e1 a1 18 78 cop cp0,cr8,cr7,cr8,0x3
16662 + *[0-9a-f]*: e1 a1 18 87 cop cp0,cr8,cr8,cr7,0x3
16663 +
16664 +[0-9a-f]* <fmul_s>:
16665 + *[0-9a-f]*: e1 a3 0f ff cop cp0,cr15,cr15,cr15,0x6
16666 + *[0-9a-f]*: e1 a3 00 00 cop cp0,cr0,cr0,cr0,0x6
16667 + *[0-9a-f]*: e1 a3 00 ff cop cp0,cr0,cr15,cr15,0x6
16668 + *[0-9a-f]*: e1 a3 0f 0f cop cp0,cr15,cr0,cr15,0x6
16669 + *[0-9a-f]*: e1 a3 0f f0 cop cp0,cr15,cr15,cr0,0x6
16670 + *[0-9a-f]*: e1 a3 07 88 cop cp0,cr7,cr8,cr8,0x6
16671 + *[0-9a-f]*: e1 a3 08 78 cop cp0,cr8,cr7,cr8,0x6
16672 + *[0-9a-f]*: e1 a3 08 87 cop cp0,cr8,cr8,cr7,0x6
16673 +
16674 +[0-9a-f]* <fnmul_s>:
16675 + *[0-9a-f]*: e1 a3 1f ff cop cp0,cr15,cr15,cr15,0x7
16676 + *[0-9a-f]*: e1 a3 10 00 cop cp0,cr0,cr0,cr0,0x7
16677 + *[0-9a-f]*: e1 a3 10 ff cop cp0,cr0,cr15,cr15,0x7
16678 + *[0-9a-f]*: e1 a3 1f 0f cop cp0,cr15,cr0,cr15,0x7
16679 + *[0-9a-f]*: e1 a3 1f f0 cop cp0,cr15,cr15,cr0,0x7
16680 + *[0-9a-f]*: e1 a3 17 88 cop cp0,cr7,cr8,cr8,0x7
16681 + *[0-9a-f]*: e1 a3 18 78 cop cp0,cr8,cr7,cr8,0x7
16682 + *[0-9a-f]*: e1 a3 18 87 cop cp0,cr8,cr8,cr7,0x7
16683 +
16684 +[0-9a-f]* <fneg_s>:
16685 + *[0-9a-f]*: e1 a4 0f f0 cop cp0,cr15,cr15,cr0,0x8
16686 + *[0-9a-f]*: e1 a4 00 00 cop cp0,cr0,cr0,cr0,0x8
16687 + *[0-9a-f]*: e1 a4 00 f0 cop cp0,cr0,cr15,cr0,0x8
16688 + *[0-9a-f]*: e1 a4 0f 00 cop cp0,cr15,cr0,cr0,0x8
16689 + *[0-9a-f]*: e1 a4 07 80 cop cp0,cr7,cr8,cr0,0x8
16690 + *[0-9a-f]*: e1 a4 08 70 cop cp0,cr8,cr7,cr0,0x8
16691 +
16692 +[0-9a-f]* <fabs_s>:
16693 + *[0-9a-f]*: e1 a4 1f f0 cop cp0,cr15,cr15,cr0,0x9
16694 + *[0-9a-f]*: e1 a4 10 00 cop cp0,cr0,cr0,cr0,0x9
16695 + *[0-9a-f]*: e1 a4 10 f0 cop cp0,cr0,cr15,cr0,0x9
16696 + *[0-9a-f]*: e1 a4 1f 00 cop cp0,cr15,cr0,cr0,0x9
16697 + *[0-9a-f]*: e1 a4 17 80 cop cp0,cr7,cr8,cr0,0x9
16698 + *[0-9a-f]*: e1 a4 18 70 cop cp0,cr8,cr7,cr0,0x9
16699 +
16700 +[0-9a-f]* <fcmp_s>:
16701 + *[0-9a-f]*: e1 a6 10 ff cop cp0,cr0,cr15,cr15,0xd
16702 + *[0-9a-f]*: e1 a6 10 00 cop cp0,cr0,cr0,cr0,0xd
16703 + *[0-9a-f]*: e1 a6 10 0f cop cp0,cr0,cr0,cr15,0xd
16704 + *[0-9a-f]*: e1 a6 10 f0 cop cp0,cr0,cr15,cr0,0xd
16705 + *[0-9a-f]*: e1 a6 10 78 cop cp0,cr0,cr7,cr8,0xd
16706 + *[0-9a-f]*: e1 a6 10 87 cop cp0,cr0,cr8,cr7,0xd
16707 +
16708 +[0-9a-f]* <fadd_d>:
16709 + *[0-9a-f]*: e5 a2 0e ee cop cp0,cr14,cr14,cr14,0x44
16710 + *[0-9a-f]*: e5 a2 00 00 cop cp0,cr0,cr0,cr0,0x44
16711 + *[0-9a-f]*: e5 a2 00 ee cop cp0,cr0,cr14,cr14,0x44
16712 + *[0-9a-f]*: e5 a2 0e 0e cop cp0,cr14,cr0,cr14,0x44
16713 + *[0-9a-f]*: e5 a2 0e e0 cop cp0,cr14,cr14,cr0,0x44
16714 + *[0-9a-f]*: e5 a2 06 88 cop cp0,cr6,cr8,cr8,0x44
16715 + *[0-9a-f]*: e5 a2 08 68 cop cp0,cr8,cr6,cr8,0x44
16716 + *[0-9a-f]*: e5 a2 08 86 cop cp0,cr8,cr8,cr6,0x44
16717 +
16718 +[0-9a-f]* <fsub_d>:
16719 + *[0-9a-f]*: e5 a2 1e ee cop cp0,cr14,cr14,cr14,0x45
16720 + *[0-9a-f]*: e5 a2 10 00 cop cp0,cr0,cr0,cr0,0x45
16721 + *[0-9a-f]*: e5 a2 10 ee cop cp0,cr0,cr14,cr14,0x45
16722 + *[0-9a-f]*: e5 a2 1e 0e cop cp0,cr14,cr0,cr14,0x45
16723 + *[0-9a-f]*: e5 a2 1e e0 cop cp0,cr14,cr14,cr0,0x45
16724 + *[0-9a-f]*: e5 a2 16 88 cop cp0,cr6,cr8,cr8,0x45
16725 + *[0-9a-f]*: e5 a2 18 68 cop cp0,cr8,cr6,cr8,0x45
16726 + *[0-9a-f]*: e5 a2 18 86 cop cp0,cr8,cr8,cr6,0x45
16727 +
16728 +[0-9a-f]* <fmac_d>:
16729 + *[0-9a-f]*: e5 a0 0e ee cop cp0,cr14,cr14,cr14,0x40
16730 + *[0-9a-f]*: e5 a0 00 00 cop cp0,cr0,cr0,cr0,0x40
16731 + *[0-9a-f]*: e5 a0 00 ee cop cp0,cr0,cr14,cr14,0x40
16732 + *[0-9a-f]*: e5 a0 0e 0e cop cp0,cr14,cr0,cr14,0x40
16733 + *[0-9a-f]*: e5 a0 0e e0 cop cp0,cr14,cr14,cr0,0x40
16734 + *[0-9a-f]*: e5 a0 06 88 cop cp0,cr6,cr8,cr8,0x40
16735 + *[0-9a-f]*: e5 a0 08 68 cop cp0,cr8,cr6,cr8,0x40
16736 + *[0-9a-f]*: e5 a0 08 86 cop cp0,cr8,cr8,cr6,0x40
16737 +
16738 +[0-9a-f]* <fnmac_d>:
16739 + *[0-9a-f]*: e5 a0 1e ee cop cp0,cr14,cr14,cr14,0x41
16740 + *[0-9a-f]*: e5 a0 10 00 cop cp0,cr0,cr0,cr0,0x41
16741 + *[0-9a-f]*: e5 a0 10 ee cop cp0,cr0,cr14,cr14,0x41
16742 + *[0-9a-f]*: e5 a0 1e 0e cop cp0,cr14,cr0,cr14,0x41
16743 + *[0-9a-f]*: e5 a0 1e e0 cop cp0,cr14,cr14,cr0,0x41
16744 + *[0-9a-f]*: e5 a0 16 88 cop cp0,cr6,cr8,cr8,0x41
16745 + *[0-9a-f]*: e5 a0 18 68 cop cp0,cr8,cr6,cr8,0x41
16746 + *[0-9a-f]*: e5 a0 18 86 cop cp0,cr8,cr8,cr6,0x41
16747 +
16748 +[0-9a-f]* <fmsc_d>:
16749 + *[0-9a-f]*: e5 a1 0e ee cop cp0,cr14,cr14,cr14,0x42
16750 + *[0-9a-f]*: e5 a1 00 00 cop cp0,cr0,cr0,cr0,0x42
16751 + *[0-9a-f]*: e5 a1 00 ee cop cp0,cr0,cr14,cr14,0x42
16752 + *[0-9a-f]*: e5 a1 0e 0e cop cp0,cr14,cr0,cr14,0x42
16753 + *[0-9a-f]*: e5 a1 0e e0 cop cp0,cr14,cr14,cr0,0x42
16754 + *[0-9a-f]*: e5 a1 06 88 cop cp0,cr6,cr8,cr8,0x42
16755 + *[0-9a-f]*: e5 a1 08 68 cop cp0,cr8,cr6,cr8,0x42
16756 + *[0-9a-f]*: e5 a1 08 86 cop cp0,cr8,cr8,cr6,0x42
16757 +
16758 +[0-9a-f]* <fnmsc_d>:
16759 + *[0-9a-f]*: e5 a1 1e ee cop cp0,cr14,cr14,cr14,0x43
16760 + *[0-9a-f]*: e5 a1 10 00 cop cp0,cr0,cr0,cr0,0x43
16761 + *[0-9a-f]*: e5 a1 10 ee cop cp0,cr0,cr14,cr14,0x43
16762 + *[0-9a-f]*: e5 a1 1e 0e cop cp0,cr14,cr0,cr14,0x43
16763 + *[0-9a-f]*: e5 a1 1e e0 cop cp0,cr14,cr14,cr0,0x43
16764 + *[0-9a-f]*: e5 a1 16 88 cop cp0,cr6,cr8,cr8,0x43
16765 + *[0-9a-f]*: e5 a1 18 68 cop cp0,cr8,cr6,cr8,0x43
16766 + *[0-9a-f]*: e5 a1 18 86 cop cp0,cr8,cr8,cr6,0x43
16767 +
16768 +[0-9a-f]* <fmul_d>:
16769 + *[0-9a-f]*: e5 a3 0e ee cop cp0,cr14,cr14,cr14,0x46
16770 + *[0-9a-f]*: e5 a3 00 00 cop cp0,cr0,cr0,cr0,0x46
16771 + *[0-9a-f]*: e5 a3 00 ee cop cp0,cr0,cr14,cr14,0x46
16772 + *[0-9a-f]*: e5 a3 0e 0e cop cp0,cr14,cr0,cr14,0x46
16773 + *[0-9a-f]*: e5 a3 0e e0 cop cp0,cr14,cr14,cr0,0x46
16774 + *[0-9a-f]*: e5 a3 06 88 cop cp0,cr6,cr8,cr8,0x46
16775 + *[0-9a-f]*: e5 a3 08 68 cop cp0,cr8,cr6,cr8,0x46
16776 + *[0-9a-f]*: e5 a3 08 86 cop cp0,cr8,cr8,cr6,0x46
16777 +
16778 +[0-9a-f]* <fnmul_d>:
16779 + *[0-9a-f]*: e5 a3 1e ee cop cp0,cr14,cr14,cr14,0x47
16780 + *[0-9a-f]*: e5 a3 10 00 cop cp0,cr0,cr0,cr0,0x47
16781 + *[0-9a-f]*: e5 a3 10 ee cop cp0,cr0,cr14,cr14,0x47
16782 + *[0-9a-f]*: e5 a3 1e 0e cop cp0,cr14,cr0,cr14,0x47
16783 + *[0-9a-f]*: e5 a3 1e e0 cop cp0,cr14,cr14,cr0,0x47
16784 + *[0-9a-f]*: e5 a3 16 88 cop cp0,cr6,cr8,cr8,0x47
16785 + *[0-9a-f]*: e5 a3 18 68 cop cp0,cr8,cr6,cr8,0x47
16786 + *[0-9a-f]*: e5 a3 18 86 cop cp0,cr8,cr8,cr6,0x47
16787 +
16788 +[0-9a-f]* <fneg_d>:
16789 + *[0-9a-f]*: e5 a4 0e e0 cop cp0,cr14,cr14,cr0,0x48
16790 + *[0-9a-f]*: e5 a4 00 00 cop cp0,cr0,cr0,cr0,0x48
16791 + *[0-9a-f]*: e5 a4 00 e0 cop cp0,cr0,cr14,cr0,0x48
16792 + *[0-9a-f]*: e5 a4 0e 00 cop cp0,cr14,cr0,cr0,0x48
16793 + *[0-9a-f]*: e5 a4 06 80 cop cp0,cr6,cr8,cr0,0x48
16794 + *[0-9a-f]*: e5 a4 08 60 cop cp0,cr8,cr6,cr0,0x48
16795 +
16796 +[0-9a-f]* <fabs_d>:
16797 + *[0-9a-f]*: e5 a4 1e e0 cop cp0,cr14,cr14,cr0,0x49
16798 + *[0-9a-f]*: e5 a4 10 00 cop cp0,cr0,cr0,cr0,0x49
16799 + *[0-9a-f]*: e5 a4 10 e0 cop cp0,cr0,cr14,cr0,0x49
16800 + *[0-9a-f]*: e5 a4 1e 00 cop cp0,cr14,cr0,cr0,0x49
16801 + *[0-9a-f]*: e5 a4 16 80 cop cp0,cr6,cr8,cr0,0x49
16802 + *[0-9a-f]*: e5 a4 18 60 cop cp0,cr8,cr6,cr0,0x49
16803 +
16804 +[0-9a-f]* <fcmp_d>:
16805 + *[0-9a-f]*: e5 a6 10 ee cop cp0,cr0,cr14,cr14,0x4d
16806 + *[0-9a-f]*: e5 a6 10 00 cop cp0,cr0,cr0,cr0,0x4d
16807 + *[0-9a-f]*: e5 a6 10 0e cop cp0,cr0,cr0,cr14,0x4d
16808 + *[0-9a-f]*: e5 a6 10 e0 cop cp0,cr0,cr14,cr0,0x4d
16809 + *[0-9a-f]*: e5 a6 10 68 cop cp0,cr0,cr6,cr8,0x4d
16810 + *[0-9a-f]*: e5 a6 10 86 cop cp0,cr0,cr8,cr6,0x4d
16811 +
16812 +[0-9a-f]* <fmov_s>:
16813 + *[0-9a-f]*: e1 a5 0f f0 cop cp0,cr15,cr15,cr0,0xa
16814 + *[0-9a-f]*: e1 a5 00 00 cop cp0,cr0,cr0,cr0,0xa
16815 + *[0-9a-f]*: e1 a5 0f 00 cop cp0,cr15,cr0,cr0,0xa
16816 + *[0-9a-f]*: e1 a5 00 f0 cop cp0,cr0,cr15,cr0,0xa
16817 + *[0-9a-f]*: e1 a5 08 70 cop cp0,cr8,cr7,cr0,0xa
16818 + *[0-9a-f]*: e1 a5 07 80 cop cp0,cr7,cr8,cr0,0xa
16819 + *[0-9a-f]*: ef af 0f 00 mvcr.w cp0,pc,cr15
16820 + *[0-9a-f]*: ef a0 00 00 mvcr.w cp0,r0,cr0
16821 + *[0-9a-f]*: ef af 00 00 mvcr.w cp0,pc,cr0
16822 + *[0-9a-f]*: ef a0 0f 00 mvcr.w cp0,r0,cr15
16823 + *[0-9a-f]*: ef a8 07 00 mvcr.w cp0,r8,cr7
16824 + *[0-9a-f]*: ef a7 08 00 mvcr.w cp0,r7,cr8
16825 + *[0-9a-f]*: ef af 0f 20 mvrc.w cp0,cr15,pc
16826 + *[0-9a-f]*: ef a0 00 20 mvrc.w cp0,cr0,r0
16827 + *[0-9a-f]*: ef a0 0f 20 mvrc.w cp0,cr15,r0
16828 + *[0-9a-f]*: ef af 00 20 mvrc.w cp0,cr0,pc
16829 + *[0-9a-f]*: ef a7 08 20 mvrc.w cp0,cr8,r7
16830 + *[0-9a-f]*: ef a8 07 20 mvrc.w cp0,cr7,r8
16831 +
16832 +[0-9a-f]* <fmov_d>:
16833 + *[0-9a-f]*: e5 a5 0e e0 cop cp0,cr14,cr14,cr0,0x4a
16834 + *[0-9a-f]*: e5 a5 00 00 cop cp0,cr0,cr0,cr0,0x4a
16835 + *[0-9a-f]*: e5 a5 0e 00 cop cp0,cr14,cr0,cr0,0x4a
16836 + *[0-9a-f]*: e5 a5 00 e0 cop cp0,cr0,cr14,cr0,0x4a
16837 + *[0-9a-f]*: e5 a5 08 60 cop cp0,cr8,cr6,cr0,0x4a
16838 + *[0-9a-f]*: e5 a5 06 80 cop cp0,cr6,cr8,cr0,0x4a
16839 + *[0-9a-f]*: ef ae 0e 10 mvcr.d cp0,lr,cr14
16840 + *[0-9a-f]*: ef a0 00 10 mvcr.d cp0,r0,cr0
16841 + *[0-9a-f]*: ef ae 00 10 mvcr.d cp0,lr,cr0
16842 + *[0-9a-f]*: ef a0 0e 10 mvcr.d cp0,r0,cr14
16843 + *[0-9a-f]*: ef a8 06 10 mvcr.d cp0,r8,cr6
16844 + *[0-9a-f]*: ef a6 08 10 mvcr.d cp0,r6,cr8
16845 + *[0-9a-f]*: ef ae 0e 30 mvrc.d cp0,cr14,lr
16846 + *[0-9a-f]*: ef a0 00 30 mvrc.d cp0,cr0,r0
16847 + *[0-9a-f]*: ef a0 0e 30 mvrc.d cp0,cr14,r0
16848 + *[0-9a-f]*: ef ae 00 30 mvrc.d cp0,cr0,lr
16849 + *[0-9a-f]*: ef a6 08 30 mvrc.d cp0,cr8,r6
16850 + *[0-9a-f]*: ef a8 06 30 mvrc.d cp0,cr6,r8
16851 +
16852 +[0-9a-f]* <fcasts_d>:
16853 + *[0-9a-f]*: e1 a7 1f e0 cop cp0,cr15,cr14,cr0,0xf
16854 + *[0-9a-f]*: e1 a7 10 00 cop cp0,cr0,cr0,cr0,0xf
16855 + *[0-9a-f]*: e1 a7 1f 00 cop cp0,cr15,cr0,cr0,0xf
16856 + *[0-9a-f]*: e1 a7 10 e0 cop cp0,cr0,cr14,cr0,0xf
16857 + *[0-9a-f]*: e1 a7 18 60 cop cp0,cr8,cr6,cr0,0xf
16858 + *[0-9a-f]*: e1 a7 17 80 cop cp0,cr7,cr8,cr0,0xf
16859 +
16860 +[0-9a-f]* <fcastd_s>:
16861 + *[0-9a-f]*: e1 a8 0e f0 cop cp0,cr14,cr15,cr0,0x10
16862 + *[0-9a-f]*: e1 a8 00 00 cop cp0,cr0,cr0,cr0,0x10
16863 + *[0-9a-f]*: e1 a8 0e 00 cop cp0,cr14,cr0,cr0,0x10
16864 + *[0-9a-f]*: e1 a8 00 f0 cop cp0,cr0,cr15,cr0,0x10
16865 + *[0-9a-f]*: e1 a8 08 70 cop cp0,cr8,cr7,cr0,0x10
16866 + *[0-9a-f]*: e1 a8 06 80 cop cp0,cr6,cr8,cr0,0x10
16867 --- /dev/null
16868 +++ b/gas/testsuite/gas/avr32/fpinsn.s
16869 @@ -0,0 +1,266 @@
16870 +
16871 + .text
16872 + .global fadd_s
16873 +fadd_s:
16874 + fadd.s fr15, fr15, fr15
16875 + fadd.s fr0, fr0, fr0
16876 + fadd.s fr0, fr15, fr15
16877 + fadd.s fr15, fr0, fr15
16878 + fadd.s fr15, fr15, fr0
16879 + fadd.s fr7, fr8, fr8
16880 + fadd.s fr8, fr7, fr8
16881 + fadd.s fr8, fr8, fr7
16882 + .global fsub_s
16883 +fsub_s:
16884 + fsub.s fr15, fr15, fr15
16885 + fsub.s fr0, fr0, fr0
16886 + fsub.s fr0, fr15, fr15
16887 + fsub.s fr15, fr0, fr15
16888 + fsub.s fr15, fr15, fr0
16889 + fsub.s fr7, fr8, fr8
16890 + fsub.s fr8, fr7, fr8
16891 + fsub.s fr8, fr8, fr7
16892 + .global fmac_s
16893 +fmac_s:
16894 + fmac.s fr15, fr15, fr15
16895 + fmac.s fr0, fr0, fr0
16896 + fmac.s fr0, fr15, fr15
16897 + fmac.s fr15, fr0, fr15
16898 + fmac.s fr15, fr15, fr0
16899 + fmac.s fr7, fr8, fr8
16900 + fmac.s fr8, fr7, fr8
16901 + fmac.s fr8, fr8, fr7
16902 + .global fnmac_s
16903 +fnmac_s:
16904 + fnmac.s fr15, fr15, fr15
16905 + fnmac.s fr0, fr0, fr0
16906 + fnmac.s fr0, fr15, fr15
16907 + fnmac.s fr15, fr0, fr15
16908 + fnmac.s fr15, fr15, fr0
16909 + fnmac.s fr7, fr8, fr8
16910 + fnmac.s fr8, fr7, fr8
16911 + fnmac.s fr8, fr8, fr7
16912 + .global fmsc_s
16913 +fmsc_s:
16914 + fmsc.s fr15, fr15, fr15
16915 + fmsc.s fr0, fr0, fr0
16916 + fmsc.s fr0, fr15, fr15
16917 + fmsc.s fr15, fr0, fr15
16918 + fmsc.s fr15, fr15, fr0
16919 + fmsc.s fr7, fr8, fr8
16920 + fmsc.s fr8, fr7, fr8
16921 + fmsc.s fr8, fr8, fr7
16922 + .global fnmsc_s
16923 +fnmsc_s:
16924 + fnmsc.s fr15, fr15, fr15
16925 + fnmsc.s fr0, fr0, fr0
16926 + fnmsc.s fr0, fr15, fr15
16927 + fnmsc.s fr15, fr0, fr15
16928 + fnmsc.s fr15, fr15, fr0
16929 + fnmsc.s fr7, fr8, fr8
16930 + fnmsc.s fr8, fr7, fr8
16931 + fnmsc.s fr8, fr8, fr7
16932 + .global fmul_s
16933 +fmul_s:
16934 + fmul.s fr15, fr15, fr15
16935 + fmul.s fr0, fr0, fr0
16936 + fmul.s fr0, fr15, fr15
16937 + fmul.s fr15, fr0, fr15
16938 + fmul.s fr15, fr15, fr0
16939 + fmul.s fr7, fr8, fr8
16940 + fmul.s fr8, fr7, fr8
16941 + fmul.s fr8, fr8, fr7
16942 + .global fnmul_s
16943 +fnmul_s:
16944 + fnmul.s fr15, fr15, fr15
16945 + fnmul.s fr0, fr0, fr0
16946 + fnmul.s fr0, fr15, fr15
16947 + fnmul.s fr15, fr0, fr15
16948 + fnmul.s fr15, fr15, fr0
16949 + fnmul.s fr7, fr8, fr8
16950 + fnmul.s fr8, fr7, fr8
16951 + fnmul.s fr8, fr8, fr7
16952 + .global fneg_s
16953 +fneg_s:
16954 + fneg.s fr15, fr15
16955 + fneg.s fr0, fr0
16956 + fneg.s fr0, fr15
16957 + fneg.s fr15, fr0
16958 + fneg.s fr7, fr8
16959 + fneg.s fr8, fr7
16960 + .global fabs_s
16961 +fabs_s:
16962 + fabs.s fr15, fr15
16963 + fabs.s fr0, fr0
16964 + fabs.s fr0, fr15
16965 + fabs.s fr15, fr0
16966 + fabs.s fr7, fr8
16967 + fabs.s fr8, fr7
16968 + .global fcmp_s
16969 +fcmp_s:
16970 + fcmp.s fr15, fr15
16971 + fcmp.s fr0, fr0
16972 + fcmp.s fr0, fr15
16973 + fcmp.s fr15, fr0
16974 + fcmp.s fr7, fr8
16975 + fcmp.s fr8, fr7
16976 + .global fadd_d
16977 +fadd_d:
16978 + fadd.d fr14, fr14, fr14
16979 + fadd.d fr0, fr0, fr0
16980 + fadd.d fr0, fr14, fr14
16981 + fadd.d fr14, fr0, fr14
16982 + fadd.d fr14, fr14, fr0
16983 + fadd.d fr6, fr8, fr8
16984 + fadd.d fr8, fr6, fr8
16985 + fadd.d fr8, fr8, fr6
16986 + .global fsub_d
16987 +fsub_d:
16988 + fsub.d fr14, fr14, fr14
16989 + fsub.d fr0, fr0, fr0
16990 + fsub.d fr0, fr14, fr14
16991 + fsub.d fr14, fr0, fr14
16992 + fsub.d fr14, fr14, fr0
16993 + fsub.d fr6, fr8, fr8
16994 + fsub.d fr8, fr6, fr8
16995 + fsub.d fr8, fr8, fr6
16996 + .global fmac_d
16997 +fmac_d:
16998 + fmac.d fr14, fr14, fr14
16999 + fmac.d fr0, fr0, fr0
17000 + fmac.d fr0, fr14, fr14
17001 + fmac.d fr14, fr0, fr14
17002 + fmac.d fr14, fr14, fr0
17003 + fmac.d fr6, fr8, fr8
17004 + fmac.d fr8, fr6, fr8
17005 + fmac.d fr8, fr8, fr6
17006 + .global fnmac_d
17007 +fnmac_d:
17008 + fnmac.d fr14, fr14, fr14
17009 + fnmac.d fr0, fr0, fr0
17010 + fnmac.d fr0, fr14, fr14
17011 + fnmac.d fr14, fr0, fr14
17012 + fnmac.d fr14, fr14, fr0
17013 + fnmac.d fr6, fr8, fr8
17014 + fnmac.d fr8, fr6, fr8
17015 + fnmac.d fr8, fr8, fr6
17016 + .global fmsc_d
17017 +fmsc_d:
17018 + fmsc.d fr14, fr14, fr14
17019 + fmsc.d fr0, fr0, fr0
17020 + fmsc.d fr0, fr14, fr14
17021 + fmsc.d fr14, fr0, fr14
17022 + fmsc.d fr14, fr14, fr0
17023 + fmsc.d fr6, fr8, fr8
17024 + fmsc.d fr8, fr6, fr8
17025 + fmsc.d fr8, fr8, fr6
17026 + .global fnmsc_d
17027 +fnmsc_d:
17028 + fnmsc.d fr14, fr14, fr14
17029 + fnmsc.d fr0, fr0, fr0
17030 + fnmsc.d fr0, fr14, fr14
17031 + fnmsc.d fr14, fr0, fr14
17032 + fnmsc.d fr14, fr14, fr0
17033 + fnmsc.d fr6, fr8, fr8
17034 + fnmsc.d fr8, fr6, fr8
17035 + fnmsc.d fr8, fr8, fr6
17036 + .global fmul_d
17037 +fmul_d:
17038 + fmul.d fr14, fr14, fr14
17039 + fmul.d fr0, fr0, fr0
17040 + fmul.d fr0, fr14, fr14
17041 + fmul.d fr14, fr0, fr14
17042 + fmul.d fr14, fr14, fr0
17043 + fmul.d fr6, fr8, fr8
17044 + fmul.d fr8, fr6, fr8
17045 + fmul.d fr8, fr8, fr6
17046 + .global fnmul_d
17047 +fnmul_d:
17048 + fnmul.d fr14, fr14, fr14
17049 + fnmul.d fr0, fr0, fr0
17050 + fnmul.d fr0, fr14, fr14
17051 + fnmul.d fr14, fr0, fr14
17052 + fnmul.d fr14, fr14, fr0
17053 + fnmul.d fr6, fr8, fr8
17054 + fnmul.d fr8, fr6, fr8
17055 + fnmul.d fr8, fr8, fr6
17056 + .global fneg_d
17057 +fneg_d:
17058 + fneg.d fr14, fr14
17059 + fneg.d fr0, fr0
17060 + fneg.d fr0, fr14
17061 + fneg.d fr14, fr0
17062 + fneg.d fr6, fr8
17063 + fneg.d fr8, fr6
17064 + .global fabs_d
17065 +fabs_d:
17066 + fabs.d fr14, fr14
17067 + fabs.d fr0, fr0
17068 + fabs.d fr0, fr14
17069 + fabs.d fr14, fr0
17070 + fabs.d fr6, fr8
17071 + fabs.d fr8, fr6
17072 + .global fcmp_d
17073 +fcmp_d:
17074 + fcmp.d fr14, fr14
17075 + fcmp.d fr0, fr0
17076 + fcmp.d fr0, fr14
17077 + fcmp.d fr14, fr0
17078 + fcmp.d fr6, fr8
17079 + fcmp.d fr8, fr6
17080 + .global fmov_s
17081 +fmov_s:
17082 + fmov.s fr15, fr15
17083 + fmov.s fr0, fr0
17084 + fmov.s fr15, fr0
17085 + fmov.s fr0, fr15
17086 + fmov.s fr8, fr7
17087 + fmov.s fr7, fr8
17088 + fmov.s pc, fr15
17089 + fmov.s r0, fr0
17090 + fmov.s pc, fr0
17091 + fmov.s r0, fr15
17092 + fmov.s r8, fr7
17093 + fmov.s r7, fr8
17094 + fmov.s fr15, pc
17095 + fmov.s fr0, r0
17096 + fmov.s fr15, r0
17097 + fmov.s fr0, pc
17098 + fmov.s fr8, r7
17099 + fmov.s fr7, r8
17100 + .global fmov_d
17101 +fmov_d:
17102 + fmov.d fr14, fr14
17103 + fmov.d fr0, fr0
17104 + fmov.d fr14, fr0
17105 + fmov.d fr0, fr14
17106 + fmov.d fr8, fr6
17107 + fmov.d fr6, fr8
17108 + fmov.d lr, fr14
17109 + fmov.d r0, fr0
17110 + fmov.d lr, fr0
17111 + fmov.d r0, fr14
17112 + fmov.d r8, fr6
17113 + fmov.d r6, fr8
17114 + fmov.d fr14, lr
17115 + fmov.d fr0, r0
17116 + fmov.d fr14, r0
17117 + fmov.d fr0, lr
17118 + fmov.d fr8, r6
17119 + fmov.d fr6, r8
17120 + .global fcasts_d
17121 +fcasts_d:
17122 + fcasts.d fr15, fr14
17123 + fcasts.d fr0, fr0
17124 + fcasts.d fr15, fr0
17125 + fcasts.d fr0, fr14
17126 + fcasts.d fr8, fr6
17127 + fcasts.d fr7, fr8
17128 + .global fcastd_s
17129 +fcastd_s:
17130 + fcastd.s fr14, fr15
17131 + fcastd.s fr0, fr0
17132 + fcastd.s fr14, fr0
17133 + fcastd.s fr0, fr15
17134 + fcastd.s fr8, fr7
17135 + fcastd.s fr6, fr8
17136 --- /dev/null
17137 +++ b/gas/testsuite/gas/avr32/hwrd-lwrd.d
17138 @@ -0,0 +1,47 @@
17139 +#as:
17140 +#objdump: -dr
17141 +#name: hwrd-lwrd
17142 +
17143 +.*: +file format .*
17144 +
17145 +Disassembly of section \.text:
17146 +
17147 +00000000 <test_hwrd>:
17148 + 0: e0 60 87 65 mov r0,34661
17149 + 4: e0 60 12 34 mov r0,4660
17150 + 8: e0 60 00 00 mov r0,0
17151 + 8: R_AVR32_HI16 \.text\+0x60
17152 + c: e0 60 00 00 mov r0,0
17153 + c: R_AVR32_HI16 extsym1
17154 + 10: ea 10 87 65 orh r0,0x8765
17155 + 14: ea 10 12 34 orh r0,0x1234
17156 + 18: ea 10 00 00 orh r0,0x0
17157 + 18: R_AVR32_HI16 \.text\+0x60
17158 + 1c: ea 10 00 00 orh r0,0x0
17159 + 1c: R_AVR32_HI16 extsym1
17160 + 20: e4 10 87 65 andh r0,0x8765
17161 + 24: e4 10 12 34 andh r0,0x1234
17162 + 28: e4 10 00 00 andh r0,0x0
17163 + 28: R_AVR32_HI16 \.text\+0x60
17164 + 2c: e4 10 00 00 andh r0,0x0
17165 + 2c: R_AVR32_HI16 extsym1
17166 +
17167 +00000030 <test_lwrd>:
17168 + 30: e0 60 43 21 mov r0,17185
17169 + 34: e0 60 56 78 mov r0,22136
17170 + 38: e0 60 00 00 mov r0,0
17171 + 38: R_AVR32_LO16 \.text\+0x60
17172 + 3c: e0 60 00 00 mov r0,0
17173 + 3c: R_AVR32_LO16 extsym1
17174 + 40: e8 10 43 21 orl r0,0x4321
17175 + 44: e8 10 56 78 orl r0,0x5678
17176 + 48: e8 10 00 00 orl r0,0x0
17177 + 48: R_AVR32_LO16 \.text\+0x60
17178 + 4c: e8 10 00 00 orl r0,0x0
17179 + 4c: R_AVR32_LO16 extsym1
17180 + 50: e0 10 43 21 andl r0,0x4321
17181 + 54: e0 10 56 78 andl r0,0x5678
17182 + 58: e0 10 00 00 andl r0,0x0
17183 + 58: R_AVR32_LO16 \.text\+0x60
17184 + 5c: e0 10 00 00 andl r0,0x0
17185 + 5c: R_AVR32_LO16 extsym1
17186 --- /dev/null
17187 +++ b/gas/testsuite/gas/avr32/hwrd-lwrd.s
17188 @@ -0,0 +1,39 @@
17189 +
17190 + .equ sym1, 0x12345678
17191 +
17192 + .text
17193 + .global test_hwrd
17194 +test_hwrd:
17195 + mov r0, hi(0x87654321)
17196 + mov r0, hi(sym1)
17197 + mov r0, hi(sym2)
17198 + mov r0, hi(extsym1)
17199 +
17200 + orh r0, hi(0x87654321)
17201 + orh r0, hi(sym1)
17202 + orh r0, hi(sym2)
17203 + orh r0, hi(extsym1)
17204 +
17205 + andh r0, hi(0x87654321)
17206 + andh r0, hi(sym1)
17207 + andh r0, hi(sym2)
17208 + andh r0, hi(extsym1)
17209 +
17210 + .global test_lwrd
17211 +test_lwrd:
17212 + mov r0, lo(0x87654321)
17213 + mov r0, lo(sym1)
17214 + mov r0, lo(sym2)
17215 + mov r0, lo(extsym1)
17216 +
17217 + orl r0, lo(0x87654321)
17218 + orl r0, lo(sym1)
17219 + orl r0, lo(sym2)
17220 + orl r0, lo(extsym1)
17221 +
17222 + andl r0, lo(0x87654321)
17223 + andl r0, lo(sym1)
17224 + andl r0, lo(sym2)
17225 + andl r0, lo(extsym1)
17226 +
17227 +sym2:
17228 --- /dev/null
17229 +++ b/gas/testsuite/gas/avr32/jmptable.d
17230 @@ -0,0 +1,20 @@
17231 +#source: jmptable.s
17232 +#as:
17233 +#objdump: -dr
17234 +#name: jmptable
17235 +
17236 +.*: +file format .*
17237 +
17238 +Disassembly of section \.text:
17239 +
17240 +00000000 <jmptable_test>:
17241 + 0: fe c8 ff f4 sub r8,pc,-12
17242 + 4: f0 00 00 2f add pc,r8,r0<<0x2
17243 + 8: d7 03 nop
17244 + a: 00 00 add r0,r0
17245 + c: c0 38 rjmp 12 <jmptable_test\+0x12>
17246 + e: c0 38 rjmp 14 <jmptable_test\+0x14>
17247 + 10: c0 38 rjmp 16 <jmptable_test\+0x16>
17248 + 12: d7 03 nop
17249 + 14: d7 03 nop
17250 + 16: d7 03 nop
17251 --- /dev/null
17252 +++ b/gas/testsuite/gas/avr32/jmptable_linkrelax.d
17253 @@ -0,0 +1,25 @@
17254 +#source: jmptable.s
17255 +#as: --linkrelax
17256 +#objdump: -dr
17257 +#name: jmptable_linkrelax
17258 +
17259 +.*: +file format .*
17260 +
17261 +Disassembly of section \.text:
17262 +
17263 +00000000 <jmptable_test>:
17264 + 0: fe c8 00 00 sub r8,pc,0
17265 + 0: R_AVR32_16N_PCREL \.text\+0xc
17266 + 4: f0 00 00 2f add pc,r8,r0<<0x2
17267 + 8: d7 03 nop
17268 + a: 00 00 add r0,r0
17269 + a: R_AVR32_ALIGN \*ABS\*\+0x2
17270 + c: c0 08 rjmp c <jmptable_test\+0xc>
17271 + c: R_AVR32_11H_PCREL \.text\+0x12
17272 + e: c0 08 rjmp e <jmptable_test\+0xe>
17273 + e: R_AVR32_11H_PCREL \.text\+0x14
17274 + 10: c0 08 rjmp 10 <jmptable_test\+0x10>
17275 + 10: R_AVR32_11H_PCREL \.text\+0x16
17276 + 12: d7 03 nop
17277 + 14: d7 03 nop
17278 + 16: d7 03 nop
17279 --- /dev/null
17280 +++ b/gas/testsuite/gas/avr32/jmptable.s
17281 @@ -0,0 +1,14 @@
17282 +
17283 + .text
17284 + .global jmptable_test
17285 +jmptable_test:
17286 + sub r8, pc, -(.L1 - .)
17287 + add pc, r8, r0 << 2
17288 + nop
17289 + .align 2
17290 +.L1: rjmp 1f
17291 + rjmp 2f
17292 + rjmp 3f
17293 +1: nop
17294 +2: nop
17295 +3: nop
17296 --- /dev/null
17297 +++ b/gas/testsuite/gas/avr32/lda_nopic.d
17298 @@ -0,0 +1,32 @@
17299 +#source: lda.s
17300 +#as:
17301 +#objdump: -dr
17302 +#name: lda_nopic
17303 +
17304 +.*: +file format .*
17305 +
17306 +Disassembly of section \.text:
17307 +
17308 +00000000 <lda_test>:
17309 + 0: f2 c8 00 00 sub r8,r9,0
17310 +
17311 +00000004 <far_negative>:
17312 + 4: f6 ca 00 00 sub r10,r11,0
17313 + ...
17314 + 8000: fe c0 7f fc sub r0,pc,32764
17315 + 8004: 48 31 lddpc r1,8010 <far_negative\+0x800c>
17316 + 8006: 48 42 lddpc r2,8014 <far_negative\+0x8010>
17317 + 8008: 48 43 lddpc r3,8018 <far_negative\+0x8014>
17318 + 800a: 48 54 lddpc r4,801c <far_negative\+0x8018>
17319 + 800c: fe c5 80 04 sub r5,pc,-32764
17320 + ...
17321 + 8010: R_AVR32_32_CPENT \.text
17322 + 8014: R_AVR32_32_CPENT \.data
17323 + 8018: R_AVR32_32_CPENT undefined
17324 + 801c: R_AVR32_32_CPENT \.text\+0x1001c
17325 +
17326 +00010008 <far_positive>:
17327 + 10008: fa cc 00 00 sub r12,sp,0
17328 + ...
17329 +0001001c <toofar_positive>:
17330 + 1001c: fe ce 00 00 sub lr,pc,0
17331 --- /dev/null
17332 +++ b/gas/testsuite/gas/avr32/lda_nopic_linkrelax.d
17333 @@ -0,0 +1,41 @@
17334 +#source: lda.s
17335 +#as: --linkrelax
17336 +#objdump: -dr
17337 +#name: lda_nopic_linkrelax
17338 +
17339 +.*: +file format .*
17340 +
17341 +Disassembly of section \.text:
17342 +
17343 +00000000 <lda_test>:
17344 + 0: f2 c8 00 00 sub r8,r9,0
17345 +
17346 +00000004 <far_negative>:
17347 + 4: f6 ca 00 00 sub r10,r11,0
17348 + \.\.\.
17349 + 8000: 48 00 lddpc r0,8000 <far_negative\+0x7ffc>
17350 + 8000: R_AVR32_9W_CP \.text\+0x800c
17351 + 8002: 48 01 lddpc r1,8000 <far_negative\+0x7ffc>
17352 + 8002: R_AVR32_9W_CP \.text\+0x8010
17353 + 8004: 48 02 lddpc r2,8004 <far_negative\+0x8000>
17354 + 8004: R_AVR32_9W_CP \.text\+0x8014
17355 + 8006: 48 03 lddpc r3,8004 <far_negative\+0x8000>
17356 + 8006: R_AVR32_9W_CP \.text\+0x8018
17357 + 8008: 48 04 lddpc r4,8008 <far_negative\+0x8004>
17358 + 8008: R_AVR32_9W_CP \.text\+0x801c
17359 + 800a: 48 05 lddpc r5,8008 <far_negative\+0x8004>
17360 + 800a: R_AVR32_9W_CP \.text\+0x8020
17361 + \.\.\.
17362 + 800c: R_AVR32_ALIGN \*ABS\*\+0x2
17363 + 800c: R_AVR32_32_CPENT \.text\+0x4
17364 + 8010: R_AVR32_32_CPENT \.text
17365 + 8014: R_AVR32_32_CPENT \.data
17366 + 8018: R_AVR32_32_CPENT undefined
17367 + 801c: R_AVR32_32_CPENT \.text\+0x10020
17368 + 8020: R_AVR32_32_CPENT \.text\+0x1000c
17369 +
17370 +0001000c <far_positive>:
17371 + 1000c: fa cc 00 00 sub r12,sp,0
17372 + \.\.\.
17373 +00010020 <toofar_positive>:
17374 + 10020: fe ce 00 00 sub lr,pc,0
17375 --- /dev/null
17376 +++ b/gas/testsuite/gas/avr32/lda_pic.d
17377 @@ -0,0 +1,32 @@
17378 +#source: lda.s
17379 +#as: --pic
17380 +#objdump: -dr
17381 +#name: lda_pic
17382 +
17383 +.*: +file format .*
17384 +
17385 +Disassembly of section \.text:
17386 +
17387 +00000000 <lda_test>:
17388 + 0: f2 c8 00 00 sub r8,r9,0
17389 +
17390 +00000004 <far_negative>:
17391 + 4: f6 ca 00 00 sub r10,r11,0
17392 + ...
17393 + 8000: fe c0 7f fc sub r0,pc,32764
17394 + 8004: ec f1 00 00 ld.w r1,r6\[0\]
17395 + 8004: R_AVR32_GOT16S toofar_negative
17396 + 8008: ec f2 00 00 ld.w r2,r6\[0\]
17397 + 8008: R_AVR32_GOT16S different_section
17398 + 800c: ec f3 00 00 ld.w r3,r6\[0\]
17399 + 800c: R_AVR32_GOT16S undefined
17400 + 8010: ec f4 00 00 ld.w r4,r6\[0\]
17401 + 8010: R_AVR32_GOT16S toofar_positive
17402 + 8014: fe c5 80 14 sub r5,pc,-32748
17403 + ...
17404 +
17405 +00010000 <far_positive>:
17406 + 10000: fa cc 00 00 sub r12,sp,0
17407 + ...
17408 +00010014 <toofar_positive>:
17409 + 10014: fe ce 00 00 sub lr,pc,0
17410 --- /dev/null
17411 +++ b/gas/testsuite/gas/avr32/lda_pic_linkrelax.d
17412 @@ -0,0 +1,40 @@
17413 +#source: lda.s
17414 +#as: --pic --linkrelax
17415 +#objdump: -dr
17416 +#name: lda_pic_linkrelax
17417 +
17418 +.*: +file format .*
17419 +
17420 +Disassembly of section \.text:
17421 +
17422 +00000000 <lda_test>:
17423 + 0: f2 c8 00 00 sub r8,r9,0
17424 +
17425 +00000004 <far_negative>:
17426 + 4: f6 ca 00 00 sub r10,r11,0
17427 + ...
17428 + 8000: e0 60 00 00 mov r0,0
17429 + 8000: R_AVR32_LDA_GOT far_negative
17430 + 8004: ec 00 03 20 ld\.w r0,r6\[r0<<0x2\]
17431 + 8008: e0 61 00 00 mov r1,0
17432 + 8008: R_AVR32_LDA_GOT toofar_negative
17433 + 800c: ec 01 03 21 ld\.w r1,r6\[r1<<0x2\]
17434 + 8010: e0 62 00 00 mov r2,0
17435 + 8010: R_AVR32_LDA_GOT different_section
17436 + 8014: ec 02 03 22 ld\.w r2,r6\[r2<<0x2\]
17437 + 8018: e0 63 00 00 mov r3,0
17438 + 8018: R_AVR32_LDA_GOT undefined
17439 + 801c: ec 03 03 23 ld\.w r3,r6\[r3<<0x2\]
17440 + 8020: e0 64 00 00 mov r4,0
17441 + 8020: R_AVR32_LDA_GOT toofar_positive
17442 + 8024: ec 04 03 24 ld\.w r4,r6\[r4<<0x2\]
17443 + 8028: e0 65 00 00 mov r5,0
17444 + 8028: R_AVR32_LDA_GOT far_positive
17445 + 802c: ec 05 03 25 ld\.w r5,r6\[r5<<0x2\]
17446 + ...
17447 +
17448 +00010018 <far_positive>:
17449 + 10018: fa cc 00 00 sub r12,sp,0
17450 + ...
17451 +0001002c <toofar_positive>:
17452 + 1002c: fe ce 00 00 sub lr,pc,0
17453 --- /dev/null
17454 +++ b/gas/testsuite/gas/avr32/lda.s
17455 @@ -0,0 +1,30 @@
17456 +
17457 + .text
17458 + .global lda_test
17459 +lda_test:
17460 +toofar_negative:
17461 + sub r8, r9, 0
17462 +far_negative:
17463 + sub r10, r11, 0
17464 +
17465 + .fill 32760, 1, 0x00
17466 +
17467 + lda.w r0, far_negative
17468 + lda.w r1, toofar_negative
17469 + lda.w r2, different_section
17470 + lda.w r3, undefined
17471 + lda.w r4, toofar_positive
17472 + lda.w r5, far_positive
17473 +
17474 + .cpool
17475 +
17476 + .fill 32744, 1, 0x00
17477 +far_positive:
17478 + sub r12, sp, 0
17479 + .fill 16, 1, 0x00
17480 +toofar_positive:
17481 + sub lr, pc, 0
17482 +
17483 + .data
17484 +different_section:
17485 + .long 0x12345678
17486 --- /dev/null
17487 +++ b/gas/testsuite/gas/avr32/pcrel.d
17488 @@ -0,0 +1,64 @@
17489 +#as:
17490 +#objdump: -dr
17491 +#name: pcrel
17492 +
17493 +.*: +file format .*
17494 +
17495 +Disassembly of section \.text:
17496 +
17497 +00000000 <test_rjmp>:
17498 + 0: d7 03 nop
17499 + 2: c0 28 rjmp 6 <test_rjmp\+0x6>
17500 + 4: d7 03 nop
17501 + 6: e0 8f 00 00 bral 6 <test_rjmp\+0x6>
17502 + 6: R_AVR32_22H_PCREL extsym10
17503 +
17504 +0000000a <test_rcall>:
17505 + a: d7 03 nop
17506 +0000000c <test_rcall2>:
17507 + c: c0 2c rcall 10 <test_rcall2\+0x4>
17508 + e: d7 03 nop
17509 + 10: e0 a0 00 00 rcall 10 <test_rcall2\+0x4>
17510 + 10: R_AVR32_22H_PCREL extsym21
17511 +
17512 +00000014 <test_branch>:
17513 + 14: c0 31 brne 1a <test_branch\+0x6>
17514 + 16: e0 8f 00 00 bral 16 <test_branch\+0x2>
17515 + 16: R_AVR32_22H_PCREL test_branch
17516 + 1a: e0 80 00 00 breq 1a <test_branch\+0x6>
17517 + 1a: R_AVR32_22H_PCREL extsym21
17518 +
17519 +0000001e <test_lddpc>:
17520 + 1e: 48 30 lddpc r0,28 <sym1>
17521 + 20: 48 20 lddpc r0,28 <sym1>
17522 + 22: fe f0 00 00 ld.w r0,pc\[0\]
17523 + 22: R_AVR32_16B_PCREL extsym16
17524 + \.\.\.
17525 +
17526 +00000028 <sym1>:
17527 + 28: d7 03 nop
17528 + 2a: d7 03 nop
17529 +
17530 +0000002c <test_local>:
17531 + 2c: 48 20 lddpc r0,34 <test_local\+0x8>
17532 + 2e: 48 30 lddpc r0,38 <test_local\+0xc>
17533 + 30: 48 20 lddpc r0,38 <test_local\+0xc>
17534 + 32: 00 00 add r0,r0
17535 + 34: d7 03 nop
17536 + 36: d7 03 nop
17537 + 38: d7 03 nop
17538 + 3a: d7 03 nop
17539 +
17540 +Disassembly of section \.text\.init:
17541 +
17542 +00000000 <test_inter_section>:
17543 + 0: e0 a0 .. .. rcall [0-9a-f]+ <.*>
17544 + 0: R_AVR32_22H_PCREL test_rcall
17545 + 4: d7 03 nop
17546 + 6: e0 a0 .. .. rcall [0-9a-f]+ <.*>
17547 + 6: R_AVR32_22H_PCREL test_rcall
17548 + a: e0 a0 .. .. rcall [0-9a-z]+ <.*>
17549 + a: R_AVR32_22H_PCREL \.text\+0xc
17550 + e: d7 03 nop
17551 + 10: e0 a0 .. .. rcall [0-9a-f]+ <.*>
17552 + 10: R_AVR32_22H_PCREL \.text\+0xc
17553 --- /dev/null
17554 +++ b/gas/testsuite/gas/avr32/pcrel.s
17555 @@ -0,0 +1,57 @@
17556 +
17557 + .text
17558 + .global test_rjmp
17559 +test_rjmp:
17560 + nop
17561 + rjmp 0f
17562 + nop
17563 +0: rjmp extsym10
17564 +
17565 + .global test_rcall
17566 +test_rcall:
17567 + nop
17568 +test_rcall2:
17569 + rcall 0f
17570 + nop
17571 +0: rcall extsym21
17572 +
17573 + .global test_branch
17574 +test_branch:
17575 + brne 0f
17576 + /* This will generate a reloc since test_branch is global */
17577 + bral test_branch
17578 +0: breq extsym21
17579 +
17580 + .global test_lddpc
17581 +test_lddpc:
17582 + lddpc r0,sym1
17583 + lddpc r0,sym1
17584 + lddpc r0,extsym16
17585 +
17586 + .align 2
17587 +sym1: nop
17588 + nop
17589 +
17590 + .global test_local
17591 +test_local:
17592 + lddpc r0, .LC1
17593 + lddpc r0, .LC2
17594 + lddpc r0, .LC1 + 0x4
17595 +
17596 + .align 2
17597 +.LC1:
17598 + nop
17599 + nop
17600 +.LC2:
17601 + nop
17602 + nop
17603 +
17604 + .section .text.init,"ax"
17605 + .global test_inter_section
17606 +test_inter_section:
17607 + rcall test_rcall
17608 + nop
17609 + rcall test_rcall
17610 + rcall test_rcall2
17611 + nop
17612 + rcall test_rcall2
17613 --- /dev/null
17614 +++ b/gas/testsuite/gas/avr32/pico.d
17615 @@ -0,0 +1,149 @@
17616 +#as:
17617 +#objdump: -dr
17618 +#name: pico
17619 +
17620 +.*: +file format .*
17621 +
17622 +Disassembly of section \.text:
17623 +
17624 +[0-9a-f]* <picosvmac>:
17625 + *[0-9a-f]*: e1 a6 20 00 cop cp1,cr0,cr0,cr0,0xc
17626 + *[0-9a-f]*: e1 a7 2b bb cop cp1,cr11,cr11,cr11,0xe
17627 + *[0-9a-f]*: e1 a6 3a 05 cop cp1,cr10,cr0,cr5,0xd
17628 + *[0-9a-f]*: e1 a7 36 90 cop cp1,cr6,cr9,cr0,0xf
17629 +
17630 +[0-9a-f]* <picosvmul>:
17631 + *[0-9a-f]*: e1 a4 20 00 cop cp1,cr0,cr0,cr0,0x8
17632 + *[0-9a-f]*: e1 a5 2b bb cop cp1,cr11,cr11,cr11,0xa
17633 + *[0-9a-f]*: e1 a4 3a 05 cop cp1,cr10,cr0,cr5,0x9
17634 + *[0-9a-f]*: e1 a5 36 90 cop cp1,cr6,cr9,cr0,0xb
17635 +
17636 +[0-9a-f]* <picovmac>:
17637 + *[0-9a-f]*: e1 a2 20 00 cop cp1,cr0,cr0,cr0,0x4
17638 + *[0-9a-f]*: e1 a3 2b bb cop cp1,cr11,cr11,cr11,0x6
17639 + *[0-9a-f]*: e1 a2 3a 05 cop cp1,cr10,cr0,cr5,0x5
17640 + *[0-9a-f]*: e1 a3 36 90 cop cp1,cr6,cr9,cr0,0x7
17641 +
17642 +[0-9a-f]* <picovmul>:
17643 + *[0-9a-f]*: e1 a0 20 00 cop cp1,cr0,cr0,cr0,0x0
17644 + *[0-9a-f]*: e1 a1 2b bb cop cp1,cr11,cr11,cr11,0x2
17645 + *[0-9a-f]*: e1 a0 3a 05 cop cp1,cr10,cr0,cr5,0x1
17646 + *[0-9a-f]*: e1 a1 36 90 cop cp1,cr6,cr9,cr0,0x3
17647 +
17648 +[0-9a-f]* <picold_d>:
17649 + *[0-9a-f]*: e9 af 3e ff ldc\.d cp1,cr14,pc\[0x3fc\]
17650 + *[0-9a-f]*: e9 a0 30 ff ldc\.d cp1,cr0,r0\[0x3fc\]
17651 + *[0-9a-f]*: e9 a0 30 00 ldc\.d cp1,cr0,r0\[0x0\]
17652 + *[0-9a-f]*: ef a8 26 50 ldc\.d cp1,cr6,--r8
17653 + *[0-9a-f]*: ef a7 28 50 ldc\.d cp1,cr8,--r7
17654 + *[0-9a-f]*: ef aa 32 65 ldc\.d cp1,cr2,r10\[r5<<0x2\]
17655 + *[0-9a-f]*: ef a3 3c 46 ldc\.d cp1,cr12,r3\[r6\]
17656 +
17657 +[0-9a-f]* <picold_w>:
17658 + *[0-9a-f]*: e9 af 2f ff ldc\.w cp1,cr15,pc\[0x3fc\]
17659 + *[0-9a-f]*: e9 a0 20 ff ldc\.w cp1,cr0,r0\[0x3fc\]
17660 + *[0-9a-f]*: e9 a0 20 00 ldc\.w cp1,cr0,r0\[0x0\]
17661 + *[0-9a-f]*: ef a8 27 40 ldc\.w cp1,cr7,--r8
17662 + *[0-9a-f]*: ef a7 28 40 ldc\.w cp1,cr8,--r7
17663 + *[0-9a-f]*: ef aa 31 25 ldc\.w cp1,cr1,r10\[r5<<0x2\]
17664 + *[0-9a-f]*: ef a3 3d 06 ldc\.w cp1,cr13,r3\[r6\]
17665 +
17666 +[0-9a-f]* <picoldm_d>:
17667 + *[0-9a-f]*: ed af 24 ff ldcm\.d cp1,pc,cr0-cr15
17668 + *[0-9a-f]*: ed a0 24 01 ldcm\.d cp1,r0,cr0-cr1
17669 + *[0-9a-f]*: ed a7 24 80 ldcm\.d cp1,r7,cr14-cr15
17670 + *[0-9a-f]*: ed a8 24 7f ldcm\.d cp1,r8,cr0-cr13
17671 +
17672 +[0-9a-f]* <picoldm_d_pu>:
17673 + *[0-9a-f]*: ed af 34 ff ldcm\.d cp1,pc\+\+,cr0-cr15
17674 + *[0-9a-f]*: ed a0 34 01 ldcm\.d cp1,r0\+\+,cr0-cr1
17675 + *[0-9a-f]*: ed a7 34 80 ldcm\.d cp1,r7\+\+,cr14-cr15
17676 + *[0-9a-f]*: ed a8 34 7f ldcm\.d cp1,r8\+\+,cr0-cr13
17677 +
17678 +[0-9a-f]* <picoldm_w>:
17679 + *[0-9a-f]*: ed af 20 ff ldcm\.w cp1,pc,cr0-cr7
17680 + *[0-9a-f]*: ed a0 20 01 ldcm\.w cp1,r0,cr0
17681 + *[0-9a-f]*: ed a7 20 80 ldcm\.w cp1,r7,cr7
17682 + *[0-9a-f]*: ed a8 20 7f ldcm\.w cp1,r8,cr0-cr6
17683 + *[0-9a-f]*: ed af 21 ff ldcm\.w cp1,pc,cr8-cr15
17684 + *[0-9a-f]*: ed a0 21 01 ldcm\.w cp1,r0,cr8
17685 + *[0-9a-f]*: ed a7 21 80 ldcm\.w cp1,r7,cr15
17686 + *[0-9a-f]*: ed a8 21 7f ldcm\.w cp1,r8,cr8-cr14
17687 +
17688 +[0-9a-f]* <picoldm_w_pu>:
17689 + *[0-9a-f]*: ed af 30 ff ldcm\.w cp1,pc\+\+,cr0-cr7
17690 + *[0-9a-f]*: ed a0 30 01 ldcm\.w cp1,r0\+\+,cr0
17691 + *[0-9a-f]*: ed a7 30 80 ldcm\.w cp1,r7\+\+,cr7
17692 + *[0-9a-f]*: ed a8 30 7f ldcm\.w cp1,r8\+\+,cr0-cr6
17693 + *[0-9a-f]*: ed af 31 ff ldcm\.w cp1,pc\+\+,cr8-cr15
17694 + *[0-9a-f]*: ed a0 31 01 ldcm\.w cp1,r0\+\+,cr8
17695 + *[0-9a-f]*: ed a7 31 80 ldcm\.w cp1,r7\+\+,cr15
17696 + *[0-9a-f]*: ed a8 31 7f ldcm\.w cp1,r8\+\+,cr8-cr14
17697 +
17698 +[0-9a-f]* <picomv_d>:
17699 + *[0-9a-f]*: ef ae 2e 30 mvrc\.d cp1,cr14,lr
17700 + *[0-9a-f]*: ef a0 20 30 mvrc\.d cp1,cr0,r0
17701 + *[0-9a-f]*: ef a8 26 30 mvrc\.d cp1,cr6,r8
17702 + *[0-9a-f]*: ef a6 28 30 mvrc\.d cp1,cr8,r6
17703 + *[0-9a-f]*: ef ae 2e 10 mvcr\.d cp1,lr,cr14
17704 + *[0-9a-f]*: ef a0 20 10 mvcr\.d cp1,r0,cr0
17705 + *[0-9a-f]*: ef a8 26 10 mvcr\.d cp1,r8,cr6
17706 + *[0-9a-f]*: ef a6 28 10 mvcr\.d cp1,r6,cr8
17707 +
17708 +[0-9a-f]* <picomv_w>:
17709 + *[0-9a-f]*: ef af 2f 20 mvrc\.w cp1,cr15,pc
17710 + *[0-9a-f]*: ef a0 20 20 mvrc\.w cp1,cr0,r0
17711 + *[0-9a-f]*: ef a8 27 20 mvrc\.w cp1,cr7,r8
17712 + *[0-9a-f]*: ef a7 28 20 mvrc\.w cp1,cr8,r7
17713 + *[0-9a-f]*: ef af 2f 00 mvcr\.w cp1,pc,cr15
17714 + *[0-9a-f]*: ef a0 20 00 mvcr\.w cp1,r0,cr0
17715 + *[0-9a-f]*: ef a8 27 00 mvcr\.w cp1,r8,cr7
17716 + *[0-9a-f]*: ef a7 28 00 mvcr\.w cp1,r7,cr8
17717 +
17718 +[0-9a-f]* <picost_d>:
17719 + *[0-9a-f]*: eb af 3e ff stc\.d cp1,pc\[0x3fc\],cr14
17720 + *[0-9a-f]*: eb a0 30 00 stc\.d cp1,r0\[0x0\],cr0
17721 + *[0-9a-f]*: ef a8 26 70 stc\.d cp1,r8\+\+,cr6
17722 + *[0-9a-f]*: ef a7 28 70 stc\.d cp1,r7\+\+,cr8
17723 + *[0-9a-f]*: ef aa 32 e5 stc\.d cp1,r10\[r5<<0x2\],cr2
17724 + *[0-9a-f]*: ef a3 3c c6 stc\.d cp1,r3\[r6\],cr12
17725 +
17726 +[0-9a-f]* <picost_w>:
17727 + *[0-9a-f]*: eb af 2f ff stc\.w cp1,pc\[0x3fc\],cr15
17728 + *[0-9a-f]*: eb a0 20 00 stc\.w cp1,r0\[0x0\],cr0
17729 + *[0-9a-f]*: ef a8 27 60 stc\.w cp1,r8\+\+,cr7
17730 + *[0-9a-f]*: ef a7 28 60 stc\.w cp1,r7\+\+,cr8
17731 + *[0-9a-f]*: ef aa 31 a5 stc\.w cp1,r10\[r5<<0x2\],cr1
17732 + *[0-9a-f]*: ef a3 3d 86 stc\.w cp1,r3\[r6\],cr13
17733 +
17734 +[0-9a-f]* <picostm_d>:
17735 + *[0-9a-f]*: ed af 25 ff stcm\.d cp1,pc,cr0-cr15
17736 + *[0-9a-f]*: ed a0 25 01 stcm\.d cp1,r0,cr0-cr1
17737 + *[0-9a-f]*: ed a7 25 80 stcm\.d cp1,r7,cr14-cr15
17738 + *[0-9a-f]*: ed a8 25 7f stcm\.d cp1,r8,cr0-cr13
17739 +
17740 +[0-9a-f]* <picostm_d_pu>:
17741 + *[0-9a-f]*: ed af 35 ff stcm\.d cp1,--pc,cr0-cr15
17742 + *[0-9a-f]*: ed a0 35 01 stcm\.d cp1,--r0,cr0-cr1
17743 + *[0-9a-f]*: ed a7 35 80 stcm\.d cp1,--r7,cr14-cr15
17744 + *[0-9a-f]*: ed a8 35 7f stcm\.d cp1,--r8,cr0-cr13
17745 +
17746 +[0-9a-f]* <picostm_w>:
17747 + *[0-9a-f]*: ed af 22 ff stcm\.w cp1,pc,cr0-cr7
17748 + *[0-9a-f]*: ed a0 22 01 stcm\.w cp1,r0,cr0
17749 + *[0-9a-f]*: ed a7 22 80 stcm\.w cp1,r7,cr7
17750 + *[0-9a-f]*: ed a8 22 7f stcm\.w cp1,r8,cr0-cr6
17751 + *[0-9a-f]*: ed af 23 ff stcm\.w cp1,pc,cr8-cr15
17752 + *[0-9a-f]*: ed a0 23 01 stcm\.w cp1,r0,cr8
17753 + *[0-9a-f]*: ed a7 23 80 stcm\.w cp1,r7,cr15
17754 + *[0-9a-f]*: ed a8 23 7f stcm\.w cp1,r8,cr8-cr14
17755 +
17756 +[0-9a-f]* <picostm_w_pu>:
17757 + *[0-9a-f]*: ed af 32 ff stcm\.w cp1,--pc,cr0-cr7
17758 + *[0-9a-f]*: ed a0 32 01 stcm\.w cp1,--r0,cr0
17759 + *[0-9a-f]*: ed a7 32 80 stcm\.w cp1,--r7,cr7
17760 + *[0-9a-f]*: ed a8 32 7f stcm\.w cp1,--r8,cr0-cr6
17761 + *[0-9a-f]*: ed af 33 ff stcm\.w cp1,--pc,cr8-cr15
17762 + *[0-9a-f]*: ed a0 33 01 stcm\.w cp1,--r0,cr8
17763 + *[0-9a-f]*: ed a7 33 80 stcm\.w cp1,--r7,cr15
17764 + *[0-9a-f]*: ed a8 33 7f stcm\.w cp1,--r8,cr8-cr14
17765 --- /dev/null
17766 +++ b/gas/testsuite/gas/avr32/pico.s
17767 @@ -0,0 +1,144 @@
17768 +
17769 + .text
17770 + .global picosvmac
17771 +picosvmac:
17772 + picosvmac out0, in0, in0, in0
17773 + picosvmac out2, in11, in11, in11
17774 + picosvmac out1, in10, in0, in5
17775 + picosvmac out3, in6, in9, in0
17776 + .global picosvmul
17777 +picosvmul:
17778 + picosvmul out0, in0, in0, in0
17779 + picosvmul out2, in11, in11, in11
17780 + picosvmul out1, in10, in0, in5
17781 + picosvmul out3, in6, in9, in0
17782 + .global picovmac
17783 +picovmac:
17784 + picovmac out0, in0, in0, in0
17785 + picovmac out2, in11, in11, in11
17786 + picovmac out1, in10, in0, in5
17787 + picovmac out3, in6, in9, in0
17788 + .global picovmul
17789 +picovmul:
17790 + picovmul out0, in0, in0, in0
17791 + picovmul out2, in11, in11, in11
17792 + picovmul out1, in10, in0, in5
17793 + picovmul out3, in6, in9, in0
17794 + .global picold_d
17795 +picold_d:
17796 + picold.d vmu2_out, pc[1020]
17797 + picold.d inpix2, r0[1020]
17798 + picold.d inpix2, r0[0]
17799 + picold.d coeff0_a, --r8
17800 + picold.d coeff1_a, --r7
17801 + picold.d inpix0, r10[r5 << 2]
17802 + picold.d vmu0_out, r3[r6 << 0]
17803 + .global picold_w
17804 +picold_w:
17805 + picold.w config, pc[1020]
17806 + picold.w inpix2, r0[1020]
17807 + picold.w inpix2, r0[0]
17808 + picold.w coeff0_b, --r8
17809 + picold.w coeff1_a, --r7
17810 + picold.w inpix1, r10[r5 << 2]
17811 + picold.w vmu1_out, r3[r6 << 0]
17812 + .global picoldm_d
17813 +picoldm_d:
17814 + picoldm.d pc, inpix2-config
17815 + picoldm.d r0, inpix2, inpix1
17816 + picoldm.d r7, vmu2_out, config
17817 + picoldm.d r8, inpix2-vmu1_out
17818 + .global picoldm_d_pu
17819 +picoldm_d_pu:
17820 + picoldm.d pc++, inpix2, inpix1, inpix0, outpix2, outpix1, outpix0, coeff0_a, coeff0_b, coeff1_a, coeff1_b, coeff2_a, coeff2_b, vmu0_out, vmu1_out, vmu2_out, config
17821 + picoldm.d r0++, inpix2, inpix1
17822 + picoldm.d r7++, vmu2_out, config
17823 + picoldm.d r8++, inpix2, inpix1, inpix0, outpix2, outpix1, outpix0, coeff0_a, coeff0_b, coeff1_a, coeff1_b, coeff2_a, coeff2_b, vmu0_out, vmu1_out
17824 + .global picoldm_w
17825 +picoldm_w:
17826 + picoldm.w pc, inpix2-coeff0_b
17827 + picoldm.w r0, inpix2
17828 + picoldm.w r7, coeff0_b
17829 + picoldm.w r8, inpix2-coeff0_a
17830 + picoldm.w pc, coeff1_a-config
17831 + picoldm.w r0, coeff1_a
17832 + picoldm.w r7, config
17833 + picoldm.w r8, coeff1_a-vmu2_out
17834 + .global picoldm_w_pu
17835 +picoldm_w_pu:
17836 + picoldm.w pc++, inpix2-coeff0_b
17837 + picoldm.w r0++, inpix2
17838 + picoldm.w r7++, coeff0_b
17839 + picoldm.w r8++, inpix2-coeff0_a
17840 + picoldm.w pc++, coeff1_a-config
17841 + picoldm.w r0++, coeff1_a
17842 + picoldm.w r7++, config
17843 + picoldm.w r8++, coeff1_a-vmu2_out
17844 + .global picomv_d
17845 +picomv_d:
17846 + picomv.d vmu2_out, lr
17847 + picomv.d inpix2, r0
17848 + picomv.d coeff0_a, r8
17849 + picomv.d coeff1_a, r6
17850 + picomv.d pc, vmu2_out
17851 + picomv.d r0, inpix2
17852 + picomv.d r8, coeff0_a
17853 + picomv.d r6, coeff1_a
17854 + .global picomv_w
17855 +picomv_w:
17856 + picomv.w config, pc
17857 + picomv.w inpix2, r0
17858 + picomv.w coeff0_b, r8
17859 + picomv.w coeff1_a, r7
17860 + picomv.w pc, config
17861 + picomv.w r0, inpix2
17862 + picomv.w r8, coeff0_b
17863 + picomv.w r7, coeff1_a
17864 + .global picost_d
17865 +picost_d:
17866 + picost.d pc[1020], vmu2_out
17867 + picost.d r0[0], inpix2
17868 + picost.d r8++, coeff0_a
17869 + picost.d r7++, coeff1_a
17870 + picost.d r10[r5 << 2], inpix0
17871 + picost.d r3[r6 << 0], vmu0_out
17872 + .global picost_w
17873 +picost_w:
17874 + picost.w pc[1020], config
17875 + picost.w r0[0], inpix2
17876 + picost.w r8++, coeff0_b
17877 + picost.w r7++, coeff1_a
17878 + picost.w r10[r5 << 2], inpix1
17879 + picost.w r3[r6 << 0], vmu1_out
17880 + .global picostm_d
17881 +picostm_d:
17882 + picostm.d pc, inpix2-config
17883 + picostm.d r0, inpix2, inpix1
17884 + picostm.d r7, vmu2_out, config
17885 + picostm.d r8, inpix2-vmu1_out
17886 + .global picostm_d_pu
17887 +picostm_d_pu:
17888 + picostm.d --pc, inpix2, inpix1, inpix0, outpix2, outpix1, outpix0, coeff0_a, coeff0_b, coeff1_a, coeff1_b, coeff2_a, coeff2_b, vmu0_out, vmu1_out, vmu2_out, config
17889 + picostm.d --r0, inpix2, inpix1
17890 + picostm.d --r7, vmu2_out, config
17891 + picostm.d --r8, inpix2, inpix1, inpix0, outpix2, outpix1, outpix0, coeff0_a, coeff0_b, coeff1_a, coeff1_b, coeff2_a, coeff2_b, vmu0_out, vmu1_out
17892 + .global picostm_w
17893 +picostm_w:
17894 + picostm.w pc, inpix2-coeff0_b
17895 + picostm.w r0, inpix2
17896 + picostm.w r7, coeff0_b
17897 + picostm.w r8, inpix2-coeff0_a
17898 + picostm.w pc, coeff1_a-config
17899 + picostm.w r0, coeff1_a
17900 + picostm.w r7, config
17901 + picostm.w r8, coeff1_a-vmu2_out
17902 + .global picostm_w_pu
17903 +picostm_w_pu:
17904 + picostm.w --pc, inpix2-coeff0_b
17905 + picostm.w --r0, inpix2
17906 + picostm.w --r7, coeff0_b
17907 + picostm.w --r8, inpix2-coeff0_a
17908 + picostm.w --pc, coeff1_a-config
17909 + picostm.w --r0, coeff1_a
17910 + picostm.w --r7, config
17911 + picostm.w --r8, coeff1_a-vmu2_out
17912 --- /dev/null
17913 +++ b/gas/testsuite/gas/avr32/pic_reloc.d
17914 @@ -0,0 +1,27 @@
17915 +#as:
17916 +#objdump: -dr
17917 +#name: pic_reloc
17918 +
17919 +.*: +file format .*
17920 +
17921 +Disassembly of section \.text:
17922 +
17923 +00000000 <mcall_got>:
17924 + 0: f0 16 00 00 mcall r6\[0\]
17925 + 0: R_AVR32_GOT18SW extfunc
17926 + 4: f0 16 00 00 mcall r6\[0\]
17927 + 4: R_AVR32_GOT18SW \.L1
17928 + 8: f0 16 00 00 mcall r6\[0\]
17929 + 8: R_AVR32_GOT18SW \.L2
17930 + c: f0 16 00 00 mcall r6\[0\]
17931 + c: R_AVR32_GOT18SW mcall_got
17932 +
17933 +00000010 <ldw_got>:
17934 + 10: ec f0 00 00 ld.w r0,r6\[0\]
17935 + 10: R_AVR32_GOT16S extvar
17936 + 14: ec f0 00 00 ld.w r0,r6\[0\]
17937 + 14: R_AVR32_GOT16S \.L3
17938 + 18: ec f0 00 00 ld.w r0,r6\[0\]
17939 + 18: R_AVR32_GOT16S \.L4
17940 + 1c: ec f0 00 00 ld.w r0,r6\[0\]
17941 + 1c: R_AVR32_GOT16S ldw_got
17942 --- /dev/null
17943 +++ b/gas/testsuite/gas/avr32/pic_reloc.s
17944 @@ -0,0 +1,18 @@
17945 +
17946 + .text
17947 + .global mcall_got
17948 +mcall_got:
17949 +.L1:
17950 + mcall r6[extfunc@got]
17951 + mcall r6[.L1@got]
17952 + mcall r6[.L2@got]
17953 + mcall r6[mcall_got@got]
17954 +.L2:
17955 +
17956 + .global ldw_got
17957 +ldw_got:
17958 +.L3: ld.w r0,r6[extvar@got]
17959 + ld.w r0,r6[.L3@got]
17960 + ld.w r0,r6[.L4@got]
17961 + ld.w r0,r6[ldw_got@got]
17962 +.L4:
17963 --- /dev/null
17964 +++ b/gas/testsuite/gas/avr32/symdiff.d
17965 @@ -0,0 +1,24 @@
17966 +#source: symdiff.s
17967 +#as:
17968 +#objdump: -dr
17969 +#name: symdiff
17970 +
17971 +.*: +file format .*
17972 +
17973 +Disassembly of section \.text:
17974 +
17975 +00000000 <diff32>:
17976 + 0: 00 00 add r0,r0
17977 + 2: 00 04 add r4,r0
17978 +
17979 +00000004 <diff16>:
17980 + 4: 00 04 add r4,r0
17981 +
17982 +00000006 <diff8>:
17983 + 6: 04 00 add r0,r2
17984 +
17985 +00000008 <symdiff_test>:
17986 + 8: d7 03 nop
17987 + a: d7 03 nop
17988 + c: d7 03 nop
17989 + e: d7 03 nop
17990 --- /dev/null
17991 +++ b/gas/testsuite/gas/avr32/symdiff_linkrelax.d
17992 @@ -0,0 +1,28 @@
17993 +#source: symdiff.s
17994 +#as: --linkrelax
17995 +#objdump: -dr
17996 +#name: symdiff_linkrelax
17997 +
17998 +.*: +file format .*
17999 +
18000 +Disassembly of section \.text:
18001 +
18002 +00000000 <diff32>:
18003 + 0: 00 00 add r0,r0
18004 + 0: R_AVR32_DIFF32 \.text\+0xa
18005 + 2: 00 04 add r4,r0
18006 +
18007 +00000004 <diff16>:
18008 + 4: 00 04 add r4,r0
18009 + 4: R_AVR32_DIFF16 \.text\+0xa
18010 +
18011 +00000006 <diff8>:
18012 + 6: 04 00 add r0,r2
18013 + 6: R_AVR32_DIFF8 \.text\+0xa
18014 + 7: R_AVR32_ALIGN \*ABS\*\+0x1
18015 +
18016 +00000008 <symdiff_test>:
18017 + 8: d7 03 nop
18018 + a: d7 03 nop
18019 + c: d7 03 nop
18020 + e: d7 03 nop
18021 --- /dev/null
18022 +++ b/gas/testsuite/gas/avr32/symdiff.s
18023 @@ -0,0 +1,19 @@
18024 +
18025 + .text
18026 + .global diff32
18027 +diff32:
18028 + .long .L2 - .L1
18029 + .global diff16
18030 +diff16:
18031 + .short .L2 - .L1
18032 + .global diff8
18033 +diff8:
18034 + .byte .L2 - .L1
18035 +
18036 + .global symdiff_test
18037 + .align 1
18038 +symdiff_test:
18039 + nop
18040 +.L1: nop
18041 + nop
18042 +.L2: nop
18043 --- a/gas/write.c
18044 +++ b/gas/write.c
18045 @@ -1955,6 +1955,10 @@ relax_frag (segT segment, fragS *fragP,
18046
18047 #endif /* defined (TC_GENERIC_RELAX_TABLE) */
18048
18049 +#ifdef TC_RELAX_ALIGN
18050 +#define RELAX_ALIGN(SEG, FRAG, ADDR) TC_RELAX_ALIGN(SEG, FRAG, ADDR)
18051 +#else
18052 +#define RELAX_ALIGN(SEG, FRAG, ADDR) relax_align(ADDR, (FRAG)->fr_offset)
18053 /* Relax_align. Advance location counter to next address that has 'alignment'
18054 lowest order bits all 0s, return size of adjustment made. */
18055 static relax_addressT
18056 @@ -1974,6 +1978,7 @@ relax_align (register relax_addressT add
18057 #endif
18058 return (new_address - address);
18059 }
18060 +#endif
18061
18062 /* Now we have a segment, not a crowd of sub-segments, we can make
18063 fr_address values.
18064 @@ -2017,7 +2022,7 @@ relax_segment (struct frag *segment_frag
18065 case rs_align_code:
18066 case rs_align_test:
18067 {
18068 - addressT offset = relax_align (address, (int) fragP->fr_offset);
18069 + addressT offset = RELAX_ALIGN(segment, fragP, address);
18070
18071 if (fragP->fr_subtype != 0 && offset > fragP->fr_subtype)
18072 offset = 0;
18073 @@ -2218,10 +2223,10 @@ relax_segment (struct frag *segment_frag
18074 {
18075 addressT oldoff, newoff;
18076
18077 - oldoff = relax_align (was_address + fragP->fr_fix,
18078 - (int) offset);
18079 - newoff = relax_align (address + fragP->fr_fix,
18080 - (int) offset);
18081 + oldoff = RELAX_ALIGN (segment, fragP,
18082 + was_address + fragP->fr_fix);
18083 + newoff = RELAX_ALIGN (segment, fragP,
18084 + address + fragP->fr_fix);
18085
18086 if (fragP->fr_subtype != 0)
18087 {
18088 --- a/include/dis-asm.h
18089 +++ b/include/dis-asm.h
18090 @@ -204,13 +204,14 @@ typedef struct disassemble_info
18091
18092 } disassemble_info;
18093
18094 -\f
18095 +
18096 /* Standard disassemblers. Disassemble one instruction at the given
18097 target address. Return number of octets processed. */
18098 typedef int (*disassembler_ftype) (bfd_vma, disassemble_info *);
18099
18100 extern int print_insn_alpha (bfd_vma, disassemble_info *);
18101 extern int print_insn_avr (bfd_vma, disassemble_info *);
18102 +extern int print_insn_avr32 (bfd_vma, disassemble_info *);
18103 extern int print_insn_bfin (bfd_vma, disassemble_info *);
18104 extern int print_insn_big_arm (bfd_vma, disassemble_info *);
18105 extern int print_insn_big_mips (bfd_vma, disassemble_info *);
18106 @@ -290,7 +291,9 @@ extern void print_i386_disassembler_opti
18107 extern void print_mips_disassembler_options (FILE *);
18108 extern void print_ppc_disassembler_options (FILE *);
18109 extern void print_arm_disassembler_options (FILE *);
18110 +extern void print_avr32_disassembler_options (FILE *);
18111 extern void parse_arm_disassembler_option (char *);
18112 +extern void parse_avr32_disassembler_option (char *);
18113 extern int get_arm_regname_num_options (void);
18114 extern int set_arm_regname_option (int);
18115 extern int get_arm_regnames (int, const char **, const char **, const char *const **);
18116 @@ -306,7 +309,7 @@ extern void disassemble_init_for_target
18117 /* Document any target specific options available from the disassembler. */
18118 extern void disassembler_usage (FILE *);
18119
18120 -\f
18121 +
18122 /* This block of definitions is for particular callers who read instructions
18123 into a buffer before calling the instruction decoder. */
18124
18125 --- /dev/null
18126 +++ b/include/elf/avr32.h
18127 @@ -0,0 +1,98 @@
18128 +/* AVR32 ELF support for BFD.
18129 + Copyright 2003-2006 Atmel Corporation.
18130 +
18131 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
18132 +
18133 + This file is part of BFD, the Binary File Descriptor library.
18134 +
18135 + This program is free software; you can redistribute it and/or
18136 + modify it under the terms of the GNU General Public License as
18137 + published by the Free Software Foundation; either version 2 of the
18138 + License, or (at your option) any later version.
18139 +
18140 + This program is distributed in the hope that it will be useful, but
18141 + WITHOUT ANY WARRANTY; without even the implied warranty of
18142 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18143 + General Public License for more details.
18144 +
18145 + You should have received a copy of the GNU General Public License
18146 + along with this program; if not, write to the Free Software
18147 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
18148 + 02111-1307, USA. */
18149 +
18150 +#include "elf/reloc-macros.h"
18151 +
18152 +/* CPU-specific flags for the ELF header e_flags field */
18153 +#define EF_AVR32_LINKRELAX 0x01
18154 +#define EF_AVR32_PIC 0x02
18155 +
18156 +START_RELOC_NUMBERS (elf_avr32_reloc_type)
18157 + RELOC_NUMBER (R_AVR32_NONE, 0)
18158 +
18159 + /* Data Relocations */
18160 + RELOC_NUMBER (R_AVR32_32, 1)
18161 + RELOC_NUMBER (R_AVR32_16, 2)
18162 + RELOC_NUMBER (R_AVR32_8, 3)
18163 + RELOC_NUMBER (R_AVR32_32_PCREL, 4)
18164 + RELOC_NUMBER (R_AVR32_16_PCREL, 5)
18165 + RELOC_NUMBER (R_AVR32_8_PCREL, 6)
18166 + RELOC_NUMBER (R_AVR32_DIFF32, 7)
18167 + RELOC_NUMBER (R_AVR32_DIFF16, 8)
18168 + RELOC_NUMBER (R_AVR32_DIFF8, 9)
18169 + RELOC_NUMBER (R_AVR32_GOT32, 10)
18170 + RELOC_NUMBER (R_AVR32_GOT16, 11)
18171 + RELOC_NUMBER (R_AVR32_GOT8, 12)
18172 +
18173 + /* Normal Code Relocations */
18174 + RELOC_NUMBER (R_AVR32_21S, 13)
18175 + RELOC_NUMBER (R_AVR32_16U, 14)
18176 + RELOC_NUMBER (R_AVR32_16S, 15)
18177 + RELOC_NUMBER (R_AVR32_8S, 16)
18178 + RELOC_NUMBER (R_AVR32_8S_EXT, 17)
18179 +
18180 + /* PC-Relative Code Relocations */
18181 + RELOC_NUMBER (R_AVR32_22H_PCREL, 18)
18182 + RELOC_NUMBER (R_AVR32_18W_PCREL, 19)
18183 + RELOC_NUMBER (R_AVR32_16B_PCREL, 20)
18184 + RELOC_NUMBER (R_AVR32_16N_PCREL, 21)
18185 + RELOC_NUMBER (R_AVR32_14UW_PCREL, 22)
18186 + RELOC_NUMBER (R_AVR32_11H_PCREL, 23)
18187 + RELOC_NUMBER (R_AVR32_10UW_PCREL, 24)
18188 + RELOC_NUMBER (R_AVR32_9H_PCREL, 25)
18189 + RELOC_NUMBER (R_AVR32_9UW_PCREL, 26)
18190 +
18191 + /* Special Code Relocations */
18192 + RELOC_NUMBER (R_AVR32_HI16, 27)
18193 + RELOC_NUMBER (R_AVR32_LO16, 28)
18194 +
18195 + /* PIC Relocations */
18196 + RELOC_NUMBER (R_AVR32_GOTPC, 29)
18197 + RELOC_NUMBER (R_AVR32_GOTCALL, 30)
18198 + RELOC_NUMBER (R_AVR32_LDA_GOT, 31)
18199 + RELOC_NUMBER (R_AVR32_GOT21S, 32)
18200 + RELOC_NUMBER (R_AVR32_GOT18SW, 33)
18201 + RELOC_NUMBER (R_AVR32_GOT16S, 34)
18202 + RELOC_NUMBER (R_AVR32_GOT7UW, 35)
18203 +
18204 + /* Constant Pool Relocations */
18205 + RELOC_NUMBER (R_AVR32_32_CPENT, 36)
18206 + RELOC_NUMBER (R_AVR32_CPCALL, 37)
18207 + RELOC_NUMBER (R_AVR32_16_CP, 38)
18208 + RELOC_NUMBER (R_AVR32_9W_CP, 39)
18209 +
18210 + /* Dynamic Relocations */
18211 + RELOC_NUMBER (R_AVR32_RELATIVE, 40)
18212 + RELOC_NUMBER (R_AVR32_GLOB_DAT, 41)
18213 + RELOC_NUMBER (R_AVR32_JMP_SLOT, 42)
18214 +
18215 + /* Linkrelax Information */
18216 + RELOC_NUMBER (R_AVR32_ALIGN, 43)
18217 +
18218 + RELOC_NUMBER (R_AVR32_15S, 44)
18219 +
18220 +END_RELOC_NUMBERS (R_AVR32_max)
18221 +
18222 +/* Processor specific dynamic array tags. */
18223 +
18224 +/* The total size in bytes of the Global Offset Table */
18225 +#define DT_AVR32_GOTSZ 0x70000001
18226 --- a/include/elf/common.h
18227 +++ b/include/elf/common.h
18228 @@ -259,6 +259,9 @@
18229 /* V850 backend magic number. Written in the absense of an ABI. */
18230 #define EM_CYGNUS_V850 0x9080
18231
18232 +/* AVR32 magic number, picked by IAR Systems. */
18233 +#define EM_AVR32 0x18ad
18234 +
18235 /* old S/390 backend magic number. Written in the absence of an ABI. */
18236 #define EM_S390_OLD 0xa390
18237
18238 --- a/ld/configdoc.texi
18239 +++ b/ld/configdoc.texi
18240 @@ -7,6 +7,7 @@
18241 @set H8300
18242 @set HPPA
18243 @set I960
18244 +@set AVR32
18245 @set M68HC11
18246 @set MMIX
18247 @set MSP430
18248 --- a/ld/configure.tgt
18249 +++ b/ld/configure.tgt
18250 @@ -109,6 +109,9 @@ xscale-*-elf) targ_emul=armelf
18251 avr-*-*) targ_emul=avr2
18252 targ_extra_emuls="avr1 avr3 avr4 avr5 avr6"
18253 ;;
18254 +avr32-*-none) targ_emul=avr32elf_ap7000
18255 + targ_extra_emuls="avr32elf_ap7001 avr32elf_ap7002 avr32elf_ap7200 avr32elf_uc3a0128 avr32elf_uc3a0256 avr32elf_uc3a0512 avr32elf_uc3a0512es avr32elf_uc3a1128 avr32elf_uc3a1256 avr32elf_uc3a1512es avr32elf_uc3a1512 avr32elf_uc3a364 avr32elf_uc3a364s avr32elf_uc3a3128 avr32elf_uc3a3128s avr32elf_uc3a3256 avr32elf_uc3a3256s avr32elf_uc3b064 avr32elf_uc3b0128 avr32elf_uc3b0256es avr32elf_uc3b0256 avr32elf_uc3b164 avr32elf_uc3b1128 avr32elf_uc3b1256es avr32elf_uc3b1256" ;;
18256 +avr32-*-linux*) targ_emul=avr32linux ;;
18257 bfin-*-elf) targ_emul=elf32bfin;
18258 targ_extra_emuls="elf32bfinfd"
18259 targ_extra_libpath=$targ_extra_emuls
18260 --- /dev/null
18261 +++ b/ld/emulparams/avr32elf.sh
18262 @@ -0,0 +1,163 @@
18263 +# This script is called from ld/genscript.sh
18264 +# There is a difference on how 'bash' and POSIX handles
18265 +# the '.' (source) command in a script.
18266 +# genscript.sh calls this script with argument ${EMULATION_NAME}
18267 +# but that will fail on POSIX compilant shells like 'sh' or 'dash'
18268 +# therefor I use the variable directly instead of $1
18269 +EMULATION=${EMULATION_NAME}
18270 +SCRIPT_NAME=elf_xip
18271 +TEMPLATE_NAME=elf32
18272 +EXTRA_EM_FILE=avr32elf
18273 +OUTPUT_FORMAT="elf32-avr32"
18274 +ARCH=avr32
18275 +MAXPAGESIZE=4096
18276 +ENTRY=_start
18277 +EMBEDDED=yes
18278 +NO_SMALL_DATA=yes
18279 +NOP=0xd703d703
18280 +
18281 +DATA_SEGMENT_ALIGN=8
18282 +BSS_ALIGNMENT=8
18283 +
18284 +RO_LMA_REGION="FLASH"
18285 +RO_VMA_REGION="FLASH"
18286 +RW_LMA_REGION="FLASH"
18287 +RW_VMA_REGION="CPUSRAM"
18288 +
18289 +STACK_SIZE=0x1000
18290 +STACK_ADDR="ORIGIN(CPUSRAM) + LENGTH(CPUSRAM) - ${STACK_SIZE}"
18291 +
18292 +DATA_SEGMENT_END="__heap_start__ = ALIGN(8);
18293 + . = ${STACK_ADDR};
18294 + __heap_end__ = .;"
18295 +
18296 +case "$EMULATION" in
18297 +avr32elf_ap*)
18298 + MACHINE=ap
18299 + INITIAL_READONLY_SECTIONS=".reset : { *(.reset) } >FLASH AT>FLASH
18300 + . = . & 0x9fffffff;"
18301 + TEXT_START_ADDR=0xa0000000
18302 + case "$EMULATION" in
18303 + avr32elf_ap700[0-2])
18304 + MEMORY="MEMORY
18305 + {
18306 + FLASH (rxai) : ORIGIN = 0x00000000, LENGTH = 64M
18307 + CPUSRAM (rwxa) : ORIGIN = 0x24000000, LENGTH = 32K
18308 + }"
18309 + ;;
18310 + avr32elf_ap7200)
18311 + MEMORY="MEMORY
18312 + {
18313 + FLASH (rxai) : ORIGIN = 0x00000000, LENGTH = 64M
18314 + CPUSRAM (rwxa) : ORIGIN = 0x08000000, LENGTH = 64K
18315 + }"
18316 + ;;
18317 + esac
18318 + ;;
18319 +
18320 +avr32elf_uc3*)
18321 + MACHINE=uc
18322 + INITIAL_READONLY_SECTIONS=".reset : { *(.reset) } >FLASH AT>FLASH"
18323 + TEXT_START_ADDR=0x80000000
18324 + OTHER_SECTIONS=".userpage : { *(.userpage .userpage.*) } >USERPAGE AT>USERPAGE
18325 + .factorypage : { *(.factorypage .factorypage.*) } >FACTORYPAGE AT>FACTORYPAGE"
18326 +
18327 + case "$EMULATION" in
18328 + avr32elf_uc3a[01]512*)
18329 + MEMORY="MEMORY
18330 + {
18331 + FLASH (rxai!w) : ORIGIN = 0x80000000, LENGTH = 512K
18332 + CPUSRAM (wxa!ri) : ORIGIN = 0x00000000, LENGTH = 64K
18333 + USERPAGE : ORIGIN = 0x80800000, LENGTH = 512
18334 + FACTORYPAGE : ORIGIN = 0x80800200, LENGTH = 512
18335 + }"
18336 + ;;
18337 +
18338 + avr32elf_uc3a[01]256)
18339 + MEMORY="MEMORY
18340 + {
18341 + FLASH (rxai!w) : ORIGIN = 0x80000000, LENGTH = 256K
18342 + CPUSRAM (wxa!ri) : ORIGIN = 0x00000000, LENGTH = 64K
18343 + USERPAGE : ORIGIN = 0x80800000, LENGTH = 512
18344 + FACTORYPAGE : ORIGIN = 0x80800200, LENGTH = 512
18345 + }"
18346 + ;;
18347 +
18348 + avr32elf_uc3b[01]256*)
18349 + MEMORY="MEMORY
18350 + {
18351 + FLASH (rxai!w) : ORIGIN = 0x80000000, LENGTH = 256K
18352 + CPUSRAM (wxa!ri) : ORIGIN = 0x00000000, LENGTH = 32K
18353 + USERPAGE : ORIGIN = 0x80800000, LENGTH = 512
18354 + FACTORYPAGE : ORIGIN = 0x80800200, LENGTH = 512
18355 + }"
18356 + ;;
18357 +
18358 + avr32elf_uc3[ab][01]128)
18359 + MEMORY="MEMORY
18360 + {
18361 + FLASH (rxai!w) : ORIGIN = 0x80000000, LENGTH = 128K
18362 + CPUSRAM (wxa!ri) : ORIGIN = 0x00000000, LENGTH = 32K
18363 + USERPAGE : ORIGIN = 0x80800000, LENGTH = 512
18364 + FACTORYPAGE : ORIGIN = 0x80800200, LENGTH = 512
18365 + }"
18366 + ;;
18367 +
18368 + avr32elf_uc3b[01]64)
18369 + MEMORY="MEMORY
18370 + {
18371 + FLASH (rxai!w) : ORIGIN = 0x80000000, LENGTH = 64K
18372 + CPUSRAM (wxa!ri) : ORIGIN = 0x00000000, LENGTH = 16K
18373 + USERPAGE : ORIGIN = 0x80800000, LENGTH = 512
18374 + FACTORYPAGE : ORIGIN = 0x80800200, LENGTH = 512
18375 + }"
18376 + ;;
18377 +
18378 + avr32elf_uc3a3256*)
18379 + MEMORY="MEMORY
18380 + {
18381 + FLASH (rxai!w) : ORIGIN = 0x80000000, LENGTH = 256K
18382 + CPUSRAM (wxa!ri) : ORIGIN = 0x00000000, LENGTH = 64K
18383 + HSBSRAM (wxa!ri) : ORIGIN = 0xFF000000, LENGTH = 64K
18384 + USERPAGE : ORIGIN = 0x80800000, LENGTH = 512
18385 + FACTORYPAGE : ORIGIN = 0x80800200, LENGTH = 512
18386 + }"
18387 + OTHER_SECTIONS ="${OTHER_SECTIONS}
18388 + .hsbsram : { *(.hsbsram .hsbsram.*) } >HSBSRAM AT>FLASH :FLASH
18389 +"
18390 +
18391 + ;;
18392 +
18393 + avr32elf_uc3a3128*)
18394 + MEMORY="MEMORY
18395 + {
18396 + FLASH (rxai!w) : ORIGIN = 0x80000000, LENGTH = 128K
18397 + CPUSRAM (wxa!ri) : ORIGIN = 0x00000000, LENGTH = 64K
18398 + HSBSRAM (wxa!ri) : ORIGIN = 0xFF000000, LENGTH = 64K
18399 + USERPAGE : ORIGIN = 0x80800000, LENGTH = 512
18400 + FACTORYPAGE : ORIGIN = 0x80800200, LENGTH = 512
18401 + }"
18402 + OTHER_SECTIONS ="${OTHER_SECTIONS}
18403 + .hsbsram : { *(.hsbsram .hsbsram.*) } >HSBSRAM AT>FLASH :FLASH
18404 +"
18405 + ;;
18406 +
18407 + avr32elf_uc3a364*)
18408 + MEMORY="MEMORY
18409 + {
18410 + FLASH (rxai!w) : ORIGIN = 0x80000000, LENGTH = 64K
18411 + CPUSRAM (wxa!ri) : ORIGIN = 0x00000000, LENGTH = 64K
18412 + HSBSRAM (wxa!ri) : ORIGIN = 0xFF000000, LENGTH = 64K
18413 + USERPAGE : ORIGIN = 0x80800000, LENGTH = 512
18414 + FACTORYPAGE : ORIGIN = 0x80800200, LENGTH = 512
18415 + }"
18416 + OTHER_SECTIONS ="${OTHER_SECTIONS}
18417 + .hsbsram : { *(.hsbsram .hsbsram.*) } >HSBSRAM AT>FLASH :FLASH
18418 +"
18419 + ;;
18420 +
18421 +
18422 + esac
18423 + ;;
18424 +
18425 +esac
18426 --- /dev/null
18427 +++ b/ld/emulparams/avr32linux.sh
18428 @@ -0,0 +1,14 @@
18429 +ARCH=avr32
18430 +SCRIPT_NAME=elf
18431 +TEMPLATE_NAME=elf32
18432 +EXTRA_EM_FILE=avr32elf
18433 +OUTPUT_FORMAT="elf32-avr32"
18434 +GENERATE_SHLIB_SCRIPT=yes
18435 +MAXPAGESIZE=0x1000
18436 +TEXT_START_ADDR=0x00001000
18437 +NOP=0xd703d703
18438 +
18439 +# This appears to place the GOT before the data section, which is
18440 +# essential for uClinux. We don't use those .s* sections on AVR32
18441 +# anyway, so it shouldn't hurt for regular Linux either...
18442 +NO_SMALL_DATA=yes
18443 --- /dev/null
18444 +++ b/ld/emultempl/avr32elf.em
18445 @@ -0,0 +1,133 @@
18446 +# This shell script emits a C file. -*- C -*-
18447 +# Copyright (C) 2007 Atmel Corporation
18448 +#
18449 +# This file is part of GLD, the Gnu Linker.
18450 +#
18451 +# This program is free software; you can redistribute it and/or modify
18452 +# it under the terms of the GNU General Public License as published by
18453 +# the Free Software Foundation; either version 2 of the License, or
18454 +# (at your option) any later version.
18455 +#
18456 +# This program is distributed in the hope that it will be useful,
18457 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
18458 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18459 +# GNU General Public License for more details.
18460 +#
18461 +# You should have received a copy of the GNU General Public License
18462 +# along with this program; if not, write to the Free Software
18463 +# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
18464 +#
18465 +
18466 +# This file is sourced from elf32.em, and defines extra avr32-elf
18467 +# specific routines.
18468 +#
18469 +
18470 +# Generate linker script for writable rodata
18471 +LD_FLAG=rodata-writable
18472 +DATA_ALIGNMENT=${DATA_ALIGNMENT_}
18473 +RELOCATING=" "
18474 +WRITABLE_RODATA=" "
18475 +( echo "/* Linker script for writable rodata */"
18476 + . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
18477 + . ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
18478 +) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xwr
18479 +
18480 +
18481 +cat >> e${EMULATION_NAME}.c <<EOF
18482 +
18483 +#include "libbfd.h"
18484 +#include "elf32-avr32.h"
18485 +
18486 +/* Whether to allow direct references (sub or mov) to SEC_DATA and
18487 + !SEC_CONTENTS sections when optimizing. Not enabled by default
18488 + since it might cause link errors. */
18489 +static int direct_data_refs = 0;
18490 +
18491 +static void avr32_elf_after_open (void)
18492 +{
18493 + bfd_elf32_avr32_set_options (&link_info, direct_data_refs);
18494 + gld${EMULATION_NAME}_after_open ();
18495 +}
18496 +
18497 +static int rodata_writable = 0;
18498 +
18499 +static char * gld${EMULATION_NAME}_get_script (int *isfile);
18500 +
18501 +static char * avr32_elf_get_script (int *isfile)
18502 +{
18503 + if ( rodata_writable )
18504 + {
18505 +EOF
18506 +if test -n "$COMPILE_IN"
18507 +then
18508 +# Scripts compiled in.
18509 +
18510 +# sed commands to quote an ld script as a C string.
18511 +sc="-f stringify.sed"
18512 +
18513 +cat >>e${EMULATION_NAME}.c <<EOF
18514 + *isfile = 0;
18515 + return
18516 +EOF
18517 +sed $sc ldscripts/${EMULATION_NAME}.xwr >> e${EMULATION_NAME}.c
18518 +echo ';' >> e${EMULATION_NAME}.c
18519 +else
18520 +# Scripts read from the filesystem.
18521 +
18522 +cat >>e${EMULATION_NAME}.c <<EOF
18523 + *isfile = 1;
18524 + return "ldscripts/${EMULATION_NAME}.xwr";
18525 +EOF
18526 +fi
18527 +
18528 +cat >>e${EMULATION_NAME}.c <<EOF
18529 + }
18530 + return gld${EMULATION_NAME}_get_script (isfile);
18531 +}
18532 +
18533 +
18534 +EOF
18535 +
18536 +# Define some shell vars to insert bits of code into the standard elf
18537 +# parse_args and list_options functions.
18538 +#
18539 +PARSE_AND_LIST_PROLOGUE='
18540 +#define OPTION_DIRECT_DATA 300
18541 +#define OPTION_NO_DIRECT_DATA 301
18542 +#define OPTION_RODATA_WRITABLE 302
18543 +#define OPTION_NO_RODATA_WRITABLE 303
18544 +'
18545 +
18546 +PARSE_AND_LIST_LONGOPTS='
18547 + { "direct-data", no_argument, NULL, OPTION_DIRECT_DATA },
18548 + { "no-direct-data", no_argument, NULL, OPTION_NO_DIRECT_DATA },
18549 + { "rodata-writable", no_argument, NULL, OPTION_RODATA_WRITABLE },
18550 + { "no-rodata-writable", no_argument, NULL, OPTION_NO_RODATA_WRITABLE },
18551 +'
18552 +
18553 +PARSE_AND_LIST_OPTIONS='
18554 + fprintf (file, _(" --direct-data\t\tAllow direct data references when optimizing\n"));
18555 + fprintf (file, _(" --no-direct-data\tDo not allow direct data references when optimizing\n"));
18556 + fprintf (file, _(" --rodata-writable\tPut read-only data in writable data section\n"));
18557 + fprintf (file, _(" --no-rodata-writable\tDo not put read-only data in writable data section\n"));
18558 +'
18559 +
18560 +PARSE_AND_LIST_ARGS_CASES='
18561 + case OPTION_DIRECT_DATA:
18562 + direct_data_refs = 1;
18563 + break;
18564 + case OPTION_NO_DIRECT_DATA:
18565 + direct_data_refs = 0;
18566 + break;
18567 + case OPTION_RODATA_WRITABLE:
18568 + rodata_writable = 1;
18569 + break;
18570 + case OPTION_NO_RODATA_WRITABLE:
18571 + rodata_writable = 0;
18572 + break;
18573 +'
18574 +
18575 +# Replace some of the standard ELF functions with our own versions.
18576 +#
18577 +LDEMUL_AFTER_OPEN=avr32_elf_after_open
18578 +LDEMUL_GET_SCRIPT=avr32_elf_get_script
18579 --- a/ld/ld.info
18580 +++ b/ld/ld.info
18581 @@ -4347,6 +4347,8 @@ not listed.
18582
18583 * ARM:: `ld' and the ARM family
18584
18585 +* AVR32:: `ld' and AVR32 processors
18586 +
18587 * HPPA ELF32:: `ld' and HPPA 32-bit ELF
18588
18589 * MMIX:: `ld' and MMIX
18590 @@ -4487,7 +4489,7 @@ PIC. This avoids problems on uClinux ta
18591 used to generate relocatable binaries.
18592
18593 \1f
18594 -File: ld.info, Node: ARM, Next: HPPA ELF32, Prev: i960, Up: Machine Dependent
18595 +File: ld.info, Node: ARM, Next: AV32, Prev: i960, Up: Machine Dependent
18596
18597 4.4 `ld' and the ARM family
18598 ===========================
18599 @@ -4588,7 +4590,31 @@ enumeration values fitted into the small
18600 diagnosed.
18601
18602 \1f
18603 -File: ld.info, Node: HPPA ELF32, Next: MMIX, Prev: ARM, Up: Machine Dependent
18604 +File: ld.info, Node: AVR32, Next: HPPA ELF32, Prev: ARM, Up: Machine Dependent
18605 +
18606 +4.4 `ld' and AVR32 processors
18607 +=============================
18608 +
18609 +`--direct-data'
18610 +
18611 +`--no-direct-data'
18612 + Taking the address of a symbol can often be done by using a direct
18613 + `mov' or pc-relative `sub' instruction, which is faster than using
18614 + a PC- or GOT-relative load, especially on the uC3 processors.
18615 + However, this does not always work when dealing with symbols in
18616 + the `.data' section so this optimization is disabled by default.
18617 +
18618 + Specifying `--direct-data' will enable this optimization. Note
18619 + that this may cause `relocation truncated to fit' errors for
18620 + certain large programs. If this happens, the optimization can be
18621 + turned off by specifying `--no-direct-data'.
18622 +
18623 + All known issues with direct data optimizations are detected at
18624 + link time, so if the linker doesn't complain, the result should
18625 + run just fine.
18626 +
18627 +\1f
18628 +File: ld.info, Node: HPPA ELF32, Next: MMIX, Prev: AVR32, Up: Machine Dependent
18629
18630 4.5 `ld' and HPPA 32-bit ELF Support
18631 ====================================
18632 @@ -6336,6 +6362,7 @@ LD Index
18633 * --no-check-sections: Options. (line 765)
18634 * --no-define-common: Options. (line 787)
18635 * --no-demangle: Options. (line 816)
18636 +* --no-direct-data: AVR32. (line 6)
18637 * --no-dotsyms: PowerPC64 ELF64. (line 33)
18638 * --no-enum-size-warning: ARM. (line 94)
18639 * --no-gc-sections: Options. (line 848)
18640 @@ -6534,6 +6561,7 @@ LD Index
18641 * AT(LMA): Output Section LMA. (line 6)
18642 * AT>LMA_REGION: Output Section LMA. (line 6)
18643 * automatic data imports: WIN32. (line 170)
18644 +* AVR32 options: AVR32. (line 6)
18645 * back end: BFD. (line 6)
18646 * BASE (MRI): MRI. (line 54)
18647 * BE8: ARM. (line 23)
18648 @@ -7018,6 +7046,7 @@ Node: H8/300\7f183897
18649 Node: i960\7f185522
18650 Node: M68HC11/68HC12\7f187207
18651 Node: ARM\7f188910
18652 +Node: AVR32\7f182578
18653 Node: HPPA ELF32\7f193760
18654 Node: MMIX\7f195383
18655 Node: MSP430\7f196600
18656 --- a/ld/ld.texinfo
18657 +++ b/ld/ld.texinfo
18658 @@ -21,6 +21,7 @@
18659 @set UsesEnvVars
18660 @set GENERIC
18661 @set ARM
18662 +@set AVR32
18663 @set H8300
18664 @set HPPA
18665 @set I960
18666 @@ -139,6 +140,9 @@ section entitled ``GNU Free Documentatio
18667 @ifset ARM
18668 * ARM:: ld and the ARM family
18669 @end ifset
18670 +@ifset AVR32
18671 +* AVR32:: ld and AVR32 processors
18672 +@end ifset
18673 @ifset HPPA
18674 * HPPA ELF32:: ld and HPPA 32-bit ELF
18675 @end ifset
18676 @@ -5248,6 +5252,9 @@ functionality are not listed.
18677 @ifset ARM
18678 * ARM:: @command{ld} and the ARM family
18679 @end ifset
18680 +@ifset AVR32
18681 +* AVR32:: @command{ld} and AVR32 processors
18682 +@end ifset
18683 @ifset HPPA
18684 * HPPA ELF32:: @command{ld} and HPPA 32-bit ELF
18685 @end ifset
18686 @@ -5589,6 +5596,52 @@ not be diagnosed.
18687 @end ifclear
18688 @end ifset
18689
18690 +@ifset AVR32
18691 +@ifclear GENERIC
18692 +@raisesections
18693 +@end ifclear
18694 +
18695 +@node AVR32
18696 +@section @command{ld} and AVR32 processors
18697 +@cindex AVR32 options
18698 +@table @option
18699 +@kindex --direct-data
18700 +@kindex --no-direct-data
18701 +@item --direct-data
18702 +@item --no-direct-data
18703 +Taking the address of a symbol can often be done by using a direct
18704 +@code{mov} or pc-relative @code{sub} instruction, which is faster than
18705 +using a PC- or GOT-relative load, especially on the uC3
18706 +processors. However, this does not always work when dealing with
18707 +symbols in the @code{.data} section so this optimization is disabled
18708 +by default.
18709 +
18710 +Specifying @option{--direct-data} will enable this optimization. Note
18711 +that this may cause @samp{relocation truncated to fit} errors for
18712 +certain large programs. If this happens, the optimization can be
18713 +turned off by specifying @option{--no-direct-data}.
18714 +
18715 +All known issues with direct data optimizations are detected at link
18716 +time, so if the linker doesn't complain, the result should run just
18717 +fine.
18718 +
18719 +@kindex --rodata-writable
18720 +@kindex --no-rodata-writable
18721 +@item --rodata-writable
18722 +@item --no-rodata-writable
18723 +Using the @option{--rodata-writable} options will cause the linker
18724 +to try and use a linker script where read-only data will be placed
18725 +in the same section as writable data. This can give great performance
18726 +gain on cacheless processors where read-only data normally is placed in
18727 +flash, and writable data is placed in internal sram. This will however
18728 +come at the expence of a larger memory footprint.
18729 +@end table
18730 +
18731 +@ifclear GENERIC
18732 +@lowersections
18733 +@end ifclear
18734 +@end ifset
18735 +
18736 @ifset HPPA
18737 @ifclear GENERIC
18738 @raisesections
18739 --- a/ld/Makefile.am
18740 +++ b/ld/Makefile.am
18741 @@ -137,7 +137,34 @@ ALL_EMULATIONS = \
18742 eavr3.o \
18743 eavr4.o \
18744 eavr5.o \
18745 - eavr6.o \
18746 + eavr6.o \
18747 + eavr32elf_ap7000.o \
18748 + eavr32elf_ap7001.o \
18749 + eavr32elf_ap7002.o \
18750 + eavr32elf_ap7200.o \
18751 + eavr32elf_uc3a0128.o \
18752 + eavr32elf_uc3a0256.o \
18753 + eavr32elf_uc3a0512.o \
18754 + eavr32elf_uc3a0512es.o \
18755 + eavr32elf_uc3a1128.o \
18756 + eavr32elf_uc3a1256.o \
18757 + eavr32elf_uc3a1512es.o \
18758 + eavr32elf_uc3a1512.o \
18759 + eavr32elf_uc3a364.o \
18760 + eavr32elf_uc3a364s.o \
18761 + eavr32elf_uc3a3128.o \
18762 + eavr32elf_uc3a3128s.o \
18763 + eavr32elf_uc3a3256.o \
18764 + eavr32elf_uc3a3256s.o \
18765 + eavr32elf_uc3b064.o \
18766 + eavr32elf_uc3b0128.o \
18767 + eavr32elf_uc3b0256es.o \
18768 + eavr32elf_uc3b0256.o \
18769 + eavr32elf_uc3b164.o \
18770 + eavr32elf_uc3b1128.o \
18771 + eavr32elf_uc3b1256es.o \
18772 + eavr32elf_uc3b1256.o \
18773 + eavr32linux.o \
18774 ecoff_i860.o \
18775 ecoff_sparc.o \
18776 eelf32_spu.o \
18777 @@ -622,6 +649,114 @@ eavr6.c: $(srcdir)/emulparams/avr6.sh $(
18778 $(ELF_DEPS) $(srcdir)/scripttempl/avr.sc \
18779 ${GEN_DEPENDS}
18780 ${GENSCRIPTS} avr6 "$(tdir_avr2)"
18781 +eavr32elf_ap7000.c: $(srcdir)/emulparams/avr32elf.sh \
18782 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18783 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18784 + ${GENSCRIPTS} avr32elf_ap7000 "$(tdir_avr32)" avr32elf
18785 +eavr32elf_ap7001.c: $(srcdir)/emulparams/avr32elf.sh \
18786 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18787 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18788 + ${GENSCRIPTS} avr32elf_ap7001 "$(tdir_avr32)" avr32elf
18789 +eavr32elf_ap7002.c: $(srcdir)/emulparams/avr32elf.sh \
18790 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18791 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18792 + ${GENSCRIPTS} avr32elf_ap7002 "$(tdir_avr32)" avr32elf
18793 +eavr32elf_ap7200.c: $(srcdir)/emulparams/avr32elf.sh \
18794 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18795 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18796 + ${GENSCRIPTS} avr32elf_ap7200 "$(tdir_avr32)" avr32elf
18797 +eavr32elf_uc3a0128.c: $(srcdir)/emulparams/avr32elf.sh \
18798 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18799 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18800 + ${GENSCRIPTS} avr32elf_uc3a0128 "$(tdir_avr32)" avr32elf
18801 +eavr32elf_uc3a0256.c: $(srcdir)/emulparams/avr32elf.sh \
18802 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18803 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18804 + ${GENSCRIPTS} avr32elf_uc3a0256 "$(tdir_avr32)" avr32elf
18805 +eavr32elf_uc3a0512.c: $(srcdir)/emulparams/avr32elf.sh \
18806 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18807 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18808 + ${GENSCRIPTS} avr32elf_uc3a0512 "$(tdir_avr32)" avr32elf
18809 +eavr32elf_uc3a0512es.c: $(srcdir)/emulparams/avr32elf.sh \
18810 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18811 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18812 + ${GENSCRIPTS} avr32elf_uc3a0512es "$(tdir_avr32)" avr32elf
18813 +eavr32elf_uc3a1128.c: $(srcdir)/emulparams/avr32elf.sh \
18814 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18815 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18816 + ${GENSCRIPTS} avr32elf_uc3a1128 "$(tdir_avr32)" avr32elf
18817 +eavr32elf_uc3a1256.c: $(srcdir)/emulparams/avr32elf.sh \
18818 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18819 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18820 + ${GENSCRIPTS} avr32elf_uc3a1256 "$(tdir_avr32)" avr32elf
18821 +eavr32elf_uc3a1512.c: $(srcdir)/emulparams/avr32elf.sh \
18822 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18823 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18824 + ${GENSCRIPTS} avr32elf_uc3a1512 "$(tdir_avr32)" avr32elf
18825 +eavr32elf_uc3a1512es.c: $(srcdir)/emulparams/avr32elf.sh \
18826 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18827 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18828 + ${GENSCRIPTS} avr32elf_uc3a1512es "$(tdir_avr32)" avr32elf
18829 +eavr32elf_uc3a364.c: $(srcdir)/emulparams/avr32elf.sh \
18830 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18831 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18832 + ${GENSCRIPTS} avr32elf_uc3a364 "$(tdir_avr32)" avr32elf
18833 +eavr32elf_uc3a364s.c: $(srcdir)/emulparams/avr32elf.sh \
18834 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18835 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18836 + ${GENSCRIPTS} avr32elf_uc3a364s "$(tdir_avr32)" avr32elf
18837 +eavr32elf_uc3a3128.c: $(srcdir)/emulparams/avr32elf.sh \
18838 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18839 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18840 + ${GENSCRIPTS} avr32elf_uc3a3128 "$(tdir_avr32)" avr32elf
18841 +eavr32elf_uc3a3128s.c: $(srcdir)/emulparams/avr32elf.sh \
18842 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18843 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18844 + ${GENSCRIPTS} avr32elf_uc3a3128s "$(tdir_avr32)" avr32elf
18845 +eavr32elf_uc3a3256.c: $(srcdir)/emulparams/avr32elf.sh \
18846 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18847 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18848 + ${GENSCRIPTS} avr32elf_uc3a3256 "$(tdir_avr32)" avr32elf
18849 +eavr32elf_uc3a3256s.c: $(srcdir)/emulparams/avr32elf.sh \
18850 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18851 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18852 + ${GENSCRIPTS} avr32elf_uc3a3256s "$(tdir_avr32)" avr32elf
18853 +eavr32elf_uc3b064.c: $(srcdir)/emulparams/avr32elf.sh \
18854 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18855 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18856 + ${GENSCRIPTS} avr32elf_uc3b064 "$(tdir_avr32)" avr32elf
18857 +eavr32elf_uc3b0128.c: $(srcdir)/emulparams/avr32elf.sh \
18858 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18859 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18860 + ${GENSCRIPTS} avr32elf_uc3b0128 "$(tdir_avr32)" avr32elf
18861 +eavr32elf_uc3b0256.c: $(srcdir)/emulparams/avr32elf.sh \
18862 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18863 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18864 + ${GENSCRIPTS} avr32elf_uc3b0256 "$(tdir_avr32)" avr32elf
18865 +eavr32elf_uc3b0256es.c: $(srcdir)/emulparams/avr32elf.sh \
18866 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18867 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18868 + ${GENSCRIPTS} avr32elf_uc3b0256es "$(tdir_avr32)" avr32elf
18869 +eavr32elf_uc3b164.c: $(srcdir)/emulparams/avr32elf.sh \
18870 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18871 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18872 + ${GENSCRIPTS} avr32elf_uc3b164 "$(tdir_avr32)" avr32elf
18873 +eavr32elf_uc3b1128.c: $(srcdir)/emulparams/avr32elf.sh \
18874 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18875 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18876 + ${GENSCRIPTS} avr32elf_uc3b1128 "$(tdir_avr32)" avr32elf
18877 +eavr32elf_uc3b1256.c: $(srcdir)/emulparams/avr32elf.sh \
18878 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18879 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18880 + ${GENSCRIPTS} avr32elf_uc3b1256 "$(tdir_avr32)" avr32elf
18881 +eavr32elf_uc3b1256es.c: $(srcdir)/emulparams/avr32elf.sh \
18882 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18883 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
18884 + ${GENSCRIPTS} avr32elf_uc3b1256es "$(tdir_avr32)" avr32elf
18885 +eavr32linux.c: $(srcdir)/emulparams/avr32linux.sh \
18886 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
18887 + $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
18888 + ${GENSCRIPTS} avr32linux "$(tdir_avr32)"
18889 ecoff_i860.c: $(srcdir)/emulparams/coff_i860.sh \
18890 $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/i860coff.sc ${GEN_DEPENDS}
18891 ${GENSCRIPTS} coff_i860 "$(tdir_coff_i860)"
18892 @@ -1877,7 +2012,9 @@ install-exec-local: ld-new$(EXEEXT)
18893 || $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) ld-new$(EXEEXT) $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT); \
18894 fi
18895
18896 -install-data-local:
18897 +# We want install to imply install-info as per GNU standards, despite the
18898 +# cygnus option.
18899 +install-data-local: install-info
18900 $(mkinstalldirs) $(DESTDIR)$(scriptdir)/ldscripts
18901 for f in ldscripts/*; do \
18902 $(INSTALL_DATA) $$f $(DESTDIR)$(scriptdir)/$$f ; \
18903 --- /dev/null
18904 +++ b/ld/scripttempl/elf_xip.sc
18905 @@ -0,0 +1,456 @@
18906 +#
18907 +# Unusual variables checked by this code:
18908 +# NOP - four byte opcode for no-op (defaults to 0)
18909 +# NO_SMALL_DATA - no .sbss/.sbss2/.sdata/.sdata2 sections if not
18910 +# empty.
18911 +# SMALL_DATA_CTOR - .ctors contains small data.
18912 +# SMALL_DATA_DTOR - .dtors contains small data.
18913 +# DATA_ADDR - if end-of-text-plus-one-page isn't right for data start
18914 +# INITIAL_READONLY_SECTIONS - at start of text segment
18915 +# OTHER_READONLY_SECTIONS - other than .text .init .rodata ...
18916 +# (e.g., .PARISC.milli)
18917 +# OTHER_TEXT_SECTIONS - these get put in .text when relocating
18918 +# OTHER_READWRITE_SECTIONS - other than .data .bss .ctors .sdata ...
18919 +# (e.g., .PARISC.global)
18920 +# OTHER_RELRO_SECTIONS - other than .data.rel.ro ...
18921 +# (e.g. PPC32 .fixup, .got[12])
18922 +# OTHER_BSS_SECTIONS - other than .bss .sbss ...
18923 +# OTHER_SECTIONS - at the end
18924 +# EXECUTABLE_SYMBOLS - symbols that must be defined for an
18925 +# executable (e.g., _DYNAMIC_LINK)
18926 +# TEXT_START_ADDR - the first byte of the text segment, after any
18927 +# headers.
18928 +# TEXT_BASE_ADDRESS - the first byte of the text segment.
18929 +# TEXT_START_SYMBOLS - symbols that appear at the start of the
18930 +# .text section.
18931 +# DATA_START_SYMBOLS - symbols that appear at the start of the
18932 +# .data section.
18933 +# OTHER_GOT_SYMBOLS - symbols defined just before .got.
18934 +# OTHER_GOT_SECTIONS - sections just after .got.
18935 +# OTHER_SDATA_SECTIONS - sections just after .sdata.
18936 +# OTHER_BSS_SYMBOLS - symbols that appear at the start of the
18937 +# .bss section besides __bss_start.
18938 +# DATA_PLT - .plt should be in data segment, not text segment.
18939 +# PLT_BEFORE_GOT - .plt just before .got when .plt is in data segement.
18940 +# BSS_PLT - .plt should be in bss segment
18941 +# TEXT_DYNAMIC - .dynamic in text segment, not data segment.
18942 +# EMBEDDED - whether this is for an embedded system.
18943 +# SHLIB_TEXT_START_ADDR - if set, add to SIZEOF_HEADERS to set
18944 +# start address of shared library.
18945 +# INPUT_FILES - INPUT command of files to always include
18946 +# WRITABLE_RODATA - if set, the .rodata section should be writable
18947 +# INIT_START, INIT_END - statements just before and just after
18948 +# combination of .init sections.
18949 +# FINI_START, FINI_END - statements just before and just after
18950 +# combination of .fini sections.
18951 +# STACK_ADDR - start of a .stack section.
18952 +# OTHER_END_SYMBOLS - symbols to place right at the end of the script.
18953 +# SEPARATE_GOTPLT - if set, .got.plt should be separate output section,
18954 +# so that .got can be in the RELRO area. It should be set to
18955 +# the number of bytes in the beginning of .got.plt which can be
18956 +# in the RELRO area as well.
18957 +#
18958 +# When adding sections, do note that the names of some sections are used
18959 +# when specifying the start address of the next.
18960 +#
18961 +
18962 +# Many sections come in three flavours. There is the 'real' section,
18963 +# like ".data". Then there are the per-procedure or per-variable
18964 +# sections, generated by -ffunction-sections and -fdata-sections in GCC,
18965 +# and useful for --gc-sections, which for a variable "foo" might be
18966 +# ".data.foo". Then there are the linkonce sections, for which the linker
18967 +# eliminates duplicates, which are named like ".gnu.linkonce.d.foo".
18968 +# The exact correspondences are:
18969 +#
18970 +# Section Linkonce section
18971 +# .text .gnu.linkonce.t.foo
18972 +# .rodata .gnu.linkonce.r.foo
18973 +# .data .gnu.linkonce.d.foo
18974 +# .bss .gnu.linkonce.b.foo
18975 +# .sdata .gnu.linkonce.s.foo
18976 +# .sbss .gnu.linkonce.sb.foo
18977 +# .sdata2 .gnu.linkonce.s2.foo
18978 +# .sbss2 .gnu.linkonce.sb2.foo
18979 +# .debug_info .gnu.linkonce.wi.foo
18980 +# .tdata .gnu.linkonce.td.foo
18981 +# .tbss .gnu.linkonce.tb.foo
18982 +#
18983 +# Each of these can also have corresponding .rel.* and .rela.* sections.
18984 +
18985 +test -z "$ENTRY" && ENTRY=_start
18986 +test -z "${BIG_OUTPUT_FORMAT}" && BIG_OUTPUT_FORMAT=${OUTPUT_FORMAT}
18987 +test -z "${LITTLE_OUTPUT_FORMAT}" && LITTLE_OUTPUT_FORMAT=${OUTPUT_FORMAT}
18988 +if [ -z "$MACHINE" ]; then OUTPUT_ARCH=${ARCH}; else OUTPUT_ARCH=${ARCH}:${MACHINE}; fi
18989 +test -z "${ELFSIZE}" && ELFSIZE=32
18990 +test -z "${ALIGNMENT}" && ALIGNMENT="${ELFSIZE} / 8"
18991 +test "$LD_FLAG" = "N" && DATA_ADDR=.
18992 +test -n "$CREATE_SHLIB$CREATE_PIE" && test -n "$SHLIB_DATA_ADDR" && COMMONPAGESIZE=""
18993 +test -z "$CREATE_SHLIB$CREATE_PIE" && test -n "$DATA_ADDR" && COMMONPAGESIZE=""
18994 +test -n "$RELRO_NOW" && unset SEPARATE_GOTPLT
18995 +if test -n "$RELOCATING"; then
18996 + RO_REGION="${RO_VMA_REGION+ >}${RO_VMA_REGION}${RO_LMA_REGION+ AT>}${RO_LMA_REGION}"
18997 + RW_REGION="${RW_VMA_REGION+ >}${RW_VMA_REGION}${RW_LMA_REGION+ AT>}${RW_LMA_REGION}"
18998 +else
18999 + RO_REGION=""
19000 + RW_REGION=""
19001 +fi
19002 +INTERP=".interp ${RELOCATING-0} : { *(.interp) }${RO_REGION}"
19003 +PLT=".plt ${RELOCATING-0} : { *(.plt) }"
19004 +if test -z "$GOT"; then
19005 + if test -z "$SEPARATE_GOTPLT"; then
19006 + GOT=".got ${RELOCATING-0} : { *(.got.plt) *(.got) }"
19007 + else
19008 + GOT=".got ${RELOCATING-0} : { *(.got) }"
19009 + GOTPLT="${RELOCATING+${DATA_SEGMENT_RELRO_GOTPLT_END}}
19010 + .got.plt ${RELOCATING-0} : { *(.got.plt) }"
19011 + fi
19012 +fi
19013 +DALIGN=".dalign : { . = ALIGN(${DATA_SEGMENT_ALIGN}); PROVIDE(_data_lma = .); }${RO_REGION}"
19014 +BALIGN=".balign : { . = ALIGN(${BSS_ALIGNMENT}); _edata = .; }${RW_REGION}"
19015 +DYNAMIC=".dynamic ${RELOCATING-0} : { *(.dynamic) }"
19016 +RODATA=".rodata ${RELOCATING-0} : { *(.rodata${RELOCATING+ .rodata.* .gnu.linkonce.r.*}) }"
19017 +DATARELRO=".data.rel.ro : { *(.data.rel.ro.local) *(.data.rel.ro*) }${RW_REGION}"
19018 +STACKNOTE="/DISCARD/ : { *(.note.GNU-stack) }"
19019 +if test -z "${NO_SMALL_DATA}"; then
19020 + SBSS=".sbss ${RELOCATING-0} :
19021 + {
19022 + ${RELOCATING+PROVIDE (__sbss_start = .);}
19023 + ${RELOCATING+PROVIDE (___sbss_start = .);}
19024 + ${CREATE_SHLIB+*(.sbss2 .sbss2.* .gnu.linkonce.sb2.*)}
19025 + *(.dynsbss)
19026 + *(.sbss${RELOCATING+ .sbss.* .gnu.linkonce.sb.*})
19027 + *(.scommon)
19028 + ${RELOCATING+PROVIDE (__sbss_end = .);}
19029 + ${RELOCATING+PROVIDE (___sbss_end = .);}
19030 + }${RW_REGION}"
19031 + SBSS2=".sbss2 ${RELOCATING-0} : { *(.sbss2${RELOCATING+ .sbss2.* .gnu.linkonce.sb2.*}) }${RW_REGION}"
19032 + SDATA="/* We want the small data sections together, so single-instruction offsets
19033 + can access them all, and initialized data all before uninitialized, so
19034 + we can shorten the on-disk segment size. */
19035 + .sdata ${RELOCATING-0} :
19036 + {
19037 + ${RELOCATING+${SDATA_START_SYMBOLS}}
19038 + ${CREATE_SHLIB+*(.sdata2 .sdata2.* .gnu.linkonce.s2.*)}
19039 + *(.sdata${RELOCATING+ .sdata.* .gnu.linkonce.s.*})
19040 + }${RW_REGION}"
19041 + SDATA2=".sdata2 ${RELOCATING-0} : { *(.sdata2${RELOCATING+ .sdata2.* .gnu.linkonce.s2.*}) }${RW_REGION}"
19042 + REL_SDATA=".rel.sdata ${RELOCATING-0} : { *(.rel.sdata${RELOCATING+ .rel.sdata.* .rel.gnu.linkonce.s.*}) }${RO_REGION}
19043 + .rela.sdata ${RELOCATING-0} : { *(.rela.sdata${RELOCATING+ .rela.sdata.* .rela.gnu.linkonce.s.*}) }"
19044 + REL_SBSS=".rel.sbss ${RELOCATING-0} : { *(.rel.sbss${RELOCATING+ .rel.sbss.* .rel.gnu.linkonce.sb.*}) }${RO_REGION}
19045 + .rela.sbss ${RELOCATING-0} : { *(.rela.sbss${RELOCATING+ .rela.sbss.* .rela.gnu.linkonce.sb.*}) }${RO_REGION}"
19046 + REL_SDATA2=".rel.sdata2 ${RELOCATING-0} : { *(.rel.sdata2${RELOCATING+ .rel.sdata2.* .rel.gnu.linkonce.s2.*}) }${RO_REGION}
19047 + .rela.sdata2 ${RELOCATING-0} : { *(.rela.sdata2${RELOCATING+ .rela.sdata2.* .rela.gnu.linkonce.s2.*}) }${RO_REGION}"
19048 + REL_SBSS2=".rel.sbss2 ${RELOCATING-0} : { *(.rel.sbss2${RELOCATING+ .rel.sbss2.* .rel.gnu.linkonce.sb2.*}) }${RO_REGION}
19049 + .rela.sbss2 ${RELOCATING-0} : { *(.rela.sbss2${RELOCATING+ .rela.sbss2.* .rela.gnu.linkonce.sb2.*}) }${RO_REGION}"
19050 +else
19051 + NO_SMALL_DATA=" "
19052 +fi
19053 +test -n "$SEPARATE_GOTPLT" && SEPARATE_GOTPLT=" "
19054 +CTOR=".ctors ${CONSTRUCTING-0} :
19055 + {
19056 + ${CONSTRUCTING+${CTOR_START}}
19057 + /* gcc uses crtbegin.o to find the start of
19058 + the constructors, so we make sure it is
19059 + first. Because this is a wildcard, it
19060 + doesn't matter if the user does not
19061 + actually link against crtbegin.o; the
19062 + linker won't look for a file to match a
19063 + wildcard. The wildcard also means that it
19064 + doesn't matter which directory crtbegin.o
19065 + is in. */
19066 +
19067 + KEEP (*crtbegin*.o(.ctors))
19068 +
19069 + /* We don't want to include the .ctor section from
19070 + from the crtend.o file until after the sorted ctors.
19071 + The .ctor section from the crtend file contains the
19072 + end of ctors marker and it must be last */
19073 +
19074 + KEEP (*(EXCLUDE_FILE (*crtend*.o $OTHER_EXCLUDE_FILES) .ctors))
19075 + KEEP (*(SORT(.ctors.*)))
19076 + KEEP (*(.ctors))
19077 + ${CONSTRUCTING+${CTOR_END}}
19078 + }"
19079 +DTOR=".dtors ${CONSTRUCTING-0} :
19080 + {
19081 + ${CONSTRUCTING+${DTOR_START}}
19082 + KEEP (*crtbegin*.o(.dtors))
19083 + KEEP (*(EXCLUDE_FILE (*crtend*.o $OTHER_EXCLUDE_FILES) .dtors))
19084 + KEEP (*(SORT(.dtors.*)))
19085 + KEEP (*(.dtors))
19086 + ${CONSTRUCTING+${DTOR_END}}
19087 + }"
19088 +STACK=".stack ${RELOCATING-0}${RELOCATING+${STACK_ADDR}} :
19089 + {
19090 + ${RELOCATING+_stack = .;}
19091 + *(.stack)
19092 + ${RELOCATING+${STACK_SIZE+. = ${STACK_SIZE};}}
19093 + ${RELOCATING+_estack = .;}
19094 + }${RW_REGION}"
19095 +
19096 +# if this is for an embedded system, don't add SIZEOF_HEADERS.
19097 +if [ -z "$EMBEDDED" ]; then
19098 + test -z "${TEXT_BASE_ADDRESS}" && TEXT_BASE_ADDRESS="${TEXT_START_ADDR} + SIZEOF_HEADERS"
19099 +else
19100 + test -z "${TEXT_BASE_ADDRESS}" && TEXT_BASE_ADDRESS="${TEXT_START_ADDR}"
19101 +fi
19102 +
19103 +cat <<EOF
19104 +OUTPUT_FORMAT("${OUTPUT_FORMAT}", "${BIG_OUTPUT_FORMAT}",
19105 + "${LITTLE_OUTPUT_FORMAT}")
19106 +OUTPUT_ARCH(${OUTPUT_ARCH})
19107 +ENTRY(${ENTRY})
19108 +
19109 +${RELOCATING+${LIB_SEARCH_DIRS}}
19110 +${RELOCATING+/* Do we need any of these for elf?
19111 + __DYNAMIC = 0; ${STACKZERO+${STACKZERO}} ${SHLIB_PATH+${SHLIB_PATH}} */}
19112 +${RELOCATING+${EXECUTABLE_SYMBOLS}}
19113 +${RELOCATING+${INPUT_FILES}}
19114 +${RELOCATING- /* For some reason, the Solaris linker makes bad executables
19115 + if gld -r is used and the intermediate file has sections starting
19116 + at non-zero addresses. Could be a Solaris ld bug, could be a GNU ld
19117 + bug. But for now assigning the zero vmas works. */}
19118 +
19119 +${RELOCATING+${MEMORY}}
19120 +
19121 +SECTIONS
19122 +{
19123 + /* Read-only sections, merged into text segment: */
19124 + ${CREATE_SHLIB-${CREATE_PIE-${RELOCATING+PROVIDE (__executable_start = ${TEXT_START_ADDR}); . = ${TEXT_BASE_ADDRESS};}}}
19125 + ${CREATE_SHLIB+${RELOCATING+. = ${SHLIB_TEXT_START_ADDR:-0} + SIZEOF_HEADERS;}}
19126 + ${CREATE_PIE+${RELOCATING+. = ${SHLIB_TEXT_START_ADDR:-0} + SIZEOF_HEADERS;}}
19127 + ${CREATE_SHLIB-${INTERP}}
19128 + ${INITIAL_READONLY_SECTIONS}
19129 + ${TEXT_DYNAMIC+${DYNAMIC}${RO_REGION}}
19130 + .hash ${RELOCATING-0} : { *(.hash) }${RO_REGION}
19131 + .dynsym ${RELOCATING-0} : { *(.dynsym) }${RO_REGION}
19132 + .dynstr ${RELOCATING-0} : { *(.dynstr) }${RO_REGION}
19133 + .gnu.version ${RELOCATING-0} : { *(.gnu.version) }${RO_REGION}
19134 + .gnu.version_d ${RELOCATING-0}: { *(.gnu.version_d) }${RO_REGION}
19135 + .gnu.version_r ${RELOCATING-0}: { *(.gnu.version_r) }${RO_REGION}
19136 +
19137 +EOF
19138 +if [ "x$COMBRELOC" = x ]; then
19139 + COMBRELOCCAT=cat
19140 +else
19141 + COMBRELOCCAT="cat > $COMBRELOC"
19142 +fi
19143 +eval $COMBRELOCCAT <<EOF
19144 + .rel.init ${RELOCATING-0} : { *(.rel.init) }${RO_REGION}
19145 + .rela.init ${RELOCATING-0} : { *(.rela.init) }${RO_REGION}
19146 + .rel.text ${RELOCATING-0} : { *(.rel.text${RELOCATING+ .rel.text.* .rel.gnu.linkonce.t.*}) }${RO_REGION}
19147 + .rela.text ${RELOCATING-0} : { *(.rela.text${RELOCATING+ .rela.text.* .rela.gnu.linkonce.t.*}) }${RO_REGION}
19148 + .rel.fini ${RELOCATING-0} : { *(.rel.fini) }${RO_REGION}
19149 + .rela.fini ${RELOCATING-0} : { *(.rela.fini) }${RO_REGION}
19150 + .rel.rodata ${RELOCATING-0} : { *(.rel.rodata${RELOCATING+ .rel.rodata.* .rel.gnu.linkonce.r.*}) }${RO_REGION}
19151 + .rela.rodata ${RELOCATING-0} : { *(.rela.rodata${RELOCATING+ .rela.rodata.* .rela.gnu.linkonce.r.*}) }${RO_REGION}
19152 + ${OTHER_READONLY_RELOC_SECTIONS}
19153 + .rel.data.rel.ro ${RELOCATING-0} : { *(.rel.data.rel.ro${RELOCATING+*}) }${RO_REGION}
19154 + .rela.data.rel.ro ${RELOCATING-0} : { *(.rel.data.rel.ro${RELOCATING+*}) }${RO_REGION}
19155 + .rel.data ${RELOCATING-0} : { *(.rel.data${RELOCATING+ .rel.data.* .rel.gnu.linkonce.d.*}) }${RO_REGION}
19156 + .rela.data ${RELOCATING-0} : { *(.rela.data${RELOCATING+ .rela.data.* .rela.gnu.linkonce.d.*}) }${RO_REGION}
19157 + .rel.tdata ${RELOCATING-0} : { *(.rel.tdata${RELOCATING+ .rel.tdata.* .rel.gnu.linkonce.td.*}) }${RO_REGION}
19158 + .rela.tdata ${RELOCATING-0} : { *(.rela.tdata${RELOCATING+ .rela.tdata.* .rela.gnu.linkonce.td.*}) }${RO_REGION}
19159 + .rel.tbss ${RELOCATING-0} : { *(.rel.tbss${RELOCATING+ .rel.tbss.* .rel.gnu.linkonce.tb.*}) }${RO_REGION}
19160 + .rela.tbss ${RELOCATING-0} : { *(.rela.tbss${RELOCATING+ .rela.tbss.* .rela.gnu.linkonce.tb.*}) }${RO_REGION}
19161 + .rel.ctors ${RELOCATING-0} : { *(.rel.ctors) }${RO_REGION}
19162 + .rela.ctors ${RELOCATING-0} : { *(.rela.ctors) }${RO_REGION}
19163 + .rel.dtors ${RELOCATING-0} : { *(.rel.dtors) }${RO_REGION}
19164 + .rela.dtors ${RELOCATING-0} : { *(.rela.dtors) }${RO_REGION}
19165 + .rel.got ${RELOCATING-0} : { *(.rel.got) }${RO_REGION}
19166 + .rela.got ${RELOCATING-0} : { *(.rela.got) }${RO_REGION}
19167 + ${OTHER_GOT_RELOC_SECTIONS}
19168 + ${REL_SDATA}
19169 + ${REL_SBSS}
19170 + ${REL_SDATA2}
19171 + ${REL_SBSS2}
19172 + .rel.bss ${RELOCATING-0} : { *(.rel.bss${RELOCATING+ .rel.bss.* .rel.gnu.linkonce.b.*}) }${RO_REGION}
19173 + .rela.bss ${RELOCATING-0} : { *(.rela.bss${RELOCATING+ .rela.bss.* .rela.gnu.linkonce.b.*}) }${RO_REGION}
19174 +EOF
19175 +if [ -n "$COMBRELOC" ]; then
19176 +cat <<EOF
19177 + .rel.dyn ${RELOCATING-0} :
19178 + {
19179 +EOF
19180 +sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rela\./d;s/^.*: { *\(.*\)}$/ \1/' $COMBRELOC
19181 +cat <<EOF
19182 + }${RO_REGION}
19183 + .rela.dyn ${RELOCATING-0} :
19184 + {
19185 +EOF
19186 +sed -e '/^[ ]*[{}][ ]*$/d;/:[ ]*$/d;/\.rel\./d;s/^.*: { *\(.*\)}/ \1/' $COMBRELOC
19187 +cat <<EOF
19188 + }${RO_REGION}
19189 +EOF
19190 +fi
19191 +cat <<EOF
19192 + .rel.plt ${RELOCATING-0} : { *(.rel.plt) }${RO_REGION}
19193 + .rela.plt ${RELOCATING-0} : { *(.rela.plt) }${RO_REGION}
19194 + ${OTHER_PLT_RELOC_SECTIONS}
19195 +
19196 + .init ${RELOCATING-0} :
19197 + {
19198 + ${RELOCATING+${INIT_START}}
19199 + KEEP (*(.init))
19200 + ${RELOCATING+${INIT_END}}
19201 + }${RO_REGION} =${NOP-0}
19202 +
19203 + ${DATA_PLT-${BSS_PLT-${PLT}${RO_REGION}}}
19204 + .text ${RELOCATING-0} :
19205 + {
19206 + ${RELOCATING+${TEXT_START_SYMBOLS}}
19207 + *(.text .stub${RELOCATING+ .text.* .gnu.linkonce.t.*})
19208 + KEEP (*(.text.*personality*))
19209 + /* .gnu.warning sections are handled specially by elf32.em. */
19210 + *(.gnu.warning)
19211 + ${RELOCATING+${OTHER_TEXT_SECTIONS}}
19212 + }${RO_REGION} =${NOP-0}
19213 + .fini ${RELOCATING-0} :
19214 + {
19215 + ${RELOCATING+${FINI_START}}
19216 + KEEP (*(.fini))
19217 + ${RELOCATING+${FINI_END}}
19218 + }${RO_REGION} =${NOP-0}
19219 + ${RELOCATING+PROVIDE (__etext = .);}
19220 + ${RELOCATING+PROVIDE (_etext = .);}
19221 + ${RELOCATING+PROVIDE (etext = .);}
19222 + ${WRITABLE_RODATA-${RODATA}${RO_REGION}}
19223 + .rodata1 ${RELOCATING-0} : { *(.rodata1) }${RO_REGION}
19224 + ${CREATE_SHLIB-${SDATA2}}
19225 + ${CREATE_SHLIB-${SBSS2}}
19226 + ${OTHER_READONLY_SECTIONS}
19227 + .eh_frame_hdr : { *(.eh_frame_hdr) }${RO_REGION}
19228 + .eh_frame ${RELOCATING-0} : ONLY_IF_RO { KEEP (*(.eh_frame)) }${RO_REGION}
19229 + .gcc_except_table ${RELOCATING-0} : ONLY_IF_RO { KEEP (*(.gcc_except_table)) *(.gcc_except_table.*) }${RO_REGION}
19230 +
19231 + ${RELOCATING+${DALIGN}}
19232 + ${RELOCATING+PROVIDE (_data = ORIGIN(${RW_VMA_REGION}));}
19233 + . = ORIGIN(${RW_VMA_REGION});
19234 + /* Exception handling */
19235 + .eh_frame ${RELOCATING-0} : ONLY_IF_RW { KEEP (*(.eh_frame)) }${RW_REGION}
19236 + .gcc_except_table ${RELOCATING-0} : ONLY_IF_RW { KEEP (*(.gcc_except_table)) *(.gcc_except_table.*) }${RW_REGION}
19237 +
19238 + /* Thread Local Storage sections */
19239 + .tdata ${RELOCATING-0} : { *(.tdata${RELOCATING+ .tdata.* .gnu.linkonce.td.*}) }${RW_REGION}
19240 + .tbss ${RELOCATING-0} : { *(.tbss${RELOCATING+ .tbss.* .gnu.linkonce.tb.*})${RELOCATING+ *(.tcommon)} }${RW_REGION}
19241 +
19242 + /* Ensure the __preinit_array_start label is properly aligned. We
19243 + could instead move the label definition inside the section, but
19244 + the linker would then create the section even if it turns out to
19245 + be empty, which isn't pretty. */
19246 + ${RELOCATING+${CREATE_SHLIB-PROVIDE (__preinit_array_start = ALIGN(${ALIGNMENT}));}}
19247 + .preinit_array ${RELOCATING-0} : { KEEP (*(.preinit_array)) }${RW_REGION}
19248 + ${RELOCATING+${CREATE_SHLIB-PROVIDE (__preinit_array_end = .);}}
19249 +
19250 + ${RELOCATING+${CREATE_SHLIB-PROVIDE (__init_array_start = .);}}
19251 + .init_array ${RELOCATING-0} : { KEEP (*(.init_array)) }${RW_REGION}
19252 + ${RELOCATING+${CREATE_SHLIB-PROVIDE (__init_array_end = .);}}
19253 +
19254 + ${RELOCATING+${CREATE_SHLIB-PROVIDE (__fini_array_start = .);}}
19255 + .fini_array ${RELOCATING-0} : { KEEP (*(.fini_array)) }${RW_REGION}
19256 + ${RELOCATING+${CREATE_SHLIB-PROVIDE (__fini_array_end = .);}}
19257 +
19258 + ${SMALL_DATA_CTOR-${RELOCATING+${CTOR}${RW_REGION}}}
19259 + ${SMALL_DATA_DTOR-${RELOCATING+${DTOR}${RW_REGION}}}
19260 + .jcr ${RELOCATING-0} : { KEEP (*(.jcr)) }${RW_REGION}
19261 +
19262 + ${RELOCATING+${DATARELRO}}
19263 + ${OTHER_RELRO_SECTIONS}
19264 + ${TEXT_DYNAMIC-${DYNAMIC}${RW_REGION}}
19265 + ${NO_SMALL_DATA+${RELRO_NOW+${GOT}${RW_REGION}}}
19266 + ${NO_SMALL_DATA+${RELRO_NOW-${SEPARATE_GOTPLT+${GOT}${RW_REGION}}}}
19267 + ${NO_SMALL_DATA+${RELRO_NOW-${SEPARATE_GOTPLT+${GOTPLT}${RW_REGION}}}}
19268 + ${RELOCATING+${DATA_SEGMENT_RELRO_END}}
19269 + ${NO_SMALL_DATA+${RELRO_NOW-${SEPARATE_GOTPLT-${GOT}${RW_REGION}}}}
19270 +
19271 + ${DATA_PLT+${PLT_BEFORE_GOT-${PLT}${RW_REGION}}}
19272 +
19273 + .data ${RELOCATING-0} :
19274 + {
19275 + ${RELOCATING+${DATA_START_SYMBOLS}}
19276 + *(.data${RELOCATING+ .data.* .gnu.linkonce.d.*})
19277 + KEEP (*(.gnu.linkonce.d.*personality*))
19278 + ${CONSTRUCTING+SORT(CONSTRUCTORS)}
19279 + }${RW_REGION}
19280 + .data1 ${RELOCATING-0} : { *(.data1) }${RW_REGION}
19281 + ${WRITABLE_RODATA+${RODATA}${RW_REGION}}
19282 + ${OTHER_READWRITE_SECTIONS}
19283 + ${SMALL_DATA_CTOR+${RELOCATING+${CTOR}${RW_REGION}}}
19284 + ${SMALL_DATA_DTOR+${RELOCATING+${DTOR}${RW_REGION}}}
19285 + ${DATA_PLT+${PLT_BEFORE_GOT+${PLT}${RW_REGION}}}
19286 + ${RELOCATING+${OTHER_GOT_SYMBOLS}}
19287 + ${NO_SMALL_DATA-${GOT}${RW_REGION}}
19288 + ${OTHER_GOT_SECTIONS}
19289 + ${SDATA}
19290 + ${OTHER_SDATA_SECTIONS}
19291 + ${RELOCATING+${BALIGN}}
19292 + ${RELOCATING+_edata = .;}
19293 + ${RELOCATING+PROVIDE (edata = .);}
19294 + ${RELOCATING+__bss_start = .;}
19295 + ${RELOCATING+${OTHER_BSS_SYMBOLS}}
19296 + ${SBSS}
19297 + ${BSS_PLT+${PLT}${RW_REGION}}
19298 + .bss ${RELOCATING-0} :
19299 + {
19300 + *(.dynbss)
19301 + *(.bss${RELOCATING+ .bss.* .gnu.linkonce.b.*})
19302 + *(COMMON)
19303 + /* Align here to ensure that the .bss section occupies space up to
19304 + _end. Align after .bss to ensure correct alignment even if the
19305 + .bss section disappears because there are no input sections. */
19306 + ${RELOCATING+. = ALIGN(${BSS_ALIGNMENT});}
19307 + }${RW_REGION}
19308 + ${OTHER_BSS_SECTIONS}
19309 + ${RELOCATING+. = ALIGN(${BSS_ALIGNMENT});}
19310 + ${RELOCATING+_end = .;}
19311 + ${RELOCATING+${OTHER_BSS_END_SYMBOLS}}
19312 + ${RELOCATING+PROVIDE (end = .);}
19313 + ${RELOCATING+${DATA_SEGMENT_END}}
19314 +
19315 + /* Stabs debugging sections. */
19316 + .stab 0 : { *(.stab) }
19317 + .stabstr 0 : { *(.stabstr) }
19318 + .stab.excl 0 : { *(.stab.excl) }
19319 + .stab.exclstr 0 : { *(.stab.exclstr) }
19320 + .stab.index 0 : { *(.stab.index) }
19321 + .stab.indexstr 0 : { *(.stab.indexstr) }
19322 +
19323 + .comment 0 : { *(.comment) }
19324 +
19325 + /* DWARF debug sections.
19326 + Symbols in the DWARF debugging sections are relative to the beginning
19327 + of the section so we begin them at 0. */
19328 +
19329 + /* DWARF 1 */
19330 + .debug 0 : { *(.debug) }
19331 + .line 0 : { *(.line) }
19332 +
19333 + /* GNU DWARF 1 extensions */
19334 + .debug_srcinfo 0 : { *(.debug_srcinfo) }
19335 + .debug_sfnames 0 : { *(.debug_sfnames) }
19336 +
19337 + /* DWARF 1.1 and DWARF 2 */
19338 + .debug_aranges 0 : { *(.debug_aranges) }
19339 + .debug_pubnames 0 : { *(.debug_pubnames) }
19340 +
19341 + /* DWARF 2 */
19342 + .debug_info 0 : { *(.debug_info .gnu.linkonce.wi.*) }
19343 + .debug_abbrev 0 : { *(.debug_abbrev) }
19344 + .debug_line 0 : { *(.debug_line) }
19345 + .debug_frame 0 : { *(.debug_frame) }
19346 + .debug_str 0 : { *(.debug_str) }
19347 + .debug_loc 0 : { *(.debug_loc) }
19348 + .debug_macinfo 0 : { *(.debug_macinfo) }
19349 +
19350 + /* SGI/MIPS DWARF 2 extensions */
19351 + .debug_weaknames 0 : { *(.debug_weaknames) }
19352 + .debug_funcnames 0 : { *(.debug_funcnames) }
19353 + .debug_typenames 0 : { *(.debug_typenames) }
19354 + .debug_varnames 0 : { *(.debug_varnames) }
19355 +
19356 + ${STACK_ADDR+${STACK}}
19357 + ${OTHER_SECTIONS}
19358 + ${RELOCATING+${OTHER_END_SYMBOLS}}
19359 + ${RELOCATING+${STACKNOTE}}
19360 +}
19361 +EOF
19362 --- /dev/null
19363 +++ b/ld/testsuite/ld-avr32/avr32.exp
19364 @@ -0,0 +1,25 @@
19365 +# Expect script for AVR32 ELF linker tests.
19366 +# Copyright 2004-2006 Atmel Corporation.
19367 +#
19368 +# This file is free software; you can redistribute it and/or modify
19369 +# it under the terms of the GNU General Public License as published by
19370 +# the Free Software Foundation; either version 2 of the License, or
19371 +# (at your option) any later version.
19372 +#
19373 +# This program is distributed in the hope that it will be useful,
19374 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
19375 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19376 +# GNU General Public License for more details.
19377 +#
19378 +# You should have received a copy of the GNU General Public License
19379 +# along with this program; if not, write to the Free Software
19380 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
19381 +#
19382 +# Written by Haavard Skinnemoen (hskinnemoen@atmel.com)
19383 +#
19384 +
19385 +if ![istarget avr32-*-*] {
19386 + return
19387 +}
19388 +
19389 +run_dump_test "pcrel"
19390 --- /dev/null
19391 +++ b/ld/testsuite/ld-avr32/pcrel.d
19392 @@ -0,0 +1,74 @@
19393 +#name: AVR32 ELF PC-relative external relocs
19394 +#source: symbols.s
19395 +#source: ../../../gas/testsuite/gas/avr32/pcrel.s
19396 +#ld: -T $srcdir/$subdir/pcrel.ld
19397 +#objdump: -d
19398 +
19399 +.*: file format elf.*avr32.*
19400 +
19401 +Disassembly of section .text:
19402 +
19403 +a0000000 <_start>:
19404 +a0000000: d7 03 nop
19405 +a0000002: d7 03 nop
19406 +
19407 +a0000004 <test_rjmp>:
19408 +a0000004: d7 03 nop
19409 +a0000006: c0 28 rjmp a000000a <test_rjmp\+0x6>
19410 +a0000008: d7 03 nop
19411 +a000000a: e0 8f 01 fb bral a0000400 <extsym10>
19412 +
19413 +a000000e <test_rcall>:
19414 +a000000e: d7 03 nop
19415 +a0000010 <test_rcall2>:
19416 +a0000010: c0 2c rcall a0000014 <test_rcall2\+0x4>
19417 +a0000012: d7 03 nop
19418 +a0000014: ee b0 ff f6 rcall a0200000 <extsym21>
19419 +
19420 +a0000018 <test_branch>:
19421 +a0000018: c0 31 brne a000001e <test_branch\+0x6>
19422 +a000001a: fe 9f ff ff bral a0000018 <test_branch>
19423 +a000001e: ee 90 ff f1 breq a0200000 <extsym21>
19424 +
19425 +a0000022 <test_lddpc>:
19426 +a0000022: 48 30 lddpc r0,a000002c <sym1>
19427 +a0000024: 48 20 lddpc r0,a000002c <sym1>
19428 +a0000026: fe f0 7f da ld.w r0,pc\[32730\]
19429 + ...
19430 +
19431 +a000002c <sym1>:
19432 +a000002c: d7 03 nop
19433 +a000002e: d7 03 nop
19434 +
19435 +a0000030 <test_local>:
19436 +a0000030: 48 20 lddpc r0,a0000038 <test_local\+0x8>
19437 +a0000032: 48 30 lddpc r0,a000003c <test_local\+0xc>
19438 +a0000034: 48 20 lddpc r0,a000003c <test_local\+0xc>
19439 +a0000036: 00 00 add r0,r0
19440 +a0000038: d7 03 nop
19441 +a000003a: d7 03 nop
19442 +a000003c: d7 03 nop
19443 +a000003e: d7 03 nop
19444 +
19445 +Disassembly of section \.text\.init:
19446 +a0000040 <test_inter_section>:
19447 +a0000040: fe b0 ff e7 rcall a000000e <test_rcall>
19448 +a0000044: d7 03 nop
19449 +a0000046: fe b0 ff e4 rcall a000000e <test_rcall>
19450 +a000004a: fe b0 ff e3 rcall a0000010 <test_rcall2>
19451 +a000004e: d7 03 nop
19452 +a0000050: fe b0 ff e0 rcall a0000010 <test_rcall2>
19453 +
19454 +Disassembly of section \.text\.pcrel10:
19455 +
19456 +a0000400 <extsym10>:
19457 +a0000400: d7 03 nop
19458 +
19459 +Disassembly of section \.text\.pcrel16:
19460 +
19461 +a0008000 <extsym16>:
19462 +a0008000: d7 03 nop
19463 +
19464 +Disassembly of section \.text\.pcrel21:
19465 +a0200000 <extsym21>:
19466 +a0200000: d7 03 nop
19467 --- /dev/null
19468 +++ b/ld/testsuite/ld-avr32/pcrel.ld
19469 @@ -0,0 +1,23 @@
19470 +ENTRY(_start)
19471 +SECTIONS
19472 +{
19473 + .text 0xa0000000:
19474 + {
19475 + *(.text)
19476 + }
19477 +
19478 + .text.pcrel10 0xa0000400:
19479 + {
19480 + *(.text.pcrel10)
19481 + }
19482 +
19483 + .text.pcrel16 0xa0008000:
19484 + {
19485 + *(.text.pcrel16)
19486 + }
19487 +
19488 + .text.pcrel21 0xa0200000:
19489 + {
19490 + *(.text.pcrel21)
19491 + }
19492 +}
19493 --- /dev/null
19494 +++ b/ld/testsuite/ld-avr32/symbols.s
19495 @@ -0,0 +1,20 @@
19496 + .text
19497 + .global _start
19498 +_start:
19499 + nop
19500 + nop
19501 +
19502 + .section .text.pcrel10,"ax"
19503 + .global extsym10
19504 +extsym10:
19505 + nop
19506 +
19507 + .section .text.pcrel16,"ax"
19508 + .global extsym16
19509 +extsym16:
19510 + nop
19511 +
19512 + .section .text.pcrel21,"ax"
19513 + .global extsym21
19514 +extsym21:
19515 + nop
19516 --- /dev/null
19517 +++ b/opcodes/avr32-asm.c
19518 @@ -0,0 +1,264 @@
19519 +/* Assembler interface for AVR32.
19520 + Copyright 2005, 2006 Atmel Corporation.
19521 +
19522 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
19523 +
19524 + This file is part of libopcodes.
19525 +
19526 + This program is free software; you can redistribute it and/or
19527 + modify it under the terms of the GNU General Public License as
19528 + published by the Free Software Foundation; either version 2 of the
19529 + License, or (at your option) any later version.
19530 +
19531 + This program is distributed in the hope that it will be useful, but
19532 + WITHOUT ANY WARRANTY; without even the implied warranty of
19533 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19534 + General Public License for more details.
19535 +
19536 + You should have received a copy of the GNU General Public License
19537 + along with this program; if not, write to the Free Software
19538 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
19539 + 02111-1307, USA. */
19540 +
19541 +#include <string.h>
19542 +
19543 +#include "avr32-opc.h"
19544 +#include "avr32-asm.h"
19545 +
19546 +/* Structure for a register hash table entry. */
19547 +struct reg_entry
19548 +{
19549 + const char *name;
19550 + int number;
19551 +};
19552 +
19553 +/* Integer Registers. */
19554 +static const struct reg_entry reg_table[] =
19555 + {
19556 + /* Primary names (used by the disassembler) */
19557 + { "r0", 0 }, { "r1", 1 }, { "r2", 2 }, { "r3", 3 },
19558 + { "r4", 4 }, { "r5", 5 }, { "r6", 6 }, { "r7", 7 },
19559 + { "r8", 8 }, { "r9", 9 }, { "r10", 10 }, { "r11", 11 },
19560 + { "r12", 12 }, { "sp", 13 }, { "lr", 14 }, { "pc", 15 },
19561 + /* Alternatives to sp, lr and pc. */
19562 + { "r13", 13 }, { "r14", 14 }, { "r15", 15 },
19563 + };
19564 +#define AVR32_NR_INTREGS (sizeof(reg_table)/sizeof(reg_table[0]))
19565 +
19566 +/* Coprocessor Registers. */
19567 +static const struct reg_entry cr_table[] =
19568 + {
19569 + { "cr0", 0 }, { "cr1", 1 }, { "cr2", 2 }, { "cr3", 3 },
19570 + { "cr4", 4 }, { "cr5", 5 }, { "cr6", 6 }, { "cr7", 7 },
19571 + { "cr8", 8 }, { "cr9", 9 }, { "cr10", 10 }, { "cr11", 11 },
19572 + { "cr12", 12 }, { "cr13", 13 }, { "cr14", 14 }, { "cr15", 15 },
19573 + };
19574 +#define AVR32_NR_CPREGS (sizeof(cr_table)/sizeof(cr_table[0]))
19575 +
19576 +/* Floating-point Registers. */
19577 +static const struct reg_entry fr_table[] =
19578 + {
19579 + { "fr0", 0 }, { "fr1", 1 }, { "fr2", 2 }, { "fr3", 3 },
19580 + { "fr4", 4 }, { "fr5", 5 }, { "fr6", 6 }, { "fr7", 7 },
19581 + { "fr8", 8 }, { "fr9", 9 }, { "fr10", 10 }, { "fr11", 11 },
19582 + { "fr12", 12 }, { "fr13", 13 }, { "fr14", 14 }, { "fr15", 15 },
19583 + };
19584 +#define AVR32_NR_FPREGS (sizeof(fr_table)/sizeof(fr_table[0]))
19585 +
19586 +/* PiCo Registers. */
19587 +static const struct reg_entry pico_table[] =
19588 + {
19589 + { "inpix2", 0 }, { "inpix1", 1 }, { "inpix0", 2 },
19590 + { "outpix2", 3 }, { "outpix1", 4 }, { "outpix0", 5 },
19591 + { "coeff0_a", 6 }, { "coeff0_b", 7 }, { "coeff1_a", 8 },
19592 + { "coeff1_b", 9 }, { "coeff2_a", 10 }, { "coeff2_b", 11 },
19593 + { "vmu0_out", 12 }, { "vmu1_out", 13 }, { "vmu2_out", 14 },
19594 + { "config", 15 },
19595 + };
19596 +#define AVR32_NR_PICOREGS (sizeof(pico_table)/sizeof(pico_table[0]))
19597 +
19598 +int
19599 +avr32_parse_intreg(const char *str)
19600 +{
19601 + unsigned int i;
19602 +
19603 + for (i = 0; i < AVR32_NR_INTREGS; i++)
19604 + {
19605 + if (strcasecmp(reg_table[i].name, str) == 0)
19606 + return reg_table[i].number;
19607 + }
19608 +
19609 + return -1;
19610 +}
19611 +
19612 +int
19613 +avr32_parse_cpreg(const char *str)
19614 +{
19615 + unsigned int i;
19616 +
19617 + for (i = 0; i < AVR32_NR_CPREGS; i++)
19618 + {
19619 + if (strcasecmp(cr_table[i].name, str) == 0)
19620 + return cr_table[i].number;
19621 + }
19622 +
19623 + return -1;
19624 +}
19625 +
19626 +int avr32_parse_fpreg(const char *str)
19627 +{
19628 + unsigned int i;
19629 +
19630 + for (i = 0; i < AVR32_NR_FPREGS; i++)
19631 + {
19632 + if (strcasecmp(fr_table[i].name, str) == 0)
19633 + return fr_table[i].number;
19634 + }
19635 +
19636 + return -1;
19637 +}
19638 +
19639 +int avr32_parse_picoreg(const char *str)
19640 +{
19641 + unsigned int i;
19642 +
19643 + for (i = 0; i < AVR32_NR_PICOREGS; i++)
19644 + {
19645 + if (strcasecmp(pico_table[i].name, str) == 0)
19646 + return pico_table[i].number;
19647 + }
19648 +
19649 + return -1;
19650 +}
19651 +
19652 +static unsigned long
19653 +parse_reglist(char *str, char **endptr, int (*parse_reg)(const char *))
19654 +{
19655 + int reg_from, reg_to;
19656 + unsigned long result = 0;
19657 + char *p1, *p2, c;
19658 +
19659 + while (*str)
19660 + {
19661 + for (p1 = str; *p1; p1++)
19662 + if (*p1 == ',' || *p1 == '-')
19663 + break;
19664 +
19665 + c = *p1, *p1 = 0;
19666 + reg_from = parse_reg(str);
19667 + *p1 = c;
19668 +
19669 + if (reg_from < 0)
19670 + break;
19671 +
19672 + if (*p1 == '-')
19673 + {
19674 + for (p2 = ++p1; *p2; p2++)
19675 + if (*p2 == ',')
19676 + break;
19677 +
19678 + c = *p2, *p2 = 0;
19679 + /* printf("going to parse reg_to from `%s'\n", p1); */
19680 + reg_to = parse_reg(p1);
19681 + *p2 = c;
19682 +
19683 + if (reg_to < 0)
19684 + break;
19685 +
19686 + while (reg_from <= reg_to)
19687 + result |= (1 << reg_from++);
19688 + p1 = p2;
19689 + }
19690 + else
19691 + result |= (1 << reg_from);
19692 +
19693 + str = p1;
19694 + if (*str) ++str;
19695 + }
19696 +
19697 + if (endptr)
19698 + *endptr = str;
19699 +
19700 + return result;
19701 +}
19702 +
19703 +unsigned long
19704 +avr32_parse_reglist(char *str, char **endptr)
19705 +{
19706 + return parse_reglist(str, endptr, avr32_parse_intreg);
19707 +}
19708 +
19709 +unsigned long
19710 +avr32_parse_cpreglist(char *str, char **endptr)
19711 +{
19712 + return parse_reglist(str, endptr, avr32_parse_cpreg);
19713 +}
19714 +
19715 +unsigned long
19716 +avr32_parse_pico_reglist(char *str, char **endptr)
19717 +{
19718 + return parse_reglist(str, endptr, avr32_parse_picoreg);
19719 +}
19720 +
19721 +int
19722 +avr32_make_regmask8(unsigned long regmask16, unsigned long *regmask8)
19723 +{
19724 + unsigned long result = 0;
19725 +
19726 + /* printf("convert regmask16 0x%04lx\n", regmask16); */
19727 +
19728 + if (regmask16 & 0xf)
19729 + {
19730 + if ((regmask16 & 0xf) == 0xf)
19731 + result |= 1 << 0;
19732 + else
19733 + return -1;
19734 + }
19735 + if (regmask16 & 0xf0)
19736 + {
19737 + if ((regmask16 & 0xf0) == 0xf0)
19738 + result |= 1 << 1;
19739 + else
19740 + return -1;
19741 + }
19742 + if (regmask16 & 0x300)
19743 + {
19744 + if ((regmask16 & 0x300) == 0x300)
19745 + result |= 1 << 2;
19746 + else
19747 + return -1;
19748 + }
19749 + if (regmask16 & (1 << 13))
19750 + return -1;
19751 +
19752 + if (regmask16 & (1 << 10))
19753 + result |= 1 << 3;
19754 + if (regmask16 & (1 << 11))
19755 + result |= 1 << 4;
19756 + if (regmask16 & (1 << 12))
19757 + result |= 1 << 5;
19758 + if (regmask16 & (1 << 14))
19759 + result |= 1 << 6;
19760 + if (regmask16 & (1 << 15))
19761 + result |= 1 << 7;
19762 +
19763 + *regmask8 = result;
19764 +
19765 + return 0;
19766 +}
19767 +
19768 +#if 0
19769 +struct reg_map
19770 +{
19771 + const struct reg_entry *names;
19772 + int nr_regs;
19773 + struct hash_control *htab;
19774 + const char *errmsg;
19775 +};
19776 +
19777 +struct reg_map all_reg_maps[] =
19778 + {
19779 + { reg_table, AVR32_NR_INTREGS, NULL, N_("integral register expected") },
19780 + { cr_table, AVR32_NR_CPREGS, NULL, N_("coprocessor register expected") },
19781 + };
19782 +#endif
19783 --- /dev/null
19784 +++ b/opcodes/avr32-asm.h
19785 @@ -0,0 +1,42 @@
19786 +/* Assembler interface for AVR32.
19787 + Copyright 2005, 2006 Atmel Corporation.
19788 +
19789 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
19790 +
19791 + This file is part of libopcodes.
19792 +
19793 + This program is free software; you can redistribute it and/or
19794 + modify it under the terms of the GNU General Public License as
19795 + published by the Free Software Foundation; either version 2 of the
19796 + License, or (at your option) any later version.
19797 +
19798 + This program is distributed in the hope that it will be useful, but
19799 + WITHOUT ANY WARRANTY; without even the implied warranty of
19800 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19801 + General Public License for more details.
19802 +
19803 + You should have received a copy of the GNU General Public License
19804 + along with this program; if not, write to the Free Software
19805 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
19806 + 02111-1307, USA. */
19807 +#ifndef __OPCODES_AVR32_ASM_H
19808 +#define __OPCODES_AVR32_ASM_H
19809 +
19810 +extern int
19811 +avr32_parse_intreg(const char *str);
19812 +extern int
19813 +avr32_parse_cpreg(const char *str);
19814 +extern int
19815 +avr32_parse_fpreg(const char *str);
19816 +extern int
19817 +avr32_parse_picoreg(const char *str);
19818 +extern unsigned long
19819 +avr32_parse_reglist(char *str, char **endptr);
19820 +extern unsigned long
19821 +avr32_parse_cpreglist(char *str, char **endptr);
19822 +extern unsigned long
19823 +avr32_parse_pico_reglist(char *str, char **endptr);
19824 +extern int
19825 +avr32_make_regmask8(unsigned long regmask16, unsigned long *regmask8);
19826 +
19827 +#endif /* __OPCODES_AVR32_ASM_H */
19828 --- /dev/null
19829 +++ b/opcodes/avr32-dis.c
19830 @@ -0,0 +1,891 @@
19831 +/* Print AVR32 instructions for GDB and objdump.
19832 + Copyright 2005, 2006 Atmel Corporation.
19833 +
19834 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
19835 +
19836 + This file is part of libopcodes.
19837 +
19838 + This program is free software; you can redistribute it and/or
19839 + modify it under the terms of the GNU General Public License as
19840 + published by the Free Software Foundation; either version 2 of the
19841 + License, or (at your option) any later version.
19842 +
19843 + This program is distributed in the hope that it will be useful, but
19844 + WITHOUT ANY WARRANTY; without even the implied warranty of
19845 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19846 + General Public License for more details.
19847 +
19848 + You should have received a copy of the GNU General Public License
19849 + along with this program; if not, write to the Free Software
19850 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
19851 + 02111-1307, USA. */
19852 +
19853 +#include "sysdep.h"
19854 +#include "dis-asm.h"
19855 +#include "avr32-opc.h"
19856 +#include "opintl.h"
19857 +#include "safe-ctype.h"
19858 +
19859 +/* TODO: Share this with -asm */
19860 +
19861 +/* Structure for a register hash table entry. */
19862 +struct reg_entry
19863 +{
19864 + const char *name;
19865 + int number;
19866 +};
19867 +
19868 +#ifndef strneq
19869 +#define strneq(a,b,n) (strncmp ((a), (b), (n)) == 0)
19870 +#endif
19871 +
19872 +
19873 +static const struct reg_entry reg_table[] =
19874 + {
19875 + /* Primary names (used by the disassembler) */
19876 + { "r0", 0 }, { "r1", 1 }, { "r2", 2 }, { "r3", 3 },
19877 + { "r4", 4 }, { "r5", 5 }, { "r6", 6 }, { "r7", 7 },
19878 + { "r8", 8 }, { "r9", 9 }, { "r10", 10 }, { "r11", 11 },
19879 + { "r12", 12 }, { "sp", 13 }, { "lr", 14 }, { "pc", 15 },
19880 + /* Alternatives to sp, lr and pc. */
19881 + { "r13", 13 }, { "r14", 14 }, { "r15", 15 },
19882 + };
19883 +#define AVR32_NR_INTREGS (sizeof(reg_table)/sizeof(reg_table[0]))
19884 +
19885 +/* Coprocessor Registers. */
19886 +static const struct reg_entry cr_table[] =
19887 + {
19888 + { "cr0", 0 }, { "cr1", 1 }, { "cr2", 2 }, { "cr3", 3 },
19889 + { "cr4", 4 }, { "cr5", 5 }, { "cr6", 6 }, { "cr7", 7 },
19890 + { "cr8", 8 }, { "cr9", 9 }, { "cr10", 10 }, { "cr11", 11 },
19891 + { "cr12", 12 }, { "cr13", 13 }, { "cr14", 14 }, { "cr15", 15 },
19892 + };
19893 +#define AVR32_NR_CPREGS (sizeof(cr_table)/sizeof(cr_table[0]))
19894 +
19895 +static const char bparts[4] = { 'b', 'l', 'u', 't' };
19896 +static bfd_vma current_pc;
19897 +
19898 +struct avr32_field_value
19899 +{
19900 + const struct avr32_ifield *ifield;
19901 + unsigned long value;
19902 +};
19903 +
19904 +struct avr32_operand
19905 +{
19906 + int id;
19907 + int is_pcrel;
19908 + int align_order;
19909 + int (*print)(struct avr32_operand *op, struct disassemble_info *info,
19910 + struct avr32_field_value *ifields);
19911 +};
19912 +
19913 +static signed long
19914 +get_signed_value(const struct avr32_field_value *fv)
19915 +{
19916 + signed long value = fv->value;
19917 +
19918 + if (fv->value & (1 << (fv->ifield->bitsize - 1)))
19919 + value |= (~0UL << fv->ifield->bitsize);
19920 +
19921 + return value;
19922 +}
19923 +
19924 +static void
19925 +print_reglist_range(unsigned int first, unsigned int last,
19926 + const struct reg_entry *reg_names,
19927 + int need_comma,
19928 + struct disassemble_info *info)
19929 +{
19930 + if (need_comma)
19931 + info->fprintf_func(info->stream, ",");
19932 +
19933 + if (first == last)
19934 + info->fprintf_func(info->stream, "%s",
19935 + reg_names[first].name);
19936 + else
19937 + info->fprintf_func(info->stream, "%s-%s",
19938 + reg_names[first].name, reg_names[last].name);
19939 +}
19940 +
19941 +static int
19942 +print_intreg(struct avr32_operand *op,
19943 + struct disassemble_info *info,
19944 + struct avr32_field_value *ifields)
19945 +{
19946 + unsigned long regid = ifields[0].value << op->align_order;
19947 +
19948 + info->fprintf_func(info->stream, "%s",
19949 + reg_table[regid].name);
19950 + return 1;
19951 +}
19952 +
19953 +static int
19954 +print_intreg_predec(struct avr32_operand *op ATTRIBUTE_UNUSED,
19955 + struct disassemble_info *info,
19956 + struct avr32_field_value *ifields)
19957 +{
19958 + info->fprintf_func(info->stream, "--%s",
19959 + reg_table[ifields[0].value].name);
19960 + return 1;
19961 +}
19962 +
19963 +static int
19964 +print_intreg_postinc(struct avr32_operand *op ATTRIBUTE_UNUSED,
19965 + struct disassemble_info *info,
19966 + struct avr32_field_value *ifields)
19967 +{
19968 + info->fprintf_func(info->stream, "%s++",
19969 + reg_table[ifields[0].value].name);
19970 + return 1;
19971 +}
19972 +
19973 +static int
19974 +print_intreg_lsl(struct avr32_operand *op ATTRIBUTE_UNUSED,
19975 + struct disassemble_info *info,
19976 + struct avr32_field_value *ifields)
19977 +{
19978 + const char *rp = reg_table[ifields[0].value].name;
19979 + unsigned long sa = ifields[1].value;
19980 +
19981 + if (sa)
19982 + info->fprintf_func(info->stream, "%s<<0x%lx", rp, sa);
19983 + else
19984 + info->fprintf_func(info->stream, "%s", rp);
19985 +
19986 + return 2;
19987 +}
19988 +
19989 +static int
19990 +print_intreg_lsr(struct avr32_operand *op ATTRIBUTE_UNUSED,
19991 + struct disassemble_info *info,
19992 + struct avr32_field_value *ifields)
19993 +{
19994 + const char *rp = reg_table[ifields[0].value].name;
19995 + unsigned long sa = ifields[1].value;
19996 +
19997 + if (sa)
19998 + info->fprintf_func(info->stream, "%s>>0x%lx", rp, sa);
19999 + else
20000 + info->fprintf_func(info->stream, "%s", rp);
20001 +
20002 + return 2;
20003 +}
20004 +
20005 +static int
20006 +print_intreg_bpart(struct avr32_operand *op ATTRIBUTE_UNUSED,
20007 + struct disassemble_info *info,
20008 + struct avr32_field_value *ifields)
20009 +{
20010 + info->fprintf_func(info->stream, "%s:%c",
20011 + reg_table[ifields[0].value].name,
20012 + bparts[ifields[1].value]);
20013 + return 2;
20014 +}
20015 +
20016 +static int
20017 +print_intreg_hpart(struct avr32_operand *op ATTRIBUTE_UNUSED,
20018 + struct disassemble_info *info,
20019 + struct avr32_field_value *ifields)
20020 +{
20021 + info->fprintf_func(info->stream, "%s:%c",
20022 + reg_table[ifields[0].value].name,
20023 + ifields[1].value ? 't' : 'b');
20024 + return 2;
20025 +}
20026 +
20027 +static int
20028 +print_intreg_sdisp(struct avr32_operand *op,
20029 + struct disassemble_info *info,
20030 + struct avr32_field_value *ifields)
20031 +{
20032 + signed long disp;
20033 +
20034 + disp = get_signed_value(&ifields[1]) << op->align_order;
20035 +
20036 + info->fprintf_func(info->stream, "%s[%ld]",
20037 + reg_table[ifields[0].value].name, disp);
20038 + return 2;
20039 +}
20040 +
20041 +static int
20042 +print_intreg_udisp(struct avr32_operand *op,
20043 + struct disassemble_info *info,
20044 + struct avr32_field_value *ifields)
20045 +{
20046 + info->fprintf_func(info->stream, "%s[0x%lx]",
20047 + reg_table[ifields[0].value].name,
20048 + ifields[1].value << op->align_order);
20049 + return 2;
20050 +}
20051 +
20052 +static int
20053 +print_intreg_index(struct avr32_operand *op ATTRIBUTE_UNUSED,
20054 + struct disassemble_info *info,
20055 + struct avr32_field_value *ifields)
20056 +{
20057 + const char *rb, *ri;
20058 + unsigned long sa = ifields[2].value;
20059 +
20060 + rb = reg_table[ifields[0].value].name;
20061 + ri = reg_table[ifields[1].value].name;
20062 +
20063 + if (sa)
20064 + info->fprintf_func(info->stream, "%s[%s<<0x%lx]", rb, ri, sa);
20065 + else
20066 + info->fprintf_func(info->stream, "%s[%s]", rb, ri);
20067 +
20068 + return 3;
20069 +}
20070 +
20071 +static int
20072 +print_intreg_xindex(struct avr32_operand *op ATTRIBUTE_UNUSED,
20073 + struct disassemble_info *info,
20074 + struct avr32_field_value *ifields)
20075 +{
20076 + info->fprintf_func(info->stream, "%s[%s:%c<<2]",
20077 + reg_table[ifields[0].value].name,
20078 + reg_table[ifields[1].value].name,
20079 + bparts[ifields[2].value]);
20080 + return 3;
20081 +}
20082 +
20083 +static int
20084 +print_jmplabel(struct avr32_operand *op,
20085 + struct disassemble_info *info,
20086 + struct avr32_field_value *ifields)
20087 +{
20088 + bfd_vma address, offset;
20089 +
20090 + offset = get_signed_value(ifields) << op->align_order;
20091 + address = (current_pc & (~0UL << op->align_order)) + offset;
20092 +
20093 + info->print_address_func(address, info);
20094 +
20095 + return 1;
20096 +}
20097 +
20098 +static int
20099 +print_pc_disp(struct avr32_operand *op,
20100 + struct disassemble_info *info,
20101 + struct avr32_field_value *ifields)
20102 +{
20103 + bfd_vma address, offset;
20104 +
20105 + offset = ifields[0].value << op->align_order;
20106 + address = (current_pc & (~0UL << op->align_order)) + offset;
20107 +
20108 + info->print_address_func(address, info);
20109 +
20110 + return 1;
20111 +}
20112 +
20113 +static int
20114 +print_sp(struct avr32_operand *op ATTRIBUTE_UNUSED,
20115 + struct disassemble_info *info,
20116 + struct avr32_field_value *ifields ATTRIBUTE_UNUSED)
20117 +{
20118 + info->fprintf_func(info->stream, "sp");
20119 + return 1;
20120 +}
20121 +
20122 +static int
20123 +print_sp_disp(struct avr32_operand *op,
20124 + struct disassemble_info *info,
20125 + struct avr32_field_value *ifields)
20126 +{
20127 + info->fprintf_func(info->stream, "sp[0x%lx]",
20128 + ifields[0].value << op->align_order);
20129 + return 1;
20130 +}
20131 +
20132 +static int
20133 +print_cpno(struct avr32_operand *op ATTRIBUTE_UNUSED,
20134 + struct disassemble_info *info,
20135 + struct avr32_field_value *ifields)
20136 +{
20137 + info->fprintf_func(info->stream, "cp%lu", ifields[0].value);
20138 + return 1;
20139 +}
20140 +
20141 +static int
20142 +print_cpreg(struct avr32_operand *op,
20143 + struct disassemble_info *info,
20144 + struct avr32_field_value *ifields)
20145 +{
20146 + info->fprintf_func(info->stream, "cr%lu",
20147 + ifields[0].value << op->align_order);
20148 + return 1;
20149 +}
20150 +
20151 +static int
20152 +print_uconst(struct avr32_operand *op,
20153 + struct disassemble_info *info,
20154 + struct avr32_field_value *ifields)
20155 +{
20156 + info->fprintf_func(info->stream, "0x%lx",
20157 + ifields[0].value << op->align_order);
20158 + return 1;
20159 +}
20160 +
20161 +static int
20162 +print_sconst(struct avr32_operand *op,
20163 + struct disassemble_info *info,
20164 + struct avr32_field_value *ifields)
20165 +{
20166 + info->fprintf_func(info->stream, "%ld",
20167 + get_signed_value(ifields) << op->align_order);
20168 + return 1;
20169 +}
20170 +
20171 +static int
20172 +print_reglist8_head(unsigned long regmask, int *commap,
20173 + struct disassemble_info *info)
20174 +{
20175 + int first = -1, last, i = 0;
20176 + int need_comma = 0;
20177 +
20178 + while (i < 12)
20179 + {
20180 + if (first == -1 && (regmask & 1))
20181 + {
20182 + first = i;
20183 + }
20184 + else if (first != -1 && !(regmask & 1))
20185 + {
20186 + last = i - 1;
20187 +
20188 + print_reglist_range(first, last, reg_table, need_comma, info);
20189 + need_comma = 1;
20190 + first = -1;
20191 + }
20192 +
20193 + if (i < 8)
20194 + i += 4;
20195 + else if (i < 10)
20196 + i += 2;
20197 + else
20198 + i++;
20199 + regmask >>= 1;
20200 + }
20201 +
20202 + *commap = need_comma;
20203 + return first;
20204 +}
20205 +
20206 +static void
20207 +print_reglist8_tail(unsigned long regmask, int first, int need_comma,
20208 + struct disassemble_info *info)
20209 +{
20210 + int last = 11;
20211 +
20212 + if (regmask & 0x20)
20213 + {
20214 + if (first == -1)
20215 + first = 12;
20216 + last = 12;
20217 + }
20218 +
20219 + if (first != -1)
20220 + {
20221 + print_reglist_range(first, last, reg_table, need_comma, info);
20222 + need_comma = 1;
20223 + first = -1;
20224 + }
20225 +
20226 + if (regmask & 0x40)
20227 + {
20228 + if (first == -1)
20229 + first = 14;
20230 + last = 14;
20231 + }
20232 +
20233 + if (regmask & 0x80)
20234 + {
20235 + if (first == -1)
20236 + first = 15;
20237 + last = 15;
20238 + }
20239 +
20240 + if (first != -1)
20241 + print_reglist_range(first, last, reg_table, need_comma, info);
20242 +}
20243 +
20244 +static int
20245 +print_reglist8(struct avr32_operand *op ATTRIBUTE_UNUSED,
20246 + struct disassemble_info *info,
20247 + struct avr32_field_value *ifields)
20248 +{
20249 + unsigned long regmask = ifields[0].value;
20250 + int first, need_comma;
20251 +
20252 + first = print_reglist8_head(regmask, &need_comma, info);
20253 + print_reglist8_tail(regmask, first, need_comma, info);
20254 +
20255 + return 1;
20256 +}
20257 +
20258 +static int
20259 +print_reglist9(struct avr32_operand *op ATTRIBUTE_UNUSED,
20260 + struct disassemble_info *info,
20261 + struct avr32_field_value *ifields)
20262 +{
20263 + unsigned long regmask = ifields[0].value >> 1;
20264 + int first, last, need_comma;
20265 +
20266 + first = print_reglist8_head(regmask, &need_comma, info);
20267 +
20268 + if ((ifields[0].value & 0x101) == 0x101)
20269 + {
20270 + if (first != -1)
20271 + {
20272 + last = 11;
20273 +
20274 + print_reglist_range(first, last, reg_table, need_comma, info);
20275 + need_comma = 1;
20276 + first = -1;
20277 + }
20278 +
20279 + print_reglist_range(15, 15, reg_table, need_comma, info);
20280 +
20281 + regmask >>= 5;
20282 +
20283 + if ((regmask & 3) == 0)
20284 + info->fprintf_func(info->stream, ",r12=0");
20285 + else if ((regmask & 3) == 1)
20286 + info->fprintf_func(info->stream, ",r12=1");
20287 + else
20288 + info->fprintf_func(info->stream, ",r12=-1");
20289 + }
20290 + else
20291 + print_reglist8_tail(regmask, first, need_comma, info);
20292 +
20293 + return 1;
20294 +}
20295 +
20296 +static int
20297 +print_reglist16(struct avr32_operand *op ATTRIBUTE_UNUSED,
20298 + struct disassemble_info *info,
20299 + struct avr32_field_value *ifields)
20300 +{
20301 + unsigned long regmask = ifields[0].value;
20302 + unsigned int i = 0, first, last;
20303 + int need_comma = 0;
20304 +
20305 + while (i < 16)
20306 + {
20307 + if (regmask & 1)
20308 + {
20309 + first = i;
20310 + while (i < 16)
20311 + {
20312 + i++;
20313 + regmask >>= 1;
20314 + if (!(regmask & 1))
20315 + break;
20316 + }
20317 + last = i - 1;
20318 + print_reglist_range(first, last, reg_table, need_comma, info);
20319 + need_comma = 1;
20320 + }
20321 + else
20322 + {
20323 + i++;
20324 + regmask >>= 1;
20325 + }
20326 + }
20327 +
20328 + return 1;
20329 +}
20330 +
20331 +static int
20332 +print_reglist_ldm(struct avr32_operand *op,
20333 + struct disassemble_info *info,
20334 + struct avr32_field_value *ifields)
20335 +{
20336 + int rp, w_bit;
20337 + int i, first, last;
20338 + unsigned long regmask;
20339 +
20340 + rp = ifields[0].value;
20341 + w_bit = ifields[1].value;
20342 + regmask = ifields[2].value;
20343 +
20344 + if (regmask & (1 << AVR32_REG_PC) && rp == AVR32_REG_PC)
20345 + {
20346 + if (w_bit)
20347 + info->fprintf_func(info->stream, "sp++");
20348 + else
20349 + info->fprintf_func(info->stream, "sp");
20350 +
20351 + for (i = 0; i < 12; )
20352 + {
20353 + if (regmask & (1 << i))
20354 + {
20355 + first = i;
20356 + while (i < 12)
20357 + {
20358 + i++;
20359 + if (!(regmask & (1 << i)))
20360 + break;
20361 + }
20362 + last = i - 1;
20363 + print_reglist_range(first, last, reg_table, 1, info);
20364 + }
20365 + else
20366 + i++;
20367 + }
20368 +
20369 + info->fprintf_func(info->stream, ",pc");
20370 + if (regmask & (1 << AVR32_REG_LR))
20371 + info->fprintf_func(info->stream, ",r12=-1");
20372 + else if (regmask & (1 << AVR32_REG_R12))
20373 + info->fprintf_func(info->stream, ",r12=1");
20374 + else
20375 + info->fprintf_func(info->stream, ",r12=0");
20376 + }
20377 + else
20378 + {
20379 + if (w_bit)
20380 + info->fprintf_func(info->stream, "%s++,", reg_table[rp].name);
20381 + else
20382 + info->fprintf_func(info->stream, "%s,", reg_table[rp].name);
20383 +
20384 + print_reglist16(op, info, ifields + 2);
20385 + }
20386 +
20387 + return 3;
20388 +}
20389 +
20390 +static int
20391 +print_reglist_cp8(struct avr32_operand *op ATTRIBUTE_UNUSED,
20392 + struct disassemble_info *info,
20393 + struct avr32_field_value *ifields)
20394 +{
20395 + unsigned long regmask = ifields[0].value;
20396 + unsigned int i = 0, first, last, offset = 0;
20397 + int need_comma = 0;
20398 +
20399 + if (ifields[1].value)
20400 + offset = 8;
20401 +
20402 + while (i < 8)
20403 + {
20404 + if (regmask & 1)
20405 + {
20406 + first = i;
20407 + while (i < 8)
20408 + {
20409 + i++;
20410 + regmask >>= 1;
20411 + if (!(regmask & 1))
20412 + break;
20413 + }
20414 + last = i - 1;
20415 + print_reglist_range(offset + first, offset + last,
20416 + cr_table, need_comma, info);
20417 + need_comma = 1;
20418 + }
20419 + else
20420 + {
20421 + i++;
20422 + regmask >>= 1;
20423 + }
20424 + }
20425 +
20426 + return 2;
20427 +}
20428 +
20429 +static int
20430 +print_reglist_cpd8(struct avr32_operand *op ATTRIBUTE_UNUSED,
20431 + struct disassemble_info *info,
20432 + struct avr32_field_value *ifields)
20433 +{
20434 + unsigned long regmask = ifields[0].value;
20435 + unsigned int i = 0, first, last;
20436 + int need_comma = 0;
20437 +
20438 + while (i < 8)
20439 + {
20440 + if (regmask & 1)
20441 + {
20442 + first = 2 * i;
20443 + while (i < 8)
20444 + {
20445 + i++;
20446 + regmask >>= 1;
20447 + if (!(regmask & 1))
20448 + break;
20449 + }
20450 + last = 2 * (i - 1) + 1;
20451 + print_reglist_range(first, last, cr_table, need_comma, info);
20452 + need_comma = 1;
20453 + }
20454 + else
20455 + {
20456 + i++;
20457 + regmask >>= 1;
20458 + }
20459 + }
20460 +
20461 + return 1;
20462 +}
20463 +
20464 +static int
20465 +print_retval(struct avr32_operand *op ATTRIBUTE_UNUSED,
20466 + struct disassemble_info *info,
20467 + struct avr32_field_value *ifields)
20468 +{
20469 + unsigned long regid = ifields[0].value;
20470 + const char *retval;
20471 +
20472 + if (regid < AVR32_REG_SP)
20473 + retval = reg_table[regid].name;
20474 + else if (regid == AVR32_REG_SP)
20475 + retval = "0";
20476 + else if (regid == AVR32_REG_LR)
20477 + retval = "-1";
20478 + else
20479 + retval = "1";
20480 +
20481 + info->fprintf_func(info->stream, "%s", retval);
20482 +
20483 + return 1;
20484 +}
20485 +
20486 +static int
20487 +print_mcall(struct avr32_operand *op,
20488 + struct disassemble_info *info,
20489 + struct avr32_field_value *ifields)
20490 +{
20491 + unsigned long regid = ifields[0].value;
20492 +
20493 + if (regid == AVR32_REG_PC)
20494 + print_jmplabel(op, info, ifields + 1);
20495 + else
20496 + print_intreg_sdisp(op, info, ifields);
20497 +
20498 + return 2;
20499 +}
20500 +
20501 +static int
20502 +print_jospinc(struct avr32_operand *op ATTRIBUTE_UNUSED,
20503 + struct disassemble_info *info,
20504 + struct avr32_field_value *ifields)
20505 +{
20506 + signed long value = ifields[0].value;
20507 +
20508 + if (value >= 4)
20509 + value -= 8;
20510 + else
20511 + value += 1;
20512 +
20513 + info->fprintf_func(info->stream, "%ld", value);
20514 +
20515 + return 1;
20516 +}
20517 +
20518 +static int
20519 +print_coh(struct avr32_operand *op ATTRIBUTE_UNUSED,
20520 + struct disassemble_info *info,
20521 + struct avr32_field_value *ifields ATTRIBUTE_UNUSED)
20522 +{
20523 + info->fprintf_func(info->stream, "COH");
20524 + return 0;
20525 +}
20526 +
20527 +#define OP(name, sgn, pcrel, align, func) \
20528 + { AVR32_OPERAND_##name, pcrel, align, print_##func }
20529 +
20530 +struct avr32_operand operand[AVR32_NR_OPERANDS] =
20531 + {
20532 + OP(INTREG, 0, 0, 0, intreg),
20533 + OP(INTREG_PREDEC, 0, 0, 0, intreg_predec),
20534 + OP(INTREG_POSTINC, 0, 0, 0, intreg_postinc),
20535 + OP(INTREG_LSL, 0, 0, 0, intreg_lsl),
20536 + OP(INTREG_LSR, 0, 0, 0, intreg_lsr),
20537 + OP(INTREG_BSEL, 0, 0, 0, intreg_bpart),
20538 + OP(INTREG_HSEL, 0, 0, 1, intreg_hpart),
20539 + OP(INTREG_SDISP, 1, 0, 0, intreg_sdisp),
20540 + OP(INTREG_SDISP_H, 1, 0, 1, intreg_sdisp),
20541 + OP(INTREG_SDISP_W, 1, 0, 2, intreg_sdisp),
20542 + OP(INTREG_UDISP, 0, 0, 0, intreg_udisp),
20543 + OP(INTREG_UDISP_H, 0, 0, 1, intreg_udisp),
20544 + OP(INTREG_UDISP_W, 0, 0, 2, intreg_udisp),
20545 + OP(INTREG_INDEX, 0, 0, 0, intreg_index),
20546 + OP(INTREG_XINDEX, 0, 0, 0, intreg_xindex),
20547 + OP(DWREG, 0, 0, 1, intreg),
20548 + OP(PC_UDISP_W, 0, 1, 2, pc_disp),
20549 + OP(SP, 0, 0, 0, sp),
20550 + OP(SP_UDISP_W, 0, 0, 2, sp_disp),
20551 + OP(CPNO, 0, 0, 0, cpno),
20552 + OP(CPREG, 0, 0, 0, cpreg),
20553 + OP(CPREG_D, 0, 0, 1, cpreg),
20554 + OP(UNSIGNED_CONST, 0, 0, 0, uconst),
20555 + OP(UNSIGNED_CONST_W, 0, 0, 2, uconst),
20556 + OP(SIGNED_CONST, 1, 0, 0, sconst),
20557 + OP(SIGNED_CONST_W, 1, 0, 2, sconst),
20558 + OP(JMPLABEL, 1, 1, 1, jmplabel),
20559 + OP(UNSIGNED_NUMBER, 0, 0, 0, uconst),
20560 + OP(UNSIGNED_NUMBER_W, 0, 0, 2, uconst),
20561 + OP(REGLIST8, 0, 0, 0, reglist8),
20562 + OP(REGLIST9, 0, 0, 0, reglist9),
20563 + OP(REGLIST16, 0, 0, 0, reglist16),
20564 + OP(REGLIST_LDM, 0, 0, 0, reglist_ldm),
20565 + OP(REGLIST_CP8, 0, 0, 0, reglist_cp8),
20566 + OP(REGLIST_CPD8, 0, 0, 0, reglist_cpd8),
20567 + OP(RETVAL, 0, 0, 0, retval),
20568 + OP(MCALL, 1, 0, 2, mcall),
20569 + OP(JOSPINC, 0, 0, 0, jospinc),
20570 + OP(COH, 0, 0, 0, coh),
20571 + };
20572 +
20573 +static void
20574 +print_opcode(bfd_vma insn_word, const struct avr32_opcode *opc,
20575 + bfd_vma pc, struct disassemble_info *info)
20576 +{
20577 + const struct avr32_syntax *syntax = opc->syntax;
20578 + struct avr32_field_value fields[AVR32_MAX_FIELDS];
20579 + unsigned int i, next_field = 0, nr_operands;
20580 +
20581 + for (i = 0; i < opc->nr_fields; i++)
20582 + {
20583 + opc->fields[i]->extract(opc->fields[i], &insn_word, &fields[i].value);
20584 + fields[i].ifield = opc->fields[i];
20585 + }
20586 +
20587 + current_pc = pc;
20588 + info->fprintf_func(info->stream, "%s", syntax->mnemonic->name);
20589 +
20590 + if (syntax->nr_operands < 0)
20591 + nr_operands = (unsigned int) -syntax->nr_operands;
20592 + else
20593 + nr_operands = (unsigned int) syntax->nr_operands;
20594 +
20595 + for (i = 0; i < nr_operands; i++)
20596 + {
20597 + struct avr32_operand *op = &operand[syntax->operand[i]];
20598 +
20599 + if (i)
20600 + info->fprintf_func(info->stream, ",");
20601 + else
20602 + info->fprintf_func(info->stream, "\t");
20603 + next_field += op->print(op, info, &fields[next_field]);
20604 + }
20605 +}
20606 +
20607 +static const struct avr32_opcode *
20608 +find_opcode(bfd_vma insn_word)
20609 +{
20610 + int i;
20611 +
20612 + for (i = 0; i < AVR32_NR_OPCODES; i++)
20613 + {
20614 + const struct avr32_opcode *opc = &avr32_opc_table[i];
20615 +
20616 + if ((insn_word & opc->mask) == opc->value)
20617 + return opc;
20618 + }
20619 +
20620 + return NULL;
20621 +}
20622 +
20623 +static int
20624 +read_insn_word(bfd_vma pc, bfd_vma *valuep,
20625 + struct disassemble_info *info)
20626 +{
20627 + bfd_byte b[4];
20628 + int status;
20629 +
20630 + status = info->read_memory_func(pc, b, 4, info);
20631 + if (status)
20632 + {
20633 + status = info->read_memory_func(pc, b, 2, info);
20634 + if (status)
20635 + {
20636 + info->memory_error_func(status, pc, info);
20637 + return -1;
20638 + }
20639 + b[3] = b[2] = 0;
20640 + }
20641 +
20642 + *valuep = (b[0] << 24) | (b[1] << 16) | (b[2] << 8) | b[3];
20643 + return 0;
20644 +}
20645 +
20646 +/* Parse an individual disassembler option. */
20647 +
20648 +void
20649 +parse_avr32_disassembler_option (option)
20650 + char * option;
20651 +{
20652 + if (option == NULL)
20653 + return;
20654 +
20655 + /* XXX - should break 'option' at following delimiter. */
20656 + fprintf (stderr, _("Unrecognised disassembler option: %s\n"), option);
20657 +
20658 + return;
20659 +}
20660 +
20661 +/* Parse the string of disassembler options, spliting it at whitespaces
20662 + or commas. (Whitespace separators supported for backwards compatibility). */
20663 +
20664 +static void
20665 +parse_disassembler_options (char *options)
20666 +{
20667 + if (options == NULL)
20668 + return;
20669 +
20670 + while (*options)
20671 + {
20672 + parse_avr32_disassembler_option (options);
20673 +
20674 + /* Skip forward to next seperator. */
20675 + while ((*options) && (! ISSPACE (*options)) && (*options != ','))
20676 + ++ options;
20677 + /* Skip forward past seperators. */
20678 + while (ISSPACE (*options) || (*options == ','))
20679 + ++ options;
20680 + }
20681 +}
20682 +
20683 +int
20684 +print_insn_avr32(bfd_vma pc, struct disassemble_info *info)
20685 +{
20686 + bfd_vma insn_word;
20687 + const struct avr32_opcode *opc;
20688 +
20689 + if (info->disassembler_options)
20690 + {
20691 + parse_disassembler_options (info->disassembler_options);
20692 +
20693 + /* To avoid repeated parsing of these options, we remove them here. */
20694 + info->disassembler_options = NULL;
20695 + }
20696 +
20697 + info->bytes_per_chunk = 1;
20698 + info->display_endian = BFD_ENDIAN_BIG;
20699 +
20700 + if (read_insn_word(pc, &insn_word, info))
20701 + return -1;
20702 +
20703 + opc = find_opcode(insn_word);
20704 + if (opc)
20705 + {
20706 + print_opcode(insn_word, opc, pc, info);
20707 + return opc->size;
20708 + }
20709 + else
20710 + {
20711 + info->fprintf_func(info->stream, _("*unknown*"));
20712 + return 2;
20713 + }
20714 +
20715 +}
20716 +
20717 +void
20718 +print_avr32_disassembler_options (FILE *stream ATTRIBUTE_UNUSED)
20719 +{
20720 +
20721 +}
20722 --- /dev/null
20723 +++ b/opcodes/avr32-opc.c
20724 @@ -0,0 +1,6932 @@
20725 +/* Opcode tables for AVR32.
20726 + Copyright 2005, 2006 Atmel Corporation.
20727 +
20728 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
20729 +
20730 + This file is part of libopcodes.
20731 +
20732 + This program is free software; you can redistribute it and/or
20733 + modify it under the terms of the GNU General Public License as
20734 + published by the Free Software Foundation; either version 2 of the
20735 + License, or (at your option) any later version.
20736 +
20737 + This program is distributed in the hope that it will be useful, but
20738 + WITHOUT ANY WARRANTY; without even the implied warranty of
20739 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20740 + General Public License for more details.
20741 +
20742 + You should have received a copy of the GNU General Public License
20743 + along with this program; if not, write to the Free Software
20744 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
20745 + 02111-1307, USA. */
20746 +
20747 +#include <stdlib.h>
20748 +#include <assert.h>
20749 +
20750 +#include "avr32-opc.h"
20751 +
20752 +#define PICO_CPNO 1
20753 +
20754 +void
20755 +avr32_insert_simple(const struct avr32_ifield *field,
20756 + void *buf, unsigned long value)
20757 +{
20758 + bfd_vma word;
20759 +
20760 + word = bfd_getb32(buf);
20761 + word &= ~field->mask;
20762 + word |= (value << field->shift) & field->mask;
20763 + bfd_putb32(word, buf);
20764 +}
20765 +
20766 +void
20767 +avr32_insert_bit5c(const struct avr32_ifield *field ATTRIBUTE_UNUSED,
20768 + void *buf, unsigned long value)
20769 +{
20770 + char *opcode = buf;
20771 +
20772 + opcode[0] = (opcode[0] & 0xe1) | (value & 0x1e);
20773 + opcode[1] = (opcode[1] & 0xef) | ((value & 1) << 4);
20774 +}
20775 +
20776 +void
20777 +avr32_insert_k10(const struct avr32_ifield *field ATTRIBUTE_UNUSED,
20778 + void *buf, unsigned long value)
20779 +{
20780 + char *opcode = buf;
20781 +
20782 + opcode[0] = (opcode[0] & 0xf0) | ((value & 0xf0) >> 4);
20783 + opcode[1] = ((opcode[1] & 0x0c) | ((value & 0x0f) << 4)
20784 + | ((value & 0x300) >> 8));
20785 +}
20786 +
20787 +
20788 +void
20789 +avr32_insert_k21(const struct avr32_ifield *field,
20790 + void *buf, unsigned long value)
20791 +{
20792 + bfd_vma word;
20793 + bfd_vma k21;
20794 +
20795 + word = bfd_getb32(buf);
20796 + word &= ~field->mask;
20797 + k21 = ((value & 0xffff) | ((value & 0x10000) << 4)
20798 + | ((value & 0x1e0000) << 8));
20799 + assert(!(k21 & ~field->mask));
20800 + word |= k21;
20801 + bfd_putb32(word, buf);
20802 +}
20803 +
20804 +void
20805 +avr32_insert_cpop(const struct avr32_ifield *field,
20806 + void *buf, unsigned long value)
20807 +{
20808 + bfd_vma word;
20809 +
20810 + word = bfd_getb32(buf);
20811 + word &= ~field->mask;
20812 + word |= (((value & 0x1e) << 15) | ((value & 0x60) << 20)
20813 + | ((value & 0x01) << 12));
20814 + bfd_putb32(word, buf);
20815 +}
20816 +
20817 +void
20818 +avr32_insert_k12cp(const struct avr32_ifield *field,
20819 + void *buf, unsigned long value)
20820 +{
20821 + bfd_vma word;
20822 +
20823 + word = bfd_getb32(buf);
20824 + word &= ~field->mask;
20825 + word |= ((value & 0xf00) << 4) | (value & 0xff);
20826 + bfd_putb32(word, buf);
20827 +}
20828 +
20829 +void avr32_extract_simple(const struct avr32_ifield *field,
20830 + void *buf, unsigned long *value)
20831 +{
20832 + /* XXX: The disassembler has done any necessary byteswapping already */
20833 + bfd_vma word = *(bfd_vma *)buf;
20834 +
20835 + *value = (word & field->mask) >> field->shift;
20836 +}
20837 +
20838 +void avr32_extract_bit5c(const struct avr32_ifield *field ATTRIBUTE_UNUSED,
20839 + void *buf, unsigned long *value)
20840 +{
20841 + bfd_vma word = *(bfd_vma *)buf;
20842 +
20843 + *value = ((word >> 20) & 1) | ((word >> 24) & 0x1e);
20844 +}
20845 +
20846 +void avr32_extract_k10(const struct avr32_ifield *field ATTRIBUTE_UNUSED,
20847 + void *buf, unsigned long *value)
20848 +{
20849 + bfd_vma word = *(bfd_vma *)buf;
20850 +
20851 + *value = ((word >> 8) & 0x300) | ((word >> 20) & 0xff);
20852 +}
20853 +
20854 +void avr32_extract_k21(const struct avr32_ifield *field ATTRIBUTE_UNUSED,
20855 + void *buf, unsigned long *value)
20856 +{
20857 + bfd_vma word = *(bfd_vma *)buf;
20858 +
20859 + *value = ((word & 0xffff) | ((word >> 4) & 0x10000)
20860 + | ((word >> 8) & 0x1e0000));
20861 +}
20862 +
20863 +void avr32_extract_cpop(const struct avr32_ifield *field ATTRIBUTE_UNUSED,
20864 + void *buf, unsigned long *value)
20865 +{
20866 + bfd_vma word = *(bfd_vma *)buf;
20867 +
20868 + *value = (((word >> 12) & 1) | ((word >> 15) & 0x1e)
20869 + | ((word >> 20) & 0x60));
20870 +}
20871 +
20872 +void avr32_extract_k12cp(const struct avr32_ifield *field ATTRIBUTE_UNUSED,
20873 + void *buf, unsigned long *value)
20874 +{
20875 + bfd_vma word = *(bfd_vma *)buf;
20876 +
20877 + *value = ((word >> 4) & 0xf00) | (word & 0xff);
20878 +}
20879 +
20880 +
20881 +#define IFLD(id, bitsz, shift, mask, func) \
20882 + { AVR32_IFIELD_##id, bitsz, shift, mask, \
20883 + avr32_insert_##func, avr32_extract_##func }
20884 +
20885 +const struct avr32_ifield avr32_ifield_table[] =
20886 + {
20887 + IFLD(RX, 4, 25, 0x1e000000, simple),
20888 + IFLD(RY, 4, 16, 0x000f0000, simple),
20889 + IFLD(COND4C, 4, 20, 0x00f00000, simple),
20890 + IFLD(K8C, 8, 20, 0x0ff00000, simple),
20891 + IFLD(K7C, 7, 20, 0x07f00000, simple),
20892 + IFLD(K5C, 5, 20, 0x01f00000, simple),
20893 + IFLD(K3, 3, 20, 0x00700000, simple),
20894 + IFLD(RY_DW, 3, 17, 0x000e0000, simple),
20895 + IFLD(COND4E, 4, 8, 0x00000f00, simple),
20896 + IFLD(K8E, 8, 0, 0x000000ff, simple),
20897 + IFLD(BIT5C, 5, 20, 0x1e100000, bit5c),
20898 + IFLD(COND3, 3, 16, 0x00070000, simple),
20899 + IFLD(K10, 10, 16, 0x0ff30000, k10),
20900 + IFLD(POPM, 9, 19, 0x0ff80000, simple),
20901 + IFLD(K2, 2, 4, 0x00000030, simple),
20902 + IFLD(RD_E, 4, 0, 0x0000000f, simple),
20903 + IFLD(RD_DW, 3, 1, 0x0000000e, simple),
20904 + IFLD(X, 1, 5, 0x00000020, simple),
20905 + IFLD(Y, 1, 4, 0x00000010, simple),
20906 + IFLD(X2, 1, 13, 0x00002000, simple),
20907 + IFLD(Y2, 1, 12, 0x00001000, simple),
20908 + IFLD(K5E, 5, 0, 0x0000001f, simple),
20909 + IFLD(PART2, 2, 0, 0x00000003, simple),
20910 + IFLD(PART1, 1, 0, 0x00000001, simple),
20911 + IFLD(K16, 16, 0, 0x0000ffff, simple),
20912 + IFLD(CACHEOP, 5, 11, 0x0000f800, simple),
20913 + IFLD(K11, 11, 0, 0x000007ff, simple),
20914 + IFLD(K21, 21, 0, 0x1e10ffff, k21),
20915 + IFLD(CPOP, 7, 12, 0x060f1000, cpop),
20916 + IFLD(CPNO, 3, 13, 0x0000e000, simple),
20917 + IFLD(CRD_RI, 4, 8, 0x00000f00, simple),
20918 + IFLD(CRX, 4, 4, 0x000000f0, simple),
20919 + IFLD(CRY, 4, 0, 0x0000000f, simple),
20920 + IFLD(K7E, 7, 0, 0x0000007f, simple),
20921 + IFLD(CRD_DW, 3, 9, 0x00000e00, simple),
20922 + IFLD(PART1_K12, 1, 12, 0x00001000, simple),
20923 + IFLD(PART2_K12, 2, 12, 0x00003000, simple),
20924 + IFLD(K12, 12, 0, 0x00000fff, simple),
20925 + IFLD(S5, 5, 5, 0x000003e0, simple),
20926 + IFLD(K5E2, 5, 4, 0x000001f0, simple),
20927 + IFLD(K4, 4, 20, 0x00f00000, simple),
20928 + IFLD(COND4E2, 4, 4, 0x000000f0, simple),
20929 + IFLD(K8E2, 8, 4, 0x00000ff0, simple),
20930 + IFLD(K6, 6, 20, 0x03f00000, simple),
20931 + IFLD(MEM15, 15, 0, 0x00007fff, simple),
20932 + IFLD(MEMB5, 5, 15, 0x000f8000, simple),
20933 + IFLD(W, 1, 25, 0x02000000, simple),
20934 + /* Coprocessor Multiple High/Low */
20935 + IFLD(CM_HL, 1, 8, 0x00000100, simple),
20936 + IFLD(K12CP, 12 ,0, 0x0000f0ff, k12cp),
20937 + IFLD(K9E, 9 ,0, 0x000001ff, simple),
20938 + };
20939 +#undef IFLD
20940 +
20941 +
20942 +struct avr32_opcode avr32_opc_table[] =
20943 + {
20944 + {
20945 + AVR32_OPC_ABS, 2, 0x5c400000, 0xfff00000,
20946 + &avr32_syntax_table[AVR32_SYNTAX_ABS],
20947 + BFD_RELOC_UNUSED, 1, -1,
20948 + {
20949 + &avr32_ifield_table[AVR32_IFIELD_RY],
20950 + }
20951 + },
20952 + {
20953 + AVR32_OPC_ACALL, 2, 0xd0000000, 0xf00f0000,
20954 + &avr32_syntax_table[AVR32_SYNTAX_ACALL],
20955 + BFD_RELOC_UNUSED, 1, -1,
20956 + {
20957 + &avr32_ifield_table[AVR32_IFIELD_K8C],
20958 + },
20959 + },
20960 + {
20961 + AVR32_OPC_ACR, 2, 0x5c000000, 0xfff00000,
20962 + &avr32_syntax_table[AVR32_SYNTAX_ACR],
20963 + BFD_RELOC_UNUSED, 1, -1,
20964 + {
20965 + &avr32_ifield_table[AVR32_IFIELD_RY],
20966 + },
20967 + },
20968 + {
20969 + AVR32_OPC_ADC, 4, 0xe0000040, 0xe1f0fff0,
20970 + &avr32_syntax_table[AVR32_SYNTAX_ADC],
20971 + BFD_RELOC_UNUSED, 3, -1,
20972 + {
20973 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
20974 + &avr32_ifield_table[AVR32_IFIELD_RX],
20975 + &avr32_ifield_table[AVR32_IFIELD_RY],
20976 + },
20977 + },
20978 + {
20979 + AVR32_OPC_ADD1, 2, 0x00000000, 0xe1f00000,
20980 + &avr32_syntax_table[AVR32_SYNTAX_ADD1],
20981 + BFD_RELOC_UNUSED, 2, -1,
20982 + {
20983 + &avr32_ifield_table[AVR32_IFIELD_RY],
20984 + &avr32_ifield_table[AVR32_IFIELD_RX],
20985 + },
20986 + },
20987 + {
20988 + AVR32_OPC_ADD2, 4, 0xe0000000, 0xe1f0ffc0,
20989 + &avr32_syntax_table[AVR32_SYNTAX_ADD2],
20990 + BFD_RELOC_UNUSED, 4, -1,
20991 + {
20992 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
20993 + &avr32_ifield_table[AVR32_IFIELD_RX],
20994 + &avr32_ifield_table[AVR32_IFIELD_RY],
20995 + &avr32_ifield_table[AVR32_IFIELD_K2],
20996 + },
20997 + },
20998 + {
20999 + AVR32_OPC_ADDABS, 4, 0xe0000e40, 0xe1f0fff0,
21000 + &avr32_syntax_table[AVR32_SYNTAX_ADDABS],
21001 + BFD_RELOC_UNUSED, 3, -1,
21002 + {
21003 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21004 + &avr32_ifield_table[AVR32_IFIELD_RX],
21005 + &avr32_ifield_table[AVR32_IFIELD_RY],
21006 + },
21007 + },
21008 + {
21009 + AVR32_OPC_ADDHH_W, 4, 0xe0000e00, 0xe1f0ffc0,
21010 + &avr32_syntax_table[AVR32_SYNTAX_ADDHH_W],
21011 + BFD_RELOC_UNUSED, 5, -1,
21012 + {
21013 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21014 + &avr32_ifield_table[AVR32_IFIELD_RX],
21015 + &avr32_ifield_table[AVR32_IFIELD_X],
21016 + &avr32_ifield_table[AVR32_IFIELD_RY],
21017 + &avr32_ifield_table[AVR32_IFIELD_Y],
21018 + },
21019 + },
21020 + {
21021 + AVR32_OPC_AND1, 2, 0x00600000, 0xe1f00000,
21022 + &avr32_syntax_table[AVR32_SYNTAX_AND1],
21023 + BFD_RELOC_UNUSED, 2, -1,
21024 + {
21025 + &avr32_ifield_table[AVR32_IFIELD_RY],
21026 + &avr32_ifield_table[AVR32_IFIELD_RX],
21027 + },
21028 + },
21029 + {
21030 + AVR32_OPC_AND2, 4, 0xe1e00000, 0xe1f0fe00,
21031 + &avr32_syntax_table[AVR32_SYNTAX_AND2],
21032 + BFD_RELOC_UNUSED, 4, -1,
21033 + {
21034 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21035 + &avr32_ifield_table[AVR32_IFIELD_RX],
21036 + &avr32_ifield_table[AVR32_IFIELD_RY],
21037 + &avr32_ifield_table[AVR32_IFIELD_K5E2],
21038 + },
21039 + },
21040 + {
21041 + AVR32_OPC_AND3, 4, 0xe1e00200, 0xe1f0fe00,
21042 + &avr32_syntax_table[AVR32_SYNTAX_AND3],
21043 + BFD_RELOC_UNUSED, 4, -1,
21044 + {
21045 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21046 + &avr32_ifield_table[AVR32_IFIELD_RX],
21047 + &avr32_ifield_table[AVR32_IFIELD_RY],
21048 + &avr32_ifield_table[AVR32_IFIELD_K5E2],
21049 + },
21050 + },
21051 + {
21052 + AVR32_OPC_ANDH, 4, 0xe4100000, 0xfff00000,
21053 + &avr32_syntax_table[AVR32_SYNTAX_ANDH],
21054 + BFD_RELOC_AVR32_16U, 2, 1,
21055 + {
21056 + &avr32_ifield_table[AVR32_IFIELD_RY],
21057 + &avr32_ifield_table[AVR32_IFIELD_K16],
21058 + },
21059 + },
21060 + {
21061 + AVR32_OPC_ANDH_COH, 4, 0xe6100000, 0xfff00000,
21062 + &avr32_syntax_table[AVR32_SYNTAX_ANDH_COH],
21063 + BFD_RELOC_AVR32_16U, 2, 1,
21064 + {
21065 + &avr32_ifield_table[AVR32_IFIELD_RY],
21066 + &avr32_ifield_table[AVR32_IFIELD_K16],
21067 + },
21068 + },
21069 + {
21070 + AVR32_OPC_ANDL, 4, 0xe0100000, 0xfff00000,
21071 + &avr32_syntax_table[AVR32_SYNTAX_ANDL],
21072 + BFD_RELOC_AVR32_16U, 2, 1,
21073 + {
21074 + &avr32_ifield_table[AVR32_IFIELD_RY],
21075 + &avr32_ifield_table[AVR32_IFIELD_K16],
21076 + },
21077 + },
21078 + {
21079 + AVR32_OPC_ANDL_COH, 4, 0xe2100000, 0xfff00000,
21080 + &avr32_syntax_table[AVR32_SYNTAX_ANDL_COH],
21081 + BFD_RELOC_AVR32_16U, 2, 1,
21082 + {
21083 + &avr32_ifield_table[AVR32_IFIELD_RY],
21084 + &avr32_ifield_table[AVR32_IFIELD_K16],
21085 + },
21086 + },
21087 + {
21088 + AVR32_OPC_ANDN, 2, 0x00800000, 0xe1f00000,
21089 + &avr32_syntax_table[AVR32_SYNTAX_ANDN],
21090 + BFD_RELOC_UNUSED, 2, -1,
21091 + {
21092 + &avr32_ifield_table[AVR32_IFIELD_RY],
21093 + &avr32_ifield_table[AVR32_IFIELD_RX],
21094 + },
21095 + },
21096 + {
21097 + AVR32_OPC_ASR1, 4, 0xe0000840, 0xe1f0fff0,
21098 + &avr32_syntax_table[AVR32_SYNTAX_ASR1],
21099 + BFD_RELOC_UNUSED, 3, -1,
21100 + {
21101 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21102 + &avr32_ifield_table[AVR32_IFIELD_RX],
21103 + &avr32_ifield_table[AVR32_IFIELD_RY],
21104 + },
21105 + },
21106 + {
21107 + AVR32_OPC_ASR3, 4, 0xe0001400, 0xe1f0ffe0,
21108 + &avr32_syntax_table[AVR32_SYNTAX_ASR3],
21109 + BFD_RELOC_UNUSED, 3, -1,
21110 + {
21111 + &avr32_ifield_table[AVR32_IFIELD_RY],
21112 + &avr32_ifield_table[AVR32_IFIELD_RX],
21113 + &avr32_ifield_table[AVR32_IFIELD_K5E],
21114 + },
21115 + },
21116 + {
21117 + AVR32_OPC_ASR2, 2, 0xa1400000, 0xe1e00000,
21118 + &avr32_syntax_table[AVR32_SYNTAX_ASR2],
21119 + BFD_RELOC_UNUSED, 2, -1,
21120 + {
21121 + &avr32_ifield_table[AVR32_IFIELD_RY],
21122 + &avr32_ifield_table[AVR32_IFIELD_BIT5C],
21123 + },
21124 + },
21125 + {
21126 + AVR32_OPC_BLD, 4, 0xedb00000, 0xfff0ffe0,
21127 + &avr32_syntax_table[AVR32_SYNTAX_BLD],
21128 + BFD_RELOC_UNUSED, 2, -1,
21129 + {
21130 + &avr32_ifield_table[AVR32_IFIELD_RY],
21131 + &avr32_ifield_table[AVR32_IFIELD_K5E],
21132 + },
21133 + },
21134 + {
21135 + AVR32_OPC_BREQ1, 2, 0xc0000000, 0xf00f0000,
21136 + &avr32_syntax_table[AVR32_SYNTAX_BREQ1],
21137 + BFD_RELOC_AVR32_9H_PCREL, 1, 0,
21138 + {
21139 + &avr32_ifield_table[AVR32_IFIELD_K8C],
21140 + },
21141 + },
21142 + {
21143 + AVR32_OPC_BRNE1, 2, 0xc0010000, 0xf00f0000,
21144 + &avr32_syntax_table[AVR32_SYNTAX_BRNE1],
21145 + BFD_RELOC_AVR32_9H_PCREL, 1, 0,
21146 + {
21147 + &avr32_ifield_table[AVR32_IFIELD_K8C],
21148 + },
21149 + },
21150 + {
21151 + AVR32_OPC_BRCC1, 2, 0xc0020000, 0xf00f0000,
21152 + &avr32_syntax_table[AVR32_SYNTAX_BRCC1],
21153 + BFD_RELOC_AVR32_9H_PCREL, 1, 0,
21154 + {
21155 + &avr32_ifield_table[AVR32_IFIELD_K8C],
21156 + },
21157 + },
21158 + {
21159 + AVR32_OPC_BRCS1, 2, 0xc0030000, 0xf00f0000,
21160 + &avr32_syntax_table[AVR32_SYNTAX_BRCS1],
21161 + BFD_RELOC_AVR32_9H_PCREL, 1, 0,
21162 + {
21163 + &avr32_ifield_table[AVR32_IFIELD_K8C],
21164 + },
21165 + },
21166 + {
21167 + AVR32_OPC_BRGE1, 2, 0xc0040000, 0xf00f0000,
21168 + &avr32_syntax_table[AVR32_SYNTAX_BRGE1],
21169 + BFD_RELOC_AVR32_9H_PCREL, 1, 0,
21170 + {
21171 + &avr32_ifield_table[AVR32_IFIELD_K8C],
21172 + },
21173 + },
21174 + {
21175 + AVR32_OPC_BRLT1, 2, 0xc0050000, 0xf00f0000,
21176 + &avr32_syntax_table[AVR32_SYNTAX_BRLT1],
21177 + BFD_RELOC_AVR32_9H_PCREL, 1, 0,
21178 + {
21179 + &avr32_ifield_table[AVR32_IFIELD_K8C],
21180 + },
21181 + },
21182 + {
21183 + AVR32_OPC_BRMI1, 2, 0xc0060000, 0xf00f0000,
21184 + &avr32_syntax_table[AVR32_SYNTAX_BRMI1],
21185 + BFD_RELOC_AVR32_9H_PCREL, 1, 0,
21186 + {
21187 + &avr32_ifield_table[AVR32_IFIELD_K8C],
21188 + },
21189 + },
21190 + {
21191 + AVR32_OPC_BRPL1, 2, 0xc0070000, 0xf00f0000,
21192 + &avr32_syntax_table[AVR32_SYNTAX_BRPL1],
21193 + BFD_RELOC_AVR32_9H_PCREL, 1, 0,
21194 + {
21195 + &avr32_ifield_table[AVR32_IFIELD_K8C],
21196 + },
21197 + },
21198 + {
21199 + AVR32_OPC_BREQ2, 4, 0xe0800000, 0xe1ef0000,
21200 + &avr32_syntax_table[AVR32_SYNTAX_BREQ2],
21201 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21202 + {
21203 + &avr32_ifield_table[AVR32_IFIELD_K21],
21204 + },
21205 + },
21206 + {
21207 + AVR32_OPC_BRNE2, 4, 0xe0810000, 0xe1ef0000,
21208 + &avr32_syntax_table[AVR32_SYNTAX_BRNE2],
21209 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21210 + {
21211 + &avr32_ifield_table[AVR32_IFIELD_K21],
21212 + },
21213 + },
21214 + {
21215 + AVR32_OPC_BRCC2, 4, 0xe0820000, 0xe1ef0000,
21216 + &avr32_syntax_table[AVR32_SYNTAX_BRHS2],
21217 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21218 + {
21219 + &avr32_ifield_table[AVR32_IFIELD_K21],
21220 + },
21221 + },
21222 + {
21223 + AVR32_OPC_BRCS2, 4, 0xe0830000, 0xe1ef0000,
21224 + &avr32_syntax_table[AVR32_SYNTAX_BRLO2],
21225 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21226 + {
21227 + &avr32_ifield_table[AVR32_IFIELD_K21],
21228 + },
21229 + },
21230 + {
21231 + AVR32_OPC_BRGE2, 4, 0xe0840000, 0xe1ef0000,
21232 + &avr32_syntax_table[AVR32_SYNTAX_BRGE2],
21233 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21234 + {
21235 + &avr32_ifield_table[AVR32_IFIELD_K21],
21236 + },
21237 + },
21238 + {
21239 + AVR32_OPC_BRLT2, 4, 0xe0850000, 0xe1ef0000,
21240 + &avr32_syntax_table[AVR32_SYNTAX_BRLT2],
21241 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21242 + {
21243 + &avr32_ifield_table[AVR32_IFIELD_K21],
21244 + },
21245 + },
21246 + {
21247 + AVR32_OPC_BRMI2, 4, 0xe0860000, 0xe1ef0000,
21248 + &avr32_syntax_table[AVR32_SYNTAX_BRMI2],
21249 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21250 + {
21251 + &avr32_ifield_table[AVR32_IFIELD_K21],
21252 + },
21253 + },
21254 + {
21255 + AVR32_OPC_BRPL2, 4, 0xe0870000, 0xe1ef0000,
21256 + &avr32_syntax_table[AVR32_SYNTAX_BRPL2],
21257 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21258 + {
21259 + &avr32_ifield_table[AVR32_IFIELD_K21],
21260 + },
21261 + },
21262 + {
21263 + AVR32_OPC_BRLS, 4, 0xe0880000, 0xe1ef0000,
21264 + &avr32_syntax_table[AVR32_SYNTAX_BRLS],
21265 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21266 + {
21267 + &avr32_ifield_table[AVR32_IFIELD_K21],
21268 + },
21269 + },
21270 + {
21271 + AVR32_OPC_BRGT, 4, 0xe0890000, 0xe1ef0000,
21272 + &avr32_syntax_table[AVR32_SYNTAX_BRGT],
21273 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21274 + {
21275 + &avr32_ifield_table[AVR32_IFIELD_K21],
21276 + },
21277 + },
21278 + {
21279 + AVR32_OPC_BRLE, 4, 0xe08a0000, 0xe1ef0000,
21280 + &avr32_syntax_table[AVR32_SYNTAX_BRLE],
21281 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21282 + {
21283 + &avr32_ifield_table[AVR32_IFIELD_K21],
21284 + },
21285 + },
21286 + {
21287 + AVR32_OPC_BRHI, 4, 0xe08b0000, 0xe1ef0000,
21288 + &avr32_syntax_table[AVR32_SYNTAX_BRHI],
21289 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21290 + {
21291 + &avr32_ifield_table[AVR32_IFIELD_K21],
21292 + },
21293 + },
21294 + {
21295 + AVR32_OPC_BRVS, 4, 0xe08c0000, 0xe1ef0000,
21296 + &avr32_syntax_table[AVR32_SYNTAX_BRVS],
21297 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21298 + {
21299 + &avr32_ifield_table[AVR32_IFIELD_K21],
21300 + },
21301 + },
21302 + {
21303 + AVR32_OPC_BRVC, 4, 0xe08d0000, 0xe1ef0000,
21304 + &avr32_syntax_table[AVR32_SYNTAX_BRVC],
21305 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21306 + {
21307 + &avr32_ifield_table[AVR32_IFIELD_K21],
21308 + },
21309 + },
21310 + {
21311 + AVR32_OPC_BRQS, 4, 0xe08e0000, 0xe1ef0000,
21312 + &avr32_syntax_table[AVR32_SYNTAX_BRQS],
21313 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21314 + {
21315 + &avr32_ifield_table[AVR32_IFIELD_K21],
21316 + },
21317 + },
21318 + {
21319 + AVR32_OPC_BRAL, 4, 0xe08f0000, 0xe1ef0000,
21320 + &avr32_syntax_table[AVR32_SYNTAX_BRAL],
21321 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
21322 + {
21323 + &avr32_ifield_table[AVR32_IFIELD_K21],
21324 + },
21325 + },
21326 + {
21327 + AVR32_OPC_BREAKPOINT, 2, 0xd6730000, 0xffff0000,
21328 + &avr32_syntax_table[AVR32_SYNTAX_BREAKPOINT],
21329 + BFD_RELOC_UNUSED, 0, -1, { NULL },
21330 + },
21331 + {
21332 + AVR32_OPC_BREV, 2, 0x5c900000, 0xfff00000,
21333 + &avr32_syntax_table[AVR32_SYNTAX_BREV],
21334 + BFD_RELOC_UNUSED, 1, -1,
21335 + {
21336 + &avr32_ifield_table[AVR32_IFIELD_RY],
21337 + },
21338 + },
21339 + {
21340 + AVR32_OPC_BST, 4, 0xefb00000, 0xfff0ffe0,
21341 + &avr32_syntax_table[AVR32_SYNTAX_BST],
21342 + BFD_RELOC_UNUSED, 2, -1,
21343 + {
21344 + &avr32_ifield_table[AVR32_IFIELD_RY],
21345 + &avr32_ifield_table[AVR32_IFIELD_K5E],
21346 + },
21347 + },
21348 + {
21349 + AVR32_OPC_CACHE, 4, 0xf4100000, 0xfff00000,
21350 + &avr32_syntax_table[AVR32_SYNTAX_CACHE],
21351 + BFD_RELOC_UNUSED, 3, -1,
21352 + {
21353 + &avr32_ifield_table[AVR32_IFIELD_RY],
21354 + &avr32_ifield_table[AVR32_IFIELD_K11],
21355 + &avr32_ifield_table[AVR32_IFIELD_CACHEOP],
21356 + },
21357 + },
21358 + {
21359 + AVR32_OPC_CASTS_B, 2, 0x5c600000, 0xfff00000,
21360 + &avr32_syntax_table[AVR32_SYNTAX_CASTS_B],
21361 + BFD_RELOC_UNUSED, 1, -1,
21362 + {
21363 + &avr32_ifield_table[AVR32_IFIELD_RY],
21364 + },
21365 + },
21366 + {
21367 + AVR32_OPC_CASTS_H, 2, 0x5c800000, 0xfff00000,
21368 + &avr32_syntax_table[AVR32_SYNTAX_CASTS_H],
21369 + BFD_RELOC_UNUSED, 1, -1,
21370 + {
21371 + &avr32_ifield_table[AVR32_IFIELD_RY],
21372 + },
21373 + },
21374 + {
21375 + AVR32_OPC_CASTU_B, 2, 0x5c500000, 0xfff00000,
21376 + &avr32_syntax_table[AVR32_SYNTAX_CASTU_B],
21377 + BFD_RELOC_UNUSED, 1, -1,
21378 + {
21379 + &avr32_ifield_table[AVR32_IFIELD_RY],
21380 + },
21381 + },
21382 + {
21383 + AVR32_OPC_CASTU_H, 2, 0x5c700000, 0xfff00000,
21384 + &avr32_syntax_table[AVR32_SYNTAX_CASTU_H],
21385 + BFD_RELOC_UNUSED, 1, -1,
21386 + {
21387 + &avr32_ifield_table[AVR32_IFIELD_RY],
21388 + },
21389 + },
21390 + {
21391 + AVR32_OPC_CBR, 2, 0xa1c00000, 0xe1e00000,
21392 + &avr32_syntax_table[AVR32_SYNTAX_CBR],
21393 + BFD_RELOC_UNUSED, 2, -1,
21394 + {
21395 + &avr32_ifield_table[AVR32_IFIELD_RY],
21396 + &avr32_ifield_table[AVR32_IFIELD_BIT5C],
21397 + },
21398 + },
21399 + {
21400 + AVR32_OPC_CLZ, 4, 0xe0001200, 0xe1f0ffff,
21401 + &avr32_syntax_table[AVR32_SYNTAX_CLZ],
21402 + BFD_RELOC_UNUSED, 2, -1,
21403 + {
21404 + &avr32_ifield_table[AVR32_IFIELD_RY],
21405 + &avr32_ifield_table[AVR32_IFIELD_RX],
21406 + },
21407 + },
21408 + {
21409 + AVR32_OPC_COM, 2, 0x5cd00000, 0xfff00000,
21410 + &avr32_syntax_table[AVR32_SYNTAX_COM],
21411 + BFD_RELOC_UNUSED, 1, -1,
21412 + {
21413 + &avr32_ifield_table[AVR32_IFIELD_RY],
21414 + },
21415 + },
21416 + {
21417 + AVR32_OPC_COP, 4, 0xe1a00000, 0xf9f00000,
21418 + &avr32_syntax_table[AVR32_SYNTAX_COP],
21419 + BFD_RELOC_UNUSED, 5, -1,
21420 + {
21421 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21422 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
21423 + &avr32_ifield_table[AVR32_IFIELD_CRX],
21424 + &avr32_ifield_table[AVR32_IFIELD_CRY],
21425 + &avr32_ifield_table[AVR32_IFIELD_CPOP],
21426 + },
21427 + },
21428 + {
21429 + AVR32_OPC_CP_B, 4, 0xe0001800, 0xe1f0ffff,
21430 + &avr32_syntax_table[AVR32_SYNTAX_CP_B],
21431 + BFD_RELOC_UNUSED, 2, -1,
21432 + {
21433 + &avr32_ifield_table[AVR32_IFIELD_RY],
21434 + &avr32_ifield_table[AVR32_IFIELD_RX],
21435 + },
21436 + },
21437 + {
21438 + AVR32_OPC_CP_H, 4, 0xe0001900, 0xe1f0ffff,
21439 + &avr32_syntax_table[AVR32_SYNTAX_CP_H],
21440 + BFD_RELOC_UNUSED, 2, -1,
21441 + {
21442 + &avr32_ifield_table[AVR32_IFIELD_RY],
21443 + &avr32_ifield_table[AVR32_IFIELD_RX],
21444 + },
21445 + },
21446 + {
21447 + AVR32_OPC_CP_W1, 2, 0x00300000, 0xe1f00000,
21448 + &avr32_syntax_table[AVR32_SYNTAX_CP_W1],
21449 + BFD_RELOC_UNUSED, 2, -1,
21450 + {
21451 + &avr32_ifield_table[AVR32_IFIELD_RY],
21452 + &avr32_ifield_table[AVR32_IFIELD_RX],
21453 + },
21454 + },
21455 + {
21456 + AVR32_OPC_CP_W2, 2, 0x58000000, 0xfc000000,
21457 + &avr32_syntax_table[AVR32_SYNTAX_CP_W2],
21458 + BFD_RELOC_AVR32_6S, 2, 1,
21459 + {
21460 + &avr32_ifield_table[AVR32_IFIELD_RY],
21461 + &avr32_ifield_table[AVR32_IFIELD_K6],
21462 + },
21463 + },
21464 + {
21465 + AVR32_OPC_CP_W3, 4, 0xe0400000, 0xe1e00000,
21466 + &avr32_syntax_table[AVR32_SYNTAX_CP_W3],
21467 + BFD_RELOC_AVR32_21S, 2, 1,
21468 + {
21469 + &avr32_ifield_table[AVR32_IFIELD_RY],
21470 + &avr32_ifield_table[AVR32_IFIELD_K21],
21471 + },
21472 + },
21473 + {
21474 + AVR32_OPC_CPC1, 4, 0xe0001300, 0xe1f0ffff,
21475 + &avr32_syntax_table[AVR32_SYNTAX_CPC1],
21476 + BFD_RELOC_UNUSED, 2, -1,
21477 + {
21478 + &avr32_ifield_table[AVR32_IFIELD_RY],
21479 + &avr32_ifield_table[AVR32_IFIELD_RX],
21480 + },
21481 + },
21482 + {
21483 + AVR32_OPC_CPC2, 2, 0x5c200000, 0xfff00000,
21484 + &avr32_syntax_table[AVR32_SYNTAX_CPC2],
21485 + BFD_RELOC_UNUSED, 1, -1,
21486 + {
21487 + &avr32_ifield_table[AVR32_IFIELD_RY],
21488 + },
21489 + },
21490 + {
21491 + AVR32_OPC_CSRF, 2, 0xd4030000, 0xfe0f0000,
21492 + &avr32_syntax_table[AVR32_SYNTAX_CSRF],
21493 + BFD_RELOC_UNUSED, 1, -1,
21494 + {
21495 + &avr32_ifield_table[AVR32_IFIELD_K5C],
21496 + },
21497 + },
21498 + {
21499 + AVR32_OPC_CSRFCZ, 2, 0xd0030000, 0xfe0f0000,
21500 + &avr32_syntax_table[AVR32_SYNTAX_CSRFCZ],
21501 + BFD_RELOC_UNUSED, 1, -1,
21502 + {
21503 + &avr32_ifield_table[AVR32_IFIELD_K5C],
21504 + },
21505 + },
21506 + {
21507 + AVR32_OPC_DIVS, 4, 0xe0000c00, 0xe1f0ffc0,
21508 + &avr32_syntax_table[AVR32_SYNTAX_DIVS],
21509 + BFD_RELOC_UNUSED, 3, -1,
21510 + {
21511 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21512 + &avr32_ifield_table[AVR32_IFIELD_RX],
21513 + &avr32_ifield_table[AVR32_IFIELD_RY],
21514 + },
21515 + },
21516 + {
21517 + AVR32_OPC_DIVU, 4, 0xe0000d00, 0xe1f0ffc0,
21518 + &avr32_syntax_table[AVR32_SYNTAX_DIVU],
21519 + BFD_RELOC_UNUSED, 3, -1,
21520 + {
21521 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21522 + &avr32_ifield_table[AVR32_IFIELD_RX],
21523 + &avr32_ifield_table[AVR32_IFIELD_RY],
21524 + },
21525 + },
21526 + {
21527 + AVR32_OPC_EOR1, 2, 0x00500000, 0xe1f00000,
21528 + &avr32_syntax_table[AVR32_SYNTAX_EOR1],
21529 + BFD_RELOC_UNUSED, 2, -1,
21530 + {
21531 + &avr32_ifield_table[AVR32_IFIELD_RY],
21532 + &avr32_ifield_table[AVR32_IFIELD_RX],
21533 + },
21534 + },
21535 + {
21536 + AVR32_OPC_EOR2, 4, 0xe1e02000, 0xe1f0fe00,
21537 + &avr32_syntax_table[AVR32_SYNTAX_EOR2],
21538 + BFD_RELOC_UNUSED, 4, -1,
21539 + {
21540 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21541 + &avr32_ifield_table[AVR32_IFIELD_RX],
21542 + &avr32_ifield_table[AVR32_IFIELD_RY],
21543 + &avr32_ifield_table[AVR32_IFIELD_K5E2],
21544 + }
21545 + },
21546 + {
21547 + AVR32_OPC_EOR3, 4, 0xe1e02200, 0xe1f0fe00,
21548 + &avr32_syntax_table[AVR32_SYNTAX_EOR3],
21549 + BFD_RELOC_UNUSED, 4, -1,
21550 + {
21551 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21552 + &avr32_ifield_table[AVR32_IFIELD_RX],
21553 + &avr32_ifield_table[AVR32_IFIELD_RY],
21554 + &avr32_ifield_table[AVR32_IFIELD_K5E2],
21555 + }
21556 + },
21557 + {
21558 + AVR32_OPC_EORL, 4, 0xec100000, 0xfff00000,
21559 + &avr32_syntax_table[AVR32_SYNTAX_EORL],
21560 + BFD_RELOC_AVR32_16U, 2, 1,
21561 + {
21562 + &avr32_ifield_table[AVR32_IFIELD_RY],
21563 + &avr32_ifield_table[AVR32_IFIELD_K16],
21564 + },
21565 + },
21566 + {
21567 + AVR32_OPC_EORH, 4, 0xee100000, 0xfff00000,
21568 + &avr32_syntax_table[AVR32_SYNTAX_EORH],
21569 + BFD_RELOC_AVR32_16U, 2, 1,
21570 + {
21571 + &avr32_ifield_table[AVR32_IFIELD_RY],
21572 + &avr32_ifield_table[AVR32_IFIELD_K16],
21573 + },
21574 + },
21575 + {
21576 + AVR32_OPC_FRS, 2, 0xd7430000, 0xffff0000,
21577 + &avr32_syntax_table[AVR32_SYNTAX_FRS],
21578 + BFD_RELOC_UNUSED, 0, -1, { NULL },
21579 + },
21580 + {
21581 + AVR32_OPC_ICALL, 2, 0x5d100000, 0xfff00000,
21582 + &avr32_syntax_table[AVR32_SYNTAX_ICALL],
21583 + BFD_RELOC_UNUSED, 1, -1,
21584 + {
21585 + &avr32_ifield_table[AVR32_IFIELD_RY],
21586 + },
21587 + },
21588 + {
21589 + AVR32_OPC_INCJOSP, 2, 0xd6830000, 0xff8f0000,
21590 + &avr32_syntax_table[AVR32_SYNTAX_INCJOSP],
21591 + BFD_RELOC_UNUSED, 1, -1,
21592 + {
21593 + &avr32_ifield_table[AVR32_IFIELD_K3],
21594 + },
21595 + },
21596 + {
21597 + AVR32_OPC_LD_D1, 2, 0xa1010000, 0xe1f10000,
21598 + &avr32_syntax_table[AVR32_SYNTAX_LD_D1],
21599 + BFD_RELOC_UNUSED, 2, -1,
21600 + {
21601 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
21602 + &avr32_ifield_table[AVR32_IFIELD_RX],
21603 + },
21604 + },
21605 + {
21606 + AVR32_OPC_LD_D2, 2, 0xa1100000, 0xe1f10000,
21607 + &avr32_syntax_table[AVR32_SYNTAX_LD_D2],
21608 + BFD_RELOC_UNUSED, 2, -1,
21609 + {
21610 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
21611 + &avr32_ifield_table[AVR32_IFIELD_RX],
21612 + },
21613 + },
21614 + {
21615 + AVR32_OPC_LD_D3, 2, 0xa1000000, 0xe1f10000,
21616 + &avr32_syntax_table[AVR32_SYNTAX_LD_D3],
21617 + BFD_RELOC_UNUSED, 2, -1,
21618 + {
21619 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
21620 + &avr32_ifield_table[AVR32_IFIELD_RX],
21621 + },
21622 + },
21623 + {
21624 + AVR32_OPC_LD_D5, 4, 0xe0000200, 0xe1f0ffc1,
21625 + &avr32_syntax_table[AVR32_SYNTAX_LD_D5],
21626 + BFD_RELOC_UNUSED, 4, -1,
21627 + {
21628 + &avr32_ifield_table[AVR32_IFIELD_RD_DW],
21629 + &avr32_ifield_table[AVR32_IFIELD_RX],
21630 + &avr32_ifield_table[AVR32_IFIELD_RY],
21631 + &avr32_ifield_table[AVR32_IFIELD_K2],
21632 + },
21633 + },
21634 + {
21635 + AVR32_OPC_LD_D4, 4, 0xe0e00000, 0xe1f10000,
21636 + &avr32_syntax_table[AVR32_SYNTAX_LD_D4],
21637 + BFD_RELOC_AVR32_16S, 3, 2,
21638 + {
21639 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
21640 + &avr32_ifield_table[AVR32_IFIELD_RX],
21641 + &avr32_ifield_table[AVR32_IFIELD_K16],
21642 + },
21643 + },
21644 + {
21645 + AVR32_OPC_LD_SB2, 4, 0xe0000600, 0xe1f0ffc0,
21646 + &avr32_syntax_table[AVR32_SYNTAX_LD_SB2],
21647 + BFD_RELOC_UNUSED, 4, -1,
21648 + {
21649 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21650 + &avr32_ifield_table[AVR32_IFIELD_RX],
21651 + &avr32_ifield_table[AVR32_IFIELD_RY],
21652 + &avr32_ifield_table[AVR32_IFIELD_K2],
21653 + },
21654 + },
21655 + {
21656 + AVR32_OPC_LD_SB1, 4, 0xe1200000, 0xe1f00000,
21657 + &avr32_syntax_table[AVR32_SYNTAX_LD_SB1],
21658 + BFD_RELOC_AVR32_16S, 3, -1,
21659 + {
21660 + &avr32_ifield_table[AVR32_IFIELD_RY],
21661 + &avr32_ifield_table[AVR32_IFIELD_RX],
21662 + &avr32_ifield_table[AVR32_IFIELD_K16],
21663 + },
21664 + },
21665 + {
21666 + AVR32_OPC_LD_UB1, 2, 0x01300000, 0xe1f00000,
21667 + &avr32_syntax_table[AVR32_SYNTAX_LD_UB1],
21668 + BFD_RELOC_UNUSED, 2, -1,
21669 + {
21670 + &avr32_ifield_table[AVR32_IFIELD_RY],
21671 + &avr32_ifield_table[AVR32_IFIELD_RX],
21672 + },
21673 + },
21674 + {
21675 + AVR32_OPC_LD_UB2, 2, 0x01700000, 0xe1f00000,
21676 + &avr32_syntax_table[AVR32_SYNTAX_LD_UB2],
21677 + BFD_RELOC_UNUSED, 2, -1,
21678 + {
21679 + &avr32_ifield_table[AVR32_IFIELD_RY],
21680 + &avr32_ifield_table[AVR32_IFIELD_RX],
21681 + },
21682 + },
21683 + {
21684 + AVR32_OPC_LD_UB5, 4, 0xe0000700, 0xe1f0ffc0,
21685 + &avr32_syntax_table[AVR32_SYNTAX_LD_UB5],
21686 + BFD_RELOC_UNUSED, 4, -1,
21687 + {
21688 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21689 + &avr32_ifield_table[AVR32_IFIELD_RX],
21690 + &avr32_ifield_table[AVR32_IFIELD_RY],
21691 + &avr32_ifield_table[AVR32_IFIELD_K2],
21692 + },
21693 + },
21694 + {
21695 + AVR32_OPC_LD_UB3, 2, 0x01800000, 0xe1800000,
21696 + &avr32_syntax_table[AVR32_SYNTAX_LD_UB3],
21697 + BFD_RELOC_AVR32_3U, 3, 2,
21698 + {
21699 + &avr32_ifield_table[AVR32_IFIELD_RY],
21700 + &avr32_ifield_table[AVR32_IFIELD_RX],
21701 + &avr32_ifield_table[AVR32_IFIELD_K3],
21702 + },
21703 + },
21704 + {
21705 + AVR32_OPC_LD_UB4, 4, 0xe1300000, 0xe1f00000,
21706 + &avr32_syntax_table[AVR32_SYNTAX_LD_UB4],
21707 + BFD_RELOC_AVR32_16S, 3, 2,
21708 + {
21709 + &avr32_ifield_table[AVR32_IFIELD_RY],
21710 + &avr32_ifield_table[AVR32_IFIELD_RX],
21711 + &avr32_ifield_table[AVR32_IFIELD_K16],
21712 + },
21713 + },
21714 + {
21715 + AVR32_OPC_LD_SH1, 2, 0x01100000, 0xe1f00000,
21716 + &avr32_syntax_table[AVR32_SYNTAX_LD_SH1],
21717 + BFD_RELOC_UNUSED, 2, -1,
21718 + {
21719 + &avr32_ifield_table[AVR32_IFIELD_RY],
21720 + &avr32_ifield_table[AVR32_IFIELD_RX],
21721 + },
21722 + },
21723 + {
21724 + AVR32_OPC_LD_SH2, 2, 0x01500000, 0xe1f00000,
21725 + &avr32_syntax_table[AVR32_SYNTAX_LD_SH2],
21726 + BFD_RELOC_UNUSED, 2, -1,
21727 + {
21728 + &avr32_ifield_table[AVR32_IFIELD_RY],
21729 + &avr32_ifield_table[AVR32_IFIELD_RX],
21730 + },
21731 + },
21732 + {
21733 + AVR32_OPC_LD_SH5, 4, 0xe0000400, 0xe1f0ffc0,
21734 + &avr32_syntax_table[AVR32_SYNTAX_LD_SH5],
21735 + BFD_RELOC_UNUSED, 4, -1,
21736 + {
21737 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21738 + &avr32_ifield_table[AVR32_IFIELD_RX],
21739 + &avr32_ifield_table[AVR32_IFIELD_RY],
21740 + &avr32_ifield_table[AVR32_IFIELD_K2],
21741 + },
21742 + },
21743 + {
21744 + AVR32_OPC_LD_SH3, 2, 0x80000000, 0xe1800000,
21745 + &avr32_syntax_table[AVR32_SYNTAX_LD_SH3],
21746 + BFD_RELOC_AVR32_4UH, 3, 2,
21747 + {
21748 + &avr32_ifield_table[AVR32_IFIELD_RY],
21749 + &avr32_ifield_table[AVR32_IFIELD_RX],
21750 + &avr32_ifield_table[AVR32_IFIELD_K3],
21751 + },
21752 + },
21753 + {
21754 + AVR32_OPC_LD_SH4, 4, 0xe1000000, 0xe1f00000,
21755 + &avr32_syntax_table[AVR32_SYNTAX_LD_SH4],
21756 + BFD_RELOC_AVR32_16S, 3, 2,
21757 + {
21758 + &avr32_ifield_table[AVR32_IFIELD_RY],
21759 + &avr32_ifield_table[AVR32_IFIELD_RX],
21760 + &avr32_ifield_table[AVR32_IFIELD_K16],
21761 + },
21762 + },
21763 + {
21764 + AVR32_OPC_LD_UH1, 2, 0x01200000, 0xe1f00000,
21765 + &avr32_syntax_table[AVR32_SYNTAX_LD_UH1],
21766 + BFD_RELOC_UNUSED, 2, -1,
21767 + {
21768 + &avr32_ifield_table[AVR32_IFIELD_RY],
21769 + &avr32_ifield_table[AVR32_IFIELD_RX],
21770 + },
21771 + },
21772 + {
21773 + AVR32_OPC_LD_UH2, 2, 0x01600000, 0xe1f00000,
21774 + &avr32_syntax_table[AVR32_SYNTAX_LD_UH2],
21775 + BFD_RELOC_UNUSED, 2, -1,
21776 + {
21777 + &avr32_ifield_table[AVR32_IFIELD_RY],
21778 + &avr32_ifield_table[AVR32_IFIELD_RX],
21779 + },
21780 + },
21781 + {
21782 + AVR32_OPC_LD_UH5, 4, 0xe0000500, 0xe1f0ffc0,
21783 + &avr32_syntax_table[AVR32_SYNTAX_LD_UH5],
21784 + BFD_RELOC_UNUSED, 4, -1,
21785 + {
21786 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21787 + &avr32_ifield_table[AVR32_IFIELD_RX],
21788 + &avr32_ifield_table[AVR32_IFIELD_RY],
21789 + &avr32_ifield_table[AVR32_IFIELD_K2],
21790 + },
21791 + },
21792 + {
21793 + AVR32_OPC_LD_UH3, 2, 0x80800000, 0xe1800000,
21794 + &avr32_syntax_table[AVR32_SYNTAX_LD_UH3],
21795 + BFD_RELOC_AVR32_4UH, 3, 2,
21796 + {
21797 + &avr32_ifield_table[AVR32_IFIELD_RY],
21798 + &avr32_ifield_table[AVR32_IFIELD_RX],
21799 + &avr32_ifield_table[AVR32_IFIELD_K3],
21800 + },
21801 + },
21802 + {
21803 + AVR32_OPC_LD_UH4, 4, 0xe1100000, 0xe1f00000,
21804 + &avr32_syntax_table[AVR32_SYNTAX_LD_UH4],
21805 + BFD_RELOC_AVR32_16S, 3, 2,
21806 + {
21807 + &avr32_ifield_table[AVR32_IFIELD_RY],
21808 + &avr32_ifield_table[AVR32_IFIELD_RX],
21809 + &avr32_ifield_table[AVR32_IFIELD_K16],
21810 + },
21811 + },
21812 + {
21813 + AVR32_OPC_LD_W1, 2, 0x01000000, 0xe1f00000,
21814 + &avr32_syntax_table[AVR32_SYNTAX_LD_W1],
21815 + BFD_RELOC_UNUSED, 2, -1,
21816 + {
21817 + &avr32_ifield_table[AVR32_IFIELD_RY],
21818 + &avr32_ifield_table[AVR32_IFIELD_RX],
21819 + },
21820 + },
21821 + {
21822 + AVR32_OPC_LD_W2, 2, 0x01400000, 0xe1f00000,
21823 + &avr32_syntax_table[AVR32_SYNTAX_LD_W2],
21824 + BFD_RELOC_UNUSED, 2, -1,
21825 + {
21826 + &avr32_ifield_table[AVR32_IFIELD_RY],
21827 + &avr32_ifield_table[AVR32_IFIELD_RX],
21828 + },
21829 + },
21830 + {
21831 + AVR32_OPC_LD_W5, 4, 0xe0000300, 0xe1f0ffc0,
21832 + &avr32_syntax_table[AVR32_SYNTAX_LD_W5],
21833 + BFD_RELOC_UNUSED, 4, -1,
21834 + {
21835 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21836 + &avr32_ifield_table[AVR32_IFIELD_RX],
21837 + &avr32_ifield_table[AVR32_IFIELD_RY],
21838 + &avr32_ifield_table[AVR32_IFIELD_K2],
21839 + },
21840 + },
21841 + {
21842 + AVR32_OPC_LD_W6, 4, 0xe0000f80, 0xe1f0ffc0,
21843 + &avr32_syntax_table[AVR32_SYNTAX_LD_W6],
21844 + BFD_RELOC_UNUSED, 4, -1,
21845 + {
21846 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21847 + &avr32_ifield_table[AVR32_IFIELD_RX],
21848 + &avr32_ifield_table[AVR32_IFIELD_RY],
21849 + &avr32_ifield_table[AVR32_IFIELD_K2],
21850 + },
21851 + },
21852 + {
21853 + AVR32_OPC_LD_W3, 2, 0x60000000, 0xe0000000,
21854 + &avr32_syntax_table[AVR32_SYNTAX_LD_W3],
21855 + BFD_RELOC_AVR32_7UW, 3, 2,
21856 + {
21857 + &avr32_ifield_table[AVR32_IFIELD_RY],
21858 + &avr32_ifield_table[AVR32_IFIELD_RX],
21859 + &avr32_ifield_table[AVR32_IFIELD_K5C],
21860 + },
21861 + },
21862 + {
21863 + AVR32_OPC_LD_W4, 4, 0xe0f00000, 0xe1f00000,
21864 + &avr32_syntax_table[AVR32_SYNTAX_LD_W4],
21865 + BFD_RELOC_AVR32_16S, 3, 2,
21866 + {
21867 + &avr32_ifield_table[AVR32_IFIELD_RY],
21868 + &avr32_ifield_table[AVR32_IFIELD_RX],
21869 + &avr32_ifield_table[AVR32_IFIELD_K16],
21870 + },
21871 + },
21872 + {
21873 + AVR32_OPC_LDC_D1, 4, 0xe9a01000, 0xfff01100,
21874 + &avr32_syntax_table[AVR32_SYNTAX_LDC_D1],
21875 + BFD_RELOC_AVR32_10UW, 4, 3,
21876 + {
21877 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21878 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
21879 + &avr32_ifield_table[AVR32_IFIELD_RY],
21880 + &avr32_ifield_table[AVR32_IFIELD_K8E],
21881 + },
21882 + },
21883 + {
21884 + AVR32_OPC_LDC_D2, 4, 0xefa00050, 0xfff011ff,
21885 + &avr32_syntax_table[AVR32_SYNTAX_LDC_D2],
21886 + BFD_RELOC_UNUSED, 3, -1,
21887 + {
21888 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21889 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
21890 + &avr32_ifield_table[AVR32_IFIELD_RY],
21891 + },
21892 + },
21893 + {
21894 + AVR32_OPC_LDC_D3, 4, 0xefa01040, 0xfff011c0,
21895 + &avr32_syntax_table[AVR32_SYNTAX_LDC_D3],
21896 + BFD_RELOC_UNUSED, 5, -1,
21897 + {
21898 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21899 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
21900 + &avr32_ifield_table[AVR32_IFIELD_RY],
21901 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21902 + &avr32_ifield_table[AVR32_IFIELD_K2],
21903 + },
21904 + },
21905 + {
21906 + AVR32_OPC_LDC_W1, 4, 0xe9a00000, 0xfff01000,
21907 + &avr32_syntax_table[AVR32_SYNTAX_LDC_W1],
21908 + BFD_RELOC_AVR32_10UW, 4, 3,
21909 + {
21910 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21911 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
21912 + &avr32_ifield_table[AVR32_IFIELD_RY],
21913 + &avr32_ifield_table[AVR32_IFIELD_K8E],
21914 + },
21915 + },
21916 + {
21917 + AVR32_OPC_LDC_W2, 4, 0xefa00040, 0xfff010ff,
21918 + &avr32_syntax_table[AVR32_SYNTAX_LDC_W2],
21919 + BFD_RELOC_UNUSED, 3, -1,
21920 + {
21921 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21922 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
21923 + &avr32_ifield_table[AVR32_IFIELD_RY],
21924 + },
21925 + },
21926 + {
21927 + AVR32_OPC_LDC_W3, 4, 0xefa01000, 0xfff010c0,
21928 + &avr32_syntax_table[AVR32_SYNTAX_LDC_W3],
21929 + BFD_RELOC_UNUSED, 5, -1,
21930 + {
21931 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21932 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
21933 + &avr32_ifield_table[AVR32_IFIELD_RY],
21934 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
21935 + &avr32_ifield_table[AVR32_IFIELD_K2],
21936 + },
21937 + },
21938 + {
21939 + AVR32_OPC_LDC0_D, 4, 0xf3a00000, 0xfff00100,
21940 + &avr32_syntax_table[AVR32_SYNTAX_LDC0_D],
21941 + BFD_RELOC_AVR32_14UW, 3, 2,
21942 + {
21943 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
21944 + &avr32_ifield_table[AVR32_IFIELD_RY],
21945 + &avr32_ifield_table[AVR32_IFIELD_K12CP],
21946 + },
21947 + },
21948 + {
21949 + AVR32_OPC_LDC0_W, 4, 0xf1a00000, 0xfff00000,
21950 + &avr32_syntax_table[AVR32_SYNTAX_LDC0_W],
21951 + BFD_RELOC_AVR32_14UW, 3, 2,
21952 + {
21953 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
21954 + &avr32_ifield_table[AVR32_IFIELD_RY],
21955 + &avr32_ifield_table[AVR32_IFIELD_K12CP],
21956 + },
21957 + },
21958 + {
21959 + AVR32_OPC_LDCM_D, 4, 0xeda00400, 0xfff01f00,
21960 + &avr32_syntax_table[AVR32_SYNTAX_LDCM_D],
21961 + BFD_RELOC_UNUSED, 3, -1,
21962 + {
21963 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21964 + &avr32_ifield_table[AVR32_IFIELD_RY],
21965 + &avr32_ifield_table[AVR32_IFIELD_K8E],
21966 + },
21967 + },
21968 + {
21969 + AVR32_OPC_LDCM_D_PU, 4, 0xeda01400, 0xfff01f00,
21970 + &avr32_syntax_table[AVR32_SYNTAX_LDCM_D_PU],
21971 + BFD_RELOC_UNUSED, 3, -1,
21972 + {
21973 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21974 + &avr32_ifield_table[AVR32_IFIELD_RY],
21975 + &avr32_ifield_table[AVR32_IFIELD_K8E],
21976 + },
21977 + },
21978 + {
21979 + AVR32_OPC_LDCM_W, 4, 0xeda00000, 0xfff01e00,
21980 + &avr32_syntax_table[AVR32_SYNTAX_LDCM_W],
21981 + BFD_RELOC_UNUSED, 4, -1,
21982 + {
21983 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21984 + &avr32_ifield_table[AVR32_IFIELD_RY],
21985 + &avr32_ifield_table[AVR32_IFIELD_K8E],
21986 + &avr32_ifield_table[AVR32_IFIELD_CM_HL],
21987 + },
21988 + },
21989 + {
21990 + AVR32_OPC_LDCM_W_PU, 4, 0xeda01000, 0xfff01e00,
21991 + &avr32_syntax_table[AVR32_SYNTAX_LDCM_W_PU],
21992 + BFD_RELOC_UNUSED, 4, -1,
21993 + {
21994 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
21995 + &avr32_ifield_table[AVR32_IFIELD_RY],
21996 + &avr32_ifield_table[AVR32_IFIELD_K8E],
21997 + &avr32_ifield_table[AVR32_IFIELD_CM_HL],
21998 + },
21999 + },
22000 + {
22001 + AVR32_OPC_LDDPC, 2, 0x48000000, 0xf8000000,
22002 + &avr32_syntax_table[AVR32_SYNTAX_LDDPC],
22003 + BFD_RELOC_AVR32_9UW_PCREL, 2, 1,
22004 + {
22005 + &avr32_ifield_table[AVR32_IFIELD_RY],
22006 + &avr32_ifield_table[AVR32_IFIELD_K7C],
22007 + },
22008 + },
22009 + {
22010 + AVR32_OPC_LDDPC_EXT, 4, 0xfef00000, 0xfff00000,
22011 + &avr32_syntax_table[AVR32_SYNTAX_LDDPC_EXT],
22012 + BFD_RELOC_AVR32_16B_PCREL, 2, 1,
22013 + {
22014 + &avr32_ifield_table[AVR32_IFIELD_RY],
22015 + &avr32_ifield_table[AVR32_IFIELD_K16],
22016 + },
22017 + },
22018 + {
22019 + AVR32_OPC_LDDSP, 2, 0x40000000, 0xf8000000,
22020 + &avr32_syntax_table[AVR32_SYNTAX_LDDSP],
22021 + BFD_RELOC_UNUSED, 2, -1,
22022 + {
22023 + &avr32_ifield_table[AVR32_IFIELD_RY],
22024 + &avr32_ifield_table[AVR32_IFIELD_K7C],
22025 + },
22026 + },
22027 + {
22028 + AVR32_OPC_LDINS_B, 4, 0xe1d04000, 0xe1f0c000,
22029 + &avr32_syntax_table[AVR32_SYNTAX_LDINS_B],
22030 + BFD_RELOC_UNUSED, 4, -1,
22031 + {
22032 + &avr32_ifield_table[AVR32_IFIELD_RY],
22033 + &avr32_ifield_table[AVR32_IFIELD_PART2_K12],
22034 + &avr32_ifield_table[AVR32_IFIELD_RX],
22035 + &avr32_ifield_table[AVR32_IFIELD_K12],
22036 + },
22037 + },
22038 + {
22039 + AVR32_OPC_LDINS_H, 4, 0xe1d00000, 0xe1f0e000,
22040 + &avr32_syntax_table[AVR32_SYNTAX_LDINS_H],
22041 + BFD_RELOC_UNUSED, 4, -1,
22042 + {
22043 + &avr32_ifield_table[AVR32_IFIELD_RY],
22044 + &avr32_ifield_table[AVR32_IFIELD_PART1_K12],
22045 + &avr32_ifield_table[AVR32_IFIELD_RX],
22046 + &avr32_ifield_table[AVR32_IFIELD_K12],
22047 + },
22048 + },
22049 + {
22050 + AVR32_OPC_LDM, 4, 0xe1c00000, 0xfdf00000,
22051 + &avr32_syntax_table[AVR32_SYNTAX_LDM],
22052 + BFD_RELOC_UNUSED, 3, -1,
22053 + {
22054 + &avr32_ifield_table[AVR32_IFIELD_RY],
22055 + &avr32_ifield_table[AVR32_IFIELD_W],
22056 + &avr32_ifield_table[AVR32_IFIELD_K16],
22057 + },
22058 + },
22059 + {
22060 + AVR32_OPC_LDMTS, 4, 0xe5c00000, 0xfff00000,
22061 + &avr32_syntax_table[AVR32_SYNTAX_LDMTS],
22062 + BFD_RELOC_UNUSED, 2, -1,
22063 + {
22064 + &avr32_ifield_table[AVR32_IFIELD_RY],
22065 + &avr32_ifield_table[AVR32_IFIELD_K16],
22066 + },
22067 + },
22068 + {
22069 + AVR32_OPC_LDMTS_PU, 4, 0xe7c00000, 0xfff00000,
22070 + &avr32_syntax_table[AVR32_SYNTAX_LDMTS_PU],
22071 + BFD_RELOC_UNUSED, 2, -1,
22072 + {
22073 + &avr32_ifield_table[AVR32_IFIELD_RY],
22074 + &avr32_ifield_table[AVR32_IFIELD_K16],
22075 + },
22076 + },
22077 + {
22078 + AVR32_OPC_LDSWP_SH, 4, 0xe1d02000, 0xe1f0f000,
22079 + &avr32_syntax_table[AVR32_SYNTAX_LDSWP_SH],
22080 + BFD_RELOC_UNUSED, 3, -1,
22081 + {
22082 + &avr32_ifield_table[AVR32_IFIELD_RY],
22083 + &avr32_ifield_table[AVR32_IFIELD_RX],
22084 + &avr32_ifield_table[AVR32_IFIELD_K12],
22085 + },
22086 + },
22087 + {
22088 + AVR32_OPC_LDSWP_UH, 4, 0xe1d03000, 0xe1f0f000,
22089 + &avr32_syntax_table[AVR32_SYNTAX_LDSWP_UH],
22090 + BFD_RELOC_UNUSED, 3, -1,
22091 + {
22092 + &avr32_ifield_table[AVR32_IFIELD_RY],
22093 + &avr32_ifield_table[AVR32_IFIELD_RX],
22094 + &avr32_ifield_table[AVR32_IFIELD_K12],
22095 + },
22096 + },
22097 + {
22098 + AVR32_OPC_LDSWP_W, 4, 0xe1d08000, 0xe1f0f000,
22099 + &avr32_syntax_table[AVR32_SYNTAX_LDSWP_W],
22100 + BFD_RELOC_UNUSED, 3, -1,
22101 + {
22102 + &avr32_ifield_table[AVR32_IFIELD_RY],
22103 + &avr32_ifield_table[AVR32_IFIELD_RX],
22104 + &avr32_ifield_table[AVR32_IFIELD_K12],
22105 + },
22106 + },
22107 + {
22108 + AVR32_OPC_LSL1, 4, 0xe0000940, 0xe1f0fff0,
22109 + &avr32_syntax_table[AVR32_SYNTAX_LSL1],
22110 + BFD_RELOC_UNUSED, 3, -1,
22111 + {
22112 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22113 + &avr32_ifield_table[AVR32_IFIELD_RX],
22114 + &avr32_ifield_table[AVR32_IFIELD_RY],
22115 + },
22116 + },
22117 + {
22118 + AVR32_OPC_LSL3, 4, 0xe0001500, 0xe1f0ffe0,
22119 + &avr32_syntax_table[AVR32_SYNTAX_LSL3],
22120 + BFD_RELOC_UNUSED, 3, -1,
22121 + {
22122 + &avr32_ifield_table[AVR32_IFIELD_RY],
22123 + &avr32_ifield_table[AVR32_IFIELD_RX],
22124 + &avr32_ifield_table[AVR32_IFIELD_K5E],
22125 + },
22126 + },
22127 + {
22128 + AVR32_OPC_LSL2, 2, 0xa1600000, 0xe1e00000,
22129 + &avr32_syntax_table[AVR32_SYNTAX_LSL2],
22130 + BFD_RELOC_UNUSED, 2, -1,
22131 + {
22132 + &avr32_ifield_table[AVR32_IFIELD_RY],
22133 + &avr32_ifield_table[AVR32_IFIELD_BIT5C],
22134 + },
22135 + },
22136 + {
22137 + AVR32_OPC_LSR1, 4, 0xe0000a40, 0xe1f0fff0,
22138 + &avr32_syntax_table[AVR32_SYNTAX_LSR1],
22139 + BFD_RELOC_UNUSED, 3, -1,
22140 + {
22141 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22142 + &avr32_ifield_table[AVR32_IFIELD_RX],
22143 + &avr32_ifield_table[AVR32_IFIELD_RY],
22144 + },
22145 + },
22146 + {
22147 + AVR32_OPC_LSR3, 4, 0xe0001600, 0xe1f0ffe0,
22148 + &avr32_syntax_table[AVR32_SYNTAX_LSR3],
22149 + BFD_RELOC_UNUSED, 3, -1,
22150 + {
22151 + &avr32_ifield_table[AVR32_IFIELD_RY],
22152 + &avr32_ifield_table[AVR32_IFIELD_RX],
22153 + &avr32_ifield_table[AVR32_IFIELD_K5E],
22154 + },
22155 + },
22156 + {
22157 + AVR32_OPC_LSR2, 2, 0xa1800000, 0xe1e00000,
22158 + &avr32_syntax_table[AVR32_SYNTAX_LSR2],
22159 + BFD_RELOC_UNUSED, 2, -1,
22160 + {
22161 + &avr32_ifield_table[AVR32_IFIELD_RY],
22162 + &avr32_ifield_table[AVR32_IFIELD_BIT5C],
22163 + },
22164 + },
22165 + {
22166 + AVR32_OPC_MAC, 4, 0xe0000340, 0xe1f0fff0,
22167 + &avr32_syntax_table[AVR32_SYNTAX_MAC],
22168 + BFD_RELOC_UNUSED, 3, -1,
22169 + {
22170 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22171 + &avr32_ifield_table[AVR32_IFIELD_RX],
22172 + &avr32_ifield_table[AVR32_IFIELD_RY],
22173 + },
22174 + },
22175 + {
22176 + AVR32_OPC_MACHH_D, 4, 0xe0000580, 0xe1f0ffc1,
22177 + &avr32_syntax_table[AVR32_SYNTAX_MACHH_D],
22178 + BFD_RELOC_UNUSED, 5, -1,
22179 + {
22180 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22181 + &avr32_ifield_table[AVR32_IFIELD_RX],
22182 + &avr32_ifield_table[AVR32_IFIELD_X],
22183 + &avr32_ifield_table[AVR32_IFIELD_RY],
22184 + &avr32_ifield_table[AVR32_IFIELD_Y],
22185 + },
22186 + },
22187 + {
22188 + AVR32_OPC_MACHH_W, 4, 0xe0000480, 0xe1f0ffc0,
22189 + &avr32_syntax_table[AVR32_SYNTAX_MACHH_W],
22190 + BFD_RELOC_UNUSED, 5, -1,
22191 + {
22192 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22193 + &avr32_ifield_table[AVR32_IFIELD_RX],
22194 + &avr32_ifield_table[AVR32_IFIELD_X],
22195 + &avr32_ifield_table[AVR32_IFIELD_RY],
22196 + &avr32_ifield_table[AVR32_IFIELD_Y],
22197 + },
22198 + },
22199 + {
22200 + AVR32_OPC_MACS_D, 4, 0xe0000540, 0xe1f0fff1,
22201 + &avr32_syntax_table[AVR32_SYNTAX_MACS_D],
22202 + BFD_RELOC_UNUSED, 3, -1,
22203 + {
22204 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22205 + &avr32_ifield_table[AVR32_IFIELD_RX],
22206 + &avr32_ifield_table[AVR32_IFIELD_RY],
22207 + },
22208 + },
22209 + {
22210 + AVR32_OPC_MACSATHH_W, 4, 0xe0000680, 0xe1f0ffc0,
22211 + &avr32_syntax_table[AVR32_SYNTAX_MACSATHH_W],
22212 + BFD_RELOC_UNUSED, 5, -1,
22213 + {
22214 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22215 + &avr32_ifield_table[AVR32_IFIELD_RX],
22216 + &avr32_ifield_table[AVR32_IFIELD_X],
22217 + &avr32_ifield_table[AVR32_IFIELD_RY],
22218 + &avr32_ifield_table[AVR32_IFIELD_Y],
22219 + },
22220 + },
22221 + {
22222 + AVR32_OPC_MACUD, 4, 0xe0000740, 0xe1f0fff1,
22223 + &avr32_syntax_table[AVR32_SYNTAX_MACUD],
22224 + BFD_RELOC_UNUSED, 3, -1,
22225 + {
22226 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22227 + &avr32_ifield_table[AVR32_IFIELD_RX],
22228 + &avr32_ifield_table[AVR32_IFIELD_RY],
22229 + },
22230 + },
22231 + {
22232 + AVR32_OPC_MACWH_D, 4, 0xe0000c80, 0xe1f0ffe1,
22233 + &avr32_syntax_table[AVR32_SYNTAX_MACWH_D],
22234 + BFD_RELOC_UNUSED, 4, -1,
22235 + {
22236 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22237 + &avr32_ifield_table[AVR32_IFIELD_RX],
22238 + &avr32_ifield_table[AVR32_IFIELD_RY],
22239 + &avr32_ifield_table[AVR32_IFIELD_Y],
22240 + },
22241 + },
22242 + {
22243 + AVR32_OPC_MAX, 4, 0xe0000c40, 0xe1f0fff0,
22244 + &avr32_syntax_table[AVR32_SYNTAX_MAX],
22245 + BFD_RELOC_UNUSED, 3, -1,
22246 + {
22247 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22248 + &avr32_ifield_table[AVR32_IFIELD_RX],
22249 + &avr32_ifield_table[AVR32_IFIELD_RY],
22250 + },
22251 + },
22252 + {
22253 + AVR32_OPC_MCALL, 4, 0xf0100000, 0xfff00000,
22254 + &avr32_syntax_table[AVR32_SYNTAX_MCALL],
22255 + BFD_RELOC_AVR32_18W_PCREL, 2, 1,
22256 + {
22257 + &avr32_ifield_table[AVR32_IFIELD_RY],
22258 + &avr32_ifield_table[AVR32_IFIELD_K16],
22259 + },
22260 + },
22261 + {
22262 + AVR32_OPC_MFDR, 4, 0xe5b00000, 0xfff0ff00,
22263 + &avr32_syntax_table[AVR32_SYNTAX_MFDR],
22264 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22265 + {
22266 + &avr32_ifield_table[AVR32_IFIELD_RY],
22267 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22268 + },
22269 + },
22270 + {
22271 + AVR32_OPC_MFSR, 4, 0xe1b00000, 0xfff0ff00,
22272 + &avr32_syntax_table[AVR32_SYNTAX_MFSR],
22273 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22274 + {
22275 + &avr32_ifield_table[AVR32_IFIELD_RY],
22276 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22277 + },
22278 + },
22279 + {
22280 + AVR32_OPC_MIN, 4, 0xe0000d40, 0xe1f0fff0,
22281 + &avr32_syntax_table[AVR32_SYNTAX_MIN],
22282 + BFD_RELOC_UNUSED, 3, -1,
22283 + {
22284 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22285 + &avr32_ifield_table[AVR32_IFIELD_RX],
22286 + &avr32_ifield_table[AVR32_IFIELD_RY],
22287 + },
22288 + },
22289 + {
22290 + AVR32_OPC_MOV3, 2, 0x00900000, 0xe1f00000,
22291 + &avr32_syntax_table[AVR32_SYNTAX_MOV3],
22292 + BFD_RELOC_NONE, 2, -1,
22293 + {
22294 + &avr32_ifield_table[AVR32_IFIELD_RY],
22295 + &avr32_ifield_table[AVR32_IFIELD_RX],
22296 + },
22297 + },
22298 + {
22299 + AVR32_OPC_MOV1, 2, 0x30000000, 0xf0000000,
22300 + &avr32_syntax_table[AVR32_SYNTAX_MOV1],
22301 + BFD_RELOC_AVR32_8S, 2, 1,
22302 + {
22303 + &avr32_ifield_table[AVR32_IFIELD_RY],
22304 + &avr32_ifield_table[AVR32_IFIELD_K8C],
22305 + },
22306 + },
22307 + {
22308 + AVR32_OPC_MOV2, 4, 0xe0600000, 0xe1e00000,
22309 + &avr32_syntax_table[AVR32_SYNTAX_MOV2],
22310 + BFD_RELOC_AVR32_21S, 2, 1,
22311 + {
22312 + &avr32_ifield_table[AVR32_IFIELD_RY],
22313 + &avr32_ifield_table[AVR32_IFIELD_K21],
22314 + },
22315 + },
22316 + {
22317 + AVR32_OPC_MOVEQ1, 4, 0xe0001700, 0xe1f0ffff,
22318 + &avr32_syntax_table[AVR32_SYNTAX_MOVEQ1],
22319 + BFD_RELOC_UNUSED, 2, -1,
22320 + {
22321 + &avr32_ifield_table[AVR32_IFIELD_RY],
22322 + &avr32_ifield_table[AVR32_IFIELD_RX],
22323 + },
22324 + },
22325 + {
22326 + AVR32_OPC_MOVNE1, 4, 0xe0001710, 0xe1f0ffff,
22327 + &avr32_syntax_table[AVR32_SYNTAX_MOVNE1],
22328 + BFD_RELOC_UNUSED, 2, -1,
22329 + {
22330 + &avr32_ifield_table[AVR32_IFIELD_RY],
22331 + &avr32_ifield_table[AVR32_IFIELD_RX],
22332 + },
22333 + },
22334 + {
22335 + AVR32_OPC_MOVCC1, 4, 0xe0001720, 0xe1f0ffff,
22336 + &avr32_syntax_table[AVR32_SYNTAX_MOVHS1],
22337 + BFD_RELOC_UNUSED, 2, -1,
22338 + {
22339 + &avr32_ifield_table[AVR32_IFIELD_RY],
22340 + &avr32_ifield_table[AVR32_IFIELD_RX],
22341 + },
22342 + },
22343 + {
22344 + AVR32_OPC_MOVCS1, 4, 0xe0001730, 0xe1f0ffff,
22345 + &avr32_syntax_table[AVR32_SYNTAX_MOVLO1],
22346 + BFD_RELOC_UNUSED, 2, -1,
22347 + {
22348 + &avr32_ifield_table[AVR32_IFIELD_RY],
22349 + &avr32_ifield_table[AVR32_IFIELD_RX],
22350 + },
22351 + },
22352 + {
22353 + AVR32_OPC_MOVGE1, 4, 0xe0001740, 0xe1f0ffff,
22354 + &avr32_syntax_table[AVR32_SYNTAX_MOVGE1],
22355 + BFD_RELOC_UNUSED, 2, -1,
22356 + {
22357 + &avr32_ifield_table[AVR32_IFIELD_RY],
22358 + &avr32_ifield_table[AVR32_IFIELD_RX],
22359 + },
22360 + },
22361 + {
22362 + AVR32_OPC_MOVLT1, 4, 0xe0001750, 0xe1f0ffff,
22363 + &avr32_syntax_table[AVR32_SYNTAX_MOVLT1],
22364 + BFD_RELOC_UNUSED, 2, -1,
22365 + {
22366 + &avr32_ifield_table[AVR32_IFIELD_RY],
22367 + &avr32_ifield_table[AVR32_IFIELD_RX],
22368 + },
22369 + },
22370 + {
22371 + AVR32_OPC_MOVMI1, 4, 0xe0001760, 0xe1f0ffff,
22372 + &avr32_syntax_table[AVR32_SYNTAX_MOVMI1],
22373 + BFD_RELOC_UNUSED, 2, -1,
22374 + {
22375 + &avr32_ifield_table[AVR32_IFIELD_RY],
22376 + &avr32_ifield_table[AVR32_IFIELD_RX],
22377 + },
22378 + },
22379 + {
22380 + AVR32_OPC_MOVPL1, 4, 0xe0001770, 0xe1f0ffff,
22381 + &avr32_syntax_table[AVR32_SYNTAX_MOVPL1],
22382 + BFD_RELOC_UNUSED, 2, -1,
22383 + {
22384 + &avr32_ifield_table[AVR32_IFIELD_RY],
22385 + &avr32_ifield_table[AVR32_IFIELD_RX],
22386 + },
22387 + },
22388 + {
22389 + AVR32_OPC_MOVLS1, 4, 0xe0001780, 0xe1f0ffff,
22390 + &avr32_syntax_table[AVR32_SYNTAX_MOVLS1],
22391 + BFD_RELOC_UNUSED, 2, -1,
22392 + {
22393 + &avr32_ifield_table[AVR32_IFIELD_RY],
22394 + &avr32_ifield_table[AVR32_IFIELD_RX],
22395 + },
22396 + },
22397 + {
22398 + AVR32_OPC_MOVGT1, 4, 0xe0001790, 0xe1f0ffff,
22399 + &avr32_syntax_table[AVR32_SYNTAX_MOVGT1],
22400 + BFD_RELOC_UNUSED, 2, -1,
22401 + {
22402 + &avr32_ifield_table[AVR32_IFIELD_RY],
22403 + &avr32_ifield_table[AVR32_IFIELD_RX],
22404 + },
22405 + },
22406 + {
22407 + AVR32_OPC_MOVLE1, 4, 0xe00017a0, 0xe1f0ffff,
22408 + &avr32_syntax_table[AVR32_SYNTAX_MOVLE1],
22409 + BFD_RELOC_UNUSED, 2, -1,
22410 + {
22411 + &avr32_ifield_table[AVR32_IFIELD_RY],
22412 + &avr32_ifield_table[AVR32_IFIELD_RX],
22413 + },
22414 + },
22415 + {
22416 + AVR32_OPC_MOVHI1, 4, 0xe00017b0, 0xe1f0ffff,
22417 + &avr32_syntax_table[AVR32_SYNTAX_MOVHI1],
22418 + BFD_RELOC_UNUSED, 2, -1,
22419 + {
22420 + &avr32_ifield_table[AVR32_IFIELD_RY],
22421 + &avr32_ifield_table[AVR32_IFIELD_RX],
22422 + },
22423 + },
22424 + {
22425 + AVR32_OPC_MOVVS1, 4, 0xe00017c0, 0xe1f0ffff,
22426 + &avr32_syntax_table[AVR32_SYNTAX_MOVVS1],
22427 + BFD_RELOC_UNUSED, 2, -1,
22428 + {
22429 + &avr32_ifield_table[AVR32_IFIELD_RY],
22430 + &avr32_ifield_table[AVR32_IFIELD_RX],
22431 + },
22432 + },
22433 + {
22434 + AVR32_OPC_MOVVC1, 4, 0xe00017d0, 0xe1f0ffff,
22435 + &avr32_syntax_table[AVR32_SYNTAX_MOVVC1],
22436 + BFD_RELOC_UNUSED, 2, -1,
22437 + {
22438 + &avr32_ifield_table[AVR32_IFIELD_RY],
22439 + &avr32_ifield_table[AVR32_IFIELD_RX],
22440 + },
22441 + },
22442 + {
22443 + AVR32_OPC_MOVQS1, 4, 0xe00017e0, 0xe1f0ffff,
22444 + &avr32_syntax_table[AVR32_SYNTAX_MOVQS1],
22445 + BFD_RELOC_UNUSED, 2, -1,
22446 + {
22447 + &avr32_ifield_table[AVR32_IFIELD_RY],
22448 + &avr32_ifield_table[AVR32_IFIELD_RX],
22449 + },
22450 + },
22451 + {
22452 + AVR32_OPC_MOVAL1, 4, 0xe00017f0, 0xe1f0ffff,
22453 + &avr32_syntax_table[AVR32_SYNTAX_MOVAL1],
22454 + BFD_RELOC_UNUSED, 2, -1,
22455 + {
22456 + &avr32_ifield_table[AVR32_IFIELD_RY],
22457 + &avr32_ifield_table[AVR32_IFIELD_RX],
22458 + },
22459 + },
22460 + {
22461 + AVR32_OPC_MOVEQ2, 4, 0xf9b00000, 0xfff0ff00,
22462 + &avr32_syntax_table[AVR32_SYNTAX_MOVEQ2],
22463 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22464 + {
22465 + &avr32_ifield_table[AVR32_IFIELD_RY],
22466 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22467 + },
22468 + },
22469 + {
22470 + AVR32_OPC_MOVNE2, 4, 0xf9b00100, 0xfff0ff00,
22471 + &avr32_syntax_table[AVR32_SYNTAX_MOVNE2],
22472 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22473 + {
22474 + &avr32_ifield_table[AVR32_IFIELD_RY],
22475 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22476 + },
22477 + },
22478 + {
22479 + AVR32_OPC_MOVCC2, 4, 0xf9b00200, 0xfff0ff00,
22480 + &avr32_syntax_table[AVR32_SYNTAX_MOVHS2],
22481 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22482 + {
22483 + &avr32_ifield_table[AVR32_IFIELD_RY],
22484 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22485 + },
22486 + },
22487 + {
22488 + AVR32_OPC_MOVCS2, 4, 0xf9b00300, 0xfff0ff00,
22489 + &avr32_syntax_table[AVR32_SYNTAX_MOVLO2],
22490 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22491 + {
22492 + &avr32_ifield_table[AVR32_IFIELD_RY],
22493 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22494 + },
22495 + },
22496 + {
22497 + AVR32_OPC_MOVGE2, 4, 0xf9b00400, 0xfff0ff00,
22498 + &avr32_syntax_table[AVR32_SYNTAX_MOVGE2],
22499 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22500 + {
22501 + &avr32_ifield_table[AVR32_IFIELD_RY],
22502 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22503 + },
22504 + },
22505 + {
22506 + AVR32_OPC_MOVLT2, 4, 0xf9b00500, 0xfff0ff00,
22507 + &avr32_syntax_table[AVR32_SYNTAX_MOVLT2],
22508 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22509 + {
22510 + &avr32_ifield_table[AVR32_IFIELD_RY],
22511 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22512 + },
22513 + },
22514 + {
22515 + AVR32_OPC_MOVMI2, 4, 0xf9b00600, 0xfff0ff00,
22516 + &avr32_syntax_table[AVR32_SYNTAX_MOVMI2],
22517 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22518 + {
22519 + &avr32_ifield_table[AVR32_IFIELD_RY],
22520 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22521 + },
22522 + },
22523 + {
22524 + AVR32_OPC_MOVPL2, 4, 0xf9b00700, 0xfff0ff00,
22525 + &avr32_syntax_table[AVR32_SYNTAX_MOVPL2],
22526 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22527 + {
22528 + &avr32_ifield_table[AVR32_IFIELD_RY],
22529 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22530 + },
22531 + },
22532 + {
22533 + AVR32_OPC_MOVLS2, 4, 0xf9b00800, 0xfff0ff00,
22534 + &avr32_syntax_table[AVR32_SYNTAX_MOVLS2],
22535 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22536 + {
22537 + &avr32_ifield_table[AVR32_IFIELD_RY],
22538 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22539 + },
22540 + },
22541 + {
22542 + AVR32_OPC_MOVGT2, 4, 0xf9b00900, 0xfff0ff00,
22543 + &avr32_syntax_table[AVR32_SYNTAX_MOVGT2],
22544 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22545 + {
22546 + &avr32_ifield_table[AVR32_IFIELD_RY],
22547 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22548 + },
22549 + },
22550 + {
22551 + AVR32_OPC_MOVLE2, 4, 0xf9b00a00, 0xfff0ff00,
22552 + &avr32_syntax_table[AVR32_SYNTAX_MOVLE2],
22553 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22554 + {
22555 + &avr32_ifield_table[AVR32_IFIELD_RY],
22556 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22557 + },
22558 + },
22559 + {
22560 + AVR32_OPC_MOVHI2, 4, 0xf9b00b00, 0xfff0ff00,
22561 + &avr32_syntax_table[AVR32_SYNTAX_MOVHI2],
22562 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22563 + {
22564 + &avr32_ifield_table[AVR32_IFIELD_RY],
22565 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22566 + },
22567 + },
22568 + {
22569 + AVR32_OPC_MOVVS2, 4, 0xf9b00c00, 0xfff0ff00,
22570 + &avr32_syntax_table[AVR32_SYNTAX_MOVVS2],
22571 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22572 + {
22573 + &avr32_ifield_table[AVR32_IFIELD_RY],
22574 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22575 + },
22576 + },
22577 + {
22578 + AVR32_OPC_MOVVC2, 4, 0xf9b00d00, 0xfff0ff00,
22579 + &avr32_syntax_table[AVR32_SYNTAX_MOVVC2],
22580 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22581 + {
22582 + &avr32_ifield_table[AVR32_IFIELD_RY],
22583 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22584 + },
22585 + },
22586 + {
22587 + AVR32_OPC_MOVQS2, 4, 0xf9b00e00, 0xfff0ff00,
22588 + &avr32_syntax_table[AVR32_SYNTAX_MOVQS2],
22589 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22590 + {
22591 + &avr32_ifield_table[AVR32_IFIELD_RY],
22592 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22593 + },
22594 + },
22595 + {
22596 + AVR32_OPC_MOVAL2, 4, 0xf9b00f00, 0xfff0ff00,
22597 + &avr32_syntax_table[AVR32_SYNTAX_MOVAL2],
22598 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
22599 + {
22600 + &avr32_ifield_table[AVR32_IFIELD_RY],
22601 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22602 + },
22603 + },
22604 + {
22605 + AVR32_OPC_MTDR, 4, 0xe7b00000, 0xfff0ff00,
22606 + &avr32_syntax_table[AVR32_SYNTAX_MTDR],
22607 + BFD_RELOC_AVR32_8S_EXT, 2, 0,
22608 + {
22609 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22610 + &avr32_ifield_table[AVR32_IFIELD_RY],
22611 + },
22612 + },
22613 + {
22614 + AVR32_OPC_MTSR, 4, 0xe3b00000, 0xfff0ff00,
22615 + &avr32_syntax_table[AVR32_SYNTAX_MTSR],
22616 + BFD_RELOC_AVR32_8S_EXT, 2, 0,
22617 + {
22618 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22619 + &avr32_ifield_table[AVR32_IFIELD_RY],
22620 + },
22621 + },
22622 + {
22623 + AVR32_OPC_MUL1, 2, 0xa1300000, 0xe1f00000,
22624 + &avr32_syntax_table[AVR32_SYNTAX_MUL1],
22625 + BFD_RELOC_UNUSED, 2, -1,
22626 + {
22627 + &avr32_ifield_table[AVR32_IFIELD_RY],
22628 + &avr32_ifield_table[AVR32_IFIELD_RX],
22629 + },
22630 + },
22631 + {
22632 + AVR32_OPC_MUL2, 4, 0xe0000240, 0xe1f0fff0,
22633 + &avr32_syntax_table[AVR32_SYNTAX_MUL2],
22634 + BFD_RELOC_UNUSED, 3, -1,
22635 + {
22636 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22637 + &avr32_ifield_table[AVR32_IFIELD_RX],
22638 + &avr32_ifield_table[AVR32_IFIELD_RY],
22639 + },
22640 + },
22641 + {
22642 + AVR32_OPC_MUL3, 4, 0xe0001000, 0xe1f0ff00,
22643 + &avr32_syntax_table[AVR32_SYNTAX_MUL3],
22644 + BFD_RELOC_AVR32_8S_EXT, 3, 2,
22645 + {
22646 + &avr32_ifield_table[AVR32_IFIELD_RY],
22647 + &avr32_ifield_table[AVR32_IFIELD_RX],
22648 + &avr32_ifield_table[AVR32_IFIELD_K8E],
22649 + },
22650 + },
22651 + {
22652 + AVR32_OPC_MULHH_W, 4, 0xe0000780, 0xe1f0ffc0,
22653 + &avr32_syntax_table[AVR32_SYNTAX_MULHH_W],
22654 + BFD_RELOC_UNUSED, 5, -1,
22655 + {
22656 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22657 + &avr32_ifield_table[AVR32_IFIELD_RX],
22658 + &avr32_ifield_table[AVR32_IFIELD_X],
22659 + &avr32_ifield_table[AVR32_IFIELD_RY],
22660 + &avr32_ifield_table[AVR32_IFIELD_Y],
22661 + },
22662 + },
22663 + {
22664 + AVR32_OPC_MULNHH_W, 4, 0xe0000180, 0xe1f0ffc0,
22665 + &avr32_syntax_table[AVR32_SYNTAX_MULNHH_W],
22666 + BFD_RELOC_UNUSED, 5, -1,
22667 + {
22668 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22669 + &avr32_ifield_table[AVR32_IFIELD_RX],
22670 + &avr32_ifield_table[AVR32_IFIELD_X],
22671 + &avr32_ifield_table[AVR32_IFIELD_RY],
22672 + &avr32_ifield_table[AVR32_IFIELD_Y],
22673 + },
22674 + },
22675 + {
22676 + AVR32_OPC_MULNWH_D, 4, 0xe0000280, 0xe1f0ffe1,
22677 + &avr32_syntax_table[AVR32_SYNTAX_MULNWH_D],
22678 + BFD_RELOC_UNUSED, 4, -1,
22679 + {
22680 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22681 + &avr32_ifield_table[AVR32_IFIELD_RX],
22682 + &avr32_ifield_table[AVR32_IFIELD_RY],
22683 + &avr32_ifield_table[AVR32_IFIELD_Y],
22684 + },
22685 + },
22686 + {
22687 + AVR32_OPC_MULSD, 4, 0xe0000440, 0xe1f0fff0,
22688 + &avr32_syntax_table[AVR32_SYNTAX_MULSD],
22689 + BFD_RELOC_UNUSED, 3, -1,
22690 + {
22691 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22692 + &avr32_ifield_table[AVR32_IFIELD_RX],
22693 + &avr32_ifield_table[AVR32_IFIELD_RY],
22694 + },
22695 + },
22696 + {
22697 + AVR32_OPC_MULSATHH_H, 4, 0xe0000880, 0xe1f0ffc0,
22698 + &avr32_syntax_table[AVR32_SYNTAX_MULSATHH_H],
22699 + BFD_RELOC_UNUSED, 5, -1,
22700 + {
22701 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22702 + &avr32_ifield_table[AVR32_IFIELD_RX],
22703 + &avr32_ifield_table[AVR32_IFIELD_X],
22704 + &avr32_ifield_table[AVR32_IFIELD_RY],
22705 + &avr32_ifield_table[AVR32_IFIELD_Y],
22706 + },
22707 + },
22708 + {
22709 + AVR32_OPC_MULSATHH_W, 4, 0xe0000980, 0xe1f0ffc0,
22710 + &avr32_syntax_table[AVR32_SYNTAX_MULSATHH_W],
22711 + BFD_RELOC_UNUSED, 5, -1,
22712 + {
22713 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22714 + &avr32_ifield_table[AVR32_IFIELD_RX],
22715 + &avr32_ifield_table[AVR32_IFIELD_X],
22716 + &avr32_ifield_table[AVR32_IFIELD_RY],
22717 + &avr32_ifield_table[AVR32_IFIELD_Y],
22718 + },
22719 + },
22720 + {
22721 + AVR32_OPC_MULSATRNDHH_H, 4, 0xe0000a80, 0xe1f0ffc0,
22722 + &avr32_syntax_table[AVR32_SYNTAX_MULSATRNDHH_H],
22723 + BFD_RELOC_UNUSED, 5, -1,
22724 + {
22725 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22726 + &avr32_ifield_table[AVR32_IFIELD_RX],
22727 + &avr32_ifield_table[AVR32_IFIELD_X],
22728 + &avr32_ifield_table[AVR32_IFIELD_RY],
22729 + &avr32_ifield_table[AVR32_IFIELD_Y],
22730 + },
22731 + },
22732 + {
22733 + AVR32_OPC_MULSATRNDWH_W, 4, 0xe0000b80, 0xe1f0ffe0,
22734 + &avr32_syntax_table[AVR32_SYNTAX_MULSATRNDWH_W],
22735 + BFD_RELOC_UNUSED, 4, -1,
22736 + {
22737 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22738 + &avr32_ifield_table[AVR32_IFIELD_RX],
22739 + &avr32_ifield_table[AVR32_IFIELD_RY],
22740 + &avr32_ifield_table[AVR32_IFIELD_Y],
22741 + },
22742 + },
22743 + {
22744 + AVR32_OPC_MULSATWH_W, 4, 0xe0000e80, 0xe1f0ffe0,
22745 + &avr32_syntax_table[AVR32_SYNTAX_MULSATWH_W],
22746 + BFD_RELOC_UNUSED, 4, -1,
22747 + {
22748 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22749 + &avr32_ifield_table[AVR32_IFIELD_RX],
22750 + &avr32_ifield_table[AVR32_IFIELD_RY],
22751 + &avr32_ifield_table[AVR32_IFIELD_Y],
22752 + },
22753 + },
22754 + {
22755 + AVR32_OPC_MULU_D, 4, 0xe0000640, 0xe1f0fff1,
22756 + &avr32_syntax_table[AVR32_SYNTAX_MULU_D],
22757 + BFD_RELOC_UNUSED, 3, -1,
22758 + {
22759 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22760 + &avr32_ifield_table[AVR32_IFIELD_RX],
22761 + &avr32_ifield_table[AVR32_IFIELD_RY],
22762 + },
22763 + },
22764 + {
22765 + AVR32_OPC_MULWH_D, 4, 0xe0000d80, 0xe1f0ffe1,
22766 + &avr32_syntax_table[AVR32_SYNTAX_MULWH_D],
22767 + BFD_RELOC_UNUSED, 4, -1,
22768 + {
22769 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22770 + &avr32_ifield_table[AVR32_IFIELD_RX],
22771 + &avr32_ifield_table[AVR32_IFIELD_RY],
22772 + &avr32_ifield_table[AVR32_IFIELD_Y],
22773 + },
22774 + },
22775 + {
22776 + AVR32_OPC_MUSFR, 2, 0x5d300000, 0xfff00000,
22777 + &avr32_syntax_table[AVR32_SYNTAX_MUSFR],
22778 + BFD_RELOC_UNUSED, 1, -1,
22779 + {
22780 + &avr32_ifield_table[AVR32_IFIELD_RY],
22781 + }
22782 + },
22783 + {
22784 + AVR32_OPC_MUSTR, 2, 0x5d200000, 0xfff00000,
22785 + &avr32_syntax_table[AVR32_SYNTAX_MUSTR],
22786 + BFD_RELOC_UNUSED, 1, -1,
22787 + {
22788 + &avr32_ifield_table[AVR32_IFIELD_RY],
22789 + }
22790 + },
22791 + {
22792 + AVR32_OPC_MVCR_D, 4, 0xefa00010, 0xfff111ff,
22793 + &avr32_syntax_table[AVR32_SYNTAX_MVCR_D],
22794 + BFD_RELOC_UNUSED, 3, -1,
22795 + {
22796 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
22797 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
22798 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
22799 + },
22800 + },
22801 + {
22802 + AVR32_OPC_MVCR_W, 4, 0xefa00000, 0xfff010ff,
22803 + &avr32_syntax_table[AVR32_SYNTAX_MVCR_W],
22804 + BFD_RELOC_UNUSED, 3, -1,
22805 + {
22806 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
22807 + &avr32_ifield_table[AVR32_IFIELD_RY],
22808 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
22809 + },
22810 + },
22811 + {
22812 + AVR32_OPC_MVRC_D, 4, 0xefa00030, 0xfff111ff,
22813 + &avr32_syntax_table[AVR32_SYNTAX_MVRC_D],
22814 + BFD_RELOC_UNUSED, 3, -1,
22815 + {
22816 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
22817 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
22818 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
22819 + },
22820 + },
22821 + {
22822 + AVR32_OPC_MVRC_W, 4, 0xefa00020, 0xfff010ff,
22823 + &avr32_syntax_table[AVR32_SYNTAX_MVRC_W],
22824 + BFD_RELOC_UNUSED, 3, -1,
22825 + {
22826 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
22827 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
22828 + &avr32_ifield_table[AVR32_IFIELD_RY],
22829 + },
22830 + },
22831 + {
22832 + AVR32_OPC_NEG, 2, 0x5c300000, 0xfff00000,
22833 + &avr32_syntax_table[AVR32_SYNTAX_NEG],
22834 + BFD_RELOC_UNUSED, 1, -1,
22835 + {
22836 + &avr32_ifield_table[AVR32_IFIELD_RY],
22837 + }
22838 + },
22839 + {
22840 + AVR32_OPC_NOP, 2, 0xd7030000, 0xffff0000,
22841 + &avr32_syntax_table[AVR32_SYNTAX_NOP],
22842 + BFD_RELOC_UNUSED, 0, -1, { NULL },
22843 + },
22844 + {
22845 + AVR32_OPC_OR1, 2, 0x00400000, 0xe1f00000,
22846 + &avr32_syntax_table[AVR32_SYNTAX_OR1],
22847 + BFD_RELOC_UNUSED, 2, -1,
22848 + {
22849 + &avr32_ifield_table[AVR32_IFIELD_RY],
22850 + &avr32_ifield_table[AVR32_IFIELD_RX],
22851 + },
22852 + },
22853 + {
22854 + AVR32_OPC_OR2, 4, 0xe1e01000, 0xe1f0fe00,
22855 + &avr32_syntax_table[AVR32_SYNTAX_OR2],
22856 + BFD_RELOC_UNUSED, 4, -1,
22857 + {
22858 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22859 + &avr32_ifield_table[AVR32_IFIELD_RX],
22860 + &avr32_ifield_table[AVR32_IFIELD_RY],
22861 + &avr32_ifield_table[AVR32_IFIELD_K5E2],
22862 + },
22863 + },
22864 + {
22865 + AVR32_OPC_OR3, 4, 0xe1e01200, 0xe1f0fe00,
22866 + &avr32_syntax_table[AVR32_SYNTAX_OR3],
22867 + BFD_RELOC_UNUSED, 4, -1,
22868 + {
22869 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22870 + &avr32_ifield_table[AVR32_IFIELD_RX],
22871 + &avr32_ifield_table[AVR32_IFIELD_RY],
22872 + &avr32_ifield_table[AVR32_IFIELD_K5E2],
22873 + },
22874 + },
22875 + {
22876 + AVR32_OPC_ORH, 4, 0xea100000, 0xfff00000,
22877 + &avr32_syntax_table[AVR32_SYNTAX_ORH],
22878 + BFD_RELOC_AVR32_16U, 2, 1,
22879 + {
22880 + &avr32_ifield_table[AVR32_IFIELD_RY],
22881 + &avr32_ifield_table[AVR32_IFIELD_K16],
22882 + },
22883 + },
22884 + {
22885 + AVR32_OPC_ORL, 4, 0xe8100000, 0xfff00000,
22886 + &avr32_syntax_table[AVR32_SYNTAX_ORL],
22887 + BFD_RELOC_AVR32_16U, 2, 1,
22888 + {
22889 + &avr32_ifield_table[AVR32_IFIELD_RY],
22890 + &avr32_ifield_table[AVR32_IFIELD_K16],
22891 + },
22892 + },
22893 + {
22894 + AVR32_OPC_PABS_SB, 4, 0xe00023e0, 0xfff0fff0,
22895 + &avr32_syntax_table[AVR32_SYNTAX_PABS_SB],
22896 + BFD_RELOC_UNUSED, 2, -1,
22897 + {
22898 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22899 + &avr32_ifield_table[AVR32_IFIELD_RY],
22900 + },
22901 + },
22902 + {
22903 + AVR32_OPC_PABS_SH, 4, 0xe00023f0, 0xfff0fff0,
22904 + &avr32_syntax_table[AVR32_SYNTAX_PABS_SH],
22905 + BFD_RELOC_UNUSED, 2, -1,
22906 + {
22907 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22908 + &avr32_ifield_table[AVR32_IFIELD_RY],
22909 + },
22910 + },
22911 + {
22912 + AVR32_OPC_PACKSH_SB, 4, 0xe00024d0, 0xe1f0fff0,
22913 + &avr32_syntax_table[AVR32_SYNTAX_PACKSH_SB],
22914 + BFD_RELOC_UNUSED, 3, -1,
22915 + {
22916 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22917 + &avr32_ifield_table[AVR32_IFIELD_RX],
22918 + &avr32_ifield_table[AVR32_IFIELD_RY],
22919 + },
22920 + },
22921 + {
22922 + AVR32_OPC_PACKSH_UB, 4, 0xe00024c0, 0xe1f0fff0,
22923 + &avr32_syntax_table[AVR32_SYNTAX_PACKSH_UB],
22924 + BFD_RELOC_UNUSED, 3, -1,
22925 + {
22926 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22927 + &avr32_ifield_table[AVR32_IFIELD_RX],
22928 + &avr32_ifield_table[AVR32_IFIELD_RY],
22929 + },
22930 + },
22931 + {
22932 + AVR32_OPC_PACKW_SH, 4, 0xe0002470, 0xe1f0fff0,
22933 + &avr32_syntax_table[AVR32_SYNTAX_PACKW_SH],
22934 + BFD_RELOC_UNUSED, 3, -1,
22935 + {
22936 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22937 + &avr32_ifield_table[AVR32_IFIELD_RX],
22938 + &avr32_ifield_table[AVR32_IFIELD_RY],
22939 + },
22940 + },
22941 + {
22942 + AVR32_OPC_PADD_B, 4, 0xe0002300, 0xe1f0fff0,
22943 + &avr32_syntax_table[AVR32_SYNTAX_PADD_B],
22944 + BFD_RELOC_UNUSED, 3, -1,
22945 + {
22946 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22947 + &avr32_ifield_table[AVR32_IFIELD_RX],
22948 + &avr32_ifield_table[AVR32_IFIELD_RY],
22949 + },
22950 + },
22951 + {
22952 + AVR32_OPC_PADD_H, 4, 0xe0002000, 0xe1f0fff0,
22953 + &avr32_syntax_table[AVR32_SYNTAX_PADD_H],
22954 + BFD_RELOC_UNUSED, 3, -1,
22955 + {
22956 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22957 + &avr32_ifield_table[AVR32_IFIELD_RX],
22958 + &avr32_ifield_table[AVR32_IFIELD_RY],
22959 + },
22960 + },
22961 + {
22962 + AVR32_OPC_PADDH_SH, 4, 0xe00020c0, 0xe1f0fff0,
22963 + &avr32_syntax_table[AVR32_SYNTAX_PADDH_SH],
22964 + BFD_RELOC_UNUSED, 3, -1,
22965 + {
22966 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22967 + &avr32_ifield_table[AVR32_IFIELD_RX],
22968 + &avr32_ifield_table[AVR32_IFIELD_RY],
22969 + },
22970 + },
22971 + {
22972 + AVR32_OPC_PADDH_UB, 4, 0xe0002360, 0xe1f0fff0,
22973 + &avr32_syntax_table[AVR32_SYNTAX_PADDH_UB],
22974 + BFD_RELOC_UNUSED, 3, -1,
22975 + {
22976 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22977 + &avr32_ifield_table[AVR32_IFIELD_RX],
22978 + &avr32_ifield_table[AVR32_IFIELD_RY],
22979 + },
22980 + },
22981 + {
22982 + AVR32_OPC_PADDS_SB, 4, 0xe0002320, 0xe1f0fff0,
22983 + &avr32_syntax_table[AVR32_SYNTAX_PADDS_SB],
22984 + BFD_RELOC_UNUSED, 3, -1,
22985 + {
22986 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22987 + &avr32_ifield_table[AVR32_IFIELD_RX],
22988 + &avr32_ifield_table[AVR32_IFIELD_RY],
22989 + },
22990 + },
22991 + {
22992 + AVR32_OPC_PADDS_SH, 4, 0xe0002040, 0xe1f0fff0,
22993 + &avr32_syntax_table[AVR32_SYNTAX_PADDS_SH],
22994 + BFD_RELOC_UNUSED, 3, -1,
22995 + {
22996 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
22997 + &avr32_ifield_table[AVR32_IFIELD_RX],
22998 + &avr32_ifield_table[AVR32_IFIELD_RY],
22999 + },
23000 + },
23001 + {
23002 + AVR32_OPC_PADDS_UB, 4, 0xe0002340, 0xe1f0fff0,
23003 + &avr32_syntax_table[AVR32_SYNTAX_PADDS_UB],
23004 + BFD_RELOC_UNUSED, 3, -1,
23005 + {
23006 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23007 + &avr32_ifield_table[AVR32_IFIELD_RX],
23008 + &avr32_ifield_table[AVR32_IFIELD_RY],
23009 + },
23010 + },
23011 + {
23012 + AVR32_OPC_PADDS_UH, 4, 0xe0002080, 0xe1f0fff0,
23013 + &avr32_syntax_table[AVR32_SYNTAX_PADDS_UH],
23014 + BFD_RELOC_UNUSED, 3, -1,
23015 + {
23016 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23017 + &avr32_ifield_table[AVR32_IFIELD_RX],
23018 + &avr32_ifield_table[AVR32_IFIELD_RY],
23019 + },
23020 + },
23021 + {
23022 + AVR32_OPC_PADDSUB_H, 4, 0xe0002100, 0xe1f0ffc0,
23023 + &avr32_syntax_table[AVR32_SYNTAX_PADDSUB_H],
23024 + BFD_RELOC_UNUSED, 5, -1,
23025 + {
23026 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23027 + &avr32_ifield_table[AVR32_IFIELD_RX],
23028 + &avr32_ifield_table[AVR32_IFIELD_X],
23029 + &avr32_ifield_table[AVR32_IFIELD_RY],
23030 + &avr32_ifield_table[AVR32_IFIELD_Y],
23031 + },
23032 + },
23033 + {
23034 + AVR32_OPC_PADDSUBH_SH, 4, 0xe0002280, 0xe1f0ffc0,
23035 + &avr32_syntax_table[AVR32_SYNTAX_PADDSUBH_SH],
23036 + BFD_RELOC_UNUSED, 5, -1,
23037 + {
23038 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23039 + &avr32_ifield_table[AVR32_IFIELD_RX],
23040 + &avr32_ifield_table[AVR32_IFIELD_X],
23041 + &avr32_ifield_table[AVR32_IFIELD_RY],
23042 + &avr32_ifield_table[AVR32_IFIELD_Y],
23043 + },
23044 + },
23045 + {
23046 + AVR32_OPC_PADDSUBS_SH, 4, 0xe0002180, 0xe1f0ffc0,
23047 + &avr32_syntax_table[AVR32_SYNTAX_PADDSUBS_SH],
23048 + BFD_RELOC_UNUSED, 5, -1,
23049 + {
23050 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23051 + &avr32_ifield_table[AVR32_IFIELD_RX],
23052 + &avr32_ifield_table[AVR32_IFIELD_X],
23053 + &avr32_ifield_table[AVR32_IFIELD_RY],
23054 + &avr32_ifield_table[AVR32_IFIELD_Y],
23055 + },
23056 + },
23057 + {
23058 + AVR32_OPC_PADDSUBS_UH, 4, 0xe0002200, 0xe1f0ffc0,
23059 + &avr32_syntax_table[AVR32_SYNTAX_PADDSUBS_UH],
23060 + BFD_RELOC_UNUSED, 5, -1,
23061 + {
23062 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23063 + &avr32_ifield_table[AVR32_IFIELD_RX],
23064 + &avr32_ifield_table[AVR32_IFIELD_X],
23065 + &avr32_ifield_table[AVR32_IFIELD_RY],
23066 + &avr32_ifield_table[AVR32_IFIELD_Y],
23067 + },
23068 + },
23069 + {
23070 + AVR32_OPC_PADDX_H, 4, 0xe0002020, 0xe1f0fff0,
23071 + &avr32_syntax_table[AVR32_SYNTAX_PADDX_H],
23072 + BFD_RELOC_UNUSED, 3, -1,
23073 + {
23074 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23075 + &avr32_ifield_table[AVR32_IFIELD_RX],
23076 + &avr32_ifield_table[AVR32_IFIELD_RY],
23077 + },
23078 + },
23079 + {
23080 + AVR32_OPC_PADDXH_SH, 4, 0xe00020e0, 0xe1f0fff0,
23081 + &avr32_syntax_table[AVR32_SYNTAX_PADDXH_SH],
23082 + BFD_RELOC_UNUSED, 3, -1,
23083 + {
23084 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23085 + &avr32_ifield_table[AVR32_IFIELD_RX],
23086 + &avr32_ifield_table[AVR32_IFIELD_RY],
23087 + },
23088 + },
23089 + {
23090 + AVR32_OPC_PADDXS_SH, 4, 0xe0002060, 0xe1f0fff0,
23091 + &avr32_syntax_table[AVR32_SYNTAX_PADDXS_SH],
23092 + BFD_RELOC_UNUSED, 3, -1,
23093 + {
23094 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23095 + &avr32_ifield_table[AVR32_IFIELD_RX],
23096 + &avr32_ifield_table[AVR32_IFIELD_RY],
23097 + },
23098 + },
23099 + {
23100 + AVR32_OPC_PADDXS_UH, 4, 0xe00020a0, 0xe1f0fff0,
23101 + &avr32_syntax_table[AVR32_SYNTAX_PADDXS_UH],
23102 + BFD_RELOC_UNUSED, 3, -1,
23103 + {
23104 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23105 + &avr32_ifield_table[AVR32_IFIELD_RX],
23106 + &avr32_ifield_table[AVR32_IFIELD_RY],
23107 + },
23108 + },
23109 + {
23110 + AVR32_OPC_PASR_B, 4, 0xe0002410, 0xe1f8fff0,
23111 + &avr32_syntax_table[AVR32_SYNTAX_PASR_B],
23112 + BFD_RELOC_UNUSED, 3, -1,
23113 + {
23114 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23115 + &avr32_ifield_table[AVR32_IFIELD_RX],
23116 + &avr32_ifield_table[AVR32_IFIELD_COND3],
23117 + },
23118 + },
23119 + {
23120 + AVR32_OPC_PASR_H, 4, 0xe0002440, 0xe1f0fff0,
23121 + &avr32_syntax_table[AVR32_SYNTAX_PASR_H],
23122 + BFD_RELOC_UNUSED, 3, -1,
23123 + {
23124 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23125 + &avr32_ifield_table[AVR32_IFIELD_RX],
23126 + &avr32_ifield_table[AVR32_IFIELD_RY],
23127 + },
23128 + },
23129 + {
23130 + AVR32_OPC_PAVG_SH, 4, 0xe00023d0, 0xe1f0fff0,
23131 + &avr32_syntax_table[AVR32_SYNTAX_PAVG_SH],
23132 + BFD_RELOC_UNUSED, 3, -1,
23133 + {
23134 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23135 + &avr32_ifield_table[AVR32_IFIELD_RX],
23136 + &avr32_ifield_table[AVR32_IFIELD_RY],
23137 + },
23138 + },
23139 + {
23140 + AVR32_OPC_PAVG_UB, 4, 0xe00023c0, 0xe1f0fff0,
23141 + &avr32_syntax_table[AVR32_SYNTAX_PAVG_UB],
23142 + BFD_RELOC_UNUSED, 3, -1,
23143 + {
23144 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23145 + &avr32_ifield_table[AVR32_IFIELD_RX],
23146 + &avr32_ifield_table[AVR32_IFIELD_RY],
23147 + },
23148 + },
23149 + {
23150 + AVR32_OPC_PLSL_B, 4, 0xe0002420, 0xe1f8fff0,
23151 + &avr32_syntax_table[AVR32_SYNTAX_PLSL_B],
23152 + BFD_RELOC_UNUSED, 3, -1,
23153 + {
23154 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23155 + &avr32_ifield_table[AVR32_IFIELD_RX],
23156 + &avr32_ifield_table[AVR32_IFIELD_COND3],
23157 + },
23158 + },
23159 + {
23160 + AVR32_OPC_PLSL_H, 4, 0xe0002450, 0xe1f0fff0,
23161 + &avr32_syntax_table[AVR32_SYNTAX_PLSL_H],
23162 + BFD_RELOC_UNUSED, 3, -1,
23163 + {
23164 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23165 + &avr32_ifield_table[AVR32_IFIELD_RX],
23166 + &avr32_ifield_table[AVR32_IFIELD_RY],
23167 + },
23168 + },
23169 + {
23170 + AVR32_OPC_PLSR_B, 4, 0xe0002430, 0xe1f8fff0,
23171 + &avr32_syntax_table[AVR32_SYNTAX_PLSR_B],
23172 + BFD_RELOC_UNUSED, 3, -1,
23173 + {
23174 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23175 + &avr32_ifield_table[AVR32_IFIELD_RX],
23176 + &avr32_ifield_table[AVR32_IFIELD_COND3],
23177 + },
23178 + },
23179 + {
23180 + AVR32_OPC_PLSR_H, 4, 0xe0002460, 0xe1f0fff0,
23181 + &avr32_syntax_table[AVR32_SYNTAX_PLSR_H],
23182 + BFD_RELOC_UNUSED, 3, -1,
23183 + {
23184 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23185 + &avr32_ifield_table[AVR32_IFIELD_RX],
23186 + &avr32_ifield_table[AVR32_IFIELD_RY],
23187 + },
23188 + },
23189 + {
23190 + AVR32_OPC_PMAX_SH, 4, 0xe0002390, 0xe1f0fff0,
23191 + &avr32_syntax_table[AVR32_SYNTAX_PMAX_SH],
23192 + BFD_RELOC_UNUSED, 3, -1,
23193 + {
23194 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23195 + &avr32_ifield_table[AVR32_IFIELD_RX],
23196 + &avr32_ifield_table[AVR32_IFIELD_RY],
23197 + },
23198 + },
23199 + {
23200 + AVR32_OPC_PMAX_UB, 4, 0xe0002380, 0xe1f0fff0,
23201 + &avr32_syntax_table[AVR32_SYNTAX_PMAX_UB],
23202 + BFD_RELOC_UNUSED, 3, -1,
23203 + {
23204 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23205 + &avr32_ifield_table[AVR32_IFIELD_RX],
23206 + &avr32_ifield_table[AVR32_IFIELD_RY],
23207 + },
23208 + },
23209 + {
23210 + AVR32_OPC_PMIN_SH, 4, 0xe00023b0, 0xe1f0fff0,
23211 + &avr32_syntax_table[AVR32_SYNTAX_PMIN_SH],
23212 + BFD_RELOC_UNUSED, 3, -1,
23213 + {
23214 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23215 + &avr32_ifield_table[AVR32_IFIELD_RX],
23216 + &avr32_ifield_table[AVR32_IFIELD_RY],
23217 + },
23218 + },
23219 + {
23220 + AVR32_OPC_PMIN_UB, 4, 0xe00023a0, 0xe1f0fff0,
23221 + &avr32_syntax_table[AVR32_SYNTAX_PMIN_UB],
23222 + BFD_RELOC_UNUSED, 3, -1,
23223 + {
23224 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23225 + &avr32_ifield_table[AVR32_IFIELD_RX],
23226 + &avr32_ifield_table[AVR32_IFIELD_RY],
23227 + },
23228 + },
23229 + {
23230 + AVR32_OPC_POPJC, 2, 0xd7130000, 0xffff0000,
23231 + &avr32_syntax_table[AVR32_SYNTAX_POPJC],
23232 + BFD_RELOC_UNUSED, 0, -1, { NULL },
23233 + },
23234 + {
23235 + AVR32_OPC_POPM, 2, 0xd0020000, 0xf0070000,
23236 + &avr32_syntax_table[AVR32_SYNTAX_POPM],
23237 + BFD_RELOC_UNUSED, 1, -1,
23238 + {
23239 + &avr32_ifield_table[AVR32_IFIELD_POPM],
23240 + },
23241 + },
23242 + {
23243 + AVR32_OPC_POPM_E, 4, 0xe3cd0000, 0xffff0000,
23244 + &avr32_syntax_table[AVR32_SYNTAX_POPM_E],
23245 + BFD_RELOC_UNUSED, 1, -1,
23246 + {
23247 + &avr32_ifield_table[AVR32_IFIELD_K16],
23248 + },
23249 + },
23250 + {
23251 + AVR32_OPC_PREF, 4, 0xf2100000, 0xfff00000,
23252 + &avr32_syntax_table[AVR32_SYNTAX_PREF],
23253 + BFD_RELOC_AVR32_16S, 2, -1,
23254 + {
23255 + &avr32_ifield_table[AVR32_IFIELD_RY],
23256 + &avr32_ifield_table[AVR32_IFIELD_K16],
23257 + },
23258 + },
23259 + {
23260 + AVR32_OPC_PSAD, 4, 0xe0002400, 0xe1f0fff0,
23261 + &avr32_syntax_table[AVR32_SYNTAX_PSAD],
23262 + BFD_RELOC_UNUSED, 3, -1,
23263 + {
23264 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23265 + &avr32_ifield_table[AVR32_IFIELD_RX],
23266 + &avr32_ifield_table[AVR32_IFIELD_RY],
23267 + },
23268 + },
23269 + {
23270 + AVR32_OPC_PSUB_B, 4, 0xe0002310, 0xe1f0fff0,
23271 + &avr32_syntax_table[AVR32_SYNTAX_PSUB_B],
23272 + BFD_RELOC_UNUSED, 3, -1,
23273 + {
23274 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23275 + &avr32_ifield_table[AVR32_IFIELD_RX],
23276 + &avr32_ifield_table[AVR32_IFIELD_RY],
23277 + },
23278 + },
23279 + {
23280 + AVR32_OPC_PSUB_H, 4, 0xe0002010, 0xe1f0fff0,
23281 + &avr32_syntax_table[AVR32_SYNTAX_PSUB_H],
23282 + BFD_RELOC_UNUSED, 3, -1,
23283 + {
23284 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23285 + &avr32_ifield_table[AVR32_IFIELD_RX],
23286 + &avr32_ifield_table[AVR32_IFIELD_RY],
23287 + },
23288 + },
23289 + {
23290 + AVR32_OPC_PSUBADD_H, 4, 0xe0002140, 0xe1f0ffc0,
23291 + &avr32_syntax_table[AVR32_SYNTAX_PSUBADD_H],
23292 + BFD_RELOC_UNUSED, 5, -1,
23293 + {
23294 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23295 + &avr32_ifield_table[AVR32_IFIELD_RX],
23296 + &avr32_ifield_table[AVR32_IFIELD_X],
23297 + &avr32_ifield_table[AVR32_IFIELD_RY],
23298 + &avr32_ifield_table[AVR32_IFIELD_Y],
23299 + },
23300 + },
23301 + {
23302 + AVR32_OPC_PSUBADDH_SH, 4, 0xe00022c0, 0xe1f0ffc0,
23303 + &avr32_syntax_table[AVR32_SYNTAX_PSUBADDH_SH],
23304 + BFD_RELOC_UNUSED, 5, -1,
23305 + {
23306 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23307 + &avr32_ifield_table[AVR32_IFIELD_RX],
23308 + &avr32_ifield_table[AVR32_IFIELD_X],
23309 + &avr32_ifield_table[AVR32_IFIELD_RY],
23310 + &avr32_ifield_table[AVR32_IFIELD_Y],
23311 + },
23312 + },
23313 + {
23314 + AVR32_OPC_PSUBADDS_SH, 4, 0xe00021c0, 0xe1f0ffc0,
23315 + &avr32_syntax_table[AVR32_SYNTAX_PSUBADDS_SH],
23316 + BFD_RELOC_UNUSED, 5, -1,
23317 + {
23318 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23319 + &avr32_ifield_table[AVR32_IFIELD_RX],
23320 + &avr32_ifield_table[AVR32_IFIELD_X],
23321 + &avr32_ifield_table[AVR32_IFIELD_RY],
23322 + &avr32_ifield_table[AVR32_IFIELD_Y],
23323 + },
23324 + },
23325 + {
23326 + AVR32_OPC_PSUBADDS_UH, 4, 0xe0002240, 0xe1f0ffc0,
23327 + &avr32_syntax_table[AVR32_SYNTAX_PSUBADDS_UH],
23328 + BFD_RELOC_UNUSED, 5, -1,
23329 + {
23330 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23331 + &avr32_ifield_table[AVR32_IFIELD_RX],
23332 + &avr32_ifield_table[AVR32_IFIELD_X],
23333 + &avr32_ifield_table[AVR32_IFIELD_RY],
23334 + &avr32_ifield_table[AVR32_IFIELD_Y],
23335 + },
23336 + },
23337 + {
23338 + AVR32_OPC_PSUBH_SH, 4, 0xe00020d0, 0xe1f0fff0,
23339 + &avr32_syntax_table[AVR32_SYNTAX_PSUBH_SH],
23340 + BFD_RELOC_UNUSED, 3, -1,
23341 + {
23342 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23343 + &avr32_ifield_table[AVR32_IFIELD_RX],
23344 + &avr32_ifield_table[AVR32_IFIELD_RY],
23345 + },
23346 + },
23347 + {
23348 + AVR32_OPC_PSUBH_UB, 4, 0xe0002370, 0xe1f0fff0,
23349 + &avr32_syntax_table[AVR32_SYNTAX_PSUBH_UB],
23350 + BFD_RELOC_UNUSED, 3, -1,
23351 + {
23352 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23353 + &avr32_ifield_table[AVR32_IFIELD_RX],
23354 + &avr32_ifield_table[AVR32_IFIELD_RY],
23355 + },
23356 + },
23357 + {
23358 + AVR32_OPC_PSUBS_SB, 4, 0xe0002330, 0xe1f0fff0,
23359 + &avr32_syntax_table[AVR32_SYNTAX_PSUBS_SB],
23360 + BFD_RELOC_UNUSED, 3, -1,
23361 + {
23362 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23363 + &avr32_ifield_table[AVR32_IFIELD_RX],
23364 + &avr32_ifield_table[AVR32_IFIELD_RY],
23365 + },
23366 + },
23367 + {
23368 + AVR32_OPC_PSUBS_SH, 4, 0xe0002050, 0xe1f0fff0,
23369 + &avr32_syntax_table[AVR32_SYNTAX_PSUBS_SH],
23370 + BFD_RELOC_UNUSED, 3, -1,
23371 + {
23372 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23373 + &avr32_ifield_table[AVR32_IFIELD_RX],
23374 + &avr32_ifield_table[AVR32_IFIELD_RY],
23375 + },
23376 + },
23377 + {
23378 + AVR32_OPC_PSUBS_UB, 4, 0xe0002350, 0xe1f0fff0,
23379 + &avr32_syntax_table[AVR32_SYNTAX_PSUBS_UB],
23380 + BFD_RELOC_UNUSED, 3, -1,
23381 + {
23382 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23383 + &avr32_ifield_table[AVR32_IFIELD_RX],
23384 + &avr32_ifield_table[AVR32_IFIELD_RY],
23385 + },
23386 + },
23387 + {
23388 + AVR32_OPC_PSUBS_UH, 4, 0xe0002090, 0xe1f0fff0,
23389 + &avr32_syntax_table[AVR32_SYNTAX_PSUBS_UH],
23390 + BFD_RELOC_UNUSED, 3, -1,
23391 + {
23392 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23393 + &avr32_ifield_table[AVR32_IFIELD_RX],
23394 + &avr32_ifield_table[AVR32_IFIELD_RY],
23395 + },
23396 + },
23397 + {
23398 + AVR32_OPC_PSUBX_H, 4, 0xe0002030, 0xe1f0fff0,
23399 + &avr32_syntax_table[AVR32_SYNTAX_PSUBX_H],
23400 + BFD_RELOC_UNUSED, 3, -1,
23401 + {
23402 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23403 + &avr32_ifield_table[AVR32_IFIELD_RX],
23404 + &avr32_ifield_table[AVR32_IFIELD_RY],
23405 + },
23406 + },
23407 + {
23408 + AVR32_OPC_PSUBXH_SH, 4, 0xe00020f0, 0xe1f0fff0,
23409 + &avr32_syntax_table[AVR32_SYNTAX_PSUBXH_SH],
23410 + BFD_RELOC_UNUSED, 3, -1,
23411 + {
23412 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23413 + &avr32_ifield_table[AVR32_IFIELD_RX],
23414 + &avr32_ifield_table[AVR32_IFIELD_RY],
23415 + },
23416 + },
23417 + {
23418 + AVR32_OPC_PSUBXS_SH, 4, 0xe0002070, 0xe1f0fff0,
23419 + &avr32_syntax_table[AVR32_SYNTAX_PSUBXS_SH],
23420 + BFD_RELOC_UNUSED, 3, -1,
23421 + {
23422 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23423 + &avr32_ifield_table[AVR32_IFIELD_RX],
23424 + &avr32_ifield_table[AVR32_IFIELD_RY],
23425 + },
23426 + },
23427 + {
23428 + AVR32_OPC_PSUBXS_UH, 4, 0xe00020b0, 0xe1f0fff0,
23429 + &avr32_syntax_table[AVR32_SYNTAX_PSUBXS_UH],
23430 + BFD_RELOC_UNUSED, 3, -1,
23431 + {
23432 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23433 + &avr32_ifield_table[AVR32_IFIELD_RX],
23434 + &avr32_ifield_table[AVR32_IFIELD_RY],
23435 + },
23436 + },
23437 + {
23438 + AVR32_OPC_PUNPCKSB_H, 4, 0xe00024a0, 0xe1ffffe0,
23439 + &avr32_syntax_table[AVR32_SYNTAX_PUNPCKSB_H],
23440 + BFD_RELOC_UNUSED, 3, -1,
23441 + {
23442 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23443 + &avr32_ifield_table[AVR32_IFIELD_RX],
23444 + &avr32_ifield_table[AVR32_IFIELD_Y],
23445 + },
23446 + },
23447 + {
23448 + AVR32_OPC_PUNPCKUB_H, 4, 0xe0002480, 0xe1ffffe0,
23449 + &avr32_syntax_table[AVR32_SYNTAX_PUNPCKUB_H],
23450 + BFD_RELOC_UNUSED, 3, -1,
23451 + {
23452 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23453 + &avr32_ifield_table[AVR32_IFIELD_RX],
23454 + &avr32_ifield_table[AVR32_IFIELD_Y],
23455 + },
23456 + },
23457 + {
23458 + AVR32_OPC_PUSHJC, 2, 0xd7230000, 0xffff0000,
23459 + &avr32_syntax_table[AVR32_SYNTAX_PUSHJC],
23460 + BFD_RELOC_UNUSED, 0, -1, { NULL },
23461 + },
23462 + {
23463 + AVR32_OPC_PUSHM, 2, 0xd0010000, 0xf00f0000,
23464 + &avr32_syntax_table[AVR32_SYNTAX_PUSHM],
23465 + BFD_RELOC_UNUSED, 1, -1,
23466 + {
23467 + &avr32_ifield_table[AVR32_IFIELD_K8C],
23468 + },
23469 + },
23470 + {
23471 + AVR32_OPC_PUSHM_E, 4, 0xebcd0000, 0xffff0000,
23472 + &avr32_syntax_table[AVR32_SYNTAX_PUSHM_E],
23473 + BFD_RELOC_UNUSED, 1, -1,
23474 + {
23475 + &avr32_ifield_table[AVR32_IFIELD_K16],
23476 + },
23477 + },
23478 + {
23479 + AVR32_OPC_RCALL1, 2, 0xc00c0000, 0xf00c0000,
23480 + &avr32_syntax_table[AVR32_SYNTAX_RCALL1],
23481 + BFD_RELOC_AVR32_11H_PCREL, 1, 0,
23482 + {
23483 + &avr32_ifield_table[AVR32_IFIELD_K10],
23484 + },
23485 + },
23486 + {
23487 + AVR32_OPC_RCALL2, 4, 0xe0a00000, 0xe1ef0000,
23488 + &avr32_syntax_table[AVR32_SYNTAX_RCALL2],
23489 + BFD_RELOC_AVR32_22H_PCREL, 1, 0,
23490 + {
23491 + &avr32_ifield_table[AVR32_IFIELD_K21],
23492 + },
23493 + },
23494 + {
23495 + AVR32_OPC_RETEQ, 2, 0x5e000000, 0xfff00000,
23496 + &avr32_syntax_table[AVR32_SYNTAX_RETEQ],
23497 + BFD_RELOC_NONE, 1, -1,
23498 + {
23499 + &avr32_ifield_table[AVR32_IFIELD_RY],
23500 + },
23501 + },
23502 + {
23503 + AVR32_OPC_RETNE, 2, 0x5e100000, 0xfff00000,
23504 + &avr32_syntax_table[AVR32_SYNTAX_RETNE],
23505 + BFD_RELOC_NONE, 1, -1,
23506 + {
23507 + &avr32_ifield_table[AVR32_IFIELD_RY],
23508 + },
23509 + },
23510 + {
23511 + AVR32_OPC_RETCC, 2, 0x5e200000, 0xfff00000,
23512 + &avr32_syntax_table[AVR32_SYNTAX_RETHS],
23513 + BFD_RELOC_NONE, 1, -1,
23514 + {
23515 + &avr32_ifield_table[AVR32_IFIELD_RY],
23516 + },
23517 + },
23518 + {
23519 + AVR32_OPC_RETCS, 2, 0x5e300000, 0xfff00000,
23520 + &avr32_syntax_table[AVR32_SYNTAX_RETLO],
23521 + BFD_RELOC_NONE, 1, -1,
23522 + {
23523 + &avr32_ifield_table[AVR32_IFIELD_RY],
23524 + },
23525 + },
23526 + {
23527 + AVR32_OPC_RETGE, 2, 0x5e400000, 0xfff00000,
23528 + &avr32_syntax_table[AVR32_SYNTAX_RETGE],
23529 + BFD_RELOC_NONE, 1, -1,
23530 + {
23531 + &avr32_ifield_table[AVR32_IFIELD_RY],
23532 + },
23533 + },
23534 + {
23535 + AVR32_OPC_RETLT, 2, 0x5e500000, 0xfff00000,
23536 + &avr32_syntax_table[AVR32_SYNTAX_RETLT],
23537 + BFD_RELOC_NONE, 1, -1,
23538 + {
23539 + &avr32_ifield_table[AVR32_IFIELD_RY],
23540 + },
23541 + },
23542 + {
23543 + AVR32_OPC_RETMI, 2, 0x5e600000, 0xfff00000,
23544 + &avr32_syntax_table[AVR32_SYNTAX_RETMI],
23545 + BFD_RELOC_NONE, 1, -1,
23546 + {
23547 + &avr32_ifield_table[AVR32_IFIELD_RY],
23548 + },
23549 + },
23550 + {
23551 + AVR32_OPC_RETPL, 2, 0x5e700000, 0xfff00000,
23552 + &avr32_syntax_table[AVR32_SYNTAX_RETPL],
23553 + BFD_RELOC_NONE, 1, -1,
23554 + {
23555 + &avr32_ifield_table[AVR32_IFIELD_RY],
23556 + },
23557 + },
23558 + {
23559 + AVR32_OPC_RETLS, 2, 0x5e800000, 0xfff00000,
23560 + &avr32_syntax_table[AVR32_SYNTAX_RETLS],
23561 + BFD_RELOC_NONE, 1, -1,
23562 + {
23563 + &avr32_ifield_table[AVR32_IFIELD_RY],
23564 + },
23565 + },
23566 + {
23567 + AVR32_OPC_RETGT, 2, 0x5e900000, 0xfff00000,
23568 + &avr32_syntax_table[AVR32_SYNTAX_RETGT],
23569 + BFD_RELOC_NONE, 1, -1,
23570 + {
23571 + &avr32_ifield_table[AVR32_IFIELD_RY],
23572 + },
23573 + },
23574 + {
23575 + AVR32_OPC_RETLE, 2, 0x5ea00000, 0xfff00000,
23576 + &avr32_syntax_table[AVR32_SYNTAX_RETLE],
23577 + BFD_RELOC_NONE, 1, -1,
23578 + {
23579 + &avr32_ifield_table[AVR32_IFIELD_RY],
23580 + },
23581 + },
23582 + {
23583 + AVR32_OPC_RETHI, 2, 0x5eb00000, 0xfff00000,
23584 + &avr32_syntax_table[AVR32_SYNTAX_RETHI],
23585 + BFD_RELOC_NONE, 1, -1,
23586 + {
23587 + &avr32_ifield_table[AVR32_IFIELD_RY],
23588 + },
23589 + },
23590 + {
23591 + AVR32_OPC_RETVS, 2, 0x5ec00000, 0xfff00000,
23592 + &avr32_syntax_table[AVR32_SYNTAX_RETVS],
23593 + BFD_RELOC_NONE, 1, -1,
23594 + {
23595 + &avr32_ifield_table[AVR32_IFIELD_RY],
23596 + },
23597 + },
23598 + {
23599 + AVR32_OPC_RETVC, 2, 0x5ed00000, 0xfff00000,
23600 + &avr32_syntax_table[AVR32_SYNTAX_RETVC],
23601 + BFD_RELOC_NONE, 1, -1,
23602 + {
23603 + &avr32_ifield_table[AVR32_IFIELD_RY],
23604 + },
23605 + },
23606 + {
23607 + AVR32_OPC_RETQS, 2, 0x5ee00000, 0xfff00000,
23608 + &avr32_syntax_table[AVR32_SYNTAX_RETQS],
23609 + BFD_RELOC_NONE, 1, -1,
23610 + {
23611 + &avr32_ifield_table[AVR32_IFIELD_RY],
23612 + },
23613 + },
23614 + {
23615 + AVR32_OPC_RETAL, 2, 0x5ef00000, 0xfff00000,
23616 + &avr32_syntax_table[AVR32_SYNTAX_RETAL],
23617 + BFD_RELOC_NONE, 1, -1,
23618 + {
23619 + &avr32_ifield_table[AVR32_IFIELD_RY],
23620 + },
23621 + },
23622 + {
23623 + AVR32_OPC_RETD, 2, 0xd6230000, 0xffff0000,
23624 + &avr32_syntax_table[AVR32_SYNTAX_RETD],
23625 + BFD_RELOC_NONE, 0, -1, { NULL },
23626 + },
23627 + {
23628 + AVR32_OPC_RETE, 2, 0xd6030000, 0xffff0000,
23629 + &avr32_syntax_table[AVR32_SYNTAX_RETE],
23630 + BFD_RELOC_NONE, 0, -1, { NULL },
23631 + },
23632 + {
23633 + AVR32_OPC_RETJ, 2, 0xd6330000, 0xffff0000,
23634 + &avr32_syntax_table[AVR32_SYNTAX_RETJ],
23635 + BFD_RELOC_NONE, 0, -1, { NULL },
23636 + },
23637 + {
23638 + AVR32_OPC_RETS, 2, 0xd6130000, 0xffff0000,
23639 + &avr32_syntax_table[AVR32_SYNTAX_RETS],
23640 + BFD_RELOC_NONE, 0, -1, { NULL },
23641 + },
23642 + {
23643 + AVR32_OPC_RJMP, 2, 0xc0080000, 0xf00c0000,
23644 + &avr32_syntax_table[AVR32_SYNTAX_RJMP],
23645 + BFD_RELOC_AVR32_11H_PCREL, 1, 0,
23646 + {
23647 + &avr32_ifield_table[AVR32_IFIELD_K10],
23648 + },
23649 + },
23650 + {
23651 + AVR32_OPC_ROL, 2, 0x5cf00000, 0xfff00000,
23652 + &avr32_syntax_table[AVR32_SYNTAX_ROL],
23653 + BFD_RELOC_UNUSED, 1, -1,
23654 + {
23655 + &avr32_ifield_table[AVR32_IFIELD_RY],
23656 + }
23657 + },
23658 + {
23659 + AVR32_OPC_ROR, 2, 0x5d000000, 0xfff00000,
23660 + &avr32_syntax_table[AVR32_SYNTAX_ROR],
23661 + BFD_RELOC_UNUSED, 1, -1,
23662 + {
23663 + &avr32_ifield_table[AVR32_IFIELD_RY],
23664 + }
23665 + },
23666 + {
23667 + AVR32_OPC_RSUB1, 2, 0x00200000, 0xe1f00000,
23668 + &avr32_syntax_table[AVR32_SYNTAX_RSUB1],
23669 + BFD_RELOC_UNUSED, 2, -1,
23670 + {
23671 + &avr32_ifield_table[AVR32_IFIELD_RY],
23672 + &avr32_ifield_table[AVR32_IFIELD_RX],
23673 + },
23674 + },
23675 + {
23676 + AVR32_OPC_RSUB2, 4, 0xe0001100, 0xe1f0ff00,
23677 + &avr32_syntax_table[AVR32_SYNTAX_RSUB2],
23678 + BFD_RELOC_AVR32_8S_EXT, 3, 2,
23679 + {
23680 + &avr32_ifield_table[AVR32_IFIELD_RY],
23681 + &avr32_ifield_table[AVR32_IFIELD_RX],
23682 + &avr32_ifield_table[AVR32_IFIELD_K8E],
23683 + },
23684 + },
23685 + {
23686 + AVR32_OPC_SATADD_H, 4, 0xe00002c0, 0xe1f0fff0,
23687 + &avr32_syntax_table[AVR32_SYNTAX_SATADD_H],
23688 + BFD_RELOC_UNUSED, 3, -1,
23689 + {
23690 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23691 + &avr32_ifield_table[AVR32_IFIELD_RX],
23692 + &avr32_ifield_table[AVR32_IFIELD_RY],
23693 + },
23694 + },
23695 + {
23696 + AVR32_OPC_SATADD_W, 4, 0xe00000c0, 0xe1f0fff0,
23697 + &avr32_syntax_table[AVR32_SYNTAX_SATADD_W],
23698 + BFD_RELOC_UNUSED, 3, -1,
23699 + {
23700 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23701 + &avr32_ifield_table[AVR32_IFIELD_RX],
23702 + &avr32_ifield_table[AVR32_IFIELD_RY],
23703 + },
23704 + },
23705 + {
23706 + AVR32_OPC_SATRNDS, 4, 0xf3b00000, 0xfff0fc00,
23707 + &avr32_syntax_table[AVR32_SYNTAX_SATRNDS],
23708 + BFD_RELOC_UNUSED, 3, -1,
23709 + {
23710 + &avr32_ifield_table[AVR32_IFIELD_RY],
23711 + &avr32_ifield_table[AVR32_IFIELD_K5E],
23712 + &avr32_ifield_table[AVR32_IFIELD_S5],
23713 + },
23714 + },
23715 + {
23716 + AVR32_OPC_SATRNDU, 4, 0xf3b00400, 0xfff0fc00,
23717 + &avr32_syntax_table[AVR32_SYNTAX_SATRNDU],
23718 + BFD_RELOC_UNUSED, 3, -1,
23719 + {
23720 + &avr32_ifield_table[AVR32_IFIELD_RY],
23721 + &avr32_ifield_table[AVR32_IFIELD_K5E],
23722 + &avr32_ifield_table[AVR32_IFIELD_S5],
23723 + },
23724 + },
23725 + {
23726 + AVR32_OPC_SATS, 4, 0xf1b00000, 0xfff0fc00,
23727 + &avr32_syntax_table[AVR32_SYNTAX_SATS],
23728 + BFD_RELOC_UNUSED, 3, -1,
23729 + {
23730 + &avr32_ifield_table[AVR32_IFIELD_RY],
23731 + &avr32_ifield_table[AVR32_IFIELD_K5E],
23732 + &avr32_ifield_table[AVR32_IFIELD_S5],
23733 + },
23734 + },
23735 + {
23736 + AVR32_OPC_SATSUB_H, 4, 0xe00003c0, 0xe1f0fff0,
23737 + &avr32_syntax_table[AVR32_SYNTAX_SATSUB_H],
23738 + BFD_RELOC_UNUSED, 3, -1,
23739 + {
23740 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23741 + &avr32_ifield_table[AVR32_IFIELD_RX],
23742 + &avr32_ifield_table[AVR32_IFIELD_RY],
23743 + },
23744 + },
23745 + {
23746 + AVR32_OPC_SATSUB_W1, 4, 0xe00001c0, 0xe1f0fff0,
23747 + &avr32_syntax_table[AVR32_SYNTAX_SATSUB_W1],
23748 + BFD_RELOC_UNUSED, 3, -1,
23749 + {
23750 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23751 + &avr32_ifield_table[AVR32_IFIELD_RX],
23752 + &avr32_ifield_table[AVR32_IFIELD_RY],
23753 + },
23754 + },
23755 + {
23756 + AVR32_OPC_SATSUB_W2, 4, 0xe0d00000, 0xe1f00000,
23757 + &avr32_syntax_table[AVR32_SYNTAX_SATSUB_W2],
23758 + BFD_RELOC_UNUSED, 3, -1,
23759 + {
23760 + &avr32_ifield_table[AVR32_IFIELD_RY],
23761 + &avr32_ifield_table[AVR32_IFIELD_RX],
23762 + &avr32_ifield_table[AVR32_IFIELD_K16],
23763 + },
23764 + },
23765 + {
23766 + AVR32_OPC_SATU, 4, 0xf1b00400, 0xfff0fc00,
23767 + &avr32_syntax_table[AVR32_SYNTAX_SATU],
23768 + BFD_RELOC_UNUSED, 3, -1,
23769 + {
23770 + &avr32_ifield_table[AVR32_IFIELD_RY],
23771 + &avr32_ifield_table[AVR32_IFIELD_K5E],
23772 + &avr32_ifield_table[AVR32_IFIELD_S5],
23773 + },
23774 + },
23775 + {
23776 + AVR32_OPC_SBC, 4, 0xe0000140, 0xe1f0fff0,
23777 + &avr32_syntax_table[AVR32_SYNTAX_SBC],
23778 + BFD_RELOC_UNUSED, 3, -1,
23779 + {
23780 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23781 + &avr32_ifield_table[AVR32_IFIELD_RX],
23782 + &avr32_ifield_table[AVR32_IFIELD_RY],
23783 + },
23784 + },
23785 + {
23786 + AVR32_OPC_SBR, 2, 0xa1a00000, 0xe1e00000,
23787 + &avr32_syntax_table[AVR32_SYNTAX_SBR],
23788 + BFD_RELOC_UNUSED, 2, -1,
23789 + {
23790 + &avr32_ifield_table[AVR32_IFIELD_RY],
23791 + &avr32_ifield_table[AVR32_IFIELD_BIT5C],
23792 + },
23793 + },
23794 + {
23795 + AVR32_OPC_SCALL, 2, 0xd7330000, 0xffff0000,
23796 + &avr32_syntax_table[AVR32_SYNTAX_SCALL],
23797 + BFD_RELOC_UNUSED, 0, -1, { NULL },
23798 + },
23799 + {
23800 + AVR32_OPC_SCR, 2, 0x5c100000, 0xfff00000,
23801 + &avr32_syntax_table[AVR32_SYNTAX_SCR],
23802 + BFD_RELOC_UNUSED, 1, -1,
23803 + {
23804 + &avr32_ifield_table[AVR32_IFIELD_RY],
23805 + },
23806 + },
23807 + {
23808 + AVR32_OPC_SLEEP, 4, 0xe9b00000, 0xffffff00,
23809 + &avr32_syntax_table[AVR32_SYNTAX_SLEEP],
23810 + BFD_RELOC_AVR32_8S_EXT, 1, 0,
23811 + {
23812 + &avr32_ifield_table[AVR32_IFIELD_K8E],
23813 + },
23814 + },
23815 + {
23816 + AVR32_OPC_SREQ, 2, 0x5f000000, 0xfff00000,
23817 + &avr32_syntax_table[AVR32_SYNTAX_SREQ],
23818 + BFD_RELOC_UNUSED, 1, -1,
23819 + {
23820 + &avr32_ifield_table[AVR32_IFIELD_RY],
23821 + },
23822 + },
23823 + {
23824 + AVR32_OPC_SRNE, 2, 0x5f100000, 0xfff00000,
23825 + &avr32_syntax_table[AVR32_SYNTAX_SRNE],
23826 + BFD_RELOC_UNUSED, 1, -1,
23827 + {
23828 + &avr32_ifield_table[AVR32_IFIELD_RY],
23829 + },
23830 + },
23831 + {
23832 + AVR32_OPC_SRCC, 2, 0x5f200000, 0xfff00000,
23833 + &avr32_syntax_table[AVR32_SYNTAX_SRHS],
23834 + BFD_RELOC_UNUSED, 1, -1,
23835 + {
23836 + &avr32_ifield_table[AVR32_IFIELD_RY],
23837 + },
23838 + },
23839 + {
23840 + AVR32_OPC_SRCS, 2, 0x5f300000, 0xfff00000,
23841 + &avr32_syntax_table[AVR32_SYNTAX_SRLO],
23842 + BFD_RELOC_UNUSED, 1, -1,
23843 + {
23844 + &avr32_ifield_table[AVR32_IFIELD_RY],
23845 + },
23846 + },
23847 + {
23848 + AVR32_OPC_SRGE, 2, 0x5f400000, 0xfff00000,
23849 + &avr32_syntax_table[AVR32_SYNTAX_SRGE],
23850 + BFD_RELOC_UNUSED, 1, -1,
23851 + {
23852 + &avr32_ifield_table[AVR32_IFIELD_RY],
23853 + },
23854 + },
23855 + {
23856 + AVR32_OPC_SRLT, 2, 0x5f500000, 0xfff00000,
23857 + &avr32_syntax_table[AVR32_SYNTAX_SRLT],
23858 + BFD_RELOC_UNUSED, 1, -1,
23859 + {
23860 + &avr32_ifield_table[AVR32_IFIELD_RY],
23861 + },
23862 + },
23863 + {
23864 + AVR32_OPC_SRMI, 2, 0x5f600000, 0xfff00000,
23865 + &avr32_syntax_table[AVR32_SYNTAX_SRMI],
23866 + BFD_RELOC_UNUSED, 1, -1,
23867 + {
23868 + &avr32_ifield_table[AVR32_IFIELD_RY],
23869 + },
23870 + },
23871 + {
23872 + AVR32_OPC_SRPL, 2, 0x5f700000, 0xfff00000,
23873 + &avr32_syntax_table[AVR32_SYNTAX_SRPL],
23874 + BFD_RELOC_UNUSED, 1, -1,
23875 + {
23876 + &avr32_ifield_table[AVR32_IFIELD_RY],
23877 + },
23878 + },
23879 + {
23880 + AVR32_OPC_SRLS, 2, 0x5f800000, 0xfff00000,
23881 + &avr32_syntax_table[AVR32_SYNTAX_SRLS],
23882 + BFD_RELOC_UNUSED, 1, -1,
23883 + {
23884 + &avr32_ifield_table[AVR32_IFIELD_RY],
23885 + },
23886 + },
23887 + {
23888 + AVR32_OPC_SRGT, 2, 0x5f900000, 0xfff00000,
23889 + &avr32_syntax_table[AVR32_SYNTAX_SRGT],
23890 + BFD_RELOC_UNUSED, 1, -1,
23891 + {
23892 + &avr32_ifield_table[AVR32_IFIELD_RY],
23893 + },
23894 + },
23895 + {
23896 + AVR32_OPC_SRLE, 2, 0x5fa00000, 0xfff00000,
23897 + &avr32_syntax_table[AVR32_SYNTAX_SRLE],
23898 + BFD_RELOC_UNUSED, 1, -1,
23899 + {
23900 + &avr32_ifield_table[AVR32_IFIELD_RY],
23901 + },
23902 + },
23903 + {
23904 + AVR32_OPC_SRHI, 2, 0x5fb00000, 0xfff00000,
23905 + &avr32_syntax_table[AVR32_SYNTAX_SRHI],
23906 + BFD_RELOC_UNUSED, 1, -1,
23907 + {
23908 + &avr32_ifield_table[AVR32_IFIELD_RY],
23909 + },
23910 + },
23911 + {
23912 + AVR32_OPC_SRVS, 2, 0x5fc00000, 0xfff00000,
23913 + &avr32_syntax_table[AVR32_SYNTAX_SRVS],
23914 + BFD_RELOC_UNUSED, 1, -1,
23915 + {
23916 + &avr32_ifield_table[AVR32_IFIELD_RY],
23917 + },
23918 + },
23919 + {
23920 + AVR32_OPC_SRVC, 2, 0x5fd00000, 0xfff00000,
23921 + &avr32_syntax_table[AVR32_SYNTAX_SRVC],
23922 + BFD_RELOC_UNUSED, 1, -1,
23923 + {
23924 + &avr32_ifield_table[AVR32_IFIELD_RY],
23925 + },
23926 + },
23927 + {
23928 + AVR32_OPC_SRQS, 2, 0x5fe00000, 0xfff00000,
23929 + &avr32_syntax_table[AVR32_SYNTAX_SRQS],
23930 + BFD_RELOC_UNUSED, 1, -1,
23931 + {
23932 + &avr32_ifield_table[AVR32_IFIELD_RY],
23933 + },
23934 + },
23935 + {
23936 + AVR32_OPC_SRAL, 2, 0x5ff00000, 0xfff00000,
23937 + &avr32_syntax_table[AVR32_SYNTAX_SRAL],
23938 + BFD_RELOC_UNUSED, 1, -1,
23939 + {
23940 + &avr32_ifield_table[AVR32_IFIELD_RY],
23941 + },
23942 + },
23943 + {
23944 + AVR32_OPC_SSRF, 2, 0xd2030000, 0xfe0f0000,
23945 + &avr32_syntax_table[AVR32_SYNTAX_SSRF],
23946 + BFD_RELOC_UNUSED, 1, -1,
23947 + {
23948 + &avr32_ifield_table[AVR32_IFIELD_K5C],
23949 + },
23950 + },
23951 + {
23952 + AVR32_OPC_ST_B1, 2, 0x00c00000, 0xe1f00000,
23953 + &avr32_syntax_table[AVR32_SYNTAX_ST_B1],
23954 + BFD_RELOC_UNUSED, 2, -1,
23955 + {
23956 + &avr32_ifield_table[AVR32_IFIELD_RX],
23957 + &avr32_ifield_table[AVR32_IFIELD_RY],
23958 + },
23959 + },
23960 + {
23961 + AVR32_OPC_ST_B2, 2, 0x00f00000, 0xe1f00000,
23962 + &avr32_syntax_table[AVR32_SYNTAX_ST_B2],
23963 + BFD_RELOC_UNUSED, 2, -1,
23964 + {
23965 + &avr32_ifield_table[AVR32_IFIELD_RX],
23966 + &avr32_ifield_table[AVR32_IFIELD_RY],
23967 + },
23968 + },
23969 + {
23970 + AVR32_OPC_ST_B5, 4, 0xe0000b00, 0xe1f0ffc0,
23971 + &avr32_syntax_table[AVR32_SYNTAX_ST_B5],
23972 + BFD_RELOC_UNUSED, 4, -1,
23973 + {
23974 + &avr32_ifield_table[AVR32_IFIELD_RX],
23975 + &avr32_ifield_table[AVR32_IFIELD_RY],
23976 + &avr32_ifield_table[AVR32_IFIELD_K2],
23977 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
23978 + },
23979 + },
23980 + {
23981 + AVR32_OPC_ST_B3, 2, 0xa0800000, 0xe1800000,
23982 + &avr32_syntax_table[AVR32_SYNTAX_ST_B3],
23983 + BFD_RELOC_AVR32_3U, 3, 1,
23984 + {
23985 + &avr32_ifield_table[AVR32_IFIELD_RX],
23986 + &avr32_ifield_table[AVR32_IFIELD_K3],
23987 + &avr32_ifield_table[AVR32_IFIELD_RY],
23988 + },
23989 + },
23990 + {
23991 + AVR32_OPC_ST_B4, 4, 0xe1600000, 0xe1f00000,
23992 + &avr32_syntax_table[AVR32_SYNTAX_ST_B4],
23993 + BFD_RELOC_AVR32_16S, 3, 1,
23994 + {
23995 + &avr32_ifield_table[AVR32_IFIELD_RX],
23996 + &avr32_ifield_table[AVR32_IFIELD_K16],
23997 + &avr32_ifield_table[AVR32_IFIELD_RY],
23998 + },
23999 + },
24000 + {
24001 + AVR32_OPC_ST_D1, 2, 0xa1200000, 0xe1f10000,
24002 + &avr32_syntax_table[AVR32_SYNTAX_ST_D1],
24003 + BFD_RELOC_UNUSED, 2, -1,
24004 + {
24005 + &avr32_ifield_table[AVR32_IFIELD_RX],
24006 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
24007 + },
24008 + },
24009 + {
24010 + AVR32_OPC_ST_D2, 2, 0xa1210000, 0xe1f10000,
24011 + &avr32_syntax_table[AVR32_SYNTAX_ST_D2],
24012 + BFD_RELOC_UNUSED, 2, -1,
24013 + {
24014 + &avr32_ifield_table[AVR32_IFIELD_RX],
24015 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
24016 + },
24017 + },
24018 + {
24019 + AVR32_OPC_ST_D3, 2, 0xa1110000, 0xe1f10000,
24020 + &avr32_syntax_table[AVR32_SYNTAX_ST_D3],
24021 + BFD_RELOC_UNUSED, 2, -1,
24022 + {
24023 + &avr32_ifield_table[AVR32_IFIELD_RX],
24024 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
24025 + },
24026 + },
24027 + {
24028 + AVR32_OPC_ST_D5, 4, 0xe0000800, 0xe1f0ffc1,
24029 + &avr32_syntax_table[AVR32_SYNTAX_ST_D5],
24030 + BFD_RELOC_UNUSED, 4, -1,
24031 + {
24032 + &avr32_ifield_table[AVR32_IFIELD_RX],
24033 + &avr32_ifield_table[AVR32_IFIELD_RY],
24034 + &avr32_ifield_table[AVR32_IFIELD_K2],
24035 + &avr32_ifield_table[AVR32_IFIELD_RD_DW],
24036 + },
24037 + },
24038 + {
24039 + AVR32_OPC_ST_D4, 4, 0xe0e10000, 0xe1f10000,
24040 + &avr32_syntax_table[AVR32_SYNTAX_ST_D4],
24041 + BFD_RELOC_AVR32_16S, 3, 1,
24042 + {
24043 + &avr32_ifield_table[AVR32_IFIELD_RX],
24044 + &avr32_ifield_table[AVR32_IFIELD_K16],
24045 + &avr32_ifield_table[AVR32_IFIELD_RY_DW],
24046 + },
24047 + },
24048 + {
24049 + AVR32_OPC_ST_H1, 2, 0x00b00000, 0xe1f00000,
24050 + &avr32_syntax_table[AVR32_SYNTAX_ST_H1],
24051 + BFD_RELOC_UNUSED, 2, -1,
24052 + {
24053 + &avr32_ifield_table[AVR32_IFIELD_RX],
24054 + &avr32_ifield_table[AVR32_IFIELD_RY],
24055 + },
24056 + },
24057 + {
24058 + AVR32_OPC_ST_H2, 2, 0x00e00000, 0xe1f00000,
24059 + &avr32_syntax_table[AVR32_SYNTAX_ST_H2],
24060 + BFD_RELOC_UNUSED, 2, -1,
24061 + {
24062 + &avr32_ifield_table[AVR32_IFIELD_RX],
24063 + &avr32_ifield_table[AVR32_IFIELD_RY],
24064 + },
24065 + },
24066 + {
24067 + AVR32_OPC_ST_H5, 4, 0xe0000a00, 0xe1f0ffc0,
24068 + &avr32_syntax_table[AVR32_SYNTAX_ST_H5],
24069 + BFD_RELOC_UNUSED, 4, -1,
24070 + {
24071 + &avr32_ifield_table[AVR32_IFIELD_RX],
24072 + &avr32_ifield_table[AVR32_IFIELD_RY],
24073 + &avr32_ifield_table[AVR32_IFIELD_K2],
24074 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
24075 + },
24076 + },
24077 + {
24078 + AVR32_OPC_ST_H3, 2, 0xa0000000, 0xe1800000,
24079 + &avr32_syntax_table[AVR32_SYNTAX_ST_H3],
24080 + BFD_RELOC_AVR32_4UH, 3, 1,
24081 + {
24082 + &avr32_ifield_table[AVR32_IFIELD_RX],
24083 + &avr32_ifield_table[AVR32_IFIELD_K3],
24084 + &avr32_ifield_table[AVR32_IFIELD_RY],
24085 + },
24086 + },
24087 + {
24088 + AVR32_OPC_ST_H4, 4, 0xe1500000, 0xe1f00000,
24089 + &avr32_syntax_table[AVR32_SYNTAX_ST_H4],
24090 + BFD_RELOC_AVR32_16S, 3, 1,
24091 + {
24092 + &avr32_ifield_table[AVR32_IFIELD_RX],
24093 + &avr32_ifield_table[AVR32_IFIELD_K16],
24094 + &avr32_ifield_table[AVR32_IFIELD_RY],
24095 + },
24096 + },
24097 + {
24098 + AVR32_OPC_ST_W1, 2, 0x00a00000, 0xe1f00000,
24099 + &avr32_syntax_table[AVR32_SYNTAX_ST_W1],
24100 + BFD_RELOC_UNUSED, 2, -1,
24101 + {
24102 + &avr32_ifield_table[AVR32_IFIELD_RX],
24103 + &avr32_ifield_table[AVR32_IFIELD_RY],
24104 + },
24105 + },
24106 + {
24107 + AVR32_OPC_ST_W2, 2, 0x00d00000, 0xe1f00000,
24108 + &avr32_syntax_table[AVR32_SYNTAX_ST_W2],
24109 + BFD_RELOC_UNUSED, 2, -1,
24110 + {
24111 + &avr32_ifield_table[AVR32_IFIELD_RX],
24112 + &avr32_ifield_table[AVR32_IFIELD_RY],
24113 + },
24114 + },
24115 + {
24116 + AVR32_OPC_ST_W5, 4, 0xe0000900, 0xe1f0ffc0,
24117 + &avr32_syntax_table[AVR32_SYNTAX_ST_W5],
24118 + BFD_RELOC_UNUSED, 4, -1,
24119 + {
24120 + &avr32_ifield_table[AVR32_IFIELD_RX],
24121 + &avr32_ifield_table[AVR32_IFIELD_RY],
24122 + &avr32_ifield_table[AVR32_IFIELD_K2],
24123 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
24124 + },
24125 + },
24126 + {
24127 + AVR32_OPC_ST_W3, 2, 0x81000000, 0xe1000000,
24128 + &avr32_syntax_table[AVR32_SYNTAX_ST_W3],
24129 + BFD_RELOC_AVR32_6UW, 3, 1,
24130 + {
24131 + &avr32_ifield_table[AVR32_IFIELD_RX],
24132 + &avr32_ifield_table[AVR32_IFIELD_K4],
24133 + &avr32_ifield_table[AVR32_IFIELD_RY],
24134 + },
24135 + },
24136 + {
24137 + AVR32_OPC_ST_W4, 4, 0xe1400000, 0xe1f00000,
24138 + &avr32_syntax_table[AVR32_SYNTAX_ST_W4],
24139 + BFD_RELOC_AVR32_16S, 3, 1,
24140 + {
24141 + &avr32_ifield_table[AVR32_IFIELD_RX],
24142 + &avr32_ifield_table[AVR32_IFIELD_K16],
24143 + &avr32_ifield_table[AVR32_IFIELD_RY],
24144 + },
24145 + },
24146 + {
24147 + AVR32_OPC_STC_D1, 4, 0xeba01000, 0xfff01100,
24148 + &avr32_syntax_table[AVR32_SYNTAX_STC_D1],
24149 + BFD_RELOC_AVR32_10UW, 4, 2,
24150 + {
24151 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24152 + &avr32_ifield_table[AVR32_IFIELD_RY],
24153 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24154 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
24155 + },
24156 + },
24157 + {
24158 + AVR32_OPC_STC_D2, 4, 0xefa00070, 0xfff011f0,
24159 + &avr32_syntax_table[AVR32_SYNTAX_STC_D2],
24160 + BFD_RELOC_UNUSED, 3, -1,
24161 + {
24162 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24163 + &avr32_ifield_table[AVR32_IFIELD_RY],
24164 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
24165 + },
24166 + },
24167 + {
24168 + AVR32_OPC_STC_D3, 4, 0xefa010c0, 0xfff011c0,
24169 + &avr32_syntax_table[AVR32_SYNTAX_STC_D3],
24170 + BFD_RELOC_UNUSED, 5, -1,
24171 + {
24172 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24173 + &avr32_ifield_table[AVR32_IFIELD_RY],
24174 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
24175 + &avr32_ifield_table[AVR32_IFIELD_K2],
24176 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
24177 + },
24178 + },
24179 + {
24180 + AVR32_OPC_STC_W1, 4, 0xeba00000, 0xfff01000,
24181 + &avr32_syntax_table[AVR32_SYNTAX_STC_W1],
24182 + BFD_RELOC_AVR32_10UW, 4, 2,
24183 + {
24184 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24185 + &avr32_ifield_table[AVR32_IFIELD_RY],
24186 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24187 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
24188 + },
24189 + },
24190 + {
24191 + AVR32_OPC_STC_W2, 4, 0xefa00060, 0xfff010ff,
24192 + &avr32_syntax_table[AVR32_SYNTAX_STC_W2],
24193 + BFD_RELOC_UNUSED, 3, -1,
24194 + {
24195 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24196 + &avr32_ifield_table[AVR32_IFIELD_RY],
24197 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
24198 + },
24199 + },
24200 + {
24201 + AVR32_OPC_STC_W3, 4, 0xefa01080, 0xfff010c0,
24202 + &avr32_syntax_table[AVR32_SYNTAX_STC_W3],
24203 + BFD_RELOC_UNUSED, 5, -1,
24204 + {
24205 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24206 + &avr32_ifield_table[AVR32_IFIELD_RY],
24207 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
24208 + &avr32_ifield_table[AVR32_IFIELD_K2],
24209 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
24210 + },
24211 + },
24212 + {
24213 + AVR32_OPC_STC0_D, 4, 0xf7a00000, 0xfff00100,
24214 + &avr32_syntax_table[AVR32_SYNTAX_STC0_D],
24215 + BFD_RELOC_AVR32_14UW, 3, 1,
24216 + {
24217 + &avr32_ifield_table[AVR32_IFIELD_RY],
24218 + &avr32_ifield_table[AVR32_IFIELD_K12CP],
24219 + &avr32_ifield_table[AVR32_IFIELD_CRD_DW],
24220 + },
24221 + },
24222 + {
24223 + AVR32_OPC_STC0_W, 4, 0xf5a00000, 0xfff00000,
24224 + &avr32_syntax_table[AVR32_SYNTAX_STC0_W],
24225 + BFD_RELOC_AVR32_14UW, 3, 1,
24226 + {
24227 + &avr32_ifield_table[AVR32_IFIELD_RY],
24228 + &avr32_ifield_table[AVR32_IFIELD_K12CP],
24229 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
24230 + },
24231 + },
24232 + {
24233 + AVR32_OPC_STCM_D, 4, 0xeda00500, 0xfff01f00,
24234 + &avr32_syntax_table[AVR32_SYNTAX_STCM_D],
24235 + BFD_RELOC_UNUSED, 3, -1,
24236 + {
24237 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24238 + &avr32_ifield_table[AVR32_IFIELD_RY],
24239 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24240 + },
24241 + },
24242 + {
24243 + AVR32_OPC_STCM_D_PU, 4, 0xeda01500, 0xfff01f00,
24244 + &avr32_syntax_table[AVR32_SYNTAX_STCM_D_PU],
24245 + BFD_RELOC_UNUSED, 3, -1,
24246 + {
24247 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24248 + &avr32_ifield_table[AVR32_IFIELD_RY],
24249 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24250 + },
24251 + },
24252 + {
24253 + AVR32_OPC_STCM_W, 4, 0xeda00200, 0xfff01e00,
24254 + &avr32_syntax_table[AVR32_SYNTAX_STCM_W],
24255 + BFD_RELOC_UNUSED, 4, -1,
24256 + {
24257 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24258 + &avr32_ifield_table[AVR32_IFIELD_RY],
24259 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24260 + &avr32_ifield_table[AVR32_IFIELD_CM_HL],
24261 + },
24262 + },
24263 + {
24264 + AVR32_OPC_STCM_W_PU, 4, 0xeda01200, 0xfff01e00,
24265 + &avr32_syntax_table[AVR32_SYNTAX_STCM_W_PU],
24266 + BFD_RELOC_UNUSED, 4, -1,
24267 + {
24268 + &avr32_ifield_table[AVR32_IFIELD_CPNO],
24269 + &avr32_ifield_table[AVR32_IFIELD_RY],
24270 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24271 + &avr32_ifield_table[AVR32_IFIELD_CM_HL],
24272 + },
24273 + },
24274 + {
24275 + AVR32_OPC_STCOND, 4, 0xe1700000, 0xe1f00000,
24276 + &avr32_syntax_table[AVR32_SYNTAX_STCOND],
24277 + BFD_RELOC_UNUSED, 3, -1,
24278 + {
24279 + &avr32_ifield_table[AVR32_IFIELD_RX],
24280 + &avr32_ifield_table[AVR32_IFIELD_K16],
24281 + &avr32_ifield_table[AVR32_IFIELD_RY],
24282 + },
24283 + },
24284 + {
24285 + AVR32_OPC_STDSP, 2, 0x50000000, 0xf8000000,
24286 + &avr32_syntax_table[AVR32_SYNTAX_STDSP],
24287 + BFD_RELOC_UNUSED, 2, -1,
24288 + {
24289 + &avr32_ifield_table[AVR32_IFIELD_K7C],
24290 + &avr32_ifield_table[AVR32_IFIELD_RY],
24291 + },
24292 + },
24293 + {
24294 + AVR32_OPC_STHH_W2, 4, 0xe1e08000, 0xe1f0c0c0,
24295 + &avr32_syntax_table[AVR32_SYNTAX_STHH_W2],
24296 + BFD_RELOC_UNUSED, 7, -1,
24297 + {
24298 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
24299 + &avr32_ifield_table[AVR32_IFIELD_CRD_RI],
24300 + &avr32_ifield_table[AVR32_IFIELD_K2],
24301 + &avr32_ifield_table[AVR32_IFIELD_RX],
24302 + &avr32_ifield_table[AVR32_IFIELD_X2],
24303 + &avr32_ifield_table[AVR32_IFIELD_RY],
24304 + &avr32_ifield_table[AVR32_IFIELD_Y2],
24305 + },
24306 + },
24307 + {
24308 + AVR32_OPC_STHH_W1, 4, 0xe1e0c000, 0xe1f0c000,
24309 + &avr32_syntax_table[AVR32_SYNTAX_STHH_W1],
24310 + BFD_RELOC_AVR32_STHH_W, 6, 1,
24311 + {
24312 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
24313 + &avr32_ifield_table[AVR32_IFIELD_K8E2],
24314 + &avr32_ifield_table[AVR32_IFIELD_RX],
24315 + &avr32_ifield_table[AVR32_IFIELD_X2],
24316 + &avr32_ifield_table[AVR32_IFIELD_RY],
24317 + &avr32_ifield_table[AVR32_IFIELD_Y2],
24318 + },
24319 + },
24320 + {
24321 + AVR32_OPC_STM, 4, 0xe9c00000, 0xfff00000,
24322 + &avr32_syntax_table[AVR32_SYNTAX_STM],
24323 + BFD_RELOC_UNUSED, 2, -1,
24324 + {
24325 + &avr32_ifield_table[AVR32_IFIELD_RY],
24326 + &avr32_ifield_table[AVR32_IFIELD_K16],
24327 + },
24328 + },
24329 + {
24330 + AVR32_OPC_STM_PU, 4, 0xebc00000, 0xfff00000,
24331 + &avr32_syntax_table[AVR32_SYNTAX_STM_PU],
24332 + BFD_RELOC_UNUSED, 2, -1,
24333 + {
24334 + &avr32_ifield_table[AVR32_IFIELD_RY],
24335 + &avr32_ifield_table[AVR32_IFIELD_K16],
24336 + },
24337 + },
24338 + {
24339 + AVR32_OPC_STMTS, 4, 0xedc00000, 0xfff00000,
24340 + &avr32_syntax_table[AVR32_SYNTAX_STMTS],
24341 + BFD_RELOC_UNUSED, 2, -1,
24342 + {
24343 + &avr32_ifield_table[AVR32_IFIELD_RY],
24344 + &avr32_ifield_table[AVR32_IFIELD_K16],
24345 + },
24346 + },
24347 + {
24348 + AVR32_OPC_STMTS_PU, 4, 0xefc00000, 0xfff00000,
24349 + &avr32_syntax_table[AVR32_SYNTAX_STMTS_PU],
24350 + BFD_RELOC_UNUSED, 2, -1,
24351 + {
24352 + &avr32_ifield_table[AVR32_IFIELD_RY],
24353 + &avr32_ifield_table[AVR32_IFIELD_K16],
24354 + },
24355 + },
24356 + {
24357 + AVR32_OPC_STSWP_H, 4, 0xe1d09000, 0xe1f0f000,
24358 + &avr32_syntax_table[AVR32_SYNTAX_STSWP_H],
24359 + BFD_RELOC_UNUSED, 3, -1,
24360 + {
24361 + &avr32_ifield_table[AVR32_IFIELD_RX],
24362 + &avr32_ifield_table[AVR32_IFIELD_K12],
24363 + &avr32_ifield_table[AVR32_IFIELD_RY],
24364 + },
24365 + },
24366 + {
24367 + AVR32_OPC_STSWP_W, 4, 0xe1d0a000, 0xe1f0f000,
24368 + &avr32_syntax_table[AVR32_SYNTAX_STSWP_W],
24369 + BFD_RELOC_UNUSED, 3, -1,
24370 + {
24371 + &avr32_ifield_table[AVR32_IFIELD_RX],
24372 + &avr32_ifield_table[AVR32_IFIELD_K12],
24373 + &avr32_ifield_table[AVR32_IFIELD_RY],
24374 + },
24375 + },
24376 + {
24377 + AVR32_OPC_SUB1, 2, 0x00100000, 0xe1f00000,
24378 + &avr32_syntax_table[AVR32_SYNTAX_SUB1],
24379 + BFD_RELOC_UNUSED, 2, -1,
24380 + {
24381 + &avr32_ifield_table[AVR32_IFIELD_RY],
24382 + &avr32_ifield_table[AVR32_IFIELD_RX],
24383 + },
24384 + },
24385 + {
24386 + AVR32_OPC_SUB2, 4, 0xe0000100, 0xe1f0ffc0,
24387 + &avr32_syntax_table[AVR32_SYNTAX_SUB2],
24388 + BFD_RELOC_UNUSED, 4, -1,
24389 + {
24390 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
24391 + &avr32_ifield_table[AVR32_IFIELD_RX],
24392 + &avr32_ifield_table[AVR32_IFIELD_RY],
24393 + &avr32_ifield_table[AVR32_IFIELD_K2],
24394 + },
24395 + },
24396 + {
24397 + AVR32_OPC_SUB5, 4, 0xe0c00000, 0xe1f00000,
24398 + &avr32_syntax_table[AVR32_SYNTAX_SUB5],
24399 + BFD_RELOC_AVR32_SUB5, 3, 2,
24400 + {
24401 + &avr32_ifield_table[AVR32_IFIELD_RY],
24402 + &avr32_ifield_table[AVR32_IFIELD_RX],
24403 + &avr32_ifield_table[AVR32_IFIELD_K16],
24404 + },
24405 + },
24406 + {
24407 + AVR32_OPC_SUB3_SP, 2, 0x200d0000, 0xf00f0000,
24408 + &avr32_syntax_table[AVR32_SYNTAX_SUB3_SP],
24409 + BFD_RELOC_AVR32_10SW, 2, 1,
24410 + {
24411 + &avr32_ifield_table[AVR32_IFIELD_RY],
24412 + &avr32_ifield_table[AVR32_IFIELD_K8C],
24413 + },
24414 + },
24415 + {
24416 + AVR32_OPC_SUB3, 2, 0x20000000, 0xf0000000,
24417 + &avr32_syntax_table[AVR32_SYNTAX_SUB3],
24418 + BFD_RELOC_AVR32_8S, 2, 1,
24419 + {
24420 + &avr32_ifield_table[AVR32_IFIELD_RY],
24421 + &avr32_ifield_table[AVR32_IFIELD_K8C],
24422 + },
24423 + },
24424 + {
24425 + AVR32_OPC_SUB4, 4, 0xe0200000, 0xe1e00000,
24426 + &avr32_syntax_table[AVR32_SYNTAX_SUB4],
24427 + BFD_RELOC_AVR32_21S, 2, 1,
24428 + {
24429 + &avr32_ifield_table[AVR32_IFIELD_RY],
24430 + &avr32_ifield_table[AVR32_IFIELD_K21],
24431 + },
24432 + },
24433 + {
24434 + AVR32_OPC_SUBEQ, 4, 0xf7b00000, 0xfff0ff00,
24435 + &avr32_syntax_table[AVR32_SYNTAX_SUBEQ],
24436 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24437 + {
24438 + &avr32_ifield_table[AVR32_IFIELD_RY],
24439 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24440 + },
24441 + },
24442 + {
24443 + AVR32_OPC_SUBNE, 4, 0xf7b00100, 0xfff0ff00,
24444 + &avr32_syntax_table[AVR32_SYNTAX_SUBNE],
24445 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24446 + {
24447 + &avr32_ifield_table[AVR32_IFIELD_RY],
24448 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24449 + },
24450 + },
24451 + {
24452 + AVR32_OPC_SUBCC, 4, 0xf7b00200, 0xfff0ff00,
24453 + &avr32_syntax_table[AVR32_SYNTAX_SUBHS],
24454 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24455 + {
24456 + &avr32_ifield_table[AVR32_IFIELD_RY],
24457 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24458 + },
24459 + },
24460 + {
24461 + AVR32_OPC_SUBCS, 4, 0xf7b00300, 0xfff0ff00,
24462 + &avr32_syntax_table[AVR32_SYNTAX_SUBLO],
24463 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24464 + {
24465 + &avr32_ifield_table[AVR32_IFIELD_RY],
24466 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24467 + },
24468 + },
24469 + {
24470 + AVR32_OPC_SUBGE, 4, 0xf7b00400, 0xfff0ff00,
24471 + &avr32_syntax_table[AVR32_SYNTAX_SUBGE],
24472 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24473 + {
24474 + &avr32_ifield_table[AVR32_IFIELD_RY],
24475 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24476 + },
24477 + },
24478 + {
24479 + AVR32_OPC_SUBLT, 4, 0xf7b00500, 0xfff0ff00,
24480 + &avr32_syntax_table[AVR32_SYNTAX_SUBLT],
24481 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24482 + {
24483 + &avr32_ifield_table[AVR32_IFIELD_RY],
24484 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24485 + },
24486 + },
24487 + {
24488 + AVR32_OPC_SUBMI, 4, 0xf7b00600, 0xfff0ff00,
24489 + &avr32_syntax_table[AVR32_SYNTAX_SUBMI],
24490 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24491 + {
24492 + &avr32_ifield_table[AVR32_IFIELD_RY],
24493 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24494 + },
24495 + },
24496 + {
24497 + AVR32_OPC_SUBPL, 4, 0xf7b00700, 0xfff0ff00,
24498 + &avr32_syntax_table[AVR32_SYNTAX_SUBPL],
24499 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24500 + {
24501 + &avr32_ifield_table[AVR32_IFIELD_RY],
24502 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24503 + },
24504 + },
24505 + {
24506 + AVR32_OPC_SUBLS, 4, 0xf7b00800, 0xfff0ff00,
24507 + &avr32_syntax_table[AVR32_SYNTAX_SUBLS],
24508 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24509 + {
24510 + &avr32_ifield_table[AVR32_IFIELD_RY],
24511 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24512 + },
24513 + },
24514 + {
24515 + AVR32_OPC_SUBGT, 4, 0xf7b00900, 0xfff0ff00,
24516 + &avr32_syntax_table[AVR32_SYNTAX_SUBGT],
24517 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24518 + {
24519 + &avr32_ifield_table[AVR32_IFIELD_RY],
24520 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24521 + },
24522 + },
24523 + {
24524 + AVR32_OPC_SUBLE, 4, 0xf7b00a00, 0xfff0ff00,
24525 + &avr32_syntax_table[AVR32_SYNTAX_SUBLE],
24526 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24527 + {
24528 + &avr32_ifield_table[AVR32_IFIELD_RY],
24529 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24530 + },
24531 + },
24532 + {
24533 + AVR32_OPC_SUBHI, 4, 0xf7b00b00, 0xfff0ff00,
24534 + &avr32_syntax_table[AVR32_SYNTAX_SUBHI],
24535 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24536 + {
24537 + &avr32_ifield_table[AVR32_IFIELD_RY],
24538 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24539 + },
24540 + },
24541 + {
24542 + AVR32_OPC_SUBVS, 4, 0xf7b00c00, 0xfff0ff00,
24543 + &avr32_syntax_table[AVR32_SYNTAX_SUBVS],
24544 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24545 + {
24546 + &avr32_ifield_table[AVR32_IFIELD_RY],
24547 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24548 + },
24549 + },
24550 + {
24551 + AVR32_OPC_SUBVC, 4, 0xf7b00d00, 0xfff0ff00,
24552 + &avr32_syntax_table[AVR32_SYNTAX_SUBVC],
24553 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24554 + {
24555 + &avr32_ifield_table[AVR32_IFIELD_RY],
24556 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24557 + },
24558 + },
24559 + {
24560 + AVR32_OPC_SUBQS, 4, 0xf7b00e00, 0xfff0ff00,
24561 + &avr32_syntax_table[AVR32_SYNTAX_SUBQS],
24562 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24563 + {
24564 + &avr32_ifield_table[AVR32_IFIELD_RY],
24565 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24566 + },
24567 + },
24568 + {
24569 + AVR32_OPC_SUBAL, 4, 0xf7b00f00, 0xfff0ff00,
24570 + &avr32_syntax_table[AVR32_SYNTAX_SUBAL],
24571 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24572 + {
24573 + &avr32_ifield_table[AVR32_IFIELD_RY],
24574 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24575 + },
24576 + },
24577 + {
24578 + AVR32_OPC_SUBFEQ, 4, 0xf5b00000, 0xfff0ff00,
24579 + &avr32_syntax_table[AVR32_SYNTAX_SUBFEQ],
24580 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24581 + {
24582 + &avr32_ifield_table[AVR32_IFIELD_RY],
24583 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24584 + },
24585 + },
24586 + {
24587 + AVR32_OPC_SUBFNE, 4, 0xf5b00100, 0xfff0ff00,
24588 + &avr32_syntax_table[AVR32_SYNTAX_SUBFNE],
24589 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24590 + {
24591 + &avr32_ifield_table[AVR32_IFIELD_RY],
24592 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24593 + },
24594 + },
24595 + {
24596 + AVR32_OPC_SUBFCC, 4, 0xf5b00200, 0xfff0ff00,
24597 + &avr32_syntax_table[AVR32_SYNTAX_SUBFHS],
24598 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24599 + {
24600 + &avr32_ifield_table[AVR32_IFIELD_RY],
24601 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24602 + },
24603 + },
24604 + {
24605 + AVR32_OPC_SUBFCS, 4, 0xf5b00300, 0xfff0ff00,
24606 + &avr32_syntax_table[AVR32_SYNTAX_SUBFLO],
24607 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24608 + {
24609 + &avr32_ifield_table[AVR32_IFIELD_RY],
24610 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24611 + },
24612 + },
24613 + {
24614 + AVR32_OPC_SUBFGE, 4, 0xf5b00400, 0xfff0ff00,
24615 + &avr32_syntax_table[AVR32_SYNTAX_SUBFGE],
24616 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24617 + {
24618 + &avr32_ifield_table[AVR32_IFIELD_RY],
24619 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24620 + },
24621 + },
24622 + {
24623 + AVR32_OPC_SUBFLT, 4, 0xf5b00500, 0xfff0ff00,
24624 + &avr32_syntax_table[AVR32_SYNTAX_SUBFLT],
24625 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24626 + {
24627 + &avr32_ifield_table[AVR32_IFIELD_RY],
24628 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24629 + },
24630 + },
24631 + {
24632 + AVR32_OPC_SUBFMI, 4, 0xf5b00600, 0xfff0ff00,
24633 + &avr32_syntax_table[AVR32_SYNTAX_SUBFMI],
24634 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24635 + {
24636 + &avr32_ifield_table[AVR32_IFIELD_RY],
24637 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24638 + },
24639 + },
24640 + {
24641 + AVR32_OPC_SUBFPL, 4, 0xf5b00700, 0xfff0ff00,
24642 + &avr32_syntax_table[AVR32_SYNTAX_SUBFPL],
24643 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24644 + {
24645 + &avr32_ifield_table[AVR32_IFIELD_RY],
24646 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24647 + },
24648 + },
24649 + {
24650 + AVR32_OPC_SUBFLS, 4, 0xf5b00800, 0xfff0ff00,
24651 + &avr32_syntax_table[AVR32_SYNTAX_SUBFLS],
24652 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24653 + {
24654 + &avr32_ifield_table[AVR32_IFIELD_RY],
24655 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24656 + },
24657 + },
24658 + {
24659 + AVR32_OPC_SUBFGT, 4, 0xf5b00900, 0xfff0ff00,
24660 + &avr32_syntax_table[AVR32_SYNTAX_SUBFGT],
24661 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24662 + {
24663 + &avr32_ifield_table[AVR32_IFIELD_RY],
24664 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24665 + },
24666 + },
24667 + {
24668 + AVR32_OPC_SUBFLE, 4, 0xf5b00a00, 0xfff0ff00,
24669 + &avr32_syntax_table[AVR32_SYNTAX_SUBFLE],
24670 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24671 + {
24672 + &avr32_ifield_table[AVR32_IFIELD_RY],
24673 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24674 + },
24675 + },
24676 + {
24677 + AVR32_OPC_SUBFHI, 4, 0xf5b00b00, 0xfff0ff00,
24678 + &avr32_syntax_table[AVR32_SYNTAX_SUBFHI],
24679 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24680 + {
24681 + &avr32_ifield_table[AVR32_IFIELD_RY],
24682 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24683 + },
24684 + },
24685 + {
24686 + AVR32_OPC_SUBFVS, 4, 0xf5b00c00, 0xfff0ff00,
24687 + &avr32_syntax_table[AVR32_SYNTAX_SUBFVS],
24688 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24689 + {
24690 + &avr32_ifield_table[AVR32_IFIELD_RY],
24691 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24692 + },
24693 + },
24694 + {
24695 + AVR32_OPC_SUBFVC, 4, 0xf5b00d00, 0xfff0ff00,
24696 + &avr32_syntax_table[AVR32_SYNTAX_SUBFVC],
24697 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24698 + {
24699 + &avr32_ifield_table[AVR32_IFIELD_RY],
24700 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24701 + },
24702 + },
24703 + {
24704 + AVR32_OPC_SUBFQS, 4, 0xf5b00e00, 0xfff0ff00,
24705 + &avr32_syntax_table[AVR32_SYNTAX_SUBFQS],
24706 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24707 + {
24708 + &avr32_ifield_table[AVR32_IFIELD_RY],
24709 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24710 + },
24711 + },
24712 + {
24713 + AVR32_OPC_SUBFAL, 4, 0xf5b00f00, 0xfff0ff00,
24714 + &avr32_syntax_table[AVR32_SYNTAX_SUBFAL],
24715 + BFD_RELOC_AVR32_8S_EXT, 2, 1,
24716 + {
24717 + &avr32_ifield_table[AVR32_IFIELD_RY],
24718 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24719 + },
24720 + },
24721 + {
24722 + AVR32_OPC_SUBHH_W, 4, 0xe0000f00, 0xe1f0ffc0,
24723 + &avr32_syntax_table[AVR32_SYNTAX_SUBHH_W],
24724 + BFD_RELOC_UNUSED, 5, -1,
24725 + {
24726 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
24727 + &avr32_ifield_table[AVR32_IFIELD_RX],
24728 + &avr32_ifield_table[AVR32_IFIELD_X],
24729 + &avr32_ifield_table[AVR32_IFIELD_RY],
24730 + &avr32_ifield_table[AVR32_IFIELD_Y],
24731 + },
24732 + },
24733 + {
24734 + AVR32_OPC_SWAP_B, 2, 0x5cb00000, 0xfff00000,
24735 + &avr32_syntax_table[AVR32_SYNTAX_SWAP_B],
24736 + BFD_RELOC_UNUSED, 1, -1,
24737 + {
24738 + &avr32_ifield_table[AVR32_IFIELD_RY],
24739 + }
24740 + },
24741 + {
24742 + AVR32_OPC_SWAP_BH, 2, 0x5cc00000, 0xfff00000,
24743 + &avr32_syntax_table[AVR32_SYNTAX_SWAP_BH],
24744 + BFD_RELOC_UNUSED, 1, -1,
24745 + {
24746 + &avr32_ifield_table[AVR32_IFIELD_RY],
24747 + }
24748 + },
24749 + {
24750 + AVR32_OPC_SWAP_H, 2, 0x5ca00000, 0xfff00000,
24751 + &avr32_syntax_table[AVR32_SYNTAX_SWAP_H],
24752 + BFD_RELOC_UNUSED, 1, -1,
24753 + {
24754 + &avr32_ifield_table[AVR32_IFIELD_RY],
24755 + }
24756 + },
24757 + {
24758 + AVR32_OPC_SYNC, 4, 0xebb00000, 0xffffff00,
24759 + &avr32_syntax_table[AVR32_SYNTAX_SYNC],
24760 + BFD_RELOC_AVR32_8S_EXT, 1, 0,
24761 + {
24762 + &avr32_ifield_table[AVR32_IFIELD_K8E],
24763 + }
24764 + },
24765 + {
24766 + AVR32_OPC_TLBR, 2, 0xd6430000, 0xffff0000,
24767 + &avr32_syntax_table[AVR32_SYNTAX_TLBR],
24768 + BFD_RELOC_UNUSED, 0, -1, { NULL },
24769 + },
24770 + {
24771 + AVR32_OPC_TLBS, 2, 0xd6530000, 0xffff0000,
24772 + &avr32_syntax_table[AVR32_SYNTAX_TLBS],
24773 + BFD_RELOC_UNUSED, 0, -1, { NULL },
24774 + },
24775 + {
24776 + AVR32_OPC_TLBW, 2, 0xd6630000, 0xffff0000,
24777 + &avr32_syntax_table[AVR32_SYNTAX_TLBW],
24778 + BFD_RELOC_UNUSED, 0, -1, { NULL },
24779 + },
24780 + {
24781 + AVR32_OPC_TNBZ, 2, 0x5ce00000, 0xfff00000,
24782 + &avr32_syntax_table[AVR32_SYNTAX_TNBZ],
24783 + BFD_RELOC_UNUSED, 1, -1,
24784 + {
24785 + &avr32_ifield_table[AVR32_IFIELD_RY],
24786 + }
24787 + },
24788 + {
24789 + AVR32_OPC_TST, 2, 0x00700000, 0xe1f00000,
24790 + &avr32_syntax_table[AVR32_SYNTAX_TST],
24791 + BFD_RELOC_UNUSED, 2, -1,
24792 + {
24793 + &avr32_ifield_table[AVR32_IFIELD_RY],
24794 + &avr32_ifield_table[AVR32_IFIELD_RX],
24795 + },
24796 + },
24797 + {
24798 + AVR32_OPC_XCHG, 4, 0xe0000b40, 0xe1f0fff0,
24799 + &avr32_syntax_table[AVR32_SYNTAX_XCHG],
24800 + BFD_RELOC_UNUSED, 3, -1,
24801 + {
24802 + &avr32_ifield_table[AVR32_IFIELD_RD_E],
24803 + &avr32_ifield_table[AVR32_IFIELD_RX],
24804 + &avr32_ifield_table[AVR32_IFIELD_RY],
24805 + },
24806 + },
24807 + {
24808 + AVR32_OPC_MEMC, 4, 0xf6100000, 0xfff00000,
24809 + &avr32_syntax_table[AVR32_SYNTAX_MEMC],
24810 + BFD_RELOC_AVR32_15S, 2, 0,
24811 + {
24812 + &avr32_ifield_table[AVR32_IFIELD_MEM15],
24813 + &avr32_ifield_table[AVR32_IFIELD_MEMB5],
24814 + },
24815 + },
24816 + {
24817 + AVR32_OPC_MEMS, 4, 0xf8100000, 0xfff00000,
24818 + &avr32_syntax_table[AVR32_SYNTAX_MEMS],
24819 + BFD_RELOC_AVR32_15S, 2, 0,
24820 + {
24821 + &avr32_ifield_table[AVR32_IFIELD_MEM15],
24822 + &avr32_ifield_table[AVR32_IFIELD_MEMB5],
24823 + },
24824 + },
24825 + {
24826 + AVR32_OPC_MEMT, 4, 0xfa100000, 0xfff00000,
24827 + &avr32_syntax_table[AVR32_SYNTAX_MEMT],
24828 + BFD_RELOC_AVR32_15S, 2, 0,
24829 + {
24830 + &avr32_ifield_table[AVR32_IFIELD_MEM15],
24831 + &avr32_ifield_table[AVR32_IFIELD_MEMB5],
24832 + },
24833 + },
24834 + {
24835 + AVR32_OPC_BFEXTS, 4, 0xe1d0b000, 0xe1f0fc00,
24836 + &avr32_syntax_table[AVR32_SYNTAX_BFEXTS],
24837 + BFD_RELOC_UNUSED, 4, -1,
24838 + {
24839 + &avr32_ifield_table[AVR32_IFIELD_RX],
24840 + &avr32_ifield_table[AVR32_IFIELD_RY],
24841 + &avr32_ifield_table[AVR32_IFIELD_S5],
24842 + &avr32_ifield_table[AVR32_IFIELD_K5E],
24843 + },
24844 + },
24845 + {
24846 + AVR32_OPC_BFEXTU, 4, 0xe1d0c000, 0xe1f0fc00,
24847 + &avr32_syntax_table[AVR32_SYNTAX_BFEXTU],
24848 + BFD_RELOC_UNUSED, 4, -1,
24849 + {
24850 + &avr32_ifield_table[AVR32_IFIELD_RX],
24851 + &avr32_ifield_table[AVR32_IFIELD_RY],
24852 + &avr32_ifield_table[AVR32_IFIELD_S5],
24853 + &avr32_ifield_table[AVR32_IFIELD_K5E],
24854 + },
24855 + },
24856 + {
24857 + AVR32_OPC_BFINS, 4, 0xe1d0d000, 0xe1f0fc00,
24858 + &avr32_syntax_table[AVR32_SYNTAX_BFINS],
24859 + BFD_RELOC_UNUSED, 4, -1,
24860 + {
24861 + &avr32_ifield_table[AVR32_IFIELD_RX],
24862 + &avr32_ifield_table[AVR32_IFIELD_RY],
24863 + &avr32_ifield_table[AVR32_IFIELD_S5],
24864 + &avr32_ifield_table[AVR32_IFIELD_K5E],
24865 + },
24866 + },
24867 +#define AVR32_OPCODE_RSUBCOND(cond_name, cond_field) \
24868 + { \
24869 + AVR32_OPC_RSUB ## cond_name , 4, \
24870 + 0xfbb00000 | (cond_field << 8), 0xfff0ff00, \
24871 + &avr32_syntax_table[AVR32_SYNTAX_RSUB ## cond_name ], \
24872 + BFD_RELOC_AVR32_8S_EXT, 2, 1, \
24873 + { \
24874 + &avr32_ifield_table[AVR32_IFIELD_RY], \
24875 + &avr32_ifield_table[AVR32_IFIELD_K8E], \
24876 + }, \
24877 + },
24878 +
24879 + AVR32_OPCODE_RSUBCOND (EQ, 0)
24880 + AVR32_OPCODE_RSUBCOND (NE, 1)
24881 + AVR32_OPCODE_RSUBCOND (CC, 2)
24882 + AVR32_OPCODE_RSUBCOND (CS, 3)
24883 + AVR32_OPCODE_RSUBCOND (GE, 4)
24884 + AVR32_OPCODE_RSUBCOND (LT, 5)
24885 + AVR32_OPCODE_RSUBCOND (MI, 6)
24886 + AVR32_OPCODE_RSUBCOND (PL, 7)
24887 + AVR32_OPCODE_RSUBCOND (LS, 8)
24888 + AVR32_OPCODE_RSUBCOND (GT, 9)
24889 + AVR32_OPCODE_RSUBCOND (LE, 10)
24890 + AVR32_OPCODE_RSUBCOND (HI, 11)
24891 + AVR32_OPCODE_RSUBCOND (VS, 12)
24892 + AVR32_OPCODE_RSUBCOND (VC, 13)
24893 + AVR32_OPCODE_RSUBCOND (QS, 14)
24894 + AVR32_OPCODE_RSUBCOND (AL, 15)
24895 +
24896 +#define AVR32_OPCODE_OP3_COND(op_name, op_field, cond_name, cond_field) \
24897 + { \
24898 + AVR32_OPC_ ## op_name ## cond_name , 4, \
24899 + 0xe1d0e000 | (cond_field << 8) | (op_field << 4), 0xe1f0fff0, \
24900 + &avr32_syntax_table[AVR32_SYNTAX_ ## op_name ## cond_name ], \
24901 + BFD_RELOC_UNUSED, 3, -1, \
24902 + { \
24903 + &avr32_ifield_table[AVR32_IFIELD_RD_E], \
24904 + &avr32_ifield_table[AVR32_IFIELD_RX], \
24905 + &avr32_ifield_table[AVR32_IFIELD_RY], \
24906 + }, \
24907 + },
24908 +
24909 + AVR32_OPCODE_OP3_COND (ADD, 0, EQ, 0)
24910 + AVR32_OPCODE_OP3_COND (ADD, 0, NE, 1)
24911 + AVR32_OPCODE_OP3_COND (ADD, 0, CC, 2)
24912 + AVR32_OPCODE_OP3_COND (ADD, 0, CS, 3)
24913 + AVR32_OPCODE_OP3_COND (ADD, 0, GE, 4)
24914 + AVR32_OPCODE_OP3_COND (ADD, 0, LT, 5)
24915 + AVR32_OPCODE_OP3_COND (ADD, 0, MI, 6)
24916 + AVR32_OPCODE_OP3_COND (ADD, 0, PL, 7)
24917 + AVR32_OPCODE_OP3_COND (ADD, 0, LS, 8)
24918 + AVR32_OPCODE_OP3_COND (ADD, 0, GT, 9)
24919 + AVR32_OPCODE_OP3_COND (ADD, 0, LE, 10)
24920 + AVR32_OPCODE_OP3_COND (ADD, 0, HI, 11)
24921 + AVR32_OPCODE_OP3_COND (ADD, 0, VS, 12)
24922 + AVR32_OPCODE_OP3_COND (ADD, 0, VC, 13)
24923 + AVR32_OPCODE_OP3_COND (ADD, 0, QS, 14)
24924 + AVR32_OPCODE_OP3_COND (ADD, 0, AL, 15)
24925 +
24926 + AVR32_OPCODE_OP3_COND (SUB2, 1, EQ, 0)
24927 + AVR32_OPCODE_OP3_COND (SUB2, 1, NE, 1)
24928 + AVR32_OPCODE_OP3_COND (SUB2, 1, CC, 2)
24929 + AVR32_OPCODE_OP3_COND (SUB2, 1, CS, 3)
24930 + AVR32_OPCODE_OP3_COND (SUB2, 1, GE, 4)
24931 + AVR32_OPCODE_OP3_COND (SUB2, 1, LT, 5)
24932 + AVR32_OPCODE_OP3_COND (SUB2, 1, MI, 6)
24933 + AVR32_OPCODE_OP3_COND (SUB2, 1, PL, 7)
24934 + AVR32_OPCODE_OP3_COND (SUB2, 1, LS, 8)
24935 + AVR32_OPCODE_OP3_COND (SUB2, 1, GT, 9)
24936 + AVR32_OPCODE_OP3_COND (SUB2, 1, LE, 10)
24937 + AVR32_OPCODE_OP3_COND (SUB2, 1, HI, 11)
24938 + AVR32_OPCODE_OP3_COND (SUB2, 1, VS, 12)
24939 + AVR32_OPCODE_OP3_COND (SUB2, 1, VC, 13)
24940 + AVR32_OPCODE_OP3_COND (SUB2, 1, QS, 14)
24941 + AVR32_OPCODE_OP3_COND (SUB2, 1, AL, 15)
24942 +
24943 + AVR32_OPCODE_OP3_COND (AND, 2, EQ, 0)
24944 + AVR32_OPCODE_OP3_COND (AND, 2, NE, 1)
24945 + AVR32_OPCODE_OP3_COND (AND, 2, CC, 2)
24946 + AVR32_OPCODE_OP3_COND (AND, 2, CS, 3)
24947 + AVR32_OPCODE_OP3_COND (AND, 2, GE, 4)
24948 + AVR32_OPCODE_OP3_COND (AND, 2, LT, 5)
24949 + AVR32_OPCODE_OP3_COND (AND, 2, MI, 6)
24950 + AVR32_OPCODE_OP3_COND (AND, 2, PL, 7)
24951 + AVR32_OPCODE_OP3_COND (AND, 2, LS, 8)
24952 + AVR32_OPCODE_OP3_COND (AND, 2, GT, 9)
24953 + AVR32_OPCODE_OP3_COND (AND, 2, LE, 10)
24954 + AVR32_OPCODE_OP3_COND (AND, 2, HI, 11)
24955 + AVR32_OPCODE_OP3_COND (AND, 2, VS, 12)
24956 + AVR32_OPCODE_OP3_COND (AND, 2, VC, 13)
24957 + AVR32_OPCODE_OP3_COND (AND, 2, QS, 14)
24958 + AVR32_OPCODE_OP3_COND (AND, 2, AL, 15)
24959 +
24960 + AVR32_OPCODE_OP3_COND (OR, 3, EQ, 0)
24961 + AVR32_OPCODE_OP3_COND (OR, 3, NE, 1)
24962 + AVR32_OPCODE_OP3_COND (OR, 3, CC, 2)
24963 + AVR32_OPCODE_OP3_COND (OR, 3, CS, 3)
24964 + AVR32_OPCODE_OP3_COND (OR, 3, GE, 4)
24965 + AVR32_OPCODE_OP3_COND (OR, 3, LT, 5)
24966 + AVR32_OPCODE_OP3_COND (OR, 3, MI, 6)
24967 + AVR32_OPCODE_OP3_COND (OR, 3, PL, 7)
24968 + AVR32_OPCODE_OP3_COND (OR, 3, LS, 8)
24969 + AVR32_OPCODE_OP3_COND (OR, 3, GT, 9)
24970 + AVR32_OPCODE_OP3_COND (OR, 3, LE, 10)
24971 + AVR32_OPCODE_OP3_COND (OR, 3, HI, 11)
24972 + AVR32_OPCODE_OP3_COND (OR, 3, VS, 12)
24973 + AVR32_OPCODE_OP3_COND (OR, 3, VC, 13)
24974 + AVR32_OPCODE_OP3_COND (OR, 3, QS, 14)
24975 + AVR32_OPCODE_OP3_COND (OR, 3, AL, 15)
24976 +
24977 + AVR32_OPCODE_OP3_COND (EOR, 4, EQ, 0)
24978 + AVR32_OPCODE_OP3_COND (EOR, 4, NE, 1)
24979 + AVR32_OPCODE_OP3_COND (EOR, 4, CC, 2)
24980 + AVR32_OPCODE_OP3_COND (EOR, 4, CS, 3)
24981 + AVR32_OPCODE_OP3_COND (EOR, 4, GE, 4)
24982 + AVR32_OPCODE_OP3_COND (EOR, 4, LT, 5)
24983 + AVR32_OPCODE_OP3_COND (EOR, 4, MI, 6)
24984 + AVR32_OPCODE_OP3_COND (EOR, 4, PL, 7)
24985 + AVR32_OPCODE_OP3_COND (EOR, 4, LS, 8)
24986 + AVR32_OPCODE_OP3_COND (EOR, 4, GT, 9)
24987 + AVR32_OPCODE_OP3_COND (EOR, 4, LE, 10)
24988 + AVR32_OPCODE_OP3_COND (EOR, 4, HI, 11)
24989 + AVR32_OPCODE_OP3_COND (EOR, 4, VS, 12)
24990 + AVR32_OPCODE_OP3_COND (EOR, 4, VC, 13)
24991 + AVR32_OPCODE_OP3_COND (EOR, 4, QS, 14)
24992 + AVR32_OPCODE_OP3_COND (EOR, 4, AL, 15)
24993 +
24994 +#define AVR32_OPCODE_LD_COND(op_name, op_field, cond_name, cond_field) \
24995 + { \
24996 + AVR32_OPC_ ## op_name ## cond_name , 4, \
24997 + 0xe1f00000 | (cond_field << 12) | (op_field << 9), 0xe1f0fe00, \
24998 + &avr32_syntax_table[AVR32_SYNTAX_ ## op_name ## cond_name ], \
24999 + BFD_RELOC_UNUSED, 3, -1, \
25000 + { \
25001 + &avr32_ifield_table[AVR32_IFIELD_RY], \
25002 + &avr32_ifield_table[AVR32_IFIELD_RX], \
25003 + &avr32_ifield_table[AVR32_IFIELD_K9E], \
25004 + }, \
25005 + },
25006 +
25007 +#define AVR32_OPCODE_ST_COND(op_name, op_field, cond_name, cond_field) \
25008 + { \
25009 + AVR32_OPC_ ## op_name ## cond_name , 4, \
25010 + 0xe1f00000 | (cond_field << 12) | (op_field << 9), 0xe1f0fe00, \
25011 + &avr32_syntax_table[AVR32_SYNTAX_ ## op_name ## cond_name ], \
25012 + BFD_RELOC_UNUSED, 3, -1, \
25013 + { \
25014 + &avr32_ifield_table[AVR32_IFIELD_RX], \
25015 + &avr32_ifield_table[AVR32_IFIELD_K9E], \
25016 + &avr32_ifield_table[AVR32_IFIELD_RY], \
25017 + }, \
25018 + },
25019 +
25020 + AVR32_OPCODE_LD_COND (LD_W, 0, EQ, 0)
25021 + AVR32_OPCODE_LD_COND (LD_W, 0, NE, 1)
25022 + AVR32_OPCODE_LD_COND (LD_W, 0, CC, 2)
25023 + AVR32_OPCODE_LD_COND (LD_W, 0, CS, 3)
25024 + AVR32_OPCODE_LD_COND (LD_W, 0, GE, 4)
25025 + AVR32_OPCODE_LD_COND (LD_W, 0, LT, 5)
25026 + AVR32_OPCODE_LD_COND (LD_W, 0, MI, 6)
25027 + AVR32_OPCODE_LD_COND (LD_W, 0, PL, 7)
25028 + AVR32_OPCODE_LD_COND (LD_W, 0, LS, 8)
25029 + AVR32_OPCODE_LD_COND (LD_W, 0, GT, 9)
25030 + AVR32_OPCODE_LD_COND (LD_W, 0, LE, 10)
25031 + AVR32_OPCODE_LD_COND (LD_W, 0, HI, 11)
25032 + AVR32_OPCODE_LD_COND (LD_W, 0, VS, 12)
25033 + AVR32_OPCODE_LD_COND (LD_W, 0, VC, 13)
25034 + AVR32_OPCODE_LD_COND (LD_W, 0, QS, 14)
25035 + AVR32_OPCODE_LD_COND (LD_W, 0, AL, 15)
25036 +
25037 + AVR32_OPCODE_LD_COND (LD_SH, 1, EQ, 0)
25038 + AVR32_OPCODE_LD_COND (LD_SH, 1, NE, 1)
25039 + AVR32_OPCODE_LD_COND (LD_SH, 1, CC, 2)
25040 + AVR32_OPCODE_LD_COND (LD_SH, 1, CS, 3)
25041 + AVR32_OPCODE_LD_COND (LD_SH, 1, GE, 4)
25042 + AVR32_OPCODE_LD_COND (LD_SH, 1, LT, 5)
25043 + AVR32_OPCODE_LD_COND (LD_SH, 1, MI, 6)
25044 + AVR32_OPCODE_LD_COND (LD_SH, 1, PL, 7)
25045 + AVR32_OPCODE_LD_COND (LD_SH, 1, LS, 8)
25046 + AVR32_OPCODE_LD_COND (LD_SH, 1, GT, 9)
25047 + AVR32_OPCODE_LD_COND (LD_SH, 1, LE, 10)
25048 + AVR32_OPCODE_LD_COND (LD_SH, 1, HI, 11)
25049 + AVR32_OPCODE_LD_COND (LD_SH, 1, VS, 12)
25050 + AVR32_OPCODE_LD_COND (LD_SH, 1, VC, 13)
25051 + AVR32_OPCODE_LD_COND (LD_SH, 1, QS, 14)
25052 + AVR32_OPCODE_LD_COND (LD_SH, 1, AL, 15)
25053 +
25054 + AVR32_OPCODE_LD_COND (LD_UH, 2, EQ, 0)
25055 + AVR32_OPCODE_LD_COND (LD_UH, 2, NE, 1)
25056 + AVR32_OPCODE_LD_COND (LD_UH, 2, CC, 2)
25057 + AVR32_OPCODE_LD_COND (LD_UH, 2, CS, 3)
25058 + AVR32_OPCODE_LD_COND (LD_UH, 2, GE, 4)
25059 + AVR32_OPCODE_LD_COND (LD_UH, 2, LT, 5)
25060 + AVR32_OPCODE_LD_COND (LD_UH, 2, MI, 6)
25061 + AVR32_OPCODE_LD_COND (LD_UH, 2, PL, 7)
25062 + AVR32_OPCODE_LD_COND (LD_SH, 2, LS, 8)
25063 + AVR32_OPCODE_LD_COND (LD_SH, 2, GT, 9)
25064 + AVR32_OPCODE_LD_COND (LD_SH, 2, LE, 10)
25065 + AVR32_OPCODE_LD_COND (LD_SH, 2, HI, 11)
25066 + AVR32_OPCODE_LD_COND (LD_SH, 2, VS, 12)
25067 + AVR32_OPCODE_LD_COND (LD_SH, 2, VC, 13)
25068 + AVR32_OPCODE_LD_COND (LD_SH, 2, QS, 14)
25069 + AVR32_OPCODE_LD_COND (LD_SH, 2, AL, 15)
25070 +
25071 + AVR32_OPCODE_LD_COND (LD_SB, 3, EQ, 0)
25072 + AVR32_OPCODE_LD_COND (LD_SB, 3, NE, 1)
25073 + AVR32_OPCODE_LD_COND (LD_SB, 3, CC, 2)
25074 + AVR32_OPCODE_LD_COND (LD_SB, 3, CS, 3)
25075 + AVR32_OPCODE_LD_COND (LD_SB, 3, GE, 4)
25076 + AVR32_OPCODE_LD_COND (LD_SB, 3, LT, 5)
25077 + AVR32_OPCODE_LD_COND (LD_SB, 3, MI, 6)
25078 + AVR32_OPCODE_LD_COND (LD_SB, 3, PL, 7)
25079 + AVR32_OPCODE_LD_COND (LD_SB, 3, LS, 8)
25080 + AVR32_OPCODE_LD_COND (LD_SB, 3, GT, 9)
25081 + AVR32_OPCODE_LD_COND (LD_SB, 3, LE, 10)
25082 + AVR32_OPCODE_LD_COND (LD_SB, 3, HI, 11)
25083 + AVR32_OPCODE_LD_COND (LD_SB, 3, VS, 12)
25084 + AVR32_OPCODE_LD_COND (LD_SB, 3, VC, 13)
25085 + AVR32_OPCODE_LD_COND (LD_SB, 3, QS, 14)
25086 + AVR32_OPCODE_LD_COND (LD_SB, 3, AL, 15)
25087 +
25088 + AVR32_OPCODE_LD_COND (LD_UB, 4, EQ, 0)
25089 + AVR32_OPCODE_LD_COND (LD_UB, 4, NE, 1)
25090 + AVR32_OPCODE_LD_COND (LD_UB, 4, CC, 2)
25091 + AVR32_OPCODE_LD_COND (LD_UB, 4, CS, 3)
25092 + AVR32_OPCODE_LD_COND (LD_UB, 4, GE, 4)
25093 + AVR32_OPCODE_LD_COND (LD_UB, 4, LT, 5)
25094 + AVR32_OPCODE_LD_COND (LD_UB, 4, MI, 6)
25095 + AVR32_OPCODE_LD_COND (LD_UB, 4, PL, 7)
25096 + AVR32_OPCODE_LD_COND (LD_UB, 4, LS, 8)
25097 + AVR32_OPCODE_LD_COND (LD_UB, 4, GT, 9)
25098 + AVR32_OPCODE_LD_COND (LD_UB, 4, LE, 10)
25099 + AVR32_OPCODE_LD_COND (LD_UB, 4, HI, 11)
25100 + AVR32_OPCODE_LD_COND (LD_UB, 4, VS, 12)
25101 + AVR32_OPCODE_LD_COND (LD_UB, 4, VC, 13)
25102 + AVR32_OPCODE_LD_COND (LD_UB, 4, QS, 14)
25103 + AVR32_OPCODE_LD_COND (LD_UB, 4, AL, 15)
25104 +
25105 + AVR32_OPCODE_ST_COND (ST_W, 5, EQ, 0)
25106 + AVR32_OPCODE_ST_COND (ST_W, 5, NE, 1)
25107 + AVR32_OPCODE_ST_COND (ST_W, 5, CC, 2)
25108 + AVR32_OPCODE_ST_COND (ST_W, 5, CS, 3)
25109 + AVR32_OPCODE_ST_COND (ST_W, 5, GE, 4)
25110 + AVR32_OPCODE_ST_COND (ST_W, 5, LT, 5)
25111 + AVR32_OPCODE_ST_COND (ST_W, 5, MI, 6)
25112 + AVR32_OPCODE_ST_COND (ST_W, 5, PL, 7)
25113 + AVR32_OPCODE_ST_COND (ST_W, 5, LS, 8)
25114 + AVR32_OPCODE_ST_COND (ST_W, 5, GT, 9)
25115 + AVR32_OPCODE_ST_COND (ST_W, 5, LE, 10)
25116 + AVR32_OPCODE_ST_COND (ST_W, 5, HI, 11)
25117 + AVR32_OPCODE_ST_COND (ST_W, 5, VS, 12)
25118 + AVR32_OPCODE_ST_COND (ST_W, 5, VC, 13)
25119 + AVR32_OPCODE_ST_COND (ST_W, 5, QS, 14)
25120 + AVR32_OPCODE_ST_COND (ST_W, 5, AL, 15)
25121 +
25122 + AVR32_OPCODE_ST_COND (ST_H, 6, EQ, 0)
25123 + AVR32_OPCODE_ST_COND (ST_H, 6, NE, 1)
25124 + AVR32_OPCODE_ST_COND (ST_H, 6, CC, 2)
25125 + AVR32_OPCODE_ST_COND (ST_H, 6, CS, 3)
25126 + AVR32_OPCODE_ST_COND (ST_H, 6, GE, 4)
25127 + AVR32_OPCODE_ST_COND (ST_H, 6, LT, 5)
25128 + AVR32_OPCODE_ST_COND (ST_H, 6, MI, 6)
25129 + AVR32_OPCODE_ST_COND (ST_H, 6, PL, 7)
25130 + AVR32_OPCODE_ST_COND (ST_H, 6, LS, 8)
25131 + AVR32_OPCODE_ST_COND (ST_H, 6, GT, 9)
25132 + AVR32_OPCODE_ST_COND (ST_H, 6, LE, 10)
25133 + AVR32_OPCODE_ST_COND (ST_H, 6, HI, 11)
25134 + AVR32_OPCODE_ST_COND (ST_H, 6, VS, 12)
25135 + AVR32_OPCODE_ST_COND (ST_H, 6, VC, 13)
25136 + AVR32_OPCODE_ST_COND (ST_H, 6, QS, 14)
25137 + AVR32_OPCODE_ST_COND (ST_H, 6, AL, 15)
25138 +
25139 + AVR32_OPCODE_ST_COND (ST_B, 7, EQ, 0)
25140 + AVR32_OPCODE_ST_COND (ST_B, 7, NE, 1)
25141 + AVR32_OPCODE_ST_COND (ST_B, 7, CC, 2)
25142 + AVR32_OPCODE_ST_COND (ST_B, 7, CS, 3)
25143 + AVR32_OPCODE_ST_COND (ST_B, 7, GE, 4)
25144 + AVR32_OPCODE_ST_COND (ST_B, 7, LT, 5)
25145 + AVR32_OPCODE_ST_COND (ST_B, 7, MI, 6)
25146 + AVR32_OPCODE_ST_COND (ST_B, 7, PL, 7)
25147 + AVR32_OPCODE_ST_COND (ST_B, 7, LS, 8)
25148 + AVR32_OPCODE_ST_COND (ST_B, 7, GT, 9)
25149 + AVR32_OPCODE_ST_COND (ST_B, 7, LE, 10)
25150 + AVR32_OPCODE_ST_COND (ST_B, 7, HI, 11)
25151 + AVR32_OPCODE_ST_COND (ST_B, 7, VS, 12)
25152 + AVR32_OPCODE_ST_COND (ST_B, 7, VC, 13)
25153 + AVR32_OPCODE_ST_COND (ST_B, 7, QS, 14)
25154 + AVR32_OPCODE_ST_COND (ST_B, 7, AL, 15)
25155 +
25156 + {
25157 + AVR32_OPC_MOVH, 4, 0xfc100000, 0xfff00000,
25158 + &avr32_syntax_table[AVR32_SYNTAX_MOVH],
25159 + BFD_RELOC_AVR32_16U, 2, 1,
25160 + {
25161 + &avr32_ifield_table[AVR32_IFIELD_RY],
25162 + &avr32_ifield_table[AVR32_IFIELD_K16],
25163 + },
25164 + },
25165 +
25166 + };
25167 +
25168 +#define FPALIAS_DXY(name, opcode) \
25169 + { \
25170 + AVR32_ALIAS_##name##_S, \
25171 + &avr32_opc_table[AVR32_OPC_COP], \
25172 + { \
25173 + { 0, 0 }, \
25174 + { 1, 0 }, { 1, 1 }, { 1, 2 }, \
25175 + { 0, opcode }, \
25176 + }, \
25177 + }, { \
25178 + AVR32_ALIAS_##name##_D, \
25179 + &avr32_opc_table[AVR32_OPC_COP], \
25180 + { \
25181 + { 0, 0 }, \
25182 + { 1, 0 }, { 1, 1 }, { 1, 2 }, \
25183 + { 0, (opcode) | 0x40 }, \
25184 + }, \
25185 + }
25186 +#define FPALIAS_DX(name, opcode) \
25187 + { \
25188 + AVR32_ALIAS_##name##_S, \
25189 + &avr32_opc_table[AVR32_OPC_COP], \
25190 + { \
25191 + { 0, 0 }, \
25192 + { 1, 0 }, { 1, 1 }, { 0, 0 }, \
25193 + { 0, opcode }, \
25194 + }, \
25195 + }, { \
25196 + AVR32_ALIAS_##name##_D, \
25197 + &avr32_opc_table[AVR32_OPC_COP], \
25198 + { \
25199 + { 0, 0 }, \
25200 + { 1, 0 }, { 1, 1 }, { 0, 0 }, \
25201 + { 0, (opcode) | 0x40 }, \
25202 + }, \
25203 + }
25204 +#define FPALIAS_XY(name, opcode) \
25205 + { \
25206 + AVR32_ALIAS_##name##_S, \
25207 + &avr32_opc_table[AVR32_OPC_COP], \
25208 + { \
25209 + { 0, 0 }, \
25210 + { 0, 0 }, { 1, 0 }, { 1, 1 }, \
25211 + { 0, opcode }, \
25212 + }, \
25213 + }, { \
25214 + AVR32_ALIAS_##name##_D, \
25215 + &avr32_opc_table[AVR32_OPC_COP], \
25216 + { \
25217 + { 0, 0 }, \
25218 + { 0, 0 }, { 1, 0 }, { 1, 1 }, \
25219 + { 0, (opcode) | 0x40 }, \
25220 + }, \
25221 + }
25222 +
25223 +const struct avr32_alias avr32_alias_table[] =
25224 + {
25225 + FPALIAS_DXY(FMAC, 0x00),
25226 + FPALIAS_DXY(FNMAC, 0x01),
25227 + FPALIAS_DXY(FMSC, 0x02),
25228 + FPALIAS_DXY(FNMSC, 0x03),
25229 + FPALIAS_DXY(FADD, 0x04),
25230 + FPALIAS_DXY(FSUB, 0x05),
25231 + FPALIAS_DXY(FMUL, 0x06),
25232 + FPALIAS_DXY(FNMUL, 0x07),
25233 + FPALIAS_DX(FNEG, 0x08),
25234 + FPALIAS_DX(FABS, 0x09),
25235 + FPALIAS_XY(FCMP, 0x0d),
25236 + FPALIAS_DX(FMOV1, 0x0a),
25237 + {
25238 + AVR32_ALIAS_FMOV2_S,
25239 + &avr32_opc_table[AVR32_OPC_MVCR_W],
25240 + { { 0, 0 }, { 1, 0 }, { 1, 1 }, },
25241 + },
25242 + {
25243 + AVR32_ALIAS_FMOV2_D,
25244 + &avr32_opc_table[AVR32_OPC_MVCR_D],
25245 + { { 0, 0 }, { 1, 0 }, { 1, 1 }, },
25246 + },
25247 + {
25248 + AVR32_ALIAS_FMOV3_S,
25249 + &avr32_opc_table[AVR32_OPC_MVRC_W],
25250 + { { 0, 0 }, { 1, 0 }, { 1, 1 }, },
25251 + },
25252 + {
25253 + AVR32_ALIAS_FMOV3_D,
25254 + &avr32_opc_table[AVR32_OPC_MVRC_D],
25255 + { { 0, 0 }, { 1, 0 }, { 1, 1 }, },
25256 + },
25257 + {
25258 + AVR32_ALIAS_FCASTS_D,
25259 + &avr32_opc_table[AVR32_OPC_COP],
25260 + {
25261 + { 0, 0 },
25262 + { 1, 0 }, { 1, 1 }, { 0, 0 },
25263 + { 0, 0x0f },
25264 + },
25265 + },
25266 + {
25267 + AVR32_ALIAS_FCASTD_S,
25268 + &avr32_opc_table[AVR32_OPC_COP],
25269 + {
25270 + { 0, 0 },
25271 + { 1, 0 }, { 1, 1 }, { 0, 0 },
25272 + { 0, 0x10 },
25273 + },
25274 + },
25275 + {
25276 + AVR32_ALIAS_PICOSVMAC0,
25277 + &avr32_opc_table[AVR32_OPC_COP],
25278 + {
25279 + { 0, PICO_CPNO },
25280 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25281 + { 0, 0x0c },
25282 + },
25283 + },
25284 + {
25285 + AVR32_ALIAS_PICOSVMAC1,
25286 + &avr32_opc_table[AVR32_OPC_COP],
25287 + {
25288 + { 0, PICO_CPNO },
25289 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25290 + { 0, 0x0d },
25291 + },
25292 + },
25293 + {
25294 + AVR32_ALIAS_PICOSVMAC2,
25295 + &avr32_opc_table[AVR32_OPC_COP],
25296 + {
25297 + { 0, PICO_CPNO },
25298 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25299 + { 0, 0x0e },
25300 + },
25301 + },
25302 + {
25303 + AVR32_ALIAS_PICOSVMAC3,
25304 + &avr32_opc_table[AVR32_OPC_COP],
25305 + {
25306 + { 0, PICO_CPNO },
25307 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25308 + { 0, 0x0f },
25309 + },
25310 + },
25311 + {
25312 + AVR32_ALIAS_PICOSVMUL0,
25313 + &avr32_opc_table[AVR32_OPC_COP],
25314 + {
25315 + { 0, PICO_CPNO },
25316 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25317 + { 0, 0x08 },
25318 + },
25319 + },
25320 + {
25321 + AVR32_ALIAS_PICOSVMUL1,
25322 + &avr32_opc_table[AVR32_OPC_COP],
25323 + {
25324 + { 0, PICO_CPNO },
25325 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25326 + { 0, 0x09 },
25327 + },
25328 + },
25329 + {
25330 + AVR32_ALIAS_PICOSVMUL2,
25331 + &avr32_opc_table[AVR32_OPC_COP],
25332 + {
25333 + { 0, PICO_CPNO },
25334 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25335 + { 0, 0x0a },
25336 + },
25337 + },
25338 + {
25339 + AVR32_ALIAS_PICOSVMUL3,
25340 + &avr32_opc_table[AVR32_OPC_COP],
25341 + {
25342 + { 0, PICO_CPNO },
25343 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25344 + { 0, 0x0b },
25345 + },
25346 + },
25347 + {
25348 + AVR32_ALIAS_PICOVMAC0,
25349 + &avr32_opc_table[AVR32_OPC_COP],
25350 + {
25351 + { 0, PICO_CPNO },
25352 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25353 + { 0, 0x04 },
25354 + },
25355 + },
25356 + {
25357 + AVR32_ALIAS_PICOVMAC1,
25358 + &avr32_opc_table[AVR32_OPC_COP],
25359 + {
25360 + { 0, PICO_CPNO },
25361 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25362 + { 0, 0x05 },
25363 + },
25364 + },
25365 + {
25366 + AVR32_ALIAS_PICOVMAC2,
25367 + &avr32_opc_table[AVR32_OPC_COP],
25368 + {
25369 + { 0, PICO_CPNO },
25370 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25371 + { 0, 0x06 },
25372 + },
25373 + },
25374 + {
25375 + AVR32_ALIAS_PICOVMAC3,
25376 + &avr32_opc_table[AVR32_OPC_COP],
25377 + {
25378 + { 0, PICO_CPNO },
25379 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25380 + { 0, 0x07 },
25381 + },
25382 + },
25383 + {
25384 + AVR32_ALIAS_PICOVMUL0,
25385 + &avr32_opc_table[AVR32_OPC_COP],
25386 + {
25387 + { 0, PICO_CPNO },
25388 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25389 + { 0, 0x00 },
25390 + },
25391 + },
25392 + {
25393 + AVR32_ALIAS_PICOVMUL1,
25394 + &avr32_opc_table[AVR32_OPC_COP],
25395 + {
25396 + { 0, PICO_CPNO },
25397 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25398 + { 0, 0x01 },
25399 + },
25400 + },
25401 + {
25402 + AVR32_ALIAS_PICOVMUL2,
25403 + &avr32_opc_table[AVR32_OPC_COP],
25404 + {
25405 + { 0, PICO_CPNO },
25406 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25407 + { 0, 0x02 },
25408 + },
25409 + },
25410 + {
25411 + AVR32_ALIAS_PICOVMUL3,
25412 + &avr32_opc_table[AVR32_OPC_COP],
25413 + {
25414 + { 0, PICO_CPNO },
25415 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25416 + { 0, 0x03 },
25417 + },
25418 + },
25419 + {
25420 + AVR32_ALIAS_PICOLD_D1,
25421 + &avr32_opc_table[AVR32_OPC_LDC_D1],
25422 + {
25423 + { 0, PICO_CPNO },
25424 + { 1, 0 }, { 1, 1 },
25425 + },
25426 + },
25427 + {
25428 + AVR32_ALIAS_PICOLD_D2,
25429 + &avr32_opc_table[AVR32_OPC_LDC_D2],
25430 + {
25431 + { 0, PICO_CPNO },
25432 + { 1, 0 }, { 1, 1 },
25433 + },
25434 + },
25435 + {
25436 + AVR32_ALIAS_PICOLD_D3,
25437 + &avr32_opc_table[AVR32_OPC_LDC_D3],
25438 + {
25439 + { 0, PICO_CPNO },
25440 + { 1, 0 }, { 1, 1 }, { 1, 2 }, { 1, 3 },
25441 + },
25442 + },
25443 + {
25444 + AVR32_ALIAS_PICOLD_W1,
25445 + &avr32_opc_table[AVR32_OPC_LDC_W1],
25446 + {
25447 + { 0, PICO_CPNO },
25448 + { 1, 0 }, { 1, 1 },
25449 + },
25450 + },
25451 + {
25452 + AVR32_ALIAS_PICOLD_W2,
25453 + &avr32_opc_table[AVR32_OPC_LDC_W2],
25454 + {
25455 + { 0, PICO_CPNO },
25456 + { 1, 0 }, { 1, 1 },
25457 + },
25458 + },
25459 + {
25460 + AVR32_ALIAS_PICOLD_W3,
25461 + &avr32_opc_table[AVR32_OPC_LDC_W3],
25462 + {
25463 + { 0, PICO_CPNO },
25464 + { 1, 0 }, { 1, 1 }, { 1, 2 }, { 1, 3 },
25465 + },
25466 + },
25467 + {
25468 + AVR32_ALIAS_PICOLDM_D,
25469 + &avr32_opc_table[AVR32_OPC_LDCM_D],
25470 + {
25471 + { 0, PICO_CPNO },
25472 + { 1, 0 }, { 1, 1 },
25473 + },
25474 + },
25475 + {
25476 + AVR32_ALIAS_PICOLDM_D_PU,
25477 + &avr32_opc_table[AVR32_OPC_LDCM_D_PU],
25478 + {
25479 + { 0, PICO_CPNO },
25480 + { 1, 0 }, { 1, 1 },
25481 + },
25482 + },
25483 + {
25484 + AVR32_ALIAS_PICOLDM_W,
25485 + &avr32_opc_table[AVR32_OPC_LDCM_W],
25486 + {
25487 + { 0, PICO_CPNO },
25488 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25489 + },
25490 + },
25491 + {
25492 + AVR32_ALIAS_PICOLDM_W_PU,
25493 + &avr32_opc_table[AVR32_OPC_LDCM_W_PU],
25494 + {
25495 + { 0, PICO_CPNO },
25496 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25497 + },
25498 + },
25499 + {
25500 + AVR32_ALIAS_PICOMV_D1,
25501 + &avr32_opc_table[AVR32_OPC_MVCR_D],
25502 + {
25503 + { 0, PICO_CPNO },
25504 + { 1, 0 }, { 1, 1 },
25505 + },
25506 + },
25507 + {
25508 + AVR32_ALIAS_PICOMV_D2,
25509 + &avr32_opc_table[AVR32_OPC_MVRC_D],
25510 + {
25511 + { 0, PICO_CPNO },
25512 + { 1, 0 }, { 1, 1 },
25513 + },
25514 + },
25515 + {
25516 + AVR32_ALIAS_PICOMV_W1,
25517 + &avr32_opc_table[AVR32_OPC_MVCR_W],
25518 + {
25519 + { 0, PICO_CPNO },
25520 + { 1, 0 }, { 1, 1 },
25521 + },
25522 + },
25523 + {
25524 + AVR32_ALIAS_PICOMV_W2,
25525 + &avr32_opc_table[AVR32_OPC_MVRC_W],
25526 + {
25527 + { 0, PICO_CPNO },
25528 + { 1, 0 }, { 1, 1 },
25529 + },
25530 + },
25531 + {
25532 + AVR32_ALIAS_PICOST_D1,
25533 + &avr32_opc_table[AVR32_OPC_STC_D1],
25534 + {
25535 + { 0, PICO_CPNO },
25536 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25537 + },
25538 + },
25539 + {
25540 + AVR32_ALIAS_PICOST_D2,
25541 + &avr32_opc_table[AVR32_OPC_STC_D2],
25542 + {
25543 + { 0, PICO_CPNO },
25544 + { 1, 0 }, { 1, 1 },
25545 + },
25546 + },
25547 + {
25548 + AVR32_ALIAS_PICOST_D3,
25549 + &avr32_opc_table[AVR32_OPC_STC_D3],
25550 + {
25551 + { 0, PICO_CPNO },
25552 + { 1, 0 }, { 1, 1 }, { 1, 2 }, { 1, 3 },
25553 + },
25554 + },
25555 + {
25556 + AVR32_ALIAS_PICOST_W1,
25557 + &avr32_opc_table[AVR32_OPC_STC_W1],
25558 + {
25559 + { 0, PICO_CPNO },
25560 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25561 + },
25562 + },
25563 + {
25564 + AVR32_ALIAS_PICOST_W2,
25565 + &avr32_opc_table[AVR32_OPC_STC_W2],
25566 + {
25567 + { 0, PICO_CPNO },
25568 + { 1, 0 }, { 1, 1 },
25569 + },
25570 + },
25571 + {
25572 + AVR32_ALIAS_PICOST_W3,
25573 + &avr32_opc_table[AVR32_OPC_STC_W3],
25574 + {
25575 + { 0, PICO_CPNO },
25576 + { 1, 0 }, { 1, 1 }, { 1, 2 }, { 1, 3 },
25577 + },
25578 + },
25579 + {
25580 + AVR32_ALIAS_PICOSTM_D,
25581 + &avr32_opc_table[AVR32_OPC_STCM_D],
25582 + {
25583 + { 0, PICO_CPNO },
25584 + { 1, 0 }, { 1, 1 },
25585 + },
25586 + },
25587 + {
25588 + AVR32_ALIAS_PICOSTM_D_PU,
25589 + &avr32_opc_table[AVR32_OPC_STCM_D_PU],
25590 + {
25591 + { 0, PICO_CPNO },
25592 + { 1, 0 }, { 1, 1 },
25593 + },
25594 + },
25595 + {
25596 + AVR32_ALIAS_PICOSTM_W,
25597 + &avr32_opc_table[AVR32_OPC_STCM_W],
25598 + {
25599 + { 0, PICO_CPNO },
25600 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25601 + },
25602 + },
25603 + {
25604 + AVR32_ALIAS_PICOSTM_W_PU,
25605 + &avr32_opc_table[AVR32_OPC_STCM_W_PU],
25606 + {
25607 + { 0, PICO_CPNO },
25608 + { 1, 0 }, { 1, 1 }, { 1, 2 },
25609 + },
25610 + },
25611 + };
25612 +
25613 +
25614 +#define SYNTAX_NORMAL0(id, mne, opc, arch) \
25615 + { \
25616 + AVR32_SYNTAX_##id, arch, \
25617 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25618 + AVR32_PARSER_NORMAL, \
25619 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25620 + NULL, 0, { } \
25621 + }
25622 +#define SYNTAX_NORMAL1(id, mne, opc, op0, arch) \
25623 + { \
25624 + AVR32_SYNTAX_##id, arch, \
25625 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25626 + AVR32_PARSER_NORMAL, \
25627 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25628 + NULL, 1, \
25629 + { \
25630 + AVR32_OPERAND_##op0, \
25631 + } \
25632 + }
25633 +#define SYNTAX_NORMALM1(id, mne, opc, op0, arch) \
25634 + { \
25635 + AVR32_SYNTAX_##id, arch, \
25636 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25637 + AVR32_PARSER_NORMAL, \
25638 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25639 + NULL, -1, \
25640 + { \
25641 + AVR32_OPERAND_##op0, \
25642 + } \
25643 + }
25644 +#define SYNTAX_NORMAL2(id, mne, opc, op0, op1, arch) \
25645 + { \
25646 + AVR32_SYNTAX_##id, arch, \
25647 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25648 + AVR32_PARSER_NORMAL, \
25649 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25650 + NULL, 2, \
25651 + { \
25652 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25653 + } \
25654 + }
25655 +#define SYNTAX_NORMALM2(id, mne, opc, op0, op1, arch) \
25656 + { \
25657 + AVR32_SYNTAX_##id, arch, \
25658 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25659 + AVR32_PARSER_NORMAL, \
25660 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25661 + NULL, -2, \
25662 + { \
25663 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25664 + } \
25665 + }
25666 +#define SYNTAX_NORMAL3(id, mne, opc, op0, op1, op2, arch) \
25667 + { \
25668 + AVR32_SYNTAX_##id, arch, \
25669 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25670 + AVR32_PARSER_NORMAL, \
25671 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25672 + NULL, 3, \
25673 + { \
25674 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25675 + AVR32_OPERAND_##op2, \
25676 + } \
25677 + }
25678 +#define SYNTAX_NORMALM3(id, mne, opc, op0, op1, op2, arch) \
25679 + { \
25680 + AVR32_SYNTAX_##id, arch, \
25681 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25682 + AVR32_PARSER_NORMAL, \
25683 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25684 + NULL, -3, \
25685 + { \
25686 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25687 + AVR32_OPERAND_##op2, \
25688 + } \
25689 + }
25690 +#define SYNTAX_NORMAL4(id, mne, opc, op0, op1, op2, op3, arch)\
25691 + { \
25692 + AVR32_SYNTAX_##id, arch, \
25693 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25694 + AVR32_PARSER_NORMAL, \
25695 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25696 + NULL, 4, \
25697 + { \
25698 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25699 + AVR32_OPERAND_##op2, AVR32_OPERAND_##op3, \
25700 + } \
25701 + }
25702 +#define SYNTAX_NORMAL5(id, mne, opc, op0, op1, op2, op3, op4, arch) \
25703 + { \
25704 + AVR32_SYNTAX_##id, arch, \
25705 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25706 + AVR32_PARSER_NORMAL, \
25707 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25708 + NULL, 5, \
25709 + { \
25710 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25711 + AVR32_OPERAND_##op2, AVR32_OPERAND_##op3, \
25712 + AVR32_OPERAND_##op4, \
25713 + } \
25714 + }
25715 +
25716 +#define SYNTAX_NORMAL_C1(id, mne, opc, nxt, op0, arch) \
25717 + { \
25718 + AVR32_SYNTAX_##id, arch, \
25719 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25720 + AVR32_PARSER_NORMAL, \
25721 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25722 + &avr32_syntax_table[AVR32_SYNTAX_##nxt], 1, \
25723 + { \
25724 + AVR32_OPERAND_##op0, \
25725 + } \
25726 + }
25727 +#define SYNTAX_NORMAL_CM1(id, mne, opc, nxt, op0, arch) \
25728 + { \
25729 + AVR32_SYNTAX_##id, arch, \
25730 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25731 + AVR32_PARSER_NORMAL, \
25732 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25733 + &avr32_syntax_table[AVR32_SYNTAX_##nxt], -1, \
25734 + { \
25735 + AVR32_OPERAND_##op0, \
25736 + } \
25737 + }
25738 +#define SYNTAX_NORMAL_C2(id, mne, opc, nxt, op0, op1, arch) \
25739 + { \
25740 + AVR32_SYNTAX_##id, arch, \
25741 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25742 + AVR32_PARSER_NORMAL, \
25743 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25744 + &avr32_syntax_table[AVR32_SYNTAX_##nxt], 2, \
25745 + { \
25746 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25747 + } \
25748 + }
25749 +#define SYNTAX_NORMAL_CM2(id, mne, opc, nxt, op0, op1, arch) \
25750 + { \
25751 + AVR32_SYNTAX_##id, arch, \
25752 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25753 + AVR32_PARSER_NORMAL, \
25754 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25755 + &avr32_syntax_table[AVR32_SYNTAX_##nxt], -2, \
25756 + { \
25757 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25758 + } \
25759 + }
25760 +#define SYNTAX_NORMAL_C3(id, mne, opc, nxt, op0, op1, op2, arch) \
25761 + { \
25762 + AVR32_SYNTAX_##id, arch, \
25763 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25764 + AVR32_PARSER_NORMAL, \
25765 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25766 + &avr32_syntax_table[AVR32_SYNTAX_##nxt], 3, \
25767 + { \
25768 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25769 + AVR32_OPERAND_##op2, \
25770 + } \
25771 + }
25772 +#define SYNTAX_NORMAL_CM3(id, mne, opc, nxt, op0, op1, op2, arch) \
25773 + { \
25774 + AVR32_SYNTAX_##id, arch, \
25775 + &avr32_mnemonic_table[AVR32_MNEMONIC_##mne], \
25776 + AVR32_PARSER_NORMAL, \
25777 + { &avr32_opc_table[AVR32_OPC_##opc], }, \
25778 + &avr32_syntax_table[AVR32_SYNTAX_##nxt], -3, \
25779 + { \
25780 + AVR32_OPERAND_##op0, AVR32_OPERAND_##op1, \
25781 + AVR32_OPERAND_##op2, \
25782 + } \
25783 + }
25784 +
25785 +#define SYNTAX_FP(name, nr_ops) \
25786 + { \
25787 + AVR32_SYNTAX_##name##_S, \
25788 + AVR32_FP, NULL, AVR32_PARSER_ALIAS, \
25789 + { .alias = &avr32_alias_table[AVR32_ALIAS_##name##_S] }, \
25790 + NULL, nr_ops, \
25791 + { \
25792 + AVR32_OPERAND_FPREG_S, \
25793 + AVR32_OPERAND_FPREG_S, \
25794 + AVR32_OPERAND_FPREG_S, \
25795 + }, \
25796 + }, \
25797 + { \
25798 + AVR32_SYNTAX_##name##_D, \
25799 + AVR32_FP, NULL, AVR32_PARSER_ALIAS, \
25800 + { .alias = &avr32_alias_table[AVR32_ALIAS_##name##_D] }, \
25801 + NULL, nr_ops, \
25802 + { \
25803 + AVR32_OPERAND_FPREG_D, \
25804 + AVR32_OPERAND_FPREG_D, \
25805 + AVR32_OPERAND_FPREG_D, \
25806 + }, \
25807 + }
25808 +
25809 +const struct avr32_syntax avr32_syntax_table[] =
25810 + {
25811 + SYNTAX_NORMAL1(ABS, ABS, ABS, INTREG, AVR32_V1),
25812 + SYNTAX_NORMAL1(ACALL, ACALL, ACALL, UNSIGNED_CONST_W, AVR32_V1),
25813 + SYNTAX_NORMAL1(ACR, ACR, ACR, INTREG,AVR32_V1),
25814 + SYNTAX_NORMAL3(ADC, ADC, ADC, INTREG, INTREG, INTREG, AVR32_V1),
25815 + SYNTAX_NORMAL_C2(ADD1, ADD, ADD1, ADD2, INTREG, INTREG, AVR32_V1),
25816 + SYNTAX_NORMAL3(ADD2, ADD, ADD2, INTREG, INTREG, INTREG_LSL, AVR32_V1),
25817 + SYNTAX_NORMAL3(ADDABS, ADDABS, ADDABS, INTREG, INTREG, INTREG, AVR32_V1),
25818 + SYNTAX_NORMAL3(ADDHH_W, ADDHH_W, ADDHH_W, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
25819 + SYNTAX_NORMAL_C2(AND1, AND, AND1, AND2, INTREG, INTREG, AVR32_V1),
25820 + SYNTAX_NORMAL_C3(AND2, AND, AND2, AND3, INTREG, INTREG, INTREG_LSL, AVR32_V1),
25821 + SYNTAX_NORMAL3(AND3, AND, AND3, INTREG, INTREG, INTREG_LSR, AVR32_V1),
25822 + SYNTAX_NORMAL_C2(ANDH, ANDH, ANDH, ANDH_COH, INTREG, UNSIGNED_CONST, AVR32_V1),
25823 + SYNTAX_NORMAL3(ANDH_COH, ANDH, ANDH_COH, INTREG, UNSIGNED_CONST, COH, AVR32_V1),
25824 + SYNTAX_NORMAL_C2(ANDL, ANDL, ANDL, ANDL_COH, INTREG, UNSIGNED_CONST, AVR32_V1),
25825 + SYNTAX_NORMAL3(ANDL_COH, ANDL, ANDL_COH, INTREG, UNSIGNED_CONST, COH, AVR32_V1),
25826 + SYNTAX_NORMAL2(ANDN, ANDN, ANDN, INTREG, INTREG, AVR32_V1),
25827 + SYNTAX_NORMAL_C3(ASR1, ASR, ASR1, ASR3, INTREG, INTREG, INTREG, AVR32_V1),
25828 + SYNTAX_NORMAL_C3(ASR3, ASR, ASR3, ASR2, INTREG, INTREG, UNSIGNED_NUMBER, AVR32_V1),
25829 + SYNTAX_NORMAL2(ASR2, ASR, ASR2, INTREG, UNSIGNED_NUMBER, AVR32_V1),
25830 + SYNTAX_NORMAL4(BFEXTS, BFEXTS, BFEXTS, INTREG, INTREG, UNSIGNED_NUMBER, UNSIGNED_NUMBER, AVR32_V1),
25831 + SYNTAX_NORMAL4(BFEXTU, BFEXTU, BFEXTU, INTREG, INTREG, UNSIGNED_NUMBER, UNSIGNED_NUMBER, AVR32_V1),
25832 + SYNTAX_NORMAL4(BFINS, BFINS, BFINS, INTREG, INTREG, UNSIGNED_NUMBER, UNSIGNED_NUMBER, AVR32_V1),
25833 + SYNTAX_NORMAL2(BLD, BLD, BLD, INTREG, UNSIGNED_NUMBER, AVR32_V1),
25834 + SYNTAX_NORMAL_C1(BREQ1, BREQ, BREQ1, BREQ2, JMPLABEL, AVR32_V1),
25835 + SYNTAX_NORMAL_C1(BRNE1, BRNE, BRNE1, BRNE2, JMPLABEL, AVR32_V1),
25836 + SYNTAX_NORMAL_C1(BRCC1, BRCC, BRCC1, BRCC2, JMPLABEL, AVR32_V1),
25837 + SYNTAX_NORMAL_C1(BRCS1, BRCS, BRCS1, BRCS2, JMPLABEL, AVR32_V1),
25838 + SYNTAX_NORMAL_C1(BRGE1, BRGE, BRGE1, BRGE2, JMPLABEL, AVR32_V1),
25839 + SYNTAX_NORMAL_C1(BRLT1, BRLT, BRLT1, BRLT2, JMPLABEL, AVR32_V1),
25840 + SYNTAX_NORMAL_C1(BRMI1, BRMI, BRMI1, BRMI2, JMPLABEL, AVR32_V1),
25841 + SYNTAX_NORMAL_C1(BRPL1, BRPL, BRPL1, BRPL2, JMPLABEL, AVR32_V1),
25842 + SYNTAX_NORMAL_C1(BRHS1, BRHS, BRCC1, BRHS2, JMPLABEL, AVR32_V1),
25843 + SYNTAX_NORMAL_C1(BRLO1, BRLO, BRCS1, BRLO2, JMPLABEL, AVR32_V1),
25844 + SYNTAX_NORMAL1(BREQ2, BREQ, BREQ2, JMPLABEL, AVR32_V1),
25845 + SYNTAX_NORMAL1(BRNE2, BRNE, BRNE2, JMPLABEL, AVR32_V1),
25846 + SYNTAX_NORMAL1(BRCC2, BRCC, BRCC2, JMPLABEL, AVR32_V1),
25847 + SYNTAX_NORMAL1(BRCS2, BRCS, BRCS2, JMPLABEL, AVR32_V1),
25848 + SYNTAX_NORMAL1(BRGE2, BRGE, BRGE2, JMPLABEL, AVR32_V1),
25849 + SYNTAX_NORMAL1(BRLT2, BRLT, BRLT2, JMPLABEL, AVR32_V1),
25850 + SYNTAX_NORMAL1(BRMI2, BRMI, BRMI2, JMPLABEL, AVR32_V1),
25851 + SYNTAX_NORMAL1(BRPL2, BRPL, BRPL2, JMPLABEL, AVR32_V1),
25852 + SYNTAX_NORMAL1(BRLS, BRLS, BRLS, JMPLABEL, AVR32_V1),
25853 + SYNTAX_NORMAL1(BRGT, BRGT, BRGT, JMPLABEL, AVR32_V1),
25854 + SYNTAX_NORMAL1(BRLE, BRLE, BRLE, JMPLABEL, AVR32_V1),
25855 + SYNTAX_NORMAL1(BRHI, BRHI, BRHI, JMPLABEL, AVR32_V1),
25856 + SYNTAX_NORMAL1(BRVS, BRVS, BRVS, JMPLABEL, AVR32_V1),
25857 + SYNTAX_NORMAL1(BRVC, BRVC, BRVC, JMPLABEL, AVR32_V1),
25858 + SYNTAX_NORMAL1(BRQS, BRQS, BRQS, JMPLABEL, AVR32_V1),
25859 + SYNTAX_NORMAL1(BRAL, BRAL, BRAL, JMPLABEL, AVR32_V1),
25860 + SYNTAX_NORMAL1(BRHS2, BRHS, BRCC2, JMPLABEL, AVR32_V1),
25861 + SYNTAX_NORMAL1(BRLO2, BRLO, BRCS2, JMPLABEL, AVR32_V1),
25862 + SYNTAX_NORMAL0(BREAKPOINT, BREAKPOINT, BREAKPOINT, AVR32_V1),
25863 + SYNTAX_NORMAL1(BREV, BREV, BREV, INTREG, AVR32_V1),
25864 + SYNTAX_NORMAL2(BST, BST, BST, INTREG, UNSIGNED_NUMBER, AVR32_V1),
25865 + SYNTAX_NORMAL2(CACHE, CACHE, CACHE, INTREG_SDISP, UNSIGNED_NUMBER, AVR32_V1),
25866 + SYNTAX_NORMAL1(CASTS_B, CASTS_B, CASTS_B, INTREG, AVR32_V1),
25867 + SYNTAX_NORMAL1(CASTS_H, CASTS_H, CASTS_H, INTREG, AVR32_V1),
25868 + SYNTAX_NORMAL1(CASTU_B, CASTU_B, CASTU_B, INTREG, AVR32_V1),
25869 + SYNTAX_NORMAL1(CASTU_H, CASTU_H, CASTU_H, INTREG, AVR32_V1),
25870 + SYNTAX_NORMAL2(CBR, CBR, CBR, INTREG, UNSIGNED_NUMBER, AVR32_V1),
25871 + SYNTAX_NORMAL2(CLZ, CLZ, CLZ, INTREG, INTREG, AVR32_V1),
25872 + SYNTAX_NORMAL1(COM, COM, COM, INTREG, AVR32_V1),
25873 + SYNTAX_NORMAL5(COP, COP, COP, CPNO, CPREG, CPREG, CPREG, UNSIGNED_NUMBER, AVR32_V1),
25874 + SYNTAX_NORMAL2(CP_B, CP_B, CP_B, INTREG, INTREG, AVR32_V1),
25875 + SYNTAX_NORMAL2(CP_H, CP_H, CP_H, INTREG, INTREG, AVR32_V1),
25876 + SYNTAX_NORMAL_C2(CP_W1, CP_W, CP_W1, CP_W2, INTREG, INTREG, AVR32_V1),
25877 + SYNTAX_NORMAL_C2(CP_W2, CP_W, CP_W2, CP_W3, INTREG, SIGNED_CONST, AVR32_V1),
25878 + SYNTAX_NORMAL2(CP_W3, CP_W, CP_W3, INTREG, SIGNED_CONST, AVR32_V1),
25879 + SYNTAX_NORMAL_C2(CPC1, CPC, CPC1, CPC2, INTREG, INTREG, AVR32_V1),
25880 + SYNTAX_NORMAL1(CPC2, CPC, CPC2, INTREG, AVR32_V1),
25881 + SYNTAX_NORMAL1(CSRF, CSRF, CSRF, UNSIGNED_NUMBER, AVR32_V1),
25882 + SYNTAX_NORMAL1(CSRFCZ, CSRFCZ, CSRFCZ, UNSIGNED_NUMBER, AVR32_V1),
25883 + SYNTAX_NORMAL3(DIVS, DIVS, DIVS, INTREG, INTREG, INTREG, AVR32_V1),
25884 + SYNTAX_NORMAL3(DIVU, DIVU, DIVU, INTREG, INTREG, INTREG, AVR32_V1),
25885 + SYNTAX_NORMAL_C2(EOR1, EOR, EOR1, EOR2, INTREG, INTREG, AVR32_V1),
25886 + SYNTAX_NORMAL_C3(EOR2, EOR, EOR2, EOR3, INTREG, INTREG, INTREG_LSL, AVR32_V1),
25887 + SYNTAX_NORMAL3(EOR3, EOR, EOR3, INTREG, INTREG, INTREG_LSR, AVR32_V1),
25888 + SYNTAX_NORMAL2(EORL, EORL, EORL, INTREG, UNSIGNED_CONST, AVR32_V1),
25889 + SYNTAX_NORMAL2(EORH, EORH, EORH, INTREG, UNSIGNED_CONST, AVR32_V1),
25890 + SYNTAX_NORMAL0(FRS, FRS, FRS, AVR32_V1),
25891 + SYNTAX_NORMAL1(ICALL, ICALL, ICALL, INTREG, AVR32_V1),
25892 + SYNTAX_NORMAL1(INCJOSP, INCJOSP, INCJOSP, JOSPINC, AVR32_V1),
25893 + SYNTAX_NORMAL_C2(LD_D1, LD_D, LD_D1, LD_D2, DWREG, INTREG_POSTINC, AVR32_V1),
25894 + SYNTAX_NORMAL_C2(LD_D2, LD_D, LD_D2, LD_D3, DWREG, INTREG_PREDEC, AVR32_V1),
25895 + SYNTAX_NORMAL_C2(LD_D3, LD_D, LD_D3, LD_D5, DWREG, INTREG, AVR32_V1),
25896 + SYNTAX_NORMAL_C2(LD_D5, LD_D, LD_D5, LD_D4, DWREG, INTREG_INDEX, AVR32_V1),
25897 + SYNTAX_NORMAL2(LD_D4, LD_D, LD_D4, DWREG, INTREG_SDISP, AVR32_V1),
25898 + SYNTAX_NORMAL_C2(LD_SB2, LD_SB, LD_SB2, LD_SB1, INTREG, INTREG_INDEX, AVR32_V1),
25899 + SYNTAX_NORMAL2(LD_SB1, LD_SB, LD_SB1, INTREG, INTREG_SDISP, AVR32_V1),
25900 + SYNTAX_NORMAL_C2(LD_UB1, LD_UB, LD_UB1, LD_UB2, INTREG, INTREG_POSTINC, AVR32_V1),
25901 + SYNTAX_NORMAL_C2(LD_UB2, LD_UB, LD_UB2, LD_UB5, INTREG, INTREG_PREDEC, AVR32_V1),
25902 + SYNTAX_NORMAL_C2(LD_UB5, LD_UB, LD_UB5, LD_UB3, INTREG, INTREG_INDEX, AVR32_V1),
25903 + SYNTAX_NORMAL_C2(LD_UB3, LD_UB, LD_UB3, LD_UB4, INTREG, INTREG_UDISP, AVR32_V1),
25904 + SYNTAX_NORMAL2(LD_UB4, LD_UB, LD_UB4, INTREG, INTREG_SDISP, AVR32_V1),
25905 + SYNTAX_NORMAL_C2(LD_SH1, LD_SH, LD_SH1, LD_SH2, INTREG, INTREG_POSTINC, AVR32_V1),
25906 + SYNTAX_NORMAL_C2(LD_SH2, LD_SH, LD_SH2, LD_SH5, INTREG, INTREG_PREDEC, AVR32_V1),
25907 + SYNTAX_NORMAL_C2(LD_SH5, LD_SH, LD_SH5, LD_SH3, INTREG, INTREG_INDEX, AVR32_V1),
25908 + SYNTAX_NORMAL_C2(LD_SH3, LD_SH, LD_SH3, LD_SH4, INTREG, INTREG_UDISP_H, AVR32_V1),
25909 + SYNTAX_NORMAL2(LD_SH4, LD_SH, LD_SH4, INTREG, INTREG_SDISP, AVR32_V1),
25910 + SYNTAX_NORMAL_C2(LD_UH1, LD_UH, LD_UH1, LD_UH2, INTREG, INTREG_POSTINC, AVR32_V1),
25911 + SYNTAX_NORMAL_C2(LD_UH2, LD_UH, LD_UH2, LD_UH5, INTREG, INTREG_PREDEC, AVR32_V1),
25912 + SYNTAX_NORMAL_C2(LD_UH5, LD_UH, LD_UH5, LD_UH3, INTREG, INTREG_INDEX, AVR32_V1),
25913 + SYNTAX_NORMAL_C2(LD_UH3, LD_UH, LD_UH3, LD_UH4, INTREG, INTREG_UDISP_H, AVR32_V1),
25914 + SYNTAX_NORMAL2(LD_UH4, LD_UH, LD_UH4, INTREG, INTREG_SDISP, AVR32_V1),
25915 + SYNTAX_NORMAL_C2(LD_W1, LD_W, LD_W1, LD_W2, INTREG, INTREG_POSTINC, AVR32_V1),
25916 + SYNTAX_NORMAL_C2(LD_W2, LD_W, LD_W2, LD_W5, INTREG, INTREG_PREDEC, AVR32_V1),
25917 + SYNTAX_NORMAL_C2(LD_W5, LD_W, LD_W5, LD_W6, INTREG, INTREG_INDEX, AVR32_V1),
25918 + SYNTAX_NORMAL_C2(LD_W6, LD_W, LD_W6, LD_W3, INTREG, INTREG_XINDEX, AVR32_V1),
25919 + SYNTAX_NORMAL_C2(LD_W3, LD_W, LD_W3, LD_W4, INTREG, INTREG_UDISP_W, AVR32_V1),
25920 + SYNTAX_NORMAL2(LD_W4, LD_W, LD_W4, INTREG, INTREG_SDISP, AVR32_V1),
25921 + SYNTAX_NORMAL3(LDC_D1, LDC_D, LDC_D1, CPNO, CPREG_D, INTREG_UDISP_W, AVR32_V1),
25922 + SYNTAX_NORMAL_C3(LDC_D2, LDC_D, LDC_D2, LDC_D1, CPNO, CPREG_D, INTREG_PREDEC, AVR32_V1),
25923 + SYNTAX_NORMAL_C3(LDC_D3, LDC_D, LDC_D3, LDC_D2, CPNO, CPREG_D, INTREG_INDEX, AVR32_V1),
25924 + SYNTAX_NORMAL3(LDC_W1, LDC_W, LDC_W1, CPNO, CPREG, INTREG_UDISP_W, AVR32_V1),
25925 + SYNTAX_NORMAL_C3(LDC_W2, LDC_W, LDC_W2, LDC_W1, CPNO, CPREG, INTREG_PREDEC, AVR32_V1),
25926 + SYNTAX_NORMAL_C3(LDC_W3, LDC_W, LDC_W3, LDC_W2, CPNO, CPREG, INTREG_INDEX, AVR32_V1),
25927 + SYNTAX_NORMAL2(LDC0_D, LDC0_D, LDC0_D, CPREG_D, INTREG_UDISP_W, AVR32_V1),
25928 + SYNTAX_NORMAL2(LDC0_W, LDC0_W, LDC0_W, CPREG, INTREG_UDISP_W, AVR32_V1),
25929 + SYNTAX_NORMAL_CM3(LDCM_D, LDCM_D, LDCM_D, LDCM_D_PU, CPNO, INTREG, REGLIST_CPD8, AVR32_V1),
25930 + SYNTAX_NORMALM3(LDCM_D_PU, LDCM_D, LDCM_D_PU, CPNO, INTREG_POSTINC, REGLIST_CPD8, AVR32_V1),
25931 + SYNTAX_NORMAL_CM3(LDCM_W, LDCM_W, LDCM_W, LDCM_W_PU, CPNO, INTREG, REGLIST_CP8, AVR32_V1),
25932 + SYNTAX_NORMALM3(LDCM_W_PU, LDCM_W, LDCM_W_PU, CPNO, INTREG_POSTINC, REGLIST_CP8, AVR32_V1),
25933 + SYNTAX_NORMAL2(LDDPC, LDDPC, LDDPC, INTREG, PC_UDISP_W, AVR32_V1),
25934 + SYNTAX_NORMAL2(LDDPC_EXT, LDDPC, LDDPC_EXT, INTREG, SIGNED_CONST, AVR32_V1),
25935 + SYNTAX_NORMAL2(LDDSP, LDDSP, LDDSP, INTREG, SP_UDISP_W, AVR32_V1),
25936 + SYNTAX_NORMAL2(LDINS_B, LDINS_B, LDINS_B, INTREG_BSEL, INTREG_SDISP, AVR32_V1),
25937 + SYNTAX_NORMAL2(LDINS_H, LDINS_H, LDINS_H, INTREG_HSEL, INTREG_SDISP_H, AVR32_V1),
25938 + SYNTAX_NORMALM1(LDM, LDM, LDM, REGLIST_LDM, AVR32_V1),
25939 + SYNTAX_NORMAL_CM2(LDMTS, LDMTS, LDMTS, LDMTS_PU, INTREG, REGLIST16, AVR32_V1),
25940 + SYNTAX_NORMALM2(LDMTS_PU, LDMTS, LDMTS_PU, INTREG_POSTINC, REGLIST16, AVR32_V1),
25941 + SYNTAX_NORMAL2(LDSWP_SH, LDSWP_SH, LDSWP_SH, INTREG, INTREG_SDISP_H, AVR32_V1),
25942 + SYNTAX_NORMAL2(LDSWP_UH, LDSWP_UH, LDSWP_UH, INTREG, INTREG_SDISP_H, AVR32_V1),
25943 + SYNTAX_NORMAL2(LDSWP_W, LDSWP_W, LDSWP_W, INTREG, INTREG_SDISP_W, AVR32_V1),
25944 + SYNTAX_NORMAL_C3(LSL1, LSL, LSL1, LSL3, INTREG, INTREG, INTREG, AVR32_V1),
25945 + SYNTAX_NORMAL_C3(LSL3, LSL, LSL3, LSL2, INTREG, INTREG, UNSIGNED_NUMBER, AVR32_V1),
25946 + SYNTAX_NORMAL2(LSL2, LSL, LSL2, INTREG, UNSIGNED_NUMBER, AVR32_V1),
25947 + SYNTAX_NORMAL_C3(LSR1, LSR, LSR1, LSR3, INTREG, INTREG, INTREG, AVR32_V1),
25948 + SYNTAX_NORMAL_C3(LSR3, LSR, LSR3, LSR2, INTREG, INTREG, UNSIGNED_NUMBER, AVR32_V1),
25949 + SYNTAX_NORMAL2(LSR2, LSR, LSR2, INTREG, UNSIGNED_NUMBER, AVR32_V1),
25950 + SYNTAX_NORMAL3(MAC, MAC, MAC, INTREG, INTREG, INTREG, AVR32_V1),
25951 + SYNTAX_NORMAL3(MACHH_D, MACHH_D, MACHH_D, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
25952 + SYNTAX_NORMAL3(MACHH_W, MACHH_W, MACHH_W, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
25953 + SYNTAX_NORMAL3(MACS_D, MACS_D, MACS_D, INTREG, INTREG, INTREG, AVR32_V1),
25954 + SYNTAX_NORMAL3(MACSATHH_W, MACSATHH_W, MACSATHH_W, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
25955 + SYNTAX_NORMAL3(MACUD, MACU_D, MACUD, INTREG, INTREG, INTREG, AVR32_V1),
25956 + SYNTAX_NORMAL3(MACWH_D, MACWH_D, MACWH_D, INTREG, INTREG, INTREG_HSEL, AVR32_DSP),
25957 + SYNTAX_NORMAL3(MAX, MAX, MAX, INTREG, INTREG, INTREG, AVR32_V1),
25958 + SYNTAX_NORMAL1(MCALL, MCALL, MCALL, MCALL, AVR32_V1),
25959 + SYNTAX_NORMAL2(MFDR, MFDR, MFDR, INTREG, UNSIGNED_CONST_W, AVR32_V1),
25960 + SYNTAX_NORMAL2(MFSR, MFSR, MFSR, INTREG, UNSIGNED_CONST_W, AVR32_V1),
25961 + SYNTAX_NORMAL3(MIN, MIN, MIN, INTREG, INTREG, INTREG, AVR32_V1),
25962 + SYNTAX_NORMAL_C2(MOV3, MOV, MOV3, MOV1, INTREG, INTREG, AVR32_V1),
25963 + SYNTAX_NORMAL_C2(MOV1, MOV, MOV1, MOV2, INTREG, SIGNED_CONST, AVR32_V1),
25964 + SYNTAX_NORMAL2(MOV2, MOV, MOV2,INTREG, SIGNED_CONST, AVR32_V1),
25965 + SYNTAX_NORMAL_C2(MOVEQ1, MOVEQ, MOVEQ1, MOVEQ2, INTREG, INTREG, AVR32_V1),
25966 + SYNTAX_NORMAL_C2(MOVNE1, MOVNE, MOVNE1, MOVNE2, INTREG, INTREG, AVR32_V1),
25967 + SYNTAX_NORMAL_C2(MOVCC1, MOVCC, MOVCC1, MOVCC2, INTREG, INTREG, AVR32_V1),
25968 + SYNTAX_NORMAL_C2(MOVCS1, MOVCS, MOVCS1, MOVCS2, INTREG, INTREG, AVR32_V1),
25969 + SYNTAX_NORMAL_C2(MOVGE1, MOVGE, MOVGE1, MOVGE2, INTREG, INTREG, AVR32_V1),
25970 + SYNTAX_NORMAL_C2(MOVLT1, MOVLT, MOVLT1, MOVLT2, INTREG, INTREG, AVR32_V1),
25971 + SYNTAX_NORMAL_C2(MOVMI1, MOVMI, MOVMI1, MOVMI2, INTREG, INTREG, AVR32_V1),
25972 + SYNTAX_NORMAL_C2(MOVPL1, MOVPL, MOVPL1, MOVPL2, INTREG, INTREG, AVR32_V1),
25973 + SYNTAX_NORMAL_C2(MOVLS1, MOVLS, MOVLS1, MOVLS2, INTREG, INTREG, AVR32_V1),
25974 + SYNTAX_NORMAL_C2(MOVGT1, MOVGT, MOVGT1, MOVGT2, INTREG, INTREG, AVR32_V1),
25975 + SYNTAX_NORMAL_C2(MOVLE1, MOVLE, MOVLE1, MOVLE2, INTREG, INTREG, AVR32_V1),
25976 + SYNTAX_NORMAL_C2(MOVHI1, MOVHI, MOVHI1, MOVHI2, INTREG, INTREG, AVR32_V1),
25977 + SYNTAX_NORMAL_C2(MOVVS1, MOVVS, MOVVS1, MOVVS2, INTREG, INTREG, AVR32_V1),
25978 + SYNTAX_NORMAL_C2(MOVVC1, MOVVC, MOVVC1, MOVVC2, INTREG, INTREG, AVR32_V1),
25979 + SYNTAX_NORMAL_C2(MOVQS1, MOVQS, MOVQS1, MOVQS2, INTREG, INTREG, AVR32_V1),
25980 + SYNTAX_NORMAL_C2(MOVAL1, MOVAL, MOVAL1, MOVAL2, INTREG, INTREG, AVR32_V1),
25981 + SYNTAX_NORMAL_C2(MOVHS1, MOVHS, MOVCC1, MOVHS2, INTREG, INTREG, AVR32_V1),
25982 + SYNTAX_NORMAL_C2(MOVLO1, MOVLO, MOVCS1, MOVLO2, INTREG, INTREG, AVR32_V1),
25983 + SYNTAX_NORMAL2(MOVEQ2, MOVEQ, MOVEQ2, INTREG, SIGNED_CONST, AVR32_V1),
25984 + SYNTAX_NORMAL2(MOVNE2, MOVNE, MOVNE2, INTREG, SIGNED_CONST, AVR32_V1),
25985 + SYNTAX_NORMAL2(MOVCC2, MOVCC, MOVCC2, INTREG, SIGNED_CONST, AVR32_V1),
25986 + SYNTAX_NORMAL2(MOVCS2, MOVCS, MOVCS2, INTREG, SIGNED_CONST, AVR32_V1),
25987 + SYNTAX_NORMAL2(MOVGE2, MOVGE, MOVGE2, INTREG, SIGNED_CONST, AVR32_V1),
25988 + SYNTAX_NORMAL2(MOVLT2, MOVLT, MOVLT2, INTREG, SIGNED_CONST, AVR32_V1),
25989 + SYNTAX_NORMAL2(MOVMI2, MOVMI, MOVMI2, INTREG, SIGNED_CONST, AVR32_V1),
25990 + SYNTAX_NORMAL2(MOVPL2, MOVPL, MOVPL2, INTREG, SIGNED_CONST, AVR32_V1),
25991 + SYNTAX_NORMAL2(MOVLS2, MOVLS, MOVLS2, INTREG, SIGNED_CONST, AVR32_V1),
25992 + SYNTAX_NORMAL2(MOVGT2, MOVGT, MOVGT2, INTREG, SIGNED_CONST, AVR32_V1),
25993 + SYNTAX_NORMAL2(MOVLE2, MOVLE, MOVLE2, INTREG, SIGNED_CONST, AVR32_V1),
25994 + SYNTAX_NORMAL2(MOVHI2, MOVHI, MOVHI2, INTREG, SIGNED_CONST, AVR32_V1),
25995 + SYNTAX_NORMAL2(MOVVS2, MOVVS, MOVVS2, INTREG, SIGNED_CONST, AVR32_V1),
25996 + SYNTAX_NORMAL2(MOVVC2, MOVVC, MOVVC2, INTREG, SIGNED_CONST, AVR32_V1),
25997 + SYNTAX_NORMAL2(MOVQS2, MOVQS, MOVQS2, INTREG, SIGNED_CONST, AVR32_V1),
25998 + SYNTAX_NORMAL2(MOVAL2, MOVAL, MOVAL2, INTREG, SIGNED_CONST, AVR32_V1),
25999 + SYNTAX_NORMAL2(MOVHS2, MOVHS, MOVCC2, INTREG, SIGNED_CONST, AVR32_V1),
26000 + SYNTAX_NORMAL2(MOVLO2, MOVLO, MOVCS2, INTREG, SIGNED_CONST, AVR32_V1),
26001 + SYNTAX_NORMAL2(MTDR, MTDR, MTDR, UNSIGNED_CONST_W, INTREG, AVR32_V1),
26002 + SYNTAX_NORMAL2(MTSR, MTSR, MTSR, UNSIGNED_CONST_W, INTREG, AVR32_V1),
26003 + SYNTAX_NORMAL_C2(MUL1, MUL, MUL1, MUL2, INTREG, INTREG, AVR32_V1),
26004 + SYNTAX_NORMAL_C3(MUL2, MUL, MUL2, MUL3, INTREG, INTREG, INTREG, AVR32_V1),
26005 + SYNTAX_NORMAL3(MUL3, MUL, MUL3, INTREG, INTREG, SIGNED_CONST, AVR32_V1),
26006 + SYNTAX_NORMAL3(MULHH_W, MULHH_W, MULHH_W, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
26007 + SYNTAX_NORMAL3(MULNHH_W, MULNHH_W, MULNHH_W, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
26008 + SYNTAX_NORMAL3(MULNWH_D, MULNWH_D, MULNWH_D, INTREG, INTREG, INTREG_HSEL, AVR32_DSP),
26009 + SYNTAX_NORMAL3(MULSD, MULS_D, MULSD, INTREG, INTREG, INTREG, AVR32_V1),
26010 + SYNTAX_NORMAL3(MULSATHH_H, MULSATHH_H, MULSATHH_H, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
26011 + SYNTAX_NORMAL3(MULSATHH_W, MULSATHH_W, MULSATHH_W, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
26012 + SYNTAX_NORMAL3(MULSATRNDHH_H, MULSATRNDHH_H, MULSATRNDHH_H, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
26013 + SYNTAX_NORMAL3(MULSATRNDWH_W, MULSATRNDWH_W, MULSATRNDWH_W, INTREG, INTREG, INTREG_HSEL, AVR32_DSP),
26014 + SYNTAX_NORMAL3(MULSATWH_W, MULSATWH_W, MULSATWH_W, INTREG, INTREG, INTREG_HSEL, AVR32_DSP),
26015 + SYNTAX_NORMAL3(MULU_D, MULU_D, MULU_D, INTREG, INTREG, INTREG, AVR32_V1),
26016 + SYNTAX_NORMAL3(MULWH_D, MULWH_D, MULWH_D, INTREG, INTREG, INTREG_HSEL, AVR32_DSP),
26017 + SYNTAX_NORMAL1(MUSFR, MUSFR, MUSFR, INTREG, AVR32_V1),
26018 + SYNTAX_NORMAL1(MUSTR, MUSTR, MUSTR, INTREG, AVR32_V1),
26019 + SYNTAX_NORMAL3(MVCR_D, MVCR_D, MVCR_D, CPNO, DWREG, CPREG_D, AVR32_V1),
26020 + SYNTAX_NORMAL3(MVCR_W, MVCR_W, MVCR_W, CPNO, INTREG, CPREG, AVR32_V1),
26021 + SYNTAX_NORMAL3(MVRC_D, MVRC_D, MVRC_D, CPNO, CPREG_D, DWREG, AVR32_V1),
26022 + SYNTAX_NORMAL3(MVRC_W, MVRC_W, MVRC_W, CPNO, CPREG, INTREG, AVR32_V1),
26023 + SYNTAX_NORMAL1(NEG, NEG, NEG, INTREG, AVR32_V1),
26024 + SYNTAX_NORMAL0(NOP, NOP, NOP, AVR32_V1),
26025 + SYNTAX_NORMAL_C2(OR1, OR, OR1, OR2, INTREG, INTREG, AVR32_V1),
26026 + SYNTAX_NORMAL_C3(OR2, OR, OR2, OR3, INTREG, INTREG, INTREG_LSL, AVR32_V1),
26027 + SYNTAX_NORMAL3(OR3, OR, OR3, INTREG, INTREG, INTREG_LSR, AVR32_V1),
26028 + SYNTAX_NORMAL2(ORH, ORH, ORH, INTREG, UNSIGNED_CONST, AVR32_V1),
26029 + SYNTAX_NORMAL2(ORL, ORL, ORL, INTREG, UNSIGNED_CONST, AVR32_V1),
26030 + SYNTAX_NORMAL2(PABS_SB, PABS_SB, PABS_SB, INTREG, INTREG, AVR32_SIMD),
26031 + SYNTAX_NORMAL2(PABS_SH, PABS_SH, PABS_SH, INTREG, INTREG, AVR32_SIMD),
26032 + SYNTAX_NORMAL3(PACKSH_SB, PACKSH_SB, PACKSH_SB, INTREG, INTREG, INTREG, AVR32_SIMD),
26033 + SYNTAX_NORMAL3(PACKSH_UB, PACKSH_UB, PACKSH_UB, INTREG, INTREG, INTREG, AVR32_SIMD),
26034 + SYNTAX_NORMAL3(PACKW_SH, PACKW_SH, PACKW_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26035 + SYNTAX_NORMAL3(PADD_B, PADD_B, PADD_B, INTREG, INTREG, INTREG, AVR32_SIMD),
26036 + SYNTAX_NORMAL3(PADD_H, PADD_H, PADD_H, INTREG, INTREG, INTREG, AVR32_SIMD),
26037 + SYNTAX_NORMAL3(PADDH_SH, PADDH_SH, PADDH_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26038 + SYNTAX_NORMAL3(PADDH_UB, PADDH_UB, PADDH_UB, INTREG, INTREG, INTREG, AVR32_SIMD),
26039 + SYNTAX_NORMAL3(PADDS_SB, PADDS_SB, PADDS_SB, INTREG, INTREG, INTREG, AVR32_SIMD),
26040 + SYNTAX_NORMAL3(PADDS_SH, PADDS_SH, PADDS_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26041 + SYNTAX_NORMAL3(PADDS_UB, PADDS_UB, PADDS_UB, INTREG, INTREG, INTREG, AVR32_SIMD),
26042 + SYNTAX_NORMAL3(PADDS_UH, PADDS_UH, PADDS_UH, INTREG, INTREG, INTREG, AVR32_SIMD),
26043 + SYNTAX_NORMAL3(PADDSUB_H, PADDSUB_H, PADDSUB_H, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_SIMD),
26044 + SYNTAX_NORMAL3(PADDSUBH_SH, PADDSUBH_SH, PADDSUBH_SH, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_SIMD),
26045 + SYNTAX_NORMAL3(PADDSUBS_SH, PADDSUBS_SH, PADDSUBS_SH, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_SIMD),
26046 + SYNTAX_NORMAL3(PADDSUBS_UH, PADDSUBS_UH, PADDSUBS_UH, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_SIMD),
26047 + SYNTAX_NORMAL3(PADDX_H, PADDX_H, PADDX_H, INTREG, INTREG, INTREG, AVR32_SIMD),
26048 + SYNTAX_NORMAL3(PADDXH_SH, PADDXH_SH, PADDXH_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26049 + SYNTAX_NORMAL3(PADDXS_SH, PADDXS_SH, PADDXS_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26050 + SYNTAX_NORMAL3(PADDXS_UH, PADDXS_UH, PADDXS_UH, INTREG, INTREG, INTREG, AVR32_SIMD),
26051 + SYNTAX_NORMAL3(PASR_B, PASR_B, PASR_B, INTREG, INTREG, UNSIGNED_NUMBER, AVR32_SIMD),
26052 + SYNTAX_NORMAL3(PASR_H, PASR_H, PASR_H, INTREG, INTREG, UNSIGNED_NUMBER, AVR32_SIMD),
26053 + SYNTAX_NORMAL3(PAVG_SH, PAVG_SH, PAVG_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26054 + SYNTAX_NORMAL3(PAVG_UB, PAVG_UB, PAVG_UB, INTREG, INTREG, INTREG, AVR32_SIMD),
26055 + SYNTAX_NORMAL3(PLSL_B, PLSL_B, PLSL_B, INTREG, INTREG, UNSIGNED_NUMBER, AVR32_SIMD),
26056 + SYNTAX_NORMAL3(PLSL_H, PLSL_H, PLSL_H, INTREG, INTREG, UNSIGNED_NUMBER, AVR32_SIMD),
26057 + SYNTAX_NORMAL3(PLSR_B, PLSR_B, PLSR_B, INTREG, INTREG, UNSIGNED_NUMBER, AVR32_SIMD),
26058 + SYNTAX_NORMAL3(PLSR_H, PLSR_H, PLSR_H, INTREG, INTREG, UNSIGNED_NUMBER, AVR32_SIMD),
26059 + SYNTAX_NORMAL3(PMAX_SH, PMAX_SH, PMAX_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26060 + SYNTAX_NORMAL3(PMAX_UB, PMAX_UB, PMAX_UB, INTREG, INTREG, INTREG, AVR32_SIMD),
26061 + SYNTAX_NORMAL3(PMIN_SH, PMIN_SH, PMIN_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26062 + SYNTAX_NORMAL3(PMIN_UB, PMIN_UB, PMIN_UB, INTREG, INTREG, INTREG, AVR32_SIMD),
26063 + SYNTAX_NORMAL0(POPJC, POPJC, POPJC, AVR32_V1),
26064 + SYNTAX_NORMAL_CM1(POPM, POPM, POPM, POPM_E, REGLIST9, AVR32_V1),
26065 + SYNTAX_NORMALM1(POPM_E, POPM, POPM_E, REGLIST16, AVR32_V1),
26066 + SYNTAX_NORMAL1(PREF, PREF, PREF, INTREG_SDISP, AVR32_V1),
26067 + SYNTAX_NORMAL3(PSAD, PSAD, PSAD, INTREG, INTREG, INTREG, AVR32_SIMD),
26068 + SYNTAX_NORMAL3(PSUB_B, PSUB_B, PSUB_B, INTREG, INTREG, INTREG, AVR32_SIMD),
26069 + SYNTAX_NORMAL3(PSUB_H, PSUB_H, PSUB_H, INTREG, INTREG, INTREG, AVR32_SIMD),
26070 + SYNTAX_NORMAL3(PSUBADD_H, PSUBADD_H, PSUBADD_H, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_SIMD),
26071 + SYNTAX_NORMAL3(PSUBADDH_SH, PSUBADDH_SH, PSUBADDH_SH, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_SIMD),
26072 + SYNTAX_NORMAL3(PSUBADDS_SH, PSUBADDS_SH, PSUBADDS_SH, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_SIMD),
26073 + SYNTAX_NORMAL3(PSUBADDS_UH, PSUBADDS_UH, PSUBADDS_UH, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_SIMD),
26074 + SYNTAX_NORMAL3(PSUBH_SH, PSUBH_SH, PSUBH_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26075 + SYNTAX_NORMAL3(PSUBH_UB, PSUBH_UB, PSUBH_UB, INTREG, INTREG, INTREG, AVR32_SIMD),
26076 + SYNTAX_NORMAL3(PSUBS_SB, PSUBS_SB, PSUBS_SB, INTREG, INTREG, INTREG, AVR32_SIMD),
26077 + SYNTAX_NORMAL3(PSUBS_SH, PSUBS_SH, PSUBS_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26078 + SYNTAX_NORMAL3(PSUBS_UB, PSUBS_UB, PSUBS_UB, INTREG, INTREG, INTREG, AVR32_SIMD),
26079 + SYNTAX_NORMAL3(PSUBS_UH, PSUBS_UH, PSUBS_UH, INTREG, INTREG, INTREG, AVR32_SIMD),
26080 + SYNTAX_NORMAL3(PSUBX_H, PSUBX_H, PSUBX_H, INTREG, INTREG, INTREG, AVR32_SIMD),
26081 + SYNTAX_NORMAL3(PSUBXH_SH, PSUBXH_SH, PSUBXH_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26082 + SYNTAX_NORMAL3(PSUBXS_SH, PSUBXS_SH, PSUBXS_SH, INTREG, INTREG, INTREG, AVR32_SIMD),
26083 + SYNTAX_NORMAL3(PSUBXS_UH, PSUBXS_UH, PSUBXS_UH, INTREG, INTREG, INTREG, AVR32_SIMD),
26084 + SYNTAX_NORMAL2(PUNPCKSB_H, PUNPCKSB_H, PUNPCKSB_H, INTREG, INTREG_HSEL, AVR32_SIMD),
26085 + SYNTAX_NORMAL2(PUNPCKUB_H, PUNPCKUB_H, PUNPCKUB_H, INTREG, INTREG_HSEL, AVR32_SIMD),
26086 + SYNTAX_NORMAL0(PUSHJC, PUSHJC, PUSHJC, AVR32_V1),
26087 + SYNTAX_NORMAL_CM1(PUSHM, PUSHM, PUSHM, PUSHM_E, REGLIST8, AVR32_V1),
26088 + SYNTAX_NORMALM1(PUSHM_E, PUSHM, PUSHM_E, REGLIST16, AVR32_V1),
26089 + SYNTAX_NORMAL_C1(RCALL1, RCALL, RCALL1, RCALL2, JMPLABEL, AVR32_V1),
26090 + SYNTAX_NORMAL1(RCALL2, RCALL, RCALL2, JMPLABEL, AVR32_V1),
26091 + SYNTAX_NORMAL1(RETEQ, RETEQ, RETEQ, RETVAL, AVR32_V1),
26092 + SYNTAX_NORMAL1(RETNE, RETNE, RETNE, RETVAL, AVR32_V1),
26093 + SYNTAX_NORMAL1(RETCC, RETCC, RETCC, RETVAL, AVR32_V1),
26094 + SYNTAX_NORMAL1(RETCS, RETCS, RETCS, RETVAL, AVR32_V1),
26095 + SYNTAX_NORMAL1(RETGE, RETGE, RETGE, RETVAL, AVR32_V1),
26096 + SYNTAX_NORMAL1(RETLT, RETLT, RETLT, RETVAL, AVR32_V1),
26097 + SYNTAX_NORMAL1(RETMI, RETMI, RETMI, RETVAL, AVR32_V1),
26098 + SYNTAX_NORMAL1(RETPL, RETPL, RETPL, RETVAL, AVR32_V1),
26099 + SYNTAX_NORMAL1(RETLS, RETLS, RETLS, RETVAL, AVR32_V1),
26100 + SYNTAX_NORMAL1(RETGT, RETGT, RETGT, RETVAL, AVR32_V1),
26101 + SYNTAX_NORMAL1(RETLE, RETLE, RETLE, RETVAL, AVR32_V1),
26102 + SYNTAX_NORMAL1(RETHI, RETHI, RETHI, RETVAL, AVR32_V1),
26103 + SYNTAX_NORMAL1(RETVS, RETVS, RETVS, RETVAL, AVR32_V1),
26104 + SYNTAX_NORMAL1(RETVC, RETVC, RETVC, RETVAL, AVR32_V1),
26105 + SYNTAX_NORMAL1(RETQS, RETQS, RETQS, RETVAL, AVR32_V1),
26106 + SYNTAX_NORMAL1(RETAL, RETAL, RETAL, RETVAL, AVR32_V1),
26107 + SYNTAX_NORMAL1(RETHS, RETHS, RETCC, RETVAL, AVR32_V1),
26108 + SYNTAX_NORMAL1(RETLO, RETLO, RETCS, RETVAL, AVR32_V1),
26109 + SYNTAX_NORMAL0(RETD, RETD, RETD, AVR32_V1),
26110 + SYNTAX_NORMAL0(RETE, RETE, RETE, AVR32_V1),
26111 + SYNTAX_NORMAL0(RETJ, RETJ, RETJ, AVR32_V1),
26112 + SYNTAX_NORMAL0(RETS, RETS, RETS, AVR32_V1),
26113 + SYNTAX_NORMAL1(RJMP, RJMP, RJMP, JMPLABEL, AVR32_V1),
26114 + SYNTAX_NORMAL1(ROL, ROL, ROL, INTREG, AVR32_V1),
26115 + SYNTAX_NORMAL1(ROR, ROR, ROR, INTREG, AVR32_V1),
26116 + SYNTAX_NORMAL_C2(RSUB1, RSUB, RSUB1, RSUB2, INTREG, INTREG, AVR32_V1),
26117 + SYNTAX_NORMAL3(RSUB2, RSUB, RSUB2, INTREG, INTREG, SIGNED_CONST, AVR32_V1),
26118 + SYNTAX_NORMAL3(SATADD_H, SATADD_H, SATADD_H, INTREG, INTREG, INTREG, AVR32_DSP),
26119 + SYNTAX_NORMAL3(SATADD_W, SATADD_W, SATADD_W, INTREG, INTREG, INTREG, AVR32_DSP),
26120 + SYNTAX_NORMAL2(SATRNDS, SATRNDS, SATRNDS, INTREG_LSR, UNSIGNED_NUMBER, AVR32_DSP),
26121 + SYNTAX_NORMAL2(SATRNDU, SATRNDU, SATRNDU, INTREG_LSR, UNSIGNED_NUMBER, AVR32_DSP),
26122 + SYNTAX_NORMAL2(SATS, SATS, SATS, INTREG_LSR, UNSIGNED_NUMBER, AVR32_DSP),
26123 + SYNTAX_NORMAL3(SATSUB_H, SATSUB_H, SATSUB_H, INTREG, INTREG, INTREG, AVR32_DSP),
26124 + SYNTAX_NORMAL_C3(SATSUB_W1, SATSUB_W, SATSUB_W1, SATSUB_W2, INTREG, INTREG, INTREG, AVR32_DSP),
26125 + SYNTAX_NORMAL3(SATSUB_W2, SATSUB_W, SATSUB_W2, INTREG, INTREG, SIGNED_CONST, AVR32_DSP),
26126 + SYNTAX_NORMAL2(SATU, SATU, SATU, INTREG_LSR, UNSIGNED_NUMBER, AVR32_V1),
26127 + SYNTAX_NORMAL3(SBC, SBC, SBC, INTREG, INTREG, INTREG, AVR32_V1),
26128 + SYNTAX_NORMAL2(SBR, SBR, SBR, INTREG, UNSIGNED_NUMBER, AVR32_V1),
26129 + SYNTAX_NORMAL0(SCALL, SCALL, SCALL, AVR32_V1),
26130 + SYNTAX_NORMAL1(SCR, SCR, SCR, INTREG, AVR32_V1),
26131 + SYNTAX_NORMAL1(SLEEP, SLEEP, SLEEP, UNSIGNED_CONST, AVR32_V1),
26132 + SYNTAX_NORMAL1(SREQ, SREQ, SREQ, INTREG, AVR32_V1),
26133 + SYNTAX_NORMAL1(SRNE, SRNE, SRNE, INTREG, AVR32_V1),
26134 + SYNTAX_NORMAL1(SRCC, SRCC, SRCC, INTREG, AVR32_V1),
26135 + SYNTAX_NORMAL1(SRCS, SRCS, SRCS, INTREG, AVR32_V1),
26136 + SYNTAX_NORMAL1(SRGE, SRGE, SRGE, INTREG, AVR32_V1),
26137 + SYNTAX_NORMAL1(SRLT, SRLT, SRLT, INTREG, AVR32_V1),
26138 + SYNTAX_NORMAL1(SRMI, SRMI, SRMI, INTREG, AVR32_V1),
26139 + SYNTAX_NORMAL1(SRPL, SRPL, SRPL, INTREG, AVR32_V1),
26140 + SYNTAX_NORMAL1(SRLS, SRLS, SRLS, INTREG, AVR32_V1),
26141 + SYNTAX_NORMAL1(SRGT, SRGT, SRGT, INTREG, AVR32_V1),
26142 + SYNTAX_NORMAL1(SRLE, SRLE, SRLE, INTREG, AVR32_V1),
26143 + SYNTAX_NORMAL1(SRHI, SRHI, SRHI, INTREG, AVR32_V1),
26144 + SYNTAX_NORMAL1(SRVS, SRVS, SRVS, INTREG, AVR32_V1),
26145 + SYNTAX_NORMAL1(SRVC, SRVC, SRVC, INTREG, AVR32_V1),
26146 + SYNTAX_NORMAL1(SRQS, SRQS, SRQS, INTREG, AVR32_V1),
26147 + SYNTAX_NORMAL1(SRAL, SRAL, SRAL, INTREG, AVR32_V1),
26148 + SYNTAX_NORMAL1(SRHS, SRHS, SRCC, INTREG, AVR32_V1),
26149 + SYNTAX_NORMAL1(SRLO, SRLO, SRCS, INTREG, AVR32_V1),
26150 + SYNTAX_NORMAL1(SSRF, SSRF, SSRF, UNSIGNED_NUMBER, AVR32_V1),
26151 + SYNTAX_NORMAL_C2(ST_B1, ST_B, ST_B1, ST_B2, INTREG_POSTINC, INTREG, AVR32_V1),
26152 + SYNTAX_NORMAL_C2(ST_B2, ST_B, ST_B2, ST_B5, INTREG_PREDEC, INTREG, AVR32_V1),
26153 + SYNTAX_NORMAL_C2(ST_B5, ST_B, ST_B5, ST_B3, INTREG_INDEX, INTREG, AVR32_V1),
26154 + SYNTAX_NORMAL_C2(ST_B3, ST_B, ST_B3, ST_B4, INTREG_UDISP, INTREG, AVR32_V1),
26155 + SYNTAX_NORMAL2(ST_B4, ST_B, ST_B4, INTREG_SDISP, INTREG, AVR32_V1),
26156 + SYNTAX_NORMAL_C2(ST_D1, ST_D, ST_D1, ST_D2, INTREG_POSTINC, DWREG, AVR32_V1),
26157 + SYNTAX_NORMAL_C2(ST_D2, ST_D, ST_D2, ST_D3, INTREG_PREDEC, DWREG, AVR32_V1),
26158 + SYNTAX_NORMAL_C2(ST_D3, ST_D, ST_D3, ST_D5, INTREG, DWREG, AVR32_V1),
26159 + SYNTAX_NORMAL_C2(ST_D5, ST_D, ST_D5, ST_D4, INTREG_INDEX, DWREG, AVR32_V1),
26160 + SYNTAX_NORMAL2(ST_D4, ST_D, ST_D4, INTREG_SDISP, DWREG, AVR32_V1),
26161 + SYNTAX_NORMAL_C2(ST_H1, ST_H, ST_H1, ST_H2, INTREG_POSTINC, INTREG, AVR32_V1),
26162 + SYNTAX_NORMAL_C2(ST_H2, ST_H, ST_H2, ST_H5, INTREG_PREDEC, INTREG, AVR32_V1),
26163 + SYNTAX_NORMAL_C2(ST_H5, ST_H, ST_H5, ST_H3, INTREG_INDEX, INTREG, AVR32_V1),
26164 + SYNTAX_NORMAL_C2(ST_H3, ST_H, ST_H3, ST_H4, INTREG_UDISP_H, INTREG, AVR32_V1),
26165 + SYNTAX_NORMAL2(ST_H4, ST_H, ST_H4, INTREG_SDISP, INTREG, AVR32_V1),
26166 + SYNTAX_NORMAL_C2(ST_W1, ST_W, ST_W1, ST_W2, INTREG_POSTINC, INTREG, AVR32_V1),
26167 + SYNTAX_NORMAL_C2(ST_W2, ST_W, ST_W2, ST_W5, INTREG_PREDEC, INTREG, AVR32_V1),
26168 + SYNTAX_NORMAL_C2(ST_W5, ST_W, ST_W5, ST_W3, INTREG_INDEX, INTREG, AVR32_V1),
26169 + SYNTAX_NORMAL_C2(ST_W3, ST_W, ST_W3, ST_W4, INTREG_UDISP_W, INTREG, AVR32_V1),
26170 + SYNTAX_NORMAL2(ST_W4, ST_W, ST_W4, INTREG_SDISP, INTREG, AVR32_V1),
26171 + SYNTAX_NORMAL3(STC_D1, STC_D, STC_D1, CPNO, INTREG_UDISP_W, CPREG_D, AVR32_V1),
26172 + SYNTAX_NORMAL_C3(STC_D2, STC_D, STC_D2, STC_D1, CPNO, INTREG_POSTINC, CPREG_D, AVR32_V1),
26173 + SYNTAX_NORMAL_C3(STC_D3, STC_D, STC_D3, STC_D2, CPNO, INTREG_INDEX, CPREG_D, AVR32_V1),
26174 + SYNTAX_NORMAL3(STC_W1, STC_W, STC_W1, CPNO, INTREG_UDISP_W, CPREG, AVR32_V1),
26175 + SYNTAX_NORMAL_C3(STC_W2, STC_W, STC_W2, STC_W1, CPNO, INTREG_POSTINC, CPREG, AVR32_V1),
26176 + SYNTAX_NORMAL_C3(STC_W3, STC_W, STC_W3, STC_W2, CPNO, INTREG_INDEX, CPREG, AVR32_V1),
26177 + SYNTAX_NORMAL2(STC0_D, STC0_D, STC0_D, INTREG_UDISP_W, CPREG_D, AVR32_V1),
26178 + SYNTAX_NORMAL2(STC0_W, STC0_W, STC0_W, INTREG_UDISP_W, CPREG, AVR32_V1),
26179 + SYNTAX_NORMAL_CM3(STCM_D, STCM_D, STCM_D, STCM_D_PU, CPNO, INTREG, REGLIST_CPD8, AVR32_V1),
26180 + SYNTAX_NORMALM3(STCM_D_PU, STCM_D, STCM_D_PU, CPNO, INTREG_PREDEC, REGLIST_CPD8, AVR32_V1),
26181 + SYNTAX_NORMAL_CM3(STCM_W, STCM_W, STCM_W, STCM_W_PU, CPNO, INTREG, REGLIST_CP8, AVR32_V1),
26182 + SYNTAX_NORMALM3(STCM_W_PU, STCM_W, STCM_W_PU, CPNO, INTREG_PREDEC, REGLIST_CP8, AVR32_V1),
26183 + SYNTAX_NORMAL2(STCOND, STCOND, STCOND, INTREG_SDISP, INTREG, AVR32_V1),
26184 + SYNTAX_NORMAL2(STDSP, STDSP, STDSP, SP_UDISP_W, INTREG, AVR32_V1),
26185 + SYNTAX_NORMAL_C3(STHH_W2, STHH_W, STHH_W2, STHH_W1, INTREG_INDEX, INTREG_HSEL, INTREG_HSEL, AVR32_V1),
26186 + SYNTAX_NORMAL3(STHH_W1, STHH_W, STHH_W1, INTREG_UDISP_W, INTREG_HSEL, INTREG_HSEL, AVR32_V1),
26187 + SYNTAX_NORMAL_CM2(STM, STM, STM, STM_PU, INTREG, REGLIST16, AVR32_V1),
26188 + SYNTAX_NORMALM2(STM_PU, STM, STM_PU, INTREG_PREDEC, REGLIST16, AVR32_V1),
26189 + SYNTAX_NORMAL_CM2(STMTS, STMTS, STMTS, STMTS_PU, INTREG, REGLIST16, AVR32_V1),
26190 + SYNTAX_NORMALM2(STMTS_PU, STMTS, STMTS_PU, INTREG_PREDEC, REGLIST16, AVR32_V1),
26191 + SYNTAX_NORMAL2(STSWP_H, STSWP_H, STSWP_H, INTREG_SDISP_H, INTREG, AVR32_V1),
26192 + SYNTAX_NORMAL2(STSWP_W, STSWP_W, STSWP_W, INTREG_SDISP_W, INTREG, AVR32_V1),
26193 + SYNTAX_NORMAL_C2(SUB1, SUB, SUB1, SUB2, INTREG, INTREG, AVR32_V1),
26194 + SYNTAX_NORMAL_C3(SUB2, SUB, SUB2, SUB5, INTREG, INTREG, INTREG_LSL, AVR32_V1),
26195 + SYNTAX_NORMAL_C3(SUB5, SUB, SUB5, SUB3_SP, INTREG, INTREG, SIGNED_CONST, AVR32_V1),
26196 + SYNTAX_NORMAL_C2(SUB3_SP, SUB, SUB3_SP, SUB3, SP, SIGNED_CONST_W, AVR32_V1),
26197 + SYNTAX_NORMAL_C2(SUB3, SUB, SUB3, SUB4, INTREG, SIGNED_CONST, AVR32_V1),
26198 + SYNTAX_NORMAL2(SUB4, SUB, SUB4, INTREG, SIGNED_CONST, AVR32_V1),
26199 + SYNTAX_NORMAL_C2(SUBEQ, SUBEQ, SUBEQ, SUB2EQ, INTREG, SIGNED_CONST, AVR32_V1),
26200 + SYNTAX_NORMAL_C2(SUBNE, SUBNE, SUBNE, SUB2NE, INTREG, SIGNED_CONST, AVR32_V1),
26201 + SYNTAX_NORMAL_C2(SUBCC, SUBCC, SUBCC, SUB2CC, INTREG, SIGNED_CONST, AVR32_V1),
26202 + SYNTAX_NORMAL_C2(SUBCS, SUBCS, SUBCS, SUB2CS, INTREG, SIGNED_CONST, AVR32_V1),
26203 + SYNTAX_NORMAL_C2(SUBGE, SUBGE, SUBGE, SUB2GE, INTREG, SIGNED_CONST, AVR32_V1),
26204 + SYNTAX_NORMAL_C2(SUBLT, SUBLT, SUBLT, SUB2LT, INTREG, SIGNED_CONST, AVR32_V1),
26205 + SYNTAX_NORMAL_C2(SUBMI, SUBMI, SUBMI, SUB2MI, INTREG, SIGNED_CONST, AVR32_V1),
26206 + SYNTAX_NORMAL_C2(SUBPL, SUBPL, SUBPL, SUB2PL, INTREG, SIGNED_CONST, AVR32_V1),
26207 + SYNTAX_NORMAL_C2(SUBLS, SUBLS, SUBLS, SUB2LS, INTREG, SIGNED_CONST, AVR32_V1),
26208 + SYNTAX_NORMAL_C2(SUBGT, SUBGT, SUBGT, SUB2GT, INTREG, SIGNED_CONST, AVR32_V1),
26209 + SYNTAX_NORMAL_C2(SUBLE, SUBLE, SUBLE, SUB2LE, INTREG, SIGNED_CONST, AVR32_V1),
26210 + SYNTAX_NORMAL_C2(SUBHI, SUBHI, SUBHI, SUB2HI, INTREG, SIGNED_CONST, AVR32_V1),
26211 + SYNTAX_NORMAL_C2(SUBVS, SUBVS, SUBVS, SUB2VS, INTREG, SIGNED_CONST, AVR32_V1),
26212 + SYNTAX_NORMAL_C2(SUBVC, SUBVC, SUBVC, SUB2VC, INTREG, SIGNED_CONST, AVR32_V1),
26213 + SYNTAX_NORMAL_C2(SUBQS, SUBQS, SUBQS, SUB2QS, INTREG, SIGNED_CONST, AVR32_V1),
26214 + SYNTAX_NORMAL_C2(SUBAL, SUBAL, SUBAL, SUB2AL, INTREG, SIGNED_CONST, AVR32_V1),
26215 + SYNTAX_NORMAL_C2(SUBHS, SUBHS, SUBCC, SUB2CC, INTREG, SIGNED_CONST, AVR32_V1),
26216 + SYNTAX_NORMAL_C2(SUBLO, SUBLO, SUBCS, SUB2CS, INTREG, SIGNED_CONST, AVR32_V1),
26217 + SYNTAX_NORMAL2(SUBFEQ, SUBFEQ, SUBFEQ, INTREG, SIGNED_CONST, AVR32_V1),
26218 + SYNTAX_NORMAL2(SUBFNE, SUBFNE, SUBFNE, INTREG, SIGNED_CONST, AVR32_V1),
26219 + SYNTAX_NORMAL2(SUBFCC, SUBFCC, SUBFCC, INTREG, SIGNED_CONST, AVR32_V1),
26220 + SYNTAX_NORMAL2(SUBFCS, SUBFCS, SUBFCS, INTREG, SIGNED_CONST, AVR32_V1),
26221 + SYNTAX_NORMAL2(SUBFGE, SUBFGE, SUBFGE, INTREG, SIGNED_CONST, AVR32_V1),
26222 + SYNTAX_NORMAL2(SUBFLT, SUBFLT, SUBFLT, INTREG, SIGNED_CONST, AVR32_V1),
26223 + SYNTAX_NORMAL2(SUBFMI, SUBFMI, SUBFMI, INTREG, SIGNED_CONST, AVR32_V1),
26224 + SYNTAX_NORMAL2(SUBFPL, SUBFPL, SUBFPL, INTREG, SIGNED_CONST, AVR32_V1),
26225 + SYNTAX_NORMAL2(SUBFLS, SUBFLS, SUBFLS, INTREG, SIGNED_CONST, AVR32_V1),
26226 + SYNTAX_NORMAL2(SUBFGT, SUBFGT, SUBFGT, INTREG, SIGNED_CONST, AVR32_V1),
26227 + SYNTAX_NORMAL2(SUBFLE, SUBFLE, SUBFLE, INTREG, SIGNED_CONST, AVR32_V1),
26228 + SYNTAX_NORMAL2(SUBFHI, SUBFHI, SUBFHI, INTREG, SIGNED_CONST, AVR32_V1),
26229 + SYNTAX_NORMAL2(SUBFVS, SUBFVS, SUBFVS, INTREG, SIGNED_CONST, AVR32_V1),
26230 + SYNTAX_NORMAL2(SUBFVC, SUBFVC, SUBFVC, INTREG, SIGNED_CONST, AVR32_V1),
26231 + SYNTAX_NORMAL2(SUBFQS, SUBFQS, SUBFQS, INTREG, SIGNED_CONST, AVR32_V1),
26232 + SYNTAX_NORMAL2(SUBFAL, SUBFAL, SUBFAL, INTREG, SIGNED_CONST, AVR32_V1),
26233 + SYNTAX_NORMAL2(SUBFHS, SUBFHS, SUBFCC, INTREG, SIGNED_CONST, AVR32_V1),
26234 + SYNTAX_NORMAL2(SUBFLO, SUBFLO, SUBFCS, INTREG, SIGNED_CONST, AVR32_V1),
26235 + SYNTAX_NORMAL3(SUBHH_W, SUBHH_W, SUBHH_W, INTREG, INTREG_HSEL, INTREG_HSEL, AVR32_DSP),
26236 + SYNTAX_NORMAL1(SWAP_B, SWAP_B, SWAP_B, INTREG, AVR32_V1),
26237 + SYNTAX_NORMAL1(SWAP_BH, SWAP_BH, SWAP_BH, INTREG, AVR32_V1),
26238 + SYNTAX_NORMAL1(SWAP_H, SWAP_H, SWAP_H, INTREG, AVR32_V1),
26239 + SYNTAX_NORMAL1(SYNC, SYNC, SYNC, UNSIGNED_CONST, AVR32_V1),
26240 + SYNTAX_NORMAL0(TLBR, TLBR, TLBR, AVR32_V1),
26241 + SYNTAX_NORMAL0(TLBS, TLBS, TLBS, AVR32_V1),
26242 + SYNTAX_NORMAL0(TLBW, TLBW, TLBW, AVR32_V1),
26243 + SYNTAX_NORMAL1(TNBZ, TNBZ, TNBZ, INTREG, AVR32_V1),
26244 + SYNTAX_NORMAL2(TST, TST, TST, INTREG, INTREG, AVR32_V1),
26245 + SYNTAX_NORMAL3(XCHG, XCHG, XCHG, INTREG, INTREG, INTREG, AVR32_V1),
26246 + SYNTAX_NORMAL2(MEMC, MEMC, MEMC, SIGNED_CONST_W, UNSIGNED_NUMBER, AVR32_RMW),
26247 + SYNTAX_NORMAL2(MEMS, MEMS, MEMS, SIGNED_CONST_W, UNSIGNED_NUMBER, AVR32_RMW),
26248 + SYNTAX_NORMAL2(MEMT, MEMT, MEMT, SIGNED_CONST_W, UNSIGNED_NUMBER, AVR32_RMW),
26249 + SYNTAX_FP(FADD, 3),
26250 + SYNTAX_FP(FSUB, 3),
26251 + SYNTAX_FP(FMAC, 3),
26252 + SYNTAX_FP(FNMAC, 3),
26253 + SYNTAX_FP(FMSC, 3),
26254 + SYNTAX_FP(FNMSC, 3),
26255 + SYNTAX_FP(FMUL, 3),
26256 + SYNTAX_FP(FNMUL, 3),
26257 + SYNTAX_FP(FNEG, 2),
26258 + SYNTAX_FP(FABS, 2),
26259 + SYNTAX_FP(FCMP, 2),
26260 + {
26261 + AVR32_SYNTAX_FMOV1_S,
26262 + AVR32_FP, NULL, AVR32_PARSER_ALIAS,
26263 + { .alias = &avr32_alias_table[AVR32_ALIAS_FMOV1_S] },
26264 + &avr32_syntax_table[AVR32_SYNTAX_FMOV2_S],
26265 + 2,
26266 + {
26267 + AVR32_OPERAND_FPREG_S,
26268 + AVR32_OPERAND_FPREG_S,
26269 + },
26270 + },
26271 + {
26272 + AVR32_SYNTAX_FMOV1_D,
26273 + AVR32_FP, NULL, AVR32_PARSER_ALIAS,
26274 + { .alias = &avr32_alias_table[AVR32_ALIAS_FMOV1_D] },
26275 + &avr32_syntax_table[AVR32_SYNTAX_FMOV2_D],
26276 + 2,
26277 + {
26278 + AVR32_OPERAND_FPREG_D,
26279 + AVR32_OPERAND_FPREG_D,
26280 + },
26281 + },
26282 + {
26283 + AVR32_SYNTAX_FMOV2_S,
26284 + AVR32_FP, NULL, AVR32_PARSER_ALIAS,
26285 + { .alias = &avr32_alias_table[AVR32_ALIAS_FMOV2_S] },
26286 + &avr32_syntax_table[AVR32_SYNTAX_FMOV3_S],
26287 + 2,
26288 + {
26289 + AVR32_OPERAND_INTREG,
26290 + AVR32_OPERAND_FPREG_S,
26291 + },
26292 + },
26293 + {
26294 + AVR32_SYNTAX_FMOV2_D,
26295 + AVR32_FP, NULL, AVR32_PARSER_ALIAS,
26296 + { .alias = &avr32_alias_table[AVR32_ALIAS_FMOV2_D] },
26297 + &avr32_syntax_table[AVR32_SYNTAX_FMOV3_D],
26298 + 2,
26299 + {
26300 + AVR32_OPERAND_DWREG,
26301 + AVR32_OPERAND_FPREG_D,
26302 + },
26303 + },
26304 + {
26305 + AVR32_SYNTAX_FMOV3_S,
26306 + AVR32_FP, NULL, AVR32_PARSER_ALIAS,
26307 + { .alias = &avr32_alias_table[AVR32_ALIAS_FMOV3_S] }, NULL,
26308 + 2,
26309 + {
26310 + AVR32_OPERAND_FPREG_S,
26311 + AVR32_OPERAND_INTREG,
26312 + },
26313 + },
26314 + {
26315 + AVR32_SYNTAX_FMOV3_D,
26316 + AVR32_FP, NULL, AVR32_PARSER_ALIAS,
26317 + { .alias = &avr32_alias_table[AVR32_ALIAS_FMOV3_D] }, NULL,
26318 + 2,
26319 + {
26320 + AVR32_OPERAND_FPREG_D,
26321 + AVR32_OPERAND_DWREG,
26322 + },
26323 + },
26324 + {
26325 + AVR32_SYNTAX_FCASTS_D,
26326 + AVR32_FP, NULL, AVR32_PARSER_ALIAS,
26327 + { .alias = &avr32_alias_table[AVR32_ALIAS_FCASTS_D] }, NULL,
26328 + 2,
26329 + {
26330 + AVR32_OPERAND_FPREG_S,
26331 + AVR32_OPERAND_FPREG_D,
26332 + },
26333 + },
26334 + {
26335 + AVR32_SYNTAX_FCASTD_S,
26336 + AVR32_FP, NULL, AVR32_PARSER_ALIAS,
26337 + { .alias = &avr32_alias_table[AVR32_ALIAS_FCASTD_S] }, NULL,
26338 + 2,
26339 + {
26340 + AVR32_OPERAND_FPREG_D,
26341 + AVR32_OPERAND_FPREG_S,
26342 + },
26343 + },
26344 + {
26345 + AVR32_SYNTAX_LDA_W,
26346 + AVR32_V1, NULL, AVR32_PARSER_LDA,
26347 + { NULL }, NULL,
26348 + 2,
26349 + {
26350 + AVR32_OPERAND_INTREG,
26351 + AVR32_OPERAND_SIGNED_CONST,
26352 + },
26353 + },
26354 + {
26355 + AVR32_SYNTAX_CALL,
26356 + AVR32_V1, NULL, AVR32_PARSER_CALL,
26357 + { NULL }, NULL,
26358 + 1,
26359 + {
26360 + AVR32_OPERAND_JMPLABEL,
26361 + },
26362 + },
26363 + {
26364 + AVR32_SYNTAX_PICOSVMAC0,
26365 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSVMAC], AVR32_PARSER_ALIAS,
26366 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSVMAC0] },
26367 + &avr32_syntax_table[AVR32_SYNTAX_PICOSVMAC1], 4,
26368 + {
26369 + AVR32_OPERAND_PICO_OUT0,
26370 + AVR32_OPERAND_PICO_IN,
26371 + AVR32_OPERAND_PICO_IN,
26372 + AVR32_OPERAND_PICO_IN,
26373 + },
26374 + },
26375 + {
26376 + AVR32_SYNTAX_PICOSVMAC1,
26377 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSVMAC], AVR32_PARSER_ALIAS,
26378 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSVMAC1] },
26379 + &avr32_syntax_table[AVR32_SYNTAX_PICOSVMAC2], 4,
26380 + {
26381 + AVR32_OPERAND_PICO_OUT1,
26382 + AVR32_OPERAND_PICO_IN,
26383 + AVR32_OPERAND_PICO_IN,
26384 + AVR32_OPERAND_PICO_IN,
26385 + },
26386 + },
26387 + {
26388 + AVR32_SYNTAX_PICOSVMAC2,
26389 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSVMAC], AVR32_PARSER_ALIAS,
26390 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSVMAC2] },
26391 + &avr32_syntax_table[AVR32_SYNTAX_PICOSVMAC3], 4,
26392 + {
26393 + AVR32_OPERAND_PICO_OUT2,
26394 + AVR32_OPERAND_PICO_IN,
26395 + AVR32_OPERAND_PICO_IN,
26396 + AVR32_OPERAND_PICO_IN,
26397 + },
26398 + },
26399 + {
26400 + AVR32_SYNTAX_PICOSVMAC3,
26401 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSVMAC], AVR32_PARSER_ALIAS,
26402 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSVMAC3] },
26403 + NULL, 4,
26404 + {
26405 + AVR32_OPERAND_PICO_OUT3,
26406 + AVR32_OPERAND_PICO_IN,
26407 + AVR32_OPERAND_PICO_IN,
26408 + AVR32_OPERAND_PICO_IN,
26409 + },
26410 + },
26411 + {
26412 + AVR32_SYNTAX_PICOSVMUL0,
26413 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSVMUL], AVR32_PARSER_ALIAS,
26414 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSVMUL0] },
26415 + &avr32_syntax_table[AVR32_SYNTAX_PICOSVMUL1], 4,
26416 + {
26417 + AVR32_OPERAND_PICO_OUT0,
26418 + AVR32_OPERAND_PICO_IN,
26419 + AVR32_OPERAND_PICO_IN,
26420 + AVR32_OPERAND_PICO_IN,
26421 + },
26422 + },
26423 + {
26424 + AVR32_SYNTAX_PICOSVMUL1,
26425 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSVMUL], AVR32_PARSER_ALIAS,
26426 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSVMUL1] },
26427 + &avr32_syntax_table[AVR32_SYNTAX_PICOSVMUL2], 4,
26428 + {
26429 + AVR32_OPERAND_PICO_OUT1,
26430 + AVR32_OPERAND_PICO_IN,
26431 + AVR32_OPERAND_PICO_IN,
26432 + AVR32_OPERAND_PICO_IN,
26433 + },
26434 + },
26435 + {
26436 + AVR32_SYNTAX_PICOSVMUL2,
26437 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSVMUL], AVR32_PARSER_ALIAS,
26438 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSVMUL2] },
26439 + &avr32_syntax_table[AVR32_SYNTAX_PICOSVMUL3], 4,
26440 + {
26441 + AVR32_OPERAND_PICO_OUT2,
26442 + AVR32_OPERAND_PICO_IN,
26443 + AVR32_OPERAND_PICO_IN,
26444 + AVR32_OPERAND_PICO_IN,
26445 + },
26446 + },
26447 + {
26448 + AVR32_SYNTAX_PICOSVMUL3,
26449 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSVMUL], AVR32_PARSER_ALIAS,
26450 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSVMUL3] },
26451 + NULL, 4,
26452 + {
26453 + AVR32_OPERAND_PICO_OUT3,
26454 + AVR32_OPERAND_PICO_IN,
26455 + AVR32_OPERAND_PICO_IN,
26456 + AVR32_OPERAND_PICO_IN,
26457 + },
26458 + },
26459 + {
26460 + AVR32_SYNTAX_PICOVMAC0,
26461 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOVMAC], AVR32_PARSER_ALIAS,
26462 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOVMAC0] },
26463 + &avr32_syntax_table[AVR32_SYNTAX_PICOVMAC1], 4,
26464 + {
26465 + AVR32_OPERAND_PICO_OUT0,
26466 + AVR32_OPERAND_PICO_IN,
26467 + AVR32_OPERAND_PICO_IN,
26468 + AVR32_OPERAND_PICO_IN,
26469 + },
26470 + },
26471 + {
26472 + AVR32_SYNTAX_PICOVMAC1,
26473 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOVMAC], AVR32_PARSER_ALIAS,
26474 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOVMAC1] },
26475 + &avr32_syntax_table[AVR32_SYNTAX_PICOVMAC2], 4,
26476 + {
26477 + AVR32_OPERAND_PICO_OUT1,
26478 + AVR32_OPERAND_PICO_IN,
26479 + AVR32_OPERAND_PICO_IN,
26480 + AVR32_OPERAND_PICO_IN,
26481 + },
26482 + },
26483 + {
26484 + AVR32_SYNTAX_PICOVMAC2,
26485 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOVMAC], AVR32_PARSER_ALIAS,
26486 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOVMAC2] },
26487 + &avr32_syntax_table[AVR32_SYNTAX_PICOVMAC3], 4,
26488 + {
26489 + AVR32_OPERAND_PICO_OUT2,
26490 + AVR32_OPERAND_PICO_IN,
26491 + AVR32_OPERAND_PICO_IN,
26492 + AVR32_OPERAND_PICO_IN,
26493 + },
26494 + },
26495 + {
26496 + AVR32_SYNTAX_PICOVMAC3,
26497 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOVMAC], AVR32_PARSER_ALIAS,
26498 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOVMAC3] },
26499 + NULL, 4,
26500 + {
26501 + AVR32_OPERAND_PICO_OUT3,
26502 + AVR32_OPERAND_PICO_IN,
26503 + AVR32_OPERAND_PICO_IN,
26504 + AVR32_OPERAND_PICO_IN,
26505 + },
26506 + },
26507 + {
26508 + AVR32_SYNTAX_PICOVMUL0,
26509 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOVMUL], AVR32_PARSER_ALIAS,
26510 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOVMUL0] },
26511 + &avr32_syntax_table[AVR32_SYNTAX_PICOVMUL1], 4,
26512 + {
26513 + AVR32_OPERAND_PICO_OUT0,
26514 + AVR32_OPERAND_PICO_IN,
26515 + AVR32_OPERAND_PICO_IN,
26516 + AVR32_OPERAND_PICO_IN,
26517 + },
26518 + },
26519 + {
26520 + AVR32_SYNTAX_PICOVMUL1,
26521 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOVMUL], AVR32_PARSER_ALIAS,
26522 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOVMUL1] },
26523 + &avr32_syntax_table[AVR32_SYNTAX_PICOVMUL2], 4,
26524 + {
26525 + AVR32_OPERAND_PICO_OUT1,
26526 + AVR32_OPERAND_PICO_IN,
26527 + AVR32_OPERAND_PICO_IN,
26528 + AVR32_OPERAND_PICO_IN,
26529 + },
26530 + },
26531 + {
26532 + AVR32_SYNTAX_PICOVMUL2,
26533 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOVMUL], AVR32_PARSER_ALIAS,
26534 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOVMUL2] },
26535 + &avr32_syntax_table[AVR32_SYNTAX_PICOVMUL3], 4,
26536 + {
26537 + AVR32_OPERAND_PICO_OUT2,
26538 + AVR32_OPERAND_PICO_IN,
26539 + AVR32_OPERAND_PICO_IN,
26540 + AVR32_OPERAND_PICO_IN,
26541 + },
26542 + },
26543 + {
26544 + AVR32_SYNTAX_PICOVMUL3,
26545 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOVMUL], AVR32_PARSER_ALIAS,
26546 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOVMUL3] },
26547 + NULL, 4,
26548 + {
26549 + AVR32_OPERAND_PICO_OUT3,
26550 + AVR32_OPERAND_PICO_IN,
26551 + AVR32_OPERAND_PICO_IN,
26552 + AVR32_OPERAND_PICO_IN,
26553 + },
26554 + },
26555 + {
26556 + AVR32_SYNTAX_PICOLD_D2,
26557 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLD_D], AVR32_PARSER_ALIAS,
26558 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLD_D2] },
26559 + &avr32_syntax_table[AVR32_SYNTAX_PICOLD_D3], 2,
26560 + {
26561 + AVR32_OPERAND_PICO_REG_D,
26562 + AVR32_OPERAND_INTREG_PREDEC,
26563 + },
26564 + },
26565 + {
26566 + AVR32_SYNTAX_PICOLD_D3,
26567 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLD_D], AVR32_PARSER_ALIAS,
26568 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLD_D3] },
26569 + &avr32_syntax_table[AVR32_SYNTAX_PICOLD_D1], 2,
26570 + {
26571 + AVR32_OPERAND_PICO_REG_D,
26572 + AVR32_OPERAND_INTREG_INDEX,
26573 + },
26574 + },
26575 + {
26576 + AVR32_SYNTAX_PICOLD_D1,
26577 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLD_D], AVR32_PARSER_ALIAS,
26578 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLD_D1] },
26579 + NULL, 2,
26580 + {
26581 + AVR32_OPERAND_PICO_REG_D,
26582 + AVR32_OPERAND_INTREG_UDISP_W,
26583 + },
26584 + },
26585 + {
26586 + AVR32_SYNTAX_PICOLD_W2,
26587 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLD_W], AVR32_PARSER_ALIAS,
26588 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLD_W2] },
26589 + &avr32_syntax_table[AVR32_SYNTAX_PICOLD_W3], 2,
26590 + {
26591 + AVR32_OPERAND_PICO_REG_W,
26592 + AVR32_OPERAND_INTREG_PREDEC,
26593 + },
26594 + },
26595 + {
26596 + AVR32_SYNTAX_PICOLD_W3,
26597 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLD_W], AVR32_PARSER_ALIAS,
26598 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLD_W3] },
26599 + &avr32_syntax_table[AVR32_SYNTAX_PICOLD_W1], 2,
26600 + {
26601 + AVR32_OPERAND_PICO_REG_W,
26602 + AVR32_OPERAND_INTREG_INDEX,
26603 + },
26604 + },
26605 + {
26606 + AVR32_SYNTAX_PICOLD_W1,
26607 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLD_W], AVR32_PARSER_ALIAS,
26608 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLD_W1] },
26609 + NULL, 2,
26610 + {
26611 + AVR32_OPERAND_PICO_REG_W,
26612 + AVR32_OPERAND_INTREG_UDISP_W,
26613 + },
26614 + },
26615 + {
26616 + AVR32_SYNTAX_PICOLDM_D,
26617 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLDM_D], AVR32_PARSER_ALIAS,
26618 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLDM_D] },
26619 + &avr32_syntax_table[AVR32_SYNTAX_PICOLDM_D_PU], -2,
26620 + {
26621 + AVR32_OPERAND_INTREG,
26622 + AVR32_OPERAND_PICO_REGLIST_D,
26623 + },
26624 + },
26625 + {
26626 + AVR32_SYNTAX_PICOLDM_D_PU,
26627 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLDM_D], AVR32_PARSER_ALIAS,
26628 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLDM_D_PU] },
26629 + NULL, -2,
26630 + {
26631 + AVR32_OPERAND_INTREG_POSTINC,
26632 + AVR32_OPERAND_PICO_REGLIST_D,
26633 + },
26634 + },
26635 + {
26636 + AVR32_SYNTAX_PICOLDM_W,
26637 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLDM_W], AVR32_PARSER_ALIAS,
26638 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLDM_W] },
26639 + &avr32_syntax_table[AVR32_SYNTAX_PICOLDM_W_PU], -2,
26640 + {
26641 + AVR32_OPERAND_INTREG,
26642 + AVR32_OPERAND_PICO_REGLIST_W,
26643 + },
26644 + },
26645 + {
26646 + AVR32_SYNTAX_PICOLDM_W_PU,
26647 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOLDM_W], AVR32_PARSER_ALIAS,
26648 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOLDM_W_PU] },
26649 + NULL, -2,
26650 + {
26651 + AVR32_OPERAND_INTREG_POSTINC,
26652 + AVR32_OPERAND_PICO_REGLIST_W,
26653 + },
26654 + },
26655 + {
26656 + AVR32_SYNTAX_PICOMV_D1,
26657 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOMV_D], AVR32_PARSER_ALIAS,
26658 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOMV_D1] },
26659 + &avr32_syntax_table[AVR32_SYNTAX_PICOMV_D2], 2,
26660 + {
26661 + AVR32_OPERAND_DWREG,
26662 + AVR32_OPERAND_PICO_REG_D,
26663 + },
26664 + },
26665 + {
26666 + AVR32_SYNTAX_PICOMV_D2,
26667 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOMV_D], AVR32_PARSER_ALIAS,
26668 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOMV_D2] },
26669 + NULL, 2,
26670 + {
26671 + AVR32_OPERAND_PICO_REG_D,
26672 + AVR32_OPERAND_DWREG,
26673 + },
26674 + },
26675 + {
26676 + AVR32_SYNTAX_PICOMV_W1,
26677 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOMV_W], AVR32_PARSER_ALIAS,
26678 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOMV_W1] },
26679 + &avr32_syntax_table[AVR32_SYNTAX_PICOMV_W2], 2,
26680 + {
26681 + AVR32_OPERAND_INTREG,
26682 + AVR32_OPERAND_PICO_REG_W,
26683 + },
26684 + },
26685 + {
26686 + AVR32_SYNTAX_PICOMV_W2,
26687 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOMV_W], AVR32_PARSER_ALIAS,
26688 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOMV_W2] },
26689 + NULL, 2,
26690 + {
26691 + AVR32_OPERAND_PICO_REG_W,
26692 + AVR32_OPERAND_INTREG,
26693 + },
26694 + },
26695 + {
26696 + AVR32_SYNTAX_PICOST_D2,
26697 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOST_D], AVR32_PARSER_ALIAS,
26698 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOST_D2] },
26699 + &avr32_syntax_table[AVR32_SYNTAX_PICOST_D3], 2,
26700 + {
26701 + AVR32_OPERAND_INTREG_POSTINC,
26702 + AVR32_OPERAND_PICO_REG_D,
26703 + },
26704 + },
26705 + {
26706 + AVR32_SYNTAX_PICOST_D3,
26707 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOST_D], AVR32_PARSER_ALIAS,
26708 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOST_D3] },
26709 + &avr32_syntax_table[AVR32_SYNTAX_PICOST_D1], 2,
26710 + {
26711 + AVR32_OPERAND_INTREG_INDEX,
26712 + AVR32_OPERAND_PICO_REG_D,
26713 + },
26714 + },
26715 + {
26716 + AVR32_SYNTAX_PICOST_D1,
26717 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOST_D], AVR32_PARSER_ALIAS,
26718 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOST_D1] },
26719 + NULL, 2,
26720 + {
26721 + AVR32_OPERAND_INTREG_UDISP_W,
26722 + AVR32_OPERAND_PICO_REG_D,
26723 + },
26724 + },
26725 + {
26726 + AVR32_SYNTAX_PICOST_W2,
26727 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOST_W], AVR32_PARSER_ALIAS,
26728 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOST_W2] },
26729 + &avr32_syntax_table[AVR32_SYNTAX_PICOST_W3], 2,
26730 + {
26731 + AVR32_OPERAND_INTREG_POSTINC,
26732 + AVR32_OPERAND_PICO_REG_W,
26733 + },
26734 + },
26735 + {
26736 + AVR32_SYNTAX_PICOST_W3,
26737 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOST_W], AVR32_PARSER_ALIAS,
26738 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOST_W3] },
26739 + &avr32_syntax_table[AVR32_SYNTAX_PICOST_W1], 2,
26740 + {
26741 + AVR32_OPERAND_INTREG_INDEX,
26742 + AVR32_OPERAND_PICO_REG_W,
26743 + },
26744 + },
26745 + {
26746 + AVR32_SYNTAX_PICOST_W1,
26747 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOST_W], AVR32_PARSER_ALIAS,
26748 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOST_W1] },
26749 + NULL, 2,
26750 + {
26751 + AVR32_OPERAND_INTREG_UDISP_W,
26752 + AVR32_OPERAND_PICO_REG_W,
26753 + },
26754 + },
26755 + {
26756 + AVR32_SYNTAX_PICOSTM_D,
26757 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSTM_D], AVR32_PARSER_ALIAS,
26758 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSTM_D] },
26759 + &avr32_syntax_table[AVR32_SYNTAX_PICOSTM_D_PU], -2,
26760 + {
26761 + AVR32_OPERAND_INTREG,
26762 + AVR32_OPERAND_PICO_REGLIST_D,
26763 + },
26764 + },
26765 + {
26766 + AVR32_SYNTAX_PICOSTM_D_PU,
26767 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSTM_D], AVR32_PARSER_ALIAS,
26768 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSTM_D_PU] },
26769 + NULL, -2,
26770 + {
26771 + AVR32_OPERAND_INTREG_PREDEC,
26772 + AVR32_OPERAND_PICO_REGLIST_D,
26773 + },
26774 + },
26775 + {
26776 + AVR32_SYNTAX_PICOSTM_W,
26777 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSTM_W], AVR32_PARSER_ALIAS,
26778 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSTM_W] },
26779 + &avr32_syntax_table[AVR32_SYNTAX_PICOSTM_W_PU], -2,
26780 + {
26781 + AVR32_OPERAND_INTREG,
26782 + AVR32_OPERAND_PICO_REGLIST_W,
26783 + },
26784 + },
26785 + {
26786 + AVR32_SYNTAX_PICOSTM_W_PU,
26787 + AVR32_PICO, &avr32_mnemonic_table[AVR32_MNEMONIC_PICOSTM_W], AVR32_PARSER_ALIAS,
26788 + { .alias = &avr32_alias_table[AVR32_ALIAS_PICOSTM_W_PU] },
26789 + NULL, -2,
26790 + {
26791 + AVR32_OPERAND_INTREG_PREDEC,
26792 + AVR32_OPERAND_PICO_REGLIST_W,
26793 + },
26794 + },
26795 + SYNTAX_NORMAL2(RSUBEQ, RSUBEQ, RSUBEQ, INTREG, SIGNED_CONST, AVR32_V1),
26796 + SYNTAX_NORMAL2(RSUBNE, RSUBNE, RSUBNE, INTREG, SIGNED_CONST, AVR32_V2),
26797 + SYNTAX_NORMAL2(RSUBCC, RSUBCC, RSUBCC, INTREG, SIGNED_CONST, AVR32_V2),
26798 + SYNTAX_NORMAL2(RSUBCS, RSUBCS, RSUBCS, INTREG, SIGNED_CONST, AVR32_V2),
26799 + SYNTAX_NORMAL2(RSUBGE, RSUBGE, RSUBGE, INTREG, SIGNED_CONST, AVR32_V2),
26800 + SYNTAX_NORMAL2(RSUBLT, RSUBLT, RSUBLT, INTREG, SIGNED_CONST, AVR32_V2),
26801 + SYNTAX_NORMAL2(RSUBMI, RSUBMI, RSUBMI, INTREG, SIGNED_CONST, AVR32_V2),
26802 + SYNTAX_NORMAL2(RSUBPL, RSUBPL, RSUBPL, INTREG, SIGNED_CONST, AVR32_V2),
26803 + SYNTAX_NORMAL2(RSUBLS, RSUBLS, RSUBLS, INTREG, SIGNED_CONST, AVR32_V2),
26804 + SYNTAX_NORMAL2(RSUBGT, RSUBGT, RSUBGT, INTREG, SIGNED_CONST, AVR32_V2),
26805 + SYNTAX_NORMAL2(RSUBLE, RSUBLE, RSUBLE, INTREG, SIGNED_CONST, AVR32_V2),
26806 + SYNTAX_NORMAL2(RSUBHI, RSUBHI, RSUBHI, INTREG, SIGNED_CONST, AVR32_V2),
26807 + SYNTAX_NORMAL2(RSUBVS, RSUBVS, RSUBVS, INTREG, SIGNED_CONST, AVR32_V2),
26808 + SYNTAX_NORMAL2(RSUBVC, RSUBVC, RSUBVC, INTREG, SIGNED_CONST, AVR32_V2),
26809 + SYNTAX_NORMAL2(RSUBQS, RSUBQS, RSUBQS, INTREG, SIGNED_CONST, AVR32_V2),
26810 + SYNTAX_NORMAL2(RSUBAL, RSUBAL, RSUBAL, INTREG, SIGNED_CONST, AVR32_V2),
26811 + SYNTAX_NORMAL2(RSUBHS, RSUBHS, RSUBCC, INTREG, SIGNED_CONST, AVR32_V2),
26812 + SYNTAX_NORMAL2(RSUBLO, RSUBLO, RSUBCS, INTREG, SIGNED_CONST, AVR32_V2),
26813 + SYNTAX_NORMAL3(ADDEQ, ADDEQ, ADDEQ, INTREG, INTREG, INTREG, AVR32_V2),
26814 + SYNTAX_NORMAL3(ADDNE, ADDNE, ADDNE, INTREG, INTREG, INTREG, AVR32_V2),
26815 + SYNTAX_NORMAL3(ADDCC, ADDCC, ADDCC, INTREG, INTREG, INTREG, AVR32_V2),
26816 + SYNTAX_NORMAL3(ADDCS, ADDCS, ADDCS, INTREG, INTREG, INTREG, AVR32_V2),
26817 + SYNTAX_NORMAL3(ADDGE, ADDGE, ADDGE, INTREG, INTREG, INTREG, AVR32_V2),
26818 + SYNTAX_NORMAL3(ADDLT, ADDLT, ADDLT, INTREG, INTREG, INTREG, AVR32_V2),
26819 + SYNTAX_NORMAL3(ADDMI, ADDMI, ADDMI, INTREG, INTREG, INTREG, AVR32_V2),
26820 + SYNTAX_NORMAL3(ADDPL, ADDPL, ADDPL, INTREG, INTREG, INTREG, AVR32_V2),
26821 + SYNTAX_NORMAL3(ADDLS, ADDLS, ADDLS, INTREG, INTREG, INTREG, AVR32_V2),
26822 + SYNTAX_NORMAL3(ADDGT, ADDGT, ADDGT, INTREG, INTREG, INTREG, AVR32_V2),
26823 + SYNTAX_NORMAL3(ADDLE, ADDLE, ADDLE, INTREG, INTREG, INTREG, AVR32_V2),
26824 + SYNTAX_NORMAL3(ADDHI, ADDHI, ADDHI, INTREG, INTREG, INTREG, AVR32_V2),
26825 + SYNTAX_NORMAL3(ADDVS, ADDVS, ADDVS, INTREG, INTREG, INTREG, AVR32_V2),
26826 + SYNTAX_NORMAL3(ADDVC, ADDVC, ADDVC, INTREG, INTREG, INTREG, AVR32_V2),
26827 + SYNTAX_NORMAL3(ADDQS, ADDQS, ADDQS, INTREG, INTREG, INTREG, AVR32_V2),
26828 + SYNTAX_NORMAL3(ADDAL, ADDAL, ADDAL, INTREG, INTREG, INTREG, AVR32_V2),
26829 + SYNTAX_NORMAL3(ADDHS, ADDHS, ADDCC, INTREG, INTREG, INTREG, AVR32_V2),
26830 + SYNTAX_NORMAL3(ADDLO, ADDLO, ADDCS, INTREG, INTREG, INTREG, AVR32_V2),
26831 + SYNTAX_NORMAL3(SUB2EQ, SUBEQ, SUB2EQ, INTREG, INTREG, INTREG, AVR32_V2),
26832 + SYNTAX_NORMAL3(SUB2NE, SUBNE, SUB2NE, INTREG, INTREG, INTREG, AVR32_V2),
26833 + SYNTAX_NORMAL3(SUB2CC, SUBCC, SUB2CC, INTREG, INTREG, INTREG, AVR32_V2),
26834 + SYNTAX_NORMAL3(SUB2CS, SUBCS, SUB2CS, INTREG, INTREG, INTREG, AVR32_V2),
26835 + SYNTAX_NORMAL3(SUB2GE, SUBGE, SUB2GE, INTREG, INTREG, INTREG, AVR32_V2),
26836 + SYNTAX_NORMAL3(SUB2LT, SUBLT, SUB2LT, INTREG, INTREG, INTREG, AVR32_V2),
26837 + SYNTAX_NORMAL3(SUB2MI, SUBMI, SUB2MI, INTREG, INTREG, INTREG, AVR32_V2),
26838 + SYNTAX_NORMAL3(SUB2PL, SUBPL, SUB2PL, INTREG, INTREG, INTREG, AVR32_V2),
26839 + SYNTAX_NORMAL3(SUB2LS, SUBLS, SUB2LS, INTREG, INTREG, INTREG, AVR32_V2),
26840 + SYNTAX_NORMAL3(SUB2GT, SUBGT, SUB2GT, INTREG, INTREG, INTREG, AVR32_V2),
26841 + SYNTAX_NORMAL3(SUB2LE, SUBLE, SUB2LE, INTREG, INTREG, INTREG, AVR32_V2),
26842 + SYNTAX_NORMAL3(SUB2HI, SUBHI, SUB2HI, INTREG, INTREG, INTREG, AVR32_V2),
26843 + SYNTAX_NORMAL3(SUB2VS, SUBVS, SUB2VS, INTREG, INTREG, INTREG, AVR32_V2),
26844 + SYNTAX_NORMAL3(SUB2VC, SUBVC, SUB2VC, INTREG, INTREG, INTREG, AVR32_V2),
26845 + SYNTAX_NORMAL3(SUB2QS, SUBQS, SUB2QS, INTREG, INTREG, INTREG, AVR32_V2),
26846 + SYNTAX_NORMAL3(SUB2AL, SUBAL, SUB2AL, INTREG, INTREG, INTREG, AVR32_V2),
26847 + SYNTAX_NORMAL3(SUB2HS, SUBHS, SUB2CC, INTREG, INTREG, INTREG, AVR32_V2),
26848 + SYNTAX_NORMAL3(SUB2LO, SUBLO, SUB2CS, INTREG, INTREG, INTREG, AVR32_V2),
26849 + SYNTAX_NORMAL3(ANDEQ, ANDEQ, ANDEQ, INTREG, INTREG, INTREG, AVR32_V2),
26850 + SYNTAX_NORMAL3(ANDNE, ANDNE, ANDNE, INTREG, INTREG, INTREG, AVR32_V2),
26851 + SYNTAX_NORMAL3(ANDCC, ANDCC, ANDCC, INTREG, INTREG, INTREG, AVR32_V2),
26852 + SYNTAX_NORMAL3(ANDCS, ANDCS, ANDCS, INTREG, INTREG, INTREG, AVR32_V2),
26853 + SYNTAX_NORMAL3(ANDGE, ANDGE, ANDGE, INTREG, INTREG, INTREG, AVR32_V2),
26854 + SYNTAX_NORMAL3(ANDLT, ANDLT, ANDLT, INTREG, INTREG, INTREG, AVR32_V2),
26855 + SYNTAX_NORMAL3(ANDMI, ANDMI, ANDMI, INTREG, INTREG, INTREG, AVR32_V2),
26856 + SYNTAX_NORMAL3(ANDPL, ANDPL, ANDPL, INTREG, INTREG, INTREG, AVR32_V2),
26857 + SYNTAX_NORMAL3(ANDLS, ANDLS, ANDLS, INTREG, INTREG, INTREG, AVR32_V2),
26858 + SYNTAX_NORMAL3(ANDGT, ANDGT, ANDGT, INTREG, INTREG, INTREG, AVR32_V2),
26859 + SYNTAX_NORMAL3(ANDLE, ANDLE, ANDLE, INTREG, INTREG, INTREG, AVR32_V2),
26860 + SYNTAX_NORMAL3(ANDHI, ANDHI, ANDHI, INTREG, INTREG, INTREG, AVR32_V2),
26861 + SYNTAX_NORMAL3(ANDVS, ANDVS, ANDVS, INTREG, INTREG, INTREG, AVR32_V2),
26862 + SYNTAX_NORMAL3(ANDVC, ANDVC, ANDVC, INTREG, INTREG, INTREG, AVR32_V2),
26863 + SYNTAX_NORMAL3(ANDQS, ANDQS, ANDQS, INTREG, INTREG, INTREG, AVR32_V2),
26864 + SYNTAX_NORMAL3(ANDAL, ANDAL, ANDAL, INTREG, INTREG, INTREG, AVR32_V2),
26865 + SYNTAX_NORMAL3(ANDHS, ANDHS, ANDCC, INTREG, INTREG, INTREG, AVR32_V2),
26866 + SYNTAX_NORMAL3(ANDLO, ANDLO, ANDCS, INTREG, INTREG, INTREG, AVR32_V2),
26867 + SYNTAX_NORMAL3(OREQ, OREQ, OREQ, INTREG, INTREG, INTREG, AVR32_V2),
26868 + SYNTAX_NORMAL3(ORNE, ORNE, ORNE, INTREG, INTREG, INTREG, AVR32_V2),
26869 + SYNTAX_NORMAL3(ORCC, ORCC, ORCC, INTREG, INTREG, INTREG, AVR32_V2),
26870 + SYNTAX_NORMAL3(ORCS, ORCS, ORCS, INTREG, INTREG, INTREG, AVR32_V2),
26871 + SYNTAX_NORMAL3(ORGE, ORGE, ORGE, INTREG, INTREG, INTREG, AVR32_V2),
26872 + SYNTAX_NORMAL3(ORLT, ORLT, ORLT, INTREG, INTREG, INTREG, AVR32_V2),
26873 + SYNTAX_NORMAL3(ORMI, ORMI, ORMI, INTREG, INTREG, INTREG, AVR32_V2),
26874 + SYNTAX_NORMAL3(ORPL, ORPL, ORPL, INTREG, INTREG, INTREG, AVR32_V2),
26875 + SYNTAX_NORMAL3(ORLS, ORLS, ORLS, INTREG, INTREG, INTREG, AVR32_V2),
26876 + SYNTAX_NORMAL3(ORGT, ORGT, ORGT, INTREG, INTREG, INTREG, AVR32_V2),
26877 + SYNTAX_NORMAL3(ORLE, ORLE, ORLE, INTREG, INTREG, INTREG, AVR32_V2),
26878 + SYNTAX_NORMAL3(ORHI, ORHI, ORHI, INTREG, INTREG, INTREG, AVR32_V2),
26879 + SYNTAX_NORMAL3(ORVS, ORVS, ORVS, INTREG, INTREG, INTREG, AVR32_V2),
26880 + SYNTAX_NORMAL3(ORVC, ORVC, ORVC, INTREG, INTREG, INTREG, AVR32_V2),
26881 + SYNTAX_NORMAL3(ORQS, ORQS, ORQS, INTREG, INTREG, INTREG, AVR32_V2),
26882 + SYNTAX_NORMAL3(ORAL, ORAL, ORAL, INTREG, INTREG, INTREG, AVR32_V2),
26883 + SYNTAX_NORMAL3(ORHS, ORHS, ORCC, INTREG, INTREG, INTREG, AVR32_V2),
26884 + SYNTAX_NORMAL3(ORLO, ORLO, ORCS, INTREG, INTREG, INTREG, AVR32_V2),
26885 + SYNTAX_NORMAL3(EOREQ, EOREQ, EOREQ, INTREG, INTREG, INTREG, AVR32_V2),
26886 + SYNTAX_NORMAL3(EORNE, EORNE, EORNE, INTREG, INTREG, INTREG, AVR32_V2),
26887 + SYNTAX_NORMAL3(EORCC, EORCC, EORCC, INTREG, INTREG, INTREG, AVR32_V2),
26888 + SYNTAX_NORMAL3(EORCS, EORCS, EORCS, INTREG, INTREG, INTREG, AVR32_V2),
26889 + SYNTAX_NORMAL3(EORGE, EORGE, EORGE, INTREG, INTREG, INTREG, AVR32_V2),
26890 + SYNTAX_NORMAL3(EORLT, EORLT, EORLT, INTREG, INTREG, INTREG, AVR32_V2),
26891 + SYNTAX_NORMAL3(EORMI, EORMI, EORMI, INTREG, INTREG, INTREG, AVR32_V2),
26892 + SYNTAX_NORMAL3(EORPL, EORPL, EORPL, INTREG, INTREG, INTREG, AVR32_V2),
26893 + SYNTAX_NORMAL3(EORLS, EORLS, EORLS, INTREG, INTREG, INTREG, AVR32_V2),
26894 + SYNTAX_NORMAL3(EORGT, EORGT, EORGT, INTREG, INTREG, INTREG, AVR32_V2),
26895 + SYNTAX_NORMAL3(EORLE, EORLE, EORLE, INTREG, INTREG, INTREG, AVR32_V2),
26896 + SYNTAX_NORMAL3(EORHI, EORHI, EORHI, INTREG, INTREG, INTREG, AVR32_V2),
26897 + SYNTAX_NORMAL3(EORVS, EORVS, EORVS, INTREG, INTREG, INTREG, AVR32_V2),
26898 + SYNTAX_NORMAL3(EORVC, EORVC, EORVC, INTREG, INTREG, INTREG, AVR32_V2),
26899 + SYNTAX_NORMAL3(EORQS, EORQS, EORQS, INTREG, INTREG, INTREG, AVR32_V2),
26900 + SYNTAX_NORMAL3(EORAL, EORAL, EORAL, INTREG, INTREG, INTREG, AVR32_V2),
26901 + SYNTAX_NORMAL3(EORHS, EORHS, EORCC, INTREG, INTREG, INTREG, AVR32_V2),
26902 + SYNTAX_NORMAL3(EORLO, EORLO, EORCS, INTREG, INTREG, INTREG, AVR32_V2),
26903 + SYNTAX_NORMAL2(LD_WEQ, LD_WEQ, LD_WEQ, INTREG, INTREG_UDISP_W, AVR32_V2),
26904 + SYNTAX_NORMAL2(LD_WNE, LD_WNE, LD_WNE, INTREG, INTREG_UDISP_W, AVR32_V2),
26905 + SYNTAX_NORMAL2(LD_WCC, LD_WCC, LD_WCC, INTREG, INTREG_UDISP_W, AVR32_V2),
26906 + SYNTAX_NORMAL2(LD_WCS, LD_WCS, LD_WCS, INTREG, INTREG_UDISP_W, AVR32_V2),
26907 + SYNTAX_NORMAL2(LD_WGE, LD_WGE, LD_WGE, INTREG, INTREG_UDISP_W, AVR32_V2),
26908 + SYNTAX_NORMAL2(LD_WLT, LD_WLT, LD_WLT, INTREG, INTREG_UDISP_W, AVR32_V2),
26909 + SYNTAX_NORMAL2(LD_WMI, LD_WMI, LD_WMI, INTREG, INTREG_UDISP_W, AVR32_V2),
26910 + SYNTAX_NORMAL2(LD_WPL, LD_WPL, LD_WPL, INTREG, INTREG_UDISP_W, AVR32_V2),
26911 + SYNTAX_NORMAL2(LD_WLS, LD_WLS, LD_WLS, INTREG, INTREG_UDISP_W, AVR32_V2),
26912 + SYNTAX_NORMAL2(LD_WGT, LD_WGT, LD_WGT, INTREG, INTREG_UDISP_W, AVR32_V2),
26913 + SYNTAX_NORMAL2(LD_WLE, LD_WLE, LD_WLE, INTREG, INTREG_UDISP_W, AVR32_V2),
26914 + SYNTAX_NORMAL2(LD_WHI, LD_WHI, LD_WHI, INTREG, INTREG_UDISP_W, AVR32_V2),
26915 + SYNTAX_NORMAL2(LD_WVS, LD_WVS, LD_WVS, INTREG, INTREG_UDISP_W, AVR32_V2),
26916 + SYNTAX_NORMAL2(LD_WVC, LD_WVC, LD_WVC, INTREG, INTREG_UDISP_W, AVR32_V2),
26917 + SYNTAX_NORMAL2(LD_WQS, LD_WQS, LD_WQS, INTREG, INTREG_UDISP_W, AVR32_V2),
26918 + SYNTAX_NORMAL2(LD_WAL, LD_WAL, LD_WAL, INTREG, INTREG_UDISP_W, AVR32_V2),
26919 + SYNTAX_NORMAL2(LD_WHS, LD_WHS, LD_WCC, INTREG, INTREG_UDISP_W, AVR32_V2),
26920 + SYNTAX_NORMAL2(LD_WLO, LD_WLO, LD_WCS, INTREG, INTREG_UDISP_W, AVR32_V2),
26921 + SYNTAX_NORMAL2(LD_SHEQ, LD_SHEQ, LD_SHEQ, INTREG, INTREG_UDISP_H, AVR32_V2),
26922 + SYNTAX_NORMAL2(LD_SHNE, LD_SHNE, LD_SHNE, INTREG, INTREG_UDISP_H, AVR32_V2),
26923 + SYNTAX_NORMAL2(LD_SHCC, LD_SHCC, LD_SHCC, INTREG, INTREG_UDISP_H, AVR32_V2),
26924 + SYNTAX_NORMAL2(LD_SHCS, LD_SHCS, LD_SHCS, INTREG, INTREG_UDISP_H, AVR32_V2),
26925 + SYNTAX_NORMAL2(LD_SHGE, LD_SHGE, LD_SHGE, INTREG, INTREG_UDISP_H, AVR32_V2),
26926 + SYNTAX_NORMAL2(LD_SHLT, LD_SHLT, LD_SHLT, INTREG, INTREG_UDISP_H, AVR32_V2),
26927 + SYNTAX_NORMAL2(LD_SHMI, LD_SHMI, LD_SHMI, INTREG, INTREG_UDISP_H, AVR32_V2),
26928 + SYNTAX_NORMAL2(LD_SHPL, LD_SHPL, LD_SHPL, INTREG, INTREG_UDISP_H, AVR32_V2),
26929 + SYNTAX_NORMAL2(LD_SHLS, LD_SHLS, LD_SHLS, INTREG, INTREG_UDISP_H, AVR32_V2),
26930 + SYNTAX_NORMAL2(LD_SHGT, LD_SHGT, LD_SHGT, INTREG, INTREG_UDISP_H, AVR32_V2),
26931 + SYNTAX_NORMAL2(LD_SHLE, LD_SHLE, LD_SHLE, INTREG, INTREG_UDISP_H, AVR32_V2),
26932 + SYNTAX_NORMAL2(LD_SHHI, LD_SHHI, LD_SHHI, INTREG, INTREG_UDISP_H, AVR32_V2),
26933 + SYNTAX_NORMAL2(LD_SHVS, LD_SHVS, LD_SHVS, INTREG, INTREG_UDISP_H, AVR32_V2),
26934 + SYNTAX_NORMAL2(LD_SHVC, LD_SHVC, LD_SHVC, INTREG, INTREG_UDISP_H, AVR32_V2),
26935 + SYNTAX_NORMAL2(LD_SHQS, LD_SHQS, LD_SHQS, INTREG, INTREG_UDISP_H, AVR32_V2),
26936 + SYNTAX_NORMAL2(LD_SHAL, LD_SHAL, LD_SHAL, INTREG, INTREG_UDISP_H, AVR32_V2),
26937 + SYNTAX_NORMAL2(LD_SHHS, LD_SHHS, LD_SHCC, INTREG, INTREG_UDISP_H, AVR32_V2),
26938 + SYNTAX_NORMAL2(LD_SHLO, LD_SHLO, LD_SHCS, INTREG, INTREG_UDISP_H, AVR32_V2),
26939 + SYNTAX_NORMAL2(LD_UHEQ, LD_UHEQ, LD_UHEQ, INTREG, INTREG_UDISP_H, AVR32_V2),
26940 + SYNTAX_NORMAL2(LD_UHNE, LD_UHNE, LD_UHNE, INTREG, INTREG_UDISP_H, AVR32_V2),
26941 + SYNTAX_NORMAL2(LD_UHCC, LD_UHCC, LD_UHCC, INTREG, INTREG_UDISP_H, AVR32_V2),
26942 + SYNTAX_NORMAL2(LD_UHCS, LD_UHCS, LD_UHCS, INTREG, INTREG_UDISP_H, AVR32_V2),
26943 + SYNTAX_NORMAL2(LD_UHGE, LD_UHGE, LD_UHGE, INTREG, INTREG_UDISP_H, AVR32_V2),
26944 + SYNTAX_NORMAL2(LD_UHLT, LD_UHLT, LD_UHLT, INTREG, INTREG_UDISP_H, AVR32_V2),
26945 + SYNTAX_NORMAL2(LD_UHMI, LD_UHMI, LD_UHMI, INTREG, INTREG_UDISP_H, AVR32_V2),
26946 + SYNTAX_NORMAL2(LD_UHPL, LD_UHPL, LD_UHPL, INTREG, INTREG_UDISP_H, AVR32_V2),
26947 + SYNTAX_NORMAL2(LD_UHLS, LD_UHLS, LD_UHLS, INTREG, INTREG_UDISP_H, AVR32_V2),
26948 + SYNTAX_NORMAL2(LD_UHGT, LD_UHGT, LD_UHGT, INTREG, INTREG_UDISP_H, AVR32_V2),
26949 + SYNTAX_NORMAL2(LD_UHLE, LD_UHLE, LD_UHLE, INTREG, INTREG_UDISP_H, AVR32_V2),
26950 + SYNTAX_NORMAL2(LD_UHHI, LD_UHHI, LD_UHHI, INTREG, INTREG_UDISP_H, AVR32_V2),
26951 + SYNTAX_NORMAL2(LD_UHVS, LD_UHVS, LD_UHVS, INTREG, INTREG_UDISP_H, AVR32_V2),
26952 + SYNTAX_NORMAL2(LD_UHVC, LD_UHVC, LD_UHVC, INTREG, INTREG_UDISP_H, AVR32_V2),
26953 + SYNTAX_NORMAL2(LD_UHQS, LD_UHQS, LD_UHQS, INTREG, INTREG_UDISP_H, AVR32_V2),
26954 + SYNTAX_NORMAL2(LD_UHAL, LD_UHAL, LD_UHAL, INTREG, INTREG_UDISP_H, AVR32_V2),
26955 + SYNTAX_NORMAL2(LD_UHHS, LD_UHHS, LD_UHCC, INTREG, INTREG_UDISP_H, AVR32_V2),
26956 + SYNTAX_NORMAL2(LD_UHLO, LD_UHLO, LD_UHCS, INTREG, INTREG_UDISP_H, AVR32_V2),
26957 + SYNTAX_NORMAL2(LD_SBEQ, LD_SBEQ, LD_SBEQ, INTREG, INTREG_UDISP, AVR32_V2),
26958 + SYNTAX_NORMAL2(LD_SBNE, LD_SBNE, LD_SBNE, INTREG, INTREG_UDISP, AVR32_V2),
26959 + SYNTAX_NORMAL2(LD_SBCC, LD_SBCC, LD_SBCC, INTREG, INTREG_UDISP, AVR32_V2),
26960 + SYNTAX_NORMAL2(LD_SBCS, LD_SBCS, LD_SBCS, INTREG, INTREG_UDISP, AVR32_V2),
26961 + SYNTAX_NORMAL2(LD_SBGE, LD_SBGE, LD_SBGE, INTREG, INTREG_UDISP, AVR32_V2),
26962 + SYNTAX_NORMAL2(LD_SBLT, LD_SBLT, LD_SBLT, INTREG, INTREG_UDISP, AVR32_V2),
26963 + SYNTAX_NORMAL2(LD_SBMI, LD_SBMI, LD_SBMI, INTREG, INTREG_UDISP, AVR32_V2),
26964 + SYNTAX_NORMAL2(LD_SBPL, LD_SBPL, LD_SBPL, INTREG, INTREG_UDISP, AVR32_V2),
26965 + SYNTAX_NORMAL2(LD_SBLS, LD_SBLS, LD_SBLS, INTREG, INTREG_UDISP, AVR32_V2),
26966 + SYNTAX_NORMAL2(LD_SBGT, LD_SBGT, LD_SBGT, INTREG, INTREG_UDISP, AVR32_V2),
26967 + SYNTAX_NORMAL2(LD_SBLE, LD_SBLE, LD_SBLE, INTREG, INTREG_UDISP, AVR32_V2),
26968 + SYNTAX_NORMAL2(LD_SBHI, LD_SBHI, LD_SBHI, INTREG, INTREG_UDISP, AVR32_V2),
26969 + SYNTAX_NORMAL2(LD_SBVS, LD_SBVS, LD_SBVS, INTREG, INTREG_UDISP, AVR32_V2),
26970 + SYNTAX_NORMAL2(LD_SBVC, LD_SBVC, LD_SBVC, INTREG, INTREG_UDISP, AVR32_V2),
26971 + SYNTAX_NORMAL2(LD_SBQS, LD_SBQS, LD_SBQS, INTREG, INTREG_UDISP, AVR32_V2),
26972 + SYNTAX_NORMAL2(LD_SBAL, LD_SBAL, LD_SBAL, INTREG, INTREG_UDISP, AVR32_V2),
26973 + SYNTAX_NORMAL2(LD_SBHS, LD_SBHS, LD_SBCC, INTREG, INTREG_UDISP, AVR32_V2),
26974 + SYNTAX_NORMAL2(LD_SBLO, LD_SBLO, LD_SBCS, INTREG, INTREG_UDISP, AVR32_V2),
26975 + SYNTAX_NORMAL2(LD_UBEQ, LD_UBEQ, LD_UBEQ, INTREG, INTREG_UDISP, AVR32_V2),
26976 + SYNTAX_NORMAL2(LD_UBNE, LD_UBNE, LD_UBNE, INTREG, INTREG_UDISP, AVR32_V2),
26977 + SYNTAX_NORMAL2(LD_UBCC, LD_UBCC, LD_UBCC, INTREG, INTREG_UDISP, AVR32_V2),
26978 + SYNTAX_NORMAL2(LD_UBCS, LD_UBCS, LD_UBCS, INTREG, INTREG_UDISP, AVR32_V2),
26979 + SYNTAX_NORMAL2(LD_UBGE, LD_UBGE, LD_UBGE, INTREG, INTREG_UDISP, AVR32_V2),
26980 + SYNTAX_NORMAL2(LD_UBLT, LD_UBLT, LD_UBLT, INTREG, INTREG_UDISP, AVR32_V2),
26981 + SYNTAX_NORMAL2(LD_UBMI, LD_UBMI, LD_UBMI, INTREG, INTREG_UDISP, AVR32_V2),
26982 + SYNTAX_NORMAL2(LD_UBPL, LD_UBPL, LD_UBPL, INTREG, INTREG_UDISP, AVR32_V2),
26983 + SYNTAX_NORMAL2(LD_UBLS, LD_UBLS, LD_UBLS, INTREG, INTREG_UDISP, AVR32_V2),
26984 + SYNTAX_NORMAL2(LD_UBGT, LD_UBGT, LD_UBGT, INTREG, INTREG_UDISP, AVR32_V2),
26985 + SYNTAX_NORMAL2(LD_UBLE, LD_UBLE, LD_UBLE, INTREG, INTREG_UDISP, AVR32_V2),
26986 + SYNTAX_NORMAL2(LD_UBHI, LD_UBHI, LD_UBHI, INTREG, INTREG_UDISP, AVR32_V2),
26987 + SYNTAX_NORMAL2(LD_UBVS, LD_UBVS, LD_UBVS, INTREG, INTREG_UDISP, AVR32_V2),
26988 + SYNTAX_NORMAL2(LD_UBVC, LD_UBVC, LD_UBVC, INTREG, INTREG_UDISP, AVR32_V2),
26989 + SYNTAX_NORMAL2(LD_UBQS, LD_UBQS, LD_UBQS, INTREG, INTREG_UDISP, AVR32_V2),
26990 + SYNTAX_NORMAL2(LD_UBAL, LD_UBAL, LD_UBAL, INTREG, INTREG_UDISP, AVR32_V2),
26991 + SYNTAX_NORMAL2(LD_UBHS, LD_UBHS, LD_UBCC, INTREG, INTREG_UDISP, AVR32_V2),
26992 + SYNTAX_NORMAL2(LD_UBLO, LD_UBLO, LD_UBCS, INTREG, INTREG_UDISP, AVR32_V2),
26993 + SYNTAX_NORMAL2(ST_WEQ, ST_WEQ, ST_WEQ, INTREG_UDISP_W, INTREG, AVR32_V2),
26994 + SYNTAX_NORMAL2(ST_WNE, ST_WNE, ST_WNE, INTREG_UDISP_W, INTREG, AVR32_V2),
26995 + SYNTAX_NORMAL2(ST_WCC, ST_WCC, ST_WCC, INTREG_UDISP_W, INTREG, AVR32_V2),
26996 + SYNTAX_NORMAL2(ST_WCS, ST_WCS, ST_WCS, INTREG_UDISP_W, INTREG, AVR32_V2),
26997 + SYNTAX_NORMAL2(ST_WGE, ST_WGE, ST_WGE, INTREG_UDISP_W, INTREG, AVR32_V2),
26998 + SYNTAX_NORMAL2(ST_WLT, ST_WLT, ST_WLT, INTREG_UDISP_W, INTREG, AVR32_V2),
26999 + SYNTAX_NORMAL2(ST_WMI, ST_WMI, ST_WMI, INTREG_UDISP_W, INTREG, AVR32_V2),
27000 + SYNTAX_NORMAL2(ST_WPL, ST_WPL, ST_WPL, INTREG_UDISP_W, INTREG, AVR32_V2),
27001 + SYNTAX_NORMAL2(ST_WLS, ST_WLS, ST_WLS, INTREG_UDISP_W, INTREG, AVR32_V2),
27002 + SYNTAX_NORMAL2(ST_WGT, ST_WGT, ST_WGT, INTREG_UDISP_W, INTREG, AVR32_V2),
27003 + SYNTAX_NORMAL2(ST_WLE, ST_WLE, ST_WLE, INTREG_UDISP_W, INTREG, AVR32_V2),
27004 + SYNTAX_NORMAL2(ST_WHI, ST_WHI, ST_WHI, INTREG_UDISP_W, INTREG, AVR32_V2),
27005 + SYNTAX_NORMAL2(ST_WVS, ST_WVS, ST_WVS, INTREG_UDISP_W, INTREG, AVR32_V2),
27006 + SYNTAX_NORMAL2(ST_WVC, ST_WVC, ST_WVC, INTREG_UDISP_W, INTREG, AVR32_V2),
27007 + SYNTAX_NORMAL2(ST_WQS, ST_WQS, ST_WQS, INTREG_UDISP_W, INTREG, AVR32_V2),
27008 + SYNTAX_NORMAL2(ST_WAL, ST_WAL, ST_WAL, INTREG_UDISP_W, INTREG, AVR32_V2),
27009 + SYNTAX_NORMAL2(ST_WHS, ST_WHS, ST_WCC, INTREG_UDISP_W, INTREG, AVR32_V2),
27010 + SYNTAX_NORMAL2(ST_WLO, ST_WLO, ST_WCS, INTREG_UDISP_W, INTREG, AVR32_V2),
27011 + SYNTAX_NORMAL2(ST_HEQ, ST_HEQ, ST_HEQ, INTREG_UDISP_H, INTREG, AVR32_V2),
27012 + SYNTAX_NORMAL2(ST_HNE, ST_HNE, ST_HNE, INTREG_UDISP_H, INTREG, AVR32_V2),
27013 + SYNTAX_NORMAL2(ST_HCC, ST_HCC, ST_HCC, INTREG_UDISP_H, INTREG, AVR32_V2),
27014 + SYNTAX_NORMAL2(ST_HCS, ST_HCS, ST_HCS, INTREG_UDISP_H, INTREG, AVR32_V2),
27015 + SYNTAX_NORMAL2(ST_HGE, ST_HGE, ST_HGE, INTREG_UDISP_H, INTREG, AVR32_V2),
27016 + SYNTAX_NORMAL2(ST_HLT, ST_HLT, ST_HLT, INTREG_UDISP_H, INTREG, AVR32_V2),
27017 + SYNTAX_NORMAL2(ST_HMI, ST_HMI, ST_HMI, INTREG_UDISP_H, INTREG, AVR32_V2),
27018 + SYNTAX_NORMAL2(ST_HPL, ST_HPL, ST_HPL, INTREG_UDISP_H, INTREG, AVR32_V2),
27019 + SYNTAX_NORMAL2(ST_HLS, ST_HLS, ST_HLS, INTREG_UDISP_H, INTREG, AVR32_V2),
27020 + SYNTAX_NORMAL2(ST_HGT, ST_HGT, ST_HGT, INTREG_UDISP_H, INTREG, AVR32_V2),
27021 + SYNTAX_NORMAL2(ST_HLE, ST_HLE, ST_HLE, INTREG_UDISP_H, INTREG, AVR32_V2),
27022 + SYNTAX_NORMAL2(ST_HHI, ST_HHI, ST_HHI, INTREG_UDISP_H, INTREG, AVR32_V2),
27023 + SYNTAX_NORMAL2(ST_HVS, ST_HVS, ST_HVS, INTREG_UDISP_H, INTREG, AVR32_V2),
27024 + SYNTAX_NORMAL2(ST_HVC, ST_HVC, ST_HVC, INTREG_UDISP_H, INTREG, AVR32_V2),
27025 + SYNTAX_NORMAL2(ST_HQS, ST_HQS, ST_HQS, INTREG_UDISP_H, INTREG, AVR32_V2),
27026 + SYNTAX_NORMAL2(ST_HAL, ST_HAL, ST_HAL, INTREG_UDISP_H, INTREG, AVR32_V2),
27027 + SYNTAX_NORMAL2(ST_HHS, ST_HHS, ST_HCC, INTREG_UDISP_H, INTREG, AVR32_V2),
27028 + SYNTAX_NORMAL2(ST_HLO, ST_HLO, ST_HCS, INTREG_UDISP_H, INTREG, AVR32_V2),
27029 + SYNTAX_NORMAL2(ST_BEQ, ST_BEQ, ST_BEQ, INTREG_UDISP, INTREG, AVR32_V2),
27030 + SYNTAX_NORMAL2(ST_BNE, ST_BNE, ST_BNE, INTREG_UDISP, INTREG, AVR32_V2),
27031 + SYNTAX_NORMAL2(ST_BCC, ST_BCC, ST_BCC, INTREG_UDISP, INTREG, AVR32_V2),
27032 + SYNTAX_NORMAL2(ST_BCS, ST_BCS, ST_BCS, INTREG_UDISP, INTREG, AVR32_V2),
27033 + SYNTAX_NORMAL2(ST_BGE, ST_BGE, ST_BGE, INTREG_UDISP, INTREG, AVR32_V2),
27034 + SYNTAX_NORMAL2(ST_BLT, ST_BLT, ST_BLT, INTREG_UDISP, INTREG, AVR32_V2),
27035 + SYNTAX_NORMAL2(ST_BMI, ST_BMI, ST_BMI, INTREG_UDISP, INTREG, AVR32_V2),
27036 + SYNTAX_NORMAL2(ST_BPL, ST_BPL, ST_BPL, INTREG_UDISP, INTREG, AVR32_V2),
27037 + SYNTAX_NORMAL2(ST_BLS, ST_BLS, ST_BLS, INTREG_UDISP, INTREG, AVR32_V2),
27038 + SYNTAX_NORMAL2(ST_BGT, ST_BGT, ST_BGT, INTREG_UDISP, INTREG, AVR32_V2),
27039 + SYNTAX_NORMAL2(ST_BLE, ST_BLE, ST_BLE, INTREG_UDISP, INTREG, AVR32_V2),
27040 + SYNTAX_NORMAL2(ST_BHI, ST_BHI, ST_BHI, INTREG_UDISP, INTREG, AVR32_V2),
27041 + SYNTAX_NORMAL2(ST_BVS, ST_BVS, ST_BVS, INTREG_UDISP, INTREG, AVR32_V2),
27042 + SYNTAX_NORMAL2(ST_BVC, ST_BVC, ST_BVC, INTREG_UDISP, INTREG, AVR32_V2),
27043 + SYNTAX_NORMAL2(ST_BQS, ST_BQS, ST_BQS, INTREG_UDISP, INTREG, AVR32_V2),
27044 + SYNTAX_NORMAL2(ST_BAL, ST_BAL, ST_BAL, INTREG_UDISP, INTREG, AVR32_V2),
27045 + SYNTAX_NORMAL2(ST_BHS, ST_BHS, ST_BCC, INTREG_UDISP, INTREG, AVR32_V2),
27046 + SYNTAX_NORMAL2(ST_BLO, ST_BLO, ST_BCS, INTREG_UDISP, INTREG, AVR32_V2),
27047 + SYNTAX_NORMAL2(MOVH, MOVH, MOVH, INTREG, UNSIGNED_CONST, AVR32_V2),
27048 +
27049 + };
27050 +
27051 +#define NORMAL_MNEMONIC(name, syntax, str) \
27052 + { \
27053 + AVR32_MNEMONIC_##name, str, \
27054 + &avr32_syntax_table[AVR32_SYNTAX_##syntax], \
27055 + }
27056 +#define FP_MNEMONIC(name, syntax, str) \
27057 + NORMAL_MNEMONIC(name##_S, syntax##_S, str ".s"), \
27058 + NORMAL_MNEMONIC(name##_D, syntax##_D, str ".d")
27059 +
27060 +const struct avr32_mnemonic avr32_mnemonic_table[] =
27061 + {
27062 + NORMAL_MNEMONIC(ABS, ABS, "abs"),
27063 + NORMAL_MNEMONIC(ACALL, ACALL, "acall"),
27064 + NORMAL_MNEMONIC(ACR, ACR, "acr"),
27065 + NORMAL_MNEMONIC(ADC, ADC, "adc"),
27066 + NORMAL_MNEMONIC(ADD, ADD1, "add"),
27067 + NORMAL_MNEMONIC(ADDABS, ADDABS, "addabs"),
27068 + NORMAL_MNEMONIC(ADDHH_W, ADDHH_W, "addhh.w"),
27069 + NORMAL_MNEMONIC(AND, AND1, "and"),
27070 + NORMAL_MNEMONIC(ANDH, ANDH, "andh"),
27071 + NORMAL_MNEMONIC(ANDL, ANDL, "andl"),
27072 + NORMAL_MNEMONIC(ANDN, ANDN, "andn"),
27073 + NORMAL_MNEMONIC(ASR, ASR1, "asr"),
27074 + NORMAL_MNEMONIC(BFEXTS, BFEXTS, "bfexts"),
27075 + NORMAL_MNEMONIC(BFEXTU, BFEXTU, "bfextu"),
27076 + NORMAL_MNEMONIC(BFINS, BFINS, "bfins"),
27077 + NORMAL_MNEMONIC(BLD, BLD, "bld"),
27078 + NORMAL_MNEMONIC(BREQ, BREQ1, "breq"),
27079 + NORMAL_MNEMONIC(BRNE, BRNE1, "brne"),
27080 + NORMAL_MNEMONIC(BRCC, BRCC1, "brcc"),
27081 + NORMAL_MNEMONIC(BRCS, BRCS1, "brcs"),
27082 + NORMAL_MNEMONIC(BRGE, BRGE1, "brge"),
27083 + NORMAL_MNEMONIC(BRLT, BRLT1, "brlt"),
27084 + NORMAL_MNEMONIC(BRMI, BRMI1, "brmi"),
27085 + NORMAL_MNEMONIC(BRPL, BRPL1, "brpl"),
27086 + NORMAL_MNEMONIC(BRHS, BRHS1, "brhs"),
27087 + NORMAL_MNEMONIC(BRLO, BRLO1, "brlo"),
27088 + NORMAL_MNEMONIC(BRLS, BRLS, "brls"),
27089 + NORMAL_MNEMONIC(BRGT, BRGT, "brgt"),
27090 + NORMAL_MNEMONIC(BRLE, BRLE, "brle"),
27091 + NORMAL_MNEMONIC(BRHI, BRHI, "brhi"),
27092 + NORMAL_MNEMONIC(BRVS, BRVS, "brvs"),
27093 + NORMAL_MNEMONIC(BRVC, BRVC, "brvc"),
27094 + NORMAL_MNEMONIC(BRQS, BRQS, "brqs"),
27095 + NORMAL_MNEMONIC(BRAL, BRAL, "bral"),
27096 + NORMAL_MNEMONIC(BREAKPOINT, BREAKPOINT, "breakpoint"),
27097 + NORMAL_MNEMONIC(BREV, BREV, "brev"),
27098 + NORMAL_MNEMONIC(BST, BST, "bst"),
27099 + NORMAL_MNEMONIC(CACHE, CACHE, "cache"),
27100 + NORMAL_MNEMONIC(CASTS_B, CASTS_B, "casts.b"),
27101 + NORMAL_MNEMONIC(CASTS_H, CASTS_H, "casts.h"),
27102 + NORMAL_MNEMONIC(CASTU_B, CASTU_B, "castu.b"),
27103 + NORMAL_MNEMONIC(CASTU_H, CASTU_H, "castu.h"),
27104 + NORMAL_MNEMONIC(CBR, CBR, "cbr"),
27105 + NORMAL_MNEMONIC(CLZ, CLZ, "clz"),
27106 + NORMAL_MNEMONIC(COM, COM, "com"),
27107 + NORMAL_MNEMONIC(COP, COP, "cop"),
27108 + NORMAL_MNEMONIC(CP_B, CP_B, "cp.b"),
27109 + NORMAL_MNEMONIC(CP_H, CP_H, "cp.h"),
27110 + NORMAL_MNEMONIC(CP_W, CP_W1, "cp.w"),
27111 + NORMAL_MNEMONIC(CP, CP_W1, "cp"),
27112 + NORMAL_MNEMONIC(CPC, CPC1, "cpc"),
27113 + NORMAL_MNEMONIC(CSRF, CSRF, "csrf"),
27114 + NORMAL_MNEMONIC(CSRFCZ, CSRFCZ, "csrfcz"),
27115 + NORMAL_MNEMONIC(DIVS, DIVS, "divs"),
27116 + NORMAL_MNEMONIC(DIVU, DIVU, "divu"),
27117 + NORMAL_MNEMONIC(EOR, EOR1, "eor"),
27118 + NORMAL_MNEMONIC(EORL, EORL, "eorl"),
27119 + NORMAL_MNEMONIC(EORH, EORH, "eorh"),
27120 + NORMAL_MNEMONIC(FRS, FRS, "frs"),
27121 + NORMAL_MNEMONIC(ICALL, ICALL, "icall"),
27122 + NORMAL_MNEMONIC(INCJOSP, INCJOSP, "incjosp"),
27123 + NORMAL_MNEMONIC(LD_D, LD_D1, "ld.d"),
27124 + NORMAL_MNEMONIC(LD_SB, LD_SB2, "ld.sb"),
27125 + NORMAL_MNEMONIC(LD_UB, LD_UB1, "ld.ub"),
27126 + NORMAL_MNEMONIC(LD_SH, LD_SH1, "ld.sh"),
27127 + NORMAL_MNEMONIC(LD_UH, LD_UH1, "ld.uh"),
27128 + NORMAL_MNEMONIC(LD_W, LD_W1, "ld.w"),
27129 + NORMAL_MNEMONIC(LDC_D, LDC_D3, "ldc.d"),
27130 + NORMAL_MNEMONIC(LDC_W, LDC_W3, "ldc.w"),
27131 + NORMAL_MNEMONIC(LDC0_D, LDC0_D, "ldc0.d"),
27132 + NORMAL_MNEMONIC(LDC0_W, LDC0_W, "ldc0.w"),
27133 + NORMAL_MNEMONIC(LDCM_D, LDCM_D, "ldcm.d"),
27134 + NORMAL_MNEMONIC(LDCM_W, LDCM_W, "ldcm.w"),
27135 + NORMAL_MNEMONIC(LDDPC, LDDPC, "lddpc"),
27136 + NORMAL_MNEMONIC(LDDSP, LDDSP, "lddsp"),
27137 + NORMAL_MNEMONIC(LDINS_B, LDINS_B, "ldins.b"),
27138 + NORMAL_MNEMONIC(LDINS_H, LDINS_H, "ldins.h"),
27139 + NORMAL_MNEMONIC(LDM, LDM, "ldm"),
27140 + NORMAL_MNEMONIC(LDMTS, LDMTS, "ldmts"),
27141 + NORMAL_MNEMONIC(LDSWP_SH, LDSWP_SH, "ldswp.sh"),
27142 + NORMAL_MNEMONIC(LDSWP_UH, LDSWP_UH, "ldswp.uh"),
27143 + NORMAL_MNEMONIC(LDSWP_W, LDSWP_W, "ldswp.w"),
27144 + NORMAL_MNEMONIC(LSL, LSL1, "lsl"),
27145 + NORMAL_MNEMONIC(LSR, LSR1, "lsr"),
27146 + NORMAL_MNEMONIC(MAC, MAC, "mac"),
27147 + NORMAL_MNEMONIC(MACHH_D, MACHH_D, "machh.d"),
27148 + NORMAL_MNEMONIC(MACHH_W, MACHH_W, "machh.w"),
27149 + NORMAL_MNEMONIC(MACS_D, MACS_D, "macs.d"),
27150 + NORMAL_MNEMONIC(MACSATHH_W, MACSATHH_W, "macsathh.w"),
27151 + NORMAL_MNEMONIC(MACU_D, MACUD, "macu.d"),
27152 + NORMAL_MNEMONIC(MACWH_D, MACWH_D, "macwh.d"),
27153 + NORMAL_MNEMONIC(MAX, MAX, "max"),
27154 + NORMAL_MNEMONIC(MCALL, MCALL, "mcall"),
27155 + NORMAL_MNEMONIC(MFDR, MFDR, "mfdr"),
27156 + NORMAL_MNEMONIC(MFSR, MFSR, "mfsr"),
27157 + NORMAL_MNEMONIC(MIN, MIN, "min"),
27158 + NORMAL_MNEMONIC(MOV, MOV3, "mov"),
27159 + NORMAL_MNEMONIC(MOVEQ, MOVEQ1, "moveq"),
27160 + NORMAL_MNEMONIC(MOVNE, MOVNE1, "movne"),
27161 + NORMAL_MNEMONIC(MOVCC, MOVCC1, "movcc"),
27162 + NORMAL_MNEMONIC(MOVCS, MOVCS1, "movcs"),
27163 + NORMAL_MNEMONIC(MOVGE, MOVGE1, "movge"),
27164 + NORMAL_MNEMONIC(MOVLT, MOVLT1, "movlt"),
27165 + NORMAL_MNEMONIC(MOVMI, MOVMI1, "movmi"),
27166 + NORMAL_MNEMONIC(MOVPL, MOVPL1, "movpl"),
27167 + NORMAL_MNEMONIC(MOVLS, MOVLS1, "movls"),
27168 + NORMAL_MNEMONIC(MOVGT, MOVGT1, "movgt"),
27169 + NORMAL_MNEMONIC(MOVLE, MOVLE1, "movle"),
27170 + NORMAL_MNEMONIC(MOVHI, MOVHI1, "movhi"),
27171 + NORMAL_MNEMONIC(MOVVS, MOVVS1, "movvs"),
27172 + NORMAL_MNEMONIC(MOVVC, MOVVC1, "movvc"),
27173 + NORMAL_MNEMONIC(MOVQS, MOVQS1, "movqs"),
27174 + NORMAL_MNEMONIC(MOVAL, MOVAL1, "moval"),
27175 + NORMAL_MNEMONIC(MOVHS, MOVHS1, "movhs"),
27176 + NORMAL_MNEMONIC(MOVLO, MOVLO1, "movlo"),
27177 + NORMAL_MNEMONIC(MTDR, MTDR, "mtdr"),
27178 + NORMAL_MNEMONIC(MTSR, MTSR, "mtsr"),
27179 + NORMAL_MNEMONIC(MUL, MUL1, "mul"),
27180 + NORMAL_MNEMONIC(MULHH_W, MULHH_W, "mulhh.w"),
27181 + NORMAL_MNEMONIC(MULNHH_W, MULNHH_W, "mulnhh.w"),
27182 + NORMAL_MNEMONIC(MULNWH_D, MULNWH_D, "mulnwh.d"),
27183 + NORMAL_MNEMONIC(MULS_D, MULSD, "muls.d"),
27184 + NORMAL_MNEMONIC(MULSATHH_H, MULSATHH_H, "mulsathh.h"),
27185 + NORMAL_MNEMONIC(MULSATHH_W, MULSATHH_W, "mulsathh.w"),
27186 + NORMAL_MNEMONIC(MULSATRNDHH_H, MULSATRNDHH_H, "mulsatrndhh.h"),
27187 + NORMAL_MNEMONIC(MULSATRNDWH_W, MULSATRNDWH_W, "mulsatrndwh.w"),
27188 + NORMAL_MNEMONIC(MULSATWH_W, MULSATWH_W, "mulsatwh.w"),
27189 + NORMAL_MNEMONIC(MULU_D, MULU_D, "mulu.d"),
27190 + NORMAL_MNEMONIC(MULWH_D, MULWH_D, "mulwh.d"),
27191 + NORMAL_MNEMONIC(MUSFR, MUSFR, "musfr"),
27192 + NORMAL_MNEMONIC(MUSTR, MUSTR, "mustr"),
27193 + NORMAL_MNEMONIC(MVCR_D, MVCR_D, "mvcr.d"),
27194 + NORMAL_MNEMONIC(MVCR_W, MVCR_W, "mvcr.w"),
27195 + NORMAL_MNEMONIC(MVRC_D, MVRC_D, "mvrc.d"),
27196 + NORMAL_MNEMONIC(MVRC_W, MVRC_W, "mvrc.w"),
27197 + NORMAL_MNEMONIC(NEG, NEG, "neg"),
27198 + NORMAL_MNEMONIC(NOP, NOP, "nop"),
27199 + NORMAL_MNEMONIC(OR, OR1, "or"),
27200 + NORMAL_MNEMONIC(ORH, ORH, "orh"),
27201 + NORMAL_MNEMONIC(ORL, ORL, "orl"),
27202 + NORMAL_MNEMONIC(PABS_SB, PABS_SB, "pabs.sb"),
27203 + NORMAL_MNEMONIC(PABS_SH, PABS_SH, "pabs.sh"),
27204 + NORMAL_MNEMONIC(PACKSH_SB, PACKSH_SB, "packsh.sb"),
27205 + NORMAL_MNEMONIC(PACKSH_UB, PACKSH_UB, "packsh.ub"),
27206 + NORMAL_MNEMONIC(PACKW_SH, PACKW_SH, "packw.sh"),
27207 + NORMAL_MNEMONIC(PADD_B, PADD_B, "padd.b"),
27208 + NORMAL_MNEMONIC(PADD_H, PADD_H, "padd.h"),
27209 + NORMAL_MNEMONIC(PADDH_SH, PADDH_SH, "paddh.sh"),
27210 + NORMAL_MNEMONIC(PADDH_UB, PADDH_UB, "paddh.ub"),
27211 + NORMAL_MNEMONIC(PADDS_SB, PADDS_SB, "padds.sb"),
27212 + NORMAL_MNEMONIC(PADDS_SH, PADDS_SH, "padds.sh"),
27213 + NORMAL_MNEMONIC(PADDS_UB, PADDS_UB, "padds.ub"),
27214 + NORMAL_MNEMONIC(PADDS_UH, PADDS_UH, "padds.uh"),
27215 + NORMAL_MNEMONIC(PADDSUB_H, PADDSUB_H, "paddsub.h"),
27216 + NORMAL_MNEMONIC(PADDSUBH_SH, PADDSUBH_SH, "paddsubh.sh"),
27217 + NORMAL_MNEMONIC(PADDSUBS_SH, PADDSUBS_SH, "paddsubs.sh"),
27218 + NORMAL_MNEMONIC(PADDSUBS_UH, PADDSUBS_UH, "paddsubs.uh"),
27219 + NORMAL_MNEMONIC(PADDX_H, PADDX_H, "paddx.h"),
27220 + NORMAL_MNEMONIC(PADDXH_SH, PADDXH_SH, "paddxh.sh"),
27221 + NORMAL_MNEMONIC(PADDXS_SH, PADDXS_SH, "paddxs.sh"),
27222 + NORMAL_MNEMONIC(PADDXS_UH, PADDXS_UH, "paddxs.uh"),
27223 + NORMAL_MNEMONIC(PASR_B, PASR_B, "pasr.b"),
27224 + NORMAL_MNEMONIC(PASR_H, PASR_H, "pasr.h"),
27225 + NORMAL_MNEMONIC(PAVG_SH, PAVG_SH, "pavg.sh"),
27226 + NORMAL_MNEMONIC(PAVG_UB, PAVG_UB, "pavg.ub"),
27227 + NORMAL_MNEMONIC(PLSL_B, PLSL_B, "plsl.b"),
27228 + NORMAL_MNEMONIC(PLSL_H, PLSL_H, "plsl.h"),
27229 + NORMAL_MNEMONIC(PLSR_B, PLSR_B, "plsr.b"),
27230 + NORMAL_MNEMONIC(PLSR_H, PLSR_H, "plsr.h"),
27231 + NORMAL_MNEMONIC(PMAX_SH, PMAX_SH, "pmax.sh"),
27232 + NORMAL_MNEMONIC(PMAX_UB, PMAX_UB, "pmax.ub"),
27233 + NORMAL_MNEMONIC(PMIN_SH, PMIN_SH, "pmin.sh"),
27234 + NORMAL_MNEMONIC(PMIN_UB, PMIN_UB, "pmin.ub"),
27235 + NORMAL_MNEMONIC(POPJC, POPJC, "popjc"),
27236 + NORMAL_MNEMONIC(POPM, POPM, "popm"),
27237 + NORMAL_MNEMONIC(PREF, PREF, "pref"),
27238 + NORMAL_MNEMONIC(PSAD, PSAD, "psad"),
27239 + NORMAL_MNEMONIC(PSUB_B, PSUB_B, "psub.b"),
27240 + NORMAL_MNEMONIC(PSUB_H, PSUB_H, "psub.h"),
27241 + NORMAL_MNEMONIC(PSUBADD_H, PSUBADD_H, "psubadd.h"),
27242 + NORMAL_MNEMONIC(PSUBADDH_SH, PSUBADDH_SH, "psubaddh.sh"),
27243 + NORMAL_MNEMONIC(PSUBADDS_SH, PSUBADDS_SH, "psubadds.sh"),
27244 + NORMAL_MNEMONIC(PSUBADDS_UH, PSUBADDS_UH, "psubadds.uh"),
27245 + NORMAL_MNEMONIC(PSUBH_SH, PSUBH_SH, "psubh.sh"),
27246 + NORMAL_MNEMONIC(PSUBH_UB, PSUBH_UB, "psubh.ub"),
27247 + NORMAL_MNEMONIC(PSUBS_SB, PSUBS_SB, "psubs.sb"),
27248 + NORMAL_MNEMONIC(PSUBS_SH, PSUBS_SH, "psubs.sh"),
27249 + NORMAL_MNEMONIC(PSUBS_UB, PSUBS_UB, "psubs.ub"),
27250 + NORMAL_MNEMONIC(PSUBS_UH, PSUBS_UH, "psubs.uh"),
27251 + NORMAL_MNEMONIC(PSUBX_H, PSUBX_H, "psubx.h"),
27252 + NORMAL_MNEMONIC(PSUBXH_SH, PSUBXH_SH, "psubxh.sh"),
27253 + NORMAL_MNEMONIC(PSUBXS_SH, PSUBXS_SH, "psubxs.sh"),
27254 + NORMAL_MNEMONIC(PSUBXS_UH, PSUBXS_UH, "psubxs.uh"),
27255 + NORMAL_MNEMONIC(PUNPCKSB_H, PUNPCKSB_H, "punpcksb.h"),
27256 + NORMAL_MNEMONIC(PUNPCKUB_H, PUNPCKUB_H, "punpckub.h"),
27257 + NORMAL_MNEMONIC(PUSHJC, PUSHJC, "pushjc"),
27258 + NORMAL_MNEMONIC(PUSHM, PUSHM, "pushm"),
27259 + NORMAL_MNEMONIC(RCALL, RCALL1, "rcall"),
27260 + NORMAL_MNEMONIC(RETEQ, RETEQ, "reteq"),
27261 + NORMAL_MNEMONIC(RETNE, RETNE, "retne"),
27262 + NORMAL_MNEMONIC(RETCC, RETCC, "retcc"),
27263 + NORMAL_MNEMONIC(RETCS, RETCS, "retcs"),
27264 + NORMAL_MNEMONIC(RETGE, RETGE, "retge"),
27265 + NORMAL_MNEMONIC(RETLT, RETLT, "retlt"),
27266 + NORMAL_MNEMONIC(RETMI, RETMI, "retmi"),
27267 + NORMAL_MNEMONIC(RETPL, RETPL, "retpl"),
27268 + NORMAL_MNEMONIC(RETLS, RETLS, "retls"),
27269 + NORMAL_MNEMONIC(RETGT, RETGT, "retgt"),
27270 + NORMAL_MNEMONIC(RETLE, RETLE, "retle"),
27271 + NORMAL_MNEMONIC(RETHI, RETHI, "rethi"),
27272 + NORMAL_MNEMONIC(RETVS, RETVS, "retvs"),
27273 + NORMAL_MNEMONIC(RETVC, RETVC, "retvc"),
27274 + NORMAL_MNEMONIC(RETQS, RETQS, "retqs"),
27275 + NORMAL_MNEMONIC(RETAL, RETAL, "retal"),
27276 + NORMAL_MNEMONIC(RETHS, RETHS, "reths"),
27277 + NORMAL_MNEMONIC(RETLO, RETLO, "retlo"),
27278 + NORMAL_MNEMONIC(RET, RETAL, "ret"),
27279 + NORMAL_MNEMONIC(RETD, RETD, "retd"),
27280 + NORMAL_MNEMONIC(RETE, RETE, "rete"),
27281 + NORMAL_MNEMONIC(RETJ, RETJ, "retj"),
27282 + NORMAL_MNEMONIC(RETS, RETS, "rets"),
27283 + NORMAL_MNEMONIC(RJMP, RJMP, "rjmp"),
27284 + NORMAL_MNEMONIC(ROL, ROL, "rol"),
27285 + NORMAL_MNEMONIC(ROR, ROR, "ror"),
27286 + NORMAL_MNEMONIC(RSUB, RSUB1, "rsub"),
27287 + NORMAL_MNEMONIC(SATADD_H, SATADD_H, "satadd.h"),
27288 + NORMAL_MNEMONIC(SATADD_W, SATADD_W, "satadd.w"),
27289 + NORMAL_MNEMONIC(SATRNDS, SATRNDS, "satrnds"),
27290 + NORMAL_MNEMONIC(SATRNDU, SATRNDU, "satrndu"),
27291 + NORMAL_MNEMONIC(SATS, SATS, "sats"),
27292 + NORMAL_MNEMONIC(SATSUB_H, SATSUB_H, "satsub.h"),
27293 + NORMAL_MNEMONIC(SATSUB_W, SATSUB_W1, "satsub.w"),
27294 + NORMAL_MNEMONIC(SATU, SATU, "satu"),
27295 + NORMAL_MNEMONIC(SBC, SBC, "sbc"),
27296 + NORMAL_MNEMONIC(SBR, SBR, "sbr"),
27297 + NORMAL_MNEMONIC(SCALL, SCALL, "scall"),
27298 + NORMAL_MNEMONIC(SCR, SCR, "scr"),
27299 + NORMAL_MNEMONIC(SLEEP, SLEEP, "sleep"),
27300 + NORMAL_MNEMONIC(SREQ, SREQ, "sreq"),
27301 + NORMAL_MNEMONIC(SRNE, SRNE, "srne"),
27302 + NORMAL_MNEMONIC(SRCC, SRCC, "srcc"),
27303 + NORMAL_MNEMONIC(SRCS, SRCS, "srcs"),
27304 + NORMAL_MNEMONIC(SRGE, SRGE, "srge"),
27305 + NORMAL_MNEMONIC(SRLT, SRLT, "srlt"),
27306 + NORMAL_MNEMONIC(SRMI, SRMI, "srmi"),
27307 + NORMAL_MNEMONIC(SRPL, SRPL, "srpl"),
27308 + NORMAL_MNEMONIC(SRLS, SRLS, "srls"),
27309 + NORMAL_MNEMONIC(SRGT, SRGT, "srgt"),
27310 + NORMAL_MNEMONIC(SRLE, SRLE, "srle"),
27311 + NORMAL_MNEMONIC(SRHI, SRHI, "srhi"),
27312 + NORMAL_MNEMONIC(SRVS, SRVS, "srvs"),
27313 + NORMAL_MNEMONIC(SRVC, SRVC, "srvc"),
27314 + NORMAL_MNEMONIC(SRQS, SRQS, "srqs"),
27315 + NORMAL_MNEMONIC(SRAL, SRAL, "sral"),
27316 + NORMAL_MNEMONIC(SRHS, SRHS, "srhs"),
27317 + NORMAL_MNEMONIC(SRLO, SRLO, "srlo"),
27318 + NORMAL_MNEMONIC(SSRF, SSRF, "ssrf"),
27319 + NORMAL_MNEMONIC(ST_B, ST_B1, "st.b"),
27320 + NORMAL_MNEMONIC(ST_D, ST_D1, "st.d"),
27321 + NORMAL_MNEMONIC(ST_H, ST_H1, "st.h"),
27322 + NORMAL_MNEMONIC(ST_W, ST_W1, "st.w"),
27323 + NORMAL_MNEMONIC(STC_D, STC_D3, "stc.d"),
27324 + NORMAL_MNEMONIC(STC_W, STC_W3, "stc.w"),
27325 + NORMAL_MNEMONIC(STC0_D, STC0_D, "stc0.d"),
27326 + NORMAL_MNEMONIC(STC0_W, STC0_W, "stc0.w"),
27327 + NORMAL_MNEMONIC(STCM_D, STCM_D, "stcm.d"),
27328 + NORMAL_MNEMONIC(STCM_W, STCM_W, "stcm.w"),
27329 + NORMAL_MNEMONIC(STCOND, STCOND, "stcond"),
27330 + NORMAL_MNEMONIC(STDSP, STDSP, "stdsp"),
27331 + NORMAL_MNEMONIC(STHH_W, STHH_W2, "sthh.w"),
27332 + NORMAL_MNEMONIC(STM, STM, "stm"),
27333 + NORMAL_MNEMONIC(STMTS, STMTS, "stmts"),
27334 + NORMAL_MNEMONIC(STSWP_H, STSWP_H, "stswp.h"),
27335 + NORMAL_MNEMONIC(STSWP_W, STSWP_W, "stswp.w"),
27336 + NORMAL_MNEMONIC(SUB, SUB1, "sub"),
27337 + NORMAL_MNEMONIC(SUBEQ, SUBEQ, "subeq"),
27338 + NORMAL_MNEMONIC(SUBNE, SUBNE, "subne"),
27339 + NORMAL_MNEMONIC(SUBCC, SUBCC, "subcc"),
27340 + NORMAL_MNEMONIC(SUBCS, SUBCS, "subcs"),
27341 + NORMAL_MNEMONIC(SUBGE, SUBGE, "subge"),
27342 + NORMAL_MNEMONIC(SUBLT, SUBLT, "sublt"),
27343 + NORMAL_MNEMONIC(SUBMI, SUBMI, "submi"),
27344 + NORMAL_MNEMONIC(SUBPL, SUBPL, "subpl"),
27345 + NORMAL_MNEMONIC(SUBLS, SUBLS, "subls"),
27346 + NORMAL_MNEMONIC(SUBGT, SUBGT, "subgt"),
27347 + NORMAL_MNEMONIC(SUBLE, SUBLE, "suble"),
27348 + NORMAL_MNEMONIC(SUBHI, SUBHI, "subhi"),
27349 + NORMAL_MNEMONIC(SUBVS, SUBVS, "subvs"),
27350 + NORMAL_MNEMONIC(SUBVC, SUBVC, "subvc"),
27351 + NORMAL_MNEMONIC(SUBQS, SUBQS, "subqs"),
27352 + NORMAL_MNEMONIC(SUBAL, SUBAL, "subal"),
27353 + NORMAL_MNEMONIC(SUBHS, SUBHS, "subhs"),
27354 + NORMAL_MNEMONIC(SUBLO, SUBLO, "sublo"),
27355 + NORMAL_MNEMONIC(SUBFEQ, SUBFEQ, "subfeq"),
27356 + NORMAL_MNEMONIC(SUBFNE, SUBFNE, "subfne"),
27357 + NORMAL_MNEMONIC(SUBFCC, SUBFCC, "subfcc"),
27358 + NORMAL_MNEMONIC(SUBFCS, SUBFCS, "subfcs"),
27359 + NORMAL_MNEMONIC(SUBFGE, SUBFGE, "subfge"),
27360 + NORMAL_MNEMONIC(SUBFLT, SUBFLT, "subflt"),
27361 + NORMAL_MNEMONIC(SUBFMI, SUBFMI, "subfmi"),
27362 + NORMAL_MNEMONIC(SUBFPL, SUBFPL, "subfpl"),
27363 + NORMAL_MNEMONIC(SUBFLS, SUBFLS, "subfls"),
27364 + NORMAL_MNEMONIC(SUBFGT, SUBFGT, "subfgt"),
27365 + NORMAL_MNEMONIC(SUBFLE, SUBFLE, "subfle"),
27366 + NORMAL_MNEMONIC(SUBFHI, SUBFHI, "subfhi"),
27367 + NORMAL_MNEMONIC(SUBFVS, SUBFVS, "subfvs"),
27368 + NORMAL_MNEMONIC(SUBFVC, SUBFVC, "subfvc"),
27369 + NORMAL_MNEMONIC(SUBFQS, SUBFQS, "subfqs"),
27370 + NORMAL_MNEMONIC(SUBFAL, SUBFAL, "subfal"),
27371 + NORMAL_MNEMONIC(SUBFHS, SUBFHS, "subfhs"),
27372 + NORMAL_MNEMONIC(SUBFLO, SUBFLO, "subflo"),
27373 + NORMAL_MNEMONIC(SUBHH_W, SUBHH_W, "subhh.w"),
27374 + NORMAL_MNEMONIC(SWAP_B, SWAP_B, "swap.b"),
27375 + NORMAL_MNEMONIC(SWAP_BH, SWAP_BH, "swap.bh"),
27376 + NORMAL_MNEMONIC(SWAP_H, SWAP_H, "swap.h"),
27377 + NORMAL_MNEMONIC(SYNC, SYNC, "sync"),
27378 + NORMAL_MNEMONIC(TLBR, TLBR, "tlbr"),
27379 + NORMAL_MNEMONIC(TLBS, TLBS, "tlbs"),
27380 + NORMAL_MNEMONIC(TLBW, TLBW, "tlbw"),
27381 + NORMAL_MNEMONIC(TNBZ, TNBZ, "tnbz"),
27382 + NORMAL_MNEMONIC(TST, TST, "tst"),
27383 + NORMAL_MNEMONIC(XCHG, XCHG, "xchg"),
27384 + NORMAL_MNEMONIC(MEMC, MEMC, "memc"),
27385 + NORMAL_MNEMONIC(MEMS, MEMS, "mems"),
27386 + NORMAL_MNEMONIC(MEMT, MEMT, "memt"),
27387 + FP_MNEMONIC(FADD, FADD, "fadd"),
27388 + FP_MNEMONIC(FSUB, FSUB, "fsub"),
27389 + FP_MNEMONIC(FMAC, FMAC, "fmac"),
27390 + FP_MNEMONIC(FNMAC, FNMAC, "fnmac"),
27391 + FP_MNEMONIC(FMSC, FMSC, "fmsc"),
27392 + FP_MNEMONIC(FNMSC, FNMSC, "fnmsc"),
27393 + FP_MNEMONIC(FMUL, FMUL, "fmul"),
27394 + FP_MNEMONIC(FNMUL, FNMUL, "fnmul"),
27395 + FP_MNEMONIC(FNEG, FNEG, "fneg"),
27396 + FP_MNEMONIC(FABS, FABS, "fabs"),
27397 + FP_MNEMONIC(FCMP, FCMP, "fcmp"),
27398 + FP_MNEMONIC(FMOV, FMOV1, "fmov"),
27399 + NORMAL_MNEMONIC(FCASTS_D, FCASTS_D, "fcasts.d"),
27400 + NORMAL_MNEMONIC(FCASTD_S, FCASTD_S, "fcastd.s"),
27401 + NORMAL_MNEMONIC(LDA_W, LDA_W, "lda.w"),
27402 + NORMAL_MNEMONIC(CALL, CALL, "call"),
27403 + NORMAL_MNEMONIC(PICOSVMAC, PICOSVMAC0, "picosvmac"),
27404 + NORMAL_MNEMONIC(PICOSVMUL, PICOSVMUL0, "picosvmul"),
27405 + NORMAL_MNEMONIC(PICOVMAC, PICOVMAC0, "picovmac"),
27406 + NORMAL_MNEMONIC(PICOVMUL, PICOVMUL0, "picovmul"),
27407 + NORMAL_MNEMONIC(PICOLD_D, PICOLD_D2, "picold.d"),
27408 + NORMAL_MNEMONIC(PICOLD_W, PICOLD_W2, "picold.w"),
27409 + NORMAL_MNEMONIC(PICOLDM_D, PICOLDM_D, "picoldm.d"),
27410 + NORMAL_MNEMONIC(PICOLDM_W, PICOLDM_W, "picoldm.w"),
27411 + NORMAL_MNEMONIC(PICOMV_D, PICOMV_D1, "picomv.d"),
27412 + NORMAL_MNEMONIC(PICOMV_W, PICOMV_W1, "picomv.w"),
27413 + NORMAL_MNEMONIC(PICOST_D, PICOST_D2, "picost.d"),
27414 + NORMAL_MNEMONIC(PICOST_W, PICOST_W2, "picost.w"),
27415 + NORMAL_MNEMONIC(PICOSTM_D, PICOSTM_D, "picostm.d"),
27416 + NORMAL_MNEMONIC(PICOSTM_W, PICOSTM_W, "picostm.w"),
27417 + NORMAL_MNEMONIC(RSUBEQ, RSUBEQ, "rsubeq"),
27418 + NORMAL_MNEMONIC(RSUBNE, RSUBNE, "rsubne"),
27419 + NORMAL_MNEMONIC(RSUBCC, RSUBCC, "rsubcc"),
27420 + NORMAL_MNEMONIC(RSUBCS, RSUBCS, "rsubcs"),
27421 + NORMAL_MNEMONIC(RSUBGE, RSUBGE, "rsubge"),
27422 + NORMAL_MNEMONIC(RSUBLT, RSUBLT, "rsublt"),
27423 + NORMAL_MNEMONIC(RSUBMI, RSUBMI, "rsubmi"),
27424 + NORMAL_MNEMONIC(RSUBPL, RSUBPL, "rsubpl"),
27425 + NORMAL_MNEMONIC(RSUBLS, RSUBLS, "rsubls"),
27426 + NORMAL_MNEMONIC(RSUBGT, RSUBGT, "rsubgt"),
27427 + NORMAL_MNEMONIC(RSUBLE, RSUBLE, "rsuble"),
27428 + NORMAL_MNEMONIC(RSUBHI, RSUBHI, "rsubhi"),
27429 + NORMAL_MNEMONIC(RSUBVS, RSUBVS, "rsubvs"),
27430 + NORMAL_MNEMONIC(RSUBVC, RSUBVC, "rsubvc"),
27431 + NORMAL_MNEMONIC(RSUBQS, RSUBQS, "rsubqs"),
27432 + NORMAL_MNEMONIC(RSUBAL, RSUBAL, "rsubal"),
27433 + NORMAL_MNEMONIC(RSUBHS, RSUBHS, "rsubhs"),
27434 + NORMAL_MNEMONIC(RSUBLO, RSUBLO, "rsublo"),
27435 + NORMAL_MNEMONIC(ADDEQ, ADDEQ, "addeq"),
27436 + NORMAL_MNEMONIC(ADDNE, ADDNE, "addne"),
27437 + NORMAL_MNEMONIC(ADDCC, ADDCC, "addcc"),
27438 + NORMAL_MNEMONIC(ADDCS, ADDCS, "addcs"),
27439 + NORMAL_MNEMONIC(ADDGE, ADDGE, "addge"),
27440 + NORMAL_MNEMONIC(ADDLT, ADDLT, "addlt"),
27441 + NORMAL_MNEMONIC(ADDMI, ADDMI, "addmi"),
27442 + NORMAL_MNEMONIC(ADDPL, ADDPL, "addpl"),
27443 + NORMAL_MNEMONIC(ADDLS, ADDLS, "addls"),
27444 + NORMAL_MNEMONIC(ADDGT, ADDGT, "addgt"),
27445 + NORMAL_MNEMONIC(ADDLE, ADDLE, "addle"),
27446 + NORMAL_MNEMONIC(ADDHI, ADDHI, "addhi"),
27447 + NORMAL_MNEMONIC(ADDVS, ADDVS, "addvs"),
27448 + NORMAL_MNEMONIC(ADDVC, ADDVC, "addvc"),
27449 + NORMAL_MNEMONIC(ADDQS, ADDQS, "addqs"),
27450 + NORMAL_MNEMONIC(ADDAL, ADDAL, "addal"),
27451 + NORMAL_MNEMONIC(ADDHS, ADDHS, "addhs"),
27452 + NORMAL_MNEMONIC(ADDLO, ADDLO, "addlo"),
27453 + NORMAL_MNEMONIC(ANDEQ, ANDEQ, "andeq"),
27454 + NORMAL_MNEMONIC(ANDNE, ANDNE, "andne"),
27455 + NORMAL_MNEMONIC(ANDCC, ANDCC, "andcc"),
27456 + NORMAL_MNEMONIC(ANDCS, ANDCS, "andcs"),
27457 + NORMAL_MNEMONIC(ANDGE, ANDGE, "andge"),
27458 + NORMAL_MNEMONIC(ANDLT, ANDLT, "andlt"),
27459 + NORMAL_MNEMONIC(ANDMI, ANDMI, "andmi"),
27460 + NORMAL_MNEMONIC(ANDPL, ANDPL, "andpl"),
27461 + NORMAL_MNEMONIC(ANDLS, ANDLS, "andls"),
27462 + NORMAL_MNEMONIC(ANDGT, ANDGT, "andgt"),
27463 + NORMAL_MNEMONIC(ANDLE, ANDLE, "andle"),
27464 + NORMAL_MNEMONIC(ANDHI, ANDHI, "andhi"),
27465 + NORMAL_MNEMONIC(ANDVS, ANDVS, "andvs"),
27466 + NORMAL_MNEMONIC(ANDVC, ANDVC, "andvc"),
27467 + NORMAL_MNEMONIC(ANDQS, ANDQS, "andqs"),
27468 + NORMAL_MNEMONIC(ANDAL, ANDAL, "andal"),
27469 + NORMAL_MNEMONIC(ANDHS, ANDHS, "andhs"),
27470 + NORMAL_MNEMONIC(ANDLO, ANDLO, "andlo"),
27471 + NORMAL_MNEMONIC(OREQ, OREQ, "oreq"),
27472 + NORMAL_MNEMONIC(ORNE, ORNE, "orne"),
27473 + NORMAL_MNEMONIC(ORCC, ORCC, "orcc"),
27474 + NORMAL_MNEMONIC(ORCS, ORCS, "orcs"),
27475 + NORMAL_MNEMONIC(ORGE, ORGE, "orge"),
27476 + NORMAL_MNEMONIC(ORLT, ORLT, "orlt"),
27477 + NORMAL_MNEMONIC(ORMI, ORMI, "ormi"),
27478 + NORMAL_MNEMONIC(ORPL, ORPL, "orpl"),
27479 + NORMAL_MNEMONIC(ORLS, ORLS, "orls"),
27480 + NORMAL_MNEMONIC(ORGT, ORGT, "orgt"),
27481 + NORMAL_MNEMONIC(ORLE, ORLE, "orle"),
27482 + NORMAL_MNEMONIC(ORHI, ORHI, "orhi"),
27483 + NORMAL_MNEMONIC(ORVS, ORVS, "orvs"),
27484 + NORMAL_MNEMONIC(ORVC, ORVC, "orvc"),
27485 + NORMAL_MNEMONIC(ORQS, ORQS, "orqs"),
27486 + NORMAL_MNEMONIC(ORAL, ORAL, "oral"),
27487 + NORMAL_MNEMONIC(ORHS, ORHS, "orhs"),
27488 + NORMAL_MNEMONIC(ORLO, ORLO, "orlo"),
27489 + NORMAL_MNEMONIC(EOREQ, EOREQ, "eoreq"),
27490 + NORMAL_MNEMONIC(EORNE, EORNE, "eorne"),
27491 + NORMAL_MNEMONIC(EORCC, EORCC, "eorcc"),
27492 + NORMAL_MNEMONIC(EORCS, EORCS, "eorcs"),
27493 + NORMAL_MNEMONIC(EORGE, EORGE, "eorge"),
27494 + NORMAL_MNEMONIC(EORLT, EORLT, "eorlt"),
27495 + NORMAL_MNEMONIC(EORMI, EORMI, "eormi"),
27496 + NORMAL_MNEMONIC(EORPL, EORPL, "eorpl"),
27497 + NORMAL_MNEMONIC(EORLS, EORLS, "eorls"),
27498 + NORMAL_MNEMONIC(EORGT, EORGT, "eorgt"),
27499 + NORMAL_MNEMONIC(EORLE, EORLE, "eorle"),
27500 + NORMAL_MNEMONIC(EORHI, EORHI, "eorhi"),
27501 + NORMAL_MNEMONIC(EORVS, EORVS, "eorvs"),
27502 + NORMAL_MNEMONIC(EORVC, EORVC, "eorvc"),
27503 + NORMAL_MNEMONIC(EORQS, EORQS, "eorqs"),
27504 + NORMAL_MNEMONIC(EORAL, EORAL, "eoral"),
27505 + NORMAL_MNEMONIC(EORHS, EORHS, "eorhs"),
27506 + NORMAL_MNEMONIC(EORLO, EORLO, "eorlo"),
27507 + NORMAL_MNEMONIC(LD_WEQ, LD_WEQ, "ld.weq"),
27508 + NORMAL_MNEMONIC(LD_WNE, LD_WNE, "ld.wne"),
27509 + NORMAL_MNEMONIC(LD_WCC, LD_WCC, "ld.wcc"),
27510 + NORMAL_MNEMONIC(LD_WCS, LD_WCS, "ld.wcs"),
27511 + NORMAL_MNEMONIC(LD_WGE, LD_WGE, "ld.wge"),
27512 + NORMAL_MNEMONIC(LD_WLT, LD_WLT, "ld.wlt"),
27513 + NORMAL_MNEMONIC(LD_WMI, LD_WMI, "ld.wmi"),
27514 + NORMAL_MNEMONIC(LD_WPL, LD_WPL, "ld.wpl"),
27515 + NORMAL_MNEMONIC(LD_WLS, LD_WLS, "ld.wls"),
27516 + NORMAL_MNEMONIC(LD_WGT, LD_WGT, "ld.wgt"),
27517 + NORMAL_MNEMONIC(LD_WLE, LD_WLE, "ld.wle"),
27518 + NORMAL_MNEMONIC(LD_WHI, LD_WHI, "ld.whi"),
27519 + NORMAL_MNEMONIC(LD_WVS, LD_WVS, "ld.wvs"),
27520 + NORMAL_MNEMONIC(LD_WVC, LD_WVC, "ld.wvc"),
27521 + NORMAL_MNEMONIC(LD_WQS, LD_WQS, "ld.wqs"),
27522 + NORMAL_MNEMONIC(LD_WAL, LD_WAL, "ld.wal"),
27523 + NORMAL_MNEMONIC(LD_WHS, LD_WHS, "ld.whs"),
27524 + NORMAL_MNEMONIC(LD_WLO, LD_WLO, "ld.wlo"),
27525 + NORMAL_MNEMONIC(LD_SHEQ, LD_SHEQ, "ld.sheq"),
27526 + NORMAL_MNEMONIC(LD_SHNE, LD_SHNE, "ld.shne"),
27527 + NORMAL_MNEMONIC(LD_SHCC, LD_SHCC, "ld.shcc"),
27528 + NORMAL_MNEMONIC(LD_SHCS, LD_SHCS, "ld.shcs"),
27529 + NORMAL_MNEMONIC(LD_SHGE, LD_SHGE, "ld.shge"),
27530 + NORMAL_MNEMONIC(LD_SHLT, LD_SHLT, "ld.shlt"),
27531 + NORMAL_MNEMONIC(LD_SHMI, LD_SHMI, "ld.shmi"),
27532 + NORMAL_MNEMONIC(LD_SHPL, LD_SHPL, "ld.shpl"),
27533 + NORMAL_MNEMONIC(LD_SHLS, LD_SHLS, "ld.shls"),
27534 + NORMAL_MNEMONIC(LD_SHGT, LD_SHGT, "ld.shgt"),
27535 + NORMAL_MNEMONIC(LD_SHLE, LD_SHLE, "ld.shle"),
27536 + NORMAL_MNEMONIC(LD_SHHI, LD_SHHI, "ld.shhi"),
27537 + NORMAL_MNEMONIC(LD_SHVS, LD_SHVS, "ld.shvs"),
27538 + NORMAL_MNEMONIC(LD_SHVC, LD_SHVC, "ld.shvc"),
27539 + NORMAL_MNEMONIC(LD_SHQS, LD_SHQS, "ld.shqs"),
27540 + NORMAL_MNEMONIC(LD_SHAL, LD_SHAL, "ld.shal"),
27541 + NORMAL_MNEMONIC(LD_SHHS, LD_SHHS, "ld.shhs"),
27542 + NORMAL_MNEMONIC(LD_SHLO, LD_SHLO, "ld.shlo"),
27543 + NORMAL_MNEMONIC(LD_UHEQ, LD_UHEQ, "ld.uheq"),
27544 + NORMAL_MNEMONIC(LD_UHNE, LD_UHNE, "ld.uhne"),
27545 + NORMAL_MNEMONIC(LD_UHCC, LD_UHCC, "ld.uhcc"),
27546 + NORMAL_MNEMONIC(LD_UHCS, LD_UHCS, "ld.uhcs"),
27547 + NORMAL_MNEMONIC(LD_UHGE, LD_UHGE, "ld.uhge"),
27548 + NORMAL_MNEMONIC(LD_UHLT, LD_UHLT, "ld.uhlt"),
27549 + NORMAL_MNEMONIC(LD_UHMI, LD_UHMI, "ld.uhmi"),
27550 + NORMAL_MNEMONIC(LD_UHPL, LD_UHPL, "ld.uhpl"),
27551 + NORMAL_MNEMONIC(LD_UHLS, LD_UHLS, "ld.uhls"),
27552 + NORMAL_MNEMONIC(LD_UHGT, LD_UHGT, "ld.uhgt"),
27553 + NORMAL_MNEMONIC(LD_UHLE, LD_UHLE, "ld.uhle"),
27554 + NORMAL_MNEMONIC(LD_UHHI, LD_UHHI, "ld.uhhi"),
27555 + NORMAL_MNEMONIC(LD_UHVS, LD_UHVS, "ld.uhvs"),
27556 + NORMAL_MNEMONIC(LD_UHVC, LD_UHVC, "ld.uhvc"),
27557 + NORMAL_MNEMONIC(LD_UHQS, LD_UHQS, "ld.uhqs"),
27558 + NORMAL_MNEMONIC(LD_UHAL, LD_UHAL, "ld.uhal"),
27559 + NORMAL_MNEMONIC(LD_UHHS, LD_UHHS, "ld.uhhs"),
27560 + NORMAL_MNEMONIC(LD_UHLO, LD_UHLO, "ld.uhlo"),
27561 + NORMAL_MNEMONIC(LD_SBEQ, LD_SBEQ, "ld.sbeq"),
27562 + NORMAL_MNEMONIC(LD_SBNE, LD_SBNE, "ld.sbne"),
27563 + NORMAL_MNEMONIC(LD_SBCC, LD_SBCC, "ld.sbcc"),
27564 + NORMAL_MNEMONIC(LD_SBCS, LD_SBCS, "ld.sbcs"),
27565 + NORMAL_MNEMONIC(LD_SBGE, LD_SBGE, "ld.sbge"),
27566 + NORMAL_MNEMONIC(LD_SBLT, LD_SBLT, "ld.sblt"),
27567 + NORMAL_MNEMONIC(LD_SBMI, LD_SBMI, "ld.sbmi"),
27568 + NORMAL_MNEMONIC(LD_SBPL, LD_SBPL, "ld.sbpl"),
27569 + NORMAL_MNEMONIC(LD_SBLS, LD_SBLS, "ld.sbls"),
27570 + NORMAL_MNEMONIC(LD_SBGT, LD_SBGT, "ld.sbgt"),
27571 + NORMAL_MNEMONIC(LD_SBLE, LD_SBLE, "ld.sble"),
27572 + NORMAL_MNEMONIC(LD_SBHI, LD_SBHI, "ld.sbhi"),
27573 + NORMAL_MNEMONIC(LD_SBVS, LD_SBVS, "ld.sbvs"),
27574 + NORMAL_MNEMONIC(LD_SBVC, LD_SBVC, "ld.sbvc"),
27575 + NORMAL_MNEMONIC(LD_SBQS, LD_SBQS, "ld.sbqs"),
27576 + NORMAL_MNEMONIC(LD_SBAL, LD_SBAL, "ld.sbal"),
27577 + NORMAL_MNEMONIC(LD_SBHS, LD_SBHS, "ld.sbhs"),
27578 + NORMAL_MNEMONIC(LD_SBLO, LD_SBLO, "ld.sblo"),
27579 + NORMAL_MNEMONIC(LD_UBEQ, LD_UBEQ, "ld.ubeq"),
27580 + NORMAL_MNEMONIC(LD_UBNE, LD_UBNE, "ld.ubne"),
27581 + NORMAL_MNEMONIC(LD_UBCC, LD_UBCC, "ld.ubcc"),
27582 + NORMAL_MNEMONIC(LD_UBCS, LD_UBCS, "ld.ubcs"),
27583 + NORMAL_MNEMONIC(LD_UBGE, LD_UBGE, "ld.ubge"),
27584 + NORMAL_MNEMONIC(LD_UBLT, LD_UBLT, "ld.ublt"),
27585 + NORMAL_MNEMONIC(LD_UBMI, LD_UBMI, "ld.ubmi"),
27586 + NORMAL_MNEMONIC(LD_UBPL, LD_UBPL, "ld.ubpl"),
27587 + NORMAL_MNEMONIC(LD_UBLS, LD_UBLS, "ld.ubls"),
27588 + NORMAL_MNEMONIC(LD_UBGT, LD_UBGT, "ld.ubgt"),
27589 + NORMAL_MNEMONIC(LD_UBLE, LD_UBLE, "ld.uble"),
27590 + NORMAL_MNEMONIC(LD_UBHI, LD_UBHI, "ld.ubhi"),
27591 + NORMAL_MNEMONIC(LD_UBVS, LD_UBVS, "ld.ubvs"),
27592 + NORMAL_MNEMONIC(LD_UBVC, LD_UBVC, "ld.ubvc"),
27593 + NORMAL_MNEMONIC(LD_UBQS, LD_UBQS, "ld.ubqs"),
27594 + NORMAL_MNEMONIC(LD_UBAL, LD_UBAL, "ld.ubal"),
27595 + NORMAL_MNEMONIC(LD_UBHS, LD_UBHS, "ld.ubhs"),
27596 + NORMAL_MNEMONIC(LD_UBLO, LD_UBLO, "ld.ublo"),
27597 + NORMAL_MNEMONIC(ST_WEQ, ST_WEQ, "st.weq"),
27598 + NORMAL_MNEMONIC(ST_WNE, ST_WNE, "st.wne"),
27599 + NORMAL_MNEMONIC(ST_WCC, ST_WCC, "st.wcc"),
27600 + NORMAL_MNEMONIC(ST_WCS, ST_WCS, "st.wcs"),
27601 + NORMAL_MNEMONIC(ST_WGE, ST_WGE, "st.wge"),
27602 + NORMAL_MNEMONIC(ST_WLT, ST_WLT, "st.wlt"),
27603 + NORMAL_MNEMONIC(ST_WMI, ST_WMI, "st.wmi"),
27604 + NORMAL_MNEMONIC(ST_WPL, ST_WPL, "st.wpl"),
27605 + NORMAL_MNEMONIC(ST_WLS, ST_WLS, "st.wls"),
27606 + NORMAL_MNEMONIC(ST_WGT, ST_WGT, "st.wgt"),
27607 + NORMAL_MNEMONIC(ST_WLE, ST_WLE, "st.wle"),
27608 + NORMAL_MNEMONIC(ST_WHI, ST_WHI, "st.whi"),
27609 + NORMAL_MNEMONIC(ST_WVS, ST_WVS, "st.wvs"),
27610 + NORMAL_MNEMONIC(ST_WVC, ST_WVC, "st.wvc"),
27611 + NORMAL_MNEMONIC(ST_WQS, ST_WQS, "st.wqs"),
27612 + NORMAL_MNEMONIC(ST_WAL, ST_WAL, "st.wal"),
27613 + NORMAL_MNEMONIC(ST_WHS, ST_WHS, "st.whs"),
27614 + NORMAL_MNEMONIC(ST_WLO, ST_WLO, "st.wlo"),
27615 + NORMAL_MNEMONIC(ST_HEQ, ST_HEQ, "st.heq"),
27616 + NORMAL_MNEMONIC(ST_HNE, ST_HNE, "st.hne"),
27617 + NORMAL_MNEMONIC(ST_HCC, ST_HCC, "st.hcc"),
27618 + NORMAL_MNEMONIC(ST_HCS, ST_HCS, "st.hcs"),
27619 + NORMAL_MNEMONIC(ST_HGE, ST_HGE, "st.hge"),
27620 + NORMAL_MNEMONIC(ST_HLT, ST_HLT, "st.hlt"),
27621 + NORMAL_MNEMONIC(ST_HMI, ST_HMI, "st.hmi"),
27622 + NORMAL_MNEMONIC(ST_HPL, ST_HPL, "st.hpl"),
27623 + NORMAL_MNEMONIC(ST_HLS, ST_HLS, "st.hls"),
27624 + NORMAL_MNEMONIC(ST_HGT, ST_HGT, "st.hgt"),
27625 + NORMAL_MNEMONIC(ST_HLE, ST_HLE, "st.hle"),
27626 + NORMAL_MNEMONIC(ST_HHI, ST_HHI, "st.hhi"),
27627 + NORMAL_MNEMONIC(ST_HVS, ST_HVS, "st.hvs"),
27628 + NORMAL_MNEMONIC(ST_HVC, ST_HVC, "st.hvc"),
27629 + NORMAL_MNEMONIC(ST_HQS, ST_HQS, "st.hqs"),
27630 + NORMAL_MNEMONIC(ST_HAL, ST_HAL, "st.hal"),
27631 + NORMAL_MNEMONIC(ST_HHS, ST_HHS, "st.hhs"),
27632 + NORMAL_MNEMONIC(ST_HLO, ST_HLO, "st.hlo"),
27633 + NORMAL_MNEMONIC(ST_BEQ, ST_BEQ, "st.beq"),
27634 + NORMAL_MNEMONIC(ST_BNE, ST_BNE, "st.bne"),
27635 + NORMAL_MNEMONIC(ST_BCC, ST_BCC, "st.bcc"),
27636 + NORMAL_MNEMONIC(ST_BCS, ST_BCS, "st.bcs"),
27637 + NORMAL_MNEMONIC(ST_BGE, ST_BGE, "st.bge"),
27638 + NORMAL_MNEMONIC(ST_BLT, ST_BLT, "st.blt"),
27639 + NORMAL_MNEMONIC(ST_BMI, ST_BMI, "st.bmi"),
27640 + NORMAL_MNEMONIC(ST_BPL, ST_BPL, "st.bpl"),
27641 + NORMAL_MNEMONIC(ST_BLS, ST_BLS, "st.bls"),
27642 + NORMAL_MNEMONIC(ST_BGT, ST_BGT, "st.bgt"),
27643 + NORMAL_MNEMONIC(ST_BLE, ST_BLE, "st.ble"),
27644 + NORMAL_MNEMONIC(ST_BHI, ST_BHI, "st.bhi"),
27645 + NORMAL_MNEMONIC(ST_BVS, ST_BVS, "st.bvs"),
27646 + NORMAL_MNEMONIC(ST_BVC, ST_BVC, "st.bvc"),
27647 + NORMAL_MNEMONIC(ST_BQS, ST_BQS, "st.bqs"),
27648 + NORMAL_MNEMONIC(ST_BAL, ST_BAL, "st.bal"),
27649 + NORMAL_MNEMONIC(ST_BHS, ST_BHS, "st.bhs"),
27650 + NORMAL_MNEMONIC(ST_BLO, ST_BLO, "st.blo"),
27651 + NORMAL_MNEMONIC(MOVH, MOVH, "movh"),
27652 +
27653 + };
27654 +#undef NORMAL_MNEMONIC
27655 +#undef ALIAS_MNEMONIC
27656 +#undef FP_MNEMONIC
27657 --- /dev/null
27658 +++ b/opcodes/avr32-opc.h
27659 @@ -0,0 +1,2370 @@
27660 +/* Opcode tables for AVR32.
27661 + Copyright 2005, 2006 Atmel Corporation.
27662 +
27663 + Written by Haavard Skinnemoen, Atmel Norway, <hskinnemoen@atmel.com>
27664 +
27665 + This file is part of libopcodes.
27666 +
27667 + This program is free software; you can redistribute it and/or
27668 + modify it under the terms of the GNU General Public License as
27669 + published by the Free Software Foundation; either version 2 of the
27670 + License, or (at your option) any later version.
27671 +
27672 + This program is distributed in the hope that it will be useful, but
27673 + WITHOUT ANY WARRANTY; without even the implied warranty of
27674 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
27675 + General Public License for more details.
27676 +
27677 + You should have received a copy of the GNU General Public License
27678 + along with this program; if not, write to the Free Software
27679 + Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
27680 + 02111-1307, USA. */
27681 +
27682 +#include "bfd.h"
27683 +
27684 +#define AVR32_MAX_OPERANDS 8
27685 +#define AVR32_MAX_FIELDS 8
27686 +
27687 +#define AVR32_V1 (1 << 1)
27688 +#define AVR32_SIMD (1 << 2)
27689 +#define AVR32_DSP (1 << 3)
27690 +#define AVR32_RMW (1 << 4)
27691 +#define AVR32_V2 (1 << 5)
27692 +#define AVR32_FP (1 << 16)
27693 +#define AVR32_PICO (1 << 17)
27694 +
27695 +/* Registers we commonly refer to */
27696 +#define AVR32_REG_R12 12
27697 +#define AVR32_REG_SP 13
27698 +#define AVR32_REG_LR 14
27699 +#define AVR32_REG_PC 15
27700 +
27701 +struct avr32_ifield
27702 +{
27703 + int id;
27704 + unsigned short bitsize;
27705 + unsigned short shift;
27706 + unsigned long mask;
27707 +
27708 + /* If the value doesn't fit, it will be truncated with no warning */
27709 + void (*insert)(const struct avr32_ifield *, void *, unsigned long);
27710 + void (*extract)(const struct avr32_ifield *, void *, unsigned long *);
27711 +};
27712 +
27713 +struct avr32_opcode
27714 +{
27715 + int id;
27716 + int size;
27717 + unsigned long value;
27718 + unsigned long mask;
27719 + const struct avr32_syntax *syntax;
27720 + bfd_reloc_code_real_type reloc_type;
27721 + unsigned int nr_fields;
27722 + /* if relaxable, which field is variable, otherwise -1 */
27723 + int var_field;
27724 + const struct avr32_ifield *fields[AVR32_MAX_FIELDS];
27725 +};
27726 +
27727 +struct avr32_alias
27728 +{
27729 + int id;
27730 + const struct avr32_opcode *opc;
27731 + struct {
27732 + int is_opindex;
27733 + unsigned long value;
27734 + } operand_map[AVR32_MAX_OPERANDS];
27735 +};
27736 +
27737 +struct avr32_syntax
27738 +{
27739 + int id;
27740 + unsigned long isa_flags;
27741 + const struct avr32_mnemonic *mnemonic;
27742 + int type;
27743 + union {
27744 + const struct avr32_opcode *opc;
27745 + const struct avr32_alias *alias;
27746 + } u;
27747 + const struct avr32_syntax *next;
27748 + /* negative means "vararg" */
27749 + int nr_operands;
27750 + int operand[AVR32_MAX_OPERANDS];
27751 +};
27752 +
27753 +#if 0
27754 +#define AVR32_ALIAS_MAKE_CONST(val) ((val) | 0x80000000UL)
27755 +#define AVR32_ALIAS_IS_CONST(mapval) (((mapval) & 0x80000000UL) != 0)
27756 +#define AVR32_ALIAS_GET_CONST(mapval) ((mapval) & ~0x80000000UL)
27757 +#endif
27758 +
27759 +struct avr32_mnemonic
27760 +{
27761 + int id;
27762 + const char *name;
27763 + const struct avr32_syntax *syntax;
27764 +};
27765 +
27766 +extern const struct avr32_ifield avr32_ifield_table[];
27767 +extern struct avr32_opcode avr32_opc_table[];
27768 +extern const struct avr32_syntax avr32_syntax_table[];
27769 +extern const struct avr32_alias avr32_alias_table[];
27770 +extern const struct avr32_mnemonic avr32_mnemonic_table[];
27771 +
27772 +extern void avr32_insert_simple(const struct avr32_ifield *field,
27773 + void *buf, unsigned long value);
27774 +extern void avr32_insert_bit5c(const struct avr32_ifield *field,
27775 + void *buf, unsigned long value);
27776 +extern void avr32_insert_k10(const struct avr32_ifield *field,
27777 + void *buf, unsigned long value);
27778 +extern void avr32_insert_k21(const struct avr32_ifield *field,
27779 + void *buf, unsigned long value);
27780 +extern void avr32_insert_cpop(const struct avr32_ifield *field,
27781 + void *buf, unsigned long value);
27782 +extern void avr32_insert_k12cp(const struct avr32_ifield *field,
27783 + void *buf, unsigned long value);
27784 +
27785 +extern void avr32_extract_simple(const struct avr32_ifield *field,
27786 + void *buf, unsigned long *value);
27787 +extern void avr32_extract_bit5c(const struct avr32_ifield *field,
27788 + void *buf, unsigned long *value);
27789 +extern void avr32_extract_k10(const struct avr32_ifield *field,
27790 + void *buf, unsigned long *value);
27791 +extern void avr32_extract_k21(const struct avr32_ifield *field,
27792 + void *buf, unsigned long *value);
27793 +extern void avr32_extract_cpop(const struct avr32_ifield *field,
27794 + void *buf, unsigned long *value);
27795 +extern void avr32_extract_k12cp(const struct avr32_ifield *field,
27796 + void *buf, unsigned long *value);
27797 +
27798 +enum avr32_operand_type
27799 +{
27800 + AVR32_OPERAND_INTREG, /* just a register */
27801 + AVR32_OPERAND_INTREG_PREDEC, /* register with pre-decrement */
27802 + AVR32_OPERAND_INTREG_POSTINC, /* register with post-increment */
27803 + AVR32_OPERAND_INTREG_LSL, /* register with left shift */
27804 + AVR32_OPERAND_INTREG_LSR, /* register with right shift */
27805 + AVR32_OPERAND_INTREG_BSEL, /* register with byte selector */
27806 + AVR32_OPERAND_INTREG_HSEL, /* register with halfword selector */
27807 + AVR32_OPERAND_INTREG_SDISP, /* Rp[signed disp] */
27808 + AVR32_OPERAND_INTREG_SDISP_H, /* Rp[signed hword-aligned disp] */
27809 + AVR32_OPERAND_INTREG_SDISP_W, /* Rp[signed word-aligned disp] */
27810 + AVR32_OPERAND_INTREG_UDISP, /* Rp[unsigned disp] */
27811 + AVR32_OPERAND_INTREG_UDISP_H, /* Rp[unsigned hword-aligned disp] */
27812 + AVR32_OPERAND_INTREG_UDISP_W, /* Rp[unsigned word-aligned disp] */
27813 + AVR32_OPERAND_INTREG_INDEX, /* Rp[Ri << sa] */
27814 + AVR32_OPERAND_INTREG_XINDEX, /* Rp[Ri:bytesel << 2] */
27815 + AVR32_OPERAND_DWREG, /* Even-numbered register */
27816 + AVR32_OPERAND_PC_UDISP_W, /* PC[unsigned word-aligned disp] or label */
27817 + AVR32_OPERAND_SP, /* Just SP */
27818 + AVR32_OPERAND_SP_UDISP_W, /* SP[unsigned word-aligned disp] */
27819 + AVR32_OPERAND_CPNO,
27820 + AVR32_OPERAND_CPREG,
27821 + AVR32_OPERAND_CPREG_D,
27822 + AVR32_OPERAND_UNSIGNED_CONST,
27823 + AVR32_OPERAND_UNSIGNED_CONST_W,
27824 + AVR32_OPERAND_SIGNED_CONST,
27825 + AVR32_OPERAND_SIGNED_CONST_W,
27826 + AVR32_OPERAND_JMPLABEL,
27827 + AVR32_OPERAND_UNSIGNED_NUMBER,
27828 + AVR32_OPERAND_UNSIGNED_NUMBER_W,
27829 + AVR32_OPERAND_REGLIST8,
27830 + AVR32_OPERAND_REGLIST9,
27831 + AVR32_OPERAND_REGLIST16,
27832 + AVR32_OPERAND_REGLIST_LDM,
27833 + AVR32_OPERAND_REGLIST_CP8,
27834 + AVR32_OPERAND_REGLIST_CPD8,
27835 + AVR32_OPERAND_RETVAL,
27836 + AVR32_OPERAND_MCALL,
27837 + AVR32_OPERAND_JOSPINC,
27838 + AVR32_OPERAND_COH,
27839 + AVR32_OPERAND_FPREG_S,
27840 + AVR32_OPERAND_FPREG_D,
27841 + AVR32_OPERAND_PICO_REG_W,
27842 + AVR32_OPERAND_PICO_REG_D,
27843 + AVR32_OPERAND_PICO_REGLIST_W,
27844 + AVR32_OPERAND_PICO_REGLIST_D,
27845 + AVR32_OPERAND_PICO_IN,
27846 + AVR32_OPERAND_PICO_OUT0,
27847 + AVR32_OPERAND_PICO_OUT1,
27848 + AVR32_OPERAND_PICO_OUT2,
27849 + AVR32_OPERAND_PICO_OUT3,
27850 + AVR32_OPERAND__END_
27851 +};
27852 +#define AVR32_OPERAND_UNKNOWN AVR32_OPERAND__END_
27853 +#define AVR32_NR_OPERANDS AVR32_OPERAND__END_
27854 +
27855 +enum avr32_ifield_type
27856 +{
27857 + AVR32_IFIELD_RX,
27858 + AVR32_IFIELD_RY,
27859 + AVR32_IFIELD_COND4C,
27860 + AVR32_IFIELD_K8C,
27861 + AVR32_IFIELD_K7C,
27862 + AVR32_IFIELD_K5C,
27863 + AVR32_IFIELD_K3,
27864 + AVR32_IFIELD_RY_DW,
27865 + AVR32_IFIELD_COND4E,
27866 + AVR32_IFIELD_K8E,
27867 + AVR32_IFIELD_BIT5C,
27868 + AVR32_IFIELD_COND3,
27869 + AVR32_IFIELD_K10,
27870 + AVR32_IFIELD_POPM,
27871 + AVR32_IFIELD_K2,
27872 + AVR32_IFIELD_RD_E,
27873 + AVR32_IFIELD_RD_DW,
27874 + AVR32_IFIELD_X,
27875 + AVR32_IFIELD_Y,
27876 + AVR32_IFIELD_X2,
27877 + AVR32_IFIELD_Y2,
27878 + AVR32_IFIELD_K5E,
27879 + AVR32_IFIELD_PART2,
27880 + AVR32_IFIELD_PART1,
27881 + AVR32_IFIELD_K16,
27882 + AVR32_IFIELD_CACHEOP,
27883 + AVR32_IFIELD_K11,
27884 + AVR32_IFIELD_K21,
27885 + AVR32_IFIELD_CPOP,
27886 + AVR32_IFIELD_CPNO,
27887 + AVR32_IFIELD_CRD_RI,
27888 + AVR32_IFIELD_CRX,
27889 + AVR32_IFIELD_CRY,
27890 + AVR32_IFIELD_K7E,
27891 + AVR32_IFIELD_CRD_DW,
27892 + AVR32_IFIELD_PART1_K12,
27893 + AVR32_IFIELD_PART2_K12,
27894 + AVR32_IFIELD_K12,
27895 + AVR32_IFIELD_S5,
27896 + AVR32_IFIELD_K5E2,
27897 + AVR32_IFIELD_K4,
27898 + AVR32_IFIELD_COND4E2,
27899 + AVR32_IFIELD_K8E2,
27900 + AVR32_IFIELD_K6,
27901 + AVR32_IFIELD_MEM15,
27902 + AVR32_IFIELD_MEMB5,
27903 + AVR32_IFIELD_W,
27904 + AVR32_IFIELD_CM_HL,
27905 + AVR32_IFIELD_K12CP,
27906 + AVR32_IFIELD_K9E,
27907 + AVR32_IFIELD__END_,
27908 +};
27909 +#define AVR32_NR_IFIELDS AVR32_IFIELD__END_
27910 +
27911 +enum avr32_opc_type
27912 +{
27913 + AVR32_OPC_ABS,
27914 + AVR32_OPC_ACALL,
27915 + AVR32_OPC_ACR,
27916 + AVR32_OPC_ADC,
27917 + AVR32_OPC_ADD1,
27918 + AVR32_OPC_ADD2,
27919 + AVR32_OPC_ADDABS,
27920 + AVR32_OPC_ADDHH_W,
27921 + AVR32_OPC_AND1,
27922 + AVR32_OPC_AND2,
27923 + AVR32_OPC_AND3,
27924 + AVR32_OPC_ANDH,
27925 + AVR32_OPC_ANDH_COH,
27926 + AVR32_OPC_ANDL,
27927 + AVR32_OPC_ANDL_COH,
27928 + AVR32_OPC_ANDN,
27929 + AVR32_OPC_ASR1,
27930 + AVR32_OPC_ASR3,
27931 + AVR32_OPC_ASR2,
27932 + AVR32_OPC_BLD,
27933 + AVR32_OPC_BREQ1,
27934 + AVR32_OPC_BRNE1,
27935 + AVR32_OPC_BRCC1,
27936 + AVR32_OPC_BRCS1,
27937 + AVR32_OPC_BRGE1,
27938 + AVR32_OPC_BRLT1,
27939 + AVR32_OPC_BRMI1,
27940 + AVR32_OPC_BRPL1,
27941 + AVR32_OPC_BREQ2,
27942 + AVR32_OPC_BRNE2,
27943 + AVR32_OPC_BRCC2,
27944 + AVR32_OPC_BRCS2,
27945 + AVR32_OPC_BRGE2,
27946 + AVR32_OPC_BRLT2,
27947 + AVR32_OPC_BRMI2,
27948 + AVR32_OPC_BRPL2,
27949 + AVR32_OPC_BRLS,
27950 + AVR32_OPC_BRGT,
27951 + AVR32_OPC_BRLE,
27952 + AVR32_OPC_BRHI,
27953 + AVR32_OPC_BRVS,
27954 + AVR32_OPC_BRVC,
27955 + AVR32_OPC_BRQS,
27956 + AVR32_OPC_BRAL,
27957 + AVR32_OPC_BREAKPOINT,
27958 + AVR32_OPC_BREV,
27959 + AVR32_OPC_BST,
27960 + AVR32_OPC_CACHE,
27961 + AVR32_OPC_CASTS_B,
27962 + AVR32_OPC_CASTS_H,
27963 + AVR32_OPC_CASTU_B,
27964 + AVR32_OPC_CASTU_H,
27965 + AVR32_OPC_CBR,
27966 + AVR32_OPC_CLZ,
27967 + AVR32_OPC_COM,
27968 + AVR32_OPC_COP,
27969 + AVR32_OPC_CP_B,
27970 + AVR32_OPC_CP_H,
27971 + AVR32_OPC_CP_W1,
27972 + AVR32_OPC_CP_W2,
27973 + AVR32_OPC_CP_W3,
27974 + AVR32_OPC_CPC1,
27975 + AVR32_OPC_CPC2,
27976 + AVR32_OPC_CSRF,
27977 + AVR32_OPC_CSRFCZ,
27978 + AVR32_OPC_DIVS,
27979 + AVR32_OPC_DIVU,
27980 + AVR32_OPC_EOR1,
27981 + AVR32_OPC_EOR2,
27982 + AVR32_OPC_EOR3,
27983 + AVR32_OPC_EORL,
27984 + AVR32_OPC_EORH,
27985 + AVR32_OPC_FRS,
27986 + AVR32_OPC_ICALL,
27987 + AVR32_OPC_INCJOSP,
27988 + AVR32_OPC_LD_D1,
27989 + AVR32_OPC_LD_D2,
27990 + AVR32_OPC_LD_D3,
27991 + AVR32_OPC_LD_D5,
27992 + AVR32_OPC_LD_D4,
27993 + AVR32_OPC_LD_SB2,
27994 + AVR32_OPC_LD_SB1,
27995 + AVR32_OPC_LD_UB1,
27996 + AVR32_OPC_LD_UB2,
27997 + AVR32_OPC_LD_UB5,
27998 + AVR32_OPC_LD_UB3,
27999 + AVR32_OPC_LD_UB4,
28000 + AVR32_OPC_LD_SH1,
28001 + AVR32_OPC_LD_SH2,
28002 + AVR32_OPC_LD_SH5,
28003 + AVR32_OPC_LD_SH3,
28004 + AVR32_OPC_LD_SH4,
28005 + AVR32_OPC_LD_UH1,
28006 + AVR32_OPC_LD_UH2,
28007 + AVR32_OPC_LD_UH5,
28008 + AVR32_OPC_LD_UH3,
28009 + AVR32_OPC_LD_UH4,
28010 + AVR32_OPC_LD_W1,
28011 + AVR32_OPC_LD_W2,
28012 + AVR32_OPC_LD_W5,
28013 + AVR32_OPC_LD_W6,
28014 + AVR32_OPC_LD_W3,
28015 + AVR32_OPC_LD_W4,
28016 + AVR32_OPC_LDC_D1,
28017 + AVR32_OPC_LDC_D2,
28018 + AVR32_OPC_LDC_D3,
28019 + AVR32_OPC_LDC_W1,
28020 + AVR32_OPC_LDC_W2,
28021 + AVR32_OPC_LDC_W3,
28022 + AVR32_OPC_LDC0_D,
28023 + AVR32_OPC_LDC0_W,
28024 + AVR32_OPC_LDCM_D,
28025 + AVR32_OPC_LDCM_D_PU,
28026 + AVR32_OPC_LDCM_W,
28027 + AVR32_OPC_LDCM_W_PU,
28028 + AVR32_OPC_LDDPC,
28029 + AVR32_OPC_LDDPC_EXT,
28030 + AVR32_OPC_LDDSP,
28031 + AVR32_OPC_LDINS_B,
28032 + AVR32_OPC_LDINS_H,
28033 + AVR32_OPC_LDM,
28034 + AVR32_OPC_LDMTS,
28035 + AVR32_OPC_LDMTS_PU,
28036 + AVR32_OPC_LDSWP_SH,
28037 + AVR32_OPC_LDSWP_UH,
28038 + AVR32_OPC_LDSWP_W,
28039 + AVR32_OPC_LSL1,
28040 + AVR32_OPC_LSL3,
28041 + AVR32_OPC_LSL2,
28042 + AVR32_OPC_LSR1,
28043 + AVR32_OPC_LSR3,
28044 + AVR32_OPC_LSR2,
28045 + AVR32_OPC_MAC,
28046 + AVR32_OPC_MACHH_D,
28047 + AVR32_OPC_MACHH_W,
28048 + AVR32_OPC_MACS_D,
28049 + AVR32_OPC_MACSATHH_W,
28050 + AVR32_OPC_MACUD,
28051 + AVR32_OPC_MACWH_D,
28052 + AVR32_OPC_MAX,
28053 + AVR32_OPC_MCALL,
28054 + AVR32_OPC_MFDR,
28055 + AVR32_OPC_MFSR,
28056 + AVR32_OPC_MIN,
28057 + AVR32_OPC_MOV3,
28058 + AVR32_OPC_MOV1,
28059 + AVR32_OPC_MOV2,
28060 + AVR32_OPC_MOVEQ1,
28061 + AVR32_OPC_MOVNE1,
28062 + AVR32_OPC_MOVCC1,
28063 + AVR32_OPC_MOVCS1,
28064 + AVR32_OPC_MOVGE1,
28065 + AVR32_OPC_MOVLT1,
28066 + AVR32_OPC_MOVMI1,
28067 + AVR32_OPC_MOVPL1,
28068 + AVR32_OPC_MOVLS1,
28069 + AVR32_OPC_MOVGT1,
28070 + AVR32_OPC_MOVLE1,
28071 + AVR32_OPC_MOVHI1,
28072 + AVR32_OPC_MOVVS1,
28073 + AVR32_OPC_MOVVC1,
28074 + AVR32_OPC_MOVQS1,
28075 + AVR32_OPC_MOVAL1,
28076 + AVR32_OPC_MOVEQ2,
28077 + AVR32_OPC_MOVNE2,
28078 + AVR32_OPC_MOVCC2,
28079 + AVR32_OPC_MOVCS2,
28080 + AVR32_OPC_MOVGE2,
28081 + AVR32_OPC_MOVLT2,
28082 + AVR32_OPC_MOVMI2,
28083 + AVR32_OPC_MOVPL2,
28084 + AVR32_OPC_MOVLS2,
28085 + AVR32_OPC_MOVGT2,
28086 + AVR32_OPC_MOVLE2,
28087 + AVR32_OPC_MOVHI2,
28088 + AVR32_OPC_MOVVS2,
28089 + AVR32_OPC_MOVVC2,
28090 + AVR32_OPC_MOVQS2,
28091 + AVR32_OPC_MOVAL2,
28092 + AVR32_OPC_MTDR,
28093 + AVR32_OPC_MTSR,
28094 + AVR32_OPC_MUL1,
28095 + AVR32_OPC_MUL2,
28096 + AVR32_OPC_MUL3,
28097 + AVR32_OPC_MULHH_W,
28098 + AVR32_OPC_MULNHH_W,
28099 + AVR32_OPC_MULNWH_D,
28100 + AVR32_OPC_MULSD,
28101 + AVR32_OPC_MULSATHH_H,
28102 + AVR32_OPC_MULSATHH_W,
28103 + AVR32_OPC_MULSATRNDHH_H,
28104 + AVR32_OPC_MULSATRNDWH_W,
28105 + AVR32_OPC_MULSATWH_W,
28106 + AVR32_OPC_MULU_D,
28107 + AVR32_OPC_MULWH_D,
28108 + AVR32_OPC_MUSFR,
28109 + AVR32_OPC_MUSTR,
28110 + AVR32_OPC_MVCR_D,
28111 + AVR32_OPC_MVCR_W,
28112 + AVR32_OPC_MVRC_D,
28113 + AVR32_OPC_MVRC_W,
28114 + AVR32_OPC_NEG,
28115 + AVR32_OPC_NOP,
28116 + AVR32_OPC_OR1,
28117 + AVR32_OPC_OR2,
28118 + AVR32_OPC_OR3,
28119 + AVR32_OPC_ORH,
28120 + AVR32_OPC_ORL,
28121 + AVR32_OPC_PABS_SB,
28122 + AVR32_OPC_PABS_SH,
28123 + AVR32_OPC_PACKSH_SB,
28124 + AVR32_OPC_PACKSH_UB,
28125 + AVR32_OPC_PACKW_SH,
28126 + AVR32_OPC_PADD_B,
28127 + AVR32_OPC_PADD_H,
28128 + AVR32_OPC_PADDH_SH,
28129 + AVR32_OPC_PADDH_UB,
28130 + AVR32_OPC_PADDS_SB,
28131 + AVR32_OPC_PADDS_SH,
28132 + AVR32_OPC_PADDS_UB,
28133 + AVR32_OPC_PADDS_UH,
28134 + AVR32_OPC_PADDSUB_H,
28135 + AVR32_OPC_PADDSUBH_SH,
28136 + AVR32_OPC_PADDSUBS_SH,
28137 + AVR32_OPC_PADDSUBS_UH,
28138 + AVR32_OPC_PADDX_H,
28139 + AVR32_OPC_PADDXH_SH,
28140 + AVR32_OPC_PADDXS_SH,
28141 + AVR32_OPC_PADDXS_UH,
28142 + AVR32_OPC_PASR_B,
28143 + AVR32_OPC_PASR_H,
28144 + AVR32_OPC_PAVG_SH,
28145 + AVR32_OPC_PAVG_UB,
28146 + AVR32_OPC_PLSL_B,
28147 + AVR32_OPC_PLSL_H,
28148 + AVR32_OPC_PLSR_B,
28149 + AVR32_OPC_PLSR_H,
28150 + AVR32_OPC_PMAX_SH,
28151 + AVR32_OPC_PMAX_UB,
28152 + AVR32_OPC_PMIN_SH,
28153 + AVR32_OPC_PMIN_UB,
28154 + AVR32_OPC_POPJC,
28155 + AVR32_OPC_POPM,
28156 + AVR32_OPC_POPM_E,
28157 + AVR32_OPC_PREF,
28158 + AVR32_OPC_PSAD,
28159 + AVR32_OPC_PSUB_B,
28160 + AVR32_OPC_PSUB_H,
28161 + AVR32_OPC_PSUBADD_H,
28162 + AVR32_OPC_PSUBADDH_SH,
28163 + AVR32_OPC_PSUBADDS_SH,
28164 + AVR32_OPC_PSUBADDS_UH,
28165 + AVR32_OPC_PSUBH_SH,
28166 + AVR32_OPC_PSUBH_UB,
28167 + AVR32_OPC_PSUBS_SB,
28168 + AVR32_OPC_PSUBS_SH,
28169 + AVR32_OPC_PSUBS_UB,
28170 + AVR32_OPC_PSUBS_UH,
28171 + AVR32_OPC_PSUBX_H,
28172 + AVR32_OPC_PSUBXH_SH,
28173 + AVR32_OPC_PSUBXS_SH,
28174 + AVR32_OPC_PSUBXS_UH,
28175 + AVR32_OPC_PUNPCKSB_H,
28176 + AVR32_OPC_PUNPCKUB_H,
28177 + AVR32_OPC_PUSHJC,
28178 + AVR32_OPC_PUSHM,
28179 + AVR32_OPC_PUSHM_E,
28180 + AVR32_OPC_RCALL1,
28181 + AVR32_OPC_RCALL2,
28182 + AVR32_OPC_RETEQ,
28183 + AVR32_OPC_RETNE,
28184 + AVR32_OPC_RETCC,
28185 + AVR32_OPC_RETCS,
28186 + AVR32_OPC_RETGE,
28187 + AVR32_OPC_RETLT,
28188 + AVR32_OPC_RETMI,
28189 + AVR32_OPC_RETPL,
28190 + AVR32_OPC_RETLS,
28191 + AVR32_OPC_RETGT,
28192 + AVR32_OPC_RETLE,
28193 + AVR32_OPC_RETHI,
28194 + AVR32_OPC_RETVS,
28195 + AVR32_OPC_RETVC,
28196 + AVR32_OPC_RETQS,
28197 + AVR32_OPC_RETAL,
28198 + AVR32_OPC_RETD,
28199 + AVR32_OPC_RETE,
28200 + AVR32_OPC_RETJ,
28201 + AVR32_OPC_RETS,
28202 + AVR32_OPC_RJMP,
28203 + AVR32_OPC_ROL,
28204 + AVR32_OPC_ROR,
28205 + AVR32_OPC_RSUB1,
28206 + AVR32_OPC_RSUB2,
28207 + AVR32_OPC_SATADD_H,
28208 + AVR32_OPC_SATADD_W,
28209 + AVR32_OPC_SATRNDS,
28210 + AVR32_OPC_SATRNDU,
28211 + AVR32_OPC_SATS,
28212 + AVR32_OPC_SATSUB_H,
28213 + AVR32_OPC_SATSUB_W1,
28214 + AVR32_OPC_SATSUB_W2,
28215 + AVR32_OPC_SATU,
28216 + AVR32_OPC_SBC,
28217 + AVR32_OPC_SBR,
28218 + AVR32_OPC_SCALL,
28219 + AVR32_OPC_SCR,
28220 + AVR32_OPC_SLEEP,
28221 + AVR32_OPC_SREQ,
28222 + AVR32_OPC_SRNE,
28223 + AVR32_OPC_SRCC,
28224 + AVR32_OPC_SRCS,
28225 + AVR32_OPC_SRGE,
28226 + AVR32_OPC_SRLT,
28227 + AVR32_OPC_SRMI,
28228 + AVR32_OPC_SRPL,
28229 + AVR32_OPC_SRLS,
28230 + AVR32_OPC_SRGT,
28231 + AVR32_OPC_SRLE,
28232 + AVR32_OPC_SRHI,
28233 + AVR32_OPC_SRVS,
28234 + AVR32_OPC_SRVC,
28235 + AVR32_OPC_SRQS,
28236 + AVR32_OPC_SRAL,
28237 + AVR32_OPC_SSRF,
28238 + AVR32_OPC_ST_B1,
28239 + AVR32_OPC_ST_B2,
28240 + AVR32_OPC_ST_B5,
28241 + AVR32_OPC_ST_B3,
28242 + AVR32_OPC_ST_B4,
28243 + AVR32_OPC_ST_D1,
28244 + AVR32_OPC_ST_D2,
28245 + AVR32_OPC_ST_D3,
28246 + AVR32_OPC_ST_D5,
28247 + AVR32_OPC_ST_D4,
28248 + AVR32_OPC_ST_H1,
28249 + AVR32_OPC_ST_H2,
28250 + AVR32_OPC_ST_H5,
28251 + AVR32_OPC_ST_H3,
28252 + AVR32_OPC_ST_H4,
28253 + AVR32_OPC_ST_W1,
28254 + AVR32_OPC_ST_W2,
28255 + AVR32_OPC_ST_W5,
28256 + AVR32_OPC_ST_W3,
28257 + AVR32_OPC_ST_W4,
28258 + AVR32_OPC_STC_D1,
28259 + AVR32_OPC_STC_D2,
28260 + AVR32_OPC_STC_D3,
28261 + AVR32_OPC_STC_W1,
28262 + AVR32_OPC_STC_W2,
28263 + AVR32_OPC_STC_W3,
28264 + AVR32_OPC_STC0_D,
28265 + AVR32_OPC_STC0_W,
28266 + AVR32_OPC_STCM_D,
28267 + AVR32_OPC_STCM_D_PU,
28268 + AVR32_OPC_STCM_W,
28269 + AVR32_OPC_STCM_W_PU,
28270 + AVR32_OPC_STCOND,
28271 + AVR32_OPC_STDSP,
28272 + AVR32_OPC_STHH_W2,
28273 + AVR32_OPC_STHH_W1,
28274 + AVR32_OPC_STM,
28275 + AVR32_OPC_STM_PU,
28276 + AVR32_OPC_STMTS,
28277 + AVR32_OPC_STMTS_PU,
28278 + AVR32_OPC_STSWP_H,
28279 + AVR32_OPC_STSWP_W,
28280 + AVR32_OPC_SUB1,
28281 + AVR32_OPC_SUB2,
28282 + AVR32_OPC_SUB5,
28283 + AVR32_OPC_SUB3_SP,
28284 + AVR32_OPC_SUB3,
28285 + AVR32_OPC_SUB4,
28286 + AVR32_OPC_SUBEQ,
28287 + AVR32_OPC_SUBNE,
28288 + AVR32_OPC_SUBCC,
28289 + AVR32_OPC_SUBCS,
28290 + AVR32_OPC_SUBGE,
28291 + AVR32_OPC_SUBLT,
28292 + AVR32_OPC_SUBMI,
28293 + AVR32_OPC_SUBPL,
28294 + AVR32_OPC_SUBLS,
28295 + AVR32_OPC_SUBGT,
28296 + AVR32_OPC_SUBLE,
28297 + AVR32_OPC_SUBHI,
28298 + AVR32_OPC_SUBVS,
28299 + AVR32_OPC_SUBVC,
28300 + AVR32_OPC_SUBQS,
28301 + AVR32_OPC_SUBAL,
28302 + AVR32_OPC_SUBFEQ,
28303 + AVR32_OPC_SUBFNE,
28304 + AVR32_OPC_SUBFCC,
28305 + AVR32_OPC_SUBFCS,
28306 + AVR32_OPC_SUBFGE,
28307 + AVR32_OPC_SUBFLT,
28308 + AVR32_OPC_SUBFMI,
28309 + AVR32_OPC_SUBFPL,
28310 + AVR32_OPC_SUBFLS,
28311 + AVR32_OPC_SUBFGT,
28312 + AVR32_OPC_SUBFLE,
28313 + AVR32_OPC_SUBFHI,
28314 + AVR32_OPC_SUBFVS,
28315 + AVR32_OPC_SUBFVC,
28316 + AVR32_OPC_SUBFQS,
28317 + AVR32_OPC_SUBFAL,
28318 + AVR32_OPC_SUBHH_W,
28319 + AVR32_OPC_SWAP_B,
28320 + AVR32_OPC_SWAP_BH,
28321 + AVR32_OPC_SWAP_H,
28322 + AVR32_OPC_SYNC,
28323 + AVR32_OPC_TLBR,
28324 + AVR32_OPC_TLBS,
28325 + AVR32_OPC_TLBW,
28326 + AVR32_OPC_TNBZ,
28327 + AVR32_OPC_TST,
28328 + AVR32_OPC_XCHG,
28329 + AVR32_OPC_MEMC,
28330 + AVR32_OPC_MEMS,
28331 + AVR32_OPC_MEMT,
28332 + AVR32_OPC_BFEXTS,
28333 + AVR32_OPC_BFEXTU,
28334 + AVR32_OPC_BFINS,
28335 + AVR32_OPC_RSUBEQ,
28336 + AVR32_OPC_RSUBNE,
28337 + AVR32_OPC_RSUBCC,
28338 + AVR32_OPC_RSUBCS,
28339 + AVR32_OPC_RSUBGE,
28340 + AVR32_OPC_RSUBLT,
28341 + AVR32_OPC_RSUBMI,
28342 + AVR32_OPC_RSUBPL,
28343 + AVR32_OPC_RSUBLS,
28344 + AVR32_OPC_RSUBGT,
28345 + AVR32_OPC_RSUBLE,
28346 + AVR32_OPC_RSUBHI,
28347 + AVR32_OPC_RSUBVS,
28348 + AVR32_OPC_RSUBVC,
28349 + AVR32_OPC_RSUBQS,
28350 + AVR32_OPC_RSUBAL,
28351 + AVR32_OPC_ADDEQ,
28352 + AVR32_OPC_ADDNE,
28353 + AVR32_OPC_ADDCC,
28354 + AVR32_OPC_ADDCS,
28355 + AVR32_OPC_ADDGE,
28356 + AVR32_OPC_ADDLT,
28357 + AVR32_OPC_ADDMI,
28358 + AVR32_OPC_ADDPL,
28359 + AVR32_OPC_ADDLS,
28360 + AVR32_OPC_ADDGT,
28361 + AVR32_OPC_ADDLE,
28362 + AVR32_OPC_ADDHI,
28363 + AVR32_OPC_ADDVS,
28364 + AVR32_OPC_ADDVC,
28365 + AVR32_OPC_ADDQS,
28366 + AVR32_OPC_ADDAL,
28367 + AVR32_OPC_SUB2EQ,
28368 + AVR32_OPC_SUB2NE,
28369 + AVR32_OPC_SUB2CC,
28370 + AVR32_OPC_SUB2CS,
28371 + AVR32_OPC_SUB2GE,
28372 + AVR32_OPC_SUB2LT,
28373 + AVR32_OPC_SUB2MI,
28374 + AVR32_OPC_SUB2PL,
28375 + AVR32_OPC_SUB2LS,
28376 + AVR32_OPC_SUB2GT,
28377 + AVR32_OPC_SUB2LE,
28378 + AVR32_OPC_SUB2HI,
28379 + AVR32_OPC_SUB2VS,
28380 + AVR32_OPC_SUB2VC,
28381 + AVR32_OPC_SUB2QS,
28382 + AVR32_OPC_SUB2AL,
28383 + AVR32_OPC_ANDEQ,
28384 + AVR32_OPC_ANDNE,
28385 + AVR32_OPC_ANDCC,
28386 + AVR32_OPC_ANDCS,
28387 + AVR32_OPC_ANDGE,
28388 + AVR32_OPC_ANDLT,
28389 + AVR32_OPC_ANDMI,
28390 + AVR32_OPC_ANDPL,
28391 + AVR32_OPC_ANDLS,
28392 + AVR32_OPC_ANDGT,
28393 + AVR32_OPC_ANDLE,
28394 + AVR32_OPC_ANDHI,
28395 + AVR32_OPC_ANDVS,
28396 + AVR32_OPC_ANDVC,
28397 + AVR32_OPC_ANDQS,
28398 + AVR32_OPC_ANDAL,
28399 + AVR32_OPC_OREQ,
28400 + AVR32_OPC_ORNE,
28401 + AVR32_OPC_ORCC,
28402 + AVR32_OPC_ORCS,
28403 + AVR32_OPC_ORGE,
28404 + AVR32_OPC_ORLT,
28405 + AVR32_OPC_ORMI,
28406 + AVR32_OPC_ORPL,
28407 + AVR32_OPC_ORLS,
28408 + AVR32_OPC_ORGT,
28409 + AVR32_OPC_ORLE,
28410 + AVR32_OPC_ORHI,
28411 + AVR32_OPC_ORVS,
28412 + AVR32_OPC_ORVC,
28413 + AVR32_OPC_ORQS,
28414 + AVR32_OPC_ORAL,
28415 + AVR32_OPC_EOREQ,
28416 + AVR32_OPC_EORNE,
28417 + AVR32_OPC_EORCC,
28418 + AVR32_OPC_EORCS,
28419 + AVR32_OPC_EORGE,
28420 + AVR32_OPC_EORLT,
28421 + AVR32_OPC_EORMI,
28422 + AVR32_OPC_EORPL,
28423 + AVR32_OPC_EORLS,
28424 + AVR32_OPC_EORGT,
28425 + AVR32_OPC_EORLE,
28426 + AVR32_OPC_EORHI,
28427 + AVR32_OPC_EORVS,
28428 + AVR32_OPC_EORVC,
28429 + AVR32_OPC_EORQS,
28430 + AVR32_OPC_EORAL,
28431 + AVR32_OPC_LD_WEQ,
28432 + AVR32_OPC_LD_WNE,
28433 + AVR32_OPC_LD_WCC,
28434 + AVR32_OPC_LD_WCS,
28435 + AVR32_OPC_LD_WGE,
28436 + AVR32_OPC_LD_WLT,
28437 + AVR32_OPC_LD_WMI,
28438 + AVR32_OPC_LD_WPL,
28439 + AVR32_OPC_LD_WLS,
28440 + AVR32_OPC_LD_WGT,
28441 + AVR32_OPC_LD_WLE,
28442 + AVR32_OPC_LD_WHI,
28443 + AVR32_OPC_LD_WVS,
28444 + AVR32_OPC_LD_WVC,
28445 + AVR32_OPC_LD_WQS,
28446 + AVR32_OPC_LD_WAL,
28447 + AVR32_OPC_LD_SHEQ,
28448 + AVR32_OPC_LD_SHNE,
28449 + AVR32_OPC_LD_SHCC,
28450 + AVR32_OPC_LD_SHCS,
28451 + AVR32_OPC_LD_SHGE,
28452 + AVR32_OPC_LD_SHLT,
28453 + AVR32_OPC_LD_SHMI,
28454 + AVR32_OPC_LD_SHPL,
28455 + AVR32_OPC_LD_SHLS,
28456 + AVR32_OPC_LD_SHGT,
28457 + AVR32_OPC_LD_SHLE,
28458 + AVR32_OPC_LD_SHHI,
28459 + AVR32_OPC_LD_SHVS,
28460 + AVR32_OPC_LD_SHVC,
28461 + AVR32_OPC_LD_SHQS,
28462 + AVR32_OPC_LD_SHAL,
28463 + AVR32_OPC_LD_UHEQ,
28464 + AVR32_OPC_LD_UHNE,
28465 + AVR32_OPC_LD_UHCC,
28466 + AVR32_OPC_LD_UHCS,
28467 + AVR32_OPC_LD_UHGE,
28468 + AVR32_OPC_LD_UHLT,
28469 + AVR32_OPC_LD_UHMI,
28470 + AVR32_OPC_LD_UHPL,
28471 + AVR32_OPC_LD_UHLS,
28472 + AVR32_OPC_LD_UHGT,
28473 + AVR32_OPC_LD_UHLE,
28474 + AVR32_OPC_LD_UHHI,
28475 + AVR32_OPC_LD_UHVS,
28476 + AVR32_OPC_LD_UHVC,
28477 + AVR32_OPC_LD_UHQS,
28478 + AVR32_OPC_LD_UHAL,
28479 + AVR32_OPC_LD_SBEQ,
28480 + AVR32_OPC_LD_SBNE,
28481 + AVR32_OPC_LD_SBCC,
28482 + AVR32_OPC_LD_SBCS,
28483 + AVR32_OPC_LD_SBGE,
28484 + AVR32_OPC_LD_SBLT,
28485 + AVR32_OPC_LD_SBMI,
28486 + AVR32_OPC_LD_SBPL,
28487 + AVR32_OPC_LD_SBLS,
28488 + AVR32_OPC_LD_SBGT,
28489 + AVR32_OPC_LD_SBLE,
28490 + AVR32_OPC_LD_SBHI,
28491 + AVR32_OPC_LD_SBVS,
28492 + AVR32_OPC_LD_SBVC,
28493 + AVR32_OPC_LD_SBQS,
28494 + AVR32_OPC_LD_SBAL,
28495 + AVR32_OPC_LD_UBEQ,
28496 + AVR32_OPC_LD_UBNE,
28497 + AVR32_OPC_LD_UBCC,
28498 + AVR32_OPC_LD_UBCS,
28499 + AVR32_OPC_LD_UBGE,
28500 + AVR32_OPC_LD_UBLT,
28501 + AVR32_OPC_LD_UBMI,
28502 + AVR32_OPC_LD_UBPL,
28503 + AVR32_OPC_LD_UBLS,
28504 + AVR32_OPC_LD_UBGT,
28505 + AVR32_OPC_LD_UBLE,
28506 + AVR32_OPC_LD_UBHI,
28507 + AVR32_OPC_LD_UBVS,
28508 + AVR32_OPC_LD_UBVC,
28509 + AVR32_OPC_LD_UBQS,
28510 + AVR32_OPC_LD_UBAL,
28511 + AVR32_OPC_ST_WEQ,
28512 + AVR32_OPC_ST_WNE,
28513 + AVR32_OPC_ST_WCC,
28514 + AVR32_OPC_ST_WCS,
28515 + AVR32_OPC_ST_WGE,
28516 + AVR32_OPC_ST_WLT,
28517 + AVR32_OPC_ST_WMI,
28518 + AVR32_OPC_ST_WPL,
28519 + AVR32_OPC_ST_WLS,
28520 + AVR32_OPC_ST_WGT,
28521 + AVR32_OPC_ST_WLE,
28522 + AVR32_OPC_ST_WHI,
28523 + AVR32_OPC_ST_WVS,
28524 + AVR32_OPC_ST_WVC,
28525 + AVR32_OPC_ST_WQS,
28526 + AVR32_OPC_ST_WAL,
28527 + AVR32_OPC_ST_HEQ,
28528 + AVR32_OPC_ST_HNE,
28529 + AVR32_OPC_ST_HCC,
28530 + AVR32_OPC_ST_HCS,
28531 + AVR32_OPC_ST_HGE,
28532 + AVR32_OPC_ST_HLT,
28533 + AVR32_OPC_ST_HMI,
28534 + AVR32_OPC_ST_HPL,
28535 + AVR32_OPC_ST_HLS,
28536 + AVR32_OPC_ST_HGT,
28537 + AVR32_OPC_ST_HLE,
28538 + AVR32_OPC_ST_HHI,
28539 + AVR32_OPC_ST_HVS,
28540 + AVR32_OPC_ST_HVC,
28541 + AVR32_OPC_ST_HQS,
28542 + AVR32_OPC_ST_HAL,
28543 + AVR32_OPC_ST_BEQ,
28544 + AVR32_OPC_ST_BNE,
28545 + AVR32_OPC_ST_BCC,
28546 + AVR32_OPC_ST_BCS,
28547 + AVR32_OPC_ST_BGE,
28548 + AVR32_OPC_ST_BLT,
28549 + AVR32_OPC_ST_BMI,
28550 + AVR32_OPC_ST_BPL,
28551 + AVR32_OPC_ST_BLS,
28552 + AVR32_OPC_ST_BGT,
28553 + AVR32_OPC_ST_BLE,
28554 + AVR32_OPC_ST_BHI,
28555 + AVR32_OPC_ST_BVS,
28556 + AVR32_OPC_ST_BVC,
28557 + AVR32_OPC_ST_BQS,
28558 + AVR32_OPC_ST_BAL,
28559 + AVR32_OPC_MOVH,
28560 + AVR32_OPC__END_
28561 +};
28562 +#define AVR32_NR_OPCODES AVR32_OPC__END_
28563 +
28564 +enum avr32_syntax_type
28565 +{
28566 + AVR32_SYNTAX_ABS,
28567 + AVR32_SYNTAX_ACALL,
28568 + AVR32_SYNTAX_ACR,
28569 + AVR32_SYNTAX_ADC,
28570 + AVR32_SYNTAX_ADD1,
28571 + AVR32_SYNTAX_ADD2,
28572 + AVR32_SYNTAX_ADDABS,
28573 + AVR32_SYNTAX_ADDHH_W,
28574 + AVR32_SYNTAX_AND1,
28575 + AVR32_SYNTAX_AND2,
28576 + AVR32_SYNTAX_AND3,
28577 + AVR32_SYNTAX_ANDH,
28578 + AVR32_SYNTAX_ANDH_COH,
28579 + AVR32_SYNTAX_ANDL,
28580 + AVR32_SYNTAX_ANDL_COH,
28581 + AVR32_SYNTAX_ANDN,
28582 + AVR32_SYNTAX_ASR1,
28583 + AVR32_SYNTAX_ASR3,
28584 + AVR32_SYNTAX_ASR2,
28585 + AVR32_SYNTAX_BFEXTS,
28586 + AVR32_SYNTAX_BFEXTU,
28587 + AVR32_SYNTAX_BFINS,
28588 + AVR32_SYNTAX_BLD,
28589 + AVR32_SYNTAX_BREQ1,
28590 + AVR32_SYNTAX_BRNE1,
28591 + AVR32_SYNTAX_BRCC1,
28592 + AVR32_SYNTAX_BRCS1,
28593 + AVR32_SYNTAX_BRGE1,
28594 + AVR32_SYNTAX_BRLT1,
28595 + AVR32_SYNTAX_BRMI1,
28596 + AVR32_SYNTAX_BRPL1,
28597 + AVR32_SYNTAX_BRHS1,
28598 + AVR32_SYNTAX_BRLO1,
28599 + AVR32_SYNTAX_BREQ2,
28600 + AVR32_SYNTAX_BRNE2,
28601 + AVR32_SYNTAX_BRCC2,
28602 + AVR32_SYNTAX_BRCS2,
28603 + AVR32_SYNTAX_BRGE2,
28604 + AVR32_SYNTAX_BRLT2,
28605 + AVR32_SYNTAX_BRMI2,
28606 + AVR32_SYNTAX_BRPL2,
28607 + AVR32_SYNTAX_BRLS,
28608 + AVR32_SYNTAX_BRGT,
28609 + AVR32_SYNTAX_BRLE,
28610 + AVR32_SYNTAX_BRHI,
28611 + AVR32_SYNTAX_BRVS,
28612 + AVR32_SYNTAX_BRVC,
28613 + AVR32_SYNTAX_BRQS,
28614 + AVR32_SYNTAX_BRAL,
28615 + AVR32_SYNTAX_BRHS2,
28616 + AVR32_SYNTAX_BRLO2,
28617 + AVR32_SYNTAX_BREAKPOINT,
28618 + AVR32_SYNTAX_BREV,
28619 + AVR32_SYNTAX_BST,
28620 + AVR32_SYNTAX_CACHE,
28621 + AVR32_SYNTAX_CASTS_B,
28622 + AVR32_SYNTAX_CASTS_H,
28623 + AVR32_SYNTAX_CASTU_B,
28624 + AVR32_SYNTAX_CASTU_H,
28625 + AVR32_SYNTAX_CBR,
28626 + AVR32_SYNTAX_CLZ,
28627 + AVR32_SYNTAX_COM,
28628 + AVR32_SYNTAX_COP,
28629 + AVR32_SYNTAX_CP_B,
28630 + AVR32_SYNTAX_CP_H,
28631 + AVR32_SYNTAX_CP_W1,
28632 + AVR32_SYNTAX_CP_W2,
28633 + AVR32_SYNTAX_CP_W3,
28634 + AVR32_SYNTAX_CPC1,
28635 + AVR32_SYNTAX_CPC2,
28636 + AVR32_SYNTAX_CSRF,
28637 + AVR32_SYNTAX_CSRFCZ,
28638 + AVR32_SYNTAX_DIVS,
28639 + AVR32_SYNTAX_DIVU,
28640 + AVR32_SYNTAX_EOR1,
28641 + AVR32_SYNTAX_EOR2,
28642 + AVR32_SYNTAX_EOR3,
28643 + AVR32_SYNTAX_EORL,
28644 + AVR32_SYNTAX_EORH,
28645 + AVR32_SYNTAX_FRS,
28646 + AVR32_SYNTAX_ICALL,
28647 + AVR32_SYNTAX_INCJOSP,
28648 + AVR32_SYNTAX_LD_D1,
28649 + AVR32_SYNTAX_LD_D2,
28650 + AVR32_SYNTAX_LD_D3,
28651 + AVR32_SYNTAX_LD_D5,
28652 + AVR32_SYNTAX_LD_D4,
28653 + AVR32_SYNTAX_LD_SB2,
28654 + AVR32_SYNTAX_LD_SB1,
28655 + AVR32_SYNTAX_LD_UB1,
28656 + AVR32_SYNTAX_LD_UB2,
28657 + AVR32_SYNTAX_LD_UB5,
28658 + AVR32_SYNTAX_LD_UB3,
28659 + AVR32_SYNTAX_LD_UB4,
28660 + AVR32_SYNTAX_LD_SH1,
28661 + AVR32_SYNTAX_LD_SH2,
28662 + AVR32_SYNTAX_LD_SH5,
28663 + AVR32_SYNTAX_LD_SH3,
28664 + AVR32_SYNTAX_LD_SH4,
28665 + AVR32_SYNTAX_LD_UH1,
28666 + AVR32_SYNTAX_LD_UH2,
28667 + AVR32_SYNTAX_LD_UH5,
28668 + AVR32_SYNTAX_LD_UH3,
28669 + AVR32_SYNTAX_LD_UH4,
28670 + AVR32_SYNTAX_LD_W1,
28671 + AVR32_SYNTAX_LD_W2,
28672 + AVR32_SYNTAX_LD_W5,
28673 + AVR32_SYNTAX_LD_W6,
28674 + AVR32_SYNTAX_LD_W3,
28675 + AVR32_SYNTAX_LD_W4,
28676 + AVR32_SYNTAX_LDC_D1,
28677 + AVR32_SYNTAX_LDC_D2,
28678 + AVR32_SYNTAX_LDC_D3,
28679 + AVR32_SYNTAX_LDC_W1,
28680 + AVR32_SYNTAX_LDC_W2,
28681 + AVR32_SYNTAX_LDC_W3,
28682 + AVR32_SYNTAX_LDC0_D,
28683 + AVR32_SYNTAX_LDC0_W,
28684 + AVR32_SYNTAX_LDCM_D,
28685 + AVR32_SYNTAX_LDCM_D_PU,
28686 + AVR32_SYNTAX_LDCM_W,
28687 + AVR32_SYNTAX_LDCM_W_PU,
28688 + AVR32_SYNTAX_LDDPC,
28689 + AVR32_SYNTAX_LDDPC_EXT,
28690 + AVR32_SYNTAX_LDDSP,
28691 + AVR32_SYNTAX_LDINS_B,
28692 + AVR32_SYNTAX_LDINS_H,
28693 + AVR32_SYNTAX_LDM,
28694 + AVR32_SYNTAX_LDMTS,
28695 + AVR32_SYNTAX_LDMTS_PU,
28696 + AVR32_SYNTAX_LDSWP_SH,
28697 + AVR32_SYNTAX_LDSWP_UH,
28698 + AVR32_SYNTAX_LDSWP_W,
28699 + AVR32_SYNTAX_LSL1,
28700 + AVR32_SYNTAX_LSL3,
28701 + AVR32_SYNTAX_LSL2,
28702 + AVR32_SYNTAX_LSR1,
28703 + AVR32_SYNTAX_LSR3,
28704 + AVR32_SYNTAX_LSR2,
28705 + AVR32_SYNTAX_MAC,
28706 + AVR32_SYNTAX_MACHH_D,
28707 + AVR32_SYNTAX_MACHH_W,
28708 + AVR32_SYNTAX_MACS_D,
28709 + AVR32_SYNTAX_MACSATHH_W,
28710 + AVR32_SYNTAX_MACUD,
28711 + AVR32_SYNTAX_MACWH_D,
28712 + AVR32_SYNTAX_MAX,
28713 + AVR32_SYNTAX_MCALL,
28714 + AVR32_SYNTAX_MFDR,
28715 + AVR32_SYNTAX_MFSR,
28716 + AVR32_SYNTAX_MIN,
28717 + AVR32_SYNTAX_MOV3,
28718 + AVR32_SYNTAX_MOV1,
28719 + AVR32_SYNTAX_MOV2,
28720 + AVR32_SYNTAX_MOVEQ1,
28721 + AVR32_SYNTAX_MOVNE1,
28722 + AVR32_SYNTAX_MOVCC1,
28723 + AVR32_SYNTAX_MOVCS1,
28724 + AVR32_SYNTAX_MOVGE1,
28725 + AVR32_SYNTAX_MOVLT1,
28726 + AVR32_SYNTAX_MOVMI1,
28727 + AVR32_SYNTAX_MOVPL1,
28728 + AVR32_SYNTAX_MOVLS1,
28729 + AVR32_SYNTAX_MOVGT1,
28730 + AVR32_SYNTAX_MOVLE1,
28731 + AVR32_SYNTAX_MOVHI1,
28732 + AVR32_SYNTAX_MOVVS1,
28733 + AVR32_SYNTAX_MOVVC1,
28734 + AVR32_SYNTAX_MOVQS1,
28735 + AVR32_SYNTAX_MOVAL1,
28736 + AVR32_SYNTAX_MOVHS1,
28737 + AVR32_SYNTAX_MOVLO1,
28738 + AVR32_SYNTAX_MOVEQ2,
28739 + AVR32_SYNTAX_MOVNE2,
28740 + AVR32_SYNTAX_MOVCC2,
28741 + AVR32_SYNTAX_MOVCS2,
28742 + AVR32_SYNTAX_MOVGE2,
28743 + AVR32_SYNTAX_MOVLT2,
28744 + AVR32_SYNTAX_MOVMI2,
28745 + AVR32_SYNTAX_MOVPL2,
28746 + AVR32_SYNTAX_MOVLS2,
28747 + AVR32_SYNTAX_MOVGT2,
28748 + AVR32_SYNTAX_MOVLE2,
28749 + AVR32_SYNTAX_MOVHI2,
28750 + AVR32_SYNTAX_MOVVS2,
28751 + AVR32_SYNTAX_MOVVC2,
28752 + AVR32_SYNTAX_MOVQS2,
28753 + AVR32_SYNTAX_MOVAL2,
28754 + AVR32_SYNTAX_MOVHS2,
28755 + AVR32_SYNTAX_MOVLO2,
28756 + AVR32_SYNTAX_MTDR,
28757 + AVR32_SYNTAX_MTSR,
28758 + AVR32_SYNTAX_MUL1,
28759 + AVR32_SYNTAX_MUL2,
28760 + AVR32_SYNTAX_MUL3,
28761 + AVR32_SYNTAX_MULHH_W,
28762 + AVR32_SYNTAX_MULNHH_W,
28763 + AVR32_SYNTAX_MULNWH_D,
28764 + AVR32_SYNTAX_MULSD,
28765 + AVR32_SYNTAX_MULSATHH_H,
28766 + AVR32_SYNTAX_MULSATHH_W,
28767 + AVR32_SYNTAX_MULSATRNDHH_H,
28768 + AVR32_SYNTAX_MULSATRNDWH_W,
28769 + AVR32_SYNTAX_MULSATWH_W,
28770 + AVR32_SYNTAX_MULU_D,
28771 + AVR32_SYNTAX_MULWH_D,
28772 + AVR32_SYNTAX_MUSFR,
28773 + AVR32_SYNTAX_MUSTR,
28774 + AVR32_SYNTAX_MVCR_D,
28775 + AVR32_SYNTAX_MVCR_W,
28776 + AVR32_SYNTAX_MVRC_D,
28777 + AVR32_SYNTAX_MVRC_W,
28778 + AVR32_SYNTAX_NEG,
28779 + AVR32_SYNTAX_NOP,
28780 + AVR32_SYNTAX_OR1,
28781 + AVR32_SYNTAX_OR2,
28782 + AVR32_SYNTAX_OR3,
28783 + AVR32_SYNTAX_ORH,
28784 + AVR32_SYNTAX_ORL,
28785 + AVR32_SYNTAX_PABS_SB,
28786 + AVR32_SYNTAX_PABS_SH,
28787 + AVR32_SYNTAX_PACKSH_SB,
28788 + AVR32_SYNTAX_PACKSH_UB,
28789 + AVR32_SYNTAX_PACKW_SH,
28790 + AVR32_SYNTAX_PADD_B,
28791 + AVR32_SYNTAX_PADD_H,
28792 + AVR32_SYNTAX_PADDH_SH,
28793 + AVR32_SYNTAX_PADDH_UB,
28794 + AVR32_SYNTAX_PADDS_SB,
28795 + AVR32_SYNTAX_PADDS_SH,
28796 + AVR32_SYNTAX_PADDS_UB,
28797 + AVR32_SYNTAX_PADDS_UH,
28798 + AVR32_SYNTAX_PADDSUB_H,
28799 + AVR32_SYNTAX_PADDSUBH_SH,
28800 + AVR32_SYNTAX_PADDSUBS_SH,
28801 + AVR32_SYNTAX_PADDSUBS_UH,
28802 + AVR32_SYNTAX_PADDX_H,
28803 + AVR32_SYNTAX_PADDXH_SH,
28804 + AVR32_SYNTAX_PADDXS_SH,
28805 + AVR32_SYNTAX_PADDXS_UH,
28806 + AVR32_SYNTAX_PASR_B,
28807 + AVR32_SYNTAX_PASR_H,
28808 + AVR32_SYNTAX_PAVG_SH,
28809 + AVR32_SYNTAX_PAVG_UB,
28810 + AVR32_SYNTAX_PLSL_B,
28811 + AVR32_SYNTAX_PLSL_H,
28812 + AVR32_SYNTAX_PLSR_B,
28813 + AVR32_SYNTAX_PLSR_H,
28814 + AVR32_SYNTAX_PMAX_SH,
28815 + AVR32_SYNTAX_PMAX_UB,
28816 + AVR32_SYNTAX_PMIN_SH,
28817 + AVR32_SYNTAX_PMIN_UB,
28818 + AVR32_SYNTAX_POPJC,
28819 + AVR32_SYNTAX_POPM,
28820 + AVR32_SYNTAX_POPM_E,
28821 + AVR32_SYNTAX_PREF,
28822 + AVR32_SYNTAX_PSAD,
28823 + AVR32_SYNTAX_PSUB_B,
28824 + AVR32_SYNTAX_PSUB_H,
28825 + AVR32_SYNTAX_PSUBADD_H,
28826 + AVR32_SYNTAX_PSUBADDH_SH,
28827 + AVR32_SYNTAX_PSUBADDS_SH,
28828 + AVR32_SYNTAX_PSUBADDS_UH,
28829 + AVR32_SYNTAX_PSUBH_SH,
28830 + AVR32_SYNTAX_PSUBH_UB,
28831 + AVR32_SYNTAX_PSUBS_SB,
28832 + AVR32_SYNTAX_PSUBS_SH,
28833 + AVR32_SYNTAX_PSUBS_UB,
28834 + AVR32_SYNTAX_PSUBS_UH,
28835 + AVR32_SYNTAX_PSUBX_H,
28836 + AVR32_SYNTAX_PSUBXH_SH,
28837 + AVR32_SYNTAX_PSUBXS_SH,
28838 + AVR32_SYNTAX_PSUBXS_UH,
28839 + AVR32_SYNTAX_PUNPCKSB_H,
28840 + AVR32_SYNTAX_PUNPCKUB_H,
28841 + AVR32_SYNTAX_PUSHJC,
28842 + AVR32_SYNTAX_PUSHM,
28843 + AVR32_SYNTAX_PUSHM_E,
28844 + AVR32_SYNTAX_RCALL1,
28845 + AVR32_SYNTAX_RCALL2,
28846 + AVR32_SYNTAX_RETEQ,
28847 + AVR32_SYNTAX_RETNE,
28848 + AVR32_SYNTAX_RETCC,
28849 + AVR32_SYNTAX_RETCS,
28850 + AVR32_SYNTAX_RETGE,
28851 + AVR32_SYNTAX_RETLT,
28852 + AVR32_SYNTAX_RETMI,
28853 + AVR32_SYNTAX_RETPL,
28854 + AVR32_SYNTAX_RETLS,
28855 + AVR32_SYNTAX_RETGT,
28856 + AVR32_SYNTAX_RETLE,
28857 + AVR32_SYNTAX_RETHI,
28858 + AVR32_SYNTAX_RETVS,
28859 + AVR32_SYNTAX_RETVC,
28860 + AVR32_SYNTAX_RETQS,
28861 + AVR32_SYNTAX_RETAL,
28862 + AVR32_SYNTAX_RETHS,
28863 + AVR32_SYNTAX_RETLO,
28864 + AVR32_SYNTAX_RETD,
28865 + AVR32_SYNTAX_RETE,
28866 + AVR32_SYNTAX_RETJ,
28867 + AVR32_SYNTAX_RETS,
28868 + AVR32_SYNTAX_RJMP,
28869 + AVR32_SYNTAX_ROL,
28870 + AVR32_SYNTAX_ROR,
28871 + AVR32_SYNTAX_RSUB1,
28872 + AVR32_SYNTAX_RSUB2,
28873 + AVR32_SYNTAX_SATADD_H,
28874 + AVR32_SYNTAX_SATADD_W,
28875 + AVR32_SYNTAX_SATRNDS,
28876 + AVR32_SYNTAX_SATRNDU,
28877 + AVR32_SYNTAX_SATS,
28878 + AVR32_SYNTAX_SATSUB_H,
28879 + AVR32_SYNTAX_SATSUB_W1,
28880 + AVR32_SYNTAX_SATSUB_W2,
28881 + AVR32_SYNTAX_SATU,
28882 + AVR32_SYNTAX_SBC,
28883 + AVR32_SYNTAX_SBR,
28884 + AVR32_SYNTAX_SCALL,
28885 + AVR32_SYNTAX_SCR,
28886 + AVR32_SYNTAX_SLEEP,
28887 + AVR32_SYNTAX_SREQ,
28888 + AVR32_SYNTAX_SRNE,
28889 + AVR32_SYNTAX_SRCC,
28890 + AVR32_SYNTAX_SRCS,
28891 + AVR32_SYNTAX_SRGE,
28892 + AVR32_SYNTAX_SRLT,
28893 + AVR32_SYNTAX_SRMI,
28894 + AVR32_SYNTAX_SRPL,
28895 + AVR32_SYNTAX_SRLS,
28896 + AVR32_SYNTAX_SRGT,
28897 + AVR32_SYNTAX_SRLE,
28898 + AVR32_SYNTAX_SRHI,
28899 + AVR32_SYNTAX_SRVS,
28900 + AVR32_SYNTAX_SRVC,
28901 + AVR32_SYNTAX_SRQS,
28902 + AVR32_SYNTAX_SRAL,
28903 + AVR32_SYNTAX_SRHS,
28904 + AVR32_SYNTAX_SRLO,
28905 + AVR32_SYNTAX_SSRF,
28906 + AVR32_SYNTAX_ST_B1,
28907 + AVR32_SYNTAX_ST_B2,
28908 + AVR32_SYNTAX_ST_B5,
28909 + AVR32_SYNTAX_ST_B3,
28910 + AVR32_SYNTAX_ST_B4,
28911 + AVR32_SYNTAX_ST_D1,
28912 + AVR32_SYNTAX_ST_D2,
28913 + AVR32_SYNTAX_ST_D3,
28914 + AVR32_SYNTAX_ST_D5,
28915 + AVR32_SYNTAX_ST_D4,
28916 + AVR32_SYNTAX_ST_H1,
28917 + AVR32_SYNTAX_ST_H2,
28918 + AVR32_SYNTAX_ST_H5,
28919 + AVR32_SYNTAX_ST_H3,
28920 + AVR32_SYNTAX_ST_H4,
28921 + AVR32_SYNTAX_ST_W1,
28922 + AVR32_SYNTAX_ST_W2,
28923 + AVR32_SYNTAX_ST_W5,
28924 + AVR32_SYNTAX_ST_W3,
28925 + AVR32_SYNTAX_ST_W4,
28926 + AVR32_SYNTAX_STC_D1,
28927 + AVR32_SYNTAX_STC_D2,
28928 + AVR32_SYNTAX_STC_D3,
28929 + AVR32_SYNTAX_STC_W1,
28930 + AVR32_SYNTAX_STC_W2,
28931 + AVR32_SYNTAX_STC_W3,
28932 + AVR32_SYNTAX_STC0_D,
28933 + AVR32_SYNTAX_STC0_W,
28934 + AVR32_SYNTAX_STCM_D,
28935 + AVR32_SYNTAX_STCM_D_PU,
28936 + AVR32_SYNTAX_STCM_W,
28937 + AVR32_SYNTAX_STCM_W_PU,
28938 + AVR32_SYNTAX_STCOND,
28939 + AVR32_SYNTAX_STDSP,
28940 + AVR32_SYNTAX_STHH_W2,
28941 + AVR32_SYNTAX_STHH_W1,
28942 + AVR32_SYNTAX_STM,
28943 + AVR32_SYNTAX_STM_PU,
28944 + AVR32_SYNTAX_STMTS,
28945 + AVR32_SYNTAX_STMTS_PU,
28946 + AVR32_SYNTAX_STSWP_H,
28947 + AVR32_SYNTAX_STSWP_W,
28948 + AVR32_SYNTAX_SUB1,
28949 + AVR32_SYNTAX_SUB2,
28950 + AVR32_SYNTAX_SUB5,
28951 + AVR32_SYNTAX_SUB3_SP,
28952 + AVR32_SYNTAX_SUB3,
28953 + AVR32_SYNTAX_SUB4,
28954 + AVR32_SYNTAX_SUBEQ,
28955 + AVR32_SYNTAX_SUBNE,
28956 + AVR32_SYNTAX_SUBCC,
28957 + AVR32_SYNTAX_SUBCS,
28958 + AVR32_SYNTAX_SUBGE,
28959 + AVR32_SYNTAX_SUBLT,
28960 + AVR32_SYNTAX_SUBMI,
28961 + AVR32_SYNTAX_SUBPL,
28962 + AVR32_SYNTAX_SUBLS,
28963 + AVR32_SYNTAX_SUBGT,
28964 + AVR32_SYNTAX_SUBLE,
28965 + AVR32_SYNTAX_SUBHI,
28966 + AVR32_SYNTAX_SUBVS,
28967 + AVR32_SYNTAX_SUBVC,
28968 + AVR32_SYNTAX_SUBQS,
28969 + AVR32_SYNTAX_SUBAL,
28970 + AVR32_SYNTAX_SUBHS,
28971 + AVR32_SYNTAX_SUBLO,
28972 + AVR32_SYNTAX_SUBFEQ,
28973 + AVR32_SYNTAX_SUBFNE,
28974 + AVR32_SYNTAX_SUBFCC,
28975 + AVR32_SYNTAX_SUBFCS,
28976 + AVR32_SYNTAX_SUBFGE,
28977 + AVR32_SYNTAX_SUBFLT,
28978 + AVR32_SYNTAX_SUBFMI,
28979 + AVR32_SYNTAX_SUBFPL,
28980 + AVR32_SYNTAX_SUBFLS,
28981 + AVR32_SYNTAX_SUBFGT,
28982 + AVR32_SYNTAX_SUBFLE,
28983 + AVR32_SYNTAX_SUBFHI,
28984 + AVR32_SYNTAX_SUBFVS,
28985 + AVR32_SYNTAX_SUBFVC,
28986 + AVR32_SYNTAX_SUBFQS,
28987 + AVR32_SYNTAX_SUBFAL,
28988 + AVR32_SYNTAX_SUBFHS,
28989 + AVR32_SYNTAX_SUBFLO,
28990 + AVR32_SYNTAX_SUBHH_W,
28991 + AVR32_SYNTAX_SWAP_B,
28992 + AVR32_SYNTAX_SWAP_BH,
28993 + AVR32_SYNTAX_SWAP_H,
28994 + AVR32_SYNTAX_SYNC,
28995 + AVR32_SYNTAX_TLBR,
28996 + AVR32_SYNTAX_TLBS,
28997 + AVR32_SYNTAX_TLBW,
28998 + AVR32_SYNTAX_TNBZ,
28999 + AVR32_SYNTAX_TST,
29000 + AVR32_SYNTAX_XCHG,
29001 + AVR32_SYNTAX_MEMC,
29002 + AVR32_SYNTAX_MEMS,
29003 + AVR32_SYNTAX_MEMT,
29004 + AVR32_SYNTAX_FADD_S,
29005 + AVR32_SYNTAX_FADD_D,
29006 + AVR32_SYNTAX_FSUB_S,
29007 + AVR32_SYNTAX_FSUB_D,
29008 + AVR32_SYNTAX_FMAC_S,
29009 + AVR32_SYNTAX_FMAC_D,
29010 + AVR32_SYNTAX_FNMAC_S,
29011 + AVR32_SYNTAX_FNMAC_D,
29012 + AVR32_SYNTAX_FMSC_S,
29013 + AVR32_SYNTAX_FMSC_D,
29014 + AVR32_SYNTAX_FNMSC_S,
29015 + AVR32_SYNTAX_FNMSC_D,
29016 + AVR32_SYNTAX_FMUL_S,
29017 + AVR32_SYNTAX_FMUL_D,
29018 + AVR32_SYNTAX_FNMUL_S,
29019 + AVR32_SYNTAX_FNMUL_D,
29020 + AVR32_SYNTAX_FNEG_S,
29021 + AVR32_SYNTAX_FNEG_D,
29022 + AVR32_SYNTAX_FABS_S,
29023 + AVR32_SYNTAX_FABS_D,
29024 + AVR32_SYNTAX_FCMP_S,
29025 + AVR32_SYNTAX_FCMP_D,
29026 + AVR32_SYNTAX_FMOV1_S,
29027 + AVR32_SYNTAX_FMOV1_D,
29028 + AVR32_SYNTAX_FMOV2_S,
29029 + AVR32_SYNTAX_FMOV2_D,
29030 + AVR32_SYNTAX_FMOV3_S,
29031 + AVR32_SYNTAX_FMOV3_D,
29032 + AVR32_SYNTAX_FCASTS_D,
29033 + AVR32_SYNTAX_FCASTD_S,
29034 + AVR32_SYNTAX_LDA_W,
29035 + AVR32_SYNTAX_CALL,
29036 + AVR32_SYNTAX_PICOSVMAC0,
29037 + AVR32_SYNTAX_PICOSVMAC1,
29038 + AVR32_SYNTAX_PICOSVMAC2,
29039 + AVR32_SYNTAX_PICOSVMAC3,
29040 + AVR32_SYNTAX_PICOSVMUL0,
29041 + AVR32_SYNTAX_PICOSVMUL1,
29042 + AVR32_SYNTAX_PICOSVMUL2,
29043 + AVR32_SYNTAX_PICOSVMUL3,
29044 + AVR32_SYNTAX_PICOVMAC0,
29045 + AVR32_SYNTAX_PICOVMAC1,
29046 + AVR32_SYNTAX_PICOVMAC2,
29047 + AVR32_SYNTAX_PICOVMAC3,
29048 + AVR32_SYNTAX_PICOVMUL0,
29049 + AVR32_SYNTAX_PICOVMUL1,
29050 + AVR32_SYNTAX_PICOVMUL2,
29051 + AVR32_SYNTAX_PICOVMUL3,
29052 + AVR32_SYNTAX_PICOLD_D2,
29053 + AVR32_SYNTAX_PICOLD_D3,
29054 + AVR32_SYNTAX_PICOLD_D1,
29055 + AVR32_SYNTAX_PICOLD_W2,
29056 + AVR32_SYNTAX_PICOLD_W3,
29057 + AVR32_SYNTAX_PICOLD_W1,
29058 + AVR32_SYNTAX_PICOLDM_D,
29059 + AVR32_SYNTAX_PICOLDM_D_PU,
29060 + AVR32_SYNTAX_PICOLDM_W,
29061 + AVR32_SYNTAX_PICOLDM_W_PU,
29062 + AVR32_SYNTAX_PICOMV_D1,
29063 + AVR32_SYNTAX_PICOMV_D2,
29064 + AVR32_SYNTAX_PICOMV_W1,
29065 + AVR32_SYNTAX_PICOMV_W2,
29066 + AVR32_SYNTAX_PICOST_D2,
29067 + AVR32_SYNTAX_PICOST_D3,
29068 + AVR32_SYNTAX_PICOST_D1,
29069 + AVR32_SYNTAX_PICOST_W2,
29070 + AVR32_SYNTAX_PICOST_W3,
29071 + AVR32_SYNTAX_PICOST_W1,
29072 + AVR32_SYNTAX_PICOSTM_D,
29073 + AVR32_SYNTAX_PICOSTM_D_PU,
29074 + AVR32_SYNTAX_PICOSTM_W,
29075 + AVR32_SYNTAX_PICOSTM_W_PU,
29076 + AVR32_SYNTAX_RSUBEQ,
29077 + AVR32_SYNTAX_RSUBNE,
29078 + AVR32_SYNTAX_RSUBCC,
29079 + AVR32_SYNTAX_RSUBCS,
29080 + AVR32_SYNTAX_RSUBGE,
29081 + AVR32_SYNTAX_RSUBLT,
29082 + AVR32_SYNTAX_RSUBMI,
29083 + AVR32_SYNTAX_RSUBPL,
29084 + AVR32_SYNTAX_RSUBLS,
29085 + AVR32_SYNTAX_RSUBGT,
29086 + AVR32_SYNTAX_RSUBLE,
29087 + AVR32_SYNTAX_RSUBHI,
29088 + AVR32_SYNTAX_RSUBVS,
29089 + AVR32_SYNTAX_RSUBVC,
29090 + AVR32_SYNTAX_RSUBQS,
29091 + AVR32_SYNTAX_RSUBAL,
29092 + AVR32_SYNTAX_RSUBHS,
29093 + AVR32_SYNTAX_RSUBLO,
29094 + AVR32_SYNTAX_ADDEQ,
29095 + AVR32_SYNTAX_ADDNE,
29096 + AVR32_SYNTAX_ADDCC,
29097 + AVR32_SYNTAX_ADDCS,
29098 + AVR32_SYNTAX_ADDGE,
29099 + AVR32_SYNTAX_ADDLT,
29100 + AVR32_SYNTAX_ADDMI,
29101 + AVR32_SYNTAX_ADDPL,
29102 + AVR32_SYNTAX_ADDLS,
29103 + AVR32_SYNTAX_ADDGT,
29104 + AVR32_SYNTAX_ADDLE,
29105 + AVR32_SYNTAX_ADDHI,
29106 + AVR32_SYNTAX_ADDVS,
29107 + AVR32_SYNTAX_ADDVC,
29108 + AVR32_SYNTAX_ADDQS,
29109 + AVR32_SYNTAX_ADDAL,
29110 + AVR32_SYNTAX_ADDHS,
29111 + AVR32_SYNTAX_ADDLO,
29112 + AVR32_SYNTAX_SUB2EQ,
29113 + AVR32_SYNTAX_SUB2NE,
29114 + AVR32_SYNTAX_SUB2CC,
29115 + AVR32_SYNTAX_SUB2CS,
29116 + AVR32_SYNTAX_SUB2GE,
29117 + AVR32_SYNTAX_SUB2LT,
29118 + AVR32_SYNTAX_SUB2MI,
29119 + AVR32_SYNTAX_SUB2PL,
29120 + AVR32_SYNTAX_SUB2LS,
29121 + AVR32_SYNTAX_SUB2GT,
29122 + AVR32_SYNTAX_SUB2LE,
29123 + AVR32_SYNTAX_SUB2HI,
29124 + AVR32_SYNTAX_SUB2VS,
29125 + AVR32_SYNTAX_SUB2VC,
29126 + AVR32_SYNTAX_SUB2QS,
29127 + AVR32_SYNTAX_SUB2AL,
29128 + AVR32_SYNTAX_SUB2HS,
29129 + AVR32_SYNTAX_SUB2LO,
29130 + AVR32_SYNTAX_ANDEQ,
29131 + AVR32_SYNTAX_ANDNE,
29132 + AVR32_SYNTAX_ANDCC,
29133 + AVR32_SYNTAX_ANDCS,
29134 + AVR32_SYNTAX_ANDGE,
29135 + AVR32_SYNTAX_ANDLT,
29136 + AVR32_SYNTAX_ANDMI,
29137 + AVR32_SYNTAX_ANDPL,
29138 + AVR32_SYNTAX_ANDLS,
29139 + AVR32_SYNTAX_ANDGT,
29140 + AVR32_SYNTAX_ANDLE,
29141 + AVR32_SYNTAX_ANDHI,
29142 + AVR32_SYNTAX_ANDVS,
29143 + AVR32_SYNTAX_ANDVC,
29144 + AVR32_SYNTAX_ANDQS,
29145 + AVR32_SYNTAX_ANDAL,
29146 + AVR32_SYNTAX_ANDHS,
29147 + AVR32_SYNTAX_ANDLO,
29148 + AVR32_SYNTAX_OREQ,
29149 + AVR32_SYNTAX_ORNE,
29150 + AVR32_SYNTAX_ORCC,
29151 + AVR32_SYNTAX_ORCS,
29152 + AVR32_SYNTAX_ORGE,
29153 + AVR32_SYNTAX_ORLT,
29154 + AVR32_SYNTAX_ORMI,
29155 + AVR32_SYNTAX_ORPL,
29156 + AVR32_SYNTAX_ORLS,
29157 + AVR32_SYNTAX_ORGT,
29158 + AVR32_SYNTAX_ORLE,
29159 + AVR32_SYNTAX_ORHI,
29160 + AVR32_SYNTAX_ORVS,
29161 + AVR32_SYNTAX_ORVC,
29162 + AVR32_SYNTAX_ORQS,
29163 + AVR32_SYNTAX_ORAL,
29164 + AVR32_SYNTAX_ORHS,
29165 + AVR32_SYNTAX_ORLO,
29166 + AVR32_SYNTAX_EOREQ,
29167 + AVR32_SYNTAX_EORNE,
29168 + AVR32_SYNTAX_EORCC,
29169 + AVR32_SYNTAX_EORCS,
29170 + AVR32_SYNTAX_EORGE,
29171 + AVR32_SYNTAX_EORLT,
29172 + AVR32_SYNTAX_EORMI,
29173 + AVR32_SYNTAX_EORPL,
29174 + AVR32_SYNTAX_EORLS,
29175 + AVR32_SYNTAX_EORGT,
29176 + AVR32_SYNTAX_EORLE,
29177 + AVR32_SYNTAX_EORHI,
29178 + AVR32_SYNTAX_EORVS,
29179 + AVR32_SYNTAX_EORVC,
29180 + AVR32_SYNTAX_EORQS,
29181 + AVR32_SYNTAX_EORAL,
29182 + AVR32_SYNTAX_EORHS,
29183 + AVR32_SYNTAX_EORLO,
29184 + AVR32_SYNTAX_LD_WEQ,
29185 + AVR32_SYNTAX_LD_WNE,
29186 + AVR32_SYNTAX_LD_WCC,
29187 + AVR32_SYNTAX_LD_WCS,
29188 + AVR32_SYNTAX_LD_WGE,
29189 + AVR32_SYNTAX_LD_WLT,
29190 + AVR32_SYNTAX_LD_WMI,
29191 + AVR32_SYNTAX_LD_WPL,
29192 + AVR32_SYNTAX_LD_WLS,
29193 + AVR32_SYNTAX_LD_WGT,
29194 + AVR32_SYNTAX_LD_WLE,
29195 + AVR32_SYNTAX_LD_WHI,
29196 + AVR32_SYNTAX_LD_WVS,
29197 + AVR32_SYNTAX_LD_WVC,
29198 + AVR32_SYNTAX_LD_WQS,
29199 + AVR32_SYNTAX_LD_WAL,
29200 + AVR32_SYNTAX_LD_WHS,
29201 + AVR32_SYNTAX_LD_WLO,
29202 + AVR32_SYNTAX_LD_SHEQ,
29203 + AVR32_SYNTAX_LD_SHNE,
29204 + AVR32_SYNTAX_LD_SHCC,
29205 + AVR32_SYNTAX_LD_SHCS,
29206 + AVR32_SYNTAX_LD_SHGE,
29207 + AVR32_SYNTAX_LD_SHLT,
29208 + AVR32_SYNTAX_LD_SHMI,
29209 + AVR32_SYNTAX_LD_SHPL,
29210 + AVR32_SYNTAX_LD_SHLS,
29211 + AVR32_SYNTAX_LD_SHGT,
29212 + AVR32_SYNTAX_LD_SHLE,
29213 + AVR32_SYNTAX_LD_SHHI,
29214 + AVR32_SYNTAX_LD_SHVS,
29215 + AVR32_SYNTAX_LD_SHVC,
29216 + AVR32_SYNTAX_LD_SHQS,
29217 + AVR32_SYNTAX_LD_SHAL,
29218 + AVR32_SYNTAX_LD_SHHS,
29219 + AVR32_SYNTAX_LD_SHLO,
29220 + AVR32_SYNTAX_LD_UHEQ,
29221 + AVR32_SYNTAX_LD_UHNE,
29222 + AVR32_SYNTAX_LD_UHCC,
29223 + AVR32_SYNTAX_LD_UHCS,
29224 + AVR32_SYNTAX_LD_UHGE,
29225 + AVR32_SYNTAX_LD_UHLT,
29226 + AVR32_SYNTAX_LD_UHMI,
29227 + AVR32_SYNTAX_LD_UHPL,
29228 + AVR32_SYNTAX_LD_UHLS,
29229 + AVR32_SYNTAX_LD_UHGT,
29230 + AVR32_SYNTAX_LD_UHLE,
29231 + AVR32_SYNTAX_LD_UHHI,
29232 + AVR32_SYNTAX_LD_UHVS,
29233 + AVR32_SYNTAX_LD_UHVC,
29234 + AVR32_SYNTAX_LD_UHQS,
29235 + AVR32_SYNTAX_LD_UHAL,
29236 + AVR32_SYNTAX_LD_UHHS,
29237 + AVR32_SYNTAX_LD_UHLO,
29238 + AVR32_SYNTAX_LD_SBEQ,
29239 + AVR32_SYNTAX_LD_SBNE,
29240 + AVR32_SYNTAX_LD_SBCC,
29241 + AVR32_SYNTAX_LD_SBCS,
29242 + AVR32_SYNTAX_LD_SBGE,
29243 + AVR32_SYNTAX_LD_SBLT,
29244 + AVR32_SYNTAX_LD_SBMI,
29245 + AVR32_SYNTAX_LD_SBPL,
29246 + AVR32_SYNTAX_LD_SBLS,
29247 + AVR32_SYNTAX_LD_SBGT,
29248 + AVR32_SYNTAX_LD_SBLE,
29249 + AVR32_SYNTAX_LD_SBHI,
29250 + AVR32_SYNTAX_LD_SBVS,
29251 + AVR32_SYNTAX_LD_SBVC,
29252 + AVR32_SYNTAX_LD_SBQS,
29253 + AVR32_SYNTAX_LD_SBAL,
29254 + AVR32_SYNTAX_LD_SBHS,
29255 + AVR32_SYNTAX_LD_SBLO,
29256 + AVR32_SYNTAX_LD_UBEQ,
29257 + AVR32_SYNTAX_LD_UBNE,
29258 + AVR32_SYNTAX_LD_UBCC,
29259 + AVR32_SYNTAX_LD_UBCS,
29260 + AVR32_SYNTAX_LD_UBGE,
29261 + AVR32_SYNTAX_LD_UBLT,
29262 + AVR32_SYNTAX_LD_UBMI,
29263 + AVR32_SYNTAX_LD_UBPL,
29264 + AVR32_SYNTAX_LD_UBLS,
29265 + AVR32_SYNTAX_LD_UBGT,
29266 + AVR32_SYNTAX_LD_UBLE,
29267 + AVR32_SYNTAX_LD_UBHI,
29268 + AVR32_SYNTAX_LD_UBVS,
29269 + AVR32_SYNTAX_LD_UBVC,
29270 + AVR32_SYNTAX_LD_UBQS,
29271 + AVR32_SYNTAX_LD_UBAL,
29272 + AVR32_SYNTAX_LD_UBHS,
29273 + AVR32_SYNTAX_LD_UBLO,
29274 + AVR32_SYNTAX_ST_WEQ,
29275 + AVR32_SYNTAX_ST_WNE,
29276 + AVR32_SYNTAX_ST_WCC,
29277 + AVR32_SYNTAX_ST_WCS,
29278 + AVR32_SYNTAX_ST_WGE,
29279 + AVR32_SYNTAX_ST_WLT,
29280 + AVR32_SYNTAX_ST_WMI,
29281 + AVR32_SYNTAX_ST_WPL,
29282 + AVR32_SYNTAX_ST_WLS,
29283 + AVR32_SYNTAX_ST_WGT,
29284 + AVR32_SYNTAX_ST_WLE,
29285 + AVR32_SYNTAX_ST_WHI,
29286 + AVR32_SYNTAX_ST_WVS,
29287 + AVR32_SYNTAX_ST_WVC,
29288 + AVR32_SYNTAX_ST_WQS,
29289 + AVR32_SYNTAX_ST_WAL,
29290 + AVR32_SYNTAX_ST_WHS,
29291 + AVR32_SYNTAX_ST_WLO,
29292 + AVR32_SYNTAX_ST_HEQ,
29293 + AVR32_SYNTAX_ST_HNE,
29294 + AVR32_SYNTAX_ST_HCC,
29295 + AVR32_SYNTAX_ST_HCS,
29296 + AVR32_SYNTAX_ST_HGE,
29297 + AVR32_SYNTAX_ST_HLT,
29298 + AVR32_SYNTAX_ST_HMI,
29299 + AVR32_SYNTAX_ST_HPL,
29300 + AVR32_SYNTAX_ST_HLS,
29301 + AVR32_SYNTAX_ST_HGT,
29302 + AVR32_SYNTAX_ST_HLE,
29303 + AVR32_SYNTAX_ST_HHI,
29304 + AVR32_SYNTAX_ST_HVS,
29305 + AVR32_SYNTAX_ST_HVC,
29306 + AVR32_SYNTAX_ST_HQS,
29307 + AVR32_SYNTAX_ST_HAL,
29308 + AVR32_SYNTAX_ST_HHS,
29309 + AVR32_SYNTAX_ST_HLO,
29310 + AVR32_SYNTAX_ST_BEQ,
29311 + AVR32_SYNTAX_ST_BNE,
29312 + AVR32_SYNTAX_ST_BCC,
29313 + AVR32_SYNTAX_ST_BCS,
29314 + AVR32_SYNTAX_ST_BGE,
29315 + AVR32_SYNTAX_ST_BLT,
29316 + AVR32_SYNTAX_ST_BMI,
29317 + AVR32_SYNTAX_ST_BPL,
29318 + AVR32_SYNTAX_ST_BLS,
29319 + AVR32_SYNTAX_ST_BGT,
29320 + AVR32_SYNTAX_ST_BLE,
29321 + AVR32_SYNTAX_ST_BHI,
29322 + AVR32_SYNTAX_ST_BVS,
29323 + AVR32_SYNTAX_ST_BVC,
29324 + AVR32_SYNTAX_ST_BQS,
29325 + AVR32_SYNTAX_ST_BAL,
29326 + AVR32_SYNTAX_ST_BHS,
29327 + AVR32_SYNTAX_ST_BLO,
29328 + AVR32_SYNTAX_MOVH,
29329 + AVR32_SYNTAX__END_
29330 +};
29331 +#define AVR32_NR_SYNTAX AVR32_SYNTAX__END_
29332 +
29333 +enum avr32_alias_type
29334 + {
29335 + AVR32_ALIAS_FMAC_S,
29336 + AVR32_ALIAS_FMAC_D,
29337 + AVR32_ALIAS_FNMAC_S,
29338 + AVR32_ALIAS_FNMAC_D,
29339 + AVR32_ALIAS_FMSC_S,
29340 + AVR32_ALIAS_FMSC_D,
29341 + AVR32_ALIAS_FNMSC_S,
29342 + AVR32_ALIAS_FNMSC_D,
29343 + AVR32_ALIAS_FADD_S,
29344 + AVR32_ALIAS_FADD_D,
29345 + AVR32_ALIAS_FSUB_S,
29346 + AVR32_ALIAS_FSUB_D,
29347 + AVR32_ALIAS_FMUL_S,
29348 + AVR32_ALIAS_FMUL_D,
29349 + AVR32_ALIAS_FNMUL_S,
29350 + AVR32_ALIAS_FNMUL_D,
29351 + AVR32_ALIAS_FNEG_S,
29352 + AVR32_ALIAS_FNEG_D,
29353 + AVR32_ALIAS_FABS_S,
29354 + AVR32_ALIAS_FABS_D,
29355 + AVR32_ALIAS_FCMP_S,
29356 + AVR32_ALIAS_FCMP_D,
29357 + AVR32_ALIAS_FMOV1_S,
29358 + AVR32_ALIAS_FMOV1_D,
29359 + AVR32_ALIAS_FMOV2_S,
29360 + AVR32_ALIAS_FMOV2_D,
29361 + AVR32_ALIAS_FMOV3_S,
29362 + AVR32_ALIAS_FMOV3_D,
29363 + AVR32_ALIAS_FCASTS_D,
29364 + AVR32_ALIAS_FCASTD_S,
29365 + AVR32_ALIAS_PICOSVMAC0,
29366 + AVR32_ALIAS_PICOSVMAC1,
29367 + AVR32_ALIAS_PICOSVMAC2,
29368 + AVR32_ALIAS_PICOSVMAC3,
29369 + AVR32_ALIAS_PICOSVMUL0,
29370 + AVR32_ALIAS_PICOSVMUL1,
29371 + AVR32_ALIAS_PICOSVMUL2,
29372 + AVR32_ALIAS_PICOSVMUL3,
29373 + AVR32_ALIAS_PICOVMAC0,
29374 + AVR32_ALIAS_PICOVMAC1,
29375 + AVR32_ALIAS_PICOVMAC2,
29376 + AVR32_ALIAS_PICOVMAC3,
29377 + AVR32_ALIAS_PICOVMUL0,
29378 + AVR32_ALIAS_PICOVMUL1,
29379 + AVR32_ALIAS_PICOVMUL2,
29380 + AVR32_ALIAS_PICOVMUL3,
29381 + AVR32_ALIAS_PICOLD_D1,
29382 + AVR32_ALIAS_PICOLD_D2,
29383 + AVR32_ALIAS_PICOLD_D3,
29384 + AVR32_ALIAS_PICOLD_W1,
29385 + AVR32_ALIAS_PICOLD_W2,
29386 + AVR32_ALIAS_PICOLD_W3,
29387 + AVR32_ALIAS_PICOLDM_D,
29388 + AVR32_ALIAS_PICOLDM_D_PU,
29389 + AVR32_ALIAS_PICOLDM_W,
29390 + AVR32_ALIAS_PICOLDM_W_PU,
29391 + AVR32_ALIAS_PICOMV_D1,
29392 + AVR32_ALIAS_PICOMV_D2,
29393 + AVR32_ALIAS_PICOMV_W1,
29394 + AVR32_ALIAS_PICOMV_W2,
29395 + AVR32_ALIAS_PICOST_D1,
29396 + AVR32_ALIAS_PICOST_D2,
29397 + AVR32_ALIAS_PICOST_D3,
29398 + AVR32_ALIAS_PICOST_W1,
29399 + AVR32_ALIAS_PICOST_W2,
29400 + AVR32_ALIAS_PICOST_W3,
29401 + AVR32_ALIAS_PICOSTM_D,
29402 + AVR32_ALIAS_PICOSTM_D_PU,
29403 + AVR32_ALIAS_PICOSTM_W,
29404 + AVR32_ALIAS_PICOSTM_W_PU,
29405 + AVR32_ALIAS__END_
29406 + };
29407 +#define AVR32_NR_ALIAS AVR32_ALIAS__END_
29408 +
29409 +enum avr32_mnemonic_type
29410 +{
29411 + AVR32_MNEMONIC_ABS,
29412 + AVR32_MNEMONIC_ACALL,
29413 + AVR32_MNEMONIC_ACR,
29414 + AVR32_MNEMONIC_ADC,
29415 + AVR32_MNEMONIC_ADD,
29416 + AVR32_MNEMONIC_ADDABS,
29417 + AVR32_MNEMONIC_ADDHH_W,
29418 + AVR32_MNEMONIC_AND,
29419 + AVR32_MNEMONIC_ANDH,
29420 + AVR32_MNEMONIC_ANDL,
29421 + AVR32_MNEMONIC_ANDN,
29422 + AVR32_MNEMONIC_ASR,
29423 + AVR32_MNEMONIC_BFEXTS,
29424 + AVR32_MNEMONIC_BFEXTU,
29425 + AVR32_MNEMONIC_BFINS,
29426 + AVR32_MNEMONIC_BLD,
29427 + AVR32_MNEMONIC_BREQ,
29428 + AVR32_MNEMONIC_BRNE,
29429 + AVR32_MNEMONIC_BRCC,
29430 + AVR32_MNEMONIC_BRCS,
29431 + AVR32_MNEMONIC_BRGE,
29432 + AVR32_MNEMONIC_BRLT,
29433 + AVR32_MNEMONIC_BRMI,
29434 + AVR32_MNEMONIC_BRPL,
29435 + AVR32_MNEMONIC_BRHS,
29436 + AVR32_MNEMONIC_BRLO,
29437 + AVR32_MNEMONIC_BRLS,
29438 + AVR32_MNEMONIC_BRGT,
29439 + AVR32_MNEMONIC_BRLE,
29440 + AVR32_MNEMONIC_BRHI,
29441 + AVR32_MNEMONIC_BRVS,
29442 + AVR32_MNEMONIC_BRVC,
29443 + AVR32_MNEMONIC_BRQS,
29444 + AVR32_MNEMONIC_BRAL,
29445 + AVR32_MNEMONIC_BREAKPOINT,
29446 + AVR32_MNEMONIC_BREV,
29447 + AVR32_MNEMONIC_BST,
29448 + AVR32_MNEMONIC_CACHE,
29449 + AVR32_MNEMONIC_CASTS_B,
29450 + AVR32_MNEMONIC_CASTS_H,
29451 + AVR32_MNEMONIC_CASTU_B,
29452 + AVR32_MNEMONIC_CASTU_H,
29453 + AVR32_MNEMONIC_CBR,
29454 + AVR32_MNEMONIC_CLZ,
29455 + AVR32_MNEMONIC_COM,
29456 + AVR32_MNEMONIC_COP,
29457 + AVR32_MNEMONIC_CP_B,
29458 + AVR32_MNEMONIC_CP_H,
29459 + AVR32_MNEMONIC_CP_W,
29460 + AVR32_MNEMONIC_CP,
29461 + AVR32_MNEMONIC_CPC,
29462 + AVR32_MNEMONIC_CSRF,
29463 + AVR32_MNEMONIC_CSRFCZ,
29464 + AVR32_MNEMONIC_DIVS,
29465 + AVR32_MNEMONIC_DIVU,
29466 + AVR32_MNEMONIC_EOR,
29467 + AVR32_MNEMONIC_EORL,
29468 + AVR32_MNEMONIC_EORH,
29469 + AVR32_MNEMONIC_FRS,
29470 + AVR32_MNEMONIC_ICALL,
29471 + AVR32_MNEMONIC_INCJOSP,
29472 + AVR32_MNEMONIC_LD_D,
29473 + AVR32_MNEMONIC_LD_SB,
29474 + AVR32_MNEMONIC_LD_UB,
29475 + AVR32_MNEMONIC_LD_SH,
29476 + AVR32_MNEMONIC_LD_UH,
29477 + AVR32_MNEMONIC_LD_W,
29478 + AVR32_MNEMONIC_LDC_D,
29479 + AVR32_MNEMONIC_LDC_W,
29480 + AVR32_MNEMONIC_LDC0_D,
29481 + AVR32_MNEMONIC_LDC0_W,
29482 + AVR32_MNEMONIC_LDCM_D,
29483 + AVR32_MNEMONIC_LDCM_W,
29484 + AVR32_MNEMONIC_LDDPC,
29485 + AVR32_MNEMONIC_LDDSP,
29486 + AVR32_MNEMONIC_LDINS_B,
29487 + AVR32_MNEMONIC_LDINS_H,
29488 + AVR32_MNEMONIC_LDM,
29489 + AVR32_MNEMONIC_LDMTS,
29490 + AVR32_MNEMONIC_LDSWP_SH,
29491 + AVR32_MNEMONIC_LDSWP_UH,
29492 + AVR32_MNEMONIC_LDSWP_W,
29493 + AVR32_MNEMONIC_LSL,
29494 + AVR32_MNEMONIC_LSR,
29495 + AVR32_MNEMONIC_MAC,
29496 + AVR32_MNEMONIC_MACHH_D,
29497 + AVR32_MNEMONIC_MACHH_W,
29498 + AVR32_MNEMONIC_MACS_D,
29499 + AVR32_MNEMONIC_MACSATHH_W,
29500 + AVR32_MNEMONIC_MACU_D,
29501 + AVR32_MNEMONIC_MACWH_D,
29502 + AVR32_MNEMONIC_MAX,
29503 + AVR32_MNEMONIC_MCALL,
29504 + AVR32_MNEMONIC_MFDR,
29505 + AVR32_MNEMONIC_MFSR,
29506 + AVR32_MNEMONIC_MIN,
29507 + AVR32_MNEMONIC_MOV,
29508 + AVR32_MNEMONIC_MOVEQ,
29509 + AVR32_MNEMONIC_MOVNE,
29510 + AVR32_MNEMONIC_MOVCC,
29511 + AVR32_MNEMONIC_MOVCS,
29512 + AVR32_MNEMONIC_MOVGE,
29513 + AVR32_MNEMONIC_MOVLT,
29514 + AVR32_MNEMONIC_MOVMI,
29515 + AVR32_MNEMONIC_MOVPL,
29516 + AVR32_MNEMONIC_MOVLS,
29517 + AVR32_MNEMONIC_MOVGT,
29518 + AVR32_MNEMONIC_MOVLE,
29519 + AVR32_MNEMONIC_MOVHI,
29520 + AVR32_MNEMONIC_MOVVS,
29521 + AVR32_MNEMONIC_MOVVC,
29522 + AVR32_MNEMONIC_MOVQS,
29523 + AVR32_MNEMONIC_MOVAL,
29524 + AVR32_MNEMONIC_MOVHS,
29525 + AVR32_MNEMONIC_MOVLO,
29526 + AVR32_MNEMONIC_MTDR,
29527 + AVR32_MNEMONIC_MTSR,
29528 + AVR32_MNEMONIC_MUL,
29529 + AVR32_MNEMONIC_MULHH_W,
29530 + AVR32_MNEMONIC_MULNHH_W,
29531 + AVR32_MNEMONIC_MULNWH_D,
29532 + AVR32_MNEMONIC_MULS_D,
29533 + AVR32_MNEMONIC_MULSATHH_H,
29534 + AVR32_MNEMONIC_MULSATHH_W,
29535 + AVR32_MNEMONIC_MULSATRNDHH_H,
29536 + AVR32_MNEMONIC_MULSATRNDWH_W,
29537 + AVR32_MNEMONIC_MULSATWH_W,
29538 + AVR32_MNEMONIC_MULU_D,
29539 + AVR32_MNEMONIC_MULWH_D,
29540 + AVR32_MNEMONIC_MUSFR,
29541 + AVR32_MNEMONIC_MUSTR,
29542 + AVR32_MNEMONIC_MVCR_D,
29543 + AVR32_MNEMONIC_MVCR_W,
29544 + AVR32_MNEMONIC_MVRC_D,
29545 + AVR32_MNEMONIC_MVRC_W,
29546 + AVR32_MNEMONIC_NEG,
29547 + AVR32_MNEMONIC_NOP,
29548 + AVR32_MNEMONIC_OR,
29549 + AVR32_MNEMONIC_ORH,
29550 + AVR32_MNEMONIC_ORL,
29551 + AVR32_MNEMONIC_PABS_SB,
29552 + AVR32_MNEMONIC_PABS_SH,
29553 + AVR32_MNEMONIC_PACKSH_SB,
29554 + AVR32_MNEMONIC_PACKSH_UB,
29555 + AVR32_MNEMONIC_PACKW_SH,
29556 + AVR32_MNEMONIC_PADD_B,
29557 + AVR32_MNEMONIC_PADD_H,
29558 + AVR32_MNEMONIC_PADDH_SH,
29559 + AVR32_MNEMONIC_PADDH_UB,
29560 + AVR32_MNEMONIC_PADDS_SB,
29561 + AVR32_MNEMONIC_PADDS_SH,
29562 + AVR32_MNEMONIC_PADDS_UB,
29563 + AVR32_MNEMONIC_PADDS_UH,
29564 + AVR32_MNEMONIC_PADDSUB_H,
29565 + AVR32_MNEMONIC_PADDSUBH_SH,
29566 + AVR32_MNEMONIC_PADDSUBS_SH,
29567 + AVR32_MNEMONIC_PADDSUBS_UH,
29568 + AVR32_MNEMONIC_PADDX_H,
29569 + AVR32_MNEMONIC_PADDXH_SH,
29570 + AVR32_MNEMONIC_PADDXS_SH,
29571 + AVR32_MNEMONIC_PADDXS_UH,
29572 + AVR32_MNEMONIC_PASR_B,
29573 + AVR32_MNEMONIC_PASR_H,
29574 + AVR32_MNEMONIC_PAVG_SH,
29575 + AVR32_MNEMONIC_PAVG_UB,
29576 + AVR32_MNEMONIC_PLSL_B,
29577 + AVR32_MNEMONIC_PLSL_H,
29578 + AVR32_MNEMONIC_PLSR_B,
29579 + AVR32_MNEMONIC_PLSR_H,
29580 + AVR32_MNEMONIC_PMAX_SH,
29581 + AVR32_MNEMONIC_PMAX_UB,
29582 + AVR32_MNEMONIC_PMIN_SH,
29583 + AVR32_MNEMONIC_PMIN_UB,
29584 + AVR32_MNEMONIC_POPJC,
29585 + AVR32_MNEMONIC_POPM,
29586 + AVR32_MNEMONIC_PREF,
29587 + AVR32_MNEMONIC_PSAD,
29588 + AVR32_MNEMONIC_PSUB_B,
29589 + AVR32_MNEMONIC_PSUB_H,
29590 + AVR32_MNEMONIC_PSUBADD_H,
29591 + AVR32_MNEMONIC_PSUBADDH_SH,
29592 + AVR32_MNEMONIC_PSUBADDS_SH,
29593 + AVR32_MNEMONIC_PSUBADDS_UH,
29594 + AVR32_MNEMONIC_PSUBH_SH,
29595 + AVR32_MNEMONIC_PSUBH_UB,
29596 + AVR32_MNEMONIC_PSUBS_SB,
29597 + AVR32_MNEMONIC_PSUBS_SH,
29598 + AVR32_MNEMONIC_PSUBS_UB,
29599 + AVR32_MNEMONIC_PSUBS_UH,
29600 + AVR32_MNEMONIC_PSUBX_H,
29601 + AVR32_MNEMONIC_PSUBXH_SH,
29602 + AVR32_MNEMONIC_PSUBXS_SH,
29603 + AVR32_MNEMONIC_PSUBXS_UH,
29604 + AVR32_MNEMONIC_PUNPCKSB_H,
29605 + AVR32_MNEMONIC_PUNPCKUB_H,
29606 + AVR32_MNEMONIC_PUSHJC,
29607 + AVR32_MNEMONIC_PUSHM,
29608 + AVR32_MNEMONIC_RCALL,
29609 + AVR32_MNEMONIC_RETEQ,
29610 + AVR32_MNEMONIC_RETNE,
29611 + AVR32_MNEMONIC_RETCC,
29612 + AVR32_MNEMONIC_RETCS,
29613 + AVR32_MNEMONIC_RETGE,
29614 + AVR32_MNEMONIC_RETLT,
29615 + AVR32_MNEMONIC_RETMI,
29616 + AVR32_MNEMONIC_RETPL,
29617 + AVR32_MNEMONIC_RETLS,
29618 + AVR32_MNEMONIC_RETGT,
29619 + AVR32_MNEMONIC_RETLE,
29620 + AVR32_MNEMONIC_RETHI,
29621 + AVR32_MNEMONIC_RETVS,
29622 + AVR32_MNEMONIC_RETVC,
29623 + AVR32_MNEMONIC_RETQS,
29624 + AVR32_MNEMONIC_RETAL,
29625 + AVR32_MNEMONIC_RETHS,
29626 + AVR32_MNEMONIC_RETLO,
29627 + AVR32_MNEMONIC_RET,
29628 + AVR32_MNEMONIC_RETD,
29629 + AVR32_MNEMONIC_RETE,
29630 + AVR32_MNEMONIC_RETJ,
29631 + AVR32_MNEMONIC_RETS,
29632 + AVR32_MNEMONIC_RJMP,
29633 + AVR32_MNEMONIC_ROL,
29634 + AVR32_MNEMONIC_ROR,
29635 + AVR32_MNEMONIC_RSUB,
29636 + AVR32_MNEMONIC_SATADD_H,
29637 + AVR32_MNEMONIC_SATADD_W,
29638 + AVR32_MNEMONIC_SATRNDS,
29639 + AVR32_MNEMONIC_SATRNDU,
29640 + AVR32_MNEMONIC_SATS,
29641 + AVR32_MNEMONIC_SATSUB_H,
29642 + AVR32_MNEMONIC_SATSUB_W,
29643 + AVR32_MNEMONIC_SATU,
29644 + AVR32_MNEMONIC_SBC,
29645 + AVR32_MNEMONIC_SBR,
29646 + AVR32_MNEMONIC_SCALL,
29647 + AVR32_MNEMONIC_SCR,
29648 + AVR32_MNEMONIC_SLEEP,
29649 + AVR32_MNEMONIC_SREQ,
29650 + AVR32_MNEMONIC_SRNE,
29651 + AVR32_MNEMONIC_SRCC,
29652 + AVR32_MNEMONIC_SRCS,
29653 + AVR32_MNEMONIC_SRGE,
29654 + AVR32_MNEMONIC_SRLT,
29655 + AVR32_MNEMONIC_SRMI,
29656 + AVR32_MNEMONIC_SRPL,
29657 + AVR32_MNEMONIC_SRLS,
29658 + AVR32_MNEMONIC_SRGT,
29659 + AVR32_MNEMONIC_SRLE,
29660 + AVR32_MNEMONIC_SRHI,
29661 + AVR32_MNEMONIC_SRVS,
29662 + AVR32_MNEMONIC_SRVC,
29663 + AVR32_MNEMONIC_SRQS,
29664 + AVR32_MNEMONIC_SRAL,
29665 + AVR32_MNEMONIC_SRHS,
29666 + AVR32_MNEMONIC_SRLO,
29667 + AVR32_MNEMONIC_SSRF,
29668 + AVR32_MNEMONIC_ST_B,
29669 + AVR32_MNEMONIC_ST_D,
29670 + AVR32_MNEMONIC_ST_H,
29671 + AVR32_MNEMONIC_ST_W,
29672 + AVR32_MNEMONIC_STC_D,
29673 + AVR32_MNEMONIC_STC_W,
29674 + AVR32_MNEMONIC_STC0_D,
29675 + AVR32_MNEMONIC_STC0_W,
29676 + AVR32_MNEMONIC_STCM_D,
29677 + AVR32_MNEMONIC_STCM_W,
29678 + AVR32_MNEMONIC_STCOND,
29679 + AVR32_MNEMONIC_STDSP,
29680 + AVR32_MNEMONIC_STHH_W,
29681 + AVR32_MNEMONIC_STM,
29682 + AVR32_MNEMONIC_STMTS,
29683 + AVR32_MNEMONIC_STSWP_H,
29684 + AVR32_MNEMONIC_STSWP_W,
29685 + AVR32_MNEMONIC_SUB,
29686 + AVR32_MNEMONIC_SUBEQ,
29687 + AVR32_MNEMONIC_SUBNE,
29688 + AVR32_MNEMONIC_SUBCC,
29689 + AVR32_MNEMONIC_SUBCS,
29690 + AVR32_MNEMONIC_SUBGE,
29691 + AVR32_MNEMONIC_SUBLT,
29692 + AVR32_MNEMONIC_SUBMI,
29693 + AVR32_MNEMONIC_SUBPL,
29694 + AVR32_MNEMONIC_SUBLS,
29695 + AVR32_MNEMONIC_SUBGT,
29696 + AVR32_MNEMONIC_SUBLE,
29697 + AVR32_MNEMONIC_SUBHI,
29698 + AVR32_MNEMONIC_SUBVS,
29699 + AVR32_MNEMONIC_SUBVC,
29700 + AVR32_MNEMONIC_SUBQS,
29701 + AVR32_MNEMONIC_SUBAL,
29702 + AVR32_MNEMONIC_SUBHS,
29703 + AVR32_MNEMONIC_SUBLO,
29704 + AVR32_MNEMONIC_SUBFEQ,
29705 + AVR32_MNEMONIC_SUBFNE,
29706 + AVR32_MNEMONIC_SUBFCC,
29707 + AVR32_MNEMONIC_SUBFCS,
29708 + AVR32_MNEMONIC_SUBFGE,
29709 + AVR32_MNEMONIC_SUBFLT,
29710 + AVR32_MNEMONIC_SUBFMI,
29711 + AVR32_MNEMONIC_SUBFPL,
29712 + AVR32_MNEMONIC_SUBFLS,
29713 + AVR32_MNEMONIC_SUBFGT,
29714 + AVR32_MNEMONIC_SUBFLE,
29715 + AVR32_MNEMONIC_SUBFHI,
29716 + AVR32_MNEMONIC_SUBFVS,
29717 + AVR32_MNEMONIC_SUBFVC,
29718 + AVR32_MNEMONIC_SUBFQS,
29719 + AVR32_MNEMONIC_SUBFAL,
29720 + AVR32_MNEMONIC_SUBFHS,
29721 + AVR32_MNEMONIC_SUBFLO,
29722 + AVR32_MNEMONIC_SUBHH_W,
29723 + AVR32_MNEMONIC_SWAP_B,
29724 + AVR32_MNEMONIC_SWAP_BH,
29725 + AVR32_MNEMONIC_SWAP_H,
29726 + AVR32_MNEMONIC_SYNC,
29727 + AVR32_MNEMONIC_TLBR,
29728 + AVR32_MNEMONIC_TLBS,
29729 + AVR32_MNEMONIC_TLBW,
29730 + AVR32_MNEMONIC_TNBZ,
29731 + AVR32_MNEMONIC_TST,
29732 + AVR32_MNEMONIC_XCHG,
29733 + AVR32_MNEMONIC_MEMC,
29734 + AVR32_MNEMONIC_MEMS,
29735 + AVR32_MNEMONIC_MEMT,
29736 + AVR32_MNEMONIC_FADD_S,
29737 + AVR32_MNEMONIC_FADD_D,
29738 + AVR32_MNEMONIC_FSUB_S,
29739 + AVR32_MNEMONIC_FSUB_D,
29740 + AVR32_MNEMONIC_FMAC_S,
29741 + AVR32_MNEMONIC_FMAC_D,
29742 + AVR32_MNEMONIC_FNMAC_S,
29743 + AVR32_MNEMONIC_FNMAC_D,
29744 + AVR32_MNEMONIC_FMSC_S,
29745 + AVR32_MNEMONIC_FMSC_D,
29746 + AVR32_MNEMONIC_FNMSC_S,
29747 + AVR32_MNEMONIC_FNMSC_D,
29748 + AVR32_MNEMONIC_FMUL_S,
29749 + AVR32_MNEMONIC_FMUL_D,
29750 + AVR32_MNEMONIC_FNMUL_S,
29751 + AVR32_MNEMONIC_FNMUL_D,
29752 + AVR32_MNEMONIC_FNEG_S,
29753 + AVR32_MNEMONIC_FNEG_D,
29754 + AVR32_MNEMONIC_FABS_S,
29755 + AVR32_MNEMONIC_FABS_D,
29756 + AVR32_MNEMONIC_FCMP_S,
29757 + AVR32_MNEMONIC_FCMP_D,
29758 + AVR32_MNEMONIC_FMOV_S,
29759 + AVR32_MNEMONIC_FMOV_D,
29760 + AVR32_MNEMONIC_FCASTS_D,
29761 + AVR32_MNEMONIC_FCASTD_S,
29762 + /* AVR32_MNEMONIC_FLD_S,
29763 + AVR32_MNEMONIC_FLD_D,
29764 + AVR32_MNEMONIC_FST_S,
29765 + AVR32_MNEMONIC_FST_D, */
29766 + AVR32_MNEMONIC_LDA_W,
29767 + AVR32_MNEMONIC_CALL,
29768 + AVR32_MNEMONIC_PICOSVMAC,
29769 + AVR32_MNEMONIC_PICOSVMUL,
29770 + AVR32_MNEMONIC_PICOVMAC,
29771 + AVR32_MNEMONIC_PICOVMUL,
29772 + AVR32_MNEMONIC_PICOLD_D,
29773 + AVR32_MNEMONIC_PICOLD_W,
29774 + AVR32_MNEMONIC_PICOLDM_D,
29775 + AVR32_MNEMONIC_PICOLDM_W,
29776 + AVR32_MNEMONIC_PICOMV_D,
29777 + AVR32_MNEMONIC_PICOMV_W,
29778 + AVR32_MNEMONIC_PICOST_D,
29779 + AVR32_MNEMONIC_PICOST_W,
29780 + AVR32_MNEMONIC_PICOSTM_D,
29781 + AVR32_MNEMONIC_PICOSTM_W,
29782 + AVR32_MNEMONIC_RSUBEQ,
29783 + AVR32_MNEMONIC_RSUBNE,
29784 + AVR32_MNEMONIC_RSUBCC,
29785 + AVR32_MNEMONIC_RSUBCS,
29786 + AVR32_MNEMONIC_RSUBGE,
29787 + AVR32_MNEMONIC_RSUBLT,
29788 + AVR32_MNEMONIC_RSUBMI,
29789 + AVR32_MNEMONIC_RSUBPL,
29790 + AVR32_MNEMONIC_RSUBLS,
29791 + AVR32_MNEMONIC_RSUBGT,
29792 + AVR32_MNEMONIC_RSUBLE,
29793 + AVR32_MNEMONIC_RSUBHI,
29794 + AVR32_MNEMONIC_RSUBVS,
29795 + AVR32_MNEMONIC_RSUBVC,
29796 + AVR32_MNEMONIC_RSUBQS,
29797 + AVR32_MNEMONIC_RSUBAL,
29798 + AVR32_MNEMONIC_RSUBHS,
29799 + AVR32_MNEMONIC_RSUBLO,
29800 + AVR32_MNEMONIC_ADDEQ,
29801 + AVR32_MNEMONIC_ADDNE,
29802 + AVR32_MNEMONIC_ADDCC,
29803 + AVR32_MNEMONIC_ADDCS,
29804 + AVR32_MNEMONIC_ADDGE,
29805 + AVR32_MNEMONIC_ADDLT,
29806 + AVR32_MNEMONIC_ADDMI,
29807 + AVR32_MNEMONIC_ADDPL,
29808 + AVR32_MNEMONIC_ADDLS,
29809 + AVR32_MNEMONIC_ADDGT,
29810 + AVR32_MNEMONIC_ADDLE,
29811 + AVR32_MNEMONIC_ADDHI,
29812 + AVR32_MNEMONIC_ADDVS,
29813 + AVR32_MNEMONIC_ADDVC,
29814 + AVR32_MNEMONIC_ADDQS,
29815 + AVR32_MNEMONIC_ADDAL,
29816 + AVR32_MNEMONIC_ADDHS,
29817 + AVR32_MNEMONIC_ADDLO,
29818 + AVR32_MNEMONIC_ANDEQ,
29819 + AVR32_MNEMONIC_ANDNE,
29820 + AVR32_MNEMONIC_ANDCC,
29821 + AVR32_MNEMONIC_ANDCS,
29822 + AVR32_MNEMONIC_ANDGE,
29823 + AVR32_MNEMONIC_ANDLT,
29824 + AVR32_MNEMONIC_ANDMI,
29825 + AVR32_MNEMONIC_ANDPL,
29826 + AVR32_MNEMONIC_ANDLS,
29827 + AVR32_MNEMONIC_ANDGT,
29828 + AVR32_MNEMONIC_ANDLE,
29829 + AVR32_MNEMONIC_ANDHI,
29830 + AVR32_MNEMONIC_ANDVS,
29831 + AVR32_MNEMONIC_ANDVC,
29832 + AVR32_MNEMONIC_ANDQS,
29833 + AVR32_MNEMONIC_ANDAL,
29834 + AVR32_MNEMONIC_ANDHS,
29835 + AVR32_MNEMONIC_ANDLO,
29836 + AVR32_MNEMONIC_OREQ,
29837 + AVR32_MNEMONIC_ORNE,
29838 + AVR32_MNEMONIC_ORCC,
29839 + AVR32_MNEMONIC_ORCS,
29840 + AVR32_MNEMONIC_ORGE,
29841 + AVR32_MNEMONIC_ORLT,
29842 + AVR32_MNEMONIC_ORMI,
29843 + AVR32_MNEMONIC_ORPL,
29844 + AVR32_MNEMONIC_ORLS,
29845 + AVR32_MNEMONIC_ORGT,
29846 + AVR32_MNEMONIC_ORLE,
29847 + AVR32_MNEMONIC_ORHI,
29848 + AVR32_MNEMONIC_ORVS,
29849 + AVR32_MNEMONIC_ORVC,
29850 + AVR32_MNEMONIC_ORQS,
29851 + AVR32_MNEMONIC_ORAL,
29852 + AVR32_MNEMONIC_ORHS,
29853 + AVR32_MNEMONIC_ORLO,
29854 + AVR32_MNEMONIC_EOREQ,
29855 + AVR32_MNEMONIC_EORNE,
29856 + AVR32_MNEMONIC_EORCC,
29857 + AVR32_MNEMONIC_EORCS,
29858 + AVR32_MNEMONIC_EORGE,
29859 + AVR32_MNEMONIC_EORLT,
29860 + AVR32_MNEMONIC_EORMI,
29861 + AVR32_MNEMONIC_EORPL,
29862 + AVR32_MNEMONIC_EORLS,
29863 + AVR32_MNEMONIC_EORGT,
29864 + AVR32_MNEMONIC_EORLE,
29865 + AVR32_MNEMONIC_EORHI,
29866 + AVR32_MNEMONIC_EORVS,
29867 + AVR32_MNEMONIC_EORVC,
29868 + AVR32_MNEMONIC_EORQS,
29869 + AVR32_MNEMONIC_EORAL,
29870 + AVR32_MNEMONIC_EORHS,
29871 + AVR32_MNEMONIC_EORLO,
29872 + AVR32_MNEMONIC_LD_WEQ,
29873 + AVR32_MNEMONIC_LD_WNE,
29874 + AVR32_MNEMONIC_LD_WCC,
29875 + AVR32_MNEMONIC_LD_WCS,
29876 + AVR32_MNEMONIC_LD_WGE,
29877 + AVR32_MNEMONIC_LD_WLT,
29878 + AVR32_MNEMONIC_LD_WMI,
29879 + AVR32_MNEMONIC_LD_WPL,
29880 + AVR32_MNEMONIC_LD_WLS,
29881 + AVR32_MNEMONIC_LD_WGT,
29882 + AVR32_MNEMONIC_LD_WLE,
29883 + AVR32_MNEMONIC_LD_WHI,
29884 + AVR32_MNEMONIC_LD_WVS,
29885 + AVR32_MNEMONIC_LD_WVC,
29886 + AVR32_MNEMONIC_LD_WQS,
29887 + AVR32_MNEMONIC_LD_WAL,
29888 + AVR32_MNEMONIC_LD_WHS,
29889 + AVR32_MNEMONIC_LD_WLO,
29890 + AVR32_MNEMONIC_LD_SHEQ,
29891 + AVR32_MNEMONIC_LD_SHNE,
29892 + AVR32_MNEMONIC_LD_SHCC,
29893 + AVR32_MNEMONIC_LD_SHCS,
29894 + AVR32_MNEMONIC_LD_SHGE,
29895 + AVR32_MNEMONIC_LD_SHLT,
29896 + AVR32_MNEMONIC_LD_SHMI,
29897 + AVR32_MNEMONIC_LD_SHPL,
29898 + AVR32_MNEMONIC_LD_SHLS,
29899 + AVR32_MNEMONIC_LD_SHGT,
29900 + AVR32_MNEMONIC_LD_SHLE,
29901 + AVR32_MNEMONIC_LD_SHHI,
29902 + AVR32_MNEMONIC_LD_SHVS,
29903 + AVR32_MNEMONIC_LD_SHVC,
29904 + AVR32_MNEMONIC_LD_SHQS,
29905 + AVR32_MNEMONIC_LD_SHAL,
29906 + AVR32_MNEMONIC_LD_SHHS,
29907 + AVR32_MNEMONIC_LD_SHLO,
29908 + AVR32_MNEMONIC_LD_UHEQ,
29909 + AVR32_MNEMONIC_LD_UHNE,
29910 + AVR32_MNEMONIC_LD_UHCC,
29911 + AVR32_MNEMONIC_LD_UHCS,
29912 + AVR32_MNEMONIC_LD_UHGE,
29913 + AVR32_MNEMONIC_LD_UHLT,
29914 + AVR32_MNEMONIC_LD_UHMI,
29915 + AVR32_MNEMONIC_LD_UHPL,
29916 + AVR32_MNEMONIC_LD_UHLS,
29917 + AVR32_MNEMONIC_LD_UHGT,
29918 + AVR32_MNEMONIC_LD_UHLE,
29919 + AVR32_MNEMONIC_LD_UHHI,
29920 + AVR32_MNEMONIC_LD_UHVS,
29921 + AVR32_MNEMONIC_LD_UHVC,
29922 + AVR32_MNEMONIC_LD_UHQS,
29923 + AVR32_MNEMONIC_LD_UHAL,
29924 + AVR32_MNEMONIC_LD_UHHS,
29925 + AVR32_MNEMONIC_LD_UHLO,
29926 + AVR32_MNEMONIC_LD_SBEQ,
29927 + AVR32_MNEMONIC_LD_SBNE,
29928 + AVR32_MNEMONIC_LD_SBCC,
29929 + AVR32_MNEMONIC_LD_SBCS,
29930 + AVR32_MNEMONIC_LD_SBGE,
29931 + AVR32_MNEMONIC_LD_SBLT,
29932 + AVR32_MNEMONIC_LD_SBMI,
29933 + AVR32_MNEMONIC_LD_SBPL,
29934 + AVR32_MNEMONIC_LD_SBLS,
29935 + AVR32_MNEMONIC_LD_SBGT,
29936 + AVR32_MNEMONIC_LD_SBLE,
29937 + AVR32_MNEMONIC_LD_SBHI,
29938 + AVR32_MNEMONIC_LD_SBVS,
29939 + AVR32_MNEMONIC_LD_SBVC,
29940 + AVR32_MNEMONIC_LD_SBQS,
29941 + AVR32_MNEMONIC_LD_SBAL,
29942 + AVR32_MNEMONIC_LD_SBHS,
29943 + AVR32_MNEMONIC_LD_SBLO,
29944 + AVR32_MNEMONIC_LD_UBEQ,
29945 + AVR32_MNEMONIC_LD_UBNE,
29946 + AVR32_MNEMONIC_LD_UBCC,
29947 + AVR32_MNEMONIC_LD_UBCS,
29948 + AVR32_MNEMONIC_LD_UBGE,
29949 + AVR32_MNEMONIC_LD_UBLT,
29950 + AVR32_MNEMONIC_LD_UBMI,
29951 + AVR32_MNEMONIC_LD_UBPL,
29952 + AVR32_MNEMONIC_LD_UBLS,
29953 + AVR32_MNEMONIC_LD_UBGT,
29954 + AVR32_MNEMONIC_LD_UBLE,
29955 + AVR32_MNEMONIC_LD_UBHI,
29956 + AVR32_MNEMONIC_LD_UBVS,
29957 + AVR32_MNEMONIC_LD_UBVC,
29958 + AVR32_MNEMONIC_LD_UBQS,
29959 + AVR32_MNEMONIC_LD_UBAL,
29960 + AVR32_MNEMONIC_LD_UBHS,
29961 + AVR32_MNEMONIC_LD_UBLO,
29962 + AVR32_MNEMONIC_ST_WEQ,
29963 + AVR32_MNEMONIC_ST_WNE,
29964 + AVR32_MNEMONIC_ST_WCC,
29965 + AVR32_MNEMONIC_ST_WCS,
29966 + AVR32_MNEMONIC_ST_WGE,
29967 + AVR32_MNEMONIC_ST_WLT,
29968 + AVR32_MNEMONIC_ST_WMI,
29969 + AVR32_MNEMONIC_ST_WPL,
29970 + AVR32_MNEMONIC_ST_WLS,
29971 + AVR32_MNEMONIC_ST_WGT,
29972 + AVR32_MNEMONIC_ST_WLE,
29973 + AVR32_MNEMONIC_ST_WHI,
29974 + AVR32_MNEMONIC_ST_WVS,
29975 + AVR32_MNEMONIC_ST_WVC,
29976 + AVR32_MNEMONIC_ST_WQS,
29977 + AVR32_MNEMONIC_ST_WAL,
29978 + AVR32_MNEMONIC_ST_WHS,
29979 + AVR32_MNEMONIC_ST_WLO,
29980 + AVR32_MNEMONIC_ST_HEQ,
29981 + AVR32_MNEMONIC_ST_HNE,
29982 + AVR32_MNEMONIC_ST_HCC,
29983 + AVR32_MNEMONIC_ST_HCS,
29984 + AVR32_MNEMONIC_ST_HGE,
29985 + AVR32_MNEMONIC_ST_HLT,
29986 + AVR32_MNEMONIC_ST_HMI,
29987 + AVR32_MNEMONIC_ST_HPL,
29988 + AVR32_MNEMONIC_ST_HLS,
29989 + AVR32_MNEMONIC_ST_HGT,
29990 + AVR32_MNEMONIC_ST_HLE,
29991 + AVR32_MNEMONIC_ST_HHI,
29992 + AVR32_MNEMONIC_ST_HVS,
29993 + AVR32_MNEMONIC_ST_HVC,
29994 + AVR32_MNEMONIC_ST_HQS,
29995 + AVR32_MNEMONIC_ST_HAL,
29996 + AVR32_MNEMONIC_ST_HHS,
29997 + AVR32_MNEMONIC_ST_HLO,
29998 + AVR32_MNEMONIC_ST_BEQ,
29999 + AVR32_MNEMONIC_ST_BNE,
30000 + AVR32_MNEMONIC_ST_BCC,
30001 + AVR32_MNEMONIC_ST_BCS,
30002 + AVR32_MNEMONIC_ST_BGE,
30003 + AVR32_MNEMONIC_ST_BLT,
30004 + AVR32_MNEMONIC_ST_BMI,
30005 + AVR32_MNEMONIC_ST_BPL,
30006 + AVR32_MNEMONIC_ST_BLS,
30007 + AVR32_MNEMONIC_ST_BGT,
30008 + AVR32_MNEMONIC_ST_BLE,
30009 + AVR32_MNEMONIC_ST_BHI,
30010 + AVR32_MNEMONIC_ST_BVS,
30011 + AVR32_MNEMONIC_ST_BVC,
30012 + AVR32_MNEMONIC_ST_BQS,
30013 + AVR32_MNEMONIC_ST_BAL,
30014 + AVR32_MNEMONIC_ST_BHS,
30015 + AVR32_MNEMONIC_ST_BLO,
30016 + AVR32_MNEMONIC_MOVH,
30017 + AVR32_MNEMONIC__END_
30018 +};
30019 +#define AVR32_NR_MNEMONICS AVR32_MNEMONIC__END_
30020 +
30021 +enum avr32_syntax_parser
30022 + {
30023 + AVR32_PARSER_NORMAL,
30024 + AVR32_PARSER_ALIAS,
30025 + AVR32_PARSER_LDA,
30026 + AVR32_PARSER_CALL,
30027 + AVR32_PARSER__END_
30028 + };
30029 +#define AVR32_NR_PARSERS AVR32_PARSER__END_
30030 --- a/opcodes/configure.in
30031 +++ b/opcodes/configure.in
30032 @@ -158,6 +158,7 @@ if test x${all_targets} = xfalse ; then
30033 bfd_arc_arch) ta="$ta arc-dis.lo arc-opc.lo arc-ext.lo" ;;
30034 bfd_arm_arch) ta="$ta arm-dis.lo" ;;
30035 bfd_avr_arch) ta="$ta avr-dis.lo" ;;
30036 + bfd_avr32_arch) ta="$ta avr32-asm.lo avr32-dis.lo avr32-opc.lo" ;;
30037 bfd_bfin_arch) ta="$ta bfin-dis.lo" ;;
30038 bfd_cr16_arch) ta="$ta cr16-dis.lo cr16-opc.lo" ;;
30039 bfd_cris_arch) ta="$ta cris-dis.lo cris-opc.lo cgen-bitset.lo" ;;
30040 @@ -216,7 +217,7 @@ if test x${all_targets} = xfalse ; then
30041 ta="$ta sh64-dis.lo sh64-opc.lo"
30042 archdefs="$archdefs -DINCLUDE_SHMEDIA"
30043 break;;
30044 - esac;
30045 + esac
30046 done
30047 ta="$ta sh-dis.lo cgen-bitset.lo" ;;
30048 bfd_sparc_arch) ta="$ta sparc-dis.lo sparc-opc.lo" ;;
30049 --- a/opcodes/disassemble.c
30050 +++ b/opcodes/disassemble.c
30051 @@ -27,6 +27,7 @@
30052 #define ARCH_arc
30053 #define ARCH_arm
30054 #define ARCH_avr
30055 +#define ARCH_avr32
30056 #define ARCH_bfin
30057 #define ARCH_cr16
30058 #define ARCH_cris
30059 @@ -128,6 +129,11 @@ disassembler (abfd)
30060 disassemble = print_insn_avr;
30061 break;
30062 #endif
30063 +#ifdef ARCH_avr32
30064 + case bfd_arch_avr32:
30065 + disassemble = print_insn_avr32;
30066 + break;
30067 +#endif
30068 #ifdef ARCH_bfin
30069 case bfd_arch_bfin:
30070 disassemble = print_insn_bfin;
30071 @@ -346,9 +352,9 @@ disassembler (abfd)
30072 #ifdef ARCH_score
30073 case bfd_arch_score:
30074 if (bfd_big_endian (abfd))
30075 - disassemble = print_insn_big_score;
30076 + disassemble = print_insn_big_score;
30077 else
30078 - disassemble = print_insn_little_score;
30079 + disassemble = print_insn_little_score;
30080 break;
30081 #endif
30082 #ifdef ARCH_sh
30083 @@ -466,6 +472,9 @@ disassembler_usage (stream)
30084 #ifdef ARCH_i386
30085 print_i386_disassembler_options (stream);
30086 #endif
30087 +#ifdef ARCH_avr32
30088 + print_avr32_disassembler_options (stream);
30089 +#endif
30090
30091 return;
30092 }
30093 --- a/opcodes/Makefile.am
30094 +++ b/opcodes/Makefile.am
30095 @@ -30,6 +30,7 @@ LIBIBERTY = ../libiberty/libiberty.a
30096 # Header files.
30097 HFILES = \
30098 cgen-ops.h cgen-types.h \
30099 + avr32-asm.h avr32-opc.h \
30100 fr30-desc.h fr30-opc.h \
30101 frv-desc.h frv-opc.h \
30102 h8500-opc.h \
30103 @@ -63,6 +64,9 @@ CFILES = \
30104 arc-ext.c \
30105 arm-dis.c \
30106 avr-dis.c \
30107 + avr32-asm.c \
30108 + avr32-dis.c \
30109 + avr32-opc.c \
30110 bfin-dis.c \
30111 cgen-asm.c \
30112 cgen-bitset.c \
30113 @@ -217,6 +221,9 @@ ALL_MACHINES = \
30114 arc-ext.lo \
30115 arm-dis.lo \
30116 avr-dis.lo \
30117 + avr32-asm.lo \
30118 + avr32-dis.lo \
30119 + avr32-opc.lo \
30120 bfin-dis.lo \
30121 cgen-asm.lo \
30122 cgen-bitset.lo \
30123 @@ -674,6 +681,15 @@ avr-dis.lo: avr-dis.c sysdep.h config.h
30124 $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
30125 opintl.h $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
30126 $(INCDIR)/opcode/avr.h
30127 +avr32-asm.lo: avr32-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
30128 + $(BFD_H) $(INCDIR)/symcat.h avr32-opc.h opintl.h \
30129 + $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
30130 + $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
30131 +avr32-dis.lo: avr32-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
30132 + $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
30133 + avr32-opc.h opintl.h
30134 +avr32-opc.lo: avr32-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
30135 + $(BFD_H) $(INCDIR)/symcat.h avr32-opc.h $(INCDIR)/libiberty.h
30136 bfin-dis.lo: bfin-dis.c $(INCDIR)/opcode/bfin.h $(INCDIR)/dis-asm.h \
30137 $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h
30138 cgen-asm.lo: cgen-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
30139 --- a/bfd/bfd-in2.h
30140 +++ b/bfd/bfd-in2.h
30141 @@ -2017,6 +2017,11 @@ enum bfd_architecture
30142 #define bfd_mach_avr4 4
30143 #define bfd_mach_avr5 5
30144 #define bfd_mach_avr6 6
30145 + bfd_arch_avr32, /* Atmel AVR32 */
30146 +#define bfd_mach_avr32_ap 7000
30147 +#define bfd_mach_avr32_uc 3000
30148 +#define bfd_mach_avr32_ucr1 3001
30149 +#define bfd_mach_avr32_ucr2 3002
30150 bfd_arch_bfin, /* ADI Blackfin */
30151 #define bfd_mach_bfin 1
30152 bfd_arch_cr16, /* National Semiconductor CompactRISC (ie CR16). */
30153 @@ -3758,6 +3763,88 @@ instructions */
30154 instructions */
30155 BFD_RELOC_AVR_6_ADIW,
30156
30157 +/* Difference between two labels: L2 - L1. The value of L1 is encoded
30158 +as sym + addend, while the initial difference after assembly is
30159 +inserted into the object file by the assembler. */
30160 + BFD_RELOC_AVR32_DIFF32,
30161 + BFD_RELOC_AVR32_DIFF16,
30162 + BFD_RELOC_AVR32_DIFF8,
30163 +
30164 +/* Reference to a symbol through the Global Offset Table. The linker
30165 +will allocate an entry for symbol in the GOT and insert the offset
30166 +of this entry as the relocation value. */
30167 + BFD_RELOC_AVR32_GOT32,
30168 + BFD_RELOC_AVR32_GOT16,
30169 + BFD_RELOC_AVR32_GOT8,
30170 +
30171 +/* Normal (non-pc-relative) code relocations. Alignment and signedness
30172 +is indicated by the suffixes. S means signed, U means unsigned. W
30173 +means word-aligned, H means halfword-aligned, neither means
30174 +byte-aligned (no alignment.) SUB5 is the same relocation as 16S. */
30175 + BFD_RELOC_AVR32_21S,
30176 + BFD_RELOC_AVR32_16U,
30177 + BFD_RELOC_AVR32_16S,
30178 + BFD_RELOC_AVR32_SUB5,
30179 + BFD_RELOC_AVR32_8S_EXT,
30180 + BFD_RELOC_AVR32_8S,
30181 + BFD_RELOC_AVR32_15S,
30182 +
30183 +/* PC-relative relocations are signed if neither 'U' nor 'S' is
30184 +specified. However, we explicitly tack on a 'B' to indicate no
30185 +alignment, to avoid confusion with data relocs. All of these resolve
30186 +to sym + addend - offset, except the one with 'N' (negated) suffix.
30187 +This particular one resolves to offset - sym - addend. */
30188 + BFD_RELOC_AVR32_22H_PCREL,
30189 + BFD_RELOC_AVR32_18W_PCREL,
30190 + BFD_RELOC_AVR32_16B_PCREL,
30191 + BFD_RELOC_AVR32_16N_PCREL,
30192 + BFD_RELOC_AVR32_14UW_PCREL,
30193 + BFD_RELOC_AVR32_11H_PCREL,
30194 + BFD_RELOC_AVR32_10UW_PCREL,
30195 + BFD_RELOC_AVR32_9H_PCREL,
30196 + BFD_RELOC_AVR32_9UW_PCREL,
30197 +
30198 +/* Subtract the link-time address of the GOT from (symbol + addend)
30199 +and insert the result. */
30200 + BFD_RELOC_AVR32_GOTPC,
30201 +
30202 +/* Reference to a symbol through the GOT. The linker will allocate an
30203 +entry for symbol in the GOT and insert the offset of this entry as
30204 +the relocation value. addend must be zero. As usual, 'S' means
30205 +signed, 'W' means word-aligned, etc. */
30206 + BFD_RELOC_AVR32_GOTCALL,
30207 + BFD_RELOC_AVR32_LDA_GOT,
30208 + BFD_RELOC_AVR32_GOT21S,
30209 + BFD_RELOC_AVR32_GOT18SW,
30210 + BFD_RELOC_AVR32_GOT16S,
30211 +
30212 +/* 32-bit constant pool entry. I don't think 8- and 16-bit entries make
30213 +a whole lot of sense. */
30214 + BFD_RELOC_AVR32_32_CPENT,
30215 +
30216 +/* Constant pool references. Some of these relocations are signed,
30217 +others are unsigned. It doesn't really matter, since the constant
30218 +pool always comes after the code that references it. */
30219 + BFD_RELOC_AVR32_CPCALL,
30220 + BFD_RELOC_AVR32_16_CP,
30221 + BFD_RELOC_AVR32_9W_CP,
30222 +
30223 +/* sym must be the absolute symbol. The addend specifies the alignment
30224 +order, e.g. if addend is 2, the linker must add padding so that the
30225 +next address is aligned to a 4-byte boundary. */
30226 + BFD_RELOC_AVR32_ALIGN,
30227 +
30228 +/* Code relocations that will never make it to the output file. */
30229 + BFD_RELOC_AVR32_14UW,
30230 + BFD_RELOC_AVR32_10UW,
30231 + BFD_RELOC_AVR32_10SW,
30232 + BFD_RELOC_AVR32_STHH_W,
30233 + BFD_RELOC_AVR32_7UW,
30234 + BFD_RELOC_AVR32_6S,
30235 + BFD_RELOC_AVR32_6UW,
30236 + BFD_RELOC_AVR32_4UH,
30237 + BFD_RELOC_AVR32_3U,
30238 +
30239 /* Direct 12 bit. */
30240 BFD_RELOC_390_12,
30241
30242 --- /dev/null
30243 +++ b/bfd/bfd-in3.h
30244 @@ -0,0 +1,5406 @@
30245 +/* DO NOT EDIT! -*- buffer-read-only: t -*- This file is automatically
30246 + generated from "bfd-in.h", "init.c", "opncls.c", "libbfd.c",
30247 + "bfdio.c", "bfdwin.c", "section.c", "archures.c", "reloc.c",
30248 + "syms.c", "bfd.c", "archive.c", "corefile.c", "targets.c", "format.c",
30249 + "linker.c" and "simple.c".
30250 + Run "make headers" in your build bfd/ to regenerate. */
30251 +
30252 +/* Main header file for the bfd library -- portable access to object files.
30253 +
30254 + Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
30255 + 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
30256 + Free Software Foundation, Inc.
30257 +
30258 + Contributed by Cygnus Support.
30259 +
30260 + This file is part of BFD, the Binary File Descriptor library.
30261 +
30262 + This program is free software; you can redistribute it and/or modify
30263 + it under the terms of the GNU General Public License as published by
30264 + the Free Software Foundation; either version 3 of the License, or
30265 + (at your option) any later version.
30266 +
30267 + This program is distributed in the hope that it will be useful,
30268 + but WITHOUT ANY WARRANTY; without even the implied warranty of
30269 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30270 + GNU General Public License for more details.
30271 +
30272 + You should have received a copy of the GNU General Public License
30273 + along with this program; if not, write to the Free Software
30274 + Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */
30275 +
30276 +#ifndef __BFD_H_SEEN__
30277 +#define __BFD_H_SEEN__
30278 +
30279 +#ifdef __cplusplus
30280 +extern "C" {
30281 +#endif
30282 +
30283 +#include "ansidecl.h"
30284 +#include "symcat.h"
30285 +#if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
30286 +#ifndef SABER
30287 +/* This hack is to avoid a problem with some strict ANSI C preprocessors.
30288 + The problem is, "32_" is not a valid preprocessing token, and we don't
30289 + want extra underscores (e.g., "nlm_32_"). The XCONCAT2 macro will
30290 + cause the inner CONCAT2 macros to be evaluated first, producing
30291 + still-valid pp-tokens. Then the final concatenation can be done. */
30292 +#undef CONCAT4
30293 +#define CONCAT4(a,b,c,d) XCONCAT2(CONCAT2(a,b),CONCAT2(c,d))
30294 +#endif
30295 +#endif
30296 +
30297 +/* This is a utility macro to handle the situation where the code
30298 + wants to place a constant string into the code, followed by a
30299 + comma and then the length of the string. Doing this by hand
30300 + is error prone, so using this macro is safer. The macro will
30301 + also safely handle the case where a NULL is passed as the arg. */
30302 +#define STRING_COMMA_LEN(STR) (STR), ((STR) ? sizeof (STR) - 1 : 0)
30303 +/* Unfortunately it is not possible to use the STRING_COMMA_LEN macro
30304 + to create the arguments to another macro, since the preprocessor
30305 + will mis-count the number of arguments to the outer macro (by not
30306 + evaluating STRING_COMMA_LEN and so missing the comma). This is a
30307 + problem for example when trying to use STRING_COMMA_LEN to build
30308 + the arguments to the strncmp() macro. Hence this alternative
30309 + definition of strncmp is provided here.
30310 +
30311 + Note - these macros do NOT work if STR2 is not a constant string. */
30312 +#define CONST_STRNEQ(STR1,STR2) (strncmp ((STR1), (STR2), sizeof (STR2) - 1) == 0)
30313 + /* strcpy() can have a similar problem, but since we know we are
30314 + copying a constant string, we can use memcpy which will be faster
30315 + since there is no need to check for a NUL byte inside STR. We
30316 + can also save time if we do not need to copy the terminating NUL. */
30317 +#define LITMEMCPY(DEST,STR2) memcpy ((DEST), (STR2), sizeof (STR2) - 1)
30318 +#define LITSTRCPY(DEST,STR2) memcpy ((DEST), (STR2), sizeof (STR2))
30319 +
30320 +
30321 +/* The word size used by BFD on the host. This may be 64 with a 32
30322 + bit target if the host is 64 bit, or if other 64 bit targets have
30323 + been selected with --enable-targets, or if --enable-64-bit-bfd. */
30324 +#define BFD_ARCH_SIZE 32
30325 +
30326 +/* The word size of the default bfd target. */
30327 +#define BFD_DEFAULT_TARGET_SIZE 32
30328 +
30329 +#define BFD_HOST_64BIT_LONG 0
30330 +#define BFD_HOST_64BIT_LONG_LONG 0
30331 +#define BFD_HOST_LONG_LONG 1
30332 +#if 1
30333 +#define BFD_HOST_64_BIT long long
30334 +#define BFD_HOST_U_64_BIT unsigned long long
30335 +typedef BFD_HOST_64_BIT bfd_int64_t;
30336 +typedef BFD_HOST_U_64_BIT bfd_uint64_t;
30337 +#endif
30338 +
30339 +#if BFD_ARCH_SIZE >= 64
30340 +#define BFD64
30341 +#endif
30342 +
30343 +#ifndef INLINE
30344 +#if __GNUC__ >= 2
30345 +#define INLINE __inline__
30346 +#else
30347 +#define INLINE
30348 +#endif
30349 +#endif
30350 +
30351 +/* Declaring a type wide enough to hold a host long and a host pointer. */
30352 +#define BFD_HOSTPTR_T unsigned long
30353 +typedef BFD_HOSTPTR_T bfd_hostptr_t;
30354 +
30355 +/* Forward declaration. */
30356 +typedef struct bfd bfd;
30357 +
30358 +/* Boolean type used in bfd. Too many systems define their own
30359 + versions of "boolean" for us to safely typedef a "boolean" of
30360 + our own. Using an enum for "bfd_boolean" has its own set of
30361 + problems, with strange looking casts required to avoid warnings
30362 + on some older compilers. Thus we just use an int.
30363 +
30364 + General rule: Functions which are bfd_boolean return TRUE on
30365 + success and FALSE on failure (unless they're a predicate). */
30366 +
30367 +typedef int bfd_boolean;
30368 +#undef FALSE
30369 +#undef TRUE
30370 +#define FALSE 0
30371 +#define TRUE 1
30372 +
30373 +#ifdef BFD64
30374 +
30375 +#ifndef BFD_HOST_64_BIT
30376 + #error No 64 bit integer type available
30377 +#endif /* ! defined (BFD_HOST_64_BIT) */
30378 +
30379 +typedef BFD_HOST_U_64_BIT bfd_vma;
30380 +typedef BFD_HOST_64_BIT bfd_signed_vma;
30381 +typedef BFD_HOST_U_64_BIT bfd_size_type;
30382 +typedef BFD_HOST_U_64_BIT symvalue;
30383 +
30384 +#ifndef fprintf_vma
30385 +#if BFD_HOST_64BIT_LONG
30386 +#define sprintf_vma(s,x) sprintf (s, "%016lx", x)
30387 +#define fprintf_vma(f,x) fprintf (f, "%016lx", x)
30388 +#elif BFD_HOST_64BIT_LONG_LONG
30389 +#define sprintf_vma(s,x) sprintf (s, "%016llx", x)
30390 +#define fprintf_vma(f,x) fprintf (f, "%016llx", x)
30391 +#else
30392 +#define _bfd_int64_low(x) ((unsigned long) (((x) & 0xffffffff)))
30393 +#define _bfd_int64_high(x) ((unsigned long) (((x) >> 32) & 0xffffffff))
30394 +#define fprintf_vma(s,x) \
30395 + fprintf ((s), "%08lx%08lx", _bfd_int64_high (x), _bfd_int64_low (x))
30396 +#define sprintf_vma(s,x) \
30397 + sprintf ((s), "%08lx%08lx", _bfd_int64_high (x), _bfd_int64_low (x))
30398 +#endif
30399 +#endif
30400 +
30401 +#else /* not BFD64 */
30402 +
30403 +/* Represent a target address. Also used as a generic unsigned type
30404 + which is guaranteed to be big enough to hold any arithmetic types
30405 + we need to deal with. */
30406 +typedef unsigned long bfd_vma;
30407 +
30408 +/* A generic signed type which is guaranteed to be big enough to hold any
30409 + arithmetic types we need to deal with. Can be assumed to be compatible
30410 + with bfd_vma in the same way that signed and unsigned ints are compatible
30411 + (as parameters, in assignment, etc). */
30412 +typedef long bfd_signed_vma;
30413 +
30414 +typedef unsigned long symvalue;
30415 +typedef unsigned long bfd_size_type;
30416 +
30417 +/* Print a bfd_vma x on stream s. */
30418 +#define fprintf_vma(s,x) fprintf (s, "%08lx", x)
30419 +#define sprintf_vma(s,x) sprintf (s, "%08lx", x)
30420 +
30421 +#endif /* not BFD64 */
30422 +
30423 +#define HALF_BFD_SIZE_TYPE \
30424 + (((bfd_size_type) 1) << (8 * sizeof (bfd_size_type) / 2))
30425 +
30426 +#ifndef BFD_HOST_64_BIT
30427 +/* Fall back on a 32 bit type. The idea is to make these types always
30428 + available for function return types, but in the case that
30429 + BFD_HOST_64_BIT is undefined such a function should abort or
30430 + otherwise signal an error. */
30431 +typedef bfd_signed_vma bfd_int64_t;
30432 +typedef bfd_vma bfd_uint64_t;
30433 +#endif
30434 +
30435 +/* An offset into a file. BFD always uses the largest possible offset
30436 + based on the build time availability of fseek, fseeko, or fseeko64. */
30437 +typedef BFD_HOST_64_BIT file_ptr;
30438 +typedef unsigned BFD_HOST_64_BIT ufile_ptr;
30439 +
30440 +extern void bfd_sprintf_vma (bfd *, char *, bfd_vma);
30441 +extern void bfd_fprintf_vma (bfd *, void *, bfd_vma);
30442 +
30443 +#define printf_vma(x) fprintf_vma(stdout,x)
30444 +#define bfd_printf_vma(abfd,x) bfd_fprintf_vma (abfd,stdout,x)
30445 +
30446 +typedef unsigned int flagword; /* 32 bits of flags */
30447 +typedef unsigned char bfd_byte;
30448 +\f
30449 +/* File formats. */
30450 +
30451 +typedef enum bfd_format
30452 +{
30453 + bfd_unknown = 0, /* File format is unknown. */
30454 + bfd_object, /* Linker/assembler/compiler output. */
30455 + bfd_archive, /* Object archive file. */
30456 + bfd_core, /* Core dump. */
30457 + bfd_type_end /* Marks the end; don't use it! */
30458 +}
30459 +bfd_format;
30460 +
30461 +/* Values that may appear in the flags field of a BFD. These also
30462 + appear in the object_flags field of the bfd_target structure, where
30463 + they indicate the set of flags used by that backend (not all flags
30464 + are meaningful for all object file formats) (FIXME: at the moment,
30465 + the object_flags values have mostly just been copied from backend
30466 + to another, and are not necessarily correct). */
30467 +
30468 +/* No flags. */
30469 +#define BFD_NO_FLAGS 0x00
30470 +
30471 +/* BFD contains relocation entries. */
30472 +#define HAS_RELOC 0x01
30473 +
30474 +/* BFD is directly executable. */
30475 +#define EXEC_P 0x02
30476 +
30477 +/* BFD has line number information (basically used for F_LNNO in a
30478 + COFF header). */
30479 +#define HAS_LINENO 0x04
30480 +
30481 +/* BFD has debugging information. */
30482 +#define HAS_DEBUG 0x08
30483 +
30484 +/* BFD has symbols. */
30485 +#define HAS_SYMS 0x10
30486 +
30487 +/* BFD has local symbols (basically used for F_LSYMS in a COFF
30488 + header). */
30489 +#define HAS_LOCALS 0x20
30490 +
30491 +/* BFD is a dynamic object. */
30492 +#define DYNAMIC 0x40
30493 +
30494 +/* Text section is write protected (if D_PAGED is not set, this is
30495 + like an a.out NMAGIC file) (the linker sets this by default, but
30496 + clears it for -r or -N). */
30497 +#define WP_TEXT 0x80
30498 +
30499 +/* BFD is dynamically paged (this is like an a.out ZMAGIC file) (the
30500 + linker sets this by default, but clears it for -r or -n or -N). */
30501 +#define D_PAGED 0x100
30502 +
30503 +/* BFD is relaxable (this means that bfd_relax_section may be able to
30504 + do something) (sometimes bfd_relax_section can do something even if
30505 + this is not set). */
30506 +#define BFD_IS_RELAXABLE 0x200
30507 +
30508 +/* This may be set before writing out a BFD to request using a
30509 + traditional format. For example, this is used to request that when
30510 + writing out an a.out object the symbols not be hashed to eliminate
30511 + duplicates. */
30512 +#define BFD_TRADITIONAL_FORMAT 0x400
30513 +
30514 +/* This flag indicates that the BFD contents are actually cached in
30515 + memory. If this is set, iostream points to a bfd_in_memory struct. */
30516 +#define BFD_IN_MEMORY 0x800
30517 +
30518 +/* The sections in this BFD specify a memory page. */
30519 +#define HAS_LOAD_PAGE 0x1000
30520 +
30521 +/* This BFD has been created by the linker and doesn't correspond
30522 + to any input file. */
30523 +#define BFD_LINKER_CREATED 0x2000
30524 +\f
30525 +/* Symbols and relocation. */
30526 +
30527 +/* A count of carsyms (canonical archive symbols). */
30528 +typedef unsigned long symindex;
30529 +
30530 +/* How to perform a relocation. */
30531 +typedef const struct reloc_howto_struct reloc_howto_type;
30532 +
30533 +#define BFD_NO_MORE_SYMBOLS ((symindex) ~0)
30534 +
30535 +/* General purpose part of a symbol X;
30536 + target specific parts are in libcoff.h, libaout.h, etc. */
30537 +
30538 +#define bfd_get_section(x) ((x)->section)
30539 +#define bfd_get_output_section(x) ((x)->section->output_section)
30540 +#define bfd_set_section(x,y) ((x)->section) = (y)
30541 +#define bfd_asymbol_base(x) ((x)->section->vma)
30542 +#define bfd_asymbol_value(x) (bfd_asymbol_base(x) + (x)->value)
30543 +#define bfd_asymbol_name(x) ((x)->name)
30544 +/*Perhaps future: #define bfd_asymbol_bfd(x) ((x)->section->owner)*/
30545 +#define bfd_asymbol_bfd(x) ((x)->the_bfd)
30546 +#define bfd_asymbol_flavour(x) (bfd_asymbol_bfd(x)->xvec->flavour)
30547 +
30548 +/* A canonical archive symbol. */
30549 +/* This is a type pun with struct ranlib on purpose! */
30550 +typedef struct carsym
30551 +{
30552 + char *name;
30553 + file_ptr file_offset; /* Look here to find the file. */
30554 +}
30555 +carsym; /* To make these you call a carsymogen. */
30556 +
30557 +/* Used in generating armaps (archive tables of contents).
30558 + Perhaps just a forward definition would do? */
30559 +struct orl /* Output ranlib. */
30560 +{
30561 + char **name; /* Symbol name. */
30562 + union
30563 + {
30564 + file_ptr pos;
30565 + bfd *abfd;
30566 + } u; /* bfd* or file position. */
30567 + int namidx; /* Index into string table. */
30568 +};
30569 +\f
30570 +/* Linenumber stuff. */
30571 +typedef struct lineno_cache_entry
30572 +{
30573 + unsigned int line_number; /* Linenumber from start of function. */
30574 + union
30575 + {
30576 + struct bfd_symbol *sym; /* Function name. */
30577 + bfd_vma offset; /* Offset into section. */
30578 + } u;
30579 +}
30580 +alent;
30581 +\f
30582 +/* Object and core file sections. */
30583 +
30584 +#define align_power(addr, align) \
30585 + (((addr) + ((bfd_vma) 1 << (align)) - 1) & ((bfd_vma) -1 << (align)))
30586 +
30587 +typedef struct bfd_section *sec_ptr;
30588 +
30589 +#define bfd_get_section_name(bfd, ptr) ((ptr)->name + 0)
30590 +#define bfd_get_section_vma(bfd, ptr) ((ptr)->vma + 0)
30591 +#define bfd_get_section_lma(bfd, ptr) ((ptr)->lma + 0)
30592 +#define bfd_get_section_alignment(bfd, ptr) ((ptr)->alignment_power + 0)
30593 +#define bfd_section_name(bfd, ptr) ((ptr)->name)
30594 +#define bfd_section_size(bfd, ptr) ((ptr)->size)
30595 +#define bfd_get_section_size(ptr) ((ptr)->size)
30596 +#define bfd_section_vma(bfd, ptr) ((ptr)->vma)
30597 +#define bfd_section_lma(bfd, ptr) ((ptr)->lma)
30598 +#define bfd_section_alignment(bfd, ptr) ((ptr)->alignment_power)
30599 +#define bfd_get_section_flags(bfd, ptr) ((ptr)->flags + 0)
30600 +#define bfd_get_section_userdata(bfd, ptr) ((ptr)->userdata)
30601 +
30602 +#define bfd_is_com_section(ptr) (((ptr)->flags & SEC_IS_COMMON) != 0)
30603 +
30604 +#define bfd_set_section_vma(bfd, ptr, val) (((ptr)->vma = (ptr)->lma = (val)), ((ptr)->user_set_vma = TRUE), TRUE)
30605 +#define bfd_set_section_alignment(bfd, ptr, val) (((ptr)->alignment_power = (val)),TRUE)
30606 +#define bfd_set_section_userdata(bfd, ptr, val) (((ptr)->userdata = (val)),TRUE)
30607 +/* Find the address one past the end of SEC. */
30608 +#define bfd_get_section_limit(bfd, sec) \
30609 + (((sec)->rawsize ? (sec)->rawsize : (sec)->size) \
30610 + / bfd_octets_per_byte (bfd))
30611 +
30612 +/* Return TRUE if section has been discarded. */
30613 +#define elf_discarded_section(sec) \
30614 + (!bfd_is_abs_section (sec) \
30615 + && bfd_is_abs_section ((sec)->output_section) \
30616 + && (sec)->sec_info_type != ELF_INFO_TYPE_MERGE \
30617 + && (sec)->sec_info_type != ELF_INFO_TYPE_JUST_SYMS)
30618 +
30619 +/* Forward define. */
30620 +struct stat;
30621 +\f
30622 +typedef enum bfd_print_symbol
30623 +{
30624 + bfd_print_symbol_name,
30625 + bfd_print_symbol_more,
30626 + bfd_print_symbol_all
30627 +} bfd_print_symbol_type;
30628 +
30629 +/* Information about a symbol that nm needs. */
30630 +
30631 +typedef struct _symbol_info
30632 +{
30633 + symvalue value;
30634 + char type;
30635 + const char *name; /* Symbol name. */
30636 + unsigned char stab_type; /* Stab type. */
30637 + char stab_other; /* Stab other. */
30638 + short stab_desc; /* Stab desc. */
30639 + const char *stab_name; /* String for stab type. */
30640 +} symbol_info;
30641 +
30642 +/* Get the name of a stabs type code. */
30643 +
30644 +extern const char *bfd_get_stab_name (int);
30645 +\f
30646 +/* Hash table routines. There is no way to free up a hash table. */
30647 +
30648 +/* An element in the hash table. Most uses will actually use a larger
30649 + structure, and an instance of this will be the first field. */
30650 +
30651 +struct bfd_hash_entry
30652 +{
30653 + /* Next entry for this hash code. */
30654 + struct bfd_hash_entry *next;
30655 + /* String being hashed. */
30656 + const char *string;
30657 + /* Hash code. This is the full hash code, not the index into the
30658 + table. */
30659 + unsigned long hash;
30660 +};
30661 +
30662 +/* A hash table. */
30663 +
30664 +struct bfd_hash_table
30665 +{
30666 + /* The hash array. */
30667 + struct bfd_hash_entry **table;
30668 + /* A function used to create new elements in the hash table. The
30669 + first entry is itself a pointer to an element. When this
30670 + function is first invoked, this pointer will be NULL. However,
30671 + having the pointer permits a hierarchy of method functions to be
30672 + built each of which calls the function in the superclass. Thus
30673 + each function should be written to allocate a new block of memory
30674 + only if the argument is NULL. */
30675 + struct bfd_hash_entry *(*newfunc)
30676 + (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
30677 + /* An objalloc for this hash table. This is a struct objalloc *,
30678 + but we use void * to avoid requiring the inclusion of objalloc.h. */
30679 + void *memory;
30680 + /* The number of slots in the hash table. */
30681 + unsigned int size;
30682 + /* The number of entries in the hash table. */
30683 + unsigned int count;
30684 + /* The size of elements. */
30685 + unsigned int entsize;
30686 + /* If non-zero, don't grow the hash table. */
30687 + unsigned int frozen:1;
30688 +};
30689 +
30690 +/* Initialize a hash table. */
30691 +extern bfd_boolean bfd_hash_table_init
30692 + (struct bfd_hash_table *,
30693 + struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
30694 + struct bfd_hash_table *,
30695 + const char *),
30696 + unsigned int);
30697 +
30698 +/* Initialize a hash table specifying a size. */
30699 +extern bfd_boolean bfd_hash_table_init_n
30700 + (struct bfd_hash_table *,
30701 + struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
30702 + struct bfd_hash_table *,
30703 + const char *),
30704 + unsigned int, unsigned int);
30705 +
30706 +/* Free up a hash table. */
30707 +extern void bfd_hash_table_free
30708 + (struct bfd_hash_table *);
30709 +
30710 +/* Look up a string in a hash table. If CREATE is TRUE, a new entry
30711 + will be created for this string if one does not already exist. The
30712 + COPY argument must be TRUE if this routine should copy the string
30713 + into newly allocated memory when adding an entry. */
30714 +extern struct bfd_hash_entry *bfd_hash_lookup
30715 + (struct bfd_hash_table *, const char *, bfd_boolean create,
30716 + bfd_boolean copy);
30717 +
30718 +/* Replace an entry in a hash table. */
30719 +extern void bfd_hash_replace
30720 + (struct bfd_hash_table *, struct bfd_hash_entry *old,
30721 + struct bfd_hash_entry *nw);
30722 +
30723 +/* Base method for creating a hash table entry. */
30724 +extern struct bfd_hash_entry *bfd_hash_newfunc
30725 + (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
30726 +
30727 +/* Grab some space for a hash table entry. */
30728 +extern void *bfd_hash_allocate
30729 + (struct bfd_hash_table *, unsigned int);
30730 +
30731 +/* Traverse a hash table in a random order, calling a function on each
30732 + element. If the function returns FALSE, the traversal stops. The
30733 + INFO argument is passed to the function. */
30734 +extern void bfd_hash_traverse
30735 + (struct bfd_hash_table *,
30736 + bfd_boolean (*) (struct bfd_hash_entry *, void *),
30737 + void *info);
30738 +
30739 +/* Allows the default size of a hash table to be configured. New hash
30740 + tables allocated using bfd_hash_table_init will be created with
30741 + this size. */
30742 +extern void bfd_hash_set_default_size (bfd_size_type);
30743 +
30744 +/* This structure is used to keep track of stabs in sections
30745 + information while linking. */
30746 +
30747 +struct stab_info
30748 +{
30749 + /* A hash table used to hold stabs strings. */
30750 + struct bfd_strtab_hash *strings;
30751 + /* The header file hash table. */
30752 + struct bfd_hash_table includes;
30753 + /* The first .stabstr section. */
30754 + struct bfd_section *stabstr;
30755 +};
30756 +
30757 +#define COFF_SWAP_TABLE (void *) &bfd_coff_std_swap_table
30758 +
30759 +/* User program access to BFD facilities. */
30760 +
30761 +/* Direct I/O routines, for programs which know more about the object
30762 + file than BFD does. Use higher level routines if possible. */
30763 +
30764 +extern bfd_size_type bfd_bread (void *, bfd_size_type, bfd *);
30765 +extern bfd_size_type bfd_bwrite (const void *, bfd_size_type, bfd *);
30766 +extern int bfd_seek (bfd *, file_ptr, int);
30767 +extern file_ptr bfd_tell (bfd *);
30768 +extern int bfd_flush (bfd *);
30769 +extern int bfd_stat (bfd *, struct stat *);
30770 +
30771 +/* Deprecated old routines. */
30772 +#if __GNUC__
30773 +#define bfd_read(BUF, ELTSIZE, NITEMS, ABFD) \
30774 + (warn_deprecated ("bfd_read", __FILE__, __LINE__, __FUNCTION__), \
30775 + bfd_bread ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
30776 +#define bfd_write(BUF, ELTSIZE, NITEMS, ABFD) \
30777 + (warn_deprecated ("bfd_write", __FILE__, __LINE__, __FUNCTION__), \
30778 + bfd_bwrite ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
30779 +#else
30780 +#define bfd_read(BUF, ELTSIZE, NITEMS, ABFD) \
30781 + (warn_deprecated ("bfd_read", (const char *) 0, 0, (const char *) 0), \
30782 + bfd_bread ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
30783 +#define bfd_write(BUF, ELTSIZE, NITEMS, ABFD) \
30784 + (warn_deprecated ("bfd_write", (const char *) 0, 0, (const char *) 0),\
30785 + bfd_bwrite ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
30786 +#endif
30787 +extern void warn_deprecated (const char *, const char *, int, const char *);
30788 +
30789 +/* Cast from const char * to char * so that caller can assign to
30790 + a char * without a warning. */
30791 +#define bfd_get_filename(abfd) ((char *) (abfd)->filename)
30792 +#define bfd_get_cacheable(abfd) ((abfd)->cacheable)
30793 +#define bfd_get_format(abfd) ((abfd)->format)
30794 +#define bfd_get_target(abfd) ((abfd)->xvec->name)
30795 +#define bfd_get_flavour(abfd) ((abfd)->xvec->flavour)
30796 +#define bfd_family_coff(abfd) \
30797 + (bfd_get_flavour (abfd) == bfd_target_coff_flavour || \
30798 + bfd_get_flavour (abfd) == bfd_target_xcoff_flavour)
30799 +#define bfd_big_endian(abfd) ((abfd)->xvec->byteorder == BFD_ENDIAN_BIG)
30800 +#define bfd_little_endian(abfd) ((abfd)->xvec->byteorder == BFD_ENDIAN_LITTLE)
30801 +#define bfd_header_big_endian(abfd) \
30802 + ((abfd)->xvec->header_byteorder == BFD_ENDIAN_BIG)
30803 +#define bfd_header_little_endian(abfd) \
30804 + ((abfd)->xvec->header_byteorder == BFD_ENDIAN_LITTLE)
30805 +#define bfd_get_file_flags(abfd) ((abfd)->flags)
30806 +#define bfd_applicable_file_flags(abfd) ((abfd)->xvec->object_flags)
30807 +#define bfd_applicable_section_flags(abfd) ((abfd)->xvec->section_flags)
30808 +#define bfd_my_archive(abfd) ((abfd)->my_archive)
30809 +#define bfd_has_map(abfd) ((abfd)->has_armap)
30810 +
30811 +#define bfd_valid_reloc_types(abfd) ((abfd)->xvec->valid_reloc_types)
30812 +#define bfd_usrdata(abfd) ((abfd)->usrdata)
30813 +
30814 +#define bfd_get_start_address(abfd) ((abfd)->start_address)
30815 +#define bfd_get_symcount(abfd) ((abfd)->symcount)
30816 +#define bfd_get_outsymbols(abfd) ((abfd)->outsymbols)
30817 +#define bfd_count_sections(abfd) ((abfd)->section_count)
30818 +
30819 +#define bfd_get_dynamic_symcount(abfd) ((abfd)->dynsymcount)
30820 +
30821 +#define bfd_get_symbol_leading_char(abfd) ((abfd)->xvec->symbol_leading_char)
30822 +
30823 +#define bfd_set_cacheable(abfd,bool) (((abfd)->cacheable = bool), TRUE)
30824 +
30825 +extern bfd_boolean bfd_cache_close
30826 + (bfd *abfd);
30827 +/* NB: This declaration should match the autogenerated one in libbfd.h. */
30828 +
30829 +extern bfd_boolean bfd_cache_close_all (void);
30830 +
30831 +extern bfd_boolean bfd_record_phdr
30832 + (bfd *, unsigned long, bfd_boolean, flagword, bfd_boolean, bfd_vma,
30833 + bfd_boolean, bfd_boolean, unsigned int, struct bfd_section **);
30834 +
30835 +/* Byte swapping routines. */
30836 +
30837 +bfd_uint64_t bfd_getb64 (const void *);
30838 +bfd_uint64_t bfd_getl64 (const void *);
30839 +bfd_int64_t bfd_getb_signed_64 (const void *);
30840 +bfd_int64_t bfd_getl_signed_64 (const void *);
30841 +bfd_vma bfd_getb32 (const void *);
30842 +bfd_vma bfd_getl32 (const void *);
30843 +bfd_signed_vma bfd_getb_signed_32 (const void *);
30844 +bfd_signed_vma bfd_getl_signed_32 (const void *);
30845 +bfd_vma bfd_getb16 (const void *);
30846 +bfd_vma bfd_getl16 (const void *);
30847 +bfd_signed_vma bfd_getb_signed_16 (const void *);
30848 +bfd_signed_vma bfd_getl_signed_16 (const void *);
30849 +void bfd_putb64 (bfd_uint64_t, void *);
30850 +void bfd_putl64 (bfd_uint64_t, void *);
30851 +void bfd_putb32 (bfd_vma, void *);
30852 +void bfd_putl32 (bfd_vma, void *);
30853 +void bfd_putb16 (bfd_vma, void *);
30854 +void bfd_putl16 (bfd_vma, void *);
30855 +
30856 +/* Byte swapping routines which take size and endiannes as arguments. */
30857 +
30858 +bfd_uint64_t bfd_get_bits (const void *, int, bfd_boolean);
30859 +void bfd_put_bits (bfd_uint64_t, void *, int, bfd_boolean);
30860 +
30861 +extern bfd_boolean bfd_section_already_linked_table_init (void);
30862 +extern void bfd_section_already_linked_table_free (void);
30863 +\f
30864 +/* Externally visible ECOFF routines. */
30865 +
30866 +#if defined(__STDC__) || defined(ALMOST_STDC)
30867 +struct ecoff_debug_info;
30868 +struct ecoff_debug_swap;
30869 +struct ecoff_extr;
30870 +struct bfd_symbol;
30871 +struct bfd_link_info;
30872 +struct bfd_link_hash_entry;
30873 +struct bfd_elf_version_tree;
30874 +#endif
30875 +extern bfd_vma bfd_ecoff_get_gp_value
30876 + (bfd * abfd);
30877 +extern bfd_boolean bfd_ecoff_set_gp_value
30878 + (bfd *abfd, bfd_vma gp_value);
30879 +extern bfd_boolean bfd_ecoff_set_regmasks
30880 + (bfd *abfd, unsigned long gprmask, unsigned long fprmask,
30881 + unsigned long *cprmask);
30882 +extern void *bfd_ecoff_debug_init
30883 + (bfd *output_bfd, struct ecoff_debug_info *output_debug,
30884 + const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
30885 +extern void bfd_ecoff_debug_free
30886 + (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
30887 + const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
30888 +extern bfd_boolean bfd_ecoff_debug_accumulate
30889 + (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
30890 + const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
30891 + struct ecoff_debug_info *input_debug,
30892 + const struct ecoff_debug_swap *input_swap, struct bfd_link_info *);
30893 +extern bfd_boolean bfd_ecoff_debug_accumulate_other
30894 + (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
30895 + const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
30896 + struct bfd_link_info *);
30897 +extern bfd_boolean bfd_ecoff_debug_externals
30898 + (bfd *abfd, struct ecoff_debug_info *debug,
30899 + const struct ecoff_debug_swap *swap, bfd_boolean relocatable,
30900 + bfd_boolean (*get_extr) (struct bfd_symbol *, struct ecoff_extr *),
30901 + void (*set_index) (struct bfd_symbol *, bfd_size_type));
30902 +extern bfd_boolean bfd_ecoff_debug_one_external
30903 + (bfd *abfd, struct ecoff_debug_info *debug,
30904 + const struct ecoff_debug_swap *swap, const char *name,
30905 + struct ecoff_extr *esym);
30906 +extern bfd_size_type bfd_ecoff_debug_size
30907 + (bfd *abfd, struct ecoff_debug_info *debug,
30908 + const struct ecoff_debug_swap *swap);
30909 +extern bfd_boolean bfd_ecoff_write_debug
30910 + (bfd *abfd, struct ecoff_debug_info *debug,
30911 + const struct ecoff_debug_swap *swap, file_ptr where);
30912 +extern bfd_boolean bfd_ecoff_write_accumulated_debug
30913 + (void *handle, bfd *abfd, struct ecoff_debug_info *debug,
30914 + const struct ecoff_debug_swap *swap,
30915 + struct bfd_link_info *info, file_ptr where);
30916 +
30917 +/* Externally visible ELF routines. */
30918 +
30919 +struct bfd_link_needed_list
30920 +{
30921 + struct bfd_link_needed_list *next;
30922 + bfd *by;
30923 + const char *name;
30924 +};
30925 +
30926 +enum dynamic_lib_link_class {
30927 + DYN_NORMAL = 0,
30928 + DYN_AS_NEEDED = 1,
30929 + DYN_DT_NEEDED = 2,
30930 + DYN_NO_ADD_NEEDED = 4,
30931 + DYN_NO_NEEDED = 8
30932 +};
30933 +
30934 +enum notice_asneeded_action {
30935 + notice_as_needed,
30936 + notice_not_needed,
30937 + notice_needed
30938 +};
30939 +
30940 +extern bfd_boolean bfd_elf_record_link_assignment
30941 + (bfd *, struct bfd_link_info *, const char *, bfd_boolean,
30942 + bfd_boolean);
30943 +extern struct bfd_link_needed_list *bfd_elf_get_needed_list
30944 + (bfd *, struct bfd_link_info *);
30945 +extern bfd_boolean bfd_elf_get_bfd_needed_list
30946 + (bfd *, struct bfd_link_needed_list **);
30947 +extern bfd_boolean bfd_elf_size_dynamic_sections
30948 + (bfd *, const char *, const char *, const char *, const char * const *,
30949 + struct bfd_link_info *, struct bfd_section **,
30950 + struct bfd_elf_version_tree *);
30951 +extern bfd_boolean bfd_elf_size_dynsym_hash_dynstr
30952 + (bfd *, struct bfd_link_info *);
30953 +extern void bfd_elf_set_dt_needed_name
30954 + (bfd *, const char *);
30955 +extern const char *bfd_elf_get_dt_soname
30956 + (bfd *);
30957 +extern void bfd_elf_set_dyn_lib_class
30958 + (bfd *, enum dynamic_lib_link_class);
30959 +extern int bfd_elf_get_dyn_lib_class
30960 + (bfd *);
30961 +extern struct bfd_link_needed_list *bfd_elf_get_runpath_list
30962 + (bfd *, struct bfd_link_info *);
30963 +extern bfd_boolean bfd_elf_discard_info
30964 + (bfd *, struct bfd_link_info *);
30965 +extern unsigned int _bfd_elf_default_action_discarded
30966 + (struct bfd_section *);
30967 +
30968 +/* Return an upper bound on the number of bytes required to store a
30969 + copy of ABFD's program header table entries. Return -1 if an error
30970 + occurs; bfd_get_error will return an appropriate code. */
30971 +extern long bfd_get_elf_phdr_upper_bound
30972 + (bfd *abfd);
30973 +
30974 +/* Copy ABFD's program header table entries to *PHDRS. The entries
30975 + will be stored as an array of Elf_Internal_Phdr structures, as
30976 + defined in include/elf/internal.h. To find out how large the
30977 + buffer needs to be, call bfd_get_elf_phdr_upper_bound.
30978 +
30979 + Return the number of program header table entries read, or -1 if an
30980 + error occurs; bfd_get_error will return an appropriate code. */
30981 +extern int bfd_get_elf_phdrs
30982 + (bfd *abfd, void *phdrs);
30983 +
30984 +/* Create a new BFD as if by bfd_openr. Rather than opening a file,
30985 + reconstruct an ELF file by reading the segments out of remote memory
30986 + based on the ELF file header at EHDR_VMA and the ELF program headers it
30987 + points to. If not null, *LOADBASEP is filled in with the difference
30988 + between the VMAs from which the segments were read, and the VMAs the
30989 + file headers (and hence BFD's idea of each section's VMA) put them at.
30990 +
30991 + The function TARGET_READ_MEMORY is called to copy LEN bytes from the
30992 + remote memory at target address VMA into the local buffer at MYADDR; it
30993 + should return zero on success or an `errno' code on failure. TEMPL must
30994 + be a BFD for an ELF target with the word size and byte order found in
30995 + the remote memory. */
30996 +extern bfd *bfd_elf_bfd_from_remote_memory
30997 + (bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
30998 + int (*target_read_memory) (bfd_vma vma, bfd_byte *myaddr, int len));
30999 +
31000 +/* Return the arch_size field of an elf bfd, or -1 if not elf. */
31001 +extern int bfd_get_arch_size
31002 + (bfd *);
31003 +
31004 +/* Return TRUE if address "naturally" sign extends, or -1 if not elf. */
31005 +extern int bfd_get_sign_extend_vma
31006 + (bfd *);
31007 +
31008 +extern struct bfd_section *_bfd_elf_tls_setup
31009 + (bfd *, struct bfd_link_info *);
31010 +
31011 +extern void _bfd_fix_excluded_sec_syms
31012 + (bfd *, struct bfd_link_info *);
31013 +
31014 +extern unsigned bfd_m68k_mach_to_features (int);
31015 +
31016 +extern int bfd_m68k_features_to_mach (unsigned);
31017 +
31018 +extern bfd_boolean bfd_m68k_elf32_create_embedded_relocs
31019 + (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *,
31020 + char **);
31021 +
31022 +extern bfd_boolean bfd_bfin_elf32_create_embedded_relocs
31023 + (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *,
31024 + char **);
31025 +
31026 +/* SunOS shared library support routines for the linker. */
31027 +
31028 +extern struct bfd_link_needed_list *bfd_sunos_get_needed_list
31029 + (bfd *, struct bfd_link_info *);
31030 +extern bfd_boolean bfd_sunos_record_link_assignment
31031 + (bfd *, struct bfd_link_info *, const char *);
31032 +extern bfd_boolean bfd_sunos_size_dynamic_sections
31033 + (bfd *, struct bfd_link_info *, struct bfd_section **,
31034 + struct bfd_section **, struct bfd_section **);
31035 +
31036 +/* Linux shared library support routines for the linker. */
31037 +
31038 +extern bfd_boolean bfd_i386linux_size_dynamic_sections
31039 + (bfd *, struct bfd_link_info *);
31040 +extern bfd_boolean bfd_m68klinux_size_dynamic_sections
31041 + (bfd *, struct bfd_link_info *);
31042 +extern bfd_boolean bfd_sparclinux_size_dynamic_sections
31043 + (bfd *, struct bfd_link_info *);
31044 +
31045 +/* mmap hacks */
31046 +
31047 +struct _bfd_window_internal;
31048 +typedef struct _bfd_window_internal bfd_window_internal;
31049 +
31050 +typedef struct _bfd_window
31051 +{
31052 + /* What the user asked for. */
31053 + void *data;
31054 + bfd_size_type size;
31055 + /* The actual window used by BFD. Small user-requested read-only
31056 + regions sharing a page may share a single window into the object
31057 + file. Read-write versions shouldn't until I've fixed things to
31058 + keep track of which portions have been claimed by the
31059 + application; don't want to give the same region back when the
31060 + application wants two writable copies! */
31061 + struct _bfd_window_internal *i;
31062 +}
31063 +bfd_window;
31064 +
31065 +extern void bfd_init_window
31066 + (bfd_window *);
31067 +extern void bfd_free_window
31068 + (bfd_window *);
31069 +extern bfd_boolean bfd_get_file_window
31070 + (bfd *, file_ptr, bfd_size_type, bfd_window *, bfd_boolean);
31071 +
31072 +/* XCOFF support routines for the linker. */
31073 +
31074 +extern bfd_boolean bfd_xcoff_link_record_set
31075 + (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *, bfd_size_type);
31076 +extern bfd_boolean bfd_xcoff_import_symbol
31077 + (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *, bfd_vma,
31078 + const char *, const char *, const char *, unsigned int);
31079 +extern bfd_boolean bfd_xcoff_export_symbol
31080 + (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *);
31081 +extern bfd_boolean bfd_xcoff_link_count_reloc
31082 + (bfd *, struct bfd_link_info *, const char *);
31083 +extern bfd_boolean bfd_xcoff_record_link_assignment
31084 + (bfd *, struct bfd_link_info *, const char *);
31085 +extern bfd_boolean bfd_xcoff_size_dynamic_sections
31086 + (bfd *, struct bfd_link_info *, const char *, const char *,
31087 + unsigned long, unsigned long, unsigned long, bfd_boolean,
31088 + int, bfd_boolean, bfd_boolean, struct bfd_section **, bfd_boolean);
31089 +extern bfd_boolean bfd_xcoff_link_generate_rtinit
31090 + (bfd *, const char *, const char *, bfd_boolean);
31091 +
31092 +/* XCOFF support routines for ar. */
31093 +extern bfd_boolean bfd_xcoff_ar_archive_set_magic
31094 + (bfd *, char *);
31095 +
31096 +/* Externally visible COFF routines. */
31097 +
31098 +#if defined(__STDC__) || defined(ALMOST_STDC)
31099 +struct internal_syment;
31100 +union internal_auxent;
31101 +#endif
31102 +
31103 +extern bfd_boolean bfd_coff_get_syment
31104 + (bfd *, struct bfd_symbol *, struct internal_syment *);
31105 +
31106 +extern bfd_boolean bfd_coff_get_auxent
31107 + (bfd *, struct bfd_symbol *, int, union internal_auxent *);
31108 +
31109 +extern bfd_boolean bfd_coff_set_symbol_class
31110 + (bfd *, struct bfd_symbol *, unsigned int);
31111 +
31112 +extern bfd_boolean bfd_m68k_coff_create_embedded_relocs
31113 + (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
31114 +
31115 +/* ARM VFP11 erratum workaround support. */
31116 +typedef enum
31117 +{
31118 + BFD_ARM_VFP11_FIX_DEFAULT,
31119 + BFD_ARM_VFP11_FIX_NONE,
31120 + BFD_ARM_VFP11_FIX_SCALAR,
31121 + BFD_ARM_VFP11_FIX_VECTOR
31122 +} bfd_arm_vfp11_fix;
31123 +
31124 +extern void bfd_elf32_arm_init_maps
31125 + (bfd *);
31126 +
31127 +extern void bfd_elf32_arm_set_vfp11_fix
31128 + (bfd *, struct bfd_link_info *);
31129 +
31130 +extern bfd_boolean bfd_elf32_arm_vfp11_erratum_scan
31131 + (bfd *, struct bfd_link_info *);
31132 +
31133 +extern void bfd_elf32_arm_vfp11_fix_veneer_locations
31134 + (bfd *, struct bfd_link_info *);
31135 +
31136 +/* ARM Interworking support. Called from linker. */
31137 +extern bfd_boolean bfd_arm_allocate_interworking_sections
31138 + (struct bfd_link_info *);
31139 +
31140 +extern bfd_boolean bfd_arm_process_before_allocation
31141 + (bfd *, struct bfd_link_info *, int);
31142 +
31143 +extern bfd_boolean bfd_arm_get_bfd_for_interworking
31144 + (bfd *, struct bfd_link_info *);
31145 +
31146 +/* PE ARM Interworking support. Called from linker. */
31147 +extern bfd_boolean bfd_arm_pe_allocate_interworking_sections
31148 + (struct bfd_link_info *);
31149 +
31150 +extern bfd_boolean bfd_arm_pe_process_before_allocation
31151 + (bfd *, struct bfd_link_info *, int);
31152 +
31153 +extern bfd_boolean bfd_arm_pe_get_bfd_for_interworking
31154 + (bfd *, struct bfd_link_info *);
31155 +
31156 +/* ELF ARM Interworking support. Called from linker. */
31157 +extern bfd_boolean bfd_elf32_arm_allocate_interworking_sections
31158 + (struct bfd_link_info *);
31159 +
31160 +extern bfd_boolean bfd_elf32_arm_process_before_allocation
31161 + (bfd *, struct bfd_link_info *);
31162 +
31163 +void bfd_elf32_arm_set_target_relocs
31164 + (bfd *, struct bfd_link_info *, int, char *, int, int, bfd_arm_vfp11_fix,
31165 + int, int);
31166 +
31167 +extern bfd_boolean bfd_elf32_arm_get_bfd_for_interworking
31168 + (bfd *, struct bfd_link_info *);
31169 +
31170 +extern bfd_boolean bfd_elf32_arm_add_glue_sections_to_bfd
31171 + (bfd *, struct bfd_link_info *);
31172 +
31173 +/* ELF ARM mapping symbol support */
31174 +#define BFD_ARM_SPECIAL_SYM_TYPE_MAP (1 << 0)
31175 +#define BFD_ARM_SPECIAL_SYM_TYPE_TAG (1 << 1)
31176 +#define BFD_ARM_SPECIAL_SYM_TYPE_OTHER (1 << 2)
31177 +#define BFD_ARM_SPECIAL_SYM_TYPE_ANY (~0)
31178 +extern bfd_boolean bfd_is_arm_special_symbol_name
31179 + (const char * name, int type);
31180 +
31181 +extern void bfd_elf32_arm_set_byteswap_code (struct bfd_link_info *, int);
31182 +
31183 +/* ARM Note section processing. */
31184 +extern bfd_boolean bfd_arm_merge_machines
31185 + (bfd *, bfd *);
31186 +
31187 +extern bfd_boolean bfd_arm_update_notes
31188 + (bfd *, const char *);
31189 +
31190 +extern unsigned int bfd_arm_get_mach_from_notes
31191 + (bfd *, const char *);
31192 +
31193 +/* TI COFF load page support. */
31194 +extern void bfd_ticoff_set_section_load_page
31195 + (struct bfd_section *, int);
31196 +
31197 +extern int bfd_ticoff_get_section_load_page
31198 + (struct bfd_section *);
31199 +
31200 +/* H8/300 functions. */
31201 +extern bfd_vma bfd_h8300_pad_address
31202 + (bfd *, bfd_vma);
31203 +
31204 +/* IA64 Itanium code generation. Called from linker. */
31205 +extern void bfd_elf32_ia64_after_parse
31206 + (int);
31207 +
31208 +extern void bfd_elf64_ia64_after_parse
31209 + (int);
31210 +
31211 +/* This structure is used for a comdat section, as in PE. A comdat
31212 + section is associated with a particular symbol. When the linker
31213 + sees a comdat section, it keeps only one of the sections with a
31214 + given name and associated with a given symbol. */
31215 +
31216 +struct coff_comdat_info
31217 +{
31218 + /* The name of the symbol associated with a comdat section. */
31219 + const char *name;
31220 +
31221 + /* The local symbol table index of the symbol associated with a
31222 + comdat section. This is only meaningful to the object file format
31223 + specific code; it is not an index into the list returned by
31224 + bfd_canonicalize_symtab. */
31225 + long symbol;
31226 +};
31227 +
31228 +extern struct coff_comdat_info *bfd_coff_get_comdat_section
31229 + (bfd *, struct bfd_section *);
31230 +
31231 +/* Extracted from init.c. */
31232 +void bfd_init (void);
31233 +
31234 +/* Extracted from opncls.c. */
31235 +bfd *bfd_fopen (const char *filename, const char *target,
31236 + const char *mode, int fd);
31237 +
31238 +bfd *bfd_openr (const char *filename, const char *target);
31239 +
31240 +bfd *bfd_fdopenr (const char *filename, const char *target, int fd);
31241 +
31242 +bfd *bfd_openstreamr (const char *, const char *, void *);
31243 +
31244 +bfd *bfd_openr_iovec (const char *filename, const char *target,
31245 + void *(*open) (struct bfd *nbfd,
31246 + void *open_closure),
31247 + void *open_closure,
31248 + file_ptr (*pread) (struct bfd *nbfd,
31249 + void *stream,
31250 + void *buf,
31251 + file_ptr nbytes,
31252 + file_ptr offset),
31253 + int (*close) (struct bfd *nbfd,
31254 + void *stream),
31255 + int (*stat) (struct bfd *abfd,
31256 + void *stream,
31257 + struct stat *sb));
31258 +
31259 +bfd *bfd_openw (const char *filename, const char *target);
31260 +
31261 +bfd_boolean bfd_close (bfd *abfd);
31262 +
31263 +bfd_boolean bfd_close_all_done (bfd *);
31264 +
31265 +bfd *bfd_create (const char *filename, bfd *templ);
31266 +
31267 +bfd_boolean bfd_make_writable (bfd *abfd);
31268 +
31269 +bfd_boolean bfd_make_readable (bfd *abfd);
31270 +
31271 +unsigned long bfd_calc_gnu_debuglink_crc32
31272 + (unsigned long crc, const unsigned char *buf, bfd_size_type len);
31273 +
31274 +char *bfd_follow_gnu_debuglink (bfd *abfd, const char *dir);
31275 +
31276 +struct bfd_section *bfd_create_gnu_debuglink_section
31277 + (bfd *abfd, const char *filename);
31278 +
31279 +bfd_boolean bfd_fill_in_gnu_debuglink_section
31280 + (bfd *abfd, struct bfd_section *sect, const char *filename);
31281 +
31282 +/* Extracted from libbfd.c. */
31283 +
31284 +/* Byte swapping macros for user section data. */
31285 +
31286 +#define bfd_put_8(abfd, val, ptr) \
31287 + ((void) (*((unsigned char *) (ptr)) = (val) & 0xff))
31288 +#define bfd_put_signed_8 \
31289 + bfd_put_8
31290 +#define bfd_get_8(abfd, ptr) \
31291 + (*(unsigned char *) (ptr) & 0xff)
31292 +#define bfd_get_signed_8(abfd, ptr) \
31293 + (((*(unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80)
31294 +
31295 +#define bfd_put_16(abfd, val, ptr) \
31296 + BFD_SEND (abfd, bfd_putx16, ((val),(ptr)))
31297 +#define bfd_put_signed_16 \
31298 + bfd_put_16
31299 +#define bfd_get_16(abfd, ptr) \
31300 + BFD_SEND (abfd, bfd_getx16, (ptr))
31301 +#define bfd_get_signed_16(abfd, ptr) \
31302 + BFD_SEND (abfd, bfd_getx_signed_16, (ptr))
31303 +
31304 +#define bfd_put_32(abfd, val, ptr) \
31305 + BFD_SEND (abfd, bfd_putx32, ((val),(ptr)))
31306 +#define bfd_put_signed_32 \
31307 + bfd_put_32
31308 +#define bfd_get_32(abfd, ptr) \
31309 + BFD_SEND (abfd, bfd_getx32, (ptr))
31310 +#define bfd_get_signed_32(abfd, ptr) \
31311 + BFD_SEND (abfd, bfd_getx_signed_32, (ptr))
31312 +
31313 +#define bfd_put_64(abfd, val, ptr) \
31314 + BFD_SEND (abfd, bfd_putx64, ((val), (ptr)))
31315 +#define bfd_put_signed_64 \
31316 + bfd_put_64
31317 +#define bfd_get_64(abfd, ptr) \
31318 + BFD_SEND (abfd, bfd_getx64, (ptr))
31319 +#define bfd_get_signed_64(abfd, ptr) \
31320 + BFD_SEND (abfd, bfd_getx_signed_64, (ptr))
31321 +
31322 +#define bfd_get(bits, abfd, ptr) \
31323 + ((bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \
31324 + : (bits) == 16 ? bfd_get_16 (abfd, ptr) \
31325 + : (bits) == 32 ? bfd_get_32 (abfd, ptr) \
31326 + : (bits) == 64 ? bfd_get_64 (abfd, ptr) \
31327 + : (abort (), (bfd_vma) - 1))
31328 +
31329 +#define bfd_put(bits, abfd, val, ptr) \
31330 + ((bits) == 8 ? bfd_put_8 (abfd, val, ptr) \
31331 + : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \
31332 + : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \
31333 + : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \
31334 + : (abort (), (void) 0))
31335 +
31336 +
31337 +/* Byte swapping macros for file header data. */
31338 +
31339 +#define bfd_h_put_8(abfd, val, ptr) \
31340 + bfd_put_8 (abfd, val, ptr)
31341 +#define bfd_h_put_signed_8(abfd, val, ptr) \
31342 + bfd_put_8 (abfd, val, ptr)
31343 +#define bfd_h_get_8(abfd, ptr) \
31344 + bfd_get_8 (abfd, ptr)
31345 +#define bfd_h_get_signed_8(abfd, ptr) \
31346 + bfd_get_signed_8 (abfd, ptr)
31347 +
31348 +#define bfd_h_put_16(abfd, val, ptr) \
31349 + BFD_SEND (abfd, bfd_h_putx16, (val, ptr))
31350 +#define bfd_h_put_signed_16 \
31351 + bfd_h_put_16
31352 +#define bfd_h_get_16(abfd, ptr) \
31353 + BFD_SEND (abfd, bfd_h_getx16, (ptr))
31354 +#define bfd_h_get_signed_16(abfd, ptr) \
31355 + BFD_SEND (abfd, bfd_h_getx_signed_16, (ptr))
31356 +
31357 +#define bfd_h_put_32(abfd, val, ptr) \
31358 + BFD_SEND (abfd, bfd_h_putx32, (val, ptr))
31359 +#define bfd_h_put_signed_32 \
31360 + bfd_h_put_32
31361 +#define bfd_h_get_32(abfd, ptr) \
31362 + BFD_SEND (abfd, bfd_h_getx32, (ptr))
31363 +#define bfd_h_get_signed_32(abfd, ptr) \
31364 + BFD_SEND (abfd, bfd_h_getx_signed_32, (ptr))
31365 +
31366 +#define bfd_h_put_64(abfd, val, ptr) \
31367 + BFD_SEND (abfd, bfd_h_putx64, (val, ptr))
31368 +#define bfd_h_put_signed_64 \
31369 + bfd_h_put_64
31370 +#define bfd_h_get_64(abfd, ptr) \
31371 + BFD_SEND (abfd, bfd_h_getx64, (ptr))
31372 +#define bfd_h_get_signed_64(abfd, ptr) \
31373 + BFD_SEND (abfd, bfd_h_getx_signed_64, (ptr))
31374 +
31375 +/* Aliases for the above, which should eventually go away. */
31376 +
31377 +#define H_PUT_64 bfd_h_put_64
31378 +#define H_PUT_32 bfd_h_put_32
31379 +#define H_PUT_16 bfd_h_put_16
31380 +#define H_PUT_8 bfd_h_put_8
31381 +#define H_PUT_S64 bfd_h_put_signed_64
31382 +#define H_PUT_S32 bfd_h_put_signed_32
31383 +#define H_PUT_S16 bfd_h_put_signed_16
31384 +#define H_PUT_S8 bfd_h_put_signed_8
31385 +#define H_GET_64 bfd_h_get_64
31386 +#define H_GET_32 bfd_h_get_32
31387 +#define H_GET_16 bfd_h_get_16
31388 +#define H_GET_8 bfd_h_get_8
31389 +#define H_GET_S64 bfd_h_get_signed_64
31390 +#define H_GET_S32 bfd_h_get_signed_32
31391 +#define H_GET_S16 bfd_h_get_signed_16
31392 +#define H_GET_S8 bfd_h_get_signed_8
31393 +
31394 +
31395 +/* Extracted from bfdio.c. */
31396 +long bfd_get_mtime (bfd *abfd);
31397 +
31398 +file_ptr bfd_get_size (bfd *abfd);
31399 +
31400 +/* Extracted from bfdwin.c. */
31401 +/* Extracted from section.c. */
31402 +typedef struct bfd_section
31403 +{
31404 + /* The name of the section; the name isn't a copy, the pointer is
31405 + the same as that passed to bfd_make_section. */
31406 + const char *name;
31407 +
31408 + /* A unique sequence number. */
31409 + int id;
31410 +
31411 + /* Which section in the bfd; 0..n-1 as sections are created in a bfd. */
31412 + int index;
31413 +
31414 + /* The next section in the list belonging to the BFD, or NULL. */
31415 + struct bfd_section *next;
31416 +
31417 + /* The previous section in the list belonging to the BFD, or NULL. */
31418 + struct bfd_section *prev;
31419 +
31420 + /* The field flags contains attributes of the section. Some
31421 + flags are read in from the object file, and some are
31422 + synthesized from other information. */
31423 + flagword flags;
31424 +
31425 +#define SEC_NO_FLAGS 0x000
31426 +
31427 + /* Tells the OS to allocate space for this section when loading.
31428 + This is clear for a section containing debug information only. */
31429 +#define SEC_ALLOC 0x001
31430 +
31431 + /* Tells the OS to load the section from the file when loading.
31432 + This is clear for a .bss section. */
31433 +#define SEC_LOAD 0x002
31434 +
31435 + /* The section contains data still to be relocated, so there is
31436 + some relocation information too. */
31437 +#define SEC_RELOC 0x004
31438 +
31439 + /* A signal to the OS that the section contains read only data. */
31440 +#define SEC_READONLY 0x008
31441 +
31442 + /* The section contains code only. */
31443 +#define SEC_CODE 0x010
31444 +
31445 + /* The section contains data only. */
31446 +#define SEC_DATA 0x020
31447 +
31448 + /* The section will reside in ROM. */
31449 +#define SEC_ROM 0x040
31450 +
31451 + /* The section contains constructor information. This section
31452 + type is used by the linker to create lists of constructors and
31453 + destructors used by <<g++>>. When a back end sees a symbol
31454 + which should be used in a constructor list, it creates a new
31455 + section for the type of name (e.g., <<__CTOR_LIST__>>), attaches
31456 + the symbol to it, and builds a relocation. To build the lists
31457 + of constructors, all the linker has to do is catenate all the
31458 + sections called <<__CTOR_LIST__>> and relocate the data
31459 + contained within - exactly the operations it would peform on
31460 + standard data. */
31461 +#define SEC_CONSTRUCTOR 0x080
31462 +
31463 + /* The section has contents - a data section could be
31464 + <<SEC_ALLOC>> | <<SEC_HAS_CONTENTS>>; a debug section could be
31465 + <<SEC_HAS_CONTENTS>> */
31466 +#define SEC_HAS_CONTENTS 0x100
31467 +
31468 + /* An instruction to the linker to not output the section
31469 + even if it has information which would normally be written. */
31470 +#define SEC_NEVER_LOAD 0x200
31471 +
31472 + /* The section contains thread local data. */
31473 +#define SEC_THREAD_LOCAL 0x400
31474 +
31475 + /* The section has GOT references. This flag is only for the
31476 + linker, and is currently only used by the elf32-hppa back end.
31477 + It will be set if global offset table references were detected
31478 + in this section, which indicate to the linker that the section
31479 + contains PIC code, and must be handled specially when doing a
31480 + static link. */
31481 +#define SEC_HAS_GOT_REF 0x800
31482 +
31483 + /* The section contains common symbols (symbols may be defined
31484 + multiple times, the value of a symbol is the amount of
31485 + space it requires, and the largest symbol value is the one
31486 + used). Most targets have exactly one of these (which we
31487 + translate to bfd_com_section_ptr), but ECOFF has two. */
31488 +#define SEC_IS_COMMON 0x1000
31489 +
31490 + /* The section contains only debugging information. For
31491 + example, this is set for ELF .debug and .stab sections.
31492 + strip tests this flag to see if a section can be
31493 + discarded. */
31494 +#define SEC_DEBUGGING 0x2000
31495 +
31496 + /* The contents of this section are held in memory pointed to
31497 + by the contents field. This is checked by bfd_get_section_contents,
31498 + and the data is retrieved from memory if appropriate. */
31499 +#define SEC_IN_MEMORY 0x4000
31500 +
31501 + /* The contents of this section are to be excluded by the
31502 + linker for executable and shared objects unless those
31503 + objects are to be further relocated. */
31504 +#define SEC_EXCLUDE 0x8000
31505 +
31506 + /* The contents of this section are to be sorted based on the sum of
31507 + the symbol and addend values specified by the associated relocation
31508 + entries. Entries without associated relocation entries will be
31509 + appended to the end of the section in an unspecified order. */
31510 +#define SEC_SORT_ENTRIES 0x10000
31511 +
31512 + /* When linking, duplicate sections of the same name should be
31513 + discarded, rather than being combined into a single section as
31514 + is usually done. This is similar to how common symbols are
31515 + handled. See SEC_LINK_DUPLICATES below. */
31516 +#define SEC_LINK_ONCE 0x20000
31517 +
31518 + /* If SEC_LINK_ONCE is set, this bitfield describes how the linker
31519 + should handle duplicate sections. */
31520 +#define SEC_LINK_DUPLICATES 0x40000
31521 +
31522 + /* This value for SEC_LINK_DUPLICATES means that duplicate
31523 + sections with the same name should simply be discarded. */
31524 +#define SEC_LINK_DUPLICATES_DISCARD 0x0
31525 +
31526 + /* This value for SEC_LINK_DUPLICATES means that the linker
31527 + should warn if there are any duplicate sections, although
31528 + it should still only link one copy. */
31529 +#define SEC_LINK_DUPLICATES_ONE_ONLY 0x80000
31530 +
31531 + /* This value for SEC_LINK_DUPLICATES means that the linker
31532 + should warn if any duplicate sections are a different size. */
31533 +#define SEC_LINK_DUPLICATES_SAME_SIZE 0x100000
31534 +
31535 + /* This value for SEC_LINK_DUPLICATES means that the linker
31536 + should warn if any duplicate sections contain different
31537 + contents. */
31538 +#define SEC_LINK_DUPLICATES_SAME_CONTENTS \
31539 + (SEC_LINK_DUPLICATES_ONE_ONLY | SEC_LINK_DUPLICATES_SAME_SIZE)
31540 +
31541 + /* This section was created by the linker as part of dynamic
31542 + relocation or other arcane processing. It is skipped when
31543 + going through the first-pass output, trusting that someone
31544 + else up the line will take care of it later. */
31545 +#define SEC_LINKER_CREATED 0x200000
31546 +
31547 + /* This section should not be subject to garbage collection.
31548 + Also set to inform the linker that this section should not be
31549 + listed in the link map as discarded. */
31550 +#define SEC_KEEP 0x400000
31551 +
31552 + /* This section contains "short" data, and should be placed
31553 + "near" the GP. */
31554 +#define SEC_SMALL_DATA 0x800000
31555 +
31556 + /* Attempt to merge identical entities in the section.
31557 + Entity size is given in the entsize field. */
31558 +#define SEC_MERGE 0x1000000
31559 +
31560 + /* If given with SEC_MERGE, entities to merge are zero terminated
31561 + strings where entsize specifies character size instead of fixed
31562 + size entries. */
31563 +#define SEC_STRINGS 0x2000000
31564 +
31565 + /* This section contains data about section groups. */
31566 +#define SEC_GROUP 0x4000000
31567 +
31568 + /* The section is a COFF shared library section. This flag is
31569 + only for the linker. If this type of section appears in
31570 + the input file, the linker must copy it to the output file
31571 + without changing the vma or size. FIXME: Although this
31572 + was originally intended to be general, it really is COFF
31573 + specific (and the flag was renamed to indicate this). It
31574 + might be cleaner to have some more general mechanism to
31575 + allow the back end to control what the linker does with
31576 + sections. */
31577 +#define SEC_COFF_SHARED_LIBRARY 0x10000000
31578 +
31579 + /* This section contains data which may be shared with other
31580 + executables or shared objects. This is for COFF only. */
31581 +#define SEC_COFF_SHARED 0x20000000
31582 +
31583 + /* When a section with this flag is being linked, then if the size of
31584 + the input section is less than a page, it should not cross a page
31585 + boundary. If the size of the input section is one page or more,
31586 + it should be aligned on a page boundary. This is for TI
31587 + TMS320C54X only. */
31588 +#define SEC_TIC54X_BLOCK 0x40000000
31589 +
31590 + /* Conditionally link this section; do not link if there are no
31591 + references found to any symbol in the section. This is for TI
31592 + TMS320C54X only. */
31593 +#define SEC_TIC54X_CLINK 0x80000000
31594 +
31595 + /* End of section flags. */
31596 +
31597 + /* Some internal packed boolean fields. */
31598 +
31599 + /* See the vma field. */
31600 + unsigned int user_set_vma : 1;
31601 +
31602 + /* A mark flag used by some of the linker backends. */
31603 + unsigned int linker_mark : 1;
31604 +
31605 + /* Another mark flag used by some of the linker backends. Set for
31606 + output sections that have an input section. */
31607 + unsigned int linker_has_input : 1;
31608 +
31609 + /* Mark flags used by some linker backends for garbage collection. */
31610 + unsigned int gc_mark : 1;
31611 + unsigned int gc_mark_from_eh : 1;
31612 +
31613 + /* The following flags are used by the ELF linker. */
31614 +
31615 + /* Mark sections which have been allocated to segments. */
31616 + unsigned int segment_mark : 1;
31617 +
31618 + /* Type of sec_info information. */
31619 + unsigned int sec_info_type:3;
31620 +#define ELF_INFO_TYPE_NONE 0
31621 +#define ELF_INFO_TYPE_STABS 1
31622 +#define ELF_INFO_TYPE_MERGE 2
31623 +#define ELF_INFO_TYPE_EH_FRAME 3
31624 +#define ELF_INFO_TYPE_JUST_SYMS 4
31625 +
31626 + /* Nonzero if this section uses RELA relocations, rather than REL. */
31627 + unsigned int use_rela_p:1;
31628 +
31629 + /* Bits used by various backends. The generic code doesn't touch
31630 + these fields. */
31631 +
31632 + /* Nonzero if this section has TLS related relocations. */
31633 + unsigned int has_tls_reloc:1;
31634 +
31635 + /* Nonzero if this section has a gp reloc. */
31636 + unsigned int has_gp_reloc:1;
31637 +
31638 + /* Nonzero if this section needs the relax finalize pass. */
31639 + unsigned int need_finalize_relax:1;
31640 +
31641 + /* Whether relocations have been processed. */
31642 + unsigned int reloc_done : 1;
31643 +
31644 + /* End of internal packed boolean fields. */
31645 +
31646 + /* The virtual memory address of the section - where it will be
31647 + at run time. The symbols are relocated against this. The
31648 + user_set_vma flag is maintained by bfd; if it's not set, the
31649 + backend can assign addresses (for example, in <<a.out>>, where
31650 + the default address for <<.data>> is dependent on the specific
31651 + target and various flags). */
31652 + bfd_vma vma;
31653 +
31654 + /* The load address of the section - where it would be in a
31655 + rom image; really only used for writing section header
31656 + information. */
31657 + bfd_vma lma;
31658 +
31659 + /* The size of the section in octets, as it will be output.
31660 + Contains a value even if the section has no contents (e.g., the
31661 + size of <<.bss>>). */
31662 + bfd_size_type size;
31663 +
31664 + /* For input sections, the original size on disk of the section, in
31665 + octets. This field is used by the linker relaxation code. It is
31666 + currently only set for sections where the linker relaxation scheme
31667 + doesn't cache altered section and reloc contents (stabs, eh_frame,
31668 + SEC_MERGE, some coff relaxing targets), and thus the original size
31669 + needs to be kept to read the section multiple times.
31670 + For output sections, rawsize holds the section size calculated on
31671 + a previous linker relaxation pass. */
31672 + bfd_size_type rawsize;
31673 +
31674 + /* If this section is going to be output, then this value is the
31675 + offset in *bytes* into the output section of the first byte in the
31676 + input section (byte ==> smallest addressable unit on the
31677 + target). In most cases, if this was going to start at the
31678 + 100th octet (8-bit quantity) in the output section, this value
31679 + would be 100. However, if the target byte size is 16 bits
31680 + (bfd_octets_per_byte is "2"), this value would be 50. */
31681 + bfd_vma output_offset;
31682 +
31683 + /* The output section through which to map on output. */
31684 + struct bfd_section *output_section;
31685 +
31686 + /* The alignment requirement of the section, as an exponent of 2 -
31687 + e.g., 3 aligns to 2^3 (or 8). */
31688 + unsigned int alignment_power;
31689 +
31690 + /* If an input section, a pointer to a vector of relocation
31691 + records for the data in this section. */
31692 + struct reloc_cache_entry *relocation;
31693 +
31694 + /* If an output section, a pointer to a vector of pointers to
31695 + relocation records for the data in this section. */
31696 + struct reloc_cache_entry **orelocation;
31697 +
31698 + /* The number of relocation records in one of the above. */
31699 + unsigned reloc_count;
31700 +
31701 + /* Information below is back end specific - and not always used
31702 + or updated. */
31703 +
31704 + /* File position of section data. */
31705 + file_ptr filepos;
31706 +
31707 + /* File position of relocation info. */
31708 + file_ptr rel_filepos;
31709 +
31710 + /* File position of line data. */
31711 + file_ptr line_filepos;
31712 +
31713 + /* Pointer to data for applications. */
31714 + void *userdata;
31715 +
31716 + /* If the SEC_IN_MEMORY flag is set, this points to the actual
31717 + contents. */
31718 + unsigned char *contents;
31719 +
31720 + /* Attached line number information. */
31721 + alent *lineno;
31722 +
31723 + /* Number of line number records. */
31724 + unsigned int lineno_count;
31725 +
31726 + /* Entity size for merging purposes. */
31727 + unsigned int entsize;
31728 +
31729 + /* Points to the kept section if this section is a link-once section,
31730 + and is discarded. */
31731 + struct bfd_section *kept_section;
31732 +
31733 + /* When a section is being output, this value changes as more
31734 + linenumbers are written out. */
31735 + file_ptr moving_line_filepos;
31736 +
31737 + /* What the section number is in the target world. */
31738 + int target_index;
31739 +
31740 + void *used_by_bfd;
31741 +
31742 + /* If this is a constructor section then here is a list of the
31743 + relocations created to relocate items within it. */
31744 + struct relent_chain *constructor_chain;
31745 +
31746 + /* The BFD which owns the section. */
31747 + bfd *owner;
31748 +
31749 + /* A symbol which points at this section only. */
31750 + struct bfd_symbol *symbol;
31751 + struct bfd_symbol **symbol_ptr_ptr;
31752 +
31753 + /* Early in the link process, map_head and map_tail are used to build
31754 + a list of input sections attached to an output section. Later,
31755 + output sections use these fields for a list of bfd_link_order
31756 + structs. */
31757 + union {
31758 + struct bfd_link_order *link_order;
31759 + struct bfd_section *s;
31760 + } map_head, map_tail;
31761 +} asection;
31762 +
31763 +/* These sections are global, and are managed by BFD. The application
31764 + and target back end are not permitted to change the values in
31765 + these sections. New code should use the section_ptr macros rather
31766 + than referring directly to the const sections. The const sections
31767 + may eventually vanish. */
31768 +#define BFD_ABS_SECTION_NAME "*ABS*"
31769 +#define BFD_UND_SECTION_NAME "*UND*"
31770 +#define BFD_COM_SECTION_NAME "*COM*"
31771 +#define BFD_IND_SECTION_NAME "*IND*"
31772 +
31773 +/* The absolute section. */
31774 +extern asection bfd_abs_section;
31775 +#define bfd_abs_section_ptr ((asection *) &bfd_abs_section)
31776 +#define bfd_is_abs_section(sec) ((sec) == bfd_abs_section_ptr)
31777 +/* Pointer to the undefined section. */
31778 +extern asection bfd_und_section;
31779 +#define bfd_und_section_ptr ((asection *) &bfd_und_section)
31780 +#define bfd_is_und_section(sec) ((sec) == bfd_und_section_ptr)
31781 +/* Pointer to the common section. */
31782 +extern asection bfd_com_section;
31783 +#define bfd_com_section_ptr ((asection *) &bfd_com_section)
31784 +/* Pointer to the indirect section. */
31785 +extern asection bfd_ind_section;
31786 +#define bfd_ind_section_ptr ((asection *) &bfd_ind_section)
31787 +#define bfd_is_ind_section(sec) ((sec) == bfd_ind_section_ptr)
31788 +
31789 +#define bfd_is_const_section(SEC) \
31790 + ( ((SEC) == bfd_abs_section_ptr) \
31791 + || ((SEC) == bfd_und_section_ptr) \
31792 + || ((SEC) == bfd_com_section_ptr) \
31793 + || ((SEC) == bfd_ind_section_ptr))
31794 +
31795 +/* Macros to handle insertion and deletion of a bfd's sections. These
31796 + only handle the list pointers, ie. do not adjust section_count,
31797 + target_index etc. */
31798 +#define bfd_section_list_remove(ABFD, S) \
31799 + do \
31800 + { \
31801 + asection *_s = S; \
31802 + asection *_next = _s->next; \
31803 + asection *_prev = _s->prev; \
31804 + if (_prev) \
31805 + _prev->next = _next; \
31806 + else \
31807 + (ABFD)->sections = _next; \
31808 + if (_next) \
31809 + _next->prev = _prev; \
31810 + else \
31811 + (ABFD)->section_last = _prev; \
31812 + } \
31813 + while (0)
31814 +#define bfd_section_list_append(ABFD, S) \
31815 + do \
31816 + { \
31817 + asection *_s = S; \
31818 + bfd *_abfd = ABFD; \
31819 + _s->next = NULL; \
31820 + if (_abfd->section_last) \
31821 + { \
31822 + _s->prev = _abfd->section_last; \
31823 + _abfd->section_last->next = _s; \
31824 + } \
31825 + else \
31826 + { \
31827 + _s->prev = NULL; \
31828 + _abfd->sections = _s; \
31829 + } \
31830 + _abfd->section_last = _s; \
31831 + } \
31832 + while (0)
31833 +#define bfd_section_list_prepend(ABFD, S) \
31834 + do \
31835 + { \
31836 + asection *_s = S; \
31837 + bfd *_abfd = ABFD; \
31838 + _s->prev = NULL; \
31839 + if (_abfd->sections) \
31840 + { \
31841 + _s->next = _abfd->sections; \
31842 + _abfd->sections->prev = _s; \
31843 + } \
31844 + else \
31845 + { \
31846 + _s->next = NULL; \
31847 + _abfd->section_last = _s; \
31848 + } \
31849 + _abfd->sections = _s; \
31850 + } \
31851 + while (0)
31852 +#define bfd_section_list_insert_after(ABFD, A, S) \
31853 + do \
31854 + { \
31855 + asection *_a = A; \
31856 + asection *_s = S; \
31857 + asection *_next = _a->next; \
31858 + _s->next = _next; \
31859 + _s->prev = _a; \
31860 + _a->next = _s; \
31861 + if (_next) \
31862 + _next->prev = _s; \
31863 + else \
31864 + (ABFD)->section_last = _s; \
31865 + } \
31866 + while (0)
31867 +#define bfd_section_list_insert_before(ABFD, B, S) \
31868 + do \
31869 + { \
31870 + asection *_b = B; \
31871 + asection *_s = S; \
31872 + asection *_prev = _b->prev; \
31873 + _s->prev = _prev; \
31874 + _s->next = _b; \
31875 + _b->prev = _s; \
31876 + if (_prev) \
31877 + _prev->next = _s; \
31878 + else \
31879 + (ABFD)->sections = _s; \
31880 + } \
31881 + while (0)
31882 +#define bfd_section_removed_from_list(ABFD, S) \
31883 + ((S)->next == NULL ? (ABFD)->section_last != (S) : (S)->next->prev != (S))
31884 +
31885 +#define BFD_FAKE_SECTION(SEC, FLAGS, SYM, NAME, IDX) \
31886 + /* name, id, index, next, prev, flags, user_set_vma, */ \
31887 + { NAME, IDX, 0, NULL, NULL, FLAGS, 0, \
31888 + \
31889 + /* linker_mark, linker_has_input, gc_mark, gc_mark_from_eh, */ \
31890 + 0, 0, 1, 0, \
31891 + \
31892 + /* segment_mark, sec_info_type, use_rela_p, has_tls_reloc, */ \
31893 + 0, 0, 0, 0, \
31894 + \
31895 + /* has_gp_reloc, need_finalize_relax, reloc_done, */ \
31896 + 0, 0, 0, \
31897 + \
31898 + /* vma, lma, size, rawsize */ \
31899 + 0, 0, 0, 0, \
31900 + \
31901 + /* output_offset, output_section, alignment_power, */ \
31902 + 0, (struct bfd_section *) &SEC, 0, \
31903 + \
31904 + /* relocation, orelocation, reloc_count, filepos, rel_filepos, */ \
31905 + NULL, NULL, 0, 0, 0, \
31906 + \
31907 + /* line_filepos, userdata, contents, lineno, lineno_count, */ \
31908 + 0, NULL, NULL, NULL, 0, \
31909 + \
31910 + /* entsize, kept_section, moving_line_filepos, */ \
31911 + 0, NULL, 0, \
31912 + \
31913 + /* target_index, used_by_bfd, constructor_chain, owner, */ \
31914 + 0, NULL, NULL, NULL, \
31915 + \
31916 + /* symbol, symbol_ptr_ptr, */ \
31917 + (struct bfd_symbol *) SYM, &SEC.symbol, \
31918 + \
31919 + /* map_head, map_tail */ \
31920 + { NULL }, { NULL } \
31921 + }
31922 +
31923 +void bfd_section_list_clear (bfd *);
31924 +
31925 +asection *bfd_get_section_by_name (bfd *abfd, const char *name);
31926 +
31927 +asection *bfd_get_section_by_name_if
31928 + (bfd *abfd,
31929 + const char *name,
31930 + bfd_boolean (*func) (bfd *abfd, asection *sect, void *obj),
31931 + void *obj);
31932 +
31933 +char *bfd_get_unique_section_name
31934 + (bfd *abfd, const char *templat, int *count);
31935 +
31936 +asection *bfd_make_section_old_way (bfd *abfd, const char *name);
31937 +
31938 +asection *bfd_make_section_anyway_with_flags
31939 + (bfd *abfd, const char *name, flagword flags);
31940 +
31941 +asection *bfd_make_section_anyway (bfd *abfd, const char *name);
31942 +
31943 +asection *bfd_make_section_with_flags
31944 + (bfd *, const char *name, flagword flags);
31945 +
31946 +asection *bfd_make_section (bfd *, const char *name);
31947 +
31948 +bfd_boolean bfd_set_section_flags
31949 + (bfd *abfd, asection *sec, flagword flags);
31950 +
31951 +void bfd_map_over_sections
31952 + (bfd *abfd,
31953 + void (*func) (bfd *abfd, asection *sect, void *obj),
31954 + void *obj);
31955 +
31956 +asection *bfd_sections_find_if
31957 + (bfd *abfd,
31958 + bfd_boolean (*operation) (bfd *abfd, asection *sect, void *obj),
31959 + void *obj);
31960 +
31961 +bfd_boolean bfd_set_section_size
31962 + (bfd *abfd, asection *sec, bfd_size_type val);
31963 +
31964 +bfd_boolean bfd_set_section_contents
31965 + (bfd *abfd, asection *section, const void *data,
31966 + file_ptr offset, bfd_size_type count);
31967 +
31968 +bfd_boolean bfd_get_section_contents
31969 + (bfd *abfd, asection *section, void *location, file_ptr offset,
31970 + bfd_size_type count);
31971 +
31972 +bfd_boolean bfd_malloc_and_get_section
31973 + (bfd *abfd, asection *section, bfd_byte **buf);
31974 +
31975 +bfd_boolean bfd_copy_private_section_data
31976 + (bfd *ibfd, asection *isec, bfd *obfd, asection *osec);
31977 +
31978 +#define bfd_copy_private_section_data(ibfd, isection, obfd, osection) \
31979 + BFD_SEND (obfd, _bfd_copy_private_section_data, \
31980 + (ibfd, isection, obfd, osection))
31981 +bfd_boolean bfd_generic_is_group_section (bfd *, const asection *sec);
31982 +
31983 +bfd_boolean bfd_generic_discard_group (bfd *abfd, asection *group);
31984 +
31985 +/* Extracted from archures.c. */
31986 +enum bfd_architecture
31987 +{
31988 + bfd_arch_unknown, /* File arch not known. */
31989 + bfd_arch_obscure, /* Arch known, not one of these. */
31990 + bfd_arch_m68k, /* Motorola 68xxx */
31991 +#define bfd_mach_m68000 1
31992 +#define bfd_mach_m68008 2
31993 +#define bfd_mach_m68010 3
31994 +#define bfd_mach_m68020 4
31995 +#define bfd_mach_m68030 5
31996 +#define bfd_mach_m68040 6
31997 +#define bfd_mach_m68060 7
31998 +#define bfd_mach_cpu32 8
31999 +#define bfd_mach_fido 9
32000 +#define bfd_mach_mcf_isa_a_nodiv 10
32001 +#define bfd_mach_mcf_isa_a 11
32002 +#define bfd_mach_mcf_isa_a_mac 12
32003 +#define bfd_mach_mcf_isa_a_emac 13
32004 +#define bfd_mach_mcf_isa_aplus 14
32005 +#define bfd_mach_mcf_isa_aplus_mac 15
32006 +#define bfd_mach_mcf_isa_aplus_emac 16
32007 +#define bfd_mach_mcf_isa_b_nousp 17
32008 +#define bfd_mach_mcf_isa_b_nousp_mac 18
32009 +#define bfd_mach_mcf_isa_b_nousp_emac 19
32010 +#define bfd_mach_mcf_isa_b 20
32011 +#define bfd_mach_mcf_isa_b_mac 21
32012 +#define bfd_mach_mcf_isa_b_emac 22
32013 +#define bfd_mach_mcf_isa_b_float 23
32014 +#define bfd_mach_mcf_isa_b_float_mac 24
32015 +#define bfd_mach_mcf_isa_b_float_emac 25
32016 +#define bfd_mach_mcf_isa_c 26
32017 +#define bfd_mach_mcf_isa_c_mac 27
32018 +#define bfd_mach_mcf_isa_c_emac 28
32019 + bfd_arch_vax, /* DEC Vax */
32020 + bfd_arch_i960, /* Intel 960 */
32021 + /* The order of the following is important.
32022 + lower number indicates a machine type that
32023 + only accepts a subset of the instructions
32024 + available to machines with higher numbers.
32025 + The exception is the "ca", which is
32026 + incompatible with all other machines except
32027 + "core". */
32028 +
32029 +#define bfd_mach_i960_core 1
32030 +#define bfd_mach_i960_ka_sa 2
32031 +#define bfd_mach_i960_kb_sb 3
32032 +#define bfd_mach_i960_mc 4
32033 +#define bfd_mach_i960_xa 5
32034 +#define bfd_mach_i960_ca 6
32035 +#define bfd_mach_i960_jx 7
32036 +#define bfd_mach_i960_hx 8
32037 +
32038 + bfd_arch_or32, /* OpenRISC 32 */
32039 +
32040 + bfd_arch_sparc, /* SPARC */
32041 +#define bfd_mach_sparc 1
32042 +/* The difference between v8plus and v9 is that v9 is a true 64 bit env. */
32043 +#define bfd_mach_sparc_sparclet 2
32044 +#define bfd_mach_sparc_sparclite 3
32045 +#define bfd_mach_sparc_v8plus 4
32046 +#define bfd_mach_sparc_v8plusa 5 /* with ultrasparc add'ns. */
32047 +#define bfd_mach_sparc_sparclite_le 6
32048 +#define bfd_mach_sparc_v9 7
32049 +#define bfd_mach_sparc_v9a 8 /* with ultrasparc add'ns. */
32050 +#define bfd_mach_sparc_v8plusb 9 /* with cheetah add'ns. */
32051 +#define bfd_mach_sparc_v9b 10 /* with cheetah add'ns. */
32052 +/* Nonzero if MACH has the v9 instruction set. */
32053 +#define bfd_mach_sparc_v9_p(mach) \
32054 + ((mach) >= bfd_mach_sparc_v8plus && (mach) <= bfd_mach_sparc_v9b \
32055 + && (mach) != bfd_mach_sparc_sparclite_le)
32056 +/* Nonzero if MACH is a 64 bit sparc architecture. */
32057 +#define bfd_mach_sparc_64bit_p(mach) \
32058 + ((mach) >= bfd_mach_sparc_v9 && (mach) != bfd_mach_sparc_v8plusb)
32059 + bfd_arch_spu, /* PowerPC SPU */
32060 +#define bfd_mach_spu 256
32061 + bfd_arch_mips, /* MIPS Rxxxx */
32062 +#define bfd_mach_mips3000 3000
32063 +#define bfd_mach_mips3900 3900
32064 +#define bfd_mach_mips4000 4000
32065 +#define bfd_mach_mips4010 4010
32066 +#define bfd_mach_mips4100 4100
32067 +#define bfd_mach_mips4111 4111
32068 +#define bfd_mach_mips4120 4120
32069 +#define bfd_mach_mips4300 4300
32070 +#define bfd_mach_mips4400 4400
32071 +#define bfd_mach_mips4600 4600
32072 +#define bfd_mach_mips4650 4650
32073 +#define bfd_mach_mips5000 5000
32074 +#define bfd_mach_mips5400 5400
32075 +#define bfd_mach_mips5500 5500
32076 +#define bfd_mach_mips6000 6000
32077 +#define bfd_mach_mips7000 7000
32078 +#define bfd_mach_mips8000 8000
32079 +#define bfd_mach_mips9000 9000
32080 +#define bfd_mach_mips10000 10000
32081 +#define bfd_mach_mips12000 12000
32082 +#define bfd_mach_mips16 16
32083 +#define bfd_mach_mips5 5
32084 +#define bfd_mach_mips_sb1 12310201 /* octal 'SB', 01 */
32085 +#define bfd_mach_mipsisa32 32
32086 +#define bfd_mach_mipsisa32r2 33
32087 +#define bfd_mach_mipsisa64 64
32088 +#define bfd_mach_mipsisa64r2 65
32089 + bfd_arch_i386, /* Intel 386 */
32090 +#define bfd_mach_i386_i386 1
32091 +#define bfd_mach_i386_i8086 2
32092 +#define bfd_mach_i386_i386_intel_syntax 3
32093 +#define bfd_mach_x86_64 64
32094 +#define bfd_mach_x86_64_intel_syntax 65
32095 + bfd_arch_we32k, /* AT&T WE32xxx */
32096 + bfd_arch_tahoe, /* CCI/Harris Tahoe */
32097 + bfd_arch_i860, /* Intel 860 */
32098 + bfd_arch_i370, /* IBM 360/370 Mainframes */
32099 + bfd_arch_romp, /* IBM ROMP PC/RT */
32100 + bfd_arch_convex, /* Convex */
32101 + bfd_arch_m88k, /* Motorola 88xxx */
32102 + bfd_arch_m98k, /* Motorola 98xxx */
32103 + bfd_arch_pyramid, /* Pyramid Technology */
32104 + bfd_arch_h8300, /* Renesas H8/300 (formerly Hitachi H8/300) */
32105 +#define bfd_mach_h8300 1
32106 +#define bfd_mach_h8300h 2
32107 +#define bfd_mach_h8300s 3
32108 +#define bfd_mach_h8300hn 4
32109 +#define bfd_mach_h8300sn 5
32110 +#define bfd_mach_h8300sx 6
32111 +#define bfd_mach_h8300sxn 7
32112 + bfd_arch_pdp11, /* DEC PDP-11 */
32113 + bfd_arch_powerpc, /* PowerPC */
32114 +#define bfd_mach_ppc 32
32115 +#define bfd_mach_ppc64 64
32116 +#define bfd_mach_ppc_403 403
32117 +#define bfd_mach_ppc_403gc 4030
32118 +#define bfd_mach_ppc_505 505
32119 +#define bfd_mach_ppc_601 601
32120 +#define bfd_mach_ppc_602 602
32121 +#define bfd_mach_ppc_603 603
32122 +#define bfd_mach_ppc_ec603e 6031
32123 +#define bfd_mach_ppc_604 604
32124 +#define bfd_mach_ppc_620 620
32125 +#define bfd_mach_ppc_630 630
32126 +#define bfd_mach_ppc_750 750
32127 +#define bfd_mach_ppc_860 860
32128 +#define bfd_mach_ppc_a35 35
32129 +#define bfd_mach_ppc_rs64ii 642
32130 +#define bfd_mach_ppc_rs64iii 643
32131 +#define bfd_mach_ppc_7400 7400
32132 +#define bfd_mach_ppc_e500 500
32133 + bfd_arch_rs6000, /* IBM RS/6000 */
32134 +#define bfd_mach_rs6k 6000
32135 +#define bfd_mach_rs6k_rs1 6001
32136 +#define bfd_mach_rs6k_rsc 6003
32137 +#define bfd_mach_rs6k_rs2 6002
32138 + bfd_arch_hppa, /* HP PA RISC */
32139 +#define bfd_mach_hppa10 10
32140 +#define bfd_mach_hppa11 11
32141 +#define bfd_mach_hppa20 20
32142 +#define bfd_mach_hppa20w 25
32143 + bfd_arch_d10v, /* Mitsubishi D10V */
32144 +#define bfd_mach_d10v 1
32145 +#define bfd_mach_d10v_ts2 2
32146 +#define bfd_mach_d10v_ts3 3
32147 + bfd_arch_d30v, /* Mitsubishi D30V */
32148 + bfd_arch_dlx, /* DLX */
32149 + bfd_arch_m68hc11, /* Motorola 68HC11 */
32150 + bfd_arch_m68hc12, /* Motorola 68HC12 */
32151 +#define bfd_mach_m6812_default 0
32152 +#define bfd_mach_m6812 1
32153 +#define bfd_mach_m6812s 2
32154 + bfd_arch_z8k, /* Zilog Z8000 */
32155 +#define bfd_mach_z8001 1
32156 +#define bfd_mach_z8002 2
32157 + bfd_arch_h8500, /* Renesas H8/500 (formerly Hitachi H8/500) */
32158 + bfd_arch_sh, /* Renesas / SuperH SH (formerly Hitachi SH) */
32159 +#define bfd_mach_sh 1
32160 +#define bfd_mach_sh2 0x20
32161 +#define bfd_mach_sh_dsp 0x2d
32162 +#define bfd_mach_sh2a 0x2a
32163 +#define bfd_mach_sh2a_nofpu 0x2b
32164 +#define bfd_mach_sh2a_nofpu_or_sh4_nommu_nofpu 0x2a1
32165 +#define bfd_mach_sh2a_nofpu_or_sh3_nommu 0x2a2
32166 +#define bfd_mach_sh2a_or_sh4 0x2a3
32167 +#define bfd_mach_sh2a_or_sh3e 0x2a4
32168 +#define bfd_mach_sh2e 0x2e
32169 +#define bfd_mach_sh3 0x30
32170 +#define bfd_mach_sh3_nommu 0x31
32171 +#define bfd_mach_sh3_dsp 0x3d
32172 +#define bfd_mach_sh3e 0x3e
32173 +#define bfd_mach_sh4 0x40
32174 +#define bfd_mach_sh4_nofpu 0x41
32175 +#define bfd_mach_sh4_nommu_nofpu 0x42
32176 +#define bfd_mach_sh4a 0x4a
32177 +#define bfd_mach_sh4a_nofpu 0x4b
32178 +#define bfd_mach_sh4al_dsp 0x4d
32179 +#define bfd_mach_sh5 0x50
32180 + bfd_arch_alpha, /* Dec Alpha */
32181 +#define bfd_mach_alpha_ev4 0x10
32182 +#define bfd_mach_alpha_ev5 0x20
32183 +#define bfd_mach_alpha_ev6 0x30
32184 + bfd_arch_arm, /* Advanced Risc Machines ARM. */
32185 +#define bfd_mach_arm_unknown 0
32186 +#define bfd_mach_arm_2 1
32187 +#define bfd_mach_arm_2a 2
32188 +#define bfd_mach_arm_3 3
32189 +#define bfd_mach_arm_3M 4
32190 +#define bfd_mach_arm_4 5
32191 +#define bfd_mach_arm_4T 6
32192 +#define bfd_mach_arm_5 7
32193 +#define bfd_mach_arm_5T 8
32194 +#define bfd_mach_arm_5TE 9
32195 +#define bfd_mach_arm_XScale 10
32196 +#define bfd_mach_arm_ep9312 11
32197 +#define bfd_mach_arm_iWMMXt 12
32198 +#define bfd_mach_arm_iWMMXt2 13
32199 + bfd_arch_ns32k, /* National Semiconductors ns32000 */
32200 + bfd_arch_w65, /* WDC 65816 */
32201 + bfd_arch_tic30, /* Texas Instruments TMS320C30 */
32202 + bfd_arch_tic4x, /* Texas Instruments TMS320C3X/4X */
32203 +#define bfd_mach_tic3x 30
32204 +#define bfd_mach_tic4x 40
32205 + bfd_arch_tic54x, /* Texas Instruments TMS320C54X */
32206 + bfd_arch_tic80, /* TI TMS320c80 (MVP) */
32207 + bfd_arch_v850, /* NEC V850 */
32208 +#define bfd_mach_v850 1
32209 +#define bfd_mach_v850e 'E'
32210 +#define bfd_mach_v850e1 '1'
32211 + bfd_arch_arc, /* ARC Cores */
32212 +#define bfd_mach_arc_5 5
32213 +#define bfd_mach_arc_6 6
32214 +#define bfd_mach_arc_7 7
32215 +#define bfd_mach_arc_8 8
32216 + bfd_arch_m32c, /* Renesas M16C/M32C. */
32217 +#define bfd_mach_m16c 0x75
32218 +#define bfd_mach_m32c 0x78
32219 + bfd_arch_m32r, /* Renesas M32R (formerly Mitsubishi M32R/D) */
32220 +#define bfd_mach_m32r 1 /* For backwards compatibility. */
32221 +#define bfd_mach_m32rx 'x'
32222 +#define bfd_mach_m32r2 '2'
32223 + bfd_arch_mn10200, /* Matsushita MN10200 */
32224 + bfd_arch_mn10300, /* Matsushita MN10300 */
32225 +#define bfd_mach_mn10300 300
32226 +#define bfd_mach_am33 330
32227 +#define bfd_mach_am33_2 332
32228 + bfd_arch_fr30,
32229 +#define bfd_mach_fr30 0x46523330
32230 + bfd_arch_frv,
32231 +#define bfd_mach_frv 1
32232 +#define bfd_mach_frvsimple 2
32233 +#define bfd_mach_fr300 300
32234 +#define bfd_mach_fr400 400
32235 +#define bfd_mach_fr450 450
32236 +#define bfd_mach_frvtomcat 499 /* fr500 prototype */
32237 +#define bfd_mach_fr500 500
32238 +#define bfd_mach_fr550 550
32239 + bfd_arch_mcore,
32240 + bfd_arch_mep,
32241 +#define bfd_mach_mep 1
32242 +#define bfd_mach_mep_h1 0x6831
32243 + bfd_arch_ia64, /* HP/Intel ia64 */
32244 +#define bfd_mach_ia64_elf64 64
32245 +#define bfd_mach_ia64_elf32 32
32246 + bfd_arch_ip2k, /* Ubicom IP2K microcontrollers. */
32247 +#define bfd_mach_ip2022 1
32248 +#define bfd_mach_ip2022ext 2
32249 + bfd_arch_iq2000, /* Vitesse IQ2000. */
32250 +#define bfd_mach_iq2000 1
32251 +#define bfd_mach_iq10 2
32252 + bfd_arch_mt,
32253 +#define bfd_mach_ms1 1
32254 +#define bfd_mach_mrisc2 2
32255 +#define bfd_mach_ms2 3
32256 + bfd_arch_pj,
32257 + bfd_arch_avr, /* Atmel AVR microcontrollers. */
32258 +#define bfd_mach_avr1 1
32259 +#define bfd_mach_avr2 2
32260 +#define bfd_mach_avr3 3
32261 +#define bfd_mach_avr4 4
32262 +#define bfd_mach_avr5 5
32263 +#define bfd_mach_avr6 6
32264 + bfd_arch_bfin, /* ADI Blackfin */
32265 +#define bfd_mach_bfin 1
32266 + bfd_arch_cr16, /* National Semiconductor CompactRISC (ie CR16). */
32267 +#define bfd_mach_cr16 1
32268 + bfd_arch_cr16c, /* National Semiconductor CompactRISC. */
32269 +#define bfd_mach_cr16c 1
32270 + bfd_arch_crx, /* National Semiconductor CRX. */
32271 +#define bfd_mach_crx 1
32272 + bfd_arch_cris, /* Axis CRIS */
32273 +#define bfd_mach_cris_v0_v10 255
32274 +#define bfd_mach_cris_v32 32
32275 +#define bfd_mach_cris_v10_v32 1032
32276 + bfd_arch_s390, /* IBM s390 */
32277 +#define bfd_mach_s390_31 31
32278 +#define bfd_mach_s390_64 64
32279 + bfd_arch_score, /* Sunplus score */
32280 + bfd_arch_openrisc, /* OpenRISC */
32281 + bfd_arch_mmix, /* Donald Knuth's educational processor. */
32282 + bfd_arch_xstormy16,
32283 +#define bfd_mach_xstormy16 1
32284 + bfd_arch_msp430, /* Texas Instruments MSP430 architecture. */
32285 +#define bfd_mach_msp11 11
32286 +#define bfd_mach_msp110 110
32287 +#define bfd_mach_msp12 12
32288 +#define bfd_mach_msp13 13
32289 +#define bfd_mach_msp14 14
32290 +#define bfd_mach_msp15 15
32291 +#define bfd_mach_msp16 16
32292 +#define bfd_mach_msp21 21
32293 +#define bfd_mach_msp31 31
32294 +#define bfd_mach_msp32 32
32295 +#define bfd_mach_msp33 33
32296 +#define bfd_mach_msp41 41
32297 +#define bfd_mach_msp42 42
32298 +#define bfd_mach_msp43 43
32299 +#define bfd_mach_msp44 44
32300 + bfd_arch_xc16x, /* Infineon's XC16X Series. */
32301 +#define bfd_mach_xc16x 1
32302 +#define bfd_mach_xc16xl 2
32303 +#define bfd_mach_xc16xs 3
32304 + bfd_arch_xtensa, /* Tensilica's Xtensa cores. */
32305 +#define bfd_mach_xtensa 1
32306 + bfd_arch_maxq, /* Dallas MAXQ 10/20 */
32307 +#define bfd_mach_maxq10 10
32308 +#define bfd_mach_maxq20 20
32309 + bfd_arch_z80,
32310 +#define bfd_mach_z80strict 1 /* No undocumented opcodes. */
32311 +#define bfd_mach_z80 3 /* With ixl, ixh, iyl, and iyh. */
32312 +#define bfd_mach_z80full 7 /* All undocumented instructions. */
32313 +#define bfd_mach_r800 11 /* R800: successor with multiplication. */
32314 + bfd_arch_last
32315 + };
32316 +
32317 +typedef struct bfd_arch_info
32318 +{
32319 + int bits_per_word;
32320 + int bits_per_address;
32321 + int bits_per_byte;
32322 + enum bfd_architecture arch;
32323 + unsigned long mach;
32324 + const char *arch_name;
32325 + const char *printable_name;
32326 + unsigned int section_align_power;
32327 + /* TRUE if this is the default machine for the architecture.
32328 + The default arch should be the first entry for an arch so that
32329 + all the entries for that arch can be accessed via <<next>>. */
32330 + bfd_boolean the_default;
32331 + const struct bfd_arch_info * (*compatible)
32332 + (const struct bfd_arch_info *a, const struct bfd_arch_info *b);
32333 +
32334 + bfd_boolean (*scan) (const struct bfd_arch_info *, const char *);
32335 +
32336 + const struct bfd_arch_info *next;
32337 +}
32338 +bfd_arch_info_type;
32339 +
32340 +const char *bfd_printable_name (bfd *abfd);
32341 +
32342 +const bfd_arch_info_type *bfd_scan_arch (const char *string);
32343 +
32344 +const char **bfd_arch_list (void);
32345 +
32346 +const bfd_arch_info_type *bfd_arch_get_compatible
32347 + (const bfd *abfd, const bfd *bbfd, bfd_boolean accept_unknowns);
32348 +
32349 +void bfd_set_arch_info (bfd *abfd, const bfd_arch_info_type *arg);
32350 +
32351 +enum bfd_architecture bfd_get_arch (bfd *abfd);
32352 +
32353 +unsigned long bfd_get_mach (bfd *abfd);
32354 +
32355 +unsigned int bfd_arch_bits_per_byte (bfd *abfd);
32356 +
32357 +unsigned int bfd_arch_bits_per_address (bfd *abfd);
32358 +
32359 +const bfd_arch_info_type *bfd_get_arch_info (bfd *abfd);
32360 +
32361 +const bfd_arch_info_type *bfd_lookup_arch
32362 + (enum bfd_architecture arch, unsigned long machine);
32363 +
32364 +const char *bfd_printable_arch_mach
32365 + (enum bfd_architecture arch, unsigned long machine);
32366 +
32367 +unsigned int bfd_octets_per_byte (bfd *abfd);
32368 +
32369 +unsigned int bfd_arch_mach_octets_per_byte
32370 + (enum bfd_architecture arch, unsigned long machine);
32371 +
32372 +/* Extracted from reloc.c. */
32373 +typedef enum bfd_reloc_status
32374 +{
32375 + /* No errors detected. */
32376 + bfd_reloc_ok,
32377 +
32378 + /* The relocation was performed, but there was an overflow. */
32379 + bfd_reloc_overflow,
32380 +
32381 + /* The address to relocate was not within the section supplied. */
32382 + bfd_reloc_outofrange,
32383 +
32384 + /* Used by special functions. */
32385 + bfd_reloc_continue,
32386 +
32387 + /* Unsupported relocation size requested. */
32388 + bfd_reloc_notsupported,
32389 +
32390 + /* Unused. */
32391 + bfd_reloc_other,
32392 +
32393 + /* The symbol to relocate against was undefined. */
32394 + bfd_reloc_undefined,
32395 +
32396 + /* The relocation was performed, but may not be ok - presently
32397 + generated only when linking i960 coff files with i960 b.out
32398 + symbols. If this type is returned, the error_message argument
32399 + to bfd_perform_relocation will be set. */
32400 + bfd_reloc_dangerous
32401 + }
32402 + bfd_reloc_status_type;
32403 +
32404 +
32405 +typedef struct reloc_cache_entry
32406 +{
32407 + /* A pointer into the canonical table of pointers. */
32408 + struct bfd_symbol **sym_ptr_ptr;
32409 +
32410 + /* offset in section. */
32411 + bfd_size_type address;
32412 +
32413 + /* addend for relocation value. */
32414 + bfd_vma addend;
32415 +
32416 + /* Pointer to how to perform the required relocation. */
32417 + reloc_howto_type *howto;
32418 +
32419 +}
32420 +arelent;
32421 +
32422 +enum complain_overflow
32423 +{
32424 + /* Do not complain on overflow. */
32425 + complain_overflow_dont,
32426 +
32427 + /* Complain if the value overflows when considered as a signed
32428 + number one bit larger than the field. ie. A bitfield of N bits
32429 + is allowed to represent -2**n to 2**n-1. */
32430 + complain_overflow_bitfield,
32431 +
32432 + /* Complain if the value overflows when considered as a signed
32433 + number. */
32434 + complain_overflow_signed,
32435 +
32436 + /* Complain if the value overflows when considered as an
32437 + unsigned number. */
32438 + complain_overflow_unsigned
32439 +};
32440 +
32441 +struct reloc_howto_struct
32442 +{
32443 + /* The type field has mainly a documentary use - the back end can
32444 + do what it wants with it, though normally the back end's
32445 + external idea of what a reloc number is stored
32446 + in this field. For example, a PC relative word relocation
32447 + in a coff environment has the type 023 - because that's
32448 + what the outside world calls a R_PCRWORD reloc. */
32449 + unsigned int type;
32450 +
32451 + /* The value the final relocation is shifted right by. This drops
32452 + unwanted data from the relocation. */
32453 + unsigned int rightshift;
32454 +
32455 + /* The size of the item to be relocated. This is *not* a
32456 + power-of-two measure. To get the number of bytes operated
32457 + on by a type of relocation, use bfd_get_reloc_size. */
32458 + int size;
32459 +
32460 + /* The number of bits in the item to be relocated. This is used
32461 + when doing overflow checking. */
32462 + unsigned int bitsize;
32463 +
32464 + /* Notes that the relocation is relative to the location in the
32465 + data section of the addend. The relocation function will
32466 + subtract from the relocation value the address of the location
32467 + being relocated. */
32468 + bfd_boolean pc_relative;
32469 +
32470 + /* The bit position of the reloc value in the destination.
32471 + The relocated value is left shifted by this amount. */
32472 + unsigned int bitpos;
32473 +
32474 + /* What type of overflow error should be checked for when
32475 + relocating. */
32476 + enum complain_overflow complain_on_overflow;
32477 +
32478 + /* If this field is non null, then the supplied function is
32479 + called rather than the normal function. This allows really
32480 + strange relocation methods to be accommodated (e.g., i960 callj
32481 + instructions). */
32482 + bfd_reloc_status_type (*special_function)
32483 + (bfd *, arelent *, struct bfd_symbol *, void *, asection *,
32484 + bfd *, char **);
32485 +
32486 + /* The textual name of the relocation type. */
32487 + char *name;
32488 +
32489 + /* Some formats record a relocation addend in the section contents
32490 + rather than with the relocation. For ELF formats this is the
32491 + distinction between USE_REL and USE_RELA (though the code checks
32492 + for USE_REL == 1/0). The value of this field is TRUE if the
32493 + addend is recorded with the section contents; when performing a
32494 + partial link (ld -r) the section contents (the data) will be
32495 + modified. The value of this field is FALSE if addends are
32496 + recorded with the relocation (in arelent.addend); when performing
32497 + a partial link the relocation will be modified.
32498 + All relocations for all ELF USE_RELA targets should set this field
32499 + to FALSE (values of TRUE should be looked on with suspicion).
32500 + However, the converse is not true: not all relocations of all ELF
32501 + USE_REL targets set this field to TRUE. Why this is so is peculiar
32502 + to each particular target. For relocs that aren't used in partial
32503 + links (e.g. GOT stuff) it doesn't matter what this is set to. */
32504 + bfd_boolean partial_inplace;
32505 +
32506 + /* src_mask selects the part of the instruction (or data) to be used
32507 + in the relocation sum. If the target relocations don't have an
32508 + addend in the reloc, eg. ELF USE_REL, src_mask will normally equal
32509 + dst_mask to extract the addend from the section contents. If
32510 + relocations do have an addend in the reloc, eg. ELF USE_RELA, this
32511 + field should be zero. Non-zero values for ELF USE_RELA targets are
32512 + bogus as in those cases the value in the dst_mask part of the
32513 + section contents should be treated as garbage. */
32514 + bfd_vma src_mask;
32515 +
32516 + /* dst_mask selects which parts of the instruction (or data) are
32517 + replaced with a relocated value. */
32518 + bfd_vma dst_mask;
32519 +
32520 + /* When some formats create PC relative instructions, they leave
32521 + the value of the pc of the place being relocated in the offset
32522 + slot of the instruction, so that a PC relative relocation can
32523 + be made just by adding in an ordinary offset (e.g., sun3 a.out).
32524 + Some formats leave the displacement part of an instruction
32525 + empty (e.g., m88k bcs); this flag signals the fact. */
32526 + bfd_boolean pcrel_offset;
32527 +};
32528 +
32529 +#define HOWTO(C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC) \
32530 + { (unsigned) C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC }
32531 +#define NEWHOWTO(FUNCTION, NAME, SIZE, REL, IN) \
32532 + HOWTO (0, 0, SIZE, 0, REL, 0, complain_overflow_dont, FUNCTION, \
32533 + NAME, FALSE, 0, 0, IN)
32534 +
32535 +#define EMPTY_HOWTO(C) \
32536 + HOWTO ((C), 0, 0, 0, FALSE, 0, complain_overflow_dont, NULL, \
32537 + NULL, FALSE, 0, 0, FALSE)
32538 +
32539 +#define HOWTO_PREPARE(relocation, symbol) \
32540 + { \
32541 + if (symbol != NULL) \
32542 + { \
32543 + if (bfd_is_com_section (symbol->section)) \
32544 + { \
32545 + relocation = 0; \
32546 + } \
32547 + else \
32548 + { \
32549 + relocation = symbol->value; \
32550 + } \
32551 + } \
32552 + }
32553 +
32554 +unsigned int bfd_get_reloc_size (reloc_howto_type *);
32555 +
32556 +typedef struct relent_chain
32557 +{
32558 + arelent relent;
32559 + struct relent_chain *next;
32560 +}
32561 +arelent_chain;
32562 +
32563 +bfd_reloc_status_type bfd_check_overflow
32564 + (enum complain_overflow how,
32565 + unsigned int bitsize,
32566 + unsigned int rightshift,
32567 + unsigned int addrsize,
32568 + bfd_vma relocation);
32569 +
32570 +bfd_reloc_status_type bfd_perform_relocation
32571 + (bfd *abfd,
32572 + arelent *reloc_entry,
32573 + void *data,
32574 + asection *input_section,
32575 + bfd *output_bfd,
32576 + char **error_message);
32577 +
32578 +bfd_reloc_status_type bfd_install_relocation
32579 + (bfd *abfd,
32580 + arelent *reloc_entry,
32581 + void *data, bfd_vma data_start,
32582 + asection *input_section,
32583 + char **error_message);
32584 +
32585 +enum bfd_reloc_code_real {
32586 + _dummy_first_bfd_reloc_code_real,
32587 +
32588 +
32589 +/* Basic absolute relocations of N bits. */
32590 + BFD_RELOC_64,
32591 + BFD_RELOC_32,
32592 + BFD_RELOC_26,
32593 + BFD_RELOC_24,
32594 + BFD_RELOC_16,
32595 + BFD_RELOC_14,
32596 + BFD_RELOC_8,
32597 +
32598 +/* PC-relative relocations. Sometimes these are relative to the address
32599 +of the relocation itself; sometimes they are relative to the start of
32600 +the section containing the relocation. It depends on the specific target.
32601 +
32602 +The 24-bit relocation is used in some Intel 960 configurations. */
32603 + BFD_RELOC_64_PCREL,
32604 + BFD_RELOC_32_PCREL,
32605 + BFD_RELOC_24_PCREL,
32606 + BFD_RELOC_16_PCREL,
32607 + BFD_RELOC_12_PCREL,
32608 + BFD_RELOC_8_PCREL,
32609 +
32610 +/* Section relative relocations. Some targets need this for DWARF2. */
32611 + BFD_RELOC_32_SECREL,
32612 +
32613 +/* For ELF. */
32614 + BFD_RELOC_32_GOT_PCREL,
32615 + BFD_RELOC_16_GOT_PCREL,
32616 + BFD_RELOC_8_GOT_PCREL,
32617 + BFD_RELOC_32_GOTOFF,
32618 + BFD_RELOC_16_GOTOFF,
32619 + BFD_RELOC_LO16_GOTOFF,
32620 + BFD_RELOC_HI16_GOTOFF,
32621 + BFD_RELOC_HI16_S_GOTOFF,
32622 + BFD_RELOC_8_GOTOFF,
32623 + BFD_RELOC_64_PLT_PCREL,
32624 + BFD_RELOC_32_PLT_PCREL,
32625 + BFD_RELOC_24_PLT_PCREL,
32626 + BFD_RELOC_16_PLT_PCREL,
32627 + BFD_RELOC_8_PLT_PCREL,
32628 + BFD_RELOC_64_PLTOFF,
32629 + BFD_RELOC_32_PLTOFF,
32630 + BFD_RELOC_16_PLTOFF,
32631 + BFD_RELOC_LO16_PLTOFF,
32632 + BFD_RELOC_HI16_PLTOFF,
32633 + BFD_RELOC_HI16_S_PLTOFF,
32634 + BFD_RELOC_8_PLTOFF,
32635 +
32636 +/* Relocations used by 68K ELF. */
32637 + BFD_RELOC_68K_GLOB_DAT,
32638 + BFD_RELOC_68K_JMP_SLOT,
32639 + BFD_RELOC_68K_RELATIVE,
32640 +
32641 +/* Linkage-table relative. */
32642 + BFD_RELOC_32_BASEREL,
32643 + BFD_RELOC_16_BASEREL,
32644 + BFD_RELOC_LO16_BASEREL,
32645 + BFD_RELOC_HI16_BASEREL,
32646 + BFD_RELOC_HI16_S_BASEREL,
32647 + BFD_RELOC_8_BASEREL,
32648 + BFD_RELOC_RVA,
32649 +
32650 +/* Absolute 8-bit relocation, but used to form an address like 0xFFnn. */
32651 + BFD_RELOC_8_FFnn,
32652 +
32653 +/* These PC-relative relocations are stored as word displacements --
32654 +i.e., byte displacements shifted right two bits. The 30-bit word
32655 +displacement (<<32_PCREL_S2>> -- 32 bits, shifted 2) is used on the
32656 +SPARC. (SPARC tools generally refer to this as <<WDISP30>>.) The
32657 +signed 16-bit displacement is used on the MIPS, and the 23-bit
32658 +displacement is used on the Alpha. */
32659 + BFD_RELOC_32_PCREL_S2,
32660 + BFD_RELOC_16_PCREL_S2,
32661 + BFD_RELOC_23_PCREL_S2,
32662 +
32663 +/* High 22 bits and low 10 bits of 32-bit value, placed into lower bits of
32664 +the target word. These are used on the SPARC. */
32665 + BFD_RELOC_HI22,
32666 + BFD_RELOC_LO10,
32667 +
32668 +/* For systems that allocate a Global Pointer register, these are
32669 +displacements off that register. These relocation types are
32670 +handled specially, because the value the register will have is
32671 +decided relatively late. */
32672 + BFD_RELOC_GPREL16,
32673 + BFD_RELOC_GPREL32,
32674 +
32675 +/* Reloc types used for i960/b.out. */
32676 + BFD_RELOC_I960_CALLJ,
32677 +
32678 +/* SPARC ELF relocations. There is probably some overlap with other
32679 +relocation types already defined. */
32680 + BFD_RELOC_NONE,
32681 + BFD_RELOC_SPARC_WDISP22,
32682 + BFD_RELOC_SPARC22,
32683 + BFD_RELOC_SPARC13,
32684 + BFD_RELOC_SPARC_GOT10,
32685 + BFD_RELOC_SPARC_GOT13,
32686 + BFD_RELOC_SPARC_GOT22,
32687 + BFD_RELOC_SPARC_PC10,
32688 + BFD_RELOC_SPARC_PC22,
32689 + BFD_RELOC_SPARC_WPLT30,
32690 + BFD_RELOC_SPARC_COPY,
32691 + BFD_RELOC_SPARC_GLOB_DAT,
32692 + BFD_RELOC_SPARC_JMP_SLOT,
32693 + BFD_RELOC_SPARC_RELATIVE,
32694 + BFD_RELOC_SPARC_UA16,
32695 + BFD_RELOC_SPARC_UA32,
32696 + BFD_RELOC_SPARC_UA64,
32697 +
32698 +/* I think these are specific to SPARC a.out (e.g., Sun 4). */
32699 + BFD_RELOC_SPARC_BASE13,
32700 + BFD_RELOC_SPARC_BASE22,
32701 +
32702 +/* SPARC64 relocations */
32703 +#define BFD_RELOC_SPARC_64 BFD_RELOC_64
32704 + BFD_RELOC_SPARC_10,
32705 + BFD_RELOC_SPARC_11,
32706 + BFD_RELOC_SPARC_OLO10,
32707 + BFD_RELOC_SPARC_HH22,
32708 + BFD_RELOC_SPARC_HM10,
32709 + BFD_RELOC_SPARC_LM22,
32710 + BFD_RELOC_SPARC_PC_HH22,
32711 + BFD_RELOC_SPARC_PC_HM10,
32712 + BFD_RELOC_SPARC_PC_LM22,
32713 + BFD_RELOC_SPARC_WDISP16,
32714 + BFD_RELOC_SPARC_WDISP19,
32715 + BFD_RELOC_SPARC_7,
32716 + BFD_RELOC_SPARC_6,
32717 + BFD_RELOC_SPARC_5,
32718 +#define BFD_RELOC_SPARC_DISP64 BFD_RELOC_64_PCREL
32719 + BFD_RELOC_SPARC_PLT32,
32720 + BFD_RELOC_SPARC_PLT64,
32721 + BFD_RELOC_SPARC_HIX22,
32722 + BFD_RELOC_SPARC_LOX10,
32723 + BFD_RELOC_SPARC_H44,
32724 + BFD_RELOC_SPARC_M44,
32725 + BFD_RELOC_SPARC_L44,
32726 + BFD_RELOC_SPARC_REGISTER,
32727 +
32728 +/* SPARC little endian relocation */
32729 + BFD_RELOC_SPARC_REV32,
32730 +
32731 +/* SPARC TLS relocations */
32732 + BFD_RELOC_SPARC_TLS_GD_HI22,
32733 + BFD_RELOC_SPARC_TLS_GD_LO10,
32734 + BFD_RELOC_SPARC_TLS_GD_ADD,
32735 + BFD_RELOC_SPARC_TLS_GD_CALL,
32736 + BFD_RELOC_SPARC_TLS_LDM_HI22,
32737 + BFD_RELOC_SPARC_TLS_LDM_LO10,
32738 + BFD_RELOC_SPARC_TLS_LDM_ADD,
32739 + BFD_RELOC_SPARC_TLS_LDM_CALL,
32740 + BFD_RELOC_SPARC_TLS_LDO_HIX22,
32741 + BFD_RELOC_SPARC_TLS_LDO_LOX10,
32742 + BFD_RELOC_SPARC_TLS_LDO_ADD,
32743 + BFD_RELOC_SPARC_TLS_IE_HI22,
32744 + BFD_RELOC_SPARC_TLS_IE_LO10,
32745 + BFD_RELOC_SPARC_TLS_IE_LD,
32746 + BFD_RELOC_SPARC_TLS_IE_LDX,
32747 + BFD_RELOC_SPARC_TLS_IE_ADD,
32748 + BFD_RELOC_SPARC_TLS_LE_HIX22,
32749 + BFD_RELOC_SPARC_TLS_LE_LOX10,
32750 + BFD_RELOC_SPARC_TLS_DTPMOD32,
32751 + BFD_RELOC_SPARC_TLS_DTPMOD64,
32752 + BFD_RELOC_SPARC_TLS_DTPOFF32,
32753 + BFD_RELOC_SPARC_TLS_DTPOFF64,
32754 + BFD_RELOC_SPARC_TLS_TPOFF32,
32755 + BFD_RELOC_SPARC_TLS_TPOFF64,
32756 +
32757 +/* SPU Relocations. */
32758 + BFD_RELOC_SPU_IMM7,
32759 + BFD_RELOC_SPU_IMM8,
32760 + BFD_RELOC_SPU_IMM10,
32761 + BFD_RELOC_SPU_IMM10W,
32762 + BFD_RELOC_SPU_IMM16,
32763 + BFD_RELOC_SPU_IMM16W,
32764 + BFD_RELOC_SPU_IMM18,
32765 + BFD_RELOC_SPU_PCREL9a,
32766 + BFD_RELOC_SPU_PCREL9b,
32767 + BFD_RELOC_SPU_PCREL16,
32768 + BFD_RELOC_SPU_LO16,
32769 + BFD_RELOC_SPU_HI16,
32770 + BFD_RELOC_SPU_PPU32,
32771 + BFD_RELOC_SPU_PPU64,
32772 +
32773 +/* Alpha ECOFF and ELF relocations. Some of these treat the symbol or
32774 +"addend" in some special way.
32775 +For GPDISP_HI16 ("gpdisp") relocations, the symbol is ignored when
32776 +writing; when reading, it will be the absolute section symbol. The
32777 +addend is the displacement in bytes of the "lda" instruction from
32778 +the "ldah" instruction (which is at the address of this reloc). */
32779 + BFD_RELOC_ALPHA_GPDISP_HI16,
32780 +
32781 +/* For GPDISP_LO16 ("ignore") relocations, the symbol is handled as
32782 +with GPDISP_HI16 relocs. The addend is ignored when writing the
32783 +relocations out, and is filled in with the file's GP value on
32784 +reading, for convenience. */
32785 + BFD_RELOC_ALPHA_GPDISP_LO16,
32786 +
32787 +/* The ELF GPDISP relocation is exactly the same as the GPDISP_HI16
32788 +relocation except that there is no accompanying GPDISP_LO16
32789 +relocation. */
32790 + BFD_RELOC_ALPHA_GPDISP,
32791 +
32792 +/* The Alpha LITERAL/LITUSE relocs are produced by a symbol reference;
32793 +the assembler turns it into a LDQ instruction to load the address of
32794 +the symbol, and then fills in a register in the real instruction.
32795 +
32796 +The LITERAL reloc, at the LDQ instruction, refers to the .lita
32797 +section symbol. The addend is ignored when writing, but is filled
32798 +in with the file's GP value on reading, for convenience, as with the
32799 +GPDISP_LO16 reloc.
32800 +
32801 +The ELF_LITERAL reloc is somewhere between 16_GOTOFF and GPDISP_LO16.
32802 +It should refer to the symbol to be referenced, as with 16_GOTOFF,
32803 +but it generates output not based on the position within the .got
32804 +section, but relative to the GP value chosen for the file during the
32805 +final link stage.
32806 +
32807 +The LITUSE reloc, on the instruction using the loaded address, gives
32808 +information to the linker that it might be able to use to optimize
32809 +away some literal section references. The symbol is ignored (read
32810 +as the absolute section symbol), and the "addend" indicates the type
32811 +of instruction using the register:
32812 +1 - "memory" fmt insn
32813 +2 - byte-manipulation (byte offset reg)
32814 +3 - jsr (target of branch) */
32815 + BFD_RELOC_ALPHA_LITERAL,
32816 + BFD_RELOC_ALPHA_ELF_LITERAL,
32817 + BFD_RELOC_ALPHA_LITUSE,
32818 +
32819 +/* The HINT relocation indicates a value that should be filled into the
32820 +"hint" field of a jmp/jsr/ret instruction, for possible branch-
32821 +prediction logic which may be provided on some processors. */
32822 + BFD_RELOC_ALPHA_HINT,
32823 +
32824 +/* The LINKAGE relocation outputs a linkage pair in the object file,
32825 +which is filled by the linker. */
32826 + BFD_RELOC_ALPHA_LINKAGE,
32827 +
32828 +/* The CODEADDR relocation outputs a STO_CA in the object file,
32829 +which is filled by the linker. */
32830 + BFD_RELOC_ALPHA_CODEADDR,
32831 +
32832 +/* The GPREL_HI/LO relocations together form a 32-bit offset from the
32833 +GP register. */
32834 + BFD_RELOC_ALPHA_GPREL_HI16,
32835 + BFD_RELOC_ALPHA_GPREL_LO16,
32836 +
32837 +/* Like BFD_RELOC_23_PCREL_S2, except that the source and target must
32838 +share a common GP, and the target address is adjusted for
32839 +STO_ALPHA_STD_GPLOAD. */
32840 + BFD_RELOC_ALPHA_BRSGP,
32841 +
32842 +/* Alpha thread-local storage relocations. */
32843 + BFD_RELOC_ALPHA_TLSGD,
32844 + BFD_RELOC_ALPHA_TLSLDM,
32845 + BFD_RELOC_ALPHA_DTPMOD64,
32846 + BFD_RELOC_ALPHA_GOTDTPREL16,
32847 + BFD_RELOC_ALPHA_DTPREL64,
32848 + BFD_RELOC_ALPHA_DTPREL_HI16,
32849 + BFD_RELOC_ALPHA_DTPREL_LO16,
32850 + BFD_RELOC_ALPHA_DTPREL16,
32851 + BFD_RELOC_ALPHA_GOTTPREL16,
32852 + BFD_RELOC_ALPHA_TPREL64,
32853 + BFD_RELOC_ALPHA_TPREL_HI16,
32854 + BFD_RELOC_ALPHA_TPREL_LO16,
32855 + BFD_RELOC_ALPHA_TPREL16,
32856 +
32857 +/* Bits 27..2 of the relocation address shifted right 2 bits;
32858 +simple reloc otherwise. */
32859 + BFD_RELOC_MIPS_JMP,
32860 +
32861 +/* The MIPS16 jump instruction. */
32862 + BFD_RELOC_MIPS16_JMP,
32863 +
32864 +/* MIPS16 GP relative reloc. */
32865 + BFD_RELOC_MIPS16_GPREL,
32866 +
32867 +/* High 16 bits of 32-bit value; simple reloc. */
32868 + BFD_RELOC_HI16,
32869 +
32870 +/* High 16 bits of 32-bit value but the low 16 bits will be sign
32871 +extended and added to form the final result. If the low 16
32872 +bits form a negative number, we need to add one to the high value
32873 +to compensate for the borrow when the low bits are added. */
32874 + BFD_RELOC_HI16_S,
32875 +
32876 +/* Low 16 bits. */
32877 + BFD_RELOC_LO16,
32878 +
32879 +/* High 16 bits of 32-bit pc-relative value */
32880 + BFD_RELOC_HI16_PCREL,
32881 +
32882 +/* High 16 bits of 32-bit pc-relative value, adjusted */
32883 + BFD_RELOC_HI16_S_PCREL,
32884 +
32885 +/* Low 16 bits of pc-relative value */
32886 + BFD_RELOC_LO16_PCREL,
32887 +
32888 +/* MIPS16 high 16 bits of 32-bit value. */
32889 + BFD_RELOC_MIPS16_HI16,
32890 +
32891 +/* MIPS16 high 16 bits of 32-bit value but the low 16 bits will be sign
32892 +extended and added to form the final result. If the low 16
32893 +bits form a negative number, we need to add one to the high value
32894 +to compensate for the borrow when the low bits are added. */
32895 + BFD_RELOC_MIPS16_HI16_S,
32896 +
32897 +/* MIPS16 low 16 bits. */
32898 + BFD_RELOC_MIPS16_LO16,
32899 +
32900 +/* Relocation against a MIPS literal section. */
32901 + BFD_RELOC_MIPS_LITERAL,
32902 +
32903 +/* MIPS ELF relocations. */
32904 + BFD_RELOC_MIPS_GOT16,
32905 + BFD_RELOC_MIPS_CALL16,
32906 + BFD_RELOC_MIPS_GOT_HI16,
32907 + BFD_RELOC_MIPS_GOT_LO16,
32908 + BFD_RELOC_MIPS_CALL_HI16,
32909 + BFD_RELOC_MIPS_CALL_LO16,
32910 + BFD_RELOC_MIPS_SUB,
32911 + BFD_RELOC_MIPS_GOT_PAGE,
32912 + BFD_RELOC_MIPS_GOT_OFST,
32913 + BFD_RELOC_MIPS_GOT_DISP,
32914 + BFD_RELOC_MIPS_SHIFT5,
32915 + BFD_RELOC_MIPS_SHIFT6,
32916 + BFD_RELOC_MIPS_INSERT_A,
32917 + BFD_RELOC_MIPS_INSERT_B,
32918 + BFD_RELOC_MIPS_DELETE,
32919 + BFD_RELOC_MIPS_HIGHEST,
32920 + BFD_RELOC_MIPS_HIGHER,
32921 + BFD_RELOC_MIPS_SCN_DISP,
32922 + BFD_RELOC_MIPS_REL16,
32923 + BFD_RELOC_MIPS_RELGOT,
32924 + BFD_RELOC_MIPS_JALR,
32925 + BFD_RELOC_MIPS_TLS_DTPMOD32,
32926 + BFD_RELOC_MIPS_TLS_DTPREL32,
32927 + BFD_RELOC_MIPS_TLS_DTPMOD64,
32928 + BFD_RELOC_MIPS_TLS_DTPREL64,
32929 + BFD_RELOC_MIPS_TLS_GD,
32930 + BFD_RELOC_MIPS_TLS_LDM,
32931 + BFD_RELOC_MIPS_TLS_DTPREL_HI16,
32932 + BFD_RELOC_MIPS_TLS_DTPREL_LO16,
32933 + BFD_RELOC_MIPS_TLS_GOTTPREL,
32934 + BFD_RELOC_MIPS_TLS_TPREL32,
32935 + BFD_RELOC_MIPS_TLS_TPREL64,
32936 + BFD_RELOC_MIPS_TLS_TPREL_HI16,
32937 + BFD_RELOC_MIPS_TLS_TPREL_LO16,
32938 +
32939 +
32940 +/* MIPS ELF relocations (VxWorks extensions). */
32941 + BFD_RELOC_MIPS_COPY,
32942 + BFD_RELOC_MIPS_JUMP_SLOT,
32943 +
32944 +
32945 +/* Fujitsu Frv Relocations. */
32946 + BFD_RELOC_FRV_LABEL16,
32947 + BFD_RELOC_FRV_LABEL24,
32948 + BFD_RELOC_FRV_LO16,
32949 + BFD_RELOC_FRV_HI16,
32950 + BFD_RELOC_FRV_GPREL12,
32951 + BFD_RELOC_FRV_GPRELU12,
32952 + BFD_RELOC_FRV_GPREL32,
32953 + BFD_RELOC_FRV_GPRELHI,
32954 + BFD_RELOC_FRV_GPRELLO,
32955 + BFD_RELOC_FRV_GOT12,
32956 + BFD_RELOC_FRV_GOTHI,
32957 + BFD_RELOC_FRV_GOTLO,
32958 + BFD_RELOC_FRV_FUNCDESC,
32959 + BFD_RELOC_FRV_FUNCDESC_GOT12,
32960 + BFD_RELOC_FRV_FUNCDESC_GOTHI,
32961 + BFD_RELOC_FRV_FUNCDESC_GOTLO,
32962 + BFD_RELOC_FRV_FUNCDESC_VALUE,
32963 + BFD_RELOC_FRV_FUNCDESC_GOTOFF12,
32964 + BFD_RELOC_FRV_FUNCDESC_GOTOFFHI,
32965 + BFD_RELOC_FRV_FUNCDESC_GOTOFFLO,
32966 + BFD_RELOC_FRV_GOTOFF12,
32967 + BFD_RELOC_FRV_GOTOFFHI,
32968 + BFD_RELOC_FRV_GOTOFFLO,
32969 + BFD_RELOC_FRV_GETTLSOFF,
32970 + BFD_RELOC_FRV_TLSDESC_VALUE,
32971 + BFD_RELOC_FRV_GOTTLSDESC12,
32972 + BFD_RELOC_FRV_GOTTLSDESCHI,
32973 + BFD_RELOC_FRV_GOTTLSDESCLO,
32974 + BFD_RELOC_FRV_TLSMOFF12,
32975 + BFD_RELOC_FRV_TLSMOFFHI,
32976 + BFD_RELOC_FRV_TLSMOFFLO,
32977 + BFD_RELOC_FRV_GOTTLSOFF12,
32978 + BFD_RELOC_FRV_GOTTLSOFFHI,
32979 + BFD_RELOC_FRV_GOTTLSOFFLO,
32980 + BFD_RELOC_FRV_TLSOFF,
32981 + BFD_RELOC_FRV_TLSDESC_RELAX,
32982 + BFD_RELOC_FRV_GETTLSOFF_RELAX,
32983 + BFD_RELOC_FRV_TLSOFF_RELAX,
32984 + BFD_RELOC_FRV_TLSMOFF,
32985 +
32986 +
32987 +/* This is a 24bit GOT-relative reloc for the mn10300. */
32988 + BFD_RELOC_MN10300_GOTOFF24,
32989 +
32990 +/* This is a 32bit GOT-relative reloc for the mn10300, offset by two bytes
32991 +in the instruction. */
32992 + BFD_RELOC_MN10300_GOT32,
32993 +
32994 +/* This is a 24bit GOT-relative reloc for the mn10300, offset by two bytes
32995 +in the instruction. */
32996 + BFD_RELOC_MN10300_GOT24,
32997 +
32998 +/* This is a 16bit GOT-relative reloc for the mn10300, offset by two bytes
32999 +in the instruction. */
33000 + BFD_RELOC_MN10300_GOT16,
33001 +
33002 +/* Copy symbol at runtime. */
33003 + BFD_RELOC_MN10300_COPY,
33004 +
33005 +/* Create GOT entry. */
33006 + BFD_RELOC_MN10300_GLOB_DAT,
33007 +
33008 +/* Create PLT entry. */
33009 + BFD_RELOC_MN10300_JMP_SLOT,
33010 +
33011 +/* Adjust by program base. */
33012 + BFD_RELOC_MN10300_RELATIVE,
33013 +
33014 +
33015 +/* i386/elf relocations */
33016 + BFD_RELOC_386_GOT32,
33017 + BFD_RELOC_386_PLT32,
33018 + BFD_RELOC_386_COPY,
33019 + BFD_RELOC_386_GLOB_DAT,
33020 + BFD_RELOC_386_JUMP_SLOT,
33021 + BFD_RELOC_386_RELATIVE,
33022 + BFD_RELOC_386_GOTOFF,
33023 + BFD_RELOC_386_GOTPC,
33024 + BFD_RELOC_386_TLS_TPOFF,
33025 + BFD_RELOC_386_TLS_IE,
33026 + BFD_RELOC_386_TLS_GOTIE,
33027 + BFD_RELOC_386_TLS_LE,
33028 + BFD_RELOC_386_TLS_GD,
33029 + BFD_RELOC_386_TLS_LDM,
33030 + BFD_RELOC_386_TLS_LDO_32,
33031 + BFD_RELOC_386_TLS_IE_32,
33032 + BFD_RELOC_386_TLS_LE_32,
33033 + BFD_RELOC_386_TLS_DTPMOD32,
33034 + BFD_RELOC_386_TLS_DTPOFF32,
33035 + BFD_RELOC_386_TLS_TPOFF32,
33036 + BFD_RELOC_386_TLS_GOTDESC,
33037 + BFD_RELOC_386_TLS_DESC_CALL,
33038 + BFD_RELOC_386_TLS_DESC,
33039 +
33040 +/* x86-64/elf relocations */
33041 + BFD_RELOC_X86_64_GOT32,
33042 + BFD_RELOC_X86_64_PLT32,
33043 + BFD_RELOC_X86_64_COPY,
33044 + BFD_RELOC_X86_64_GLOB_DAT,
33045 + BFD_RELOC_X86_64_JUMP_SLOT,
33046 + BFD_RELOC_X86_64_RELATIVE,
33047 + BFD_RELOC_X86_64_GOTPCREL,
33048 + BFD_RELOC_X86_64_32S,
33049 + BFD_RELOC_X86_64_DTPMOD64,
33050 + BFD_RELOC_X86_64_DTPOFF64,
33051 + BFD_RELOC_X86_64_TPOFF64,
33052 + BFD_RELOC_X86_64_TLSGD,
33053 + BFD_RELOC_X86_64_TLSLD,
33054 + BFD_RELOC_X86_64_DTPOFF32,
33055 + BFD_RELOC_X86_64_GOTTPOFF,
33056 + BFD_RELOC_X86_64_TPOFF32,
33057 + BFD_RELOC_X86_64_GOTOFF64,
33058 + BFD_RELOC_X86_64_GOTPC32,
33059 + BFD_RELOC_X86_64_GOT64,
33060 + BFD_RELOC_X86_64_GOTPCREL64,
33061 + BFD_RELOC_X86_64_GOTPC64,
33062 + BFD_RELOC_X86_64_GOTPLT64,
33063 + BFD_RELOC_X86_64_PLTOFF64,
33064 + BFD_RELOC_X86_64_GOTPC32_TLSDESC,
33065 + BFD_RELOC_X86_64_TLSDESC_CALL,
33066 + BFD_RELOC_X86_64_TLSDESC,
33067 +
33068 +/* ns32k relocations */
33069 + BFD_RELOC_NS32K_IMM_8,
33070 + BFD_RELOC_NS32K_IMM_16,
33071 + BFD_RELOC_NS32K_IMM_32,
33072 + BFD_RELOC_NS32K_IMM_8_PCREL,
33073 + BFD_RELOC_NS32K_IMM_16_PCREL,
33074 + BFD_RELOC_NS32K_IMM_32_PCREL,
33075 + BFD_RELOC_NS32K_DISP_8,
33076 + BFD_RELOC_NS32K_DISP_16,
33077 + BFD_RELOC_NS32K_DISP_32,
33078 + BFD_RELOC_NS32K_DISP_8_PCREL,
33079 + BFD_RELOC_NS32K_DISP_16_PCREL,
33080 + BFD_RELOC_NS32K_DISP_32_PCREL,
33081 +
33082 +/* PDP11 relocations */
33083 + BFD_RELOC_PDP11_DISP_8_PCREL,
33084 + BFD_RELOC_PDP11_DISP_6_PCREL,
33085 +
33086 +/* Picojava relocs. Not all of these appear in object files. */
33087 + BFD_RELOC_PJ_CODE_HI16,
33088 + BFD_RELOC_PJ_CODE_LO16,
33089 + BFD_RELOC_PJ_CODE_DIR16,
33090 + BFD_RELOC_PJ_CODE_DIR32,
33091 + BFD_RELOC_PJ_CODE_REL16,
33092 + BFD_RELOC_PJ_CODE_REL32,
33093 +
33094 +/* Power(rs6000) and PowerPC relocations. */
33095 + BFD_RELOC_PPC_B26,
33096 + BFD_RELOC_PPC_BA26,
33097 + BFD_RELOC_PPC_TOC16,
33098 + BFD_RELOC_PPC_B16,
33099 + BFD_RELOC_PPC_B16_BRTAKEN,
33100 + BFD_RELOC_PPC_B16_BRNTAKEN,
33101 + BFD_RELOC_PPC_BA16,
33102 + BFD_RELOC_PPC_BA16_BRTAKEN,
33103 + BFD_RELOC_PPC_BA16_BRNTAKEN,
33104 + BFD_RELOC_PPC_COPY,
33105 + BFD_RELOC_PPC_GLOB_DAT,
33106 + BFD_RELOC_PPC_JMP_SLOT,
33107 + BFD_RELOC_PPC_RELATIVE,
33108 + BFD_RELOC_PPC_LOCAL24PC,
33109 + BFD_RELOC_PPC_EMB_NADDR32,
33110 + BFD_RELOC_PPC_EMB_NADDR16,
33111 + BFD_RELOC_PPC_EMB_NADDR16_LO,
33112 + BFD_RELOC_PPC_EMB_NADDR16_HI,
33113 + BFD_RELOC_PPC_EMB_NADDR16_HA,
33114 + BFD_RELOC_PPC_EMB_SDAI16,
33115 + BFD_RELOC_PPC_EMB_SDA2I16,
33116 + BFD_RELOC_PPC_EMB_SDA2REL,
33117 + BFD_RELOC_PPC_EMB_SDA21,
33118 + BFD_RELOC_PPC_EMB_MRKREF,
33119 + BFD_RELOC_PPC_EMB_RELSEC16,
33120 + BFD_RELOC_PPC_EMB_RELST_LO,
33121 + BFD_RELOC_PPC_EMB_RELST_HI,
33122 + BFD_RELOC_PPC_EMB_RELST_HA,
33123 + BFD_RELOC_PPC_EMB_BIT_FLD,
33124 + BFD_RELOC_PPC_EMB_RELSDA,
33125 + BFD_RELOC_PPC64_HIGHER,
33126 + BFD_RELOC_PPC64_HIGHER_S,
33127 + BFD_RELOC_PPC64_HIGHEST,
33128 + BFD_RELOC_PPC64_HIGHEST_S,
33129 + BFD_RELOC_PPC64_TOC16_LO,
33130 + BFD_RELOC_PPC64_TOC16_HI,
33131 + BFD_RELOC_PPC64_TOC16_HA,
33132 + BFD_RELOC_PPC64_TOC,
33133 + BFD_RELOC_PPC64_PLTGOT16,
33134 + BFD_RELOC_PPC64_PLTGOT16_LO,
33135 + BFD_RELOC_PPC64_PLTGOT16_HI,
33136 + BFD_RELOC_PPC64_PLTGOT16_HA,
33137 + BFD_RELOC_PPC64_ADDR16_DS,
33138 + BFD_RELOC_PPC64_ADDR16_LO_DS,
33139 + BFD_RELOC_PPC64_GOT16_DS,
33140 + BFD_RELOC_PPC64_GOT16_LO_DS,
33141 + BFD_RELOC_PPC64_PLT16_LO_DS,
33142 + BFD_RELOC_PPC64_SECTOFF_DS,
33143 + BFD_RELOC_PPC64_SECTOFF_LO_DS,
33144 + BFD_RELOC_PPC64_TOC16_DS,
33145 + BFD_RELOC_PPC64_TOC16_LO_DS,
33146 + BFD_RELOC_PPC64_PLTGOT16_DS,
33147 + BFD_RELOC_PPC64_PLTGOT16_LO_DS,
33148 +
33149 +/* PowerPC and PowerPC64 thread-local storage relocations. */
33150 + BFD_RELOC_PPC_TLS,
33151 + BFD_RELOC_PPC_DTPMOD,
33152 + BFD_RELOC_PPC_TPREL16,
33153 + BFD_RELOC_PPC_TPREL16_LO,
33154 + BFD_RELOC_PPC_TPREL16_HI,
33155 + BFD_RELOC_PPC_TPREL16_HA,
33156 + BFD_RELOC_PPC_TPREL,
33157 + BFD_RELOC_PPC_DTPREL16,
33158 + BFD_RELOC_PPC_DTPREL16_LO,
33159 + BFD_RELOC_PPC_DTPREL16_HI,
33160 + BFD_RELOC_PPC_DTPREL16_HA,
33161 + BFD_RELOC_PPC_DTPREL,
33162 + BFD_RELOC_PPC_GOT_TLSGD16,
33163 + BFD_RELOC_PPC_GOT_TLSGD16_LO,
33164 + BFD_RELOC_PPC_GOT_TLSGD16_HI,
33165 + BFD_RELOC_PPC_GOT_TLSGD16_HA,
33166 + BFD_RELOC_PPC_GOT_TLSLD16,
33167 + BFD_RELOC_PPC_GOT_TLSLD16_LO,
33168 + BFD_RELOC_PPC_GOT_TLSLD16_HI,
33169 + BFD_RELOC_PPC_GOT_TLSLD16_HA,
33170 + BFD_RELOC_PPC_GOT_TPREL16,
33171 + BFD_RELOC_PPC_GOT_TPREL16_LO,
33172 + BFD_RELOC_PPC_GOT_TPREL16_HI,
33173 + BFD_RELOC_PPC_GOT_TPREL16_HA,
33174 + BFD_RELOC_PPC_GOT_DTPREL16,
33175 + BFD_RELOC_PPC_GOT_DTPREL16_LO,
33176 + BFD_RELOC_PPC_GOT_DTPREL16_HI,
33177 + BFD_RELOC_PPC_GOT_DTPREL16_HA,
33178 + BFD_RELOC_PPC64_TPREL16_DS,
33179 + BFD_RELOC_PPC64_TPREL16_LO_DS,
33180 + BFD_RELOC_PPC64_TPREL16_HIGHER,
33181 + BFD_RELOC_PPC64_TPREL16_HIGHERA,
33182 + BFD_RELOC_PPC64_TPREL16_HIGHEST,
33183 + BFD_RELOC_PPC64_TPREL16_HIGHESTA,
33184 + BFD_RELOC_PPC64_DTPREL16_DS,
33185 + BFD_RELOC_PPC64_DTPREL16_LO_DS,
33186 + BFD_RELOC_PPC64_DTPREL16_HIGHER,
33187 + BFD_RELOC_PPC64_DTPREL16_HIGHERA,
33188 + BFD_RELOC_PPC64_DTPREL16_HIGHEST,
33189 + BFD_RELOC_PPC64_DTPREL16_HIGHESTA,
33190 +
33191 +/* IBM 370/390 relocations */
33192 + BFD_RELOC_I370_D12,
33193 +
33194 +/* The type of reloc used to build a constructor table - at the moment
33195 +probably a 32 bit wide absolute relocation, but the target can choose.
33196 +It generally does map to one of the other relocation types. */
33197 + BFD_RELOC_CTOR,
33198 +
33199 +/* ARM 26 bit pc-relative branch. The lowest two bits must be zero and are
33200 +not stored in the instruction. */
33201 + BFD_RELOC_ARM_PCREL_BRANCH,
33202 +
33203 +/* ARM 26 bit pc-relative branch. The lowest bit must be zero and is
33204 +not stored in the instruction. The 2nd lowest bit comes from a 1 bit
33205 +field in the instruction. */
33206 + BFD_RELOC_ARM_PCREL_BLX,
33207 +
33208 +/* Thumb 22 bit pc-relative branch. The lowest bit must be zero and is
33209 +not stored in the instruction. The 2nd lowest bit comes from a 1 bit
33210 +field in the instruction. */
33211 + BFD_RELOC_THUMB_PCREL_BLX,
33212 +
33213 +/* ARM 26-bit pc-relative branch for an unconditional BL or BLX instruction. */
33214 + BFD_RELOC_ARM_PCREL_CALL,
33215 +
33216 +/* ARM 26-bit pc-relative branch for B or conditional BL instruction. */
33217 + BFD_RELOC_ARM_PCREL_JUMP,
33218 +
33219 +/* Thumb 7-, 9-, 12-, 20-, 23-, and 25-bit pc-relative branches.
33220 +The lowest bit must be zero and is not stored in the instruction.
33221 +Note that the corresponding ELF R_ARM_THM_JUMPnn constant has an
33222 +"nn" one smaller in all cases. Note further that BRANCH23
33223 +corresponds to R_ARM_THM_CALL. */
33224 + BFD_RELOC_THUMB_PCREL_BRANCH7,
33225 + BFD_RELOC_THUMB_PCREL_BRANCH9,
33226 + BFD_RELOC_THUMB_PCREL_BRANCH12,
33227 + BFD_RELOC_THUMB_PCREL_BRANCH20,
33228 + BFD_RELOC_THUMB_PCREL_BRANCH23,
33229 + BFD_RELOC_THUMB_PCREL_BRANCH25,
33230 +
33231 +/* 12-bit immediate offset, used in ARM-format ldr and str instructions. */
33232 + BFD_RELOC_ARM_OFFSET_IMM,
33233 +
33234 +/* 5-bit immediate offset, used in Thumb-format ldr and str instructions. */
33235 + BFD_RELOC_ARM_THUMB_OFFSET,
33236 +
33237 +/* Pc-relative or absolute relocation depending on target. Used for
33238 +entries in .init_array sections. */
33239 + BFD_RELOC_ARM_TARGET1,
33240 +
33241 +/* Read-only segment base relative address. */
33242 + BFD_RELOC_ARM_ROSEGREL32,
33243 +
33244 +/* Data segment base relative address. */
33245 + BFD_RELOC_ARM_SBREL32,
33246 +
33247 +/* This reloc is used for references to RTTI data from exception handling
33248 +tables. The actual definition depends on the target. It may be a
33249 +pc-relative or some form of GOT-indirect relocation. */
33250 + BFD_RELOC_ARM_TARGET2,
33251 +
33252 +/* 31-bit PC relative address. */
33253 + BFD_RELOC_ARM_PREL31,
33254 +
33255 +/* Low and High halfword relocations for MOVW and MOVT instructions. */
33256 + BFD_RELOC_ARM_MOVW,
33257 + BFD_RELOC_ARM_MOVT,
33258 + BFD_RELOC_ARM_MOVW_PCREL,
33259 + BFD_RELOC_ARM_MOVT_PCREL,
33260 + BFD_RELOC_ARM_THUMB_MOVW,
33261 + BFD_RELOC_ARM_THUMB_MOVT,
33262 + BFD_RELOC_ARM_THUMB_MOVW_PCREL,
33263 + BFD_RELOC_ARM_THUMB_MOVT_PCREL,
33264 +
33265 +/* Relocations for setting up GOTs and PLTs for shared libraries. */
33266 + BFD_RELOC_ARM_JUMP_SLOT,
33267 + BFD_RELOC_ARM_GLOB_DAT,
33268 + BFD_RELOC_ARM_GOT32,
33269 + BFD_RELOC_ARM_PLT32,
33270 + BFD_RELOC_ARM_RELATIVE,
33271 + BFD_RELOC_ARM_GOTOFF,
33272 + BFD_RELOC_ARM_GOTPC,
33273 +
33274 +/* ARM thread-local storage relocations. */
33275 + BFD_RELOC_ARM_TLS_GD32,
33276 + BFD_RELOC_ARM_TLS_LDO32,
33277 + BFD_RELOC_ARM_TLS_LDM32,
33278 + BFD_RELOC_ARM_TLS_DTPOFF32,
33279 + BFD_RELOC_ARM_TLS_DTPMOD32,
33280 + BFD_RELOC_ARM_TLS_TPOFF32,
33281 + BFD_RELOC_ARM_TLS_IE32,
33282 + BFD_RELOC_ARM_TLS_LE32,
33283 +
33284 +/* ARM group relocations. */
33285 + BFD_RELOC_ARM_ALU_PC_G0_NC,
33286 + BFD_RELOC_ARM_ALU_PC_G0,
33287 + BFD_RELOC_ARM_ALU_PC_G1_NC,
33288 + BFD_RELOC_ARM_ALU_PC_G1,
33289 + BFD_RELOC_ARM_ALU_PC_G2,
33290 + BFD_RELOC_ARM_LDR_PC_G0,
33291 + BFD_RELOC_ARM_LDR_PC_G1,
33292 + BFD_RELOC_ARM_LDR_PC_G2,
33293 + BFD_RELOC_ARM_LDRS_PC_G0,
33294 + BFD_RELOC_ARM_LDRS_PC_G1,
33295 + BFD_RELOC_ARM_LDRS_PC_G2,
33296 + BFD_RELOC_ARM_LDC_PC_G0,
33297 + BFD_RELOC_ARM_LDC_PC_G1,
33298 + BFD_RELOC_ARM_LDC_PC_G2,
33299 + BFD_RELOC_ARM_ALU_SB_G0_NC,
33300 + BFD_RELOC_ARM_ALU_SB_G0,
33301 + BFD_RELOC_ARM_ALU_SB_G1_NC,
33302 + BFD_RELOC_ARM_ALU_SB_G1,
33303 + BFD_RELOC_ARM_ALU_SB_G2,
33304 + BFD_RELOC_ARM_LDR_SB_G0,
33305 + BFD_RELOC_ARM_LDR_SB_G1,
33306 + BFD_RELOC_ARM_LDR_SB_G2,
33307 + BFD_RELOC_ARM_LDRS_SB_G0,
33308 + BFD_RELOC_ARM_LDRS_SB_G1,
33309 + BFD_RELOC_ARM_LDRS_SB_G2,
33310 + BFD_RELOC_ARM_LDC_SB_G0,
33311 + BFD_RELOC_ARM_LDC_SB_G1,
33312 + BFD_RELOC_ARM_LDC_SB_G2,
33313 +
33314 +/* These relocs are only used within the ARM assembler. They are not
33315 +(at present) written to any object files. */
33316 + BFD_RELOC_ARM_IMMEDIATE,
33317 + BFD_RELOC_ARM_ADRL_IMMEDIATE,
33318 + BFD_RELOC_ARM_T32_IMMEDIATE,
33319 + BFD_RELOC_ARM_T32_ADD_IMM,
33320 + BFD_RELOC_ARM_T32_IMM12,
33321 + BFD_RELOC_ARM_T32_ADD_PC12,
33322 + BFD_RELOC_ARM_SHIFT_IMM,
33323 + BFD_RELOC_ARM_SMC,
33324 + BFD_RELOC_ARM_SWI,
33325 + BFD_RELOC_ARM_MULTI,
33326 + BFD_RELOC_ARM_CP_OFF_IMM,
33327 + BFD_RELOC_ARM_CP_OFF_IMM_S2,
33328 + BFD_RELOC_ARM_T32_CP_OFF_IMM,
33329 + BFD_RELOC_ARM_T32_CP_OFF_IMM_S2,
33330 + BFD_RELOC_ARM_ADR_IMM,
33331 + BFD_RELOC_ARM_LDR_IMM,
33332 + BFD_RELOC_ARM_LITERAL,
33333 + BFD_RELOC_ARM_IN_POOL,
33334 + BFD_RELOC_ARM_OFFSET_IMM8,
33335 + BFD_RELOC_ARM_T32_OFFSET_U8,
33336 + BFD_RELOC_ARM_T32_OFFSET_IMM,
33337 + BFD_RELOC_ARM_HWLITERAL,
33338 + BFD_RELOC_ARM_THUMB_ADD,
33339 + BFD_RELOC_ARM_THUMB_IMM,
33340 + BFD_RELOC_ARM_THUMB_SHIFT,
33341 +
33342 +/* Renesas / SuperH SH relocs. Not all of these appear in object files. */
33343 + BFD_RELOC_SH_PCDISP8BY2,
33344 + BFD_RELOC_SH_PCDISP12BY2,
33345 + BFD_RELOC_SH_IMM3,
33346 + BFD_RELOC_SH_IMM3U,
33347 + BFD_RELOC_SH_DISP12,
33348 + BFD_RELOC_SH_DISP12BY2,
33349 + BFD_RELOC_SH_DISP12BY4,
33350 + BFD_RELOC_SH_DISP12BY8,
33351 + BFD_RELOC_SH_DISP20,
33352 + BFD_RELOC_SH_DISP20BY8,
33353 + BFD_RELOC_SH_IMM4,
33354 + BFD_RELOC_SH_IMM4BY2,
33355 + BFD_RELOC_SH_IMM4BY4,
33356 + BFD_RELOC_SH_IMM8,
33357 + BFD_RELOC_SH_IMM8BY2,
33358 + BFD_RELOC_SH_IMM8BY4,
33359 + BFD_RELOC_SH_PCRELIMM8BY2,
33360 + BFD_RELOC_SH_PCRELIMM8BY4,
33361 + BFD_RELOC_SH_SWITCH16,
33362 + BFD_RELOC_SH_SWITCH32,
33363 + BFD_RELOC_SH_USES,
33364 + BFD_RELOC_SH_COUNT,
33365 + BFD_RELOC_SH_ALIGN,
33366 + BFD_RELOC_SH_CODE,
33367 + BFD_RELOC_SH_DATA,
33368 + BFD_RELOC_SH_LABEL,
33369 + BFD_RELOC_SH_LOOP_START,
33370 + BFD_RELOC_SH_LOOP_END,
33371 + BFD_RELOC_SH_COPY,
33372 + BFD_RELOC_SH_GLOB_DAT,
33373 + BFD_RELOC_SH_JMP_SLOT,
33374 + BFD_RELOC_SH_RELATIVE,
33375 + BFD_RELOC_SH_GOTPC,
33376 + BFD_RELOC_SH_GOT_LOW16,
33377 + BFD_RELOC_SH_GOT_MEDLOW16,
33378 + BFD_RELOC_SH_GOT_MEDHI16,
33379 + BFD_RELOC_SH_GOT_HI16,
33380 + BFD_RELOC_SH_GOTPLT_LOW16,
33381 + BFD_RELOC_SH_GOTPLT_MEDLOW16,
33382 + BFD_RELOC_SH_GOTPLT_MEDHI16,
33383 + BFD_RELOC_SH_GOTPLT_HI16,
33384 + BFD_RELOC_SH_PLT_LOW16,
33385 + BFD_RELOC_SH_PLT_MEDLOW16,
33386 + BFD_RELOC_SH_PLT_MEDHI16,
33387 + BFD_RELOC_SH_PLT_HI16,
33388 + BFD_RELOC_SH_GOTOFF_LOW16,
33389 + BFD_RELOC_SH_GOTOFF_MEDLOW16,
33390 + BFD_RELOC_SH_GOTOFF_MEDHI16,
33391 + BFD_RELOC_SH_GOTOFF_HI16,
33392 + BFD_RELOC_SH_GOTPC_LOW16,
33393 + BFD_RELOC_SH_GOTPC_MEDLOW16,
33394 + BFD_RELOC_SH_GOTPC_MEDHI16,
33395 + BFD_RELOC_SH_GOTPC_HI16,
33396 + BFD_RELOC_SH_COPY64,
33397 + BFD_RELOC_SH_GLOB_DAT64,
33398 + BFD_RELOC_SH_JMP_SLOT64,
33399 + BFD_RELOC_SH_RELATIVE64,
33400 + BFD_RELOC_SH_GOT10BY4,
33401 + BFD_RELOC_SH_GOT10BY8,
33402 + BFD_RELOC_SH_GOTPLT10BY4,
33403 + BFD_RELOC_SH_GOTPLT10BY8,
33404 + BFD_RELOC_SH_GOTPLT32,
33405 + BFD_RELOC_SH_SHMEDIA_CODE,
33406 + BFD_RELOC_SH_IMMU5,
33407 + BFD_RELOC_SH_IMMS6,
33408 + BFD_RELOC_SH_IMMS6BY32,
33409 + BFD_RELOC_SH_IMMU6,
33410 + BFD_RELOC_SH_IMMS10,
33411 + BFD_RELOC_SH_IMMS10BY2,
33412 + BFD_RELOC_SH_IMMS10BY4,
33413 + BFD_RELOC_SH_IMMS10BY8,
33414 + BFD_RELOC_SH_IMMS16,
33415 + BFD_RELOC_SH_IMMU16,
33416 + BFD_RELOC_SH_IMM_LOW16,
33417 + BFD_RELOC_SH_IMM_LOW16_PCREL,
33418 + BFD_RELOC_SH_IMM_MEDLOW16,
33419 + BFD_RELOC_SH_IMM_MEDLOW16_PCREL,
33420 + BFD_RELOC_SH_IMM_MEDHI16,
33421 + BFD_RELOC_SH_IMM_MEDHI16_PCREL,
33422 + BFD_RELOC_SH_IMM_HI16,
33423 + BFD_RELOC_SH_IMM_HI16_PCREL,
33424 + BFD_RELOC_SH_PT_16,
33425 + BFD_RELOC_SH_TLS_GD_32,
33426 + BFD_RELOC_SH_TLS_LD_32,
33427 + BFD_RELOC_SH_TLS_LDO_32,
33428 + BFD_RELOC_SH_TLS_IE_32,
33429 + BFD_RELOC_SH_TLS_LE_32,
33430 + BFD_RELOC_SH_TLS_DTPMOD32,
33431 + BFD_RELOC_SH_TLS_DTPOFF32,
33432 + BFD_RELOC_SH_TLS_TPOFF32,
33433 +
33434 +/* ARC Cores relocs.
33435 +ARC 22 bit pc-relative branch. The lowest two bits must be zero and are
33436 +not stored in the instruction. The high 20 bits are installed in bits 26
33437 +through 7 of the instruction. */
33438 + BFD_RELOC_ARC_B22_PCREL,
33439 +
33440 +/* ARC 26 bit absolute branch. The lowest two bits must be zero and are not
33441 +stored in the instruction. The high 24 bits are installed in bits 23
33442 +through 0. */
33443 + BFD_RELOC_ARC_B26,
33444 +
33445 +/* ADI Blackfin 16 bit immediate absolute reloc. */
33446 + BFD_RELOC_BFIN_16_IMM,
33447 +
33448 +/* ADI Blackfin 16 bit immediate absolute reloc higher 16 bits. */
33449 + BFD_RELOC_BFIN_16_HIGH,
33450 +
33451 +/* ADI Blackfin 'a' part of LSETUP. */
33452 + BFD_RELOC_BFIN_4_PCREL,
33453 +
33454 +/* ADI Blackfin. */
33455 + BFD_RELOC_BFIN_5_PCREL,
33456 +
33457 +/* ADI Blackfin 16 bit immediate absolute reloc lower 16 bits. */
33458 + BFD_RELOC_BFIN_16_LOW,
33459 +
33460 +/* ADI Blackfin. */
33461 + BFD_RELOC_BFIN_10_PCREL,
33462 +
33463 +/* ADI Blackfin 'b' part of LSETUP. */
33464 + BFD_RELOC_BFIN_11_PCREL,
33465 +
33466 +/* ADI Blackfin. */
33467 + BFD_RELOC_BFIN_12_PCREL_JUMP,
33468 +
33469 +/* ADI Blackfin Short jump, pcrel. */
33470 + BFD_RELOC_BFIN_12_PCREL_JUMP_S,
33471 +
33472 +/* ADI Blackfin Call.x not implemented. */
33473 + BFD_RELOC_BFIN_24_PCREL_CALL_X,
33474 +
33475 +/* ADI Blackfin Long Jump pcrel. */
33476 + BFD_RELOC_BFIN_24_PCREL_JUMP_L,
33477 +
33478 +/* ADI Blackfin FD-PIC relocations. */
33479 + BFD_RELOC_BFIN_GOT17M4,
33480 + BFD_RELOC_BFIN_GOTHI,
33481 + BFD_RELOC_BFIN_GOTLO,
33482 + BFD_RELOC_BFIN_FUNCDESC,
33483 + BFD_RELOC_BFIN_FUNCDESC_GOT17M4,
33484 + BFD_RELOC_BFIN_FUNCDESC_GOTHI,
33485 + BFD_RELOC_BFIN_FUNCDESC_GOTLO,
33486 + BFD_RELOC_BFIN_FUNCDESC_VALUE,
33487 + BFD_RELOC_BFIN_FUNCDESC_GOTOFF17M4,
33488 + BFD_RELOC_BFIN_FUNCDESC_GOTOFFHI,
33489 + BFD_RELOC_BFIN_FUNCDESC_GOTOFFLO,
33490 + BFD_RELOC_BFIN_GOTOFF17M4,
33491 + BFD_RELOC_BFIN_GOTOFFHI,
33492 + BFD_RELOC_BFIN_GOTOFFLO,
33493 +
33494 +/* ADI Blackfin GOT relocation. */
33495 + BFD_RELOC_BFIN_GOT,
33496 +
33497 +/* ADI Blackfin PLTPC relocation. */
33498 + BFD_RELOC_BFIN_PLTPC,
33499 +
33500 +/* ADI Blackfin arithmetic relocation. */
33501 + BFD_ARELOC_BFIN_PUSH,
33502 +
33503 +/* ADI Blackfin arithmetic relocation. */
33504 + BFD_ARELOC_BFIN_CONST,
33505 +
33506 +/* ADI Blackfin arithmetic relocation. */
33507 + BFD_ARELOC_BFIN_ADD,
33508 +
33509 +/* ADI Blackfin arithmetic relocation. */
33510 + BFD_ARELOC_BFIN_SUB,
33511 +
33512 +/* ADI Blackfin arithmetic relocation. */
33513 + BFD_ARELOC_BFIN_MULT,
33514 +
33515 +/* ADI Blackfin arithmetic relocation. */
33516 + BFD_ARELOC_BFIN_DIV,
33517 +
33518 +/* ADI Blackfin arithmetic relocation. */
33519 + BFD_ARELOC_BFIN_MOD,
33520 +
33521 +/* ADI Blackfin arithmetic relocation. */
33522 + BFD_ARELOC_BFIN_LSHIFT,
33523 +
33524 +/* ADI Blackfin arithmetic relocation. */
33525 + BFD_ARELOC_BFIN_RSHIFT,
33526 +
33527 +/* ADI Blackfin arithmetic relocation. */
33528 + BFD_ARELOC_BFIN_AND,
33529 +
33530 +/* ADI Blackfin arithmetic relocation. */
33531 + BFD_ARELOC_BFIN_OR,
33532 +
33533 +/* ADI Blackfin arithmetic relocation. */
33534 + BFD_ARELOC_BFIN_XOR,
33535 +
33536 +/* ADI Blackfin arithmetic relocation. */
33537 + BFD_ARELOC_BFIN_LAND,
33538 +
33539 +/* ADI Blackfin arithmetic relocation. */
33540 + BFD_ARELOC_BFIN_LOR,
33541 +
33542 +/* ADI Blackfin arithmetic relocation. */
33543 + BFD_ARELOC_BFIN_LEN,
33544 +
33545 +/* ADI Blackfin arithmetic relocation. */
33546 + BFD_ARELOC_BFIN_NEG,
33547 +
33548 +/* ADI Blackfin arithmetic relocation. */
33549 + BFD_ARELOC_BFIN_COMP,
33550 +
33551 +/* ADI Blackfin arithmetic relocation. */
33552 + BFD_ARELOC_BFIN_PAGE,
33553 +
33554 +/* ADI Blackfin arithmetic relocation. */
33555 + BFD_ARELOC_BFIN_HWPAGE,
33556 +
33557 +/* ADI Blackfin arithmetic relocation. */
33558 + BFD_ARELOC_BFIN_ADDR,
33559 +
33560 +/* Mitsubishi D10V relocs.
33561 +This is a 10-bit reloc with the right 2 bits
33562 +assumed to be 0. */
33563 + BFD_RELOC_D10V_10_PCREL_R,
33564 +
33565 +/* Mitsubishi D10V relocs.
33566 +This is a 10-bit reloc with the right 2 bits
33567 +assumed to be 0. This is the same as the previous reloc
33568 +except it is in the left container, i.e.,
33569 +shifted left 15 bits. */
33570 + BFD_RELOC_D10V_10_PCREL_L,
33571 +
33572 +/* This is an 18-bit reloc with the right 2 bits
33573 +assumed to be 0. */
33574 + BFD_RELOC_D10V_18,
33575 +
33576 +/* This is an 18-bit reloc with the right 2 bits
33577 +assumed to be 0. */
33578 + BFD_RELOC_D10V_18_PCREL,
33579 +
33580 +/* Mitsubishi D30V relocs.
33581 +This is a 6-bit absolute reloc. */
33582 + BFD_RELOC_D30V_6,
33583 +
33584 +/* This is a 6-bit pc-relative reloc with
33585 +the right 3 bits assumed to be 0. */
33586 + BFD_RELOC_D30V_9_PCREL,
33587 +
33588 +/* This is a 6-bit pc-relative reloc with
33589 +the right 3 bits assumed to be 0. Same
33590 +as the previous reloc but on the right side
33591 +of the container. */
33592 + BFD_RELOC_D30V_9_PCREL_R,
33593 +
33594 +/* This is a 12-bit absolute reloc with the
33595 +right 3 bitsassumed to be 0. */
33596 + BFD_RELOC_D30V_15,
33597 +
33598 +/* This is a 12-bit pc-relative reloc with
33599 +the right 3 bits assumed to be 0. */
33600 + BFD_RELOC_D30V_15_PCREL,
33601 +
33602 +/* This is a 12-bit pc-relative reloc with
33603 +the right 3 bits assumed to be 0. Same
33604 +as the previous reloc but on the right side
33605 +of the container. */
33606 + BFD_RELOC_D30V_15_PCREL_R,
33607 +
33608 +/* This is an 18-bit absolute reloc with
33609 +the right 3 bits assumed to be 0. */
33610 + BFD_RELOC_D30V_21,
33611 +
33612 +/* This is an 18-bit pc-relative reloc with
33613 +the right 3 bits assumed to be 0. */
33614 + BFD_RELOC_D30V_21_PCREL,
33615 +
33616 +/* This is an 18-bit pc-relative reloc with
33617 +the right 3 bits assumed to be 0. Same
33618 +as the previous reloc but on the right side
33619 +of the container. */
33620 + BFD_RELOC_D30V_21_PCREL_R,
33621 +
33622 +/* This is a 32-bit absolute reloc. */
33623 + BFD_RELOC_D30V_32,
33624 +
33625 +/* This is a 32-bit pc-relative reloc. */
33626 + BFD_RELOC_D30V_32_PCREL,
33627 +
33628 +/* DLX relocs */
33629 + BFD_RELOC_DLX_HI16_S,
33630 +
33631 +/* DLX relocs */
33632 + BFD_RELOC_DLX_LO16,
33633 +
33634 +/* DLX relocs */
33635 + BFD_RELOC_DLX_JMP26,
33636 +
33637 +/* Renesas M16C/M32C Relocations. */
33638 + BFD_RELOC_M32C_HI8,
33639 + BFD_RELOC_M32C_RL_JUMP,
33640 + BFD_RELOC_M32C_RL_1ADDR,
33641 + BFD_RELOC_M32C_RL_2ADDR,
33642 +
33643 +/* Renesas M32R (formerly Mitsubishi M32R) relocs.
33644 +This is a 24 bit absolute address. */
33645 + BFD_RELOC_M32R_24,
33646 +
33647 +/* This is a 10-bit pc-relative reloc with the right 2 bits assumed to be 0. */
33648 + BFD_RELOC_M32R_10_PCREL,
33649 +
33650 +/* This is an 18-bit reloc with the right 2 bits assumed to be 0. */
33651 + BFD_RELOC_M32R_18_PCREL,
33652 +
33653 +/* This is a 26-bit reloc with the right 2 bits assumed to be 0. */
33654 + BFD_RELOC_M32R_26_PCREL,
33655 +
33656 +/* This is a 16-bit reloc containing the high 16 bits of an address
33657 +used when the lower 16 bits are treated as unsigned. */
33658 + BFD_RELOC_M32R_HI16_ULO,
33659 +
33660 +/* This is a 16-bit reloc containing the high 16 bits of an address
33661 +used when the lower 16 bits are treated as signed. */
33662 + BFD_RELOC_M32R_HI16_SLO,
33663 +
33664 +/* This is a 16-bit reloc containing the lower 16 bits of an address. */
33665 + BFD_RELOC_M32R_LO16,
33666 +
33667 +/* This is a 16-bit reloc containing the small data area offset for use in
33668 +add3, load, and store instructions. */
33669 + BFD_RELOC_M32R_SDA16,
33670 +
33671 +/* For PIC. */
33672 + BFD_RELOC_M32R_GOT24,
33673 + BFD_RELOC_M32R_26_PLTREL,
33674 + BFD_RELOC_M32R_COPY,
33675 + BFD_RELOC_M32R_GLOB_DAT,
33676 + BFD_RELOC_M32R_JMP_SLOT,
33677 + BFD_RELOC_M32R_RELATIVE,
33678 + BFD_RELOC_M32R_GOTOFF,
33679 + BFD_RELOC_M32R_GOTOFF_HI_ULO,
33680 + BFD_RELOC_M32R_GOTOFF_HI_SLO,
33681 + BFD_RELOC_M32R_GOTOFF_LO,
33682 + BFD_RELOC_M32R_GOTPC24,
33683 + BFD_RELOC_M32R_GOT16_HI_ULO,
33684 + BFD_RELOC_M32R_GOT16_HI_SLO,
33685 + BFD_RELOC_M32R_GOT16_LO,
33686 + BFD_RELOC_M32R_GOTPC_HI_ULO,
33687 + BFD_RELOC_M32R_GOTPC_HI_SLO,
33688 + BFD_RELOC_M32R_GOTPC_LO,
33689 +
33690 +/* This is a 9-bit reloc */
33691 + BFD_RELOC_V850_9_PCREL,
33692 +
33693 +/* This is a 22-bit reloc */
33694 + BFD_RELOC_V850_22_PCREL,
33695 +
33696 +/* This is a 16 bit offset from the short data area pointer. */
33697 + BFD_RELOC_V850_SDA_16_16_OFFSET,
33698 +
33699 +/* This is a 16 bit offset (of which only 15 bits are used) from the
33700 +short data area pointer. */
33701 + BFD_RELOC_V850_SDA_15_16_OFFSET,
33702 +
33703 +/* This is a 16 bit offset from the zero data area pointer. */
33704 + BFD_RELOC_V850_ZDA_16_16_OFFSET,
33705 +
33706 +/* This is a 16 bit offset (of which only 15 bits are used) from the
33707 +zero data area pointer. */
33708 + BFD_RELOC_V850_ZDA_15_16_OFFSET,
33709 +
33710 +/* This is an 8 bit offset (of which only 6 bits are used) from the
33711 +tiny data area pointer. */
33712 + BFD_RELOC_V850_TDA_6_8_OFFSET,
33713 +
33714 +/* This is an 8bit offset (of which only 7 bits are used) from the tiny
33715 +data area pointer. */
33716 + BFD_RELOC_V850_TDA_7_8_OFFSET,
33717 +
33718 +/* This is a 7 bit offset from the tiny data area pointer. */
33719 + BFD_RELOC_V850_TDA_7_7_OFFSET,
33720 +
33721 +/* This is a 16 bit offset from the tiny data area pointer. */
33722 + BFD_RELOC_V850_TDA_16_16_OFFSET,
33723 +
33724 +/* This is a 5 bit offset (of which only 4 bits are used) from the tiny
33725 +data area pointer. */
33726 + BFD_RELOC_V850_TDA_4_5_OFFSET,
33727 +
33728 +/* This is a 4 bit offset from the tiny data area pointer. */
33729 + BFD_RELOC_V850_TDA_4_4_OFFSET,
33730 +
33731 +/* This is a 16 bit offset from the short data area pointer, with the
33732 +bits placed non-contiguously in the instruction. */
33733 + BFD_RELOC_V850_SDA_16_16_SPLIT_OFFSET,
33734 +
33735 +/* This is a 16 bit offset from the zero data area pointer, with the
33736 +bits placed non-contiguously in the instruction. */
33737 + BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET,
33738 +
33739 +/* This is a 6 bit offset from the call table base pointer. */
33740 + BFD_RELOC_V850_CALLT_6_7_OFFSET,
33741 +
33742 +/* This is a 16 bit offset from the call table base pointer. */
33743 + BFD_RELOC_V850_CALLT_16_16_OFFSET,
33744 +
33745 +/* Used for relaxing indirect function calls. */
33746 + BFD_RELOC_V850_LONGCALL,
33747 +
33748 +/* Used for relaxing indirect jumps. */
33749 + BFD_RELOC_V850_LONGJUMP,
33750 +
33751 +/* Used to maintain alignment whilst relaxing. */
33752 + BFD_RELOC_V850_ALIGN,
33753 +
33754 +/* This is a variation of BFD_RELOC_LO16 that can be used in v850e ld.bu
33755 +instructions. */
33756 + BFD_RELOC_V850_LO16_SPLIT_OFFSET,
33757 +
33758 +/* This is a 32bit pcrel reloc for the mn10300, offset by two bytes in the
33759 +instruction. */
33760 + BFD_RELOC_MN10300_32_PCREL,
33761 +
33762 +/* This is a 16bit pcrel reloc for the mn10300, offset by two bytes in the
33763 +instruction. */
33764 + BFD_RELOC_MN10300_16_PCREL,
33765 +
33766 +/* This is a 8bit DP reloc for the tms320c30, where the most
33767 +significant 8 bits of a 24 bit word are placed into the least
33768 +significant 8 bits of the opcode. */
33769 + BFD_RELOC_TIC30_LDP,
33770 +
33771 +/* This is a 7bit reloc for the tms320c54x, where the least
33772 +significant 7 bits of a 16 bit word are placed into the least
33773 +significant 7 bits of the opcode. */
33774 + BFD_RELOC_TIC54X_PARTLS7,
33775 +
33776 +/* This is a 9bit DP reloc for the tms320c54x, where the most
33777 +significant 9 bits of a 16 bit word are placed into the least
33778 +significant 9 bits of the opcode. */
33779 + BFD_RELOC_TIC54X_PARTMS9,
33780 +
33781 +/* This is an extended address 23-bit reloc for the tms320c54x. */
33782 + BFD_RELOC_TIC54X_23,
33783 +
33784 +/* This is a 16-bit reloc for the tms320c54x, where the least
33785 +significant 16 bits of a 23-bit extended address are placed into
33786 +the opcode. */
33787 + BFD_RELOC_TIC54X_16_OF_23,
33788 +
33789 +/* This is a reloc for the tms320c54x, where the most
33790 +significant 7 bits of a 23-bit extended address are placed into
33791 +the opcode. */
33792 + BFD_RELOC_TIC54X_MS7_OF_23,
33793 +
33794 +/* This is a 48 bit reloc for the FR30 that stores 32 bits. */
33795 + BFD_RELOC_FR30_48,
33796 +
33797 +/* This is a 32 bit reloc for the FR30 that stores 20 bits split up into
33798 +two sections. */
33799 + BFD_RELOC_FR30_20,
33800 +
33801 +/* This is a 16 bit reloc for the FR30 that stores a 6 bit word offset in
33802 +4 bits. */
33803 + BFD_RELOC_FR30_6_IN_4,
33804 +
33805 +/* This is a 16 bit reloc for the FR30 that stores an 8 bit byte offset
33806 +into 8 bits. */
33807 + BFD_RELOC_FR30_8_IN_8,
33808 +
33809 +/* This is a 16 bit reloc for the FR30 that stores a 9 bit short offset
33810 +into 8 bits. */
33811 + BFD_RELOC_FR30_9_IN_8,
33812 +
33813 +/* This is a 16 bit reloc for the FR30 that stores a 10 bit word offset
33814 +into 8 bits. */
33815 + BFD_RELOC_FR30_10_IN_8,
33816 +
33817 +/* This is a 16 bit reloc for the FR30 that stores a 9 bit pc relative
33818 +short offset into 8 bits. */
33819 + BFD_RELOC_FR30_9_PCREL,
33820 +
33821 +/* This is a 16 bit reloc for the FR30 that stores a 12 bit pc relative
33822 +short offset into 11 bits. */
33823 + BFD_RELOC_FR30_12_PCREL,
33824 +
33825 +/* Motorola Mcore relocations. */
33826 + BFD_RELOC_MCORE_PCREL_IMM8BY4,
33827 + BFD_RELOC_MCORE_PCREL_IMM11BY2,
33828 + BFD_RELOC_MCORE_PCREL_IMM4BY2,
33829 + BFD_RELOC_MCORE_PCREL_32,
33830 + BFD_RELOC_MCORE_PCREL_JSR_IMM11BY2,
33831 + BFD_RELOC_MCORE_RVA,
33832 +
33833 +/* Toshiba Media Processor Relocations. */
33834 + BFD_RELOC_MEP_8,
33835 + BFD_RELOC_MEP_16,
33836 + BFD_RELOC_MEP_32,
33837 + BFD_RELOC_MEP_PCREL8A2,
33838 + BFD_RELOC_MEP_PCREL12A2,
33839 + BFD_RELOC_MEP_PCREL17A2,
33840 + BFD_RELOC_MEP_PCREL24A2,
33841 + BFD_RELOC_MEP_PCABS24A2,
33842 + BFD_RELOC_MEP_LOW16,
33843 + BFD_RELOC_MEP_HI16U,
33844 + BFD_RELOC_MEP_HI16S,
33845 + BFD_RELOC_MEP_GPREL,
33846 + BFD_RELOC_MEP_TPREL,
33847 + BFD_RELOC_MEP_TPREL7,
33848 + BFD_RELOC_MEP_TPREL7A2,
33849 + BFD_RELOC_MEP_TPREL7A4,
33850 + BFD_RELOC_MEP_UIMM24,
33851 + BFD_RELOC_MEP_ADDR24A4,
33852 + BFD_RELOC_MEP_GNU_VTINHERIT,
33853 + BFD_RELOC_MEP_GNU_VTENTRY,
33854 +
33855 +
33856 +/* These are relocations for the GETA instruction. */
33857 + BFD_RELOC_MMIX_GETA,
33858 + BFD_RELOC_MMIX_GETA_1,
33859 + BFD_RELOC_MMIX_GETA_2,
33860 + BFD_RELOC_MMIX_GETA_3,
33861 +
33862 +/* These are relocations for a conditional branch instruction. */
33863 + BFD_RELOC_MMIX_CBRANCH,
33864 + BFD_RELOC_MMIX_CBRANCH_J,
33865 + BFD_RELOC_MMIX_CBRANCH_1,
33866 + BFD_RELOC_MMIX_CBRANCH_2,
33867 + BFD_RELOC_MMIX_CBRANCH_3,
33868 +
33869 +/* These are relocations for the PUSHJ instruction. */
33870 + BFD_RELOC_MMIX_PUSHJ,
33871 + BFD_RELOC_MMIX_PUSHJ_1,
33872 + BFD_RELOC_MMIX_PUSHJ_2,
33873 + BFD_RELOC_MMIX_PUSHJ_3,
33874 + BFD_RELOC_MMIX_PUSHJ_STUBBABLE,
33875 +
33876 +/* These are relocations for the JMP instruction. */
33877 + BFD_RELOC_MMIX_JMP,
33878 + BFD_RELOC_MMIX_JMP_1,
33879 + BFD_RELOC_MMIX_JMP_2,
33880 + BFD_RELOC_MMIX_JMP_3,
33881 +
33882 +/* This is a relocation for a relative address as in a GETA instruction or
33883 +a branch. */
33884 + BFD_RELOC_MMIX_ADDR19,
33885 +
33886 +/* This is a relocation for a relative address as in a JMP instruction. */
33887 + BFD_RELOC_MMIX_ADDR27,
33888 +
33889 +/* This is a relocation for an instruction field that may be a general
33890 +register or a value 0..255. */
33891 + BFD_RELOC_MMIX_REG_OR_BYTE,
33892 +
33893 +/* This is a relocation for an instruction field that may be a general
33894 +register. */
33895 + BFD_RELOC_MMIX_REG,
33896 +
33897 +/* This is a relocation for two instruction fields holding a register and
33898 +an offset, the equivalent of the relocation. */
33899 + BFD_RELOC_MMIX_BASE_PLUS_OFFSET,
33900 +
33901 +/* This relocation is an assertion that the expression is not allocated as
33902 +a global register. It does not modify contents. */
33903 + BFD_RELOC_MMIX_LOCAL,
33904 +
33905 +/* This is a 16 bit reloc for the AVR that stores 8 bit pc relative
33906 +short offset into 7 bits. */
33907 + BFD_RELOC_AVR_7_PCREL,
33908 +
33909 +/* This is a 16 bit reloc for the AVR that stores 13 bit pc relative
33910 +short offset into 12 bits. */
33911 + BFD_RELOC_AVR_13_PCREL,
33912 +
33913 +/* This is a 16 bit reloc for the AVR that stores 17 bit value (usually
33914 +program memory address) into 16 bits. */
33915 + BFD_RELOC_AVR_16_PM,
33916 +
33917 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (usually
33918 +data memory address) into 8 bit immediate value of LDI insn. */
33919 + BFD_RELOC_AVR_LO8_LDI,
33920 +
33921 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 bit
33922 +of data memory address) into 8 bit immediate value of LDI insn. */
33923 + BFD_RELOC_AVR_HI8_LDI,
33924 +
33925 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (most high 8 bit
33926 +of program memory address) into 8 bit immediate value of LDI insn. */
33927 + BFD_RELOC_AVR_HH8_LDI,
33928 +
33929 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (most high 8 bit
33930 +of 32 bit value) into 8 bit immediate value of LDI insn. */
33931 + BFD_RELOC_AVR_MS8_LDI,
33932 +
33933 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
33934 +(usually data memory address) into 8 bit immediate value of SUBI insn. */
33935 + BFD_RELOC_AVR_LO8_LDI_NEG,
33936 +
33937 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
33938 +(high 8 bit of data memory address) into 8 bit immediate value of
33939 +SUBI insn. */
33940 + BFD_RELOC_AVR_HI8_LDI_NEG,
33941 +
33942 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
33943 +(most high 8 bit of program memory address) into 8 bit immediate value
33944 +of LDI or SUBI insn. */
33945 + BFD_RELOC_AVR_HH8_LDI_NEG,
33946 +
33947 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value (msb
33948 +of 32 bit value) into 8 bit immediate value of LDI insn. */
33949 + BFD_RELOC_AVR_MS8_LDI_NEG,
33950 +
33951 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (usually
33952 +command address) into 8 bit immediate value of LDI insn. */
33953 + BFD_RELOC_AVR_LO8_LDI_PM,
33954 +
33955 +/* This is a 16 bit reloc for the AVR that stores 8 bit value
33956 +(command address) into 8 bit immediate value of LDI insn. If the address
33957 +is beyond the 128k boundary, the linker inserts a jump stub for this reloc
33958 +in the lower 128k. */
33959 + BFD_RELOC_AVR_LO8_LDI_GS,
33960 +
33961 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 bit
33962 +of command address) into 8 bit immediate value of LDI insn. */
33963 + BFD_RELOC_AVR_HI8_LDI_PM,
33964 +
33965 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 bit
33966 +of command address) into 8 bit immediate value of LDI insn. If the address
33967 +is beyond the 128k boundary, the linker inserts a jump stub for this reloc
33968 +below 128k. */
33969 + BFD_RELOC_AVR_HI8_LDI_GS,
33970 +
33971 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (most high 8 bit
33972 +of command address) into 8 bit immediate value of LDI insn. */
33973 + BFD_RELOC_AVR_HH8_LDI_PM,
33974 +
33975 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
33976 +(usually command address) into 8 bit immediate value of SUBI insn. */
33977 + BFD_RELOC_AVR_LO8_LDI_PM_NEG,
33978 +
33979 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
33980 +(high 8 bit of 16 bit command address) into 8 bit immediate value
33981 +of SUBI insn. */
33982 + BFD_RELOC_AVR_HI8_LDI_PM_NEG,
33983 +
33984 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
33985 +(high 6 bit of 22 bit command address) into 8 bit immediate
33986 +value of SUBI insn. */
33987 + BFD_RELOC_AVR_HH8_LDI_PM_NEG,
33988 +
33989 +/* This is a 32 bit reloc for the AVR that stores 23 bit value
33990 +into 22 bits. */
33991 + BFD_RELOC_AVR_CALL,
33992 +
33993 +/* This is a 16 bit reloc for the AVR that stores all needed bits
33994 +for absolute addressing with ldi with overflow check to linktime */
33995 + BFD_RELOC_AVR_LDI,
33996 +
33997 +/* This is a 6 bit reloc for the AVR that stores offset for ldd/std
33998 +instructions */
33999 + BFD_RELOC_AVR_6,
34000 +
34001 +/* This is a 6 bit reloc for the AVR that stores offset for adiw/sbiw
34002 +instructions */
34003 + BFD_RELOC_AVR_6_ADIW,
34004 +
34005 +/* Direct 12 bit. */
34006 + BFD_RELOC_390_12,
34007 +
34008 +/* 12 bit GOT offset. */
34009 + BFD_RELOC_390_GOT12,
34010 +
34011 +/* 32 bit PC relative PLT address. */
34012 + BFD_RELOC_390_PLT32,
34013 +
34014 +/* Copy symbol at runtime. */
34015 + BFD_RELOC_390_COPY,
34016 +
34017 +/* Create GOT entry. */
34018 + BFD_RELOC_390_GLOB_DAT,
34019 +
34020 +/* Create PLT entry. */
34021 + BFD_RELOC_390_JMP_SLOT,
34022 +
34023 +/* Adjust by program base. */
34024 + BFD_RELOC_390_RELATIVE,
34025 +
34026 +/* 32 bit PC relative offset to GOT. */
34027 + BFD_RELOC_390_GOTPC,
34028 +
34029 +/* 16 bit GOT offset. */
34030 + BFD_RELOC_390_GOT16,
34031 +
34032 +/* PC relative 16 bit shifted by 1. */
34033 + BFD_RELOC_390_PC16DBL,
34034 +
34035 +/* 16 bit PC rel. PLT shifted by 1. */
34036 + BFD_RELOC_390_PLT16DBL,
34037 +
34038 +/* PC relative 32 bit shifted by 1. */
34039 + BFD_RELOC_390_PC32DBL,
34040 +
34041 +/* 32 bit PC rel. PLT shifted by 1. */
34042 + BFD_RELOC_390_PLT32DBL,
34043 +
34044 +/* 32 bit PC rel. GOT shifted by 1. */
34045 + BFD_RELOC_390_GOTPCDBL,
34046 +
34047 +/* 64 bit GOT offset. */
34048 + BFD_RELOC_390_GOT64,
34049 +
34050 +/* 64 bit PC relative PLT address. */
34051 + BFD_RELOC_390_PLT64,
34052 +
34053 +/* 32 bit rel. offset to GOT entry. */
34054 + BFD_RELOC_390_GOTENT,
34055 +
34056 +/* 64 bit offset to GOT. */
34057 + BFD_RELOC_390_GOTOFF64,
34058 +
34059 +/* 12-bit offset to symbol-entry within GOT, with PLT handling. */
34060 + BFD_RELOC_390_GOTPLT12,
34061 +
34062 +/* 16-bit offset to symbol-entry within GOT, with PLT handling. */
34063 + BFD_RELOC_390_GOTPLT16,
34064 +
34065 +/* 32-bit offset to symbol-entry within GOT, with PLT handling. */
34066 + BFD_RELOC_390_GOTPLT32,
34067 +
34068 +/* 64-bit offset to symbol-entry within GOT, with PLT handling. */
34069 + BFD_RELOC_390_GOTPLT64,
34070 +
34071 +/* 32-bit rel. offset to symbol-entry within GOT, with PLT handling. */
34072 + BFD_RELOC_390_GOTPLTENT,
34073 +
34074 +/* 16-bit rel. offset from the GOT to a PLT entry. */
34075 + BFD_RELOC_390_PLTOFF16,
34076 +
34077 +/* 32-bit rel. offset from the GOT to a PLT entry. */
34078 + BFD_RELOC_390_PLTOFF32,
34079 +
34080 +/* 64-bit rel. offset from the GOT to a PLT entry. */
34081 + BFD_RELOC_390_PLTOFF64,
34082 +
34083 +/* s390 tls relocations. */
34084 + BFD_RELOC_390_TLS_LOAD,
34085 + BFD_RELOC_390_TLS_GDCALL,
34086 + BFD_RELOC_390_TLS_LDCALL,
34087 + BFD_RELOC_390_TLS_GD32,
34088 + BFD_RELOC_390_TLS_GD64,
34089 + BFD_RELOC_390_TLS_GOTIE12,
34090 + BFD_RELOC_390_TLS_GOTIE32,
34091 + BFD_RELOC_390_TLS_GOTIE64,
34092 + BFD_RELOC_390_TLS_LDM32,
34093 + BFD_RELOC_390_TLS_LDM64,
34094 + BFD_RELOC_390_TLS_IE32,
34095 + BFD_RELOC_390_TLS_IE64,
34096 + BFD_RELOC_390_TLS_IEENT,
34097 + BFD_RELOC_390_TLS_LE32,
34098 + BFD_RELOC_390_TLS_LE64,
34099 + BFD_RELOC_390_TLS_LDO32,
34100 + BFD_RELOC_390_TLS_LDO64,
34101 + BFD_RELOC_390_TLS_DTPMOD,
34102 + BFD_RELOC_390_TLS_DTPOFF,
34103 + BFD_RELOC_390_TLS_TPOFF,
34104 +
34105 +/* Long displacement extension. */
34106 + BFD_RELOC_390_20,
34107 + BFD_RELOC_390_GOT20,
34108 + BFD_RELOC_390_GOTPLT20,
34109 + BFD_RELOC_390_TLS_GOTIE20,
34110 +
34111 +/* Score relocations */
34112 + BFD_RELOC_SCORE_DUMMY1,
34113 +
34114 +/* Low 16 bit for load/store */
34115 + BFD_RELOC_SCORE_GPREL15,
34116 +
34117 +/* This is a 24-bit reloc with the right 1 bit assumed to be 0 */
34118 + BFD_RELOC_SCORE_DUMMY2,
34119 + BFD_RELOC_SCORE_JMP,
34120 +
34121 +/* This is a 19-bit reloc with the right 1 bit assumed to be 0 */
34122 + BFD_RELOC_SCORE_BRANCH,
34123 +
34124 +/* This is a 11-bit reloc with the right 1 bit assumed to be 0 */
34125 + BFD_RELOC_SCORE16_JMP,
34126 +
34127 +/* This is a 8-bit reloc with the right 1 bit assumed to be 0 */
34128 + BFD_RELOC_SCORE16_BRANCH,
34129 +
34130 +/* Undocumented Score relocs */
34131 + BFD_RELOC_SCORE_GOT15,
34132 + BFD_RELOC_SCORE_GOT_LO16,
34133 + BFD_RELOC_SCORE_CALL15,
34134 + BFD_RELOC_SCORE_DUMMY_HI16,
34135 +
34136 +/* Scenix IP2K - 9-bit register number / data address */
34137 + BFD_RELOC_IP2K_FR9,
34138 +
34139 +/* Scenix IP2K - 4-bit register/data bank number */
34140 + BFD_RELOC_IP2K_BANK,
34141 +
34142 +/* Scenix IP2K - low 13 bits of instruction word address */
34143 + BFD_RELOC_IP2K_ADDR16CJP,
34144 +
34145 +/* Scenix IP2K - high 3 bits of instruction word address */
34146 + BFD_RELOC_IP2K_PAGE3,
34147 +
34148 +/* Scenix IP2K - ext/low/high 8 bits of data address */
34149 + BFD_RELOC_IP2K_LO8DATA,
34150 + BFD_RELOC_IP2K_HI8DATA,
34151 + BFD_RELOC_IP2K_EX8DATA,
34152 +
34153 +/* Scenix IP2K - low/high 8 bits of instruction word address */
34154 + BFD_RELOC_IP2K_LO8INSN,
34155 + BFD_RELOC_IP2K_HI8INSN,
34156 +
34157 +/* Scenix IP2K - even/odd PC modifier to modify snb pcl.0 */
34158 + BFD_RELOC_IP2K_PC_SKIP,
34159 +
34160 +/* Scenix IP2K - 16 bit word address in text section. */
34161 + BFD_RELOC_IP2K_TEXT,
34162 +
34163 +/* Scenix IP2K - 7-bit sp or dp offset */
34164 + BFD_RELOC_IP2K_FR_OFFSET,
34165 +
34166 +/* Scenix VPE4K coprocessor - data/insn-space addressing */
34167 + BFD_RELOC_VPE4KMATH_DATA,
34168 + BFD_RELOC_VPE4KMATH_INSN,
34169 +
34170 +/* These two relocations are used by the linker to determine which of
34171 +the entries in a C++ virtual function table are actually used. When
34172 +the --gc-sections option is given, the linker will zero out the entries
34173 +that are not used, so that the code for those functions need not be
34174 +included in the output.
34175 +
34176 +VTABLE_INHERIT is a zero-space relocation used to describe to the
34177 +linker the inheritance tree of a C++ virtual function table. The
34178 +relocation's symbol should be the parent class' vtable, and the
34179 +relocation should be located at the child vtable.
34180 +
34181 +VTABLE_ENTRY is a zero-space relocation that describes the use of a
34182 +virtual function table entry. The reloc's symbol should refer to the
34183 +table of the class mentioned in the code. Off of that base, an offset
34184 +describes the entry that is being used. For Rela hosts, this offset
34185 +is stored in the reloc's addend. For Rel hosts, we are forced to put
34186 +this offset in the reloc's section offset. */
34187 + BFD_RELOC_VTABLE_INHERIT,
34188 + BFD_RELOC_VTABLE_ENTRY,
34189 +
34190 +/* Intel IA64 Relocations. */
34191 + BFD_RELOC_IA64_IMM14,
34192 + BFD_RELOC_IA64_IMM22,
34193 + BFD_RELOC_IA64_IMM64,
34194 + BFD_RELOC_IA64_DIR32MSB,
34195 + BFD_RELOC_IA64_DIR32LSB,
34196 + BFD_RELOC_IA64_DIR64MSB,
34197 + BFD_RELOC_IA64_DIR64LSB,
34198 + BFD_RELOC_IA64_GPREL22,
34199 + BFD_RELOC_IA64_GPREL64I,
34200 + BFD_RELOC_IA64_GPREL32MSB,
34201 + BFD_RELOC_IA64_GPREL32LSB,
34202 + BFD_RELOC_IA64_GPREL64MSB,
34203 + BFD_RELOC_IA64_GPREL64LSB,
34204 + BFD_RELOC_IA64_LTOFF22,
34205 + BFD_RELOC_IA64_LTOFF64I,
34206 + BFD_RELOC_IA64_PLTOFF22,
34207 + BFD_RELOC_IA64_PLTOFF64I,
34208 + BFD_RELOC_IA64_PLTOFF64MSB,
34209 + BFD_RELOC_IA64_PLTOFF64LSB,
34210 + BFD_RELOC_IA64_FPTR64I,
34211 + BFD_RELOC_IA64_FPTR32MSB,
34212 + BFD_RELOC_IA64_FPTR32LSB,
34213 + BFD_RELOC_IA64_FPTR64MSB,
34214 + BFD_RELOC_IA64_FPTR64LSB,
34215 + BFD_RELOC_IA64_PCREL21B,
34216 + BFD_RELOC_IA64_PCREL21BI,
34217 + BFD_RELOC_IA64_PCREL21M,
34218 + BFD_RELOC_IA64_PCREL21F,
34219 + BFD_RELOC_IA64_PCREL22,
34220 + BFD_RELOC_IA64_PCREL60B,
34221 + BFD_RELOC_IA64_PCREL64I,
34222 + BFD_RELOC_IA64_PCREL32MSB,
34223 + BFD_RELOC_IA64_PCREL32LSB,
34224 + BFD_RELOC_IA64_PCREL64MSB,
34225 + BFD_RELOC_IA64_PCREL64LSB,
34226 + BFD_RELOC_IA64_LTOFF_FPTR22,
34227 + BFD_RELOC_IA64_LTOFF_FPTR64I,
34228 + BFD_RELOC_IA64_LTOFF_FPTR32MSB,
34229 + BFD_RELOC_IA64_LTOFF_FPTR32LSB,
34230 + BFD_RELOC_IA64_LTOFF_FPTR64MSB,
34231 + BFD_RELOC_IA64_LTOFF_FPTR64LSB,
34232 + BFD_RELOC_IA64_SEGREL32MSB,
34233 + BFD_RELOC_IA64_SEGREL32LSB,
34234 + BFD_RELOC_IA64_SEGREL64MSB,
34235 + BFD_RELOC_IA64_SEGREL64LSB,
34236 + BFD_RELOC_IA64_SECREL32MSB,
34237 + BFD_RELOC_IA64_SECREL32LSB,
34238 + BFD_RELOC_IA64_SECREL64MSB,
34239 + BFD_RELOC_IA64_SECREL64LSB,
34240 + BFD_RELOC_IA64_REL32MSB,
34241 + BFD_RELOC_IA64_REL32LSB,
34242 + BFD_RELOC_IA64_REL64MSB,
34243 + BFD_RELOC_IA64_REL64LSB,
34244 + BFD_RELOC_IA64_LTV32MSB,
34245 + BFD_RELOC_IA64_LTV32LSB,
34246 + BFD_RELOC_IA64_LTV64MSB,
34247 + BFD_RELOC_IA64_LTV64LSB,
34248 + BFD_RELOC_IA64_IPLTMSB,
34249 + BFD_RELOC_IA64_IPLTLSB,
34250 + BFD_RELOC_IA64_COPY,
34251 + BFD_RELOC_IA64_LTOFF22X,
34252 + BFD_RELOC_IA64_LDXMOV,
34253 + BFD_RELOC_IA64_TPREL14,
34254 + BFD_RELOC_IA64_TPREL22,
34255 + BFD_RELOC_IA64_TPREL64I,
34256 + BFD_RELOC_IA64_TPREL64MSB,
34257 + BFD_RELOC_IA64_TPREL64LSB,
34258 + BFD_RELOC_IA64_LTOFF_TPREL22,
34259 + BFD_RELOC_IA64_DTPMOD64MSB,
34260 + BFD_RELOC_IA64_DTPMOD64LSB,
34261 + BFD_RELOC_IA64_LTOFF_DTPMOD22,
34262 + BFD_RELOC_IA64_DTPREL14,
34263 + BFD_RELOC_IA64_DTPREL22,
34264 + BFD_RELOC_IA64_DTPREL64I,
34265 + BFD_RELOC_IA64_DTPREL32MSB,
34266 + BFD_RELOC_IA64_DTPREL32LSB,
34267 + BFD_RELOC_IA64_DTPREL64MSB,
34268 + BFD_RELOC_IA64_DTPREL64LSB,
34269 + BFD_RELOC_IA64_LTOFF_DTPREL22,
34270 +
34271 +/* Motorola 68HC11 reloc.
34272 +This is the 8 bit high part of an absolute address. */
34273 + BFD_RELOC_M68HC11_HI8,
34274 +
34275 +/* Motorola 68HC11 reloc.
34276 +This is the 8 bit low part of an absolute address. */
34277 + BFD_RELOC_M68HC11_LO8,
34278 +
34279 +/* Motorola 68HC11 reloc.
34280 +This is the 3 bit of a value. */
34281 + BFD_RELOC_M68HC11_3B,
34282 +
34283 +/* Motorola 68HC11 reloc.
34284 +This reloc marks the beginning of a jump/call instruction.
34285 +It is used for linker relaxation to correctly identify beginning
34286 +of instruction and change some branches to use PC-relative
34287 +addressing mode. */
34288 + BFD_RELOC_M68HC11_RL_JUMP,
34289 +
34290 +/* Motorola 68HC11 reloc.
34291 +This reloc marks a group of several instructions that gcc generates
34292 +and for which the linker relaxation pass can modify and/or remove
34293 +some of them. */
34294 + BFD_RELOC_M68HC11_RL_GROUP,
34295 +
34296 +/* Motorola 68HC11 reloc.
34297 +This is the 16-bit lower part of an address. It is used for 'call'
34298 +instruction to specify the symbol address without any special
34299 +transformation (due to memory bank window). */
34300 + BFD_RELOC_M68HC11_LO16,
34301 +
34302 +/* Motorola 68HC11 reloc.
34303 +This is a 8-bit reloc that specifies the page number of an address.
34304 +It is used by 'call' instruction to specify the page number of
34305 +the symbol. */
34306 + BFD_RELOC_M68HC11_PAGE,
34307 +
34308 +/* Motorola 68HC11 reloc.
34309 +This is a 24-bit reloc that represents the address with a 16-bit
34310 +value and a 8-bit page number. The symbol address is transformed
34311 +to follow the 16K memory bank of 68HC12 (seen as mapped in the window). */
34312 + BFD_RELOC_M68HC11_24,
34313 +
34314 +/* Motorola 68HC12 reloc.
34315 +This is the 5 bits of a value. */
34316 + BFD_RELOC_M68HC12_5B,
34317 +
34318 +/* NS CR16C Relocations. */
34319 + BFD_RELOC_16C_NUM08,
34320 + BFD_RELOC_16C_NUM08_C,
34321 + BFD_RELOC_16C_NUM16,
34322 + BFD_RELOC_16C_NUM16_C,
34323 + BFD_RELOC_16C_NUM32,
34324 + BFD_RELOC_16C_NUM32_C,
34325 + BFD_RELOC_16C_DISP04,
34326 + BFD_RELOC_16C_DISP04_C,
34327 + BFD_RELOC_16C_DISP08,
34328 + BFD_RELOC_16C_DISP08_C,
34329 + BFD_RELOC_16C_DISP16,
34330 + BFD_RELOC_16C_DISP16_C,
34331 + BFD_RELOC_16C_DISP24,
34332 + BFD_RELOC_16C_DISP24_C,
34333 + BFD_RELOC_16C_DISP24a,
34334 + BFD_RELOC_16C_DISP24a_C,
34335 + BFD_RELOC_16C_REG04,
34336 + BFD_RELOC_16C_REG04_C,
34337 + BFD_RELOC_16C_REG04a,
34338 + BFD_RELOC_16C_REG04a_C,
34339 + BFD_RELOC_16C_REG14,
34340 + BFD_RELOC_16C_REG14_C,
34341 + BFD_RELOC_16C_REG16,
34342 + BFD_RELOC_16C_REG16_C,
34343 + BFD_RELOC_16C_REG20,
34344 + BFD_RELOC_16C_REG20_C,
34345 + BFD_RELOC_16C_ABS20,
34346 + BFD_RELOC_16C_ABS20_C,
34347 + BFD_RELOC_16C_ABS24,
34348 + BFD_RELOC_16C_ABS24_C,
34349 + BFD_RELOC_16C_IMM04,
34350 + BFD_RELOC_16C_IMM04_C,
34351 + BFD_RELOC_16C_IMM16,
34352 + BFD_RELOC_16C_IMM16_C,
34353 + BFD_RELOC_16C_IMM20,
34354 + BFD_RELOC_16C_IMM20_C,
34355 + BFD_RELOC_16C_IMM24,
34356 + BFD_RELOC_16C_IMM24_C,
34357 + BFD_RELOC_16C_IMM32,
34358 + BFD_RELOC_16C_IMM32_C,
34359 +
34360 +/* NS CR16 Relocations. */
34361 + BFD_RELOC_CR16_NUM8,
34362 + BFD_RELOC_CR16_NUM16,
34363 + BFD_RELOC_CR16_NUM32,
34364 + BFD_RELOC_CR16_NUM32a,
34365 + BFD_RELOC_CR16_REGREL0,
34366 + BFD_RELOC_CR16_REGREL4,
34367 + BFD_RELOC_CR16_REGREL4a,
34368 + BFD_RELOC_CR16_REGREL14,
34369 + BFD_RELOC_CR16_REGREL14a,
34370 + BFD_RELOC_CR16_REGREL16,
34371 + BFD_RELOC_CR16_REGREL20,
34372 + BFD_RELOC_CR16_REGREL20a,
34373 + BFD_RELOC_CR16_ABS20,
34374 + BFD_RELOC_CR16_ABS24,
34375 + BFD_RELOC_CR16_IMM4,
34376 + BFD_RELOC_CR16_IMM8,
34377 + BFD_RELOC_CR16_IMM16,
34378 + BFD_RELOC_CR16_IMM20,
34379 + BFD_RELOC_CR16_IMM24,
34380 + BFD_RELOC_CR16_IMM32,
34381 + BFD_RELOC_CR16_IMM32a,
34382 + BFD_RELOC_CR16_DISP4,
34383 + BFD_RELOC_CR16_DISP8,
34384 + BFD_RELOC_CR16_DISP16,
34385 + BFD_RELOC_CR16_DISP20,
34386 + BFD_RELOC_CR16_DISP24,
34387 + BFD_RELOC_CR16_DISP24a,
34388 +
34389 +/* NS CRX Relocations. */
34390 + BFD_RELOC_CRX_REL4,
34391 + BFD_RELOC_CRX_REL8,
34392 + BFD_RELOC_CRX_REL8_CMP,
34393 + BFD_RELOC_CRX_REL16,
34394 + BFD_RELOC_CRX_REL24,
34395 + BFD_RELOC_CRX_REL32,
34396 + BFD_RELOC_CRX_REGREL12,
34397 + BFD_RELOC_CRX_REGREL22,
34398 + BFD_RELOC_CRX_REGREL28,
34399 + BFD_RELOC_CRX_REGREL32,
34400 + BFD_RELOC_CRX_ABS16,
34401 + BFD_RELOC_CRX_ABS32,
34402 + BFD_RELOC_CRX_NUM8,
34403 + BFD_RELOC_CRX_NUM16,
34404 + BFD_RELOC_CRX_NUM32,
34405 + BFD_RELOC_CRX_IMM16,
34406 + BFD_RELOC_CRX_IMM32,
34407 + BFD_RELOC_CRX_SWITCH8,
34408 + BFD_RELOC_CRX_SWITCH16,
34409 + BFD_RELOC_CRX_SWITCH32,
34410 +
34411 +/* These relocs are only used within the CRIS assembler. They are not
34412 +(at present) written to any object files. */
34413 + BFD_RELOC_CRIS_BDISP8,
34414 + BFD_RELOC_CRIS_UNSIGNED_5,
34415 + BFD_RELOC_CRIS_SIGNED_6,
34416 + BFD_RELOC_CRIS_UNSIGNED_6,
34417 + BFD_RELOC_CRIS_SIGNED_8,
34418 + BFD_RELOC_CRIS_UNSIGNED_8,
34419 + BFD_RELOC_CRIS_SIGNED_16,
34420 + BFD_RELOC_CRIS_UNSIGNED_16,
34421 + BFD_RELOC_CRIS_LAPCQ_OFFSET,
34422 + BFD_RELOC_CRIS_UNSIGNED_4,
34423 +
34424 +/* Relocs used in ELF shared libraries for CRIS. */
34425 + BFD_RELOC_CRIS_COPY,
34426 + BFD_RELOC_CRIS_GLOB_DAT,
34427 + BFD_RELOC_CRIS_JUMP_SLOT,
34428 + BFD_RELOC_CRIS_RELATIVE,
34429 +
34430 +/* 32-bit offset to symbol-entry within GOT. */
34431 + BFD_RELOC_CRIS_32_GOT,
34432 +
34433 +/* 16-bit offset to symbol-entry within GOT. */
34434 + BFD_RELOC_CRIS_16_GOT,
34435 +
34436 +/* 32-bit offset to symbol-entry within GOT, with PLT handling. */
34437 + BFD_RELOC_CRIS_32_GOTPLT,
34438 +
34439 +/* 16-bit offset to symbol-entry within GOT, with PLT handling. */
34440 + BFD_RELOC_CRIS_16_GOTPLT,
34441 +
34442 +/* 32-bit offset to symbol, relative to GOT. */
34443 + BFD_RELOC_CRIS_32_GOTREL,
34444 +
34445 +/* 32-bit offset to symbol with PLT entry, relative to GOT. */
34446 + BFD_RELOC_CRIS_32_PLT_GOTREL,
34447 +
34448 +/* 32-bit offset to symbol with PLT entry, relative to this relocation. */
34449 + BFD_RELOC_CRIS_32_PLT_PCREL,
34450 +
34451 +/* Intel i860 Relocations. */
34452 + BFD_RELOC_860_COPY,
34453 + BFD_RELOC_860_GLOB_DAT,
34454 + BFD_RELOC_860_JUMP_SLOT,
34455 + BFD_RELOC_860_RELATIVE,
34456 + BFD_RELOC_860_PC26,
34457 + BFD_RELOC_860_PLT26,
34458 + BFD_RELOC_860_PC16,
34459 + BFD_RELOC_860_LOW0,
34460 + BFD_RELOC_860_SPLIT0,
34461 + BFD_RELOC_860_LOW1,
34462 + BFD_RELOC_860_SPLIT1,
34463 + BFD_RELOC_860_LOW2,
34464 + BFD_RELOC_860_SPLIT2,
34465 + BFD_RELOC_860_LOW3,
34466 + BFD_RELOC_860_LOGOT0,
34467 + BFD_RELOC_860_SPGOT0,
34468 + BFD_RELOC_860_LOGOT1,
34469 + BFD_RELOC_860_SPGOT1,
34470 + BFD_RELOC_860_LOGOTOFF0,
34471 + BFD_RELOC_860_SPGOTOFF0,
34472 + BFD_RELOC_860_LOGOTOFF1,
34473 + BFD_RELOC_860_SPGOTOFF1,
34474 + BFD_RELOC_860_LOGOTOFF2,
34475 + BFD_RELOC_860_LOGOTOFF3,
34476 + BFD_RELOC_860_LOPC,
34477 + BFD_RELOC_860_HIGHADJ,
34478 + BFD_RELOC_860_HAGOT,
34479 + BFD_RELOC_860_HAGOTOFF,
34480 + BFD_RELOC_860_HAPC,
34481 + BFD_RELOC_860_HIGH,
34482 + BFD_RELOC_860_HIGOT,
34483 + BFD_RELOC_860_HIGOTOFF,
34484 +
34485 +/* OpenRISC Relocations. */
34486 + BFD_RELOC_OPENRISC_ABS_26,
34487 + BFD_RELOC_OPENRISC_REL_26,
34488 +
34489 +/* H8 elf Relocations. */
34490 + BFD_RELOC_H8_DIR16A8,
34491 + BFD_RELOC_H8_DIR16R8,
34492 + BFD_RELOC_H8_DIR24A8,
34493 + BFD_RELOC_H8_DIR24R8,
34494 + BFD_RELOC_H8_DIR32A16,
34495 +
34496 +/* Sony Xstormy16 Relocations. */
34497 + BFD_RELOC_XSTORMY16_REL_12,
34498 + BFD_RELOC_XSTORMY16_12,
34499 + BFD_RELOC_XSTORMY16_24,
34500 + BFD_RELOC_XSTORMY16_FPTR16,
34501 +
34502 +/* Self-describing complex relocations. */
34503 + BFD_RELOC_RELC,
34504 +
34505 +
34506 +/* Infineon Relocations. */
34507 + BFD_RELOC_XC16X_PAG,
34508 + BFD_RELOC_XC16X_POF,
34509 + BFD_RELOC_XC16X_SEG,
34510 + BFD_RELOC_XC16X_SOF,
34511 +
34512 +/* Relocations used by VAX ELF. */
34513 + BFD_RELOC_VAX_GLOB_DAT,
34514 + BFD_RELOC_VAX_JMP_SLOT,
34515 + BFD_RELOC_VAX_RELATIVE,
34516 +
34517 +/* Morpho MT - 16 bit immediate relocation. */
34518 + BFD_RELOC_MT_PC16,
34519 +
34520 +/* Morpho MT - Hi 16 bits of an address. */
34521 + BFD_RELOC_MT_HI16,
34522 +
34523 +/* Morpho MT - Low 16 bits of an address. */
34524 + BFD_RELOC_MT_LO16,
34525 +
34526 +/* Morpho MT - Used to tell the linker which vtable entries are used. */
34527 + BFD_RELOC_MT_GNU_VTINHERIT,
34528 +
34529 +/* Morpho MT - Used to tell the linker which vtable entries are used. */
34530 + BFD_RELOC_MT_GNU_VTENTRY,
34531 +
34532 +/* Morpho MT - 8 bit immediate relocation. */
34533 + BFD_RELOC_MT_PCINSN8,
34534 +
34535 +/* msp430 specific relocation codes */
34536 + BFD_RELOC_MSP430_10_PCREL,
34537 + BFD_RELOC_MSP430_16_PCREL,
34538 + BFD_RELOC_MSP430_16,
34539 + BFD_RELOC_MSP430_16_PCREL_BYTE,
34540 + BFD_RELOC_MSP430_16_BYTE,
34541 + BFD_RELOC_MSP430_2X_PCREL,
34542 + BFD_RELOC_MSP430_RL_PCREL,
34543 +
34544 +/* IQ2000 Relocations. */
34545 + BFD_RELOC_IQ2000_OFFSET_16,
34546 + BFD_RELOC_IQ2000_OFFSET_21,
34547 + BFD_RELOC_IQ2000_UHI16,
34548 +
34549 +/* Special Xtensa relocation used only by PLT entries in ELF shared
34550 +objects to indicate that the runtime linker should set the value
34551 +to one of its own internal functions or data structures. */
34552 + BFD_RELOC_XTENSA_RTLD,
34553 +
34554 +/* Xtensa relocations for ELF shared objects. */
34555 + BFD_RELOC_XTENSA_GLOB_DAT,
34556 + BFD_RELOC_XTENSA_JMP_SLOT,
34557 + BFD_RELOC_XTENSA_RELATIVE,
34558 +
34559 +/* Xtensa relocation used in ELF object files for symbols that may require
34560 +PLT entries. Otherwise, this is just a generic 32-bit relocation. */
34561 + BFD_RELOC_XTENSA_PLT,
34562 +
34563 +/* Xtensa relocations to mark the difference of two local symbols.
34564 +These are only needed to support linker relaxation and can be ignored
34565 +when not relaxing. The field is set to the value of the difference
34566 +assuming no relaxation. The relocation encodes the position of the
34567 +first symbol so the linker can determine whether to adjust the field
34568 +value. */
34569 + BFD_RELOC_XTENSA_DIFF8,
34570 + BFD_RELOC_XTENSA_DIFF16,
34571 + BFD_RELOC_XTENSA_DIFF32,
34572 +
34573 +/* Generic Xtensa relocations for instruction operands. Only the slot
34574 +number is encoded in the relocation. The relocation applies to the
34575 +last PC-relative immediate operand, or if there are no PC-relative
34576 +immediates, to the last immediate operand. */
34577 + BFD_RELOC_XTENSA_SLOT0_OP,
34578 + BFD_RELOC_XTENSA_SLOT1_OP,
34579 + BFD_RELOC_XTENSA_SLOT2_OP,
34580 + BFD_RELOC_XTENSA_SLOT3_OP,
34581 + BFD_RELOC_XTENSA_SLOT4_OP,
34582 + BFD_RELOC_XTENSA_SLOT5_OP,
34583 + BFD_RELOC_XTENSA_SLOT6_OP,
34584 + BFD_RELOC_XTENSA_SLOT7_OP,
34585 + BFD_RELOC_XTENSA_SLOT8_OP,
34586 + BFD_RELOC_XTENSA_SLOT9_OP,
34587 + BFD_RELOC_XTENSA_SLOT10_OP,
34588 + BFD_RELOC_XTENSA_SLOT11_OP,
34589 + BFD_RELOC_XTENSA_SLOT12_OP,
34590 + BFD_RELOC_XTENSA_SLOT13_OP,
34591 + BFD_RELOC_XTENSA_SLOT14_OP,
34592 +
34593 +/* Alternate Xtensa relocations. Only the slot is encoded in the
34594 +relocation. The meaning of these relocations is opcode-specific. */
34595 + BFD_RELOC_XTENSA_SLOT0_ALT,
34596 + BFD_RELOC_XTENSA_SLOT1_ALT,
34597 + BFD_RELOC_XTENSA_SLOT2_ALT,
34598 + BFD_RELOC_XTENSA_SLOT3_ALT,
34599 + BFD_RELOC_XTENSA_SLOT4_ALT,
34600 + BFD_RELOC_XTENSA_SLOT5_ALT,
34601 + BFD_RELOC_XTENSA_SLOT6_ALT,
34602 + BFD_RELOC_XTENSA_SLOT7_ALT,
34603 + BFD_RELOC_XTENSA_SLOT8_ALT,
34604 + BFD_RELOC_XTENSA_SLOT9_ALT,
34605 + BFD_RELOC_XTENSA_SLOT10_ALT,
34606 + BFD_RELOC_XTENSA_SLOT11_ALT,
34607 + BFD_RELOC_XTENSA_SLOT12_ALT,
34608 + BFD_RELOC_XTENSA_SLOT13_ALT,
34609 + BFD_RELOC_XTENSA_SLOT14_ALT,
34610 +
34611 +/* Xtensa relocations for backward compatibility. These have all been
34612 +replaced by BFD_RELOC_XTENSA_SLOT0_OP. */
34613 + BFD_RELOC_XTENSA_OP0,
34614 + BFD_RELOC_XTENSA_OP1,
34615 + BFD_RELOC_XTENSA_OP2,
34616 +
34617 +/* Xtensa relocation to mark that the assembler expanded the
34618 +instructions from an original target. The expansion size is
34619 +encoded in the reloc size. */
34620 + BFD_RELOC_XTENSA_ASM_EXPAND,
34621 +
34622 +/* Xtensa relocation to mark that the linker should simplify
34623 +assembler-expanded instructions. This is commonly used
34624 +internally by the linker after analysis of a
34625 +BFD_RELOC_XTENSA_ASM_EXPAND. */
34626 + BFD_RELOC_XTENSA_ASM_SIMPLIFY,
34627 +
34628 +/* 8 bit signed offset in (ix+d) or (iy+d). */
34629 + BFD_RELOC_Z80_DISP8,
34630 +
34631 +/* DJNZ offset. */
34632 + BFD_RELOC_Z8K_DISP7,
34633 +
34634 +/* CALR offset. */
34635 + BFD_RELOC_Z8K_CALLR,
34636 +
34637 +/* 4 bit value. */
34638 + BFD_RELOC_Z8K_IMM4L,
34639 + BFD_RELOC_UNUSED };
34640 +typedef enum bfd_reloc_code_real bfd_reloc_code_real_type;
34641 +reloc_howto_type *bfd_reloc_type_lookup
34642 + (bfd *abfd, bfd_reloc_code_real_type code);
34643 +reloc_howto_type *bfd_reloc_name_lookup
34644 + (bfd *abfd, const char *reloc_name);
34645 +
34646 +const char *bfd_get_reloc_code_name (bfd_reloc_code_real_type code);
34647 +
34648 +/* Extracted from syms.c. */
34649 +
34650 +typedef struct bfd_symbol
34651 +{
34652 + /* A pointer to the BFD which owns the symbol. This information
34653 + is necessary so that a back end can work out what additional
34654 + information (invisible to the application writer) is carried
34655 + with the symbol.
34656 +
34657 + This field is *almost* redundant, since you can use section->owner
34658 + instead, except that some symbols point to the global sections
34659 + bfd_{abs,com,und}_section. This could be fixed by making
34660 + these globals be per-bfd (or per-target-flavor). FIXME. */
34661 + struct bfd *the_bfd; /* Use bfd_asymbol_bfd(sym) to access this field. */
34662 +
34663 + /* The text of the symbol. The name is left alone, and not copied; the
34664 + application may not alter it. */
34665 + const char *name;
34666 +
34667 + /* The value of the symbol. This really should be a union of a
34668 + numeric value with a pointer, since some flags indicate that
34669 + a pointer to another symbol is stored here. */
34670 + symvalue value;
34671 +
34672 + /* Attributes of a symbol. */
34673 +#define BSF_NO_FLAGS 0x00
34674 +
34675 + /* The symbol has local scope; <<static>> in <<C>>. The value
34676 + is the offset into the section of the data. */
34677 +#define BSF_LOCAL 0x01
34678 +
34679 + /* The symbol has global scope; initialized data in <<C>>. The
34680 + value is the offset into the section of the data. */
34681 +#define BSF_GLOBAL 0x02
34682 +
34683 + /* The symbol has global scope and is exported. The value is
34684 + the offset into the section of the data. */
34685 +#define BSF_EXPORT BSF_GLOBAL /* No real difference. */
34686 +
34687 + /* A normal C symbol would be one of:
34688 + <<BSF_LOCAL>>, <<BSF_FORT_COMM>>, <<BSF_UNDEFINED>> or
34689 + <<BSF_GLOBAL>>. */
34690 +
34691 + /* The symbol is a debugging record. The value has an arbitrary
34692 + meaning, unless BSF_DEBUGGING_RELOC is also set. */
34693 +#define BSF_DEBUGGING 0x08
34694 +
34695 + /* The symbol denotes a function entry point. Used in ELF,
34696 + perhaps others someday. */
34697 +#define BSF_FUNCTION 0x10
34698 +
34699 + /* Used by the linker. */
34700 +#define BSF_KEEP 0x20
34701 +#define BSF_KEEP_G 0x40
34702 +
34703 + /* A weak global symbol, overridable without warnings by
34704 + a regular global symbol of the same name. */
34705 +#define BSF_WEAK 0x80
34706 +
34707 + /* This symbol was created to point to a section, e.g. ELF's
34708 + STT_SECTION symbols. */
34709 +#define BSF_SECTION_SYM 0x100
34710 +
34711 + /* The symbol used to be a common symbol, but now it is
34712 + allocated. */
34713 +#define BSF_OLD_COMMON 0x200
34714 +
34715 + /* The default value for common data. */
34716 +#define BFD_FORT_COMM_DEFAULT_VALUE 0
34717 +
34718 + /* In some files the type of a symbol sometimes alters its
34719 + location in an output file - ie in coff a <<ISFCN>> symbol
34720 + which is also <<C_EXT>> symbol appears where it was
34721 + declared and not at the end of a section. This bit is set
34722 + by the target BFD part to convey this information. */
34723 +#define BSF_NOT_AT_END 0x400
34724 +
34725 + /* Signal that the symbol is the label of constructor section. */
34726 +#define BSF_CONSTRUCTOR 0x800
34727 +
34728 + /* Signal that the symbol is a warning symbol. The name is a
34729 + warning. The name of the next symbol is the one to warn about;
34730 + if a reference is made to a symbol with the same name as the next
34731 + symbol, a warning is issued by the linker. */
34732 +#define BSF_WARNING 0x1000
34733 +
34734 + /* Signal that the symbol is indirect. This symbol is an indirect
34735 + pointer to the symbol with the same name as the next symbol. */
34736 +#define BSF_INDIRECT 0x2000
34737 +
34738 + /* BSF_FILE marks symbols that contain a file name. This is used
34739 + for ELF STT_FILE symbols. */
34740 +#define BSF_FILE 0x4000
34741 +
34742 + /* Symbol is from dynamic linking information. */
34743 +#define BSF_DYNAMIC 0x8000
34744 +
34745 + /* The symbol denotes a data object. Used in ELF, and perhaps
34746 + others someday. */
34747 +#define BSF_OBJECT 0x10000
34748 +
34749 + /* This symbol is a debugging symbol. The value is the offset
34750 + into the section of the data. BSF_DEBUGGING should be set
34751 + as well. */
34752 +#define BSF_DEBUGGING_RELOC 0x20000
34753 +
34754 + /* This symbol is thread local. Used in ELF. */
34755 +#define BSF_THREAD_LOCAL 0x40000
34756 +
34757 + /* This symbol represents a complex relocation expression,
34758 + with the expression tree serialized in the symbol name. */
34759 +#define BSF_RELC 0x80000
34760 +
34761 + /* This symbol represents a signed complex relocation expression,
34762 + with the expression tree serialized in the symbol name. */
34763 +#define BSF_SRELC 0x100000
34764 +
34765 + flagword flags;
34766 +
34767 + /* A pointer to the section to which this symbol is
34768 + relative. This will always be non NULL, there are special
34769 + sections for undefined and absolute symbols. */
34770 + struct bfd_section *section;
34771 +
34772 + /* Back end special data. */
34773 + union
34774 + {
34775 + void *p;
34776 + bfd_vma i;
34777 + }
34778 + udata;
34779 +}
34780 +asymbol;
34781 +
34782 +#define bfd_get_symtab_upper_bound(abfd) \
34783 + BFD_SEND (abfd, _bfd_get_symtab_upper_bound, (abfd))
34784 +
34785 +bfd_boolean bfd_is_local_label (bfd *abfd, asymbol *sym);
34786 +
34787 +bfd_boolean bfd_is_local_label_name (bfd *abfd, const char *name);
34788 +
34789 +#define bfd_is_local_label_name(abfd, name) \
34790 + BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
34791 +
34792 +bfd_boolean bfd_is_target_special_symbol (bfd *abfd, asymbol *sym);
34793 +
34794 +#define bfd_is_target_special_symbol(abfd, sym) \
34795 + BFD_SEND (abfd, _bfd_is_target_special_symbol, (abfd, sym))
34796 +
34797 +#define bfd_canonicalize_symtab(abfd, location) \
34798 + BFD_SEND (abfd, _bfd_canonicalize_symtab, (abfd, location))
34799 +
34800 +bfd_boolean bfd_set_symtab
34801 + (bfd *abfd, asymbol **location, unsigned int count);
34802 +
34803 +void bfd_print_symbol_vandf (bfd *abfd, void *file, asymbol *symbol);
34804 +
34805 +#define bfd_make_empty_symbol(abfd) \
34806 + BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd))
34807 +
34808 +asymbol *_bfd_generic_make_empty_symbol (bfd *);
34809 +
34810 +#define bfd_make_debug_symbol(abfd,ptr,size) \
34811 + BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd, ptr, size))
34812 +
34813 +int bfd_decode_symclass (asymbol *symbol);
34814 +
34815 +bfd_boolean bfd_is_undefined_symclass (int symclass);
34816 +
34817 +void bfd_symbol_info (asymbol *symbol, symbol_info *ret);
34818 +
34819 +bfd_boolean bfd_copy_private_symbol_data
34820 + (bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym);
34821 +
34822 +#define bfd_copy_private_symbol_data(ibfd, isymbol, obfd, osymbol) \
34823 + BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
34824 + (ibfd, isymbol, obfd, osymbol))
34825 +
34826 +/* Extracted from bfd.c. */
34827 +struct bfd
34828 +{
34829 + /* A unique identifier of the BFD */
34830 + unsigned int id;
34831 +
34832 + /* The filename the application opened the BFD with. */
34833 + const char *filename;
34834 +
34835 + /* A pointer to the target jump table. */
34836 + const struct bfd_target *xvec;
34837 +
34838 + /* The IOSTREAM, and corresponding IO vector that provide access
34839 + to the file backing the BFD. */
34840 + void *iostream;
34841 + const struct bfd_iovec *iovec;
34842 +
34843 + /* Is the file descriptor being cached? That is, can it be closed as
34844 + needed, and re-opened when accessed later? */
34845 + bfd_boolean cacheable;
34846 +
34847 + /* Marks whether there was a default target specified when the
34848 + BFD was opened. This is used to select which matching algorithm
34849 + to use to choose the back end. */
34850 + bfd_boolean target_defaulted;
34851 +
34852 + /* The caching routines use these to maintain a
34853 + least-recently-used list of BFDs. */
34854 + struct bfd *lru_prev, *lru_next;
34855 +
34856 + /* When a file is closed by the caching routines, BFD retains
34857 + state information on the file here... */
34858 + ufile_ptr where;
34859 +
34860 + /* ... and here: (``once'' means at least once). */
34861 + bfd_boolean opened_once;
34862 +
34863 + /* Set if we have a locally maintained mtime value, rather than
34864 + getting it from the file each time. */
34865 + bfd_boolean mtime_set;
34866 +
34867 + /* File modified time, if mtime_set is TRUE. */
34868 + long mtime;
34869 +
34870 + /* Reserved for an unimplemented file locking extension. */
34871 + int ifd;
34872 +
34873 + /* The format which belongs to the BFD. (object, core, etc.) */
34874 + bfd_format format;
34875 +
34876 + /* The direction with which the BFD was opened. */
34877 + enum bfd_direction
34878 + {
34879 + no_direction = 0,
34880 + read_direction = 1,
34881 + write_direction = 2,
34882 + both_direction = 3
34883 + }
34884 + direction;
34885 +
34886 + /* Format_specific flags. */
34887 + flagword flags;
34888 +
34889 + /* Currently my_archive is tested before adding origin to
34890 + anything. I believe that this can become always an add of
34891 + origin, with origin set to 0 for non archive files. */
34892 + ufile_ptr origin;
34893 +
34894 + /* Remember when output has begun, to stop strange things
34895 + from happening. */
34896 + bfd_boolean output_has_begun;
34897 +
34898 + /* A hash table for section names. */
34899 + struct bfd_hash_table section_htab;
34900 +
34901 + /* Pointer to linked list of sections. */
34902 + struct bfd_section *sections;
34903 +
34904 + /* The last section on the section list. */
34905 + struct bfd_section *section_last;
34906 +
34907 + /* The number of sections. */
34908 + unsigned int section_count;
34909 +
34910 + /* Stuff only useful for object files:
34911 + The start address. */
34912 + bfd_vma start_address;
34913 +
34914 + /* Used for input and output. */
34915 + unsigned int symcount;
34916 +
34917 + /* Symbol table for output BFD (with symcount entries). */
34918 + struct bfd_symbol **outsymbols;
34919 +
34920 + /* Used for slurped dynamic symbol tables. */
34921 + unsigned int dynsymcount;
34922 +
34923 + /* Pointer to structure which contains architecture information. */
34924 + const struct bfd_arch_info *arch_info;
34925 +
34926 + /* Flag set if symbols from this BFD should not be exported. */
34927 + bfd_boolean no_export;
34928 +
34929 + /* Stuff only useful for archives. */
34930 + void *arelt_data;
34931 + struct bfd *my_archive; /* The containing archive BFD. */
34932 + struct bfd *archive_next; /* The next BFD in the archive. */
34933 + struct bfd *archive_head; /* The first BFD in the archive. */
34934 + bfd_boolean has_armap;
34935 +
34936 + /* A chain of BFD structures involved in a link. */
34937 + struct bfd *link_next;
34938 +
34939 + /* A field used by _bfd_generic_link_add_archive_symbols. This will
34940 + be used only for archive elements. */
34941 + int archive_pass;
34942 +
34943 + /* Used by the back end to hold private data. */
34944 + union
34945 + {
34946 + struct aout_data_struct *aout_data;
34947 + struct artdata *aout_ar_data;
34948 + struct _oasys_data *oasys_obj_data;
34949 + struct _oasys_ar_data *oasys_ar_data;
34950 + struct coff_tdata *coff_obj_data;
34951 + struct pe_tdata *pe_obj_data;
34952 + struct xcoff_tdata *xcoff_obj_data;
34953 + struct ecoff_tdata *ecoff_obj_data;
34954 + struct ieee_data_struct *ieee_data;
34955 + struct ieee_ar_data_struct *ieee_ar_data;
34956 + struct srec_data_struct *srec_data;
34957 + struct ihex_data_struct *ihex_data;
34958 + struct tekhex_data_struct *tekhex_data;
34959 + struct elf_obj_tdata *elf_obj_data;
34960 + struct nlm_obj_tdata *nlm_obj_data;
34961 + struct bout_data_struct *bout_data;
34962 + struct mmo_data_struct *mmo_data;
34963 + struct sun_core_struct *sun_core_data;
34964 + struct sco5_core_struct *sco5_core_data;
34965 + struct trad_core_struct *trad_core_data;
34966 + struct som_data_struct *som_data;
34967 + struct hpux_core_struct *hpux_core_data;
34968 + struct hppabsd_core_struct *hppabsd_core_data;
34969 + struct sgi_core_struct *sgi_core_data;
34970 + struct lynx_core_struct *lynx_core_data;
34971 + struct osf_core_struct *osf_core_data;
34972 + struct cisco_core_struct *cisco_core_data;
34973 + struct versados_data_struct *versados_data;
34974 + struct netbsd_core_struct *netbsd_core_data;
34975 + struct mach_o_data_struct *mach_o_data;
34976 + struct mach_o_fat_data_struct *mach_o_fat_data;
34977 + struct bfd_pef_data_struct *pef_data;
34978 + struct bfd_pef_xlib_data_struct *pef_xlib_data;
34979 + struct bfd_sym_data_struct *sym_data;
34980 + void *any;
34981 + }
34982 + tdata;
34983 +
34984 + /* Used by the application to hold private data. */
34985 + void *usrdata;
34986 +
34987 + /* Where all the allocated stuff under this BFD goes. This is a
34988 + struct objalloc *, but we use void * to avoid requiring the inclusion
34989 + of objalloc.h. */
34990 + void *memory;
34991 +};
34992 +
34993 +typedef enum bfd_error
34994 +{
34995 + bfd_error_no_error = 0,
34996 + bfd_error_system_call,
34997 + bfd_error_invalid_target,
34998 + bfd_error_wrong_format,
34999 + bfd_error_wrong_object_format,
35000 + bfd_error_invalid_operation,
35001 + bfd_error_no_memory,
35002 + bfd_error_no_symbols,
35003 + bfd_error_no_armap,
35004 + bfd_error_no_more_archived_files,
35005 + bfd_error_malformed_archive,
35006 + bfd_error_file_not_recognized,
35007 + bfd_error_file_ambiguously_recognized,
35008 + bfd_error_no_contents,
35009 + bfd_error_nonrepresentable_section,
35010 + bfd_error_no_debug_section,
35011 + bfd_error_bad_value,
35012 + bfd_error_file_truncated,
35013 + bfd_error_file_too_big,
35014 + bfd_error_on_input,
35015 + bfd_error_invalid_error_code
35016 +}
35017 +bfd_error_type;
35018 +
35019 +bfd_error_type bfd_get_error (void);
35020 +
35021 +void bfd_set_error (bfd_error_type error_tag, ...);
35022 +
35023 +const char *bfd_errmsg (bfd_error_type error_tag);
35024 +
35025 +void bfd_perror (const char *message);
35026 +
35027 +typedef void (*bfd_error_handler_type) (const char *, ...);
35028 +
35029 +bfd_error_handler_type bfd_set_error_handler (bfd_error_handler_type);
35030 +
35031 +void bfd_set_error_program_name (const char *);
35032 +
35033 +bfd_error_handler_type bfd_get_error_handler (void);
35034 +
35035 +long bfd_get_reloc_upper_bound (bfd *abfd, asection *sect);
35036 +
35037 +long bfd_canonicalize_reloc
35038 + (bfd *abfd, asection *sec, arelent **loc, asymbol **syms);
35039 +
35040 +void bfd_set_reloc
35041 + (bfd *abfd, asection *sec, arelent **rel, unsigned int count);
35042 +
35043 +bfd_boolean bfd_set_file_flags (bfd *abfd, flagword flags);
35044 +
35045 +int bfd_get_arch_size (bfd *abfd);
35046 +
35047 +int bfd_get_sign_extend_vma (bfd *abfd);
35048 +
35049 +bfd_boolean bfd_set_start_address (bfd *abfd, bfd_vma vma);
35050 +
35051 +unsigned int bfd_get_gp_size (bfd *abfd);
35052 +
35053 +void bfd_set_gp_size (bfd *abfd, unsigned int i);
35054 +
35055 +bfd_vma bfd_scan_vma (const char *string, const char **end, int base);
35056 +
35057 +bfd_boolean bfd_copy_private_header_data (bfd *ibfd, bfd *obfd);
35058 +
35059 +#define bfd_copy_private_header_data(ibfd, obfd) \
35060 + BFD_SEND (obfd, _bfd_copy_private_header_data, \
35061 + (ibfd, obfd))
35062 +bfd_boolean bfd_copy_private_bfd_data (bfd *ibfd, bfd *obfd);
35063 +
35064 +#define bfd_copy_private_bfd_data(ibfd, obfd) \
35065 + BFD_SEND (obfd, _bfd_copy_private_bfd_data, \
35066 + (ibfd, obfd))
35067 +bfd_boolean bfd_merge_private_bfd_data (bfd *ibfd, bfd *obfd);
35068 +
35069 +#define bfd_merge_private_bfd_data(ibfd, obfd) \
35070 + BFD_SEND (obfd, _bfd_merge_private_bfd_data, \
35071 + (ibfd, obfd))
35072 +bfd_boolean bfd_set_private_flags (bfd *abfd, flagword flags);
35073 +
35074 +#define bfd_set_private_flags(abfd, flags) \
35075 + BFD_SEND (abfd, _bfd_set_private_flags, (abfd, flags))
35076 +#define bfd_sizeof_headers(abfd, info) \
35077 + BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, info))
35078 +
35079 +#define bfd_find_nearest_line(abfd, sec, syms, off, file, func, line) \
35080 + BFD_SEND (abfd, _bfd_find_nearest_line, \
35081 + (abfd, sec, syms, off, file, func, line))
35082 +
35083 +#define bfd_find_line(abfd, syms, sym, file, line) \
35084 + BFD_SEND (abfd, _bfd_find_line, \
35085 + (abfd, syms, sym, file, line))
35086 +
35087 +#define bfd_find_inliner_info(abfd, file, func, line) \
35088 + BFD_SEND (abfd, _bfd_find_inliner_info, \
35089 + (abfd, file, func, line))
35090 +
35091 +#define bfd_debug_info_start(abfd) \
35092 + BFD_SEND (abfd, _bfd_debug_info_start, (abfd))
35093 +
35094 +#define bfd_debug_info_end(abfd) \
35095 + BFD_SEND (abfd, _bfd_debug_info_end, (abfd))
35096 +
35097 +#define bfd_debug_info_accumulate(abfd, section) \
35098 + BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section))
35099 +
35100 +#define bfd_stat_arch_elt(abfd, stat) \
35101 + BFD_SEND (abfd, _bfd_stat_arch_elt,(abfd, stat))
35102 +
35103 +#define bfd_update_armap_timestamp(abfd) \
35104 + BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd))
35105 +
35106 +#define bfd_set_arch_mach(abfd, arch, mach)\
35107 + BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach))
35108 +
35109 +#define bfd_relax_section(abfd, section, link_info, again) \
35110 + BFD_SEND (abfd, _bfd_relax_section, (abfd, section, link_info, again))
35111 +
35112 +#define bfd_gc_sections(abfd, link_info) \
35113 + BFD_SEND (abfd, _bfd_gc_sections, (abfd, link_info))
35114 +
35115 +#define bfd_merge_sections(abfd, link_info) \
35116 + BFD_SEND (abfd, _bfd_merge_sections, (abfd, link_info))
35117 +
35118 +#define bfd_is_group_section(abfd, sec) \
35119 + BFD_SEND (abfd, _bfd_is_group_section, (abfd, sec))
35120 +
35121 +#define bfd_discard_group(abfd, sec) \
35122 + BFD_SEND (abfd, _bfd_discard_group, (abfd, sec))
35123 +
35124 +#define bfd_link_hash_table_create(abfd) \
35125 + BFD_SEND (abfd, _bfd_link_hash_table_create, (abfd))
35126 +
35127 +#define bfd_link_hash_table_free(abfd, hash) \
35128 + BFD_SEND (abfd, _bfd_link_hash_table_free, (hash))
35129 +
35130 +#define bfd_link_add_symbols(abfd, info) \
35131 + BFD_SEND (abfd, _bfd_link_add_symbols, (abfd, info))
35132 +
35133 +#define bfd_link_just_syms(abfd, sec, info) \
35134 + BFD_SEND (abfd, _bfd_link_just_syms, (sec, info))
35135 +
35136 +#define bfd_final_link(abfd, info) \
35137 + BFD_SEND (abfd, _bfd_final_link, (abfd, info))
35138 +
35139 +#define bfd_free_cached_info(abfd) \
35140 + BFD_SEND (abfd, _bfd_free_cached_info, (abfd))
35141 +
35142 +#define bfd_get_dynamic_symtab_upper_bound(abfd) \
35143 + BFD_SEND (abfd, _bfd_get_dynamic_symtab_upper_bound, (abfd))
35144 +
35145 +#define bfd_print_private_bfd_data(abfd, file)\
35146 + BFD_SEND (abfd, _bfd_print_private_bfd_data, (abfd, file))
35147 +
35148 +#define bfd_canonicalize_dynamic_symtab(abfd, asymbols) \
35149 + BFD_SEND (abfd, _bfd_canonicalize_dynamic_symtab, (abfd, asymbols))
35150 +
35151 +#define bfd_get_synthetic_symtab(abfd, count, syms, dyncount, dynsyms, ret) \
35152 + BFD_SEND (abfd, _bfd_get_synthetic_symtab, (abfd, count, syms, \
35153 + dyncount, dynsyms, ret))
35154 +
35155 +#define bfd_get_dynamic_reloc_upper_bound(abfd) \
35156 + BFD_SEND (abfd, _bfd_get_dynamic_reloc_upper_bound, (abfd))
35157 +
35158 +#define bfd_canonicalize_dynamic_reloc(abfd, arels, asyms) \
35159 + BFD_SEND (abfd, _bfd_canonicalize_dynamic_reloc, (abfd, arels, asyms))
35160 +
35161 +extern bfd_byte *bfd_get_relocated_section_contents
35162 + (bfd *, struct bfd_link_info *, struct bfd_link_order *, bfd_byte *,
35163 + bfd_boolean, asymbol **);
35164 +
35165 +bfd_boolean bfd_alt_mach_code (bfd *abfd, int alternative);
35166 +
35167 +struct bfd_preserve
35168 +{
35169 + void *marker;
35170 + void *tdata;
35171 + flagword flags;
35172 + const struct bfd_arch_info *arch_info;
35173 + struct bfd_section *sections;
35174 + struct bfd_section *section_last;
35175 + unsigned int section_count;
35176 + struct bfd_hash_table section_htab;
35177 +};
35178 +
35179 +bfd_boolean bfd_preserve_save (bfd *, struct bfd_preserve *);
35180 +
35181 +void bfd_preserve_restore (bfd *, struct bfd_preserve *);
35182 +
35183 +void bfd_preserve_finish (bfd *, struct bfd_preserve *);
35184 +
35185 +bfd_vma bfd_emul_get_maxpagesize (const char *);
35186 +
35187 +void bfd_emul_set_maxpagesize (const char *, bfd_vma);
35188 +
35189 +bfd_vma bfd_emul_get_commonpagesize (const char *);
35190 +
35191 +void bfd_emul_set_commonpagesize (const char *, bfd_vma);
35192 +
35193 +char *bfd_demangle (bfd *, const char *, int);
35194 +
35195 +/* Extracted from archive.c. */
35196 +symindex bfd_get_next_mapent
35197 + (bfd *abfd, symindex previous, carsym **sym);
35198 +
35199 +bfd_boolean bfd_set_archive_head (bfd *output, bfd *new_head);
35200 +
35201 +bfd *bfd_openr_next_archived_file (bfd *archive, bfd *previous);
35202 +
35203 +/* Extracted from corefile.c. */
35204 +const char *bfd_core_file_failing_command (bfd *abfd);
35205 +
35206 +int bfd_core_file_failing_signal (bfd *abfd);
35207 +
35208 +bfd_boolean core_file_matches_executable_p
35209 + (bfd *core_bfd, bfd *exec_bfd);
35210 +
35211 +bfd_boolean generic_core_file_matches_executable_p
35212 + (bfd *core_bfd, bfd *exec_bfd);
35213 +
35214 +/* Extracted from targets.c. */
35215 +#define BFD_SEND(bfd, message, arglist) \
35216 + ((*((bfd)->xvec->message)) arglist)
35217 +
35218 +#ifdef DEBUG_BFD_SEND
35219 +#undef BFD_SEND
35220 +#define BFD_SEND(bfd, message, arglist) \
35221 + (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
35222 + ((*((bfd)->xvec->message)) arglist) : \
35223 + (bfd_assert (__FILE__,__LINE__), NULL))
35224 +#endif
35225 +#define BFD_SEND_FMT(bfd, message, arglist) \
35226 + (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist)
35227 +
35228 +#ifdef DEBUG_BFD_SEND
35229 +#undef BFD_SEND_FMT
35230 +#define BFD_SEND_FMT(bfd, message, arglist) \
35231 + (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
35232 + (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist) : \
35233 + (bfd_assert (__FILE__,__LINE__), NULL))
35234 +#endif
35235 +
35236 +enum bfd_flavour
35237 +{
35238 + bfd_target_unknown_flavour,
35239 + bfd_target_aout_flavour,
35240 + bfd_target_coff_flavour,
35241 + bfd_target_ecoff_flavour,
35242 + bfd_target_xcoff_flavour,
35243 + bfd_target_elf_flavour,
35244 + bfd_target_ieee_flavour,
35245 + bfd_target_nlm_flavour,
35246 + bfd_target_oasys_flavour,
35247 + bfd_target_tekhex_flavour,
35248 + bfd_target_srec_flavour,
35249 + bfd_target_ihex_flavour,
35250 + bfd_target_som_flavour,
35251 + bfd_target_os9k_flavour,
35252 + bfd_target_versados_flavour,
35253 + bfd_target_msdos_flavour,
35254 + bfd_target_ovax_flavour,
35255 + bfd_target_evax_flavour,
35256 + bfd_target_mmo_flavour,
35257 + bfd_target_mach_o_flavour,
35258 + bfd_target_pef_flavour,
35259 + bfd_target_pef_xlib_flavour,
35260 + bfd_target_sym_flavour
35261 +};
35262 +
35263 +enum bfd_endian { BFD_ENDIAN_BIG, BFD_ENDIAN_LITTLE, BFD_ENDIAN_UNKNOWN };
35264 +
35265 +/* Forward declaration. */
35266 +typedef struct bfd_link_info _bfd_link_info;
35267 +
35268 +typedef struct bfd_target
35269 +{
35270 + /* Identifies the kind of target, e.g., SunOS4, Ultrix, etc. */
35271 + char *name;
35272 +
35273 + /* The "flavour" of a back end is a general indication about
35274 + the contents of a file. */
35275 + enum bfd_flavour flavour;
35276 +
35277 + /* The order of bytes within the data area of a file. */
35278 + enum bfd_endian byteorder;
35279 +
35280 + /* The order of bytes within the header parts of a file. */
35281 + enum bfd_endian header_byteorder;
35282 +
35283 + /* A mask of all the flags which an executable may have set -
35284 + from the set <<BFD_NO_FLAGS>>, <<HAS_RELOC>>, ...<<D_PAGED>>. */
35285 + flagword object_flags;
35286 +
35287 + /* A mask of all the flags which a section may have set - from
35288 + the set <<SEC_NO_FLAGS>>, <<SEC_ALLOC>>, ...<<SET_NEVER_LOAD>>. */
35289 + flagword section_flags;
35290 +
35291 + /* The character normally found at the front of a symbol.
35292 + (if any), perhaps `_'. */
35293 + char symbol_leading_char;
35294 +
35295 + /* The pad character for file names within an archive header. */
35296 + char ar_pad_char;
35297 +
35298 + /* The maximum number of characters in an archive header. */
35299 + unsigned short ar_max_namelen;
35300 +
35301 + /* Entries for byte swapping for data. These are different from the
35302 + other entry points, since they don't take a BFD as the first argument.
35303 + Certain other handlers could do the same. */
35304 + bfd_uint64_t (*bfd_getx64) (const void *);
35305 + bfd_int64_t (*bfd_getx_signed_64) (const void *);
35306 + void (*bfd_putx64) (bfd_uint64_t, void *);
35307 + bfd_vma (*bfd_getx32) (const void *);
35308 + bfd_signed_vma (*bfd_getx_signed_32) (const void *);
35309 + void (*bfd_putx32) (bfd_vma, void *);
35310 + bfd_vma (*bfd_getx16) (const void *);
35311 + bfd_signed_vma (*bfd_getx_signed_16) (const void *);
35312 + void (*bfd_putx16) (bfd_vma, void *);
35313 +
35314 + /* Byte swapping for the headers. */
35315 + bfd_uint64_t (*bfd_h_getx64) (const void *);
35316 + bfd_int64_t (*bfd_h_getx_signed_64) (const void *);
35317 + void (*bfd_h_putx64) (bfd_uint64_t, void *);
35318 + bfd_vma (*bfd_h_getx32) (const void *);
35319 + bfd_signed_vma (*bfd_h_getx_signed_32) (const void *);
35320 + void (*bfd_h_putx32) (bfd_vma, void *);
35321 + bfd_vma (*bfd_h_getx16) (const void *);
35322 + bfd_signed_vma (*bfd_h_getx_signed_16) (const void *);
35323 + void (*bfd_h_putx16) (bfd_vma, void *);
35324 +
35325 + /* Format dependent routines: these are vectors of entry points
35326 + within the target vector structure, one for each format to check. */
35327 +
35328 + /* Check the format of a file being read. Return a <<bfd_target *>> or zero. */
35329 + const struct bfd_target *(*_bfd_check_format[bfd_type_end]) (bfd *);
35330 +
35331 + /* Set the format of a file being written. */
35332 + bfd_boolean (*_bfd_set_format[bfd_type_end]) (bfd *);
35333 +
35334 + /* Write cached information into a file being written, at <<bfd_close>>. */
35335 + bfd_boolean (*_bfd_write_contents[bfd_type_end]) (bfd *);
35336 +
35337 +
35338 + /* Generic entry points. */
35339 +#define BFD_JUMP_TABLE_GENERIC(NAME) \
35340 + NAME##_close_and_cleanup, \
35341 + NAME##_bfd_free_cached_info, \
35342 + NAME##_new_section_hook, \
35343 + NAME##_get_section_contents, \
35344 + NAME##_get_section_contents_in_window
35345 +
35346 + /* Called when the BFD is being closed to do any necessary cleanup. */
35347 + bfd_boolean (*_close_and_cleanup) (bfd *);
35348 + /* Ask the BFD to free all cached information. */
35349 + bfd_boolean (*_bfd_free_cached_info) (bfd *);
35350 + /* Called when a new section is created. */
35351 + bfd_boolean (*_new_section_hook) (bfd *, sec_ptr);
35352 + /* Read the contents of a section. */
35353 + bfd_boolean (*_bfd_get_section_contents)
35354 + (bfd *, sec_ptr, void *, file_ptr, bfd_size_type);
35355 + bfd_boolean (*_bfd_get_section_contents_in_window)
35356 + (bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type);
35357 +
35358 + /* Entry points to copy private data. */
35359 +#define BFD_JUMP_TABLE_COPY(NAME) \
35360 + NAME##_bfd_copy_private_bfd_data, \
35361 + NAME##_bfd_merge_private_bfd_data, \
35362 + _bfd_generic_init_private_section_data, \
35363 + NAME##_bfd_copy_private_section_data, \
35364 + NAME##_bfd_copy_private_symbol_data, \
35365 + NAME##_bfd_copy_private_header_data, \
35366 + NAME##_bfd_set_private_flags, \
35367 + NAME##_bfd_print_private_bfd_data
35368 +
35369 + /* Called to copy BFD general private data from one object file
35370 + to another. */
35371 + bfd_boolean (*_bfd_copy_private_bfd_data) (bfd *, bfd *);
35372 + /* Called to merge BFD general private data from one object file
35373 + to a common output file when linking. */
35374 + bfd_boolean (*_bfd_merge_private_bfd_data) (bfd *, bfd *);
35375 + /* Called to initialize BFD private section data from one object file
35376 + to another. */
35377 +#define bfd_init_private_section_data(ibfd, isec, obfd, osec, link_info) \
35378 + BFD_SEND (obfd, _bfd_init_private_section_data, (ibfd, isec, obfd, osec, link_info))
35379 + bfd_boolean (*_bfd_init_private_section_data)
35380 + (bfd *, sec_ptr, bfd *, sec_ptr, struct bfd_link_info *);
35381 + /* Called to copy BFD private section data from one object file
35382 + to another. */
35383 + bfd_boolean (*_bfd_copy_private_section_data)
35384 + (bfd *, sec_ptr, bfd *, sec_ptr);
35385 + /* Called to copy BFD private symbol data from one symbol
35386 + to another. */
35387 + bfd_boolean (*_bfd_copy_private_symbol_data)
35388 + (bfd *, asymbol *, bfd *, asymbol *);
35389 + /* Called to copy BFD private header data from one object file
35390 + to another. */
35391 + bfd_boolean (*_bfd_copy_private_header_data)
35392 + (bfd *, bfd *);
35393 + /* Called to set private backend flags. */
35394 + bfd_boolean (*_bfd_set_private_flags) (bfd *, flagword);
35395 +
35396 + /* Called to print private BFD data. */
35397 + bfd_boolean (*_bfd_print_private_bfd_data) (bfd *, void *);
35398 +
35399 + /* Core file entry points. */
35400 +#define BFD_JUMP_TABLE_CORE(NAME) \
35401 + NAME##_core_file_failing_command, \
35402 + NAME##_core_file_failing_signal, \
35403 + NAME##_core_file_matches_executable_p
35404 +
35405 + char * (*_core_file_failing_command) (bfd *);
35406 + int (*_core_file_failing_signal) (bfd *);
35407 + bfd_boolean (*_core_file_matches_executable_p) (bfd *, bfd *);
35408 +
35409 + /* Archive entry points. */
35410 +#define BFD_JUMP_TABLE_ARCHIVE(NAME) \
35411 + NAME##_slurp_armap, \
35412 + NAME##_slurp_extended_name_table, \
35413 + NAME##_construct_extended_name_table, \
35414 + NAME##_truncate_arname, \
35415 + NAME##_write_armap, \
35416 + NAME##_read_ar_hdr, \
35417 + NAME##_openr_next_archived_file, \
35418 + NAME##_get_elt_at_index, \
35419 + NAME##_generic_stat_arch_elt, \
35420 + NAME##_update_armap_timestamp
35421 +
35422 + bfd_boolean (*_bfd_slurp_armap) (bfd *);
35423 + bfd_boolean (*_bfd_slurp_extended_name_table) (bfd *);
35424 + bfd_boolean (*_bfd_construct_extended_name_table)
35425 + (bfd *, char **, bfd_size_type *, const char **);
35426 + void (*_bfd_truncate_arname) (bfd *, const char *, char *);
35427 + bfd_boolean (*write_armap)
35428 + (bfd *, unsigned int, struct orl *, unsigned int, int);
35429 + void * (*_bfd_read_ar_hdr_fn) (bfd *);
35430 + bfd * (*openr_next_archived_file) (bfd *, bfd *);
35431 +#define bfd_get_elt_at_index(b,i) BFD_SEND (b, _bfd_get_elt_at_index, (b,i))
35432 + bfd * (*_bfd_get_elt_at_index) (bfd *, symindex);
35433 + int (*_bfd_stat_arch_elt) (bfd *, struct stat *);
35434 + bfd_boolean (*_bfd_update_armap_timestamp) (bfd *);
35435 +
35436 + /* Entry points used for symbols. */
35437 +#define BFD_JUMP_TABLE_SYMBOLS(NAME) \
35438 + NAME##_get_symtab_upper_bound, \
35439 + NAME##_canonicalize_symtab, \
35440 + NAME##_make_empty_symbol, \
35441 + NAME##_print_symbol, \
35442 + NAME##_get_symbol_info, \
35443 + NAME##_bfd_is_local_label_name, \
35444 + NAME##_bfd_is_target_special_symbol, \
35445 + NAME##_get_lineno, \
35446 + NAME##_find_nearest_line, \
35447 + _bfd_generic_find_line, \
35448 + NAME##_find_inliner_info, \
35449 + NAME##_bfd_make_debug_symbol, \
35450 + NAME##_read_minisymbols, \
35451 + NAME##_minisymbol_to_symbol
35452 +
35453 + long (*_bfd_get_symtab_upper_bound) (bfd *);
35454 + long (*_bfd_canonicalize_symtab)
35455 + (bfd *, struct bfd_symbol **);
35456 + struct bfd_symbol *
35457 + (*_bfd_make_empty_symbol) (bfd *);
35458 + void (*_bfd_print_symbol)
35459 + (bfd *, void *, struct bfd_symbol *, bfd_print_symbol_type);
35460 +#define bfd_print_symbol(b,p,s,e) BFD_SEND (b, _bfd_print_symbol, (b,p,s,e))
35461 + void (*_bfd_get_symbol_info)
35462 + (bfd *, struct bfd_symbol *, symbol_info *);
35463 +#define bfd_get_symbol_info(b,p,e) BFD_SEND (b, _bfd_get_symbol_info, (b,p,e))
35464 + bfd_boolean (*_bfd_is_local_label_name) (bfd *, const char *);
35465 + bfd_boolean (*_bfd_is_target_special_symbol) (bfd *, asymbol *);
35466 + alent * (*_get_lineno) (bfd *, struct bfd_symbol *);
35467 + bfd_boolean (*_bfd_find_nearest_line)
35468 + (bfd *, struct bfd_section *, struct bfd_symbol **, bfd_vma,
35469 + const char **, const char **, unsigned int *);
35470 + bfd_boolean (*_bfd_find_line)
35471 + (bfd *, struct bfd_symbol **, struct bfd_symbol *,
35472 + const char **, unsigned int *);
35473 + bfd_boolean (*_bfd_find_inliner_info)
35474 + (bfd *, const char **, const char **, unsigned int *);
35475 + /* Back-door to allow format-aware applications to create debug symbols
35476 + while using BFD for everything else. Currently used by the assembler
35477 + when creating COFF files. */
35478 + asymbol * (*_bfd_make_debug_symbol)
35479 + (bfd *, void *, unsigned long size);
35480 +#define bfd_read_minisymbols(b, d, m, s) \
35481 + BFD_SEND (b, _read_minisymbols, (b, d, m, s))
35482 + long (*_read_minisymbols)
35483 + (bfd *, bfd_boolean, void **, unsigned int *);
35484 +#define bfd_minisymbol_to_symbol(b, d, m, f) \
35485 + BFD_SEND (b, _minisymbol_to_symbol, (b, d, m, f))
35486 + asymbol * (*_minisymbol_to_symbol)
35487 + (bfd *, bfd_boolean, const void *, asymbol *);
35488 +
35489 + /* Routines for relocs. */
35490 +#define BFD_JUMP_TABLE_RELOCS(NAME) \
35491 + NAME##_get_reloc_upper_bound, \
35492 + NAME##_canonicalize_reloc, \
35493 + NAME##_bfd_reloc_type_lookup, \
35494 + NAME##_bfd_reloc_name_lookup
35495 +
35496 + long (*_get_reloc_upper_bound) (bfd *, sec_ptr);
35497 + long (*_bfd_canonicalize_reloc)
35498 + (bfd *, sec_ptr, arelent **, struct bfd_symbol **);
35499 + /* See documentation on reloc types. */
35500 + reloc_howto_type *
35501 + (*reloc_type_lookup) (bfd *, bfd_reloc_code_real_type);
35502 + reloc_howto_type *
35503 + (*reloc_name_lookup) (bfd *, const char *);
35504 +
35505 +
35506 + /* Routines used when writing an object file. */
35507 +#define BFD_JUMP_TABLE_WRITE(NAME) \
35508 + NAME##_set_arch_mach, \
35509 + NAME##_set_section_contents
35510 +
35511 + bfd_boolean (*_bfd_set_arch_mach)
35512 + (bfd *, enum bfd_architecture, unsigned long);
35513 + bfd_boolean (*_bfd_set_section_contents)
35514 + (bfd *, sec_ptr, const void *, file_ptr, bfd_size_type);
35515 +
35516 + /* Routines used by the linker. */
35517 +#define BFD_JUMP_TABLE_LINK(NAME) \
35518 + NAME##_sizeof_headers, \
35519 + NAME##_bfd_get_relocated_section_contents, \
35520 + NAME##_bfd_relax_section, \
35521 + NAME##_bfd_link_hash_table_create, \
35522 + NAME##_bfd_link_hash_table_free, \
35523 + NAME##_bfd_link_add_symbols, \
35524 + NAME##_bfd_link_just_syms, \
35525 + NAME##_bfd_final_link, \
35526 + NAME##_bfd_link_split_section, \
35527 + NAME##_bfd_gc_sections, \
35528 + NAME##_bfd_merge_sections, \
35529 + NAME##_bfd_is_group_section, \
35530 + NAME##_bfd_discard_group, \
35531 + NAME##_section_already_linked \
35532 +
35533 + int (*_bfd_sizeof_headers) (bfd *, struct bfd_link_info *);
35534 + bfd_byte * (*_bfd_get_relocated_section_contents)
35535 + (bfd *, struct bfd_link_info *, struct bfd_link_order *,
35536 + bfd_byte *, bfd_boolean, struct bfd_symbol **);
35537 +
35538 + bfd_boolean (*_bfd_relax_section)
35539 + (bfd *, struct bfd_section *, struct bfd_link_info *, bfd_boolean *);
35540 +
35541 + /* Create a hash table for the linker. Different backends store
35542 + different information in this table. */
35543 + struct bfd_link_hash_table *
35544 + (*_bfd_link_hash_table_create) (bfd *);
35545 +
35546 + /* Release the memory associated with the linker hash table. */
35547 + void (*_bfd_link_hash_table_free) (struct bfd_link_hash_table *);
35548 +
35549 + /* Add symbols from this object file into the hash table. */
35550 + bfd_boolean (*_bfd_link_add_symbols) (bfd *, struct bfd_link_info *);
35551 +
35552 + /* Indicate that we are only retrieving symbol values from this section. */
35553 + void (*_bfd_link_just_syms) (asection *, struct bfd_link_info *);
35554 +
35555 + /* Do a link based on the link_order structures attached to each
35556 + section of the BFD. */
35557 + bfd_boolean (*_bfd_final_link) (bfd *, struct bfd_link_info *);
35558 +
35559 + /* Should this section be split up into smaller pieces during linking. */
35560 + bfd_boolean (*_bfd_link_split_section) (bfd *, struct bfd_section *);
35561 +
35562 + /* Remove sections that are not referenced from the output. */
35563 + bfd_boolean (*_bfd_gc_sections) (bfd *, struct bfd_link_info *);
35564 +
35565 + /* Attempt to merge SEC_MERGE sections. */
35566 + bfd_boolean (*_bfd_merge_sections) (bfd *, struct bfd_link_info *);
35567 +
35568 + /* Is this section a member of a group? */
35569 + bfd_boolean (*_bfd_is_group_section) (bfd *, const struct bfd_section *);
35570 +
35571 + /* Discard members of a group. */
35572 + bfd_boolean (*_bfd_discard_group) (bfd *, struct bfd_section *);
35573 +
35574 + /* Check if SEC has been already linked during a reloceatable or
35575 + final link. */
35576 + void (*_section_already_linked) (bfd *, struct bfd_section *,
35577 + struct bfd_link_info *);
35578 +
35579 + /* Routines to handle dynamic symbols and relocs. */
35580 +#define BFD_JUMP_TABLE_DYNAMIC(NAME) \
35581 + NAME##_get_dynamic_symtab_upper_bound, \
35582 + NAME##_canonicalize_dynamic_symtab, \
35583 + NAME##_get_synthetic_symtab, \
35584 + NAME##_get_dynamic_reloc_upper_bound, \
35585 + NAME##_canonicalize_dynamic_reloc
35586 +
35587 + /* Get the amount of memory required to hold the dynamic symbols. */
35588 + long (*_bfd_get_dynamic_symtab_upper_bound) (bfd *);
35589 + /* Read in the dynamic symbols. */
35590 + long (*_bfd_canonicalize_dynamic_symtab)
35591 + (bfd *, struct bfd_symbol **);
35592 + /* Create synthetized symbols. */
35593 + long (*_bfd_get_synthetic_symtab)
35594 + (bfd *, long, struct bfd_symbol **, long, struct bfd_symbol **,
35595 + struct bfd_symbol **);
35596 + /* Get the amount of memory required to hold the dynamic relocs. */
35597 + long (*_bfd_get_dynamic_reloc_upper_bound) (bfd *);
35598 + /* Read in the dynamic relocs. */
35599 + long (*_bfd_canonicalize_dynamic_reloc)
35600 + (bfd *, arelent **, struct bfd_symbol **);
35601 +
35602 + /* Opposite endian version of this target. */
35603 + const struct bfd_target * alternative_target;
35604 +
35605 + /* Data for use by back-end routines, which isn't
35606 + generic enough to belong in this structure. */
35607 + const void *backend_data;
35608 +
35609 +} bfd_target;
35610 +
35611 +bfd_boolean bfd_set_default_target (const char *name);
35612 +
35613 +const bfd_target *bfd_find_target (const char *target_name, bfd *abfd);
35614 +
35615 +const char ** bfd_target_list (void);
35616 +
35617 +const bfd_target *bfd_search_for_target
35618 + (int (*search_func) (const bfd_target *, void *),
35619 + void *);
35620 +
35621 +/* Extracted from format.c. */
35622 +bfd_boolean bfd_check_format (bfd *abfd, bfd_format format);
35623 +
35624 +bfd_boolean bfd_check_format_matches
35625 + (bfd *abfd, bfd_format format, char ***matching);
35626 +
35627 +bfd_boolean bfd_set_format (bfd *abfd, bfd_format format);
35628 +
35629 +const char *bfd_format_string (bfd_format format);
35630 +
35631 +/* Extracted from linker.c. */
35632 +bfd_boolean bfd_link_split_section (bfd *abfd, asection *sec);
35633 +
35634 +#define bfd_link_split_section(abfd, sec) \
35635 + BFD_SEND (abfd, _bfd_link_split_section, (abfd, sec))
35636 +
35637 +void bfd_section_already_linked (bfd *abfd, asection *sec,
35638 + struct bfd_link_info *info);
35639 +
35640 +#define bfd_section_already_linked(abfd, sec, info) \
35641 + BFD_SEND (abfd, _section_already_linked, (abfd, sec, info))
35642 +
35643 +/* Extracted from simple.c. */
35644 +bfd_byte *bfd_simple_get_relocated_section_contents
35645 + (bfd *abfd, asection *sec, bfd_byte *outbuf, asymbol **symbol_table);
35646 +
35647 +#ifdef __cplusplus
35648 +}
35649 +#endif
35650 +#endif
35651 --- /dev/null
35652 +++ b/bfd/bfd_stdint.h
35653 @@ -0,0 +1,47 @@
35654 +/* generated for gcc (GCC) 4.2.4 (Ubuntu 4.2.4-3ubuntu4) */
35655 +
35656 +#ifndef GCC_GENERATED_STDINT_H
35657 +#define GCC_GENERATED_STDINT_H 1
35658 +
35659 +#include <sys/types.h>
35660 +#include <stdint.h>
35661 +/* glibc uses these symbols as guards to prevent redefinitions. */
35662 +#ifdef __int8_t_defined
35663 +#define _INT8_T
35664 +#define _INT16_T
35665 +#define _INT32_T
35666 +#endif
35667 +#ifdef __uint32_t_defined
35668 +#define _UINT32_T
35669 +#endif
35670 +
35671 +
35672 +/* Some systems have guard macros to prevent redefinitions, define them. */
35673 +#ifndef _INT8_T
35674 +#define _INT8_T
35675 +#endif
35676 +#ifndef _INT16_T
35677 +#define _INT16_T
35678 +#endif
35679 +#ifndef _INT32_T
35680 +#define _INT32_T
35681 +#endif
35682 +#ifndef _UINT8_T
35683 +#define _UINT8_T
35684 +#endif
35685 +#ifndef _UINT16_T
35686 +#define _UINT16_T
35687 +#endif
35688 +#ifndef _UINT32_T
35689 +#define _UINT32_T
35690 +#endif
35691 +
35692 +/* system headers have good uint64_t and int64_t */
35693 +#ifndef _INT64_T
35694 +#define _INT64_T
35695 +#endif
35696 +#ifndef _UINT64_T
35697 +#define _UINT64_T
35698 +#endif
35699 +
35700 +#endif /* GCC_GENERATED_STDINT_H */
35701 --- a/bfd/configure
35702 +++ b/bfd/configure
35703 @@ -19041,6 +19041,7 @@ do
35704 bfd_efi_app_ia64_vec) tb="$tb efi-app-ia64.lo pepigen.lo cofflink.lo"; target_size=64 ;;
35705 bfd_elf32_am33lin_vec) tb="$tb elf32-am33lin.lo elf32.lo $elf" ;;
35706 bfd_elf32_avr_vec) tb="$tb elf32-avr.lo elf32.lo $elf" ;;
35707 + bfd_elf32_avr32_vec) tb="$tb elf32-avr32.lo elf32.lo $elf" ;;
35708 bfd_elf32_bfin_vec) tb="$tb elf32-bfin.lo elf32.lo $elf" ;;
35709 bfd_elf32_bfinfdpic_vec) tb="$tb elf32-bfin.lo elf32.lo $elf" ;;
35710 bfd_elf32_big_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
35711 --- /dev/null
35712 +++ b/bfd/doc/bfd.h
35713 @@ -0,0 +1,5493 @@
35714 +/* DO NOT EDIT! -*- buffer-read-only: t -*- This file is automatically
35715 + generated from "bfd-in.h", "init.c", "opncls.c", "libbfd.c",
35716 + "bfdio.c", "bfdwin.c", "section.c", "archures.c", "reloc.c",
35717 + "syms.c", "bfd.c", "archive.c", "corefile.c", "targets.c", "format.c",
35718 + "linker.c" and "simple.c".
35719 + Run "make headers" in your build bfd/ to regenerate. */
35720 +
35721 +/* Main header file for the bfd library -- portable access to object files.
35722 +
35723 + Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
35724 + 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
35725 + Free Software Foundation, Inc.
35726 +
35727 + Contributed by Cygnus Support.
35728 +
35729 + This file is part of BFD, the Binary File Descriptor library.
35730 +
35731 + This program is free software; you can redistribute it and/or modify
35732 + it under the terms of the GNU General Public License as published by
35733 + the Free Software Foundation; either version 3 of the License, or
35734 + (at your option) any later version.
35735 +
35736 + This program is distributed in the hope that it will be useful,
35737 + but WITHOUT ANY WARRANTY; without even the implied warranty of
35738 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
35739 + GNU General Public License for more details.
35740 +
35741 + You should have received a copy of the GNU General Public License
35742 + along with this program; if not, write to the Free Software
35743 + Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */
35744 +
35745 +#ifndef __BFD_H_SEEN__
35746 +#define __BFD_H_SEEN__
35747 +
35748 +#ifdef __cplusplus
35749 +extern "C" {
35750 +#endif
35751 +
35752 +#include "ansidecl.h"
35753 +#include "symcat.h"
35754 +#if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
35755 +#ifndef SABER
35756 +/* This hack is to avoid a problem with some strict ANSI C preprocessors.
35757 + The problem is, "32_" is not a valid preprocessing token, and we don't
35758 + want extra underscores (e.g., "nlm_32_"). The XCONCAT2 macro will
35759 + cause the inner CONCAT2 macros to be evaluated first, producing
35760 + still-valid pp-tokens. Then the final concatenation can be done. */
35761 +#undef CONCAT4
35762 +#define CONCAT4(a,b,c,d) XCONCAT2(CONCAT2(a,b),CONCAT2(c,d))
35763 +#endif
35764 +#endif
35765 +
35766 +/* This is a utility macro to handle the situation where the code
35767 + wants to place a constant string into the code, followed by a
35768 + comma and then the length of the string. Doing this by hand
35769 + is error prone, so using this macro is safer. The macro will
35770 + also safely handle the case where a NULL is passed as the arg. */
35771 +#define STRING_COMMA_LEN(STR) (STR), ((STR) ? sizeof (STR) - 1 : 0)
35772 +/* Unfortunately it is not possible to use the STRING_COMMA_LEN macro
35773 + to create the arguments to another macro, since the preprocessor
35774 + will mis-count the number of arguments to the outer macro (by not
35775 + evaluating STRING_COMMA_LEN and so missing the comma). This is a
35776 + problem for example when trying to use STRING_COMMA_LEN to build
35777 + the arguments to the strncmp() macro. Hence this alternative
35778 + definition of strncmp is provided here.
35779 +
35780 + Note - these macros do NOT work if STR2 is not a constant string. */
35781 +#define CONST_STRNEQ(STR1,STR2) (strncmp ((STR1), (STR2), sizeof (STR2) - 1) == 0)
35782 + /* strcpy() can have a similar problem, but since we know we are
35783 + copying a constant string, we can use memcpy which will be faster
35784 + since there is no need to check for a NUL byte inside STR. We
35785 + can also save time if we do not need to copy the terminating NUL. */
35786 +#define LITMEMCPY(DEST,STR2) memcpy ((DEST), (STR2), sizeof (STR2) - 1)
35787 +#define LITSTRCPY(DEST,STR2) memcpy ((DEST), (STR2), sizeof (STR2))
35788 +
35789 +
35790 +/* The word size used by BFD on the host. This may be 64 with a 32
35791 + bit target if the host is 64 bit, or if other 64 bit targets have
35792 + been selected with --enable-targets, or if --enable-64-bit-bfd. */
35793 +#define BFD_ARCH_SIZE @wordsize@
35794 +
35795 +/* The word size of the default bfd target. */
35796 +#define BFD_DEFAULT_TARGET_SIZE @bfd_default_target_size@
35797 +
35798 +#define BFD_HOST_64BIT_LONG @BFD_HOST_64BIT_LONG@
35799 +#define BFD_HOST_64BIT_LONG_LONG @BFD_HOST_64BIT_LONG_LONG@
35800 +#define BFD_HOST_LONG_LONG @BFD_HOST_LONG_LONG@
35801 +#if @BFD_HOST_64_BIT_DEFINED@
35802 +#define BFD_HOST_64_BIT @BFD_HOST_64_BIT@
35803 +#define BFD_HOST_U_64_BIT @BFD_HOST_U_64_BIT@
35804 +typedef BFD_HOST_64_BIT bfd_int64_t;
35805 +typedef BFD_HOST_U_64_BIT bfd_uint64_t;
35806 +#endif
35807 +
35808 +#if BFD_ARCH_SIZE >= 64
35809 +#define BFD64
35810 +#endif
35811 +
35812 +#ifndef INLINE
35813 +#if __GNUC__ >= 2
35814 +#define INLINE __inline__
35815 +#else
35816 +#define INLINE
35817 +#endif
35818 +#endif
35819 +
35820 +/* Declaring a type wide enough to hold a host long and a host pointer. */
35821 +#define BFD_HOSTPTR_T @BFD_HOSTPTR_T@
35822 +typedef BFD_HOSTPTR_T bfd_hostptr_t;
35823 +
35824 +/* Forward declaration. */
35825 +typedef struct bfd bfd;
35826 +
35827 +/* Boolean type used in bfd. Too many systems define their own
35828 + versions of "boolean" for us to safely typedef a "boolean" of
35829 + our own. Using an enum for "bfd_boolean" has its own set of
35830 + problems, with strange looking casts required to avoid warnings
35831 + on some older compilers. Thus we just use an int.
35832 +
35833 + General rule: Functions which are bfd_boolean return TRUE on
35834 + success and FALSE on failure (unless they're a predicate). */
35835 +
35836 +typedef int bfd_boolean;
35837 +#undef FALSE
35838 +#undef TRUE
35839 +#define FALSE 0
35840 +#define TRUE 1
35841 +
35842 +#ifdef BFD64
35843 +
35844 +#ifndef BFD_HOST_64_BIT
35845 + #error No 64 bit integer type available
35846 +#endif /* ! defined (BFD_HOST_64_BIT) */
35847 +
35848 +typedef BFD_HOST_U_64_BIT bfd_vma;
35849 +typedef BFD_HOST_64_BIT bfd_signed_vma;
35850 +typedef BFD_HOST_U_64_BIT bfd_size_type;
35851 +typedef BFD_HOST_U_64_BIT symvalue;
35852 +
35853 +#ifndef fprintf_vma
35854 +#if BFD_HOST_64BIT_LONG
35855 +#define sprintf_vma(s,x) sprintf (s, "%016lx", x)
35856 +#define fprintf_vma(f,x) fprintf (f, "%016lx", x)
35857 +#elif BFD_HOST_64BIT_LONG_LONG
35858 +#define sprintf_vma(s,x) sprintf (s, "%016llx", x)
35859 +#define fprintf_vma(f,x) fprintf (f, "%016llx", x)
35860 +#else
35861 +#define _bfd_int64_low(x) ((unsigned long) (((x) & 0xffffffff)))
35862 +#define _bfd_int64_high(x) ((unsigned long) (((x) >> 32) & 0xffffffff))
35863 +#define fprintf_vma(s,x) \
35864 + fprintf ((s), "%08lx%08lx", _bfd_int64_high (x), _bfd_int64_low (x))
35865 +#define sprintf_vma(s,x) \
35866 + sprintf ((s), "%08lx%08lx", _bfd_int64_high (x), _bfd_int64_low (x))
35867 +#endif
35868 +#endif
35869 +
35870 +#else /* not BFD64 */
35871 +
35872 +/* Represent a target address. Also used as a generic unsigned type
35873 + which is guaranteed to be big enough to hold any arithmetic types
35874 + we need to deal with. */
35875 +typedef unsigned long bfd_vma;
35876 +
35877 +/* A generic signed type which is guaranteed to be big enough to hold any
35878 + arithmetic types we need to deal with. Can be assumed to be compatible
35879 + with bfd_vma in the same way that signed and unsigned ints are compatible
35880 + (as parameters, in assignment, etc). */
35881 +typedef long bfd_signed_vma;
35882 +
35883 +typedef unsigned long symvalue;
35884 +typedef unsigned long bfd_size_type;
35885 +
35886 +/* Print a bfd_vma x on stream s. */
35887 +#define fprintf_vma(s,x) fprintf (s, "%08lx", x)
35888 +#define sprintf_vma(s,x) sprintf (s, "%08lx", x)
35889 +
35890 +#endif /* not BFD64 */
35891 +
35892 +#define HALF_BFD_SIZE_TYPE \
35893 + (((bfd_size_type) 1) << (8 * sizeof (bfd_size_type) / 2))
35894 +
35895 +#ifndef BFD_HOST_64_BIT
35896 +/* Fall back on a 32 bit type. The idea is to make these types always
35897 + available for function return types, but in the case that
35898 + BFD_HOST_64_BIT is undefined such a function should abort or
35899 + otherwise signal an error. */
35900 +typedef bfd_signed_vma bfd_int64_t;
35901 +typedef bfd_vma bfd_uint64_t;
35902 +#endif
35903 +
35904 +/* An offset into a file. BFD always uses the largest possible offset
35905 + based on the build time availability of fseek, fseeko, or fseeko64. */
35906 +typedef @bfd_file_ptr@ file_ptr;
35907 +typedef unsigned @bfd_file_ptr@ ufile_ptr;
35908 +
35909 +extern void bfd_sprintf_vma (bfd *, char *, bfd_vma);
35910 +extern void bfd_fprintf_vma (bfd *, void *, bfd_vma);
35911 +
35912 +#define printf_vma(x) fprintf_vma(stdout,x)
35913 +#define bfd_printf_vma(abfd,x) bfd_fprintf_vma (abfd,stdout,x)
35914 +
35915 +typedef unsigned int flagword; /* 32 bits of flags */
35916 +typedef unsigned char bfd_byte;
35917 +\f
35918 +/* File formats. */
35919 +
35920 +typedef enum bfd_format
35921 +{
35922 + bfd_unknown = 0, /* File format is unknown. */
35923 + bfd_object, /* Linker/assembler/compiler output. */
35924 + bfd_archive, /* Object archive file. */
35925 + bfd_core, /* Core dump. */
35926 + bfd_type_end /* Marks the end; don't use it! */
35927 +}
35928 +bfd_format;
35929 +
35930 +/* Values that may appear in the flags field of a BFD. These also
35931 + appear in the object_flags field of the bfd_target structure, where
35932 + they indicate the set of flags used by that backend (not all flags
35933 + are meaningful for all object file formats) (FIXME: at the moment,
35934 + the object_flags values have mostly just been copied from backend
35935 + to another, and are not necessarily correct). */
35936 +
35937 +/* No flags. */
35938 +#define BFD_NO_FLAGS 0x00
35939 +
35940 +/* BFD contains relocation entries. */
35941 +#define HAS_RELOC 0x01
35942 +
35943 +/* BFD is directly executable. */
35944 +#define EXEC_P 0x02
35945 +
35946 +/* BFD has line number information (basically used for F_LNNO in a
35947 + COFF header). */
35948 +#define HAS_LINENO 0x04
35949 +
35950 +/* BFD has debugging information. */
35951 +#define HAS_DEBUG 0x08
35952 +
35953 +/* BFD has symbols. */
35954 +#define HAS_SYMS 0x10
35955 +
35956 +/* BFD has local symbols (basically used for F_LSYMS in a COFF
35957 + header). */
35958 +#define HAS_LOCALS 0x20
35959 +
35960 +/* BFD is a dynamic object. */
35961 +#define DYNAMIC 0x40
35962 +
35963 +/* Text section is write protected (if D_PAGED is not set, this is
35964 + like an a.out NMAGIC file) (the linker sets this by default, but
35965 + clears it for -r or -N). */
35966 +#define WP_TEXT 0x80
35967 +
35968 +/* BFD is dynamically paged (this is like an a.out ZMAGIC file) (the
35969 + linker sets this by default, but clears it for -r or -n or -N). */
35970 +#define D_PAGED 0x100
35971 +
35972 +/* BFD is relaxable (this means that bfd_relax_section may be able to
35973 + do something) (sometimes bfd_relax_section can do something even if
35974 + this is not set). */
35975 +#define BFD_IS_RELAXABLE 0x200
35976 +
35977 +/* This may be set before writing out a BFD to request using a
35978 + traditional format. For example, this is used to request that when
35979 + writing out an a.out object the symbols not be hashed to eliminate
35980 + duplicates. */
35981 +#define BFD_TRADITIONAL_FORMAT 0x400
35982 +
35983 +/* This flag indicates that the BFD contents are actually cached in
35984 + memory. If this is set, iostream points to a bfd_in_memory struct. */
35985 +#define BFD_IN_MEMORY 0x800
35986 +
35987 +/* The sections in this BFD specify a memory page. */
35988 +#define HAS_LOAD_PAGE 0x1000
35989 +
35990 +/* This BFD has been created by the linker and doesn't correspond
35991 + to any input file. */
35992 +#define BFD_LINKER_CREATED 0x2000
35993 +\f
35994 +/* Symbols and relocation. */
35995 +
35996 +/* A count of carsyms (canonical archive symbols). */
35997 +typedef unsigned long symindex;
35998 +
35999 +/* How to perform a relocation. */
36000 +typedef const struct reloc_howto_struct reloc_howto_type;
36001 +
36002 +#define BFD_NO_MORE_SYMBOLS ((symindex) ~0)
36003 +
36004 +/* General purpose part of a symbol X;
36005 + target specific parts are in libcoff.h, libaout.h, etc. */
36006 +
36007 +#define bfd_get_section(x) ((x)->section)
36008 +#define bfd_get_output_section(x) ((x)->section->output_section)
36009 +#define bfd_set_section(x,y) ((x)->section) = (y)
36010 +#define bfd_asymbol_base(x) ((x)->section->vma)
36011 +#define bfd_asymbol_value(x) (bfd_asymbol_base(x) + (x)->value)
36012 +#define bfd_asymbol_name(x) ((x)->name)
36013 +/*Perhaps future: #define bfd_asymbol_bfd(x) ((x)->section->owner)*/
36014 +#define bfd_asymbol_bfd(x) ((x)->the_bfd)
36015 +#define bfd_asymbol_flavour(x) (bfd_asymbol_bfd(x)->xvec->flavour)
36016 +
36017 +/* A canonical archive symbol. */
36018 +/* This is a type pun with struct ranlib on purpose! */
36019 +typedef struct carsym
36020 +{
36021 + char *name;
36022 + file_ptr file_offset; /* Look here to find the file. */
36023 +}
36024 +carsym; /* To make these you call a carsymogen. */
36025 +
36026 +/* Used in generating armaps (archive tables of contents).
36027 + Perhaps just a forward definition would do? */
36028 +struct orl /* Output ranlib. */
36029 +{
36030 + char **name; /* Symbol name. */
36031 + union
36032 + {
36033 + file_ptr pos;
36034 + bfd *abfd;
36035 + } u; /* bfd* or file position. */
36036 + int namidx; /* Index into string table. */
36037 +};
36038 +\f
36039 +/* Linenumber stuff. */
36040 +typedef struct lineno_cache_entry
36041 +{
36042 + unsigned int line_number; /* Linenumber from start of function. */
36043 + union
36044 + {
36045 + struct bfd_symbol *sym; /* Function name. */
36046 + bfd_vma offset; /* Offset into section. */
36047 + } u;
36048 +}
36049 +alent;
36050 +\f
36051 +/* Object and core file sections. */
36052 +
36053 +#define align_power(addr, align) \
36054 + (((addr) + ((bfd_vma) 1 << (align)) - 1) & ((bfd_vma) -1 << (align)))
36055 +
36056 +typedef struct bfd_section *sec_ptr;
36057 +
36058 +#define bfd_get_section_name(bfd, ptr) ((ptr)->name + 0)
36059 +#define bfd_get_section_vma(bfd, ptr) ((ptr)->vma + 0)
36060 +#define bfd_get_section_lma(bfd, ptr) ((ptr)->lma + 0)
36061 +#define bfd_get_section_alignment(bfd, ptr) ((ptr)->alignment_power + 0)
36062 +#define bfd_section_name(bfd, ptr) ((ptr)->name)
36063 +#define bfd_section_size(bfd, ptr) ((ptr)->size)
36064 +#define bfd_get_section_size(ptr) ((ptr)->size)
36065 +#define bfd_section_vma(bfd, ptr) ((ptr)->vma)
36066 +#define bfd_section_lma(bfd, ptr) ((ptr)->lma)
36067 +#define bfd_section_alignment(bfd, ptr) ((ptr)->alignment_power)
36068 +#define bfd_get_section_flags(bfd, ptr) ((ptr)->flags + 0)
36069 +#define bfd_get_section_userdata(bfd, ptr) ((ptr)->userdata)
36070 +
36071 +#define bfd_is_com_section(ptr) (((ptr)->flags & SEC_IS_COMMON) != 0)
36072 +
36073 +#define bfd_set_section_vma(bfd, ptr, val) (((ptr)->vma = (ptr)->lma = (val)), ((ptr)->user_set_vma = TRUE), TRUE)
36074 +#define bfd_set_section_alignment(bfd, ptr, val) (((ptr)->alignment_power = (val)),TRUE)
36075 +#define bfd_set_section_userdata(bfd, ptr, val) (((ptr)->userdata = (val)),TRUE)
36076 +/* Find the address one past the end of SEC. */
36077 +#define bfd_get_section_limit(bfd, sec) \
36078 + (((sec)->rawsize ? (sec)->rawsize : (sec)->size) \
36079 + / bfd_octets_per_byte (bfd))
36080 +
36081 +/* Return TRUE if section has been discarded. */
36082 +#define elf_discarded_section(sec) \
36083 + (!bfd_is_abs_section (sec) \
36084 + && bfd_is_abs_section ((sec)->output_section) \
36085 + && (sec)->sec_info_type != ELF_INFO_TYPE_MERGE \
36086 + && (sec)->sec_info_type != ELF_INFO_TYPE_JUST_SYMS)
36087 +
36088 +/* Forward define. */
36089 +struct stat;
36090 +\f
36091 +typedef enum bfd_print_symbol
36092 +{
36093 + bfd_print_symbol_name,
36094 + bfd_print_symbol_more,
36095 + bfd_print_symbol_all
36096 +} bfd_print_symbol_type;
36097 +
36098 +/* Information about a symbol that nm needs. */
36099 +
36100 +typedef struct _symbol_info
36101 +{
36102 + symvalue value;
36103 + char type;
36104 + const char *name; /* Symbol name. */
36105 + unsigned char stab_type; /* Stab type. */
36106 + char stab_other; /* Stab other. */
36107 + short stab_desc; /* Stab desc. */
36108 + const char *stab_name; /* String for stab type. */
36109 +} symbol_info;
36110 +
36111 +/* Get the name of a stabs type code. */
36112 +
36113 +extern const char *bfd_get_stab_name (int);
36114 +\f
36115 +/* Hash table routines. There is no way to free up a hash table. */
36116 +
36117 +/* An element in the hash table. Most uses will actually use a larger
36118 + structure, and an instance of this will be the first field. */
36119 +
36120 +struct bfd_hash_entry
36121 +{
36122 + /* Next entry for this hash code. */
36123 + struct bfd_hash_entry *next;
36124 + /* String being hashed. */
36125 + const char *string;
36126 + /* Hash code. This is the full hash code, not the index into the
36127 + table. */
36128 + unsigned long hash;
36129 +};
36130 +
36131 +/* A hash table. */
36132 +
36133 +struct bfd_hash_table
36134 +{
36135 + /* The hash array. */
36136 + struct bfd_hash_entry **table;
36137 + /* A function used to create new elements in the hash table. The
36138 + first entry is itself a pointer to an element. When this
36139 + function is first invoked, this pointer will be NULL. However,
36140 + having the pointer permits a hierarchy of method functions to be
36141 + built each of which calls the function in the superclass. Thus
36142 + each function should be written to allocate a new block of memory
36143 + only if the argument is NULL. */
36144 + struct bfd_hash_entry *(*newfunc)
36145 + (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
36146 + /* An objalloc for this hash table. This is a struct objalloc *,
36147 + but we use void * to avoid requiring the inclusion of objalloc.h. */
36148 + void *memory;
36149 + /* The number of slots in the hash table. */
36150 + unsigned int size;
36151 + /* The number of entries in the hash table. */
36152 + unsigned int count;
36153 + /* The size of elements. */
36154 + unsigned int entsize;
36155 + /* If non-zero, don't grow the hash table. */
36156 + unsigned int frozen:1;
36157 +};
36158 +
36159 +/* Initialize a hash table. */
36160 +extern bfd_boolean bfd_hash_table_init
36161 + (struct bfd_hash_table *,
36162 + struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
36163 + struct bfd_hash_table *,
36164 + const char *),
36165 + unsigned int);
36166 +
36167 +/* Initialize a hash table specifying a size. */
36168 +extern bfd_boolean bfd_hash_table_init_n
36169 + (struct bfd_hash_table *,
36170 + struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
36171 + struct bfd_hash_table *,
36172 + const char *),
36173 + unsigned int, unsigned int);
36174 +
36175 +/* Free up a hash table. */
36176 +extern void bfd_hash_table_free
36177 + (struct bfd_hash_table *);
36178 +
36179 +/* Look up a string in a hash table. If CREATE is TRUE, a new entry
36180 + will be created for this string if one does not already exist. The
36181 + COPY argument must be TRUE if this routine should copy the string
36182 + into newly allocated memory when adding an entry. */
36183 +extern struct bfd_hash_entry *bfd_hash_lookup
36184 + (struct bfd_hash_table *, const char *, bfd_boolean create,
36185 + bfd_boolean copy);
36186 +
36187 +/* Replace an entry in a hash table. */
36188 +extern void bfd_hash_replace
36189 + (struct bfd_hash_table *, struct bfd_hash_entry *old,
36190 + struct bfd_hash_entry *nw);
36191 +
36192 +/* Base method for creating a hash table entry. */
36193 +extern struct bfd_hash_entry *bfd_hash_newfunc
36194 + (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
36195 +
36196 +/* Grab some space for a hash table entry. */
36197 +extern void *bfd_hash_allocate
36198 + (struct bfd_hash_table *, unsigned int);
36199 +
36200 +/* Traverse a hash table in a random order, calling a function on each
36201 + element. If the function returns FALSE, the traversal stops. The
36202 + INFO argument is passed to the function. */
36203 +extern void bfd_hash_traverse
36204 + (struct bfd_hash_table *,
36205 + bfd_boolean (*) (struct bfd_hash_entry *, void *),
36206 + void *info);
36207 +
36208 +/* Allows the default size of a hash table to be configured. New hash
36209 + tables allocated using bfd_hash_table_init will be created with
36210 + this size. */
36211 +extern void bfd_hash_set_default_size (bfd_size_type);
36212 +
36213 +/* This structure is used to keep track of stabs in sections
36214 + information while linking. */
36215 +
36216 +struct stab_info
36217 +{
36218 + /* A hash table used to hold stabs strings. */
36219 + struct bfd_strtab_hash *strings;
36220 + /* The header file hash table. */
36221 + struct bfd_hash_table includes;
36222 + /* The first .stabstr section. */
36223 + struct bfd_section *stabstr;
36224 +};
36225 +
36226 +#define COFF_SWAP_TABLE (void *) &bfd_coff_std_swap_table
36227 +
36228 +/* User program access to BFD facilities. */
36229 +
36230 +/* Direct I/O routines, for programs which know more about the object
36231 + file than BFD does. Use higher level routines if possible. */
36232 +
36233 +extern bfd_size_type bfd_bread (void *, bfd_size_type, bfd *);
36234 +extern bfd_size_type bfd_bwrite (const void *, bfd_size_type, bfd *);
36235 +extern int bfd_seek (bfd *, file_ptr, int);
36236 +extern file_ptr bfd_tell (bfd *);
36237 +extern int bfd_flush (bfd *);
36238 +extern int bfd_stat (bfd *, struct stat *);
36239 +
36240 +/* Deprecated old routines. */
36241 +#if __GNUC__
36242 +#define bfd_read(BUF, ELTSIZE, NITEMS, ABFD) \
36243 + (warn_deprecated ("bfd_read", __FILE__, __LINE__, __FUNCTION__), \
36244 + bfd_bread ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
36245 +#define bfd_write(BUF, ELTSIZE, NITEMS, ABFD) \
36246 + (warn_deprecated ("bfd_write", __FILE__, __LINE__, __FUNCTION__), \
36247 + bfd_bwrite ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
36248 +#else
36249 +#define bfd_read(BUF, ELTSIZE, NITEMS, ABFD) \
36250 + (warn_deprecated ("bfd_read", (const char *) 0, 0, (const char *) 0), \
36251 + bfd_bread ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
36252 +#define bfd_write(BUF, ELTSIZE, NITEMS, ABFD) \
36253 + (warn_deprecated ("bfd_write", (const char *) 0, 0, (const char *) 0),\
36254 + bfd_bwrite ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
36255 +#endif
36256 +extern void warn_deprecated (const char *, const char *, int, const char *);
36257 +
36258 +/* Cast from const char * to char * so that caller can assign to
36259 + a char * without a warning. */
36260 +#define bfd_get_filename(abfd) ((char *) (abfd)->filename)
36261 +#define bfd_get_cacheable(abfd) ((abfd)->cacheable)
36262 +#define bfd_get_format(abfd) ((abfd)->format)
36263 +#define bfd_get_target(abfd) ((abfd)->xvec->name)
36264 +#define bfd_get_flavour(abfd) ((abfd)->xvec->flavour)
36265 +#define bfd_family_coff(abfd) \
36266 + (bfd_get_flavour (abfd) == bfd_target_coff_flavour || \
36267 + bfd_get_flavour (abfd) == bfd_target_xcoff_flavour)
36268 +#define bfd_big_endian(abfd) ((abfd)->xvec->byteorder == BFD_ENDIAN_BIG)
36269 +#define bfd_little_endian(abfd) ((abfd)->xvec->byteorder == BFD_ENDIAN_LITTLE)
36270 +#define bfd_header_big_endian(abfd) \
36271 + ((abfd)->xvec->header_byteorder == BFD_ENDIAN_BIG)
36272 +#define bfd_header_little_endian(abfd) \
36273 + ((abfd)->xvec->header_byteorder == BFD_ENDIAN_LITTLE)
36274 +#define bfd_get_file_flags(abfd) ((abfd)->flags)
36275 +#define bfd_applicable_file_flags(abfd) ((abfd)->xvec->object_flags)
36276 +#define bfd_applicable_section_flags(abfd) ((abfd)->xvec->section_flags)
36277 +#define bfd_my_archive(abfd) ((abfd)->my_archive)
36278 +#define bfd_has_map(abfd) ((abfd)->has_armap)
36279 +
36280 +#define bfd_valid_reloc_types(abfd) ((abfd)->xvec->valid_reloc_types)
36281 +#define bfd_usrdata(abfd) ((abfd)->usrdata)
36282 +
36283 +#define bfd_get_start_address(abfd) ((abfd)->start_address)
36284 +#define bfd_get_symcount(abfd) ((abfd)->symcount)
36285 +#define bfd_get_outsymbols(abfd) ((abfd)->outsymbols)
36286 +#define bfd_count_sections(abfd) ((abfd)->section_count)
36287 +
36288 +#define bfd_get_dynamic_symcount(abfd) ((abfd)->dynsymcount)
36289 +
36290 +#define bfd_get_symbol_leading_char(abfd) ((abfd)->xvec->symbol_leading_char)
36291 +
36292 +#define bfd_set_cacheable(abfd,bool) (((abfd)->cacheable = bool), TRUE)
36293 +
36294 +extern bfd_boolean bfd_cache_close
36295 + (bfd *abfd);
36296 +/* NB: This declaration should match the autogenerated one in libbfd.h. */
36297 +
36298 +extern bfd_boolean bfd_cache_close_all (void);
36299 +
36300 +extern bfd_boolean bfd_record_phdr
36301 + (bfd *, unsigned long, bfd_boolean, flagword, bfd_boolean, bfd_vma,
36302 + bfd_boolean, bfd_boolean, unsigned int, struct bfd_section **);
36303 +
36304 +/* Byte swapping routines. */
36305 +
36306 +bfd_uint64_t bfd_getb64 (const void *);
36307 +bfd_uint64_t bfd_getl64 (const void *);
36308 +bfd_int64_t bfd_getb_signed_64 (const void *);
36309 +bfd_int64_t bfd_getl_signed_64 (const void *);
36310 +bfd_vma bfd_getb32 (const void *);
36311 +bfd_vma bfd_getl32 (const void *);
36312 +bfd_signed_vma bfd_getb_signed_32 (const void *);
36313 +bfd_signed_vma bfd_getl_signed_32 (const void *);
36314 +bfd_vma bfd_getb16 (const void *);
36315 +bfd_vma bfd_getl16 (const void *);
36316 +bfd_signed_vma bfd_getb_signed_16 (const void *);
36317 +bfd_signed_vma bfd_getl_signed_16 (const void *);
36318 +void bfd_putb64 (bfd_uint64_t, void *);
36319 +void bfd_putl64 (bfd_uint64_t, void *);
36320 +void bfd_putb32 (bfd_vma, void *);
36321 +void bfd_putl32 (bfd_vma, void *);
36322 +void bfd_putb16 (bfd_vma, void *);
36323 +void bfd_putl16 (bfd_vma, void *);
36324 +
36325 +/* Byte swapping routines which take size and endiannes as arguments. */
36326 +
36327 +bfd_uint64_t bfd_get_bits (const void *, int, bfd_boolean);
36328 +void bfd_put_bits (bfd_uint64_t, void *, int, bfd_boolean);
36329 +
36330 +extern bfd_boolean bfd_section_already_linked_table_init (void);
36331 +extern void bfd_section_already_linked_table_free (void);
36332 +\f
36333 +/* Externally visible ECOFF routines. */
36334 +
36335 +#if defined(__STDC__) || defined(ALMOST_STDC)
36336 +struct ecoff_debug_info;
36337 +struct ecoff_debug_swap;
36338 +struct ecoff_extr;
36339 +struct bfd_symbol;
36340 +struct bfd_link_info;
36341 +struct bfd_link_hash_entry;
36342 +struct bfd_elf_version_tree;
36343 +#endif
36344 +extern bfd_vma bfd_ecoff_get_gp_value
36345 + (bfd * abfd);
36346 +extern bfd_boolean bfd_ecoff_set_gp_value
36347 + (bfd *abfd, bfd_vma gp_value);
36348 +extern bfd_boolean bfd_ecoff_set_regmasks
36349 + (bfd *abfd, unsigned long gprmask, unsigned long fprmask,
36350 + unsigned long *cprmask);
36351 +extern void *bfd_ecoff_debug_init
36352 + (bfd *output_bfd, struct ecoff_debug_info *output_debug,
36353 + const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
36354 +extern void bfd_ecoff_debug_free
36355 + (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
36356 + const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
36357 +extern bfd_boolean bfd_ecoff_debug_accumulate
36358 + (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
36359 + const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
36360 + struct ecoff_debug_info *input_debug,
36361 + const struct ecoff_debug_swap *input_swap, struct bfd_link_info *);
36362 +extern bfd_boolean bfd_ecoff_debug_accumulate_other
36363 + (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
36364 + const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
36365 + struct bfd_link_info *);
36366 +extern bfd_boolean bfd_ecoff_debug_externals
36367 + (bfd *abfd, struct ecoff_debug_info *debug,
36368 + const struct ecoff_debug_swap *swap, bfd_boolean relocatable,
36369 + bfd_boolean (*get_extr) (struct bfd_symbol *, struct ecoff_extr *),
36370 + void (*set_index) (struct bfd_symbol *, bfd_size_type));
36371 +extern bfd_boolean bfd_ecoff_debug_one_external
36372 + (bfd *abfd, struct ecoff_debug_info *debug,
36373 + const struct ecoff_debug_swap *swap, const char *name,
36374 + struct ecoff_extr *esym);
36375 +extern bfd_size_type bfd_ecoff_debug_size
36376 + (bfd *abfd, struct ecoff_debug_info *debug,
36377 + const struct ecoff_debug_swap *swap);
36378 +extern bfd_boolean bfd_ecoff_write_debug
36379 + (bfd *abfd, struct ecoff_debug_info *debug,
36380 + const struct ecoff_debug_swap *swap, file_ptr where);
36381 +extern bfd_boolean bfd_ecoff_write_accumulated_debug
36382 + (void *handle, bfd *abfd, struct ecoff_debug_info *debug,
36383 + const struct ecoff_debug_swap *swap,
36384 + struct bfd_link_info *info, file_ptr where);
36385 +
36386 +/* Externally visible ELF routines. */
36387 +
36388 +struct bfd_link_needed_list
36389 +{
36390 + struct bfd_link_needed_list *next;
36391 + bfd *by;
36392 + const char *name;
36393 +};
36394 +
36395 +enum dynamic_lib_link_class {
36396 + DYN_NORMAL = 0,
36397 + DYN_AS_NEEDED = 1,
36398 + DYN_DT_NEEDED = 2,
36399 + DYN_NO_ADD_NEEDED = 4,
36400 + DYN_NO_NEEDED = 8
36401 +};
36402 +
36403 +enum notice_asneeded_action {
36404 + notice_as_needed,
36405 + notice_not_needed,
36406 + notice_needed
36407 +};
36408 +
36409 +extern bfd_boolean bfd_elf_record_link_assignment
36410 + (bfd *, struct bfd_link_info *, const char *, bfd_boolean,
36411 + bfd_boolean);
36412 +extern struct bfd_link_needed_list *bfd_elf_get_needed_list
36413 + (bfd *, struct bfd_link_info *);
36414 +extern bfd_boolean bfd_elf_get_bfd_needed_list
36415 + (bfd *, struct bfd_link_needed_list **);
36416 +extern bfd_boolean bfd_elf_size_dynamic_sections
36417 + (bfd *, const char *, const char *, const char *, const char * const *,
36418 + struct bfd_link_info *, struct bfd_section **,
36419 + struct bfd_elf_version_tree *);
36420 +extern bfd_boolean bfd_elf_size_dynsym_hash_dynstr
36421 + (bfd *, struct bfd_link_info *);
36422 +extern void bfd_elf_set_dt_needed_name
36423 + (bfd *, const char *);
36424 +extern const char *bfd_elf_get_dt_soname
36425 + (bfd *);
36426 +extern void bfd_elf_set_dyn_lib_class
36427 + (bfd *, enum dynamic_lib_link_class);
36428 +extern int bfd_elf_get_dyn_lib_class
36429 + (bfd *);
36430 +extern struct bfd_link_needed_list *bfd_elf_get_runpath_list
36431 + (bfd *, struct bfd_link_info *);
36432 +extern bfd_boolean bfd_elf_discard_info
36433 + (bfd *, struct bfd_link_info *);
36434 +extern unsigned int _bfd_elf_default_action_discarded
36435 + (struct bfd_section *);
36436 +
36437 +/* Return an upper bound on the number of bytes required to store a
36438 + copy of ABFD's program header table entries. Return -1 if an error
36439 + occurs; bfd_get_error will return an appropriate code. */
36440 +extern long bfd_get_elf_phdr_upper_bound
36441 + (bfd *abfd);
36442 +
36443 +/* Copy ABFD's program header table entries to *PHDRS. The entries
36444 + will be stored as an array of Elf_Internal_Phdr structures, as
36445 + defined in include/elf/internal.h. To find out how large the
36446 + buffer needs to be, call bfd_get_elf_phdr_upper_bound.
36447 +
36448 + Return the number of program header table entries read, or -1 if an
36449 + error occurs; bfd_get_error will return an appropriate code. */
36450 +extern int bfd_get_elf_phdrs
36451 + (bfd *abfd, void *phdrs);
36452 +
36453 +/* Create a new BFD as if by bfd_openr. Rather than opening a file,
36454 + reconstruct an ELF file by reading the segments out of remote memory
36455 + based on the ELF file header at EHDR_VMA and the ELF program headers it
36456 + points to. If not null, *LOADBASEP is filled in with the difference
36457 + between the VMAs from which the segments were read, and the VMAs the
36458 + file headers (and hence BFD's idea of each section's VMA) put them at.
36459 +
36460 + The function TARGET_READ_MEMORY is called to copy LEN bytes from the
36461 + remote memory at target address VMA into the local buffer at MYADDR; it
36462 + should return zero on success or an `errno' code on failure. TEMPL must
36463 + be a BFD for an ELF target with the word size and byte order found in
36464 + the remote memory. */
36465 +extern bfd *bfd_elf_bfd_from_remote_memory
36466 + (bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
36467 + int (*target_read_memory) (bfd_vma vma, bfd_byte *myaddr, int len));
36468 +
36469 +/* Return the arch_size field of an elf bfd, or -1 if not elf. */
36470 +extern int bfd_get_arch_size
36471 + (bfd *);
36472 +
36473 +/* Return TRUE if address "naturally" sign extends, or -1 if not elf. */
36474 +extern int bfd_get_sign_extend_vma
36475 + (bfd *);
36476 +
36477 +extern struct bfd_section *_bfd_elf_tls_setup
36478 + (bfd *, struct bfd_link_info *);
36479 +
36480 +extern void _bfd_fix_excluded_sec_syms
36481 + (bfd *, struct bfd_link_info *);
36482 +
36483 +extern unsigned bfd_m68k_mach_to_features (int);
36484 +
36485 +extern int bfd_m68k_features_to_mach (unsigned);
36486 +
36487 +extern bfd_boolean bfd_m68k_elf32_create_embedded_relocs
36488 + (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *,
36489 + char **);
36490 +
36491 +extern bfd_boolean bfd_bfin_elf32_create_embedded_relocs
36492 + (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *,
36493 + char **);
36494 +
36495 +/* SunOS shared library support routines for the linker. */
36496 +
36497 +extern struct bfd_link_needed_list *bfd_sunos_get_needed_list
36498 + (bfd *, struct bfd_link_info *);
36499 +extern bfd_boolean bfd_sunos_record_link_assignment
36500 + (bfd *, struct bfd_link_info *, const char *);
36501 +extern bfd_boolean bfd_sunos_size_dynamic_sections
36502 + (bfd *, struct bfd_link_info *, struct bfd_section **,
36503 + struct bfd_section **, struct bfd_section **);
36504 +
36505 +/* Linux shared library support routines for the linker. */
36506 +
36507 +extern bfd_boolean bfd_i386linux_size_dynamic_sections
36508 + (bfd *, struct bfd_link_info *);
36509 +extern bfd_boolean bfd_m68klinux_size_dynamic_sections
36510 + (bfd *, struct bfd_link_info *);
36511 +extern bfd_boolean bfd_sparclinux_size_dynamic_sections
36512 + (bfd *, struct bfd_link_info *);
36513 +
36514 +/* mmap hacks */
36515 +
36516 +struct _bfd_window_internal;
36517 +typedef struct _bfd_window_internal bfd_window_internal;
36518 +
36519 +typedef struct _bfd_window
36520 +{
36521 + /* What the user asked for. */
36522 + void *data;
36523 + bfd_size_type size;
36524 + /* The actual window used by BFD. Small user-requested read-only
36525 + regions sharing a page may share a single window into the object
36526 + file. Read-write versions shouldn't until I've fixed things to
36527 + keep track of which portions have been claimed by the
36528 + application; don't want to give the same region back when the
36529 + application wants two writable copies! */
36530 + struct _bfd_window_internal *i;
36531 +}
36532 +bfd_window;
36533 +
36534 +extern void bfd_init_window
36535 + (bfd_window *);
36536 +extern void bfd_free_window
36537 + (bfd_window *);
36538 +extern bfd_boolean bfd_get_file_window
36539 + (bfd *, file_ptr, bfd_size_type, bfd_window *, bfd_boolean);
36540 +
36541 +/* XCOFF support routines for the linker. */
36542 +
36543 +extern bfd_boolean bfd_xcoff_link_record_set
36544 + (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *, bfd_size_type);
36545 +extern bfd_boolean bfd_xcoff_import_symbol
36546 + (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *, bfd_vma,
36547 + const char *, const char *, const char *, unsigned int);
36548 +extern bfd_boolean bfd_xcoff_export_symbol
36549 + (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *);
36550 +extern bfd_boolean bfd_xcoff_link_count_reloc
36551 + (bfd *, struct bfd_link_info *, const char *);
36552 +extern bfd_boolean bfd_xcoff_record_link_assignment
36553 + (bfd *, struct bfd_link_info *, const char *);
36554 +extern bfd_boolean bfd_xcoff_size_dynamic_sections
36555 + (bfd *, struct bfd_link_info *, const char *, const char *,
36556 + unsigned long, unsigned long, unsigned long, bfd_boolean,
36557 + int, bfd_boolean, bfd_boolean, struct bfd_section **, bfd_boolean);
36558 +extern bfd_boolean bfd_xcoff_link_generate_rtinit
36559 + (bfd *, const char *, const char *, bfd_boolean);
36560 +
36561 +/* XCOFF support routines for ar. */
36562 +extern bfd_boolean bfd_xcoff_ar_archive_set_magic
36563 + (bfd *, char *);
36564 +
36565 +/* Externally visible COFF routines. */
36566 +
36567 +#if defined(__STDC__) || defined(ALMOST_STDC)
36568 +struct internal_syment;
36569 +union internal_auxent;
36570 +#endif
36571 +
36572 +extern bfd_boolean bfd_coff_get_syment
36573 + (bfd *, struct bfd_symbol *, struct internal_syment *);
36574 +
36575 +extern bfd_boolean bfd_coff_get_auxent
36576 + (bfd *, struct bfd_symbol *, int, union internal_auxent *);
36577 +
36578 +extern bfd_boolean bfd_coff_set_symbol_class
36579 + (bfd *, struct bfd_symbol *, unsigned int);
36580 +
36581 +extern bfd_boolean bfd_m68k_coff_create_embedded_relocs
36582 + (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
36583 +
36584 +/* ARM VFP11 erratum workaround support. */
36585 +typedef enum
36586 +{
36587 + BFD_ARM_VFP11_FIX_DEFAULT,
36588 + BFD_ARM_VFP11_FIX_NONE,
36589 + BFD_ARM_VFP11_FIX_SCALAR,
36590 + BFD_ARM_VFP11_FIX_VECTOR
36591 +} bfd_arm_vfp11_fix;
36592 +
36593 +extern void bfd_elf32_arm_init_maps
36594 + (bfd *);
36595 +
36596 +extern void bfd_elf32_arm_set_vfp11_fix
36597 + (bfd *, struct bfd_link_info *);
36598 +
36599 +extern bfd_boolean bfd_elf32_arm_vfp11_erratum_scan
36600 + (bfd *, struct bfd_link_info *);
36601 +
36602 +extern void bfd_elf32_arm_vfp11_fix_veneer_locations
36603 + (bfd *, struct bfd_link_info *);
36604 +
36605 +/* ARM Interworking support. Called from linker. */
36606 +extern bfd_boolean bfd_arm_allocate_interworking_sections
36607 + (struct bfd_link_info *);
36608 +
36609 +extern bfd_boolean bfd_arm_process_before_allocation
36610 + (bfd *, struct bfd_link_info *, int);
36611 +
36612 +extern bfd_boolean bfd_arm_get_bfd_for_interworking
36613 + (bfd *, struct bfd_link_info *);
36614 +
36615 +/* PE ARM Interworking support. Called from linker. */
36616 +extern bfd_boolean bfd_arm_pe_allocate_interworking_sections
36617 + (struct bfd_link_info *);
36618 +
36619 +extern bfd_boolean bfd_arm_pe_process_before_allocation
36620 + (bfd *, struct bfd_link_info *, int);
36621 +
36622 +extern bfd_boolean bfd_arm_pe_get_bfd_for_interworking
36623 + (bfd *, struct bfd_link_info *);
36624 +
36625 +/* ELF ARM Interworking support. Called from linker. */
36626 +extern bfd_boolean bfd_elf32_arm_allocate_interworking_sections
36627 + (struct bfd_link_info *);
36628 +
36629 +extern bfd_boolean bfd_elf32_arm_process_before_allocation
36630 + (bfd *, struct bfd_link_info *);
36631 +
36632 +void bfd_elf32_arm_set_target_relocs
36633 + (bfd *, struct bfd_link_info *, int, char *, int, int, bfd_arm_vfp11_fix,
36634 + int, int);
36635 +
36636 +extern bfd_boolean bfd_elf32_arm_get_bfd_for_interworking
36637 + (bfd *, struct bfd_link_info *);
36638 +
36639 +extern bfd_boolean bfd_elf32_arm_add_glue_sections_to_bfd
36640 + (bfd *, struct bfd_link_info *);
36641 +
36642 +/* ELF ARM mapping symbol support */
36643 +#define BFD_ARM_SPECIAL_SYM_TYPE_MAP (1 << 0)
36644 +#define BFD_ARM_SPECIAL_SYM_TYPE_TAG (1 << 1)
36645 +#define BFD_ARM_SPECIAL_SYM_TYPE_OTHER (1 << 2)
36646 +#define BFD_ARM_SPECIAL_SYM_TYPE_ANY (~0)
36647 +extern bfd_boolean bfd_is_arm_special_symbol_name
36648 + (const char * name, int type);
36649 +
36650 +extern void bfd_elf32_arm_set_byteswap_code (struct bfd_link_info *, int);
36651 +
36652 +/* ARM Note section processing. */
36653 +extern bfd_boolean bfd_arm_merge_machines
36654 + (bfd *, bfd *);
36655 +
36656 +extern bfd_boolean bfd_arm_update_notes
36657 + (bfd *, const char *);
36658 +
36659 +extern unsigned int bfd_arm_get_mach_from_notes
36660 + (bfd *, const char *);
36661 +
36662 +/* TI COFF load page support. */
36663 +extern void bfd_ticoff_set_section_load_page
36664 + (struct bfd_section *, int);
36665 +
36666 +extern int bfd_ticoff_get_section_load_page
36667 + (struct bfd_section *);
36668 +
36669 +/* H8/300 functions. */
36670 +extern bfd_vma bfd_h8300_pad_address
36671 + (bfd *, bfd_vma);
36672 +
36673 +/* IA64 Itanium code generation. Called from linker. */
36674 +extern void bfd_elf32_ia64_after_parse
36675 + (int);
36676 +
36677 +extern void bfd_elf64_ia64_after_parse
36678 + (int);
36679 +
36680 +/* This structure is used for a comdat section, as in PE. A comdat
36681 + section is associated with a particular symbol. When the linker
36682 + sees a comdat section, it keeps only one of the sections with a
36683 + given name and associated with a given symbol. */
36684 +
36685 +struct coff_comdat_info
36686 +{
36687 + /* The name of the symbol associated with a comdat section. */
36688 + const char *name;
36689 +
36690 + /* The local symbol table index of the symbol associated with a
36691 + comdat section. This is only meaningful to the object file format
36692 + specific code; it is not an index into the list returned by
36693 + bfd_canonicalize_symtab. */
36694 + long symbol;
36695 +};
36696 +
36697 +extern struct coff_comdat_info *bfd_coff_get_comdat_section
36698 + (bfd *, struct bfd_section *);
36699 +
36700 +/* Extracted from init.c. */
36701 +void bfd_init (void);
36702 +
36703 +/* Extracted from opncls.c. */
36704 +bfd *bfd_fopen (const char *filename, const char *target,
36705 + const char *mode, int fd);
36706 +
36707 +bfd *bfd_openr (const char *filename, const char *target);
36708 +
36709 +bfd *bfd_fdopenr (const char *filename, const char *target, int fd);
36710 +
36711 +bfd *bfd_openstreamr (const char *, const char *, void *);
36712 +
36713 +bfd *bfd_openr_iovec (const char *filename, const char *target,
36714 + void *(*open) (struct bfd *nbfd,
36715 + void *open_closure),
36716 + void *open_closure,
36717 + file_ptr (*pread) (struct bfd *nbfd,
36718 + void *stream,
36719 + void *buf,
36720 + file_ptr nbytes,
36721 + file_ptr offset),
36722 + int (*close) (struct bfd *nbfd,
36723 + void *stream),
36724 + int (*stat) (struct bfd *abfd,
36725 + void *stream,
36726 + struct stat *sb));
36727 +
36728 +bfd *bfd_openw (const char *filename, const char *target);
36729 +
36730 +bfd_boolean bfd_close (bfd *abfd);
36731 +
36732 +bfd_boolean bfd_close_all_done (bfd *);
36733 +
36734 +bfd *bfd_create (const char *filename, bfd *templ);
36735 +
36736 +bfd_boolean bfd_make_writable (bfd *abfd);
36737 +
36738 +bfd_boolean bfd_make_readable (bfd *abfd);
36739 +
36740 +unsigned long bfd_calc_gnu_debuglink_crc32
36741 + (unsigned long crc, const unsigned char *buf, bfd_size_type len);
36742 +
36743 +char *bfd_follow_gnu_debuglink (bfd *abfd, const char *dir);
36744 +
36745 +struct bfd_section *bfd_create_gnu_debuglink_section
36746 + (bfd *abfd, const char *filename);
36747 +
36748 +bfd_boolean bfd_fill_in_gnu_debuglink_section
36749 + (bfd *abfd, struct bfd_section *sect, const char *filename);
36750 +
36751 +/* Extracted from libbfd.c. */
36752 +
36753 +/* Byte swapping macros for user section data. */
36754 +
36755 +#define bfd_put_8(abfd, val, ptr) \
36756 + ((void) (*((unsigned char *) (ptr)) = (val) & 0xff))
36757 +#define bfd_put_signed_8 \
36758 + bfd_put_8
36759 +#define bfd_get_8(abfd, ptr) \
36760 + (*(unsigned char *) (ptr) & 0xff)
36761 +#define bfd_get_signed_8(abfd, ptr) \
36762 + (((*(unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80)
36763 +
36764 +#define bfd_put_16(abfd, val, ptr) \
36765 + BFD_SEND (abfd, bfd_putx16, ((val),(ptr)))
36766 +#define bfd_put_signed_16 \
36767 + bfd_put_16
36768 +#define bfd_get_16(abfd, ptr) \
36769 + BFD_SEND (abfd, bfd_getx16, (ptr))
36770 +#define bfd_get_signed_16(abfd, ptr) \
36771 + BFD_SEND (abfd, bfd_getx_signed_16, (ptr))
36772 +
36773 +#define bfd_put_32(abfd, val, ptr) \
36774 + BFD_SEND (abfd, bfd_putx32, ((val),(ptr)))
36775 +#define bfd_put_signed_32 \
36776 + bfd_put_32
36777 +#define bfd_get_32(abfd, ptr) \
36778 + BFD_SEND (abfd, bfd_getx32, (ptr))
36779 +#define bfd_get_signed_32(abfd, ptr) \
36780 + BFD_SEND (abfd, bfd_getx_signed_32, (ptr))
36781 +
36782 +#define bfd_put_64(abfd, val, ptr) \
36783 + BFD_SEND (abfd, bfd_putx64, ((val), (ptr)))
36784 +#define bfd_put_signed_64 \
36785 + bfd_put_64
36786 +#define bfd_get_64(abfd, ptr) \
36787 + BFD_SEND (abfd, bfd_getx64, (ptr))
36788 +#define bfd_get_signed_64(abfd, ptr) \
36789 + BFD_SEND (abfd, bfd_getx_signed_64, (ptr))
36790 +
36791 +#define bfd_get(bits, abfd, ptr) \
36792 + ((bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \
36793 + : (bits) == 16 ? bfd_get_16 (abfd, ptr) \
36794 + : (bits) == 32 ? bfd_get_32 (abfd, ptr) \
36795 + : (bits) == 64 ? bfd_get_64 (abfd, ptr) \
36796 + : (abort (), (bfd_vma) - 1))
36797 +
36798 +#define bfd_put(bits, abfd, val, ptr) \
36799 + ((bits) == 8 ? bfd_put_8 (abfd, val, ptr) \
36800 + : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \
36801 + : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \
36802 + : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \
36803 + : (abort (), (void) 0))
36804 +
36805 +
36806 +/* Byte swapping macros for file header data. */
36807 +
36808 +#define bfd_h_put_8(abfd, val, ptr) \
36809 + bfd_put_8 (abfd, val, ptr)
36810 +#define bfd_h_put_signed_8(abfd, val, ptr) \
36811 + bfd_put_8 (abfd, val, ptr)
36812 +#define bfd_h_get_8(abfd, ptr) \
36813 + bfd_get_8 (abfd, ptr)
36814 +#define bfd_h_get_signed_8(abfd, ptr) \
36815 + bfd_get_signed_8 (abfd, ptr)
36816 +
36817 +#define bfd_h_put_16(abfd, val, ptr) \
36818 + BFD_SEND (abfd, bfd_h_putx16, (val, ptr))
36819 +#define bfd_h_put_signed_16 \
36820 + bfd_h_put_16
36821 +#define bfd_h_get_16(abfd, ptr) \
36822 + BFD_SEND (abfd, bfd_h_getx16, (ptr))
36823 +#define bfd_h_get_signed_16(abfd, ptr) \
36824 + BFD_SEND (abfd, bfd_h_getx_signed_16, (ptr))
36825 +
36826 +#define bfd_h_put_32(abfd, val, ptr) \
36827 + BFD_SEND (abfd, bfd_h_putx32, (val, ptr))
36828 +#define bfd_h_put_signed_32 \
36829 + bfd_h_put_32
36830 +#define bfd_h_get_32(abfd, ptr) \
36831 + BFD_SEND (abfd, bfd_h_getx32, (ptr))
36832 +#define bfd_h_get_signed_32(abfd, ptr) \
36833 + BFD_SEND (abfd, bfd_h_getx_signed_32, (ptr))
36834 +
36835 +#define bfd_h_put_64(abfd, val, ptr) \
36836 + BFD_SEND (abfd, bfd_h_putx64, (val, ptr))
36837 +#define bfd_h_put_signed_64 \
36838 + bfd_h_put_64
36839 +#define bfd_h_get_64(abfd, ptr) \
36840 + BFD_SEND (abfd, bfd_h_getx64, (ptr))
36841 +#define bfd_h_get_signed_64(abfd, ptr) \
36842 + BFD_SEND (abfd, bfd_h_getx_signed_64, (ptr))
36843 +
36844 +/* Aliases for the above, which should eventually go away. */
36845 +
36846 +#define H_PUT_64 bfd_h_put_64
36847 +#define H_PUT_32 bfd_h_put_32
36848 +#define H_PUT_16 bfd_h_put_16
36849 +#define H_PUT_8 bfd_h_put_8
36850 +#define H_PUT_S64 bfd_h_put_signed_64
36851 +#define H_PUT_S32 bfd_h_put_signed_32
36852 +#define H_PUT_S16 bfd_h_put_signed_16
36853 +#define H_PUT_S8 bfd_h_put_signed_8
36854 +#define H_GET_64 bfd_h_get_64
36855 +#define H_GET_32 bfd_h_get_32
36856 +#define H_GET_16 bfd_h_get_16
36857 +#define H_GET_8 bfd_h_get_8
36858 +#define H_GET_S64 bfd_h_get_signed_64
36859 +#define H_GET_S32 bfd_h_get_signed_32
36860 +#define H_GET_S16 bfd_h_get_signed_16
36861 +#define H_GET_S8 bfd_h_get_signed_8
36862 +
36863 +
36864 +/* Extracted from bfdio.c. */
36865 +long bfd_get_mtime (bfd *abfd);
36866 +
36867 +file_ptr bfd_get_size (bfd *abfd);
36868 +
36869 +/* Extracted from bfdwin.c. */
36870 +/* Extracted from section.c. */
36871 +typedef struct bfd_section
36872 +{
36873 + /* The name of the section; the name isn't a copy, the pointer is
36874 + the same as that passed to bfd_make_section. */
36875 + const char *name;
36876 +
36877 + /* A unique sequence number. */
36878 + int id;
36879 +
36880 + /* Which section in the bfd; 0..n-1 as sections are created in a bfd. */
36881 + int index;
36882 +
36883 + /* The next section in the list belonging to the BFD, or NULL. */
36884 + struct bfd_section *next;
36885 +
36886 + /* The previous section in the list belonging to the BFD, or NULL. */
36887 + struct bfd_section *prev;
36888 +
36889 + /* The field flags contains attributes of the section. Some
36890 + flags are read in from the object file, and some are
36891 + synthesized from other information. */
36892 + flagword flags;
36893 +
36894 +#define SEC_NO_FLAGS 0x000
36895 +
36896 + /* Tells the OS to allocate space for this section when loading.
36897 + This is clear for a section containing debug information only. */
36898 +#define SEC_ALLOC 0x001
36899 +
36900 + /* Tells the OS to load the section from the file when loading.
36901 + This is clear for a .bss section. */
36902 +#define SEC_LOAD 0x002
36903 +
36904 + /* The section contains data still to be relocated, so there is
36905 + some relocation information too. */
36906 +#define SEC_RELOC 0x004
36907 +
36908 + /* A signal to the OS that the section contains read only data. */
36909 +#define SEC_READONLY 0x008
36910 +
36911 + /* The section contains code only. */
36912 +#define SEC_CODE 0x010
36913 +
36914 + /* The section contains data only. */
36915 +#define SEC_DATA 0x020
36916 +
36917 + /* The section will reside in ROM. */
36918 +#define SEC_ROM 0x040
36919 +
36920 + /* The section contains constructor information. This section
36921 + type is used by the linker to create lists of constructors and
36922 + destructors used by <<g++>>. When a back end sees a symbol
36923 + which should be used in a constructor list, it creates a new
36924 + section for the type of name (e.g., <<__CTOR_LIST__>>), attaches
36925 + the symbol to it, and builds a relocation. To build the lists
36926 + of constructors, all the linker has to do is catenate all the
36927 + sections called <<__CTOR_LIST__>> and relocate the data
36928 + contained within - exactly the operations it would peform on
36929 + standard data. */
36930 +#define SEC_CONSTRUCTOR 0x080
36931 +
36932 + /* The section has contents - a data section could be
36933 + <<SEC_ALLOC>> | <<SEC_HAS_CONTENTS>>; a debug section could be
36934 + <<SEC_HAS_CONTENTS>> */
36935 +#define SEC_HAS_CONTENTS 0x100
36936 +
36937 + /* An instruction to the linker to not output the section
36938 + even if it has information which would normally be written. */
36939 +#define SEC_NEVER_LOAD 0x200
36940 +
36941 + /* The section contains thread local data. */
36942 +#define SEC_THREAD_LOCAL 0x400
36943 +
36944 + /* The section has GOT references. This flag is only for the
36945 + linker, and is currently only used by the elf32-hppa back end.
36946 + It will be set if global offset table references were detected
36947 + in this section, which indicate to the linker that the section
36948 + contains PIC code, and must be handled specially when doing a
36949 + static link. */
36950 +#define SEC_HAS_GOT_REF 0x800
36951 +
36952 + /* The section contains common symbols (symbols may be defined
36953 + multiple times, the value of a symbol is the amount of
36954 + space it requires, and the largest symbol value is the one
36955 + used). Most targets have exactly one of these (which we
36956 + translate to bfd_com_section_ptr), but ECOFF has two. */
36957 +#define SEC_IS_COMMON 0x1000
36958 +
36959 + /* The section contains only debugging information. For
36960 + example, this is set for ELF .debug and .stab sections.
36961 + strip tests this flag to see if a section can be
36962 + discarded. */
36963 +#define SEC_DEBUGGING 0x2000
36964 +
36965 + /* The contents of this section are held in memory pointed to
36966 + by the contents field. This is checked by bfd_get_section_contents,
36967 + and the data is retrieved from memory if appropriate. */
36968 +#define SEC_IN_MEMORY 0x4000
36969 +
36970 + /* The contents of this section are to be excluded by the
36971 + linker for executable and shared objects unless those
36972 + objects are to be further relocated. */
36973 +#define SEC_EXCLUDE 0x8000
36974 +
36975 + /* The contents of this section are to be sorted based on the sum of
36976 + the symbol and addend values specified by the associated relocation
36977 + entries. Entries without associated relocation entries will be
36978 + appended to the end of the section in an unspecified order. */
36979 +#define SEC_SORT_ENTRIES 0x10000
36980 +
36981 + /* When linking, duplicate sections of the same name should be
36982 + discarded, rather than being combined into a single section as
36983 + is usually done. This is similar to how common symbols are
36984 + handled. See SEC_LINK_DUPLICATES below. */
36985 +#define SEC_LINK_ONCE 0x20000
36986 +
36987 + /* If SEC_LINK_ONCE is set, this bitfield describes how the linker
36988 + should handle duplicate sections. */
36989 +#define SEC_LINK_DUPLICATES 0x40000
36990 +
36991 + /* This value for SEC_LINK_DUPLICATES means that duplicate
36992 + sections with the same name should simply be discarded. */
36993 +#define SEC_LINK_DUPLICATES_DISCARD 0x0
36994 +
36995 + /* This value for SEC_LINK_DUPLICATES means that the linker
36996 + should warn if there are any duplicate sections, although
36997 + it should still only link one copy. */
36998 +#define SEC_LINK_DUPLICATES_ONE_ONLY 0x80000
36999 +
37000 + /* This value for SEC_LINK_DUPLICATES means that the linker
37001 + should warn if any duplicate sections are a different size. */
37002 +#define SEC_LINK_DUPLICATES_SAME_SIZE 0x100000
37003 +
37004 + /* This value for SEC_LINK_DUPLICATES means that the linker
37005 + should warn if any duplicate sections contain different
37006 + contents. */
37007 +#define SEC_LINK_DUPLICATES_SAME_CONTENTS \
37008 + (SEC_LINK_DUPLICATES_ONE_ONLY | SEC_LINK_DUPLICATES_SAME_SIZE)
37009 +
37010 + /* This section was created by the linker as part of dynamic
37011 + relocation or other arcane processing. It is skipped when
37012 + going through the first-pass output, trusting that someone
37013 + else up the line will take care of it later. */
37014 +#define SEC_LINKER_CREATED 0x200000
37015 +
37016 + /* This section should not be subject to garbage collection.
37017 + Also set to inform the linker that this section should not be
37018 + listed in the link map as discarded. */
37019 +#define SEC_KEEP 0x400000
37020 +
37021 + /* This section contains "short" data, and should be placed
37022 + "near" the GP. */
37023 +#define SEC_SMALL_DATA 0x800000
37024 +
37025 + /* Attempt to merge identical entities in the section.
37026 + Entity size is given in the entsize field. */
37027 +#define SEC_MERGE 0x1000000
37028 +
37029 + /* If given with SEC_MERGE, entities to merge are zero terminated
37030 + strings where entsize specifies character size instead of fixed
37031 + size entries. */
37032 +#define SEC_STRINGS 0x2000000
37033 +
37034 + /* This section contains data about section groups. */
37035 +#define SEC_GROUP 0x4000000
37036 +
37037 + /* The section is a COFF shared library section. This flag is
37038 + only for the linker. If this type of section appears in
37039 + the input file, the linker must copy it to the output file
37040 + without changing the vma or size. FIXME: Although this
37041 + was originally intended to be general, it really is COFF
37042 + specific (and the flag was renamed to indicate this). It
37043 + might be cleaner to have some more general mechanism to
37044 + allow the back end to control what the linker does with
37045 + sections. */
37046 +#define SEC_COFF_SHARED_LIBRARY 0x10000000
37047 +
37048 + /* This section contains data which may be shared with other
37049 + executables or shared objects. This is for COFF only. */
37050 +#define SEC_COFF_SHARED 0x20000000
37051 +
37052 + /* When a section with this flag is being linked, then if the size of
37053 + the input section is less than a page, it should not cross a page
37054 + boundary. If the size of the input section is one page or more,
37055 + it should be aligned on a page boundary. This is for TI
37056 + TMS320C54X only. */
37057 +#define SEC_TIC54X_BLOCK 0x40000000
37058 +
37059 + /* Conditionally link this section; do not link if there are no
37060 + references found to any symbol in the section. This is for TI
37061 + TMS320C54X only. */
37062 +#define SEC_TIC54X_CLINK 0x80000000
37063 +
37064 + /* End of section flags. */
37065 +
37066 + /* Some internal packed boolean fields. */
37067 +
37068 + /* See the vma field. */
37069 + unsigned int user_set_vma : 1;
37070 +
37071 + /* A mark flag used by some of the linker backends. */
37072 + unsigned int linker_mark : 1;
37073 +
37074 + /* Another mark flag used by some of the linker backends. Set for
37075 + output sections that have an input section. */
37076 + unsigned int linker_has_input : 1;
37077 +
37078 + /* Mark flags used by some linker backends for garbage collection. */
37079 + unsigned int gc_mark : 1;
37080 + unsigned int gc_mark_from_eh : 1;
37081 +
37082 + /* The following flags are used by the ELF linker. */
37083 +
37084 + /* Mark sections which have been allocated to segments. */
37085 + unsigned int segment_mark : 1;
37086 +
37087 + /* Type of sec_info information. */
37088 + unsigned int sec_info_type:3;
37089 +#define ELF_INFO_TYPE_NONE 0
37090 +#define ELF_INFO_TYPE_STABS 1
37091 +#define ELF_INFO_TYPE_MERGE 2
37092 +#define ELF_INFO_TYPE_EH_FRAME 3
37093 +#define ELF_INFO_TYPE_JUST_SYMS 4
37094 +
37095 + /* Nonzero if this section uses RELA relocations, rather than REL. */
37096 + unsigned int use_rela_p:1;
37097 +
37098 + /* Bits used by various backends. The generic code doesn't touch
37099 + these fields. */
37100 +
37101 + /* Nonzero if this section has TLS related relocations. */
37102 + unsigned int has_tls_reloc:1;
37103 +
37104 + /* Nonzero if this section has a gp reloc. */
37105 + unsigned int has_gp_reloc:1;
37106 +
37107 + /* Nonzero if this section needs the relax finalize pass. */
37108 + unsigned int need_finalize_relax:1;
37109 +
37110 + /* Whether relocations have been processed. */
37111 + unsigned int reloc_done : 1;
37112 +
37113 + /* End of internal packed boolean fields. */
37114 +
37115 + /* The virtual memory address of the section - where it will be
37116 + at run time. The symbols are relocated against this. The
37117 + user_set_vma flag is maintained by bfd; if it's not set, the
37118 + backend can assign addresses (for example, in <<a.out>>, where
37119 + the default address for <<.data>> is dependent on the specific
37120 + target and various flags). */
37121 + bfd_vma vma;
37122 +
37123 + /* The load address of the section - where it would be in a
37124 + rom image; really only used for writing section header
37125 + information. */
37126 + bfd_vma lma;
37127 +
37128 + /* The size of the section in octets, as it will be output.
37129 + Contains a value even if the section has no contents (e.g., the
37130 + size of <<.bss>>). */
37131 + bfd_size_type size;
37132 +
37133 + /* For input sections, the original size on disk of the section, in
37134 + octets. This field is used by the linker relaxation code. It is
37135 + currently only set for sections where the linker relaxation scheme
37136 + doesn't cache altered section and reloc contents (stabs, eh_frame,
37137 + SEC_MERGE, some coff relaxing targets), and thus the original size
37138 + needs to be kept to read the section multiple times.
37139 + For output sections, rawsize holds the section size calculated on
37140 + a previous linker relaxation pass. */
37141 + bfd_size_type rawsize;
37142 +
37143 + /* If this section is going to be output, then this value is the
37144 + offset in *bytes* into the output section of the first byte in the
37145 + input section (byte ==> smallest addressable unit on the
37146 + target). In most cases, if this was going to start at the
37147 + 100th octet (8-bit quantity) in the output section, this value
37148 + would be 100. However, if the target byte size is 16 bits
37149 + (bfd_octets_per_byte is "2"), this value would be 50. */
37150 + bfd_vma output_offset;
37151 +
37152 + /* The output section through which to map on output. */
37153 + struct bfd_section *output_section;
37154 +
37155 + /* The alignment requirement of the section, as an exponent of 2 -
37156 + e.g., 3 aligns to 2^3 (or 8). */
37157 + unsigned int alignment_power;
37158 +
37159 + /* If an input section, a pointer to a vector of relocation
37160 + records for the data in this section. */
37161 + struct reloc_cache_entry *relocation;
37162 +
37163 + /* If an output section, a pointer to a vector of pointers to
37164 + relocation records for the data in this section. */
37165 + struct reloc_cache_entry **orelocation;
37166 +
37167 + /* The number of relocation records in one of the above. */
37168 + unsigned reloc_count;
37169 +
37170 + /* Information below is back end specific - and not always used
37171 + or updated. */
37172 +
37173 + /* File position of section data. */
37174 + file_ptr filepos;
37175 +
37176 + /* File position of relocation info. */
37177 + file_ptr rel_filepos;
37178 +
37179 + /* File position of line data. */
37180 + file_ptr line_filepos;
37181 +
37182 + /* Pointer to data for applications. */
37183 + void *userdata;
37184 +
37185 + /* If the SEC_IN_MEMORY flag is set, this points to the actual
37186 + contents. */
37187 + unsigned char *contents;
37188 +
37189 + /* Attached line number information. */
37190 + alent *lineno;
37191 +
37192 + /* Number of line number records. */
37193 + unsigned int lineno_count;
37194 +
37195 + /* Entity size for merging purposes. */
37196 + unsigned int entsize;
37197 +
37198 + /* Points to the kept section if this section is a link-once section,
37199 + and is discarded. */
37200 + struct bfd_section *kept_section;
37201 +
37202 + /* When a section is being output, this value changes as more
37203 + linenumbers are written out. */
37204 + file_ptr moving_line_filepos;
37205 +
37206 + /* What the section number is in the target world. */
37207 + int target_index;
37208 +
37209 + void *used_by_bfd;
37210 +
37211 + /* If this is a constructor section then here is a list of the
37212 + relocations created to relocate items within it. */
37213 + struct relent_chain *constructor_chain;
37214 +
37215 + /* The BFD which owns the section. */
37216 + bfd *owner;
37217 +
37218 + /* A symbol which points at this section only. */
37219 + struct bfd_symbol *symbol;
37220 + struct bfd_symbol **symbol_ptr_ptr;
37221 +
37222 + /* Early in the link process, map_head and map_tail are used to build
37223 + a list of input sections attached to an output section. Later,
37224 + output sections use these fields for a list of bfd_link_order
37225 + structs. */
37226 + union {
37227 + struct bfd_link_order *link_order;
37228 + struct bfd_section *s;
37229 + } map_head, map_tail;
37230 +} asection;
37231 +
37232 +/* These sections are global, and are managed by BFD. The application
37233 + and target back end are not permitted to change the values in
37234 + these sections. New code should use the section_ptr macros rather
37235 + than referring directly to the const sections. The const sections
37236 + may eventually vanish. */
37237 +#define BFD_ABS_SECTION_NAME "*ABS*"
37238 +#define BFD_UND_SECTION_NAME "*UND*"
37239 +#define BFD_COM_SECTION_NAME "*COM*"
37240 +#define BFD_IND_SECTION_NAME "*IND*"
37241 +
37242 +/* The absolute section. */
37243 +extern asection bfd_abs_section;
37244 +#define bfd_abs_section_ptr ((asection *) &bfd_abs_section)
37245 +#define bfd_is_abs_section(sec) ((sec) == bfd_abs_section_ptr)
37246 +/* Pointer to the undefined section. */
37247 +extern asection bfd_und_section;
37248 +#define bfd_und_section_ptr ((asection *) &bfd_und_section)
37249 +#define bfd_is_und_section(sec) ((sec) == bfd_und_section_ptr)
37250 +/* Pointer to the common section. */
37251 +extern asection bfd_com_section;
37252 +#define bfd_com_section_ptr ((asection *) &bfd_com_section)
37253 +/* Pointer to the indirect section. */
37254 +extern asection bfd_ind_section;
37255 +#define bfd_ind_section_ptr ((asection *) &bfd_ind_section)
37256 +#define bfd_is_ind_section(sec) ((sec) == bfd_ind_section_ptr)
37257 +
37258 +#define bfd_is_const_section(SEC) \
37259 + ( ((SEC) == bfd_abs_section_ptr) \
37260 + || ((SEC) == bfd_und_section_ptr) \
37261 + || ((SEC) == bfd_com_section_ptr) \
37262 + || ((SEC) == bfd_ind_section_ptr))
37263 +
37264 +/* Macros to handle insertion and deletion of a bfd's sections. These
37265 + only handle the list pointers, ie. do not adjust section_count,
37266 + target_index etc. */
37267 +#define bfd_section_list_remove(ABFD, S) \
37268 + do \
37269 + { \
37270 + asection *_s = S; \
37271 + asection *_next = _s->next; \
37272 + asection *_prev = _s->prev; \
37273 + if (_prev) \
37274 + _prev->next = _next; \
37275 + else \
37276 + (ABFD)->sections = _next; \
37277 + if (_next) \
37278 + _next->prev = _prev; \
37279 + else \
37280 + (ABFD)->section_last = _prev; \
37281 + } \
37282 + while (0)
37283 +#define bfd_section_list_append(ABFD, S) \
37284 + do \
37285 + { \
37286 + asection *_s = S; \
37287 + bfd *_abfd = ABFD; \
37288 + _s->next = NULL; \
37289 + if (_abfd->section_last) \
37290 + { \
37291 + _s->prev = _abfd->section_last; \
37292 + _abfd->section_last->next = _s; \
37293 + } \
37294 + else \
37295 + { \
37296 + _s->prev = NULL; \
37297 + _abfd->sections = _s; \
37298 + } \
37299 + _abfd->section_last = _s; \
37300 + } \
37301 + while (0)
37302 +#define bfd_section_list_prepend(ABFD, S) \
37303 + do \
37304 + { \
37305 + asection *_s = S; \
37306 + bfd *_abfd = ABFD; \
37307 + _s->prev = NULL; \
37308 + if (_abfd->sections) \
37309 + { \
37310 + _s->next = _abfd->sections; \
37311 + _abfd->sections->prev = _s; \
37312 + } \
37313 + else \
37314 + { \
37315 + _s->next = NULL; \
37316 + _abfd->section_last = _s; \
37317 + } \
37318 + _abfd->sections = _s; \
37319 + } \
37320 + while (0)
37321 +#define bfd_section_list_insert_after(ABFD, A, S) \
37322 + do \
37323 + { \
37324 + asection *_a = A; \
37325 + asection *_s = S; \
37326 + asection *_next = _a->next; \
37327 + _s->next = _next; \
37328 + _s->prev = _a; \
37329 + _a->next = _s; \
37330 + if (_next) \
37331 + _next->prev = _s; \
37332 + else \
37333 + (ABFD)->section_last = _s; \
37334 + } \
37335 + while (0)
37336 +#define bfd_section_list_insert_before(ABFD, B, S) \
37337 + do \
37338 + { \
37339 + asection *_b = B; \
37340 + asection *_s = S; \
37341 + asection *_prev = _b->prev; \
37342 + _s->prev = _prev; \
37343 + _s->next = _b; \
37344 + _b->prev = _s; \
37345 + if (_prev) \
37346 + _prev->next = _s; \
37347 + else \
37348 + (ABFD)->sections = _s; \
37349 + } \
37350 + while (0)
37351 +#define bfd_section_removed_from_list(ABFD, S) \
37352 + ((S)->next == NULL ? (ABFD)->section_last != (S) : (S)->next->prev != (S))
37353 +
37354 +#define BFD_FAKE_SECTION(SEC, FLAGS, SYM, NAME, IDX) \
37355 + /* name, id, index, next, prev, flags, user_set_vma, */ \
37356 + { NAME, IDX, 0, NULL, NULL, FLAGS, 0, \
37357 + \
37358 + /* linker_mark, linker_has_input, gc_mark, gc_mark_from_eh, */ \
37359 + 0, 0, 1, 0, \
37360 + \
37361 + /* segment_mark, sec_info_type, use_rela_p, has_tls_reloc, */ \
37362 + 0, 0, 0, 0, \
37363 + \
37364 + /* has_gp_reloc, need_finalize_relax, reloc_done, */ \
37365 + 0, 0, 0, \
37366 + \
37367 + /* vma, lma, size, rawsize */ \
37368 + 0, 0, 0, 0, \
37369 + \
37370 + /* output_offset, output_section, alignment_power, */ \
37371 + 0, (struct bfd_section *) &SEC, 0, \
37372 + \
37373 + /* relocation, orelocation, reloc_count, filepos, rel_filepos, */ \
37374 + NULL, NULL, 0, 0, 0, \
37375 + \
37376 + /* line_filepos, userdata, contents, lineno, lineno_count, */ \
37377 + 0, NULL, NULL, NULL, 0, \
37378 + \
37379 + /* entsize, kept_section, moving_line_filepos, */ \
37380 + 0, NULL, 0, \
37381 + \
37382 + /* target_index, used_by_bfd, constructor_chain, owner, */ \
37383 + 0, NULL, NULL, NULL, \
37384 + \
37385 + /* symbol, symbol_ptr_ptr, */ \
37386 + (struct bfd_symbol *) SYM, &SEC.symbol, \
37387 + \
37388 + /* map_head, map_tail */ \
37389 + { NULL }, { NULL } \
37390 + }
37391 +
37392 +void bfd_section_list_clear (bfd *);
37393 +
37394 +asection *bfd_get_section_by_name (bfd *abfd, const char *name);
37395 +
37396 +asection *bfd_get_section_by_name_if
37397 + (bfd *abfd,
37398 + const char *name,
37399 + bfd_boolean (*func) (bfd *abfd, asection *sect, void *obj),
37400 + void *obj);
37401 +
37402 +char *bfd_get_unique_section_name
37403 + (bfd *abfd, const char *templat, int *count);
37404 +
37405 +asection *bfd_make_section_old_way (bfd *abfd, const char *name);
37406 +
37407 +asection *bfd_make_section_anyway_with_flags
37408 + (bfd *abfd, const char *name, flagword flags);
37409 +
37410 +asection *bfd_make_section_anyway (bfd *abfd, const char *name);
37411 +
37412 +asection *bfd_make_section_with_flags
37413 + (bfd *, const char *name, flagword flags);
37414 +
37415 +asection *bfd_make_section (bfd *, const char *name);
37416 +
37417 +bfd_boolean bfd_set_section_flags
37418 + (bfd *abfd, asection *sec, flagword flags);
37419 +
37420 +void bfd_map_over_sections
37421 + (bfd *abfd,
37422 + void (*func) (bfd *abfd, asection *sect, void *obj),
37423 + void *obj);
37424 +
37425 +asection *bfd_sections_find_if
37426 + (bfd *abfd,
37427 + bfd_boolean (*operation) (bfd *abfd, asection *sect, void *obj),
37428 + void *obj);
37429 +
37430 +bfd_boolean bfd_set_section_size
37431 + (bfd *abfd, asection *sec, bfd_size_type val);
37432 +
37433 +bfd_boolean bfd_set_section_contents
37434 + (bfd *abfd, asection *section, const void *data,
37435 + file_ptr offset, bfd_size_type count);
37436 +
37437 +bfd_boolean bfd_get_section_contents
37438 + (bfd *abfd, asection *section, void *location, file_ptr offset,
37439 + bfd_size_type count);
37440 +
37441 +bfd_boolean bfd_malloc_and_get_section
37442 + (bfd *abfd, asection *section, bfd_byte **buf);
37443 +
37444 +bfd_boolean bfd_copy_private_section_data
37445 + (bfd *ibfd, asection *isec, bfd *obfd, asection *osec);
37446 +
37447 +#define bfd_copy_private_section_data(ibfd, isection, obfd, osection) \
37448 + BFD_SEND (obfd, _bfd_copy_private_section_data, \
37449 + (ibfd, isection, obfd, osection))
37450 +bfd_boolean bfd_generic_is_group_section (bfd *, const asection *sec);
37451 +
37452 +bfd_boolean bfd_generic_discard_group (bfd *abfd, asection *group);
37453 +
37454 +/* Extracted from archures.c. */
37455 +enum bfd_architecture
37456 +{
37457 + bfd_arch_unknown, /* File arch not known. */
37458 + bfd_arch_obscure, /* Arch known, not one of these. */
37459 + bfd_arch_m68k, /* Motorola 68xxx */
37460 +#define bfd_mach_m68000 1
37461 +#define bfd_mach_m68008 2
37462 +#define bfd_mach_m68010 3
37463 +#define bfd_mach_m68020 4
37464 +#define bfd_mach_m68030 5
37465 +#define bfd_mach_m68040 6
37466 +#define bfd_mach_m68060 7
37467 +#define bfd_mach_cpu32 8
37468 +#define bfd_mach_fido 9
37469 +#define bfd_mach_mcf_isa_a_nodiv 10
37470 +#define bfd_mach_mcf_isa_a 11
37471 +#define bfd_mach_mcf_isa_a_mac 12
37472 +#define bfd_mach_mcf_isa_a_emac 13
37473 +#define bfd_mach_mcf_isa_aplus 14
37474 +#define bfd_mach_mcf_isa_aplus_mac 15
37475 +#define bfd_mach_mcf_isa_aplus_emac 16
37476 +#define bfd_mach_mcf_isa_b_nousp 17
37477 +#define bfd_mach_mcf_isa_b_nousp_mac 18
37478 +#define bfd_mach_mcf_isa_b_nousp_emac 19
37479 +#define bfd_mach_mcf_isa_b 20
37480 +#define bfd_mach_mcf_isa_b_mac 21
37481 +#define bfd_mach_mcf_isa_b_emac 22
37482 +#define bfd_mach_mcf_isa_b_float 23
37483 +#define bfd_mach_mcf_isa_b_float_mac 24
37484 +#define bfd_mach_mcf_isa_b_float_emac 25
37485 +#define bfd_mach_mcf_isa_c 26
37486 +#define bfd_mach_mcf_isa_c_mac 27
37487 +#define bfd_mach_mcf_isa_c_emac 28
37488 + bfd_arch_vax, /* DEC Vax */
37489 + bfd_arch_i960, /* Intel 960 */
37490 + /* The order of the following is important.
37491 + lower number indicates a machine type that
37492 + only accepts a subset of the instructions
37493 + available to machines with higher numbers.
37494 + The exception is the "ca", which is
37495 + incompatible with all other machines except
37496 + "core". */
37497 +
37498 +#define bfd_mach_i960_core 1
37499 +#define bfd_mach_i960_ka_sa 2
37500 +#define bfd_mach_i960_kb_sb 3
37501 +#define bfd_mach_i960_mc 4
37502 +#define bfd_mach_i960_xa 5
37503 +#define bfd_mach_i960_ca 6
37504 +#define bfd_mach_i960_jx 7
37505 +#define bfd_mach_i960_hx 8
37506 +
37507 + bfd_arch_or32, /* OpenRISC 32 */
37508 +
37509 + bfd_arch_sparc, /* SPARC */
37510 +#define bfd_mach_sparc 1
37511 +/* The difference between v8plus and v9 is that v9 is a true 64 bit env. */
37512 +#define bfd_mach_sparc_sparclet 2
37513 +#define bfd_mach_sparc_sparclite 3
37514 +#define bfd_mach_sparc_v8plus 4
37515 +#define bfd_mach_sparc_v8plusa 5 /* with ultrasparc add'ns. */
37516 +#define bfd_mach_sparc_sparclite_le 6
37517 +#define bfd_mach_sparc_v9 7
37518 +#define bfd_mach_sparc_v9a 8 /* with ultrasparc add'ns. */
37519 +#define bfd_mach_sparc_v8plusb 9 /* with cheetah add'ns. */
37520 +#define bfd_mach_sparc_v9b 10 /* with cheetah add'ns. */
37521 +/* Nonzero if MACH has the v9 instruction set. */
37522 +#define bfd_mach_sparc_v9_p(mach) \
37523 + ((mach) >= bfd_mach_sparc_v8plus && (mach) <= bfd_mach_sparc_v9b \
37524 + && (mach) != bfd_mach_sparc_sparclite_le)
37525 +/* Nonzero if MACH is a 64 bit sparc architecture. */
37526 +#define bfd_mach_sparc_64bit_p(mach) \
37527 + ((mach) >= bfd_mach_sparc_v9 && (mach) != bfd_mach_sparc_v8plusb)
37528 + bfd_arch_spu, /* PowerPC SPU */
37529 +#define bfd_mach_spu 256
37530 + bfd_arch_mips, /* MIPS Rxxxx */
37531 +#define bfd_mach_mips3000 3000
37532 +#define bfd_mach_mips3900 3900
37533 +#define bfd_mach_mips4000 4000
37534 +#define bfd_mach_mips4010 4010
37535 +#define bfd_mach_mips4100 4100
37536 +#define bfd_mach_mips4111 4111
37537 +#define bfd_mach_mips4120 4120
37538 +#define bfd_mach_mips4300 4300
37539 +#define bfd_mach_mips4400 4400
37540 +#define bfd_mach_mips4600 4600
37541 +#define bfd_mach_mips4650 4650
37542 +#define bfd_mach_mips5000 5000
37543 +#define bfd_mach_mips5400 5400
37544 +#define bfd_mach_mips5500 5500
37545 +#define bfd_mach_mips6000 6000
37546 +#define bfd_mach_mips7000 7000
37547 +#define bfd_mach_mips8000 8000
37548 +#define bfd_mach_mips9000 9000
37549 +#define bfd_mach_mips10000 10000
37550 +#define bfd_mach_mips12000 12000
37551 +#define bfd_mach_mips16 16
37552 +#define bfd_mach_mips5 5
37553 +#define bfd_mach_mips_sb1 12310201 /* octal 'SB', 01 */
37554 +#define bfd_mach_mipsisa32 32
37555 +#define bfd_mach_mipsisa32r2 33
37556 +#define bfd_mach_mipsisa64 64
37557 +#define bfd_mach_mipsisa64r2 65
37558 + bfd_arch_i386, /* Intel 386 */
37559 +#define bfd_mach_i386_i386 1
37560 +#define bfd_mach_i386_i8086 2
37561 +#define bfd_mach_i386_i386_intel_syntax 3
37562 +#define bfd_mach_x86_64 64
37563 +#define bfd_mach_x86_64_intel_syntax 65
37564 + bfd_arch_we32k, /* AT&T WE32xxx */
37565 + bfd_arch_tahoe, /* CCI/Harris Tahoe */
37566 + bfd_arch_i860, /* Intel 860 */
37567 + bfd_arch_i370, /* IBM 360/370 Mainframes */
37568 + bfd_arch_romp, /* IBM ROMP PC/RT */
37569 + bfd_arch_convex, /* Convex */
37570 + bfd_arch_m88k, /* Motorola 88xxx */
37571 + bfd_arch_m98k, /* Motorola 98xxx */
37572 + bfd_arch_pyramid, /* Pyramid Technology */
37573 + bfd_arch_h8300, /* Renesas H8/300 (formerly Hitachi H8/300) */
37574 +#define bfd_mach_h8300 1
37575 +#define bfd_mach_h8300h 2
37576 +#define bfd_mach_h8300s 3
37577 +#define bfd_mach_h8300hn 4
37578 +#define bfd_mach_h8300sn 5
37579 +#define bfd_mach_h8300sx 6
37580 +#define bfd_mach_h8300sxn 7
37581 + bfd_arch_pdp11, /* DEC PDP-11 */
37582 + bfd_arch_powerpc, /* PowerPC */
37583 +#define bfd_mach_ppc 32
37584 +#define bfd_mach_ppc64 64
37585 +#define bfd_mach_ppc_403 403
37586 +#define bfd_mach_ppc_403gc 4030
37587 +#define bfd_mach_ppc_505 505
37588 +#define bfd_mach_ppc_601 601
37589 +#define bfd_mach_ppc_602 602
37590 +#define bfd_mach_ppc_603 603
37591 +#define bfd_mach_ppc_ec603e 6031
37592 +#define bfd_mach_ppc_604 604
37593 +#define bfd_mach_ppc_620 620
37594 +#define bfd_mach_ppc_630 630
37595 +#define bfd_mach_ppc_750 750
37596 +#define bfd_mach_ppc_860 860
37597 +#define bfd_mach_ppc_a35 35
37598 +#define bfd_mach_ppc_rs64ii 642
37599 +#define bfd_mach_ppc_rs64iii 643
37600 +#define bfd_mach_ppc_7400 7400
37601 +#define bfd_mach_ppc_e500 500
37602 + bfd_arch_rs6000, /* IBM RS/6000 */
37603 +#define bfd_mach_rs6k 6000
37604 +#define bfd_mach_rs6k_rs1 6001
37605 +#define bfd_mach_rs6k_rsc 6003
37606 +#define bfd_mach_rs6k_rs2 6002
37607 + bfd_arch_hppa, /* HP PA RISC */
37608 +#define bfd_mach_hppa10 10
37609 +#define bfd_mach_hppa11 11
37610 +#define bfd_mach_hppa20 20
37611 +#define bfd_mach_hppa20w 25
37612 + bfd_arch_d10v, /* Mitsubishi D10V */
37613 +#define bfd_mach_d10v 1
37614 +#define bfd_mach_d10v_ts2 2
37615 +#define bfd_mach_d10v_ts3 3
37616 + bfd_arch_d30v, /* Mitsubishi D30V */
37617 + bfd_arch_dlx, /* DLX */
37618 + bfd_arch_m68hc11, /* Motorola 68HC11 */
37619 + bfd_arch_m68hc12, /* Motorola 68HC12 */
37620 +#define bfd_mach_m6812_default 0
37621 +#define bfd_mach_m6812 1
37622 +#define bfd_mach_m6812s 2
37623 + bfd_arch_z8k, /* Zilog Z8000 */
37624 +#define bfd_mach_z8001 1
37625 +#define bfd_mach_z8002 2
37626 + bfd_arch_h8500, /* Renesas H8/500 (formerly Hitachi H8/500) */
37627 + bfd_arch_sh, /* Renesas / SuperH SH (formerly Hitachi SH) */
37628 +#define bfd_mach_sh 1
37629 +#define bfd_mach_sh2 0x20
37630 +#define bfd_mach_sh_dsp 0x2d
37631 +#define bfd_mach_sh2a 0x2a
37632 +#define bfd_mach_sh2a_nofpu 0x2b
37633 +#define bfd_mach_sh2a_nofpu_or_sh4_nommu_nofpu 0x2a1
37634 +#define bfd_mach_sh2a_nofpu_or_sh3_nommu 0x2a2
37635 +#define bfd_mach_sh2a_or_sh4 0x2a3
37636 +#define bfd_mach_sh2a_or_sh3e 0x2a4
37637 +#define bfd_mach_sh2e 0x2e
37638 +#define bfd_mach_sh3 0x30
37639 +#define bfd_mach_sh3_nommu 0x31
37640 +#define bfd_mach_sh3_dsp 0x3d
37641 +#define bfd_mach_sh3e 0x3e
37642 +#define bfd_mach_sh4 0x40
37643 +#define bfd_mach_sh4_nofpu 0x41
37644 +#define bfd_mach_sh4_nommu_nofpu 0x42
37645 +#define bfd_mach_sh4a 0x4a
37646 +#define bfd_mach_sh4a_nofpu 0x4b
37647 +#define bfd_mach_sh4al_dsp 0x4d
37648 +#define bfd_mach_sh5 0x50
37649 + bfd_arch_alpha, /* Dec Alpha */
37650 +#define bfd_mach_alpha_ev4 0x10
37651 +#define bfd_mach_alpha_ev5 0x20
37652 +#define bfd_mach_alpha_ev6 0x30
37653 + bfd_arch_arm, /* Advanced Risc Machines ARM. */
37654 +#define bfd_mach_arm_unknown 0
37655 +#define bfd_mach_arm_2 1
37656 +#define bfd_mach_arm_2a 2
37657 +#define bfd_mach_arm_3 3
37658 +#define bfd_mach_arm_3M 4
37659 +#define bfd_mach_arm_4 5
37660 +#define bfd_mach_arm_4T 6
37661 +#define bfd_mach_arm_5 7
37662 +#define bfd_mach_arm_5T 8
37663 +#define bfd_mach_arm_5TE 9
37664 +#define bfd_mach_arm_XScale 10
37665 +#define bfd_mach_arm_ep9312 11
37666 +#define bfd_mach_arm_iWMMXt 12
37667 +#define bfd_mach_arm_iWMMXt2 13
37668 + bfd_arch_ns32k, /* National Semiconductors ns32000 */
37669 + bfd_arch_w65, /* WDC 65816 */
37670 + bfd_arch_tic30, /* Texas Instruments TMS320C30 */
37671 + bfd_arch_tic4x, /* Texas Instruments TMS320C3X/4X */
37672 +#define bfd_mach_tic3x 30
37673 +#define bfd_mach_tic4x 40
37674 + bfd_arch_tic54x, /* Texas Instruments TMS320C54X */
37675 + bfd_arch_tic80, /* TI TMS320c80 (MVP) */
37676 + bfd_arch_v850, /* NEC V850 */
37677 +#define bfd_mach_v850 1
37678 +#define bfd_mach_v850e 'E'
37679 +#define bfd_mach_v850e1 '1'
37680 + bfd_arch_arc, /* ARC Cores */
37681 +#define bfd_mach_arc_5 5
37682 +#define bfd_mach_arc_6 6
37683 +#define bfd_mach_arc_7 7
37684 +#define bfd_mach_arc_8 8
37685 + bfd_arch_m32c, /* Renesas M16C/M32C. */
37686 +#define bfd_mach_m16c 0x75
37687 +#define bfd_mach_m32c 0x78
37688 + bfd_arch_m32r, /* Renesas M32R (formerly Mitsubishi M32R/D) */
37689 +#define bfd_mach_m32r 1 /* For backwards compatibility. */
37690 +#define bfd_mach_m32rx 'x'
37691 +#define bfd_mach_m32r2 '2'
37692 + bfd_arch_mn10200, /* Matsushita MN10200 */
37693 + bfd_arch_mn10300, /* Matsushita MN10300 */
37694 +#define bfd_mach_mn10300 300
37695 +#define bfd_mach_am33 330
37696 +#define bfd_mach_am33_2 332
37697 + bfd_arch_fr30,
37698 +#define bfd_mach_fr30 0x46523330
37699 + bfd_arch_frv,
37700 +#define bfd_mach_frv 1
37701 +#define bfd_mach_frvsimple 2
37702 +#define bfd_mach_fr300 300
37703 +#define bfd_mach_fr400 400
37704 +#define bfd_mach_fr450 450
37705 +#define bfd_mach_frvtomcat 499 /* fr500 prototype */
37706 +#define bfd_mach_fr500 500
37707 +#define bfd_mach_fr550 550
37708 + bfd_arch_mcore,
37709 + bfd_arch_mep,
37710 +#define bfd_mach_mep 1
37711 +#define bfd_mach_mep_h1 0x6831
37712 + bfd_arch_ia64, /* HP/Intel ia64 */
37713 +#define bfd_mach_ia64_elf64 64
37714 +#define bfd_mach_ia64_elf32 32
37715 + bfd_arch_ip2k, /* Ubicom IP2K microcontrollers. */
37716 +#define bfd_mach_ip2022 1
37717 +#define bfd_mach_ip2022ext 2
37718 + bfd_arch_iq2000, /* Vitesse IQ2000. */
37719 +#define bfd_mach_iq2000 1
37720 +#define bfd_mach_iq10 2
37721 + bfd_arch_mt,
37722 +#define bfd_mach_ms1 1
37723 +#define bfd_mach_mrisc2 2
37724 +#define bfd_mach_ms2 3
37725 + bfd_arch_pj,
37726 + bfd_arch_avr, /* Atmel AVR microcontrollers. */
37727 +#define bfd_mach_avr1 1
37728 +#define bfd_mach_avr2 2
37729 +#define bfd_mach_avr3 3
37730 +#define bfd_mach_avr4 4
37731 +#define bfd_mach_avr5 5
37732 +#define bfd_mach_avr6 6
37733 + bfd_arch_avr32, /* Atmel AVR32 */
37734 +#define bfd_mach_avr32_ap 7000
37735 +#define bfd_mach_avr32_uc 3000
37736 +#define bfd_mach_avr32_ucr1 3001
37737 +#define bfd_mach_avr32_ucr2 3002
37738 + bfd_arch_bfin, /* ADI Blackfin */
37739 +#define bfd_mach_bfin 1
37740 + bfd_arch_cr16, /* National Semiconductor CompactRISC (ie CR16). */
37741 +#define bfd_mach_cr16 1
37742 + bfd_arch_cr16c, /* National Semiconductor CompactRISC. */
37743 +#define bfd_mach_cr16c 1
37744 + bfd_arch_crx, /* National Semiconductor CRX. */
37745 +#define bfd_mach_crx 1
37746 + bfd_arch_cris, /* Axis CRIS */
37747 +#define bfd_mach_cris_v0_v10 255
37748 +#define bfd_mach_cris_v32 32
37749 +#define bfd_mach_cris_v10_v32 1032
37750 + bfd_arch_s390, /* IBM s390 */
37751 +#define bfd_mach_s390_31 31
37752 +#define bfd_mach_s390_64 64
37753 + bfd_arch_score, /* Sunplus score */
37754 + bfd_arch_openrisc, /* OpenRISC */
37755 + bfd_arch_mmix, /* Donald Knuth's educational processor. */
37756 + bfd_arch_xstormy16,
37757 +#define bfd_mach_xstormy16 1
37758 + bfd_arch_msp430, /* Texas Instruments MSP430 architecture. */
37759 +#define bfd_mach_msp11 11
37760 +#define bfd_mach_msp110 110
37761 +#define bfd_mach_msp12 12
37762 +#define bfd_mach_msp13 13
37763 +#define bfd_mach_msp14 14
37764 +#define bfd_mach_msp15 15
37765 +#define bfd_mach_msp16 16
37766 +#define bfd_mach_msp21 21
37767 +#define bfd_mach_msp31 31
37768 +#define bfd_mach_msp32 32
37769 +#define bfd_mach_msp33 33
37770 +#define bfd_mach_msp41 41
37771 +#define bfd_mach_msp42 42
37772 +#define bfd_mach_msp43 43
37773 +#define bfd_mach_msp44 44
37774 + bfd_arch_xc16x, /* Infineon's XC16X Series. */
37775 +#define bfd_mach_xc16x 1
37776 +#define bfd_mach_xc16xl 2
37777 +#define bfd_mach_xc16xs 3
37778 + bfd_arch_xtensa, /* Tensilica's Xtensa cores. */
37779 +#define bfd_mach_xtensa 1
37780 + bfd_arch_maxq, /* Dallas MAXQ 10/20 */
37781 +#define bfd_mach_maxq10 10
37782 +#define bfd_mach_maxq20 20
37783 + bfd_arch_z80,
37784 +#define bfd_mach_z80strict 1 /* No undocumented opcodes. */
37785 +#define bfd_mach_z80 3 /* With ixl, ixh, iyl, and iyh. */
37786 +#define bfd_mach_z80full 7 /* All undocumented instructions. */
37787 +#define bfd_mach_r800 11 /* R800: successor with multiplication. */
37788 + bfd_arch_last
37789 + };
37790 +
37791 +typedef struct bfd_arch_info
37792 +{
37793 + int bits_per_word;
37794 + int bits_per_address;
37795 + int bits_per_byte;
37796 + enum bfd_architecture arch;
37797 + unsigned long mach;
37798 + const char *arch_name;
37799 + const char *printable_name;
37800 + unsigned int section_align_power;
37801 + /* TRUE if this is the default machine for the architecture.
37802 + The default arch should be the first entry for an arch so that
37803 + all the entries for that arch can be accessed via <<next>>. */
37804 + bfd_boolean the_default;
37805 + const struct bfd_arch_info * (*compatible)
37806 + (const struct bfd_arch_info *a, const struct bfd_arch_info *b);
37807 +
37808 + bfd_boolean (*scan) (const struct bfd_arch_info *, const char *);
37809 +
37810 + const struct bfd_arch_info *next;
37811 +}
37812 +bfd_arch_info_type;
37813 +
37814 +const char *bfd_printable_name (bfd *abfd);
37815 +
37816 +const bfd_arch_info_type *bfd_scan_arch (const char *string);
37817 +
37818 +const char **bfd_arch_list (void);
37819 +
37820 +const bfd_arch_info_type *bfd_arch_get_compatible
37821 + (const bfd *abfd, const bfd *bbfd, bfd_boolean accept_unknowns);
37822 +
37823 +void bfd_set_arch_info (bfd *abfd, const bfd_arch_info_type *arg);
37824 +
37825 +enum bfd_architecture bfd_get_arch (bfd *abfd);
37826 +
37827 +unsigned long bfd_get_mach (bfd *abfd);
37828 +
37829 +unsigned int bfd_arch_bits_per_byte (bfd *abfd);
37830 +
37831 +unsigned int bfd_arch_bits_per_address (bfd *abfd);
37832 +
37833 +const bfd_arch_info_type *bfd_get_arch_info (bfd *abfd);
37834 +
37835 +const bfd_arch_info_type *bfd_lookup_arch
37836 + (enum bfd_architecture arch, unsigned long machine);
37837 +
37838 +const char *bfd_printable_arch_mach
37839 + (enum bfd_architecture arch, unsigned long machine);
37840 +
37841 +unsigned int bfd_octets_per_byte (bfd *abfd);
37842 +
37843 +unsigned int bfd_arch_mach_octets_per_byte
37844 + (enum bfd_architecture arch, unsigned long machine);
37845 +
37846 +/* Extracted from reloc.c. */
37847 +typedef enum bfd_reloc_status
37848 +{
37849 + /* No errors detected. */
37850 + bfd_reloc_ok,
37851 +
37852 + /* The relocation was performed, but there was an overflow. */
37853 + bfd_reloc_overflow,
37854 +
37855 + /* The address to relocate was not within the section supplied. */
37856 + bfd_reloc_outofrange,
37857 +
37858 + /* Used by special functions. */
37859 + bfd_reloc_continue,
37860 +
37861 + /* Unsupported relocation size requested. */
37862 + bfd_reloc_notsupported,
37863 +
37864 + /* Unused. */
37865 + bfd_reloc_other,
37866 +
37867 + /* The symbol to relocate against was undefined. */
37868 + bfd_reloc_undefined,
37869 +
37870 + /* The relocation was performed, but may not be ok - presently
37871 + generated only when linking i960 coff files with i960 b.out
37872 + symbols. If this type is returned, the error_message argument
37873 + to bfd_perform_relocation will be set. */
37874 + bfd_reloc_dangerous
37875 + }
37876 + bfd_reloc_status_type;
37877 +
37878 +
37879 +typedef struct reloc_cache_entry
37880 +{
37881 + /* A pointer into the canonical table of pointers. */
37882 + struct bfd_symbol **sym_ptr_ptr;
37883 +
37884 + /* offset in section. */
37885 + bfd_size_type address;
37886 +
37887 + /* addend for relocation value. */
37888 + bfd_vma addend;
37889 +
37890 + /* Pointer to how to perform the required relocation. */
37891 + reloc_howto_type *howto;
37892 +
37893 +}
37894 +arelent;
37895 +
37896 +enum complain_overflow
37897 +{
37898 + /* Do not complain on overflow. */
37899 + complain_overflow_dont,
37900 +
37901 + /* Complain if the value overflows when considered as a signed
37902 + number one bit larger than the field. ie. A bitfield of N bits
37903 + is allowed to represent -2**n to 2**n-1. */
37904 + complain_overflow_bitfield,
37905 +
37906 + /* Complain if the value overflows when considered as a signed
37907 + number. */
37908 + complain_overflow_signed,
37909 +
37910 + /* Complain if the value overflows when considered as an
37911 + unsigned number. */
37912 + complain_overflow_unsigned
37913 +};
37914 +
37915 +struct reloc_howto_struct
37916 +{
37917 + /* The type field has mainly a documentary use - the back end can
37918 + do what it wants with it, though normally the back end's
37919 + external idea of what a reloc number is stored
37920 + in this field. For example, a PC relative word relocation
37921 + in a coff environment has the type 023 - because that's
37922 + what the outside world calls a R_PCRWORD reloc. */
37923 + unsigned int type;
37924 +
37925 + /* The value the final relocation is shifted right by. This drops
37926 + unwanted data from the relocation. */
37927 + unsigned int rightshift;
37928 +
37929 + /* The size of the item to be relocated. This is *not* a
37930 + power-of-two measure. To get the number of bytes operated
37931 + on by a type of relocation, use bfd_get_reloc_size. */
37932 + int size;
37933 +
37934 + /* The number of bits in the item to be relocated. This is used
37935 + when doing overflow checking. */
37936 + unsigned int bitsize;
37937 +
37938 + /* Notes that the relocation is relative to the location in the
37939 + data section of the addend. The relocation function will
37940 + subtract from the relocation value the address of the location
37941 + being relocated. */
37942 + bfd_boolean pc_relative;
37943 +
37944 + /* The bit position of the reloc value in the destination.
37945 + The relocated value is left shifted by this amount. */
37946 + unsigned int bitpos;
37947 +
37948 + /* What type of overflow error should be checked for when
37949 + relocating. */
37950 + enum complain_overflow complain_on_overflow;
37951 +
37952 + /* If this field is non null, then the supplied function is
37953 + called rather than the normal function. This allows really
37954 + strange relocation methods to be accommodated (e.g., i960 callj
37955 + instructions). */
37956 + bfd_reloc_status_type (*special_function)
37957 + (bfd *, arelent *, struct bfd_symbol *, void *, asection *,
37958 + bfd *, char **);
37959 +
37960 + /* The textual name of the relocation type. */
37961 + char *name;
37962 +
37963 + /* Some formats record a relocation addend in the section contents
37964 + rather than with the relocation. For ELF formats this is the
37965 + distinction between USE_REL and USE_RELA (though the code checks
37966 + for USE_REL == 1/0). The value of this field is TRUE if the
37967 + addend is recorded with the section contents; when performing a
37968 + partial link (ld -r) the section contents (the data) will be
37969 + modified. The value of this field is FALSE if addends are
37970 + recorded with the relocation (in arelent.addend); when performing
37971 + a partial link the relocation will be modified.
37972 + All relocations for all ELF USE_RELA targets should set this field
37973 + to FALSE (values of TRUE should be looked on with suspicion).
37974 + However, the converse is not true: not all relocations of all ELF
37975 + USE_REL targets set this field to TRUE. Why this is so is peculiar
37976 + to each particular target. For relocs that aren't used in partial
37977 + links (e.g. GOT stuff) it doesn't matter what this is set to. */
37978 + bfd_boolean partial_inplace;
37979 +
37980 + /* src_mask selects the part of the instruction (or data) to be used
37981 + in the relocation sum. If the target relocations don't have an
37982 + addend in the reloc, eg. ELF USE_REL, src_mask will normally equal
37983 + dst_mask to extract the addend from the section contents. If
37984 + relocations do have an addend in the reloc, eg. ELF USE_RELA, this
37985 + field should be zero. Non-zero values for ELF USE_RELA targets are
37986 + bogus as in those cases the value in the dst_mask part of the
37987 + section contents should be treated as garbage. */
37988 + bfd_vma src_mask;
37989 +
37990 + /* dst_mask selects which parts of the instruction (or data) are
37991 + replaced with a relocated value. */
37992 + bfd_vma dst_mask;
37993 +
37994 + /* When some formats create PC relative instructions, they leave
37995 + the value of the pc of the place being relocated in the offset
37996 + slot of the instruction, so that a PC relative relocation can
37997 + be made just by adding in an ordinary offset (e.g., sun3 a.out).
37998 + Some formats leave the displacement part of an instruction
37999 + empty (e.g., m88k bcs); this flag signals the fact. */
38000 + bfd_boolean pcrel_offset;
38001 +};
38002 +
38003 +#define HOWTO(C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC) \
38004 + { (unsigned) C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC }
38005 +#define NEWHOWTO(FUNCTION, NAME, SIZE, REL, IN) \
38006 + HOWTO (0, 0, SIZE, 0, REL, 0, complain_overflow_dont, FUNCTION, \
38007 + NAME, FALSE, 0, 0, IN)
38008 +
38009 +#define EMPTY_HOWTO(C) \
38010 + HOWTO ((C), 0, 0, 0, FALSE, 0, complain_overflow_dont, NULL, \
38011 + NULL, FALSE, 0, 0, FALSE)
38012 +
38013 +#define HOWTO_PREPARE(relocation, symbol) \
38014 + { \
38015 + if (symbol != NULL) \
38016 + { \
38017 + if (bfd_is_com_section (symbol->section)) \
38018 + { \
38019 + relocation = 0; \
38020 + } \
38021 + else \
38022 + { \
38023 + relocation = symbol->value; \
38024 + } \
38025 + } \
38026 + }
38027 +
38028 +unsigned int bfd_get_reloc_size (reloc_howto_type *);
38029 +
38030 +typedef struct relent_chain
38031 +{
38032 + arelent relent;
38033 + struct relent_chain *next;
38034 +}
38035 +arelent_chain;
38036 +
38037 +bfd_reloc_status_type bfd_check_overflow
38038 + (enum complain_overflow how,
38039 + unsigned int bitsize,
38040 + unsigned int rightshift,
38041 + unsigned int addrsize,
38042 + bfd_vma relocation);
38043 +
38044 +bfd_reloc_status_type bfd_perform_relocation
38045 + (bfd *abfd,
38046 + arelent *reloc_entry,
38047 + void *data,
38048 + asection *input_section,
38049 + bfd *output_bfd,
38050 + char **error_message);
38051 +
38052 +bfd_reloc_status_type bfd_install_relocation
38053 + (bfd *abfd,
38054 + arelent *reloc_entry,
38055 + void *data, bfd_vma data_start,
38056 + asection *input_section,
38057 + char **error_message);
38058 +
38059 +enum bfd_reloc_code_real {
38060 + _dummy_first_bfd_reloc_code_real,
38061 +
38062 +
38063 +/* Basic absolute relocations of N bits. */
38064 + BFD_RELOC_64,
38065 + BFD_RELOC_32,
38066 + BFD_RELOC_26,
38067 + BFD_RELOC_24,
38068 + BFD_RELOC_16,
38069 + BFD_RELOC_14,
38070 + BFD_RELOC_8,
38071 +
38072 +/* PC-relative relocations. Sometimes these are relative to the address
38073 +of the relocation itself; sometimes they are relative to the start of
38074 +the section containing the relocation. It depends on the specific target.
38075 +
38076 +The 24-bit relocation is used in some Intel 960 configurations. */
38077 + BFD_RELOC_64_PCREL,
38078 + BFD_RELOC_32_PCREL,
38079 + BFD_RELOC_24_PCREL,
38080 + BFD_RELOC_16_PCREL,
38081 + BFD_RELOC_12_PCREL,
38082 + BFD_RELOC_8_PCREL,
38083 +
38084 +/* Section relative relocations. Some targets need this for DWARF2. */
38085 + BFD_RELOC_32_SECREL,
38086 +
38087 +/* For ELF. */
38088 + BFD_RELOC_32_GOT_PCREL,
38089 + BFD_RELOC_16_GOT_PCREL,
38090 + BFD_RELOC_8_GOT_PCREL,
38091 + BFD_RELOC_32_GOTOFF,
38092 + BFD_RELOC_16_GOTOFF,
38093 + BFD_RELOC_LO16_GOTOFF,
38094 + BFD_RELOC_HI16_GOTOFF,
38095 + BFD_RELOC_HI16_S_GOTOFF,
38096 + BFD_RELOC_8_GOTOFF,
38097 + BFD_RELOC_64_PLT_PCREL,
38098 + BFD_RELOC_32_PLT_PCREL,
38099 + BFD_RELOC_24_PLT_PCREL,
38100 + BFD_RELOC_16_PLT_PCREL,
38101 + BFD_RELOC_8_PLT_PCREL,
38102 + BFD_RELOC_64_PLTOFF,
38103 + BFD_RELOC_32_PLTOFF,
38104 + BFD_RELOC_16_PLTOFF,
38105 + BFD_RELOC_LO16_PLTOFF,
38106 + BFD_RELOC_HI16_PLTOFF,
38107 + BFD_RELOC_HI16_S_PLTOFF,
38108 + BFD_RELOC_8_PLTOFF,
38109 +
38110 +/* Relocations used by 68K ELF. */
38111 + BFD_RELOC_68K_GLOB_DAT,
38112 + BFD_RELOC_68K_JMP_SLOT,
38113 + BFD_RELOC_68K_RELATIVE,
38114 +
38115 +/* Linkage-table relative. */
38116 + BFD_RELOC_32_BASEREL,
38117 + BFD_RELOC_16_BASEREL,
38118 + BFD_RELOC_LO16_BASEREL,
38119 + BFD_RELOC_HI16_BASEREL,
38120 + BFD_RELOC_HI16_S_BASEREL,
38121 + BFD_RELOC_8_BASEREL,
38122 + BFD_RELOC_RVA,
38123 +
38124 +/* Absolute 8-bit relocation, but used to form an address like 0xFFnn. */
38125 + BFD_RELOC_8_FFnn,
38126 +
38127 +/* These PC-relative relocations are stored as word displacements --
38128 +i.e., byte displacements shifted right two bits. The 30-bit word
38129 +displacement (<<32_PCREL_S2>> -- 32 bits, shifted 2) is used on the
38130 +SPARC. (SPARC tools generally refer to this as <<WDISP30>>.) The
38131 +signed 16-bit displacement is used on the MIPS, and the 23-bit
38132 +displacement is used on the Alpha. */
38133 + BFD_RELOC_32_PCREL_S2,
38134 + BFD_RELOC_16_PCREL_S2,
38135 + BFD_RELOC_23_PCREL_S2,
38136 +
38137 +/* High 22 bits and low 10 bits of 32-bit value, placed into lower bits of
38138 +the target word. These are used on the SPARC. */
38139 + BFD_RELOC_HI22,
38140 + BFD_RELOC_LO10,
38141 +
38142 +/* For systems that allocate a Global Pointer register, these are
38143 +displacements off that register. These relocation types are
38144 +handled specially, because the value the register will have is
38145 +decided relatively late. */
38146 + BFD_RELOC_GPREL16,
38147 + BFD_RELOC_GPREL32,
38148 +
38149 +/* Reloc types used for i960/b.out. */
38150 + BFD_RELOC_I960_CALLJ,
38151 +
38152 +/* SPARC ELF relocations. There is probably some overlap with other
38153 +relocation types already defined. */
38154 + BFD_RELOC_NONE,
38155 + BFD_RELOC_SPARC_WDISP22,
38156 + BFD_RELOC_SPARC22,
38157 + BFD_RELOC_SPARC13,
38158 + BFD_RELOC_SPARC_GOT10,
38159 + BFD_RELOC_SPARC_GOT13,
38160 + BFD_RELOC_SPARC_GOT22,
38161 + BFD_RELOC_SPARC_PC10,
38162 + BFD_RELOC_SPARC_PC22,
38163 + BFD_RELOC_SPARC_WPLT30,
38164 + BFD_RELOC_SPARC_COPY,
38165 + BFD_RELOC_SPARC_GLOB_DAT,
38166 + BFD_RELOC_SPARC_JMP_SLOT,
38167 + BFD_RELOC_SPARC_RELATIVE,
38168 + BFD_RELOC_SPARC_UA16,
38169 + BFD_RELOC_SPARC_UA32,
38170 + BFD_RELOC_SPARC_UA64,
38171 +
38172 +/* I think these are specific to SPARC a.out (e.g., Sun 4). */
38173 + BFD_RELOC_SPARC_BASE13,
38174 + BFD_RELOC_SPARC_BASE22,
38175 +
38176 +/* SPARC64 relocations */
38177 +#define BFD_RELOC_SPARC_64 BFD_RELOC_64
38178 + BFD_RELOC_SPARC_10,
38179 + BFD_RELOC_SPARC_11,
38180 + BFD_RELOC_SPARC_OLO10,
38181 + BFD_RELOC_SPARC_HH22,
38182 + BFD_RELOC_SPARC_HM10,
38183 + BFD_RELOC_SPARC_LM22,
38184 + BFD_RELOC_SPARC_PC_HH22,
38185 + BFD_RELOC_SPARC_PC_HM10,
38186 + BFD_RELOC_SPARC_PC_LM22,
38187 + BFD_RELOC_SPARC_WDISP16,
38188 + BFD_RELOC_SPARC_WDISP19,
38189 + BFD_RELOC_SPARC_7,
38190 + BFD_RELOC_SPARC_6,
38191 + BFD_RELOC_SPARC_5,
38192 +#define BFD_RELOC_SPARC_DISP64 BFD_RELOC_64_PCREL
38193 + BFD_RELOC_SPARC_PLT32,
38194 + BFD_RELOC_SPARC_PLT64,
38195 + BFD_RELOC_SPARC_HIX22,
38196 + BFD_RELOC_SPARC_LOX10,
38197 + BFD_RELOC_SPARC_H44,
38198 + BFD_RELOC_SPARC_M44,
38199 + BFD_RELOC_SPARC_L44,
38200 + BFD_RELOC_SPARC_REGISTER,
38201 +
38202 +/* SPARC little endian relocation */
38203 + BFD_RELOC_SPARC_REV32,
38204 +
38205 +/* SPARC TLS relocations */
38206 + BFD_RELOC_SPARC_TLS_GD_HI22,
38207 + BFD_RELOC_SPARC_TLS_GD_LO10,
38208 + BFD_RELOC_SPARC_TLS_GD_ADD,
38209 + BFD_RELOC_SPARC_TLS_GD_CALL,
38210 + BFD_RELOC_SPARC_TLS_LDM_HI22,
38211 + BFD_RELOC_SPARC_TLS_LDM_LO10,
38212 + BFD_RELOC_SPARC_TLS_LDM_ADD,
38213 + BFD_RELOC_SPARC_TLS_LDM_CALL,
38214 + BFD_RELOC_SPARC_TLS_LDO_HIX22,
38215 + BFD_RELOC_SPARC_TLS_LDO_LOX10,
38216 + BFD_RELOC_SPARC_TLS_LDO_ADD,
38217 + BFD_RELOC_SPARC_TLS_IE_HI22,
38218 + BFD_RELOC_SPARC_TLS_IE_LO10,
38219 + BFD_RELOC_SPARC_TLS_IE_LD,
38220 + BFD_RELOC_SPARC_TLS_IE_LDX,
38221 + BFD_RELOC_SPARC_TLS_IE_ADD,
38222 + BFD_RELOC_SPARC_TLS_LE_HIX22,
38223 + BFD_RELOC_SPARC_TLS_LE_LOX10,
38224 + BFD_RELOC_SPARC_TLS_DTPMOD32,
38225 + BFD_RELOC_SPARC_TLS_DTPMOD64,
38226 + BFD_RELOC_SPARC_TLS_DTPOFF32,
38227 + BFD_RELOC_SPARC_TLS_DTPOFF64,
38228 + BFD_RELOC_SPARC_TLS_TPOFF32,
38229 + BFD_RELOC_SPARC_TLS_TPOFF64,
38230 +
38231 +/* SPU Relocations. */
38232 + BFD_RELOC_SPU_IMM7,
38233 + BFD_RELOC_SPU_IMM8,
38234 + BFD_RELOC_SPU_IMM10,
38235 + BFD_RELOC_SPU_IMM10W,
38236 + BFD_RELOC_SPU_IMM16,
38237 + BFD_RELOC_SPU_IMM16W,
38238 + BFD_RELOC_SPU_IMM18,
38239 + BFD_RELOC_SPU_PCREL9a,
38240 + BFD_RELOC_SPU_PCREL9b,
38241 + BFD_RELOC_SPU_PCREL16,
38242 + BFD_RELOC_SPU_LO16,
38243 + BFD_RELOC_SPU_HI16,
38244 + BFD_RELOC_SPU_PPU32,
38245 + BFD_RELOC_SPU_PPU64,
38246 +
38247 +/* Alpha ECOFF and ELF relocations. Some of these treat the symbol or
38248 +"addend" in some special way.
38249 +For GPDISP_HI16 ("gpdisp") relocations, the symbol is ignored when
38250 +writing; when reading, it will be the absolute section symbol. The
38251 +addend is the displacement in bytes of the "lda" instruction from
38252 +the "ldah" instruction (which is at the address of this reloc). */
38253 + BFD_RELOC_ALPHA_GPDISP_HI16,
38254 +
38255 +/* For GPDISP_LO16 ("ignore") relocations, the symbol is handled as
38256 +with GPDISP_HI16 relocs. The addend is ignored when writing the
38257 +relocations out, and is filled in with the file's GP value on
38258 +reading, for convenience. */
38259 + BFD_RELOC_ALPHA_GPDISP_LO16,
38260 +
38261 +/* The ELF GPDISP relocation is exactly the same as the GPDISP_HI16
38262 +relocation except that there is no accompanying GPDISP_LO16
38263 +relocation. */
38264 + BFD_RELOC_ALPHA_GPDISP,
38265 +
38266 +/* The Alpha LITERAL/LITUSE relocs are produced by a symbol reference;
38267 +the assembler turns it into a LDQ instruction to load the address of
38268 +the symbol, and then fills in a register in the real instruction.
38269 +
38270 +The LITERAL reloc, at the LDQ instruction, refers to the .lita
38271 +section symbol. The addend is ignored when writing, but is filled
38272 +in with the file's GP value on reading, for convenience, as with the
38273 +GPDISP_LO16 reloc.
38274 +
38275 +The ELF_LITERAL reloc is somewhere between 16_GOTOFF and GPDISP_LO16.
38276 +It should refer to the symbol to be referenced, as with 16_GOTOFF,
38277 +but it generates output not based on the position within the .got
38278 +section, but relative to the GP value chosen for the file during the
38279 +final link stage.
38280 +
38281 +The LITUSE reloc, on the instruction using the loaded address, gives
38282 +information to the linker that it might be able to use to optimize
38283 +away some literal section references. The symbol is ignored (read
38284 +as the absolute section symbol), and the "addend" indicates the type
38285 +of instruction using the register:
38286 +1 - "memory" fmt insn
38287 +2 - byte-manipulation (byte offset reg)
38288 +3 - jsr (target of branch) */
38289 + BFD_RELOC_ALPHA_LITERAL,
38290 + BFD_RELOC_ALPHA_ELF_LITERAL,
38291 + BFD_RELOC_ALPHA_LITUSE,
38292 +
38293 +/* The HINT relocation indicates a value that should be filled into the
38294 +"hint" field of a jmp/jsr/ret instruction, for possible branch-
38295 +prediction logic which may be provided on some processors. */
38296 + BFD_RELOC_ALPHA_HINT,
38297 +
38298 +/* The LINKAGE relocation outputs a linkage pair in the object file,
38299 +which is filled by the linker. */
38300 + BFD_RELOC_ALPHA_LINKAGE,
38301 +
38302 +/* The CODEADDR relocation outputs a STO_CA in the object file,
38303 +which is filled by the linker. */
38304 + BFD_RELOC_ALPHA_CODEADDR,
38305 +
38306 +/* The GPREL_HI/LO relocations together form a 32-bit offset from the
38307 +GP register. */
38308 + BFD_RELOC_ALPHA_GPREL_HI16,
38309 + BFD_RELOC_ALPHA_GPREL_LO16,
38310 +
38311 +/* Like BFD_RELOC_23_PCREL_S2, except that the source and target must
38312 +share a common GP, and the target address is adjusted for
38313 +STO_ALPHA_STD_GPLOAD. */
38314 + BFD_RELOC_ALPHA_BRSGP,
38315 +
38316 +/* Alpha thread-local storage relocations. */
38317 + BFD_RELOC_ALPHA_TLSGD,
38318 + BFD_RELOC_ALPHA_TLSLDM,
38319 + BFD_RELOC_ALPHA_DTPMOD64,
38320 + BFD_RELOC_ALPHA_GOTDTPREL16,
38321 + BFD_RELOC_ALPHA_DTPREL64,
38322 + BFD_RELOC_ALPHA_DTPREL_HI16,
38323 + BFD_RELOC_ALPHA_DTPREL_LO16,
38324 + BFD_RELOC_ALPHA_DTPREL16,
38325 + BFD_RELOC_ALPHA_GOTTPREL16,
38326 + BFD_RELOC_ALPHA_TPREL64,
38327 + BFD_RELOC_ALPHA_TPREL_HI16,
38328 + BFD_RELOC_ALPHA_TPREL_LO16,
38329 + BFD_RELOC_ALPHA_TPREL16,
38330 +
38331 +/* Bits 27..2 of the relocation address shifted right 2 bits;
38332 +simple reloc otherwise. */
38333 + BFD_RELOC_MIPS_JMP,
38334 +
38335 +/* The MIPS16 jump instruction. */
38336 + BFD_RELOC_MIPS16_JMP,
38337 +
38338 +/* MIPS16 GP relative reloc. */
38339 + BFD_RELOC_MIPS16_GPREL,
38340 +
38341 +/* High 16 bits of 32-bit value; simple reloc. */
38342 + BFD_RELOC_HI16,
38343 +
38344 +/* High 16 bits of 32-bit value but the low 16 bits will be sign
38345 +extended and added to form the final result. If the low 16
38346 +bits form a negative number, we need to add one to the high value
38347 +to compensate for the borrow when the low bits are added. */
38348 + BFD_RELOC_HI16_S,
38349 +
38350 +/* Low 16 bits. */
38351 + BFD_RELOC_LO16,
38352 +
38353 +/* High 16 bits of 32-bit pc-relative value */
38354 + BFD_RELOC_HI16_PCREL,
38355 +
38356 +/* High 16 bits of 32-bit pc-relative value, adjusted */
38357 + BFD_RELOC_HI16_S_PCREL,
38358 +
38359 +/* Low 16 bits of pc-relative value */
38360 + BFD_RELOC_LO16_PCREL,
38361 +
38362 +/* MIPS16 high 16 bits of 32-bit value. */
38363 + BFD_RELOC_MIPS16_HI16,
38364 +
38365 +/* MIPS16 high 16 bits of 32-bit value but the low 16 bits will be sign
38366 +extended and added to form the final result. If the low 16
38367 +bits form a negative number, we need to add one to the high value
38368 +to compensate for the borrow when the low bits are added. */
38369 + BFD_RELOC_MIPS16_HI16_S,
38370 +
38371 +/* MIPS16 low 16 bits. */
38372 + BFD_RELOC_MIPS16_LO16,
38373 +
38374 +/* Relocation against a MIPS literal section. */
38375 + BFD_RELOC_MIPS_LITERAL,
38376 +
38377 +/* MIPS ELF relocations. */
38378 + BFD_RELOC_MIPS_GOT16,
38379 + BFD_RELOC_MIPS_CALL16,
38380 + BFD_RELOC_MIPS_GOT_HI16,
38381 + BFD_RELOC_MIPS_GOT_LO16,
38382 + BFD_RELOC_MIPS_CALL_HI16,
38383 + BFD_RELOC_MIPS_CALL_LO16,
38384 + BFD_RELOC_MIPS_SUB,
38385 + BFD_RELOC_MIPS_GOT_PAGE,
38386 + BFD_RELOC_MIPS_GOT_OFST,
38387 + BFD_RELOC_MIPS_GOT_DISP,
38388 + BFD_RELOC_MIPS_SHIFT5,
38389 + BFD_RELOC_MIPS_SHIFT6,
38390 + BFD_RELOC_MIPS_INSERT_A,
38391 + BFD_RELOC_MIPS_INSERT_B,
38392 + BFD_RELOC_MIPS_DELETE,
38393 + BFD_RELOC_MIPS_HIGHEST,
38394 + BFD_RELOC_MIPS_HIGHER,
38395 + BFD_RELOC_MIPS_SCN_DISP,
38396 + BFD_RELOC_MIPS_REL16,
38397 + BFD_RELOC_MIPS_RELGOT,
38398 + BFD_RELOC_MIPS_JALR,
38399 + BFD_RELOC_MIPS_TLS_DTPMOD32,
38400 + BFD_RELOC_MIPS_TLS_DTPREL32,
38401 + BFD_RELOC_MIPS_TLS_DTPMOD64,
38402 + BFD_RELOC_MIPS_TLS_DTPREL64,
38403 + BFD_RELOC_MIPS_TLS_GD,
38404 + BFD_RELOC_MIPS_TLS_LDM,
38405 + BFD_RELOC_MIPS_TLS_DTPREL_HI16,
38406 + BFD_RELOC_MIPS_TLS_DTPREL_LO16,
38407 + BFD_RELOC_MIPS_TLS_GOTTPREL,
38408 + BFD_RELOC_MIPS_TLS_TPREL32,
38409 + BFD_RELOC_MIPS_TLS_TPREL64,
38410 + BFD_RELOC_MIPS_TLS_TPREL_HI16,
38411 + BFD_RELOC_MIPS_TLS_TPREL_LO16,
38412 +
38413 +
38414 +/* MIPS ELF relocations (VxWorks extensions). */
38415 + BFD_RELOC_MIPS_COPY,
38416 + BFD_RELOC_MIPS_JUMP_SLOT,
38417 +
38418 +
38419 +/* Fujitsu Frv Relocations. */
38420 + BFD_RELOC_FRV_LABEL16,
38421 + BFD_RELOC_FRV_LABEL24,
38422 + BFD_RELOC_FRV_LO16,
38423 + BFD_RELOC_FRV_HI16,
38424 + BFD_RELOC_FRV_GPREL12,
38425 + BFD_RELOC_FRV_GPRELU12,
38426 + BFD_RELOC_FRV_GPREL32,
38427 + BFD_RELOC_FRV_GPRELHI,
38428 + BFD_RELOC_FRV_GPRELLO,
38429 + BFD_RELOC_FRV_GOT12,
38430 + BFD_RELOC_FRV_GOTHI,
38431 + BFD_RELOC_FRV_GOTLO,
38432 + BFD_RELOC_FRV_FUNCDESC,
38433 + BFD_RELOC_FRV_FUNCDESC_GOT12,
38434 + BFD_RELOC_FRV_FUNCDESC_GOTHI,
38435 + BFD_RELOC_FRV_FUNCDESC_GOTLO,
38436 + BFD_RELOC_FRV_FUNCDESC_VALUE,
38437 + BFD_RELOC_FRV_FUNCDESC_GOTOFF12,
38438 + BFD_RELOC_FRV_FUNCDESC_GOTOFFHI,
38439 + BFD_RELOC_FRV_FUNCDESC_GOTOFFLO,
38440 + BFD_RELOC_FRV_GOTOFF12,
38441 + BFD_RELOC_FRV_GOTOFFHI,
38442 + BFD_RELOC_FRV_GOTOFFLO,
38443 + BFD_RELOC_FRV_GETTLSOFF,
38444 + BFD_RELOC_FRV_TLSDESC_VALUE,
38445 + BFD_RELOC_FRV_GOTTLSDESC12,
38446 + BFD_RELOC_FRV_GOTTLSDESCHI,
38447 + BFD_RELOC_FRV_GOTTLSDESCLO,
38448 + BFD_RELOC_FRV_TLSMOFF12,
38449 + BFD_RELOC_FRV_TLSMOFFHI,
38450 + BFD_RELOC_FRV_TLSMOFFLO,
38451 + BFD_RELOC_FRV_GOTTLSOFF12,
38452 + BFD_RELOC_FRV_GOTTLSOFFHI,
38453 + BFD_RELOC_FRV_GOTTLSOFFLO,
38454 + BFD_RELOC_FRV_TLSOFF,
38455 + BFD_RELOC_FRV_TLSDESC_RELAX,
38456 + BFD_RELOC_FRV_GETTLSOFF_RELAX,
38457 + BFD_RELOC_FRV_TLSOFF_RELAX,
38458 + BFD_RELOC_FRV_TLSMOFF,
38459 +
38460 +
38461 +/* This is a 24bit GOT-relative reloc for the mn10300. */
38462 + BFD_RELOC_MN10300_GOTOFF24,
38463 +
38464 +/* This is a 32bit GOT-relative reloc for the mn10300, offset by two bytes
38465 +in the instruction. */
38466 + BFD_RELOC_MN10300_GOT32,
38467 +
38468 +/* This is a 24bit GOT-relative reloc for the mn10300, offset by two bytes
38469 +in the instruction. */
38470 + BFD_RELOC_MN10300_GOT24,
38471 +
38472 +/* This is a 16bit GOT-relative reloc for the mn10300, offset by two bytes
38473 +in the instruction. */
38474 + BFD_RELOC_MN10300_GOT16,
38475 +
38476 +/* Copy symbol at runtime. */
38477 + BFD_RELOC_MN10300_COPY,
38478 +
38479 +/* Create GOT entry. */
38480 + BFD_RELOC_MN10300_GLOB_DAT,
38481 +
38482 +/* Create PLT entry. */
38483 + BFD_RELOC_MN10300_JMP_SLOT,
38484 +
38485 +/* Adjust by program base. */
38486 + BFD_RELOC_MN10300_RELATIVE,
38487 +
38488 +
38489 +/* i386/elf relocations */
38490 + BFD_RELOC_386_GOT32,
38491 + BFD_RELOC_386_PLT32,
38492 + BFD_RELOC_386_COPY,
38493 + BFD_RELOC_386_GLOB_DAT,
38494 + BFD_RELOC_386_JUMP_SLOT,
38495 + BFD_RELOC_386_RELATIVE,
38496 + BFD_RELOC_386_GOTOFF,
38497 + BFD_RELOC_386_GOTPC,
38498 + BFD_RELOC_386_TLS_TPOFF,
38499 + BFD_RELOC_386_TLS_IE,
38500 + BFD_RELOC_386_TLS_GOTIE,
38501 + BFD_RELOC_386_TLS_LE,
38502 + BFD_RELOC_386_TLS_GD,
38503 + BFD_RELOC_386_TLS_LDM,
38504 + BFD_RELOC_386_TLS_LDO_32,
38505 + BFD_RELOC_386_TLS_IE_32,
38506 + BFD_RELOC_386_TLS_LE_32,
38507 + BFD_RELOC_386_TLS_DTPMOD32,
38508 + BFD_RELOC_386_TLS_DTPOFF32,
38509 + BFD_RELOC_386_TLS_TPOFF32,
38510 + BFD_RELOC_386_TLS_GOTDESC,
38511 + BFD_RELOC_386_TLS_DESC_CALL,
38512 + BFD_RELOC_386_TLS_DESC,
38513 +
38514 +/* x86-64/elf relocations */
38515 + BFD_RELOC_X86_64_GOT32,
38516 + BFD_RELOC_X86_64_PLT32,
38517 + BFD_RELOC_X86_64_COPY,
38518 + BFD_RELOC_X86_64_GLOB_DAT,
38519 + BFD_RELOC_X86_64_JUMP_SLOT,
38520 + BFD_RELOC_X86_64_RELATIVE,
38521 + BFD_RELOC_X86_64_GOTPCREL,
38522 + BFD_RELOC_X86_64_32S,
38523 + BFD_RELOC_X86_64_DTPMOD64,
38524 + BFD_RELOC_X86_64_DTPOFF64,
38525 + BFD_RELOC_X86_64_TPOFF64,
38526 + BFD_RELOC_X86_64_TLSGD,
38527 + BFD_RELOC_X86_64_TLSLD,
38528 + BFD_RELOC_X86_64_DTPOFF32,
38529 + BFD_RELOC_X86_64_GOTTPOFF,
38530 + BFD_RELOC_X86_64_TPOFF32,
38531 + BFD_RELOC_X86_64_GOTOFF64,
38532 + BFD_RELOC_X86_64_GOTPC32,
38533 + BFD_RELOC_X86_64_GOT64,
38534 + BFD_RELOC_X86_64_GOTPCREL64,
38535 + BFD_RELOC_X86_64_GOTPC64,
38536 + BFD_RELOC_X86_64_GOTPLT64,
38537 + BFD_RELOC_X86_64_PLTOFF64,
38538 + BFD_RELOC_X86_64_GOTPC32_TLSDESC,
38539 + BFD_RELOC_X86_64_TLSDESC_CALL,
38540 + BFD_RELOC_X86_64_TLSDESC,
38541 +
38542 +/* ns32k relocations */
38543 + BFD_RELOC_NS32K_IMM_8,
38544 + BFD_RELOC_NS32K_IMM_16,
38545 + BFD_RELOC_NS32K_IMM_32,
38546 + BFD_RELOC_NS32K_IMM_8_PCREL,
38547 + BFD_RELOC_NS32K_IMM_16_PCREL,
38548 + BFD_RELOC_NS32K_IMM_32_PCREL,
38549 + BFD_RELOC_NS32K_DISP_8,
38550 + BFD_RELOC_NS32K_DISP_16,
38551 + BFD_RELOC_NS32K_DISP_32,
38552 + BFD_RELOC_NS32K_DISP_8_PCREL,
38553 + BFD_RELOC_NS32K_DISP_16_PCREL,
38554 + BFD_RELOC_NS32K_DISP_32_PCREL,
38555 +
38556 +/* PDP11 relocations */
38557 + BFD_RELOC_PDP11_DISP_8_PCREL,
38558 + BFD_RELOC_PDP11_DISP_6_PCREL,
38559 +
38560 +/* Picojava relocs. Not all of these appear in object files. */
38561 + BFD_RELOC_PJ_CODE_HI16,
38562 + BFD_RELOC_PJ_CODE_LO16,
38563 + BFD_RELOC_PJ_CODE_DIR16,
38564 + BFD_RELOC_PJ_CODE_DIR32,
38565 + BFD_RELOC_PJ_CODE_REL16,
38566 + BFD_RELOC_PJ_CODE_REL32,
38567 +
38568 +/* Power(rs6000) and PowerPC relocations. */
38569 + BFD_RELOC_PPC_B26,
38570 + BFD_RELOC_PPC_BA26,
38571 + BFD_RELOC_PPC_TOC16,
38572 + BFD_RELOC_PPC_B16,
38573 + BFD_RELOC_PPC_B16_BRTAKEN,
38574 + BFD_RELOC_PPC_B16_BRNTAKEN,
38575 + BFD_RELOC_PPC_BA16,
38576 + BFD_RELOC_PPC_BA16_BRTAKEN,
38577 + BFD_RELOC_PPC_BA16_BRNTAKEN,
38578 + BFD_RELOC_PPC_COPY,
38579 + BFD_RELOC_PPC_GLOB_DAT,
38580 + BFD_RELOC_PPC_JMP_SLOT,
38581 + BFD_RELOC_PPC_RELATIVE,
38582 + BFD_RELOC_PPC_LOCAL24PC,
38583 + BFD_RELOC_PPC_EMB_NADDR32,
38584 + BFD_RELOC_PPC_EMB_NADDR16,
38585 + BFD_RELOC_PPC_EMB_NADDR16_LO,
38586 + BFD_RELOC_PPC_EMB_NADDR16_HI,
38587 + BFD_RELOC_PPC_EMB_NADDR16_HA,
38588 + BFD_RELOC_PPC_EMB_SDAI16,
38589 + BFD_RELOC_PPC_EMB_SDA2I16,
38590 + BFD_RELOC_PPC_EMB_SDA2REL,
38591 + BFD_RELOC_PPC_EMB_SDA21,
38592 + BFD_RELOC_PPC_EMB_MRKREF,
38593 + BFD_RELOC_PPC_EMB_RELSEC16,
38594 + BFD_RELOC_PPC_EMB_RELST_LO,
38595 + BFD_RELOC_PPC_EMB_RELST_HI,
38596 + BFD_RELOC_PPC_EMB_RELST_HA,
38597 + BFD_RELOC_PPC_EMB_BIT_FLD,
38598 + BFD_RELOC_PPC_EMB_RELSDA,
38599 + BFD_RELOC_PPC64_HIGHER,
38600 + BFD_RELOC_PPC64_HIGHER_S,
38601 + BFD_RELOC_PPC64_HIGHEST,
38602 + BFD_RELOC_PPC64_HIGHEST_S,
38603 + BFD_RELOC_PPC64_TOC16_LO,
38604 + BFD_RELOC_PPC64_TOC16_HI,
38605 + BFD_RELOC_PPC64_TOC16_HA,
38606 + BFD_RELOC_PPC64_TOC,
38607 + BFD_RELOC_PPC64_PLTGOT16,
38608 + BFD_RELOC_PPC64_PLTGOT16_LO,
38609 + BFD_RELOC_PPC64_PLTGOT16_HI,
38610 + BFD_RELOC_PPC64_PLTGOT16_HA,
38611 + BFD_RELOC_PPC64_ADDR16_DS,
38612 + BFD_RELOC_PPC64_ADDR16_LO_DS,
38613 + BFD_RELOC_PPC64_GOT16_DS,
38614 + BFD_RELOC_PPC64_GOT16_LO_DS,
38615 + BFD_RELOC_PPC64_PLT16_LO_DS,
38616 + BFD_RELOC_PPC64_SECTOFF_DS,
38617 + BFD_RELOC_PPC64_SECTOFF_LO_DS,
38618 + BFD_RELOC_PPC64_TOC16_DS,
38619 + BFD_RELOC_PPC64_TOC16_LO_DS,
38620 + BFD_RELOC_PPC64_PLTGOT16_DS,
38621 + BFD_RELOC_PPC64_PLTGOT16_LO_DS,
38622 +
38623 +/* PowerPC and PowerPC64 thread-local storage relocations. */
38624 + BFD_RELOC_PPC_TLS,
38625 + BFD_RELOC_PPC_DTPMOD,
38626 + BFD_RELOC_PPC_TPREL16,
38627 + BFD_RELOC_PPC_TPREL16_LO,
38628 + BFD_RELOC_PPC_TPREL16_HI,
38629 + BFD_RELOC_PPC_TPREL16_HA,
38630 + BFD_RELOC_PPC_TPREL,
38631 + BFD_RELOC_PPC_DTPREL16,
38632 + BFD_RELOC_PPC_DTPREL16_LO,
38633 + BFD_RELOC_PPC_DTPREL16_HI,
38634 + BFD_RELOC_PPC_DTPREL16_HA,
38635 + BFD_RELOC_PPC_DTPREL,
38636 + BFD_RELOC_PPC_GOT_TLSGD16,
38637 + BFD_RELOC_PPC_GOT_TLSGD16_LO,
38638 + BFD_RELOC_PPC_GOT_TLSGD16_HI,
38639 + BFD_RELOC_PPC_GOT_TLSGD16_HA,
38640 + BFD_RELOC_PPC_GOT_TLSLD16,
38641 + BFD_RELOC_PPC_GOT_TLSLD16_LO,
38642 + BFD_RELOC_PPC_GOT_TLSLD16_HI,
38643 + BFD_RELOC_PPC_GOT_TLSLD16_HA,
38644 + BFD_RELOC_PPC_GOT_TPREL16,
38645 + BFD_RELOC_PPC_GOT_TPREL16_LO,
38646 + BFD_RELOC_PPC_GOT_TPREL16_HI,
38647 + BFD_RELOC_PPC_GOT_TPREL16_HA,
38648 + BFD_RELOC_PPC_GOT_DTPREL16,
38649 + BFD_RELOC_PPC_GOT_DTPREL16_LO,
38650 + BFD_RELOC_PPC_GOT_DTPREL16_HI,
38651 + BFD_RELOC_PPC_GOT_DTPREL16_HA,
38652 + BFD_RELOC_PPC64_TPREL16_DS,
38653 + BFD_RELOC_PPC64_TPREL16_LO_DS,
38654 + BFD_RELOC_PPC64_TPREL16_HIGHER,
38655 + BFD_RELOC_PPC64_TPREL16_HIGHERA,
38656 + BFD_RELOC_PPC64_TPREL16_HIGHEST,
38657 + BFD_RELOC_PPC64_TPREL16_HIGHESTA,
38658 + BFD_RELOC_PPC64_DTPREL16_DS,
38659 + BFD_RELOC_PPC64_DTPREL16_LO_DS,
38660 + BFD_RELOC_PPC64_DTPREL16_HIGHER,
38661 + BFD_RELOC_PPC64_DTPREL16_HIGHERA,
38662 + BFD_RELOC_PPC64_DTPREL16_HIGHEST,
38663 + BFD_RELOC_PPC64_DTPREL16_HIGHESTA,
38664 +
38665 +/* IBM 370/390 relocations */
38666 + BFD_RELOC_I370_D12,
38667 +
38668 +/* The type of reloc used to build a constructor table - at the moment
38669 +probably a 32 bit wide absolute relocation, but the target can choose.
38670 +It generally does map to one of the other relocation types. */
38671 + BFD_RELOC_CTOR,
38672 +
38673 +/* ARM 26 bit pc-relative branch. The lowest two bits must be zero and are
38674 +not stored in the instruction. */
38675 + BFD_RELOC_ARM_PCREL_BRANCH,
38676 +
38677 +/* ARM 26 bit pc-relative branch. The lowest bit must be zero and is
38678 +not stored in the instruction. The 2nd lowest bit comes from a 1 bit
38679 +field in the instruction. */
38680 + BFD_RELOC_ARM_PCREL_BLX,
38681 +
38682 +/* Thumb 22 bit pc-relative branch. The lowest bit must be zero and is
38683 +not stored in the instruction. The 2nd lowest bit comes from a 1 bit
38684 +field in the instruction. */
38685 + BFD_RELOC_THUMB_PCREL_BLX,
38686 +
38687 +/* ARM 26-bit pc-relative branch for an unconditional BL or BLX instruction. */
38688 + BFD_RELOC_ARM_PCREL_CALL,
38689 +
38690 +/* ARM 26-bit pc-relative branch for B or conditional BL instruction. */
38691 + BFD_RELOC_ARM_PCREL_JUMP,
38692 +
38693 +/* Thumb 7-, 9-, 12-, 20-, 23-, and 25-bit pc-relative branches.
38694 +The lowest bit must be zero and is not stored in the instruction.
38695 +Note that the corresponding ELF R_ARM_THM_JUMPnn constant has an
38696 +"nn" one smaller in all cases. Note further that BRANCH23
38697 +corresponds to R_ARM_THM_CALL. */
38698 + BFD_RELOC_THUMB_PCREL_BRANCH7,
38699 + BFD_RELOC_THUMB_PCREL_BRANCH9,
38700 + BFD_RELOC_THUMB_PCREL_BRANCH12,
38701 + BFD_RELOC_THUMB_PCREL_BRANCH20,
38702 + BFD_RELOC_THUMB_PCREL_BRANCH23,
38703 + BFD_RELOC_THUMB_PCREL_BRANCH25,
38704 +
38705 +/* 12-bit immediate offset, used in ARM-format ldr and str instructions. */
38706 + BFD_RELOC_ARM_OFFSET_IMM,
38707 +
38708 +/* 5-bit immediate offset, used in Thumb-format ldr and str instructions. */
38709 + BFD_RELOC_ARM_THUMB_OFFSET,
38710 +
38711 +/* Pc-relative or absolute relocation depending on target. Used for
38712 +entries in .init_array sections. */
38713 + BFD_RELOC_ARM_TARGET1,
38714 +
38715 +/* Read-only segment base relative address. */
38716 + BFD_RELOC_ARM_ROSEGREL32,
38717 +
38718 +/* Data segment base relative address. */
38719 + BFD_RELOC_ARM_SBREL32,
38720 +
38721 +/* This reloc is used for references to RTTI data from exception handling
38722 +tables. The actual definition depends on the target. It may be a
38723 +pc-relative or some form of GOT-indirect relocation. */
38724 + BFD_RELOC_ARM_TARGET2,
38725 +
38726 +/* 31-bit PC relative address. */
38727 + BFD_RELOC_ARM_PREL31,
38728 +
38729 +/* Low and High halfword relocations for MOVW and MOVT instructions. */
38730 + BFD_RELOC_ARM_MOVW,
38731 + BFD_RELOC_ARM_MOVT,
38732 + BFD_RELOC_ARM_MOVW_PCREL,
38733 + BFD_RELOC_ARM_MOVT_PCREL,
38734 + BFD_RELOC_ARM_THUMB_MOVW,
38735 + BFD_RELOC_ARM_THUMB_MOVT,
38736 + BFD_RELOC_ARM_THUMB_MOVW_PCREL,
38737 + BFD_RELOC_ARM_THUMB_MOVT_PCREL,
38738 +
38739 +/* Relocations for setting up GOTs and PLTs for shared libraries. */
38740 + BFD_RELOC_ARM_JUMP_SLOT,
38741 + BFD_RELOC_ARM_GLOB_DAT,
38742 + BFD_RELOC_ARM_GOT32,
38743 + BFD_RELOC_ARM_PLT32,
38744 + BFD_RELOC_ARM_RELATIVE,
38745 + BFD_RELOC_ARM_GOTOFF,
38746 + BFD_RELOC_ARM_GOTPC,
38747 +
38748 +/* ARM thread-local storage relocations. */
38749 + BFD_RELOC_ARM_TLS_GD32,
38750 + BFD_RELOC_ARM_TLS_LDO32,
38751 + BFD_RELOC_ARM_TLS_LDM32,
38752 + BFD_RELOC_ARM_TLS_DTPOFF32,
38753 + BFD_RELOC_ARM_TLS_DTPMOD32,
38754 + BFD_RELOC_ARM_TLS_TPOFF32,
38755 + BFD_RELOC_ARM_TLS_IE32,
38756 + BFD_RELOC_ARM_TLS_LE32,
38757 +
38758 +/* ARM group relocations. */
38759 + BFD_RELOC_ARM_ALU_PC_G0_NC,
38760 + BFD_RELOC_ARM_ALU_PC_G0,
38761 + BFD_RELOC_ARM_ALU_PC_G1_NC,
38762 + BFD_RELOC_ARM_ALU_PC_G1,
38763 + BFD_RELOC_ARM_ALU_PC_G2,
38764 + BFD_RELOC_ARM_LDR_PC_G0,
38765 + BFD_RELOC_ARM_LDR_PC_G1,
38766 + BFD_RELOC_ARM_LDR_PC_G2,
38767 + BFD_RELOC_ARM_LDRS_PC_G0,
38768 + BFD_RELOC_ARM_LDRS_PC_G1,
38769 + BFD_RELOC_ARM_LDRS_PC_G2,
38770 + BFD_RELOC_ARM_LDC_PC_G0,
38771 + BFD_RELOC_ARM_LDC_PC_G1,
38772 + BFD_RELOC_ARM_LDC_PC_G2,
38773 + BFD_RELOC_ARM_ALU_SB_G0_NC,
38774 + BFD_RELOC_ARM_ALU_SB_G0,
38775 + BFD_RELOC_ARM_ALU_SB_G1_NC,
38776 + BFD_RELOC_ARM_ALU_SB_G1,
38777 + BFD_RELOC_ARM_ALU_SB_G2,
38778 + BFD_RELOC_ARM_LDR_SB_G0,
38779 + BFD_RELOC_ARM_LDR_SB_G1,
38780 + BFD_RELOC_ARM_LDR_SB_G2,
38781 + BFD_RELOC_ARM_LDRS_SB_G0,
38782 + BFD_RELOC_ARM_LDRS_SB_G1,
38783 + BFD_RELOC_ARM_LDRS_SB_G2,
38784 + BFD_RELOC_ARM_LDC_SB_G0,
38785 + BFD_RELOC_ARM_LDC_SB_G1,
38786 + BFD_RELOC_ARM_LDC_SB_G2,
38787 +
38788 +/* These relocs are only used within the ARM assembler. They are not
38789 +(at present) written to any object files. */
38790 + BFD_RELOC_ARM_IMMEDIATE,
38791 + BFD_RELOC_ARM_ADRL_IMMEDIATE,
38792 + BFD_RELOC_ARM_T32_IMMEDIATE,
38793 + BFD_RELOC_ARM_T32_ADD_IMM,
38794 + BFD_RELOC_ARM_T32_IMM12,
38795 + BFD_RELOC_ARM_T32_ADD_PC12,
38796 + BFD_RELOC_ARM_SHIFT_IMM,
38797 + BFD_RELOC_ARM_SMC,
38798 + BFD_RELOC_ARM_SWI,
38799 + BFD_RELOC_ARM_MULTI,
38800 + BFD_RELOC_ARM_CP_OFF_IMM,
38801 + BFD_RELOC_ARM_CP_OFF_IMM_S2,
38802 + BFD_RELOC_ARM_T32_CP_OFF_IMM,
38803 + BFD_RELOC_ARM_T32_CP_OFF_IMM_S2,
38804 + BFD_RELOC_ARM_ADR_IMM,
38805 + BFD_RELOC_ARM_LDR_IMM,
38806 + BFD_RELOC_ARM_LITERAL,
38807 + BFD_RELOC_ARM_IN_POOL,
38808 + BFD_RELOC_ARM_OFFSET_IMM8,
38809 + BFD_RELOC_ARM_T32_OFFSET_U8,
38810 + BFD_RELOC_ARM_T32_OFFSET_IMM,
38811 + BFD_RELOC_ARM_HWLITERAL,
38812 + BFD_RELOC_ARM_THUMB_ADD,
38813 + BFD_RELOC_ARM_THUMB_IMM,
38814 + BFD_RELOC_ARM_THUMB_SHIFT,
38815 +
38816 +/* Renesas / SuperH SH relocs. Not all of these appear in object files. */
38817 + BFD_RELOC_SH_PCDISP8BY2,
38818 + BFD_RELOC_SH_PCDISP12BY2,
38819 + BFD_RELOC_SH_IMM3,
38820 + BFD_RELOC_SH_IMM3U,
38821 + BFD_RELOC_SH_DISP12,
38822 + BFD_RELOC_SH_DISP12BY2,
38823 + BFD_RELOC_SH_DISP12BY4,
38824 + BFD_RELOC_SH_DISP12BY8,
38825 + BFD_RELOC_SH_DISP20,
38826 + BFD_RELOC_SH_DISP20BY8,
38827 + BFD_RELOC_SH_IMM4,
38828 + BFD_RELOC_SH_IMM4BY2,
38829 + BFD_RELOC_SH_IMM4BY4,
38830 + BFD_RELOC_SH_IMM8,
38831 + BFD_RELOC_SH_IMM8BY2,
38832 + BFD_RELOC_SH_IMM8BY4,
38833 + BFD_RELOC_SH_PCRELIMM8BY2,
38834 + BFD_RELOC_SH_PCRELIMM8BY4,
38835 + BFD_RELOC_SH_SWITCH16,
38836 + BFD_RELOC_SH_SWITCH32,
38837 + BFD_RELOC_SH_USES,
38838 + BFD_RELOC_SH_COUNT,
38839 + BFD_RELOC_SH_ALIGN,
38840 + BFD_RELOC_SH_CODE,
38841 + BFD_RELOC_SH_DATA,
38842 + BFD_RELOC_SH_LABEL,
38843 + BFD_RELOC_SH_LOOP_START,
38844 + BFD_RELOC_SH_LOOP_END,
38845 + BFD_RELOC_SH_COPY,
38846 + BFD_RELOC_SH_GLOB_DAT,
38847 + BFD_RELOC_SH_JMP_SLOT,
38848 + BFD_RELOC_SH_RELATIVE,
38849 + BFD_RELOC_SH_GOTPC,
38850 + BFD_RELOC_SH_GOT_LOW16,
38851 + BFD_RELOC_SH_GOT_MEDLOW16,
38852 + BFD_RELOC_SH_GOT_MEDHI16,
38853 + BFD_RELOC_SH_GOT_HI16,
38854 + BFD_RELOC_SH_GOTPLT_LOW16,
38855 + BFD_RELOC_SH_GOTPLT_MEDLOW16,
38856 + BFD_RELOC_SH_GOTPLT_MEDHI16,
38857 + BFD_RELOC_SH_GOTPLT_HI16,
38858 + BFD_RELOC_SH_PLT_LOW16,
38859 + BFD_RELOC_SH_PLT_MEDLOW16,
38860 + BFD_RELOC_SH_PLT_MEDHI16,
38861 + BFD_RELOC_SH_PLT_HI16,
38862 + BFD_RELOC_SH_GOTOFF_LOW16,
38863 + BFD_RELOC_SH_GOTOFF_MEDLOW16,
38864 + BFD_RELOC_SH_GOTOFF_MEDHI16,
38865 + BFD_RELOC_SH_GOTOFF_HI16,
38866 + BFD_RELOC_SH_GOTPC_LOW16,
38867 + BFD_RELOC_SH_GOTPC_MEDLOW16,
38868 + BFD_RELOC_SH_GOTPC_MEDHI16,
38869 + BFD_RELOC_SH_GOTPC_HI16,
38870 + BFD_RELOC_SH_COPY64,
38871 + BFD_RELOC_SH_GLOB_DAT64,
38872 + BFD_RELOC_SH_JMP_SLOT64,
38873 + BFD_RELOC_SH_RELATIVE64,
38874 + BFD_RELOC_SH_GOT10BY4,
38875 + BFD_RELOC_SH_GOT10BY8,
38876 + BFD_RELOC_SH_GOTPLT10BY4,
38877 + BFD_RELOC_SH_GOTPLT10BY8,
38878 + BFD_RELOC_SH_GOTPLT32,
38879 + BFD_RELOC_SH_SHMEDIA_CODE,
38880 + BFD_RELOC_SH_IMMU5,
38881 + BFD_RELOC_SH_IMMS6,
38882 + BFD_RELOC_SH_IMMS6BY32,
38883 + BFD_RELOC_SH_IMMU6,
38884 + BFD_RELOC_SH_IMMS10,
38885 + BFD_RELOC_SH_IMMS10BY2,
38886 + BFD_RELOC_SH_IMMS10BY4,
38887 + BFD_RELOC_SH_IMMS10BY8,
38888 + BFD_RELOC_SH_IMMS16,
38889 + BFD_RELOC_SH_IMMU16,
38890 + BFD_RELOC_SH_IMM_LOW16,
38891 + BFD_RELOC_SH_IMM_LOW16_PCREL,
38892 + BFD_RELOC_SH_IMM_MEDLOW16,
38893 + BFD_RELOC_SH_IMM_MEDLOW16_PCREL,
38894 + BFD_RELOC_SH_IMM_MEDHI16,
38895 + BFD_RELOC_SH_IMM_MEDHI16_PCREL,
38896 + BFD_RELOC_SH_IMM_HI16,
38897 + BFD_RELOC_SH_IMM_HI16_PCREL,
38898 + BFD_RELOC_SH_PT_16,
38899 + BFD_RELOC_SH_TLS_GD_32,
38900 + BFD_RELOC_SH_TLS_LD_32,
38901 + BFD_RELOC_SH_TLS_LDO_32,
38902 + BFD_RELOC_SH_TLS_IE_32,
38903 + BFD_RELOC_SH_TLS_LE_32,
38904 + BFD_RELOC_SH_TLS_DTPMOD32,
38905 + BFD_RELOC_SH_TLS_DTPOFF32,
38906 + BFD_RELOC_SH_TLS_TPOFF32,
38907 +
38908 +/* ARC Cores relocs.
38909 +ARC 22 bit pc-relative branch. The lowest two bits must be zero and are
38910 +not stored in the instruction. The high 20 bits are installed in bits 26
38911 +through 7 of the instruction. */
38912 + BFD_RELOC_ARC_B22_PCREL,
38913 +
38914 +/* ARC 26 bit absolute branch. The lowest two bits must be zero and are not
38915 +stored in the instruction. The high 24 bits are installed in bits 23
38916 +through 0. */
38917 + BFD_RELOC_ARC_B26,
38918 +
38919 +/* ADI Blackfin 16 bit immediate absolute reloc. */
38920 + BFD_RELOC_BFIN_16_IMM,
38921 +
38922 +/* ADI Blackfin 16 bit immediate absolute reloc higher 16 bits. */
38923 + BFD_RELOC_BFIN_16_HIGH,
38924 +
38925 +/* ADI Blackfin 'a' part of LSETUP. */
38926 + BFD_RELOC_BFIN_4_PCREL,
38927 +
38928 +/* ADI Blackfin. */
38929 + BFD_RELOC_BFIN_5_PCREL,
38930 +
38931 +/* ADI Blackfin 16 bit immediate absolute reloc lower 16 bits. */
38932 + BFD_RELOC_BFIN_16_LOW,
38933 +
38934 +/* ADI Blackfin. */
38935 + BFD_RELOC_BFIN_10_PCREL,
38936 +
38937 +/* ADI Blackfin 'b' part of LSETUP. */
38938 + BFD_RELOC_BFIN_11_PCREL,
38939 +
38940 +/* ADI Blackfin. */
38941 + BFD_RELOC_BFIN_12_PCREL_JUMP,
38942 +
38943 +/* ADI Blackfin Short jump, pcrel. */
38944 + BFD_RELOC_BFIN_12_PCREL_JUMP_S,
38945 +
38946 +/* ADI Blackfin Call.x not implemented. */
38947 + BFD_RELOC_BFIN_24_PCREL_CALL_X,
38948 +
38949 +/* ADI Blackfin Long Jump pcrel. */
38950 + BFD_RELOC_BFIN_24_PCREL_JUMP_L,
38951 +
38952 +/* ADI Blackfin FD-PIC relocations. */
38953 + BFD_RELOC_BFIN_GOT17M4,
38954 + BFD_RELOC_BFIN_GOTHI,
38955 + BFD_RELOC_BFIN_GOTLO,
38956 + BFD_RELOC_BFIN_FUNCDESC,
38957 + BFD_RELOC_BFIN_FUNCDESC_GOT17M4,
38958 + BFD_RELOC_BFIN_FUNCDESC_GOTHI,
38959 + BFD_RELOC_BFIN_FUNCDESC_GOTLO,
38960 + BFD_RELOC_BFIN_FUNCDESC_VALUE,
38961 + BFD_RELOC_BFIN_FUNCDESC_GOTOFF17M4,
38962 + BFD_RELOC_BFIN_FUNCDESC_GOTOFFHI,
38963 + BFD_RELOC_BFIN_FUNCDESC_GOTOFFLO,
38964 + BFD_RELOC_BFIN_GOTOFF17M4,
38965 + BFD_RELOC_BFIN_GOTOFFHI,
38966 + BFD_RELOC_BFIN_GOTOFFLO,
38967 +
38968 +/* ADI Blackfin GOT relocation. */
38969 + BFD_RELOC_BFIN_GOT,
38970 +
38971 +/* ADI Blackfin PLTPC relocation. */
38972 + BFD_RELOC_BFIN_PLTPC,
38973 +
38974 +/* ADI Blackfin arithmetic relocation. */
38975 + BFD_ARELOC_BFIN_PUSH,
38976 +
38977 +/* ADI Blackfin arithmetic relocation. */
38978 + BFD_ARELOC_BFIN_CONST,
38979 +
38980 +/* ADI Blackfin arithmetic relocation. */
38981 + BFD_ARELOC_BFIN_ADD,
38982 +
38983 +/* ADI Blackfin arithmetic relocation. */
38984 + BFD_ARELOC_BFIN_SUB,
38985 +
38986 +/* ADI Blackfin arithmetic relocation. */
38987 + BFD_ARELOC_BFIN_MULT,
38988 +
38989 +/* ADI Blackfin arithmetic relocation. */
38990 + BFD_ARELOC_BFIN_DIV,
38991 +
38992 +/* ADI Blackfin arithmetic relocation. */
38993 + BFD_ARELOC_BFIN_MOD,
38994 +
38995 +/* ADI Blackfin arithmetic relocation. */
38996 + BFD_ARELOC_BFIN_LSHIFT,
38997 +
38998 +/* ADI Blackfin arithmetic relocation. */
38999 + BFD_ARELOC_BFIN_RSHIFT,
39000 +
39001 +/* ADI Blackfin arithmetic relocation. */
39002 + BFD_ARELOC_BFIN_AND,
39003 +
39004 +/* ADI Blackfin arithmetic relocation. */
39005 + BFD_ARELOC_BFIN_OR,
39006 +
39007 +/* ADI Blackfin arithmetic relocation. */
39008 + BFD_ARELOC_BFIN_XOR,
39009 +
39010 +/* ADI Blackfin arithmetic relocation. */
39011 + BFD_ARELOC_BFIN_LAND,
39012 +
39013 +/* ADI Blackfin arithmetic relocation. */
39014 + BFD_ARELOC_BFIN_LOR,
39015 +
39016 +/* ADI Blackfin arithmetic relocation. */
39017 + BFD_ARELOC_BFIN_LEN,
39018 +
39019 +/* ADI Blackfin arithmetic relocation. */
39020 + BFD_ARELOC_BFIN_NEG,
39021 +
39022 +/* ADI Blackfin arithmetic relocation. */
39023 + BFD_ARELOC_BFIN_COMP,
39024 +
39025 +/* ADI Blackfin arithmetic relocation. */
39026 + BFD_ARELOC_BFIN_PAGE,
39027 +
39028 +/* ADI Blackfin arithmetic relocation. */
39029 + BFD_ARELOC_BFIN_HWPAGE,
39030 +
39031 +/* ADI Blackfin arithmetic relocation. */
39032 + BFD_ARELOC_BFIN_ADDR,
39033 +
39034 +/* Mitsubishi D10V relocs.
39035 +This is a 10-bit reloc with the right 2 bits
39036 +assumed to be 0. */
39037 + BFD_RELOC_D10V_10_PCREL_R,
39038 +
39039 +/* Mitsubishi D10V relocs.
39040 +This is a 10-bit reloc with the right 2 bits
39041 +assumed to be 0. This is the same as the previous reloc
39042 +except it is in the left container, i.e.,
39043 +shifted left 15 bits. */
39044 + BFD_RELOC_D10V_10_PCREL_L,
39045 +
39046 +/* This is an 18-bit reloc with the right 2 bits
39047 +assumed to be 0. */
39048 + BFD_RELOC_D10V_18,
39049 +
39050 +/* This is an 18-bit reloc with the right 2 bits
39051 +assumed to be 0. */
39052 + BFD_RELOC_D10V_18_PCREL,
39053 +
39054 +/* Mitsubishi D30V relocs.
39055 +This is a 6-bit absolute reloc. */
39056 + BFD_RELOC_D30V_6,
39057 +
39058 +/* This is a 6-bit pc-relative reloc with
39059 +the right 3 bits assumed to be 0. */
39060 + BFD_RELOC_D30V_9_PCREL,
39061 +
39062 +/* This is a 6-bit pc-relative reloc with
39063 +the right 3 bits assumed to be 0. Same
39064 +as the previous reloc but on the right side
39065 +of the container. */
39066 + BFD_RELOC_D30V_9_PCREL_R,
39067 +
39068 +/* This is a 12-bit absolute reloc with the
39069 +right 3 bitsassumed to be 0. */
39070 + BFD_RELOC_D30V_15,
39071 +
39072 +/* This is a 12-bit pc-relative reloc with
39073 +the right 3 bits assumed to be 0. */
39074 + BFD_RELOC_D30V_15_PCREL,
39075 +
39076 +/* This is a 12-bit pc-relative reloc with
39077 +the right 3 bits assumed to be 0. Same
39078 +as the previous reloc but on the right side
39079 +of the container. */
39080 + BFD_RELOC_D30V_15_PCREL_R,
39081 +
39082 +/* This is an 18-bit absolute reloc with
39083 +the right 3 bits assumed to be 0. */
39084 + BFD_RELOC_D30V_21,
39085 +
39086 +/* This is an 18-bit pc-relative reloc with
39087 +the right 3 bits assumed to be 0. */
39088 + BFD_RELOC_D30V_21_PCREL,
39089 +
39090 +/* This is an 18-bit pc-relative reloc with
39091 +the right 3 bits assumed to be 0. Same
39092 +as the previous reloc but on the right side
39093 +of the container. */
39094 + BFD_RELOC_D30V_21_PCREL_R,
39095 +
39096 +/* This is a 32-bit absolute reloc. */
39097 + BFD_RELOC_D30V_32,
39098 +
39099 +/* This is a 32-bit pc-relative reloc. */
39100 + BFD_RELOC_D30V_32_PCREL,
39101 +
39102 +/* DLX relocs */
39103 + BFD_RELOC_DLX_HI16_S,
39104 +
39105 +/* DLX relocs */
39106 + BFD_RELOC_DLX_LO16,
39107 +
39108 +/* DLX relocs */
39109 + BFD_RELOC_DLX_JMP26,
39110 +
39111 +/* Renesas M16C/M32C Relocations. */
39112 + BFD_RELOC_M32C_HI8,
39113 + BFD_RELOC_M32C_RL_JUMP,
39114 + BFD_RELOC_M32C_RL_1ADDR,
39115 + BFD_RELOC_M32C_RL_2ADDR,
39116 +
39117 +/* Renesas M32R (formerly Mitsubishi M32R) relocs.
39118 +This is a 24 bit absolute address. */
39119 + BFD_RELOC_M32R_24,
39120 +
39121 +/* This is a 10-bit pc-relative reloc with the right 2 bits assumed to be 0. */
39122 + BFD_RELOC_M32R_10_PCREL,
39123 +
39124 +/* This is an 18-bit reloc with the right 2 bits assumed to be 0. */
39125 + BFD_RELOC_M32R_18_PCREL,
39126 +
39127 +/* This is a 26-bit reloc with the right 2 bits assumed to be 0. */
39128 + BFD_RELOC_M32R_26_PCREL,
39129 +
39130 +/* This is a 16-bit reloc containing the high 16 bits of an address
39131 +used when the lower 16 bits are treated as unsigned. */
39132 + BFD_RELOC_M32R_HI16_ULO,
39133 +
39134 +/* This is a 16-bit reloc containing the high 16 bits of an address
39135 +used when the lower 16 bits are treated as signed. */
39136 + BFD_RELOC_M32R_HI16_SLO,
39137 +
39138 +/* This is a 16-bit reloc containing the lower 16 bits of an address. */
39139 + BFD_RELOC_M32R_LO16,
39140 +
39141 +/* This is a 16-bit reloc containing the small data area offset for use in
39142 +add3, load, and store instructions. */
39143 + BFD_RELOC_M32R_SDA16,
39144 +
39145 +/* For PIC. */
39146 + BFD_RELOC_M32R_GOT24,
39147 + BFD_RELOC_M32R_26_PLTREL,
39148 + BFD_RELOC_M32R_COPY,
39149 + BFD_RELOC_M32R_GLOB_DAT,
39150 + BFD_RELOC_M32R_JMP_SLOT,
39151 + BFD_RELOC_M32R_RELATIVE,
39152 + BFD_RELOC_M32R_GOTOFF,
39153 + BFD_RELOC_M32R_GOTOFF_HI_ULO,
39154 + BFD_RELOC_M32R_GOTOFF_HI_SLO,
39155 + BFD_RELOC_M32R_GOTOFF_LO,
39156 + BFD_RELOC_M32R_GOTPC24,
39157 + BFD_RELOC_M32R_GOT16_HI_ULO,
39158 + BFD_RELOC_M32R_GOT16_HI_SLO,
39159 + BFD_RELOC_M32R_GOT16_LO,
39160 + BFD_RELOC_M32R_GOTPC_HI_ULO,
39161 + BFD_RELOC_M32R_GOTPC_HI_SLO,
39162 + BFD_RELOC_M32R_GOTPC_LO,
39163 +
39164 +/* This is a 9-bit reloc */
39165 + BFD_RELOC_V850_9_PCREL,
39166 +
39167 +/* This is a 22-bit reloc */
39168 + BFD_RELOC_V850_22_PCREL,
39169 +
39170 +/* This is a 16 bit offset from the short data area pointer. */
39171 + BFD_RELOC_V850_SDA_16_16_OFFSET,
39172 +
39173 +/* This is a 16 bit offset (of which only 15 bits are used) from the
39174 +short data area pointer. */
39175 + BFD_RELOC_V850_SDA_15_16_OFFSET,
39176 +
39177 +/* This is a 16 bit offset from the zero data area pointer. */
39178 + BFD_RELOC_V850_ZDA_16_16_OFFSET,
39179 +
39180 +/* This is a 16 bit offset (of which only 15 bits are used) from the
39181 +zero data area pointer. */
39182 + BFD_RELOC_V850_ZDA_15_16_OFFSET,
39183 +
39184 +/* This is an 8 bit offset (of which only 6 bits are used) from the
39185 +tiny data area pointer. */
39186 + BFD_RELOC_V850_TDA_6_8_OFFSET,
39187 +
39188 +/* This is an 8bit offset (of which only 7 bits are used) from the tiny
39189 +data area pointer. */
39190 + BFD_RELOC_V850_TDA_7_8_OFFSET,
39191 +
39192 +/* This is a 7 bit offset from the tiny data area pointer. */
39193 + BFD_RELOC_V850_TDA_7_7_OFFSET,
39194 +
39195 +/* This is a 16 bit offset from the tiny data area pointer. */
39196 + BFD_RELOC_V850_TDA_16_16_OFFSET,
39197 +
39198 +/* This is a 5 bit offset (of which only 4 bits are used) from the tiny
39199 +data area pointer. */
39200 + BFD_RELOC_V850_TDA_4_5_OFFSET,
39201 +
39202 +/* This is a 4 bit offset from the tiny data area pointer. */
39203 + BFD_RELOC_V850_TDA_4_4_OFFSET,
39204 +
39205 +/* This is a 16 bit offset from the short data area pointer, with the
39206 +bits placed non-contiguously in the instruction. */
39207 + BFD_RELOC_V850_SDA_16_16_SPLIT_OFFSET,
39208 +
39209 +/* This is a 16 bit offset from the zero data area pointer, with the
39210 +bits placed non-contiguously in the instruction. */
39211 + BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET,
39212 +
39213 +/* This is a 6 bit offset from the call table base pointer. */
39214 + BFD_RELOC_V850_CALLT_6_7_OFFSET,
39215 +
39216 +/* This is a 16 bit offset from the call table base pointer. */
39217 + BFD_RELOC_V850_CALLT_16_16_OFFSET,
39218 +
39219 +/* Used for relaxing indirect function calls. */
39220 + BFD_RELOC_V850_LONGCALL,
39221 +
39222 +/* Used for relaxing indirect jumps. */
39223 + BFD_RELOC_V850_LONGJUMP,
39224 +
39225 +/* Used to maintain alignment whilst relaxing. */
39226 + BFD_RELOC_V850_ALIGN,
39227 +
39228 +/* This is a variation of BFD_RELOC_LO16 that can be used in v850e ld.bu
39229 +instructions. */
39230 + BFD_RELOC_V850_LO16_SPLIT_OFFSET,
39231 +
39232 +/* This is a 32bit pcrel reloc for the mn10300, offset by two bytes in the
39233 +instruction. */
39234 + BFD_RELOC_MN10300_32_PCREL,
39235 +
39236 +/* This is a 16bit pcrel reloc for the mn10300, offset by two bytes in the
39237 +instruction. */
39238 + BFD_RELOC_MN10300_16_PCREL,
39239 +
39240 +/* This is a 8bit DP reloc for the tms320c30, where the most
39241 +significant 8 bits of a 24 bit word are placed into the least
39242 +significant 8 bits of the opcode. */
39243 + BFD_RELOC_TIC30_LDP,
39244 +
39245 +/* This is a 7bit reloc for the tms320c54x, where the least
39246 +significant 7 bits of a 16 bit word are placed into the least
39247 +significant 7 bits of the opcode. */
39248 + BFD_RELOC_TIC54X_PARTLS7,
39249 +
39250 +/* This is a 9bit DP reloc for the tms320c54x, where the most
39251 +significant 9 bits of a 16 bit word are placed into the least
39252 +significant 9 bits of the opcode. */
39253 + BFD_RELOC_TIC54X_PARTMS9,
39254 +
39255 +/* This is an extended address 23-bit reloc for the tms320c54x. */
39256 + BFD_RELOC_TIC54X_23,
39257 +
39258 +/* This is a 16-bit reloc for the tms320c54x, where the least
39259 +significant 16 bits of a 23-bit extended address are placed into
39260 +the opcode. */
39261 + BFD_RELOC_TIC54X_16_OF_23,
39262 +
39263 +/* This is a reloc for the tms320c54x, where the most
39264 +significant 7 bits of a 23-bit extended address are placed into
39265 +the opcode. */
39266 + BFD_RELOC_TIC54X_MS7_OF_23,
39267 +
39268 +/* This is a 48 bit reloc for the FR30 that stores 32 bits. */
39269 + BFD_RELOC_FR30_48,
39270 +
39271 +/* This is a 32 bit reloc for the FR30 that stores 20 bits split up into
39272 +two sections. */
39273 + BFD_RELOC_FR30_20,
39274 +
39275 +/* This is a 16 bit reloc for the FR30 that stores a 6 bit word offset in
39276 +4 bits. */
39277 + BFD_RELOC_FR30_6_IN_4,
39278 +
39279 +/* This is a 16 bit reloc for the FR30 that stores an 8 bit byte offset
39280 +into 8 bits. */
39281 + BFD_RELOC_FR30_8_IN_8,
39282 +
39283 +/* This is a 16 bit reloc for the FR30 that stores a 9 bit short offset
39284 +into 8 bits. */
39285 + BFD_RELOC_FR30_9_IN_8,
39286 +
39287 +/* This is a 16 bit reloc for the FR30 that stores a 10 bit word offset
39288 +into 8 bits. */
39289 + BFD_RELOC_FR30_10_IN_8,
39290 +
39291 +/* This is a 16 bit reloc for the FR30 that stores a 9 bit pc relative
39292 +short offset into 8 bits. */
39293 + BFD_RELOC_FR30_9_PCREL,
39294 +
39295 +/* This is a 16 bit reloc for the FR30 that stores a 12 bit pc relative
39296 +short offset into 11 bits. */
39297 + BFD_RELOC_FR30_12_PCREL,
39298 +
39299 +/* Motorola Mcore relocations. */
39300 + BFD_RELOC_MCORE_PCREL_IMM8BY4,
39301 + BFD_RELOC_MCORE_PCREL_IMM11BY2,
39302 + BFD_RELOC_MCORE_PCREL_IMM4BY2,
39303 + BFD_RELOC_MCORE_PCREL_32,
39304 + BFD_RELOC_MCORE_PCREL_JSR_IMM11BY2,
39305 + BFD_RELOC_MCORE_RVA,
39306 +
39307 +/* Toshiba Media Processor Relocations. */
39308 + BFD_RELOC_MEP_8,
39309 + BFD_RELOC_MEP_16,
39310 + BFD_RELOC_MEP_32,
39311 + BFD_RELOC_MEP_PCREL8A2,
39312 + BFD_RELOC_MEP_PCREL12A2,
39313 + BFD_RELOC_MEP_PCREL17A2,
39314 + BFD_RELOC_MEP_PCREL24A2,
39315 + BFD_RELOC_MEP_PCABS24A2,
39316 + BFD_RELOC_MEP_LOW16,
39317 + BFD_RELOC_MEP_HI16U,
39318 + BFD_RELOC_MEP_HI16S,
39319 + BFD_RELOC_MEP_GPREL,
39320 + BFD_RELOC_MEP_TPREL,
39321 + BFD_RELOC_MEP_TPREL7,
39322 + BFD_RELOC_MEP_TPREL7A2,
39323 + BFD_RELOC_MEP_TPREL7A4,
39324 + BFD_RELOC_MEP_UIMM24,
39325 + BFD_RELOC_MEP_ADDR24A4,
39326 + BFD_RELOC_MEP_GNU_VTINHERIT,
39327 + BFD_RELOC_MEP_GNU_VTENTRY,
39328 +
39329 +
39330 +/* These are relocations for the GETA instruction. */
39331 + BFD_RELOC_MMIX_GETA,
39332 + BFD_RELOC_MMIX_GETA_1,
39333 + BFD_RELOC_MMIX_GETA_2,
39334 + BFD_RELOC_MMIX_GETA_3,
39335 +
39336 +/* These are relocations for a conditional branch instruction. */
39337 + BFD_RELOC_MMIX_CBRANCH,
39338 + BFD_RELOC_MMIX_CBRANCH_J,
39339 + BFD_RELOC_MMIX_CBRANCH_1,
39340 + BFD_RELOC_MMIX_CBRANCH_2,
39341 + BFD_RELOC_MMIX_CBRANCH_3,
39342 +
39343 +/* These are relocations for the PUSHJ instruction. */
39344 + BFD_RELOC_MMIX_PUSHJ,
39345 + BFD_RELOC_MMIX_PUSHJ_1,
39346 + BFD_RELOC_MMIX_PUSHJ_2,
39347 + BFD_RELOC_MMIX_PUSHJ_3,
39348 + BFD_RELOC_MMIX_PUSHJ_STUBBABLE,
39349 +
39350 +/* These are relocations for the JMP instruction. */
39351 + BFD_RELOC_MMIX_JMP,
39352 + BFD_RELOC_MMIX_JMP_1,
39353 + BFD_RELOC_MMIX_JMP_2,
39354 + BFD_RELOC_MMIX_JMP_3,
39355 +
39356 +/* This is a relocation for a relative address as in a GETA instruction or
39357 +a branch. */
39358 + BFD_RELOC_MMIX_ADDR19,
39359 +
39360 +/* This is a relocation for a relative address as in a JMP instruction. */
39361 + BFD_RELOC_MMIX_ADDR27,
39362 +
39363 +/* This is a relocation for an instruction field that may be a general
39364 +register or a value 0..255. */
39365 + BFD_RELOC_MMIX_REG_OR_BYTE,
39366 +
39367 +/* This is a relocation for an instruction field that may be a general
39368 +register. */
39369 + BFD_RELOC_MMIX_REG,
39370 +
39371 +/* This is a relocation for two instruction fields holding a register and
39372 +an offset, the equivalent of the relocation. */
39373 + BFD_RELOC_MMIX_BASE_PLUS_OFFSET,
39374 +
39375 +/* This relocation is an assertion that the expression is not allocated as
39376 +a global register. It does not modify contents. */
39377 + BFD_RELOC_MMIX_LOCAL,
39378 +
39379 +/* This is a 16 bit reloc for the AVR that stores 8 bit pc relative
39380 +short offset into 7 bits. */
39381 + BFD_RELOC_AVR_7_PCREL,
39382 +
39383 +/* This is a 16 bit reloc for the AVR that stores 13 bit pc relative
39384 +short offset into 12 bits. */
39385 + BFD_RELOC_AVR_13_PCREL,
39386 +
39387 +/* This is a 16 bit reloc for the AVR that stores 17 bit value (usually
39388 +program memory address) into 16 bits. */
39389 + BFD_RELOC_AVR_16_PM,
39390 +
39391 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (usually
39392 +data memory address) into 8 bit immediate value of LDI insn. */
39393 + BFD_RELOC_AVR_LO8_LDI,
39394 +
39395 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 bit
39396 +of data memory address) into 8 bit immediate value of LDI insn. */
39397 + BFD_RELOC_AVR_HI8_LDI,
39398 +
39399 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (most high 8 bit
39400 +of program memory address) into 8 bit immediate value of LDI insn. */
39401 + BFD_RELOC_AVR_HH8_LDI,
39402 +
39403 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (most high 8 bit
39404 +of 32 bit value) into 8 bit immediate value of LDI insn. */
39405 + BFD_RELOC_AVR_MS8_LDI,
39406 +
39407 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
39408 +(usually data memory address) into 8 bit immediate value of SUBI insn. */
39409 + BFD_RELOC_AVR_LO8_LDI_NEG,
39410 +
39411 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
39412 +(high 8 bit of data memory address) into 8 bit immediate value of
39413 +SUBI insn. */
39414 + BFD_RELOC_AVR_HI8_LDI_NEG,
39415 +
39416 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
39417 +(most high 8 bit of program memory address) into 8 bit immediate value
39418 +of LDI or SUBI insn. */
39419 + BFD_RELOC_AVR_HH8_LDI_NEG,
39420 +
39421 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value (msb
39422 +of 32 bit value) into 8 bit immediate value of LDI insn. */
39423 + BFD_RELOC_AVR_MS8_LDI_NEG,
39424 +
39425 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (usually
39426 +command address) into 8 bit immediate value of LDI insn. */
39427 + BFD_RELOC_AVR_LO8_LDI_PM,
39428 +
39429 +/* This is a 16 bit reloc for the AVR that stores 8 bit value
39430 +(command address) into 8 bit immediate value of LDI insn. If the address
39431 +is beyond the 128k boundary, the linker inserts a jump stub for this reloc
39432 +in the lower 128k. */
39433 + BFD_RELOC_AVR_LO8_LDI_GS,
39434 +
39435 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 bit
39436 +of command address) into 8 bit immediate value of LDI insn. */
39437 + BFD_RELOC_AVR_HI8_LDI_PM,
39438 +
39439 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 bit
39440 +of command address) into 8 bit immediate value of LDI insn. If the address
39441 +is beyond the 128k boundary, the linker inserts a jump stub for this reloc
39442 +below 128k. */
39443 + BFD_RELOC_AVR_HI8_LDI_GS,
39444 +
39445 +/* This is a 16 bit reloc for the AVR that stores 8 bit value (most high 8 bit
39446 +of command address) into 8 bit immediate value of LDI insn. */
39447 + BFD_RELOC_AVR_HH8_LDI_PM,
39448 +
39449 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
39450 +(usually command address) into 8 bit immediate value of SUBI insn. */
39451 + BFD_RELOC_AVR_LO8_LDI_PM_NEG,
39452 +
39453 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
39454 +(high 8 bit of 16 bit command address) into 8 bit immediate value
39455 +of SUBI insn. */
39456 + BFD_RELOC_AVR_HI8_LDI_PM_NEG,
39457 +
39458 +/* This is a 16 bit reloc for the AVR that stores negated 8 bit value
39459 +(high 6 bit of 22 bit command address) into 8 bit immediate
39460 +value of SUBI insn. */
39461 + BFD_RELOC_AVR_HH8_LDI_PM_NEG,
39462 +
39463 +/* This is a 32 bit reloc for the AVR that stores 23 bit value
39464 +into 22 bits. */
39465 + BFD_RELOC_AVR_CALL,
39466 +
39467 +/* This is a 16 bit reloc for the AVR that stores all needed bits
39468 +for absolute addressing with ldi with overflow check to linktime */
39469 + BFD_RELOC_AVR_LDI,
39470 +
39471 +/* This is a 6 bit reloc for the AVR that stores offset for ldd/std
39472 +instructions */
39473 + BFD_RELOC_AVR_6,
39474 +
39475 +/* This is a 6 bit reloc for the AVR that stores offset for adiw/sbiw
39476 +instructions */
39477 + BFD_RELOC_AVR_6_ADIW,
39478 +
39479 +/* Difference between two labels: L2 - L1. The value of L1 is encoded
39480 +as sym + addend, while the initial difference after assembly is
39481 +inserted into the object file by the assembler. */
39482 + BFD_RELOC_AVR32_DIFF32,
39483 + BFD_RELOC_AVR32_DIFF16,
39484 + BFD_RELOC_AVR32_DIFF8,
39485 +
39486 +/* Reference to a symbol through the Global Offset Table. The linker
39487 +will allocate an entry for symbol in the GOT and insert the offset
39488 +of this entry as the relocation value. */
39489 + BFD_RELOC_AVR32_GOT32,
39490 + BFD_RELOC_AVR32_GOT16,
39491 + BFD_RELOC_AVR32_GOT8,
39492 +
39493 +/* Normal (non-pc-relative) code relocations. Alignment and signedness
39494 +is indicated by the suffixes. S means signed, U means unsigned. W
39495 +means word-aligned, H means halfword-aligned, neither means
39496 +byte-aligned (no alignment.) SUB5 is the same relocation as 16S. */
39497 + BFD_RELOC_AVR32_21S,
39498 + BFD_RELOC_AVR32_16U,
39499 + BFD_RELOC_AVR32_16S,
39500 + BFD_RELOC_AVR32_SUB5,
39501 + BFD_RELOC_AVR32_8S_EXT,
39502 + BFD_RELOC_AVR32_8S,
39503 + BFD_RELOC_AVR32_15S,
39504 +
39505 +/* PC-relative relocations are signed if neither 'U' nor 'S' is
39506 +specified. However, we explicitly tack on a 'B' to indicate no
39507 +alignment, to avoid confusion with data relocs. All of these resolve
39508 +to sym + addend - offset, except the one with 'N' (negated) suffix.
39509 +This particular one resolves to offset - sym - addend. */
39510 + BFD_RELOC_AVR32_22H_PCREL,
39511 + BFD_RELOC_AVR32_18W_PCREL,
39512 + BFD_RELOC_AVR32_16B_PCREL,
39513 + BFD_RELOC_AVR32_16N_PCREL,
39514 + BFD_RELOC_AVR32_14UW_PCREL,
39515 + BFD_RELOC_AVR32_11H_PCREL,
39516 + BFD_RELOC_AVR32_10UW_PCREL,
39517 + BFD_RELOC_AVR32_9H_PCREL,
39518 + BFD_RELOC_AVR32_9UW_PCREL,
39519 +
39520 +/* Subtract the link-time address of the GOT from (symbol + addend)
39521 +and insert the result. */
39522 + BFD_RELOC_AVR32_GOTPC,
39523 +
39524 +/* Reference to a symbol through the GOT. The linker will allocate an
39525 +entry for symbol in the GOT and insert the offset of this entry as
39526 +the relocation value. addend must be zero. As usual, 'S' means
39527 +signed, 'W' means word-aligned, etc. */
39528 + BFD_RELOC_AVR32_GOTCALL,
39529 + BFD_RELOC_AVR32_LDA_GOT,
39530 + BFD_RELOC_AVR32_GOT21S,
39531 + BFD_RELOC_AVR32_GOT18SW,
39532 + BFD_RELOC_AVR32_GOT16S,
39533 +
39534 +/* 32-bit constant pool entry. I don't think 8- and 16-bit entries make
39535 +a whole lot of sense. */
39536 + BFD_RELOC_AVR32_32_CPENT,
39537 +
39538 +/* Constant pool references. Some of these relocations are signed,
39539 +others are unsigned. It doesn't really matter, since the constant
39540 +pool always comes after the code that references it. */
39541 + BFD_RELOC_AVR32_CPCALL,
39542 + BFD_RELOC_AVR32_16_CP,
39543 + BFD_RELOC_AVR32_9W_CP,
39544 +
39545 +/* sym must be the absolute symbol. The addend specifies the alignment
39546 +order, e.g. if addend is 2, the linker must add padding so that the
39547 +next address is aligned to a 4-byte boundary. */
39548 + BFD_RELOC_AVR32_ALIGN,
39549 +
39550 +/* Code relocations that will never make it to the output file. */
39551 + BFD_RELOC_AVR32_14UW,
39552 + BFD_RELOC_AVR32_10UW,
39553 + BFD_RELOC_AVR32_10SW,
39554 + BFD_RELOC_AVR32_STHH_W,
39555 + BFD_RELOC_AVR32_7UW,
39556 + BFD_RELOC_AVR32_6S,
39557 + BFD_RELOC_AVR32_6UW,
39558 + BFD_RELOC_AVR32_4UH,
39559 + BFD_RELOC_AVR32_3U,
39560 +
39561 +/* Direct 12 bit. */
39562 + BFD_RELOC_390_12,
39563 +
39564 +/* 12 bit GOT offset. */
39565 + BFD_RELOC_390_GOT12,
39566 +
39567 +/* 32 bit PC relative PLT address. */
39568 + BFD_RELOC_390_PLT32,
39569 +
39570 +/* Copy symbol at runtime. */
39571 + BFD_RELOC_390_COPY,
39572 +
39573 +/* Create GOT entry. */
39574 + BFD_RELOC_390_GLOB_DAT,
39575 +
39576 +/* Create PLT entry. */
39577 + BFD_RELOC_390_JMP_SLOT,
39578 +
39579 +/* Adjust by program base. */
39580 + BFD_RELOC_390_RELATIVE,
39581 +
39582 +/* 32 bit PC relative offset to GOT. */
39583 + BFD_RELOC_390_GOTPC,
39584 +
39585 +/* 16 bit GOT offset. */
39586 + BFD_RELOC_390_GOT16,
39587 +
39588 +/* PC relative 16 bit shifted by 1. */
39589 + BFD_RELOC_390_PC16DBL,
39590 +
39591 +/* 16 bit PC rel. PLT shifted by 1. */
39592 + BFD_RELOC_390_PLT16DBL,
39593 +
39594 +/* PC relative 32 bit shifted by 1. */
39595 + BFD_RELOC_390_PC32DBL,
39596 +
39597 +/* 32 bit PC rel. PLT shifted by 1. */
39598 + BFD_RELOC_390_PLT32DBL,
39599 +
39600 +/* 32 bit PC rel. GOT shifted by 1. */
39601 + BFD_RELOC_390_GOTPCDBL,
39602 +
39603 +/* 64 bit GOT offset. */
39604 + BFD_RELOC_390_GOT64,
39605 +
39606 +/* 64 bit PC relative PLT address. */
39607 + BFD_RELOC_390_PLT64,
39608 +
39609 +/* 32 bit rel. offset to GOT entry. */
39610 + BFD_RELOC_390_GOTENT,
39611 +
39612 +/* 64 bit offset to GOT. */
39613 + BFD_RELOC_390_GOTOFF64,
39614 +
39615 +/* 12-bit offset to symbol-entry within GOT, with PLT handling. */
39616 + BFD_RELOC_390_GOTPLT12,
39617 +
39618 +/* 16-bit offset to symbol-entry within GOT, with PLT handling. */
39619 + BFD_RELOC_390_GOTPLT16,
39620 +
39621 +/* 32-bit offset to symbol-entry within GOT, with PLT handling. */
39622 + BFD_RELOC_390_GOTPLT32,
39623 +
39624 +/* 64-bit offset to symbol-entry within GOT, with PLT handling. */
39625 + BFD_RELOC_390_GOTPLT64,
39626 +
39627 +/* 32-bit rel. offset to symbol-entry within GOT, with PLT handling. */
39628 + BFD_RELOC_390_GOTPLTENT,
39629 +
39630 +/* 16-bit rel. offset from the GOT to a PLT entry. */
39631 + BFD_RELOC_390_PLTOFF16,
39632 +
39633 +/* 32-bit rel. offset from the GOT to a PLT entry. */
39634 + BFD_RELOC_390_PLTOFF32,
39635 +
39636 +/* 64-bit rel. offset from the GOT to a PLT entry. */
39637 + BFD_RELOC_390_PLTOFF64,
39638 +
39639 +/* s390 tls relocations. */
39640 + BFD_RELOC_390_TLS_LOAD,
39641 + BFD_RELOC_390_TLS_GDCALL,
39642 + BFD_RELOC_390_TLS_LDCALL,
39643 + BFD_RELOC_390_TLS_GD32,
39644 + BFD_RELOC_390_TLS_GD64,
39645 + BFD_RELOC_390_TLS_GOTIE12,
39646 + BFD_RELOC_390_TLS_GOTIE32,
39647 + BFD_RELOC_390_TLS_GOTIE64,
39648 + BFD_RELOC_390_TLS_LDM32,
39649 + BFD_RELOC_390_TLS_LDM64,
39650 + BFD_RELOC_390_TLS_IE32,
39651 + BFD_RELOC_390_TLS_IE64,
39652 + BFD_RELOC_390_TLS_IEENT,
39653 + BFD_RELOC_390_TLS_LE32,
39654 + BFD_RELOC_390_TLS_LE64,
39655 + BFD_RELOC_390_TLS_LDO32,
39656 + BFD_RELOC_390_TLS_LDO64,
39657 + BFD_RELOC_390_TLS_DTPMOD,
39658 + BFD_RELOC_390_TLS_DTPOFF,
39659 + BFD_RELOC_390_TLS_TPOFF,
39660 +
39661 +/* Long displacement extension. */
39662 + BFD_RELOC_390_20,
39663 + BFD_RELOC_390_GOT20,
39664 + BFD_RELOC_390_GOTPLT20,
39665 + BFD_RELOC_390_TLS_GOTIE20,
39666 +
39667 +/* Score relocations */
39668 + BFD_RELOC_SCORE_DUMMY1,
39669 +
39670 +/* Low 16 bit for load/store */
39671 + BFD_RELOC_SCORE_GPREL15,
39672 +
39673 +/* This is a 24-bit reloc with the right 1 bit assumed to be 0 */
39674 + BFD_RELOC_SCORE_DUMMY2,
39675 + BFD_RELOC_SCORE_JMP,
39676 +
39677 +/* This is a 19-bit reloc with the right 1 bit assumed to be 0 */
39678 + BFD_RELOC_SCORE_BRANCH,
39679 +
39680 +/* This is a 11-bit reloc with the right 1 bit assumed to be 0 */
39681 + BFD_RELOC_SCORE16_JMP,
39682 +
39683 +/* This is a 8-bit reloc with the right 1 bit assumed to be 0 */
39684 + BFD_RELOC_SCORE16_BRANCH,
39685 +
39686 +/* Undocumented Score relocs */
39687 + BFD_RELOC_SCORE_GOT15,
39688 + BFD_RELOC_SCORE_GOT_LO16,
39689 + BFD_RELOC_SCORE_CALL15,
39690 + BFD_RELOC_SCORE_DUMMY_HI16,
39691 +
39692 +/* Scenix IP2K - 9-bit register number / data address */
39693 + BFD_RELOC_IP2K_FR9,
39694 +
39695 +/* Scenix IP2K - 4-bit register/data bank number */
39696 + BFD_RELOC_IP2K_BANK,
39697 +
39698 +/* Scenix IP2K - low 13 bits of instruction word address */
39699 + BFD_RELOC_IP2K_ADDR16CJP,
39700 +
39701 +/* Scenix IP2K - high 3 bits of instruction word address */
39702 + BFD_RELOC_IP2K_PAGE3,
39703 +
39704 +/* Scenix IP2K - ext/low/high 8 bits of data address */
39705 + BFD_RELOC_IP2K_LO8DATA,
39706 + BFD_RELOC_IP2K_HI8DATA,
39707 + BFD_RELOC_IP2K_EX8DATA,
39708 +
39709 +/* Scenix IP2K - low/high 8 bits of instruction word address */
39710 + BFD_RELOC_IP2K_LO8INSN,
39711 + BFD_RELOC_IP2K_HI8INSN,
39712 +
39713 +/* Scenix IP2K - even/odd PC modifier to modify snb pcl.0 */
39714 + BFD_RELOC_IP2K_PC_SKIP,
39715 +
39716 +/* Scenix IP2K - 16 bit word address in text section. */
39717 + BFD_RELOC_IP2K_TEXT,
39718 +
39719 +/* Scenix IP2K - 7-bit sp or dp offset */
39720 + BFD_RELOC_IP2K_FR_OFFSET,
39721 +
39722 +/* Scenix VPE4K coprocessor - data/insn-space addressing */
39723 + BFD_RELOC_VPE4KMATH_DATA,
39724 + BFD_RELOC_VPE4KMATH_INSN,
39725 +
39726 +/* These two relocations are used by the linker to determine which of
39727 +the entries in a C++ virtual function table are actually used. When
39728 +the --gc-sections option is given, the linker will zero out the entries
39729 +that are not used, so that the code for those functions need not be
39730 +included in the output.
39731 +
39732 +VTABLE_INHERIT is a zero-space relocation used to describe to the
39733 +linker the inheritance tree of a C++ virtual function table. The
39734 +relocation's symbol should be the parent class' vtable, and the
39735 +relocation should be located at the child vtable.
39736 +
39737 +VTABLE_ENTRY is a zero-space relocation that describes the use of a
39738 +virtual function table entry. The reloc's symbol should refer to the
39739 +table of the class mentioned in the code. Off of that base, an offset
39740 +describes the entry that is being used. For Rela hosts, this offset
39741 +is stored in the reloc's addend. For Rel hosts, we are forced to put
39742 +this offset in the reloc's section offset. */
39743 + BFD_RELOC_VTABLE_INHERIT,
39744 + BFD_RELOC_VTABLE_ENTRY,
39745 +
39746 +/* Intel IA64 Relocations. */
39747 + BFD_RELOC_IA64_IMM14,
39748 + BFD_RELOC_IA64_IMM22,
39749 + BFD_RELOC_IA64_IMM64,
39750 + BFD_RELOC_IA64_DIR32MSB,
39751 + BFD_RELOC_IA64_DIR32LSB,
39752 + BFD_RELOC_IA64_DIR64MSB,
39753 + BFD_RELOC_IA64_DIR64LSB,
39754 + BFD_RELOC_IA64_GPREL22,
39755 + BFD_RELOC_IA64_GPREL64I,
39756 + BFD_RELOC_IA64_GPREL32MSB,
39757 + BFD_RELOC_IA64_GPREL32LSB,
39758 + BFD_RELOC_IA64_GPREL64MSB,
39759 + BFD_RELOC_IA64_GPREL64LSB,
39760 + BFD_RELOC_IA64_LTOFF22,
39761 + BFD_RELOC_IA64_LTOFF64I,
39762 + BFD_RELOC_IA64_PLTOFF22,
39763 + BFD_RELOC_IA64_PLTOFF64I,
39764 + BFD_RELOC_IA64_PLTOFF64MSB,
39765 + BFD_RELOC_IA64_PLTOFF64LSB,
39766 + BFD_RELOC_IA64_FPTR64I,
39767 + BFD_RELOC_IA64_FPTR32MSB,
39768 + BFD_RELOC_IA64_FPTR32LSB,
39769 + BFD_RELOC_IA64_FPTR64MSB,
39770 + BFD_RELOC_IA64_FPTR64LSB,
39771 + BFD_RELOC_IA64_PCREL21B,
39772 + BFD_RELOC_IA64_PCREL21BI,
39773 + BFD_RELOC_IA64_PCREL21M,
39774 + BFD_RELOC_IA64_PCREL21F,
39775 + BFD_RELOC_IA64_PCREL22,
39776 + BFD_RELOC_IA64_PCREL60B,
39777 + BFD_RELOC_IA64_PCREL64I,
39778 + BFD_RELOC_IA64_PCREL32MSB,
39779 + BFD_RELOC_IA64_PCREL32LSB,
39780 + BFD_RELOC_IA64_PCREL64MSB,
39781 + BFD_RELOC_IA64_PCREL64LSB,
39782 + BFD_RELOC_IA64_LTOFF_FPTR22,
39783 + BFD_RELOC_IA64_LTOFF_FPTR64I,
39784 + BFD_RELOC_IA64_LTOFF_FPTR32MSB,
39785 + BFD_RELOC_IA64_LTOFF_FPTR32LSB,
39786 + BFD_RELOC_IA64_LTOFF_FPTR64MSB,
39787 + BFD_RELOC_IA64_LTOFF_FPTR64LSB,
39788 + BFD_RELOC_IA64_SEGREL32MSB,
39789 + BFD_RELOC_IA64_SEGREL32LSB,
39790 + BFD_RELOC_IA64_SEGREL64MSB,
39791 + BFD_RELOC_IA64_SEGREL64LSB,
39792 + BFD_RELOC_IA64_SECREL32MSB,
39793 + BFD_RELOC_IA64_SECREL32LSB,
39794 + BFD_RELOC_IA64_SECREL64MSB,
39795 + BFD_RELOC_IA64_SECREL64LSB,
39796 + BFD_RELOC_IA64_REL32MSB,
39797 + BFD_RELOC_IA64_REL32LSB,
39798 + BFD_RELOC_IA64_REL64MSB,
39799 + BFD_RELOC_IA64_REL64LSB,
39800 + BFD_RELOC_IA64_LTV32MSB,
39801 + BFD_RELOC_IA64_LTV32LSB,
39802 + BFD_RELOC_IA64_LTV64MSB,
39803 + BFD_RELOC_IA64_LTV64LSB,
39804 + BFD_RELOC_IA64_IPLTMSB,
39805 + BFD_RELOC_IA64_IPLTLSB,
39806 + BFD_RELOC_IA64_COPY,
39807 + BFD_RELOC_IA64_LTOFF22X,
39808 + BFD_RELOC_IA64_LDXMOV,
39809 + BFD_RELOC_IA64_TPREL14,
39810 + BFD_RELOC_IA64_TPREL22,
39811 + BFD_RELOC_IA64_TPREL64I,
39812 + BFD_RELOC_IA64_TPREL64MSB,
39813 + BFD_RELOC_IA64_TPREL64LSB,
39814 + BFD_RELOC_IA64_LTOFF_TPREL22,
39815 + BFD_RELOC_IA64_DTPMOD64MSB,
39816 + BFD_RELOC_IA64_DTPMOD64LSB,
39817 + BFD_RELOC_IA64_LTOFF_DTPMOD22,
39818 + BFD_RELOC_IA64_DTPREL14,
39819 + BFD_RELOC_IA64_DTPREL22,
39820 + BFD_RELOC_IA64_DTPREL64I,
39821 + BFD_RELOC_IA64_DTPREL32MSB,
39822 + BFD_RELOC_IA64_DTPREL32LSB,
39823 + BFD_RELOC_IA64_DTPREL64MSB,
39824 + BFD_RELOC_IA64_DTPREL64LSB,
39825 + BFD_RELOC_IA64_LTOFF_DTPREL22,
39826 +
39827 +/* Motorola 68HC11 reloc.
39828 +This is the 8 bit high part of an absolute address. */
39829 + BFD_RELOC_M68HC11_HI8,
39830 +
39831 +/* Motorola 68HC11 reloc.
39832 +This is the 8 bit low part of an absolute address. */
39833 + BFD_RELOC_M68HC11_LO8,
39834 +
39835 +/* Motorola 68HC11 reloc.
39836 +This is the 3 bit of a value. */
39837 + BFD_RELOC_M68HC11_3B,
39838 +
39839 +/* Motorola 68HC11 reloc.
39840 +This reloc marks the beginning of a jump/call instruction.
39841 +It is used for linker relaxation to correctly identify beginning
39842 +of instruction and change some branches to use PC-relative
39843 +addressing mode. */
39844 + BFD_RELOC_M68HC11_RL_JUMP,
39845 +
39846 +/* Motorola 68HC11 reloc.
39847 +This reloc marks a group of several instructions that gcc generates
39848 +and for which the linker relaxation pass can modify and/or remove
39849 +some of them. */
39850 + BFD_RELOC_M68HC11_RL_GROUP,
39851 +
39852 +/* Motorola 68HC11 reloc.
39853 +This is the 16-bit lower part of an address. It is used for 'call'
39854 +instruction to specify the symbol address without any special
39855 +transformation (due to memory bank window). */
39856 + BFD_RELOC_M68HC11_LO16,
39857 +
39858 +/* Motorola 68HC11 reloc.
39859 +This is a 8-bit reloc that specifies the page number of an address.
39860 +It is used by 'call' instruction to specify the page number of
39861 +the symbol. */
39862 + BFD_RELOC_M68HC11_PAGE,
39863 +
39864 +/* Motorola 68HC11 reloc.
39865 +This is a 24-bit reloc that represents the address with a 16-bit
39866 +value and a 8-bit page number. The symbol address is transformed
39867 +to follow the 16K memory bank of 68HC12 (seen as mapped in the window). */
39868 + BFD_RELOC_M68HC11_24,
39869 +
39870 +/* Motorola 68HC12 reloc.
39871 +This is the 5 bits of a value. */
39872 + BFD_RELOC_M68HC12_5B,
39873 +
39874 +/* NS CR16C Relocations. */
39875 + BFD_RELOC_16C_NUM08,
39876 + BFD_RELOC_16C_NUM08_C,
39877 + BFD_RELOC_16C_NUM16,
39878 + BFD_RELOC_16C_NUM16_C,
39879 + BFD_RELOC_16C_NUM32,
39880 + BFD_RELOC_16C_NUM32_C,
39881 + BFD_RELOC_16C_DISP04,
39882 + BFD_RELOC_16C_DISP04_C,
39883 + BFD_RELOC_16C_DISP08,
39884 + BFD_RELOC_16C_DISP08_C,
39885 + BFD_RELOC_16C_DISP16,
39886 + BFD_RELOC_16C_DISP16_C,
39887 + BFD_RELOC_16C_DISP24,
39888 + BFD_RELOC_16C_DISP24_C,
39889 + BFD_RELOC_16C_DISP24a,
39890 + BFD_RELOC_16C_DISP24a_C,
39891 + BFD_RELOC_16C_REG04,
39892 + BFD_RELOC_16C_REG04_C,
39893 + BFD_RELOC_16C_REG04a,
39894 + BFD_RELOC_16C_REG04a_C,
39895 + BFD_RELOC_16C_REG14,
39896 + BFD_RELOC_16C_REG14_C,
39897 + BFD_RELOC_16C_REG16,
39898 + BFD_RELOC_16C_REG16_C,
39899 + BFD_RELOC_16C_REG20,
39900 + BFD_RELOC_16C_REG20_C,
39901 + BFD_RELOC_16C_ABS20,
39902 + BFD_RELOC_16C_ABS20_C,
39903 + BFD_RELOC_16C_ABS24,
39904 + BFD_RELOC_16C_ABS24_C,
39905 + BFD_RELOC_16C_IMM04,
39906 + BFD_RELOC_16C_IMM04_C,
39907 + BFD_RELOC_16C_IMM16,
39908 + BFD_RELOC_16C_IMM16_C,
39909 + BFD_RELOC_16C_IMM20,
39910 + BFD_RELOC_16C_IMM20_C,
39911 + BFD_RELOC_16C_IMM24,
39912 + BFD_RELOC_16C_IMM24_C,
39913 + BFD_RELOC_16C_IMM32,
39914 + BFD_RELOC_16C_IMM32_C,
39915 +
39916 +/* NS CR16 Relocations. */
39917 + BFD_RELOC_CR16_NUM8,
39918 + BFD_RELOC_CR16_NUM16,
39919 + BFD_RELOC_CR16_NUM32,
39920 + BFD_RELOC_CR16_NUM32a,
39921 + BFD_RELOC_CR16_REGREL0,
39922 + BFD_RELOC_CR16_REGREL4,
39923 + BFD_RELOC_CR16_REGREL4a,
39924 + BFD_RELOC_CR16_REGREL14,
39925 + BFD_RELOC_CR16_REGREL14a,
39926 + BFD_RELOC_CR16_REGREL16,
39927 + BFD_RELOC_CR16_REGREL20,
39928 + BFD_RELOC_CR16_REGREL20a,
39929 + BFD_RELOC_CR16_ABS20,
39930 + BFD_RELOC_CR16_ABS24,
39931 + BFD_RELOC_CR16_IMM4,
39932 + BFD_RELOC_CR16_IMM8,
39933 + BFD_RELOC_CR16_IMM16,
39934 + BFD_RELOC_CR16_IMM20,
39935 + BFD_RELOC_CR16_IMM24,
39936 + BFD_RELOC_CR16_IMM32,
39937 + BFD_RELOC_CR16_IMM32a,
39938 + BFD_RELOC_CR16_DISP4,
39939 + BFD_RELOC_CR16_DISP8,
39940 + BFD_RELOC_CR16_DISP16,
39941 + BFD_RELOC_CR16_DISP20,
39942 + BFD_RELOC_CR16_DISP24,
39943 + BFD_RELOC_CR16_DISP24a,
39944 +
39945 +/* NS CRX Relocations. */
39946 + BFD_RELOC_CRX_REL4,
39947 + BFD_RELOC_CRX_REL8,
39948 + BFD_RELOC_CRX_REL8_CMP,
39949 + BFD_RELOC_CRX_REL16,
39950 + BFD_RELOC_CRX_REL24,
39951 + BFD_RELOC_CRX_REL32,
39952 + BFD_RELOC_CRX_REGREL12,
39953 + BFD_RELOC_CRX_REGREL22,
39954 + BFD_RELOC_CRX_REGREL28,
39955 + BFD_RELOC_CRX_REGREL32,
39956 + BFD_RELOC_CRX_ABS16,
39957 + BFD_RELOC_CRX_ABS32,
39958 + BFD_RELOC_CRX_NUM8,
39959 + BFD_RELOC_CRX_NUM16,
39960 + BFD_RELOC_CRX_NUM32,
39961 + BFD_RELOC_CRX_IMM16,
39962 + BFD_RELOC_CRX_IMM32,
39963 + BFD_RELOC_CRX_SWITCH8,
39964 + BFD_RELOC_CRX_SWITCH16,
39965 + BFD_RELOC_CRX_SWITCH32,
39966 +
39967 +/* These relocs are only used within the CRIS assembler. They are not
39968 +(at present) written to any object files. */
39969 + BFD_RELOC_CRIS_BDISP8,
39970 + BFD_RELOC_CRIS_UNSIGNED_5,
39971 + BFD_RELOC_CRIS_SIGNED_6,
39972 + BFD_RELOC_CRIS_UNSIGNED_6,
39973 + BFD_RELOC_CRIS_SIGNED_8,
39974 + BFD_RELOC_CRIS_UNSIGNED_8,
39975 + BFD_RELOC_CRIS_SIGNED_16,
39976 + BFD_RELOC_CRIS_UNSIGNED_16,
39977 + BFD_RELOC_CRIS_LAPCQ_OFFSET,
39978 + BFD_RELOC_CRIS_UNSIGNED_4,
39979 +
39980 +/* Relocs used in ELF shared libraries for CRIS. */
39981 + BFD_RELOC_CRIS_COPY,
39982 + BFD_RELOC_CRIS_GLOB_DAT,
39983 + BFD_RELOC_CRIS_JUMP_SLOT,
39984 + BFD_RELOC_CRIS_RELATIVE,
39985 +
39986 +/* 32-bit offset to symbol-entry within GOT. */
39987 + BFD_RELOC_CRIS_32_GOT,
39988 +
39989 +/* 16-bit offset to symbol-entry within GOT. */
39990 + BFD_RELOC_CRIS_16_GOT,
39991 +
39992 +/* 32-bit offset to symbol-entry within GOT, with PLT handling. */
39993 + BFD_RELOC_CRIS_32_GOTPLT,
39994 +
39995 +/* 16-bit offset to symbol-entry within GOT, with PLT handling. */
39996 + BFD_RELOC_CRIS_16_GOTPLT,
39997 +
39998 +/* 32-bit offset to symbol, relative to GOT. */
39999 + BFD_RELOC_CRIS_32_GOTREL,
40000 +
40001 +/* 32-bit offset to symbol with PLT entry, relative to GOT. */
40002 + BFD_RELOC_CRIS_32_PLT_GOTREL,
40003 +
40004 +/* 32-bit offset to symbol with PLT entry, relative to this relocation. */
40005 + BFD_RELOC_CRIS_32_PLT_PCREL,
40006 +
40007 +/* Intel i860 Relocations. */
40008 + BFD_RELOC_860_COPY,
40009 + BFD_RELOC_860_GLOB_DAT,
40010 + BFD_RELOC_860_JUMP_SLOT,
40011 + BFD_RELOC_860_RELATIVE,
40012 + BFD_RELOC_860_PC26,
40013 + BFD_RELOC_860_PLT26,
40014 + BFD_RELOC_860_PC16,
40015 + BFD_RELOC_860_LOW0,
40016 + BFD_RELOC_860_SPLIT0,
40017 + BFD_RELOC_860_LOW1,
40018 + BFD_RELOC_860_SPLIT1,
40019 + BFD_RELOC_860_LOW2,
40020 + BFD_RELOC_860_SPLIT2,
40021 + BFD_RELOC_860_LOW3,
40022 + BFD_RELOC_860_LOGOT0,
40023 + BFD_RELOC_860_SPGOT0,
40024 + BFD_RELOC_860_LOGOT1,
40025 + BFD_RELOC_860_SPGOT1,
40026 + BFD_RELOC_860_LOGOTOFF0,
40027 + BFD_RELOC_860_SPGOTOFF0,
40028 + BFD_RELOC_860_LOGOTOFF1,
40029 + BFD_RELOC_860_SPGOTOFF1,
40030 + BFD_RELOC_860_LOGOTOFF2,
40031 + BFD_RELOC_860_LOGOTOFF3,
40032 + BFD_RELOC_860_LOPC,
40033 + BFD_RELOC_860_HIGHADJ,
40034 + BFD_RELOC_860_HAGOT,
40035 + BFD_RELOC_860_HAGOTOFF,
40036 + BFD_RELOC_860_HAPC,
40037 + BFD_RELOC_860_HIGH,
40038 + BFD_RELOC_860_HIGOT,
40039 + BFD_RELOC_860_HIGOTOFF,
40040 +
40041 +/* OpenRISC Relocations. */
40042 + BFD_RELOC_OPENRISC_ABS_26,
40043 + BFD_RELOC_OPENRISC_REL_26,
40044 +
40045 +/* H8 elf Relocations. */
40046 + BFD_RELOC_H8_DIR16A8,
40047 + BFD_RELOC_H8_DIR16R8,
40048 + BFD_RELOC_H8_DIR24A8,
40049 + BFD_RELOC_H8_DIR24R8,
40050 + BFD_RELOC_H8_DIR32A16,
40051 +
40052 +/* Sony Xstormy16 Relocations. */
40053 + BFD_RELOC_XSTORMY16_REL_12,
40054 + BFD_RELOC_XSTORMY16_12,
40055 + BFD_RELOC_XSTORMY16_24,
40056 + BFD_RELOC_XSTORMY16_FPTR16,
40057 +
40058 +/* Self-describing complex relocations. */
40059 + BFD_RELOC_RELC,
40060 +
40061 +
40062 +/* Infineon Relocations. */
40063 + BFD_RELOC_XC16X_PAG,
40064 + BFD_RELOC_XC16X_POF,
40065 + BFD_RELOC_XC16X_SEG,
40066 + BFD_RELOC_XC16X_SOF,
40067 +
40068 +/* Relocations used by VAX ELF. */
40069 + BFD_RELOC_VAX_GLOB_DAT,
40070 + BFD_RELOC_VAX_JMP_SLOT,
40071 + BFD_RELOC_VAX_RELATIVE,
40072 +
40073 +/* Morpho MT - 16 bit immediate relocation. */
40074 + BFD_RELOC_MT_PC16,
40075 +
40076 +/* Morpho MT - Hi 16 bits of an address. */
40077 + BFD_RELOC_MT_HI16,
40078 +
40079 +/* Morpho MT - Low 16 bits of an address. */
40080 + BFD_RELOC_MT_LO16,
40081 +
40082 +/* Morpho MT - Used to tell the linker which vtable entries are used. */
40083 + BFD_RELOC_MT_GNU_VTINHERIT,
40084 +
40085 +/* Morpho MT - Used to tell the linker which vtable entries are used. */
40086 + BFD_RELOC_MT_GNU_VTENTRY,
40087 +
40088 +/* Morpho MT - 8 bit immediate relocation. */
40089 + BFD_RELOC_MT_PCINSN8,
40090 +
40091 +/* msp430 specific relocation codes */
40092 + BFD_RELOC_MSP430_10_PCREL,
40093 + BFD_RELOC_MSP430_16_PCREL,
40094 + BFD_RELOC_MSP430_16,
40095 + BFD_RELOC_MSP430_16_PCREL_BYTE,
40096 + BFD_RELOC_MSP430_16_BYTE,
40097 + BFD_RELOC_MSP430_2X_PCREL,
40098 + BFD_RELOC_MSP430_RL_PCREL,
40099 +
40100 +/* IQ2000 Relocations. */
40101 + BFD_RELOC_IQ2000_OFFSET_16,
40102 + BFD_RELOC_IQ2000_OFFSET_21,
40103 + BFD_RELOC_IQ2000_UHI16,
40104 +
40105 +/* Special Xtensa relocation used only by PLT entries in ELF shared
40106 +objects to indicate that the runtime linker should set the value
40107 +to one of its own internal functions or data structures. */
40108 + BFD_RELOC_XTENSA_RTLD,
40109 +
40110 +/* Xtensa relocations for ELF shared objects. */
40111 + BFD_RELOC_XTENSA_GLOB_DAT,
40112 + BFD_RELOC_XTENSA_JMP_SLOT,
40113 + BFD_RELOC_XTENSA_RELATIVE,
40114 +
40115 +/* Xtensa relocation used in ELF object files for symbols that may require
40116 +PLT entries. Otherwise, this is just a generic 32-bit relocation. */
40117 + BFD_RELOC_XTENSA_PLT,
40118 +
40119 +/* Xtensa relocations to mark the difference of two local symbols.
40120 +These are only needed to support linker relaxation and can be ignored
40121 +when not relaxing. The field is set to the value of the difference
40122 +assuming no relaxation. The relocation encodes the position of the
40123 +first symbol so the linker can determine whether to adjust the field
40124 +value. */
40125 + BFD_RELOC_XTENSA_DIFF8,
40126 + BFD_RELOC_XTENSA_DIFF16,
40127 + BFD_RELOC_XTENSA_DIFF32,
40128 +
40129 +/* Generic Xtensa relocations for instruction operands. Only the slot
40130 +number is encoded in the relocation. The relocation applies to the
40131 +last PC-relative immediate operand, or if there are no PC-relative
40132 +immediates, to the last immediate operand. */
40133 + BFD_RELOC_XTENSA_SLOT0_OP,
40134 + BFD_RELOC_XTENSA_SLOT1_OP,
40135 + BFD_RELOC_XTENSA_SLOT2_OP,
40136 + BFD_RELOC_XTENSA_SLOT3_OP,
40137 + BFD_RELOC_XTENSA_SLOT4_OP,
40138 + BFD_RELOC_XTENSA_SLOT5_OP,
40139 + BFD_RELOC_XTENSA_SLOT6_OP,
40140 + BFD_RELOC_XTENSA_SLOT7_OP,
40141 + BFD_RELOC_XTENSA_SLOT8_OP,
40142 + BFD_RELOC_XTENSA_SLOT9_OP,
40143 + BFD_RELOC_XTENSA_SLOT10_OP,
40144 + BFD_RELOC_XTENSA_SLOT11_OP,
40145 + BFD_RELOC_XTENSA_SLOT12_OP,
40146 + BFD_RELOC_XTENSA_SLOT13_OP,
40147 + BFD_RELOC_XTENSA_SLOT14_OP,
40148 +
40149 +/* Alternate Xtensa relocations. Only the slot is encoded in the
40150 +relocation. The meaning of these relocations is opcode-specific. */
40151 + BFD_RELOC_XTENSA_SLOT0_ALT,
40152 + BFD_RELOC_XTENSA_SLOT1_ALT,
40153 + BFD_RELOC_XTENSA_SLOT2_ALT,
40154 + BFD_RELOC_XTENSA_SLOT3_ALT,
40155 + BFD_RELOC_XTENSA_SLOT4_ALT,
40156 + BFD_RELOC_XTENSA_SLOT5_ALT,
40157 + BFD_RELOC_XTENSA_SLOT6_ALT,
40158 + BFD_RELOC_XTENSA_SLOT7_ALT,
40159 + BFD_RELOC_XTENSA_SLOT8_ALT,
40160 + BFD_RELOC_XTENSA_SLOT9_ALT,
40161 + BFD_RELOC_XTENSA_SLOT10_ALT,
40162 + BFD_RELOC_XTENSA_SLOT11_ALT,
40163 + BFD_RELOC_XTENSA_SLOT12_ALT,
40164 + BFD_RELOC_XTENSA_SLOT13_ALT,
40165 + BFD_RELOC_XTENSA_SLOT14_ALT,
40166 +
40167 +/* Xtensa relocations for backward compatibility. These have all been
40168 +replaced by BFD_RELOC_XTENSA_SLOT0_OP. */
40169 + BFD_RELOC_XTENSA_OP0,
40170 + BFD_RELOC_XTENSA_OP1,
40171 + BFD_RELOC_XTENSA_OP2,
40172 +
40173 +/* Xtensa relocation to mark that the assembler expanded the
40174 +instructions from an original target. The expansion size is
40175 +encoded in the reloc size. */
40176 + BFD_RELOC_XTENSA_ASM_EXPAND,
40177 +
40178 +/* Xtensa relocation to mark that the linker should simplify
40179 +assembler-expanded instructions. This is commonly used
40180 +internally by the linker after analysis of a
40181 +BFD_RELOC_XTENSA_ASM_EXPAND. */
40182 + BFD_RELOC_XTENSA_ASM_SIMPLIFY,
40183 +
40184 +/* 8 bit signed offset in (ix+d) or (iy+d). */
40185 + BFD_RELOC_Z80_DISP8,
40186 +
40187 +/* DJNZ offset. */
40188 + BFD_RELOC_Z8K_DISP7,
40189 +
40190 +/* CALR offset. */
40191 + BFD_RELOC_Z8K_CALLR,
40192 +
40193 +/* 4 bit value. */
40194 + BFD_RELOC_Z8K_IMM4L,
40195 + BFD_RELOC_UNUSED };
40196 +typedef enum bfd_reloc_code_real bfd_reloc_code_real_type;
40197 +reloc_howto_type *bfd_reloc_type_lookup
40198 + (bfd *abfd, bfd_reloc_code_real_type code);
40199 +reloc_howto_type *bfd_reloc_name_lookup
40200 + (bfd *abfd, const char *reloc_name);
40201 +
40202 +const char *bfd_get_reloc_code_name (bfd_reloc_code_real_type code);
40203 +
40204 +/* Extracted from syms.c. */
40205 +
40206 +typedef struct bfd_symbol
40207 +{
40208 + /* A pointer to the BFD which owns the symbol. This information
40209 + is necessary so that a back end can work out what additional
40210 + information (invisible to the application writer) is carried
40211 + with the symbol.
40212 +
40213 + This field is *almost* redundant, since you can use section->owner
40214 + instead, except that some symbols point to the global sections
40215 + bfd_{abs,com,und}_section. This could be fixed by making
40216 + these globals be per-bfd (or per-target-flavor). FIXME. */
40217 + struct bfd *the_bfd; /* Use bfd_asymbol_bfd(sym) to access this field. */
40218 +
40219 + /* The text of the symbol. The name is left alone, and not copied; the
40220 + application may not alter it. */
40221 + const char *name;
40222 +
40223 + /* The value of the symbol. This really should be a union of a
40224 + numeric value with a pointer, since some flags indicate that
40225 + a pointer to another symbol is stored here. */
40226 + symvalue value;
40227 +
40228 + /* Attributes of a symbol. */
40229 +#define BSF_NO_FLAGS 0x00
40230 +
40231 + /* The symbol has local scope; <<static>> in <<C>>. The value
40232 + is the offset into the section of the data. */
40233 +#define BSF_LOCAL 0x01
40234 +
40235 + /* The symbol has global scope; initialized data in <<C>>. The
40236 + value is the offset into the section of the data. */
40237 +#define BSF_GLOBAL 0x02
40238 +
40239 + /* The symbol has global scope and is exported. The value is
40240 + the offset into the section of the data. */
40241 +#define BSF_EXPORT BSF_GLOBAL /* No real difference. */
40242 +
40243 + /* A normal C symbol would be one of:
40244 + <<BSF_LOCAL>>, <<BSF_FORT_COMM>>, <<BSF_UNDEFINED>> or
40245 + <<BSF_GLOBAL>>. */
40246 +
40247 + /* The symbol is a debugging record. The value has an arbitrary
40248 + meaning, unless BSF_DEBUGGING_RELOC is also set. */
40249 +#define BSF_DEBUGGING 0x08
40250 +
40251 + /* The symbol denotes a function entry point. Used in ELF,
40252 + perhaps others someday. */
40253 +#define BSF_FUNCTION 0x10
40254 +
40255 + /* Used by the linker. */
40256 +#define BSF_KEEP 0x20
40257 +#define BSF_KEEP_G 0x40
40258 +
40259 + /* A weak global symbol, overridable without warnings by
40260 + a regular global symbol of the same name. */
40261 +#define BSF_WEAK 0x80
40262 +
40263 + /* This symbol was created to point to a section, e.g. ELF's
40264 + STT_SECTION symbols. */
40265 +#define BSF_SECTION_SYM 0x100
40266 +
40267 + /* The symbol used to be a common symbol, but now it is
40268 + allocated. */
40269 +#define BSF_OLD_COMMON 0x200
40270 +
40271 + /* The default value for common data. */
40272 +#define BFD_FORT_COMM_DEFAULT_VALUE 0
40273 +
40274 + /* In some files the type of a symbol sometimes alters its
40275 + location in an output file - ie in coff a <<ISFCN>> symbol
40276 + which is also <<C_EXT>> symbol appears where it was
40277 + declared and not at the end of a section. This bit is set
40278 + by the target BFD part to convey this information. */
40279 +#define BSF_NOT_AT_END 0x400
40280 +
40281 + /* Signal that the symbol is the label of constructor section. */
40282 +#define BSF_CONSTRUCTOR 0x800
40283 +
40284 + /* Signal that the symbol is a warning symbol. The name is a
40285 + warning. The name of the next symbol is the one to warn about;
40286 + if a reference is made to a symbol with the same name as the next
40287 + symbol, a warning is issued by the linker. */
40288 +#define BSF_WARNING 0x1000
40289 +
40290 + /* Signal that the symbol is indirect. This symbol is an indirect
40291 + pointer to the symbol with the same name as the next symbol. */
40292 +#define BSF_INDIRECT 0x2000
40293 +
40294 + /* BSF_FILE marks symbols that contain a file name. This is used
40295 + for ELF STT_FILE symbols. */
40296 +#define BSF_FILE 0x4000
40297 +
40298 + /* Symbol is from dynamic linking information. */
40299 +#define BSF_DYNAMIC 0x8000
40300 +
40301 + /* The symbol denotes a data object. Used in ELF, and perhaps
40302 + others someday. */
40303 +#define BSF_OBJECT 0x10000
40304 +
40305 + /* This symbol is a debugging symbol. The value is the offset
40306 + into the section of the data. BSF_DEBUGGING should be set
40307 + as well. */
40308 +#define BSF_DEBUGGING_RELOC 0x20000
40309 +
40310 + /* This symbol is thread local. Used in ELF. */
40311 +#define BSF_THREAD_LOCAL 0x40000
40312 +
40313 + /* This symbol represents a complex relocation expression,
40314 + with the expression tree serialized in the symbol name. */
40315 +#define BSF_RELC 0x80000
40316 +
40317 + /* This symbol represents a signed complex relocation expression,
40318 + with the expression tree serialized in the symbol name. */
40319 +#define BSF_SRELC 0x100000
40320 +
40321 + flagword flags;
40322 +
40323 + /* A pointer to the section to which this symbol is
40324 + relative. This will always be non NULL, there are special
40325 + sections for undefined and absolute symbols. */
40326 + struct bfd_section *section;
40327 +
40328 + /* Back end special data. */
40329 + union
40330 + {
40331 + void *p;
40332 + bfd_vma i;
40333 + }
40334 + udata;
40335 +}
40336 +asymbol;
40337 +
40338 +#define bfd_get_symtab_upper_bound(abfd) \
40339 + BFD_SEND (abfd, _bfd_get_symtab_upper_bound, (abfd))
40340 +
40341 +bfd_boolean bfd_is_local_label (bfd *abfd, asymbol *sym);
40342 +
40343 +bfd_boolean bfd_is_local_label_name (bfd *abfd, const char *name);
40344 +
40345 +#define bfd_is_local_label_name(abfd, name) \
40346 + BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
40347 +
40348 +bfd_boolean bfd_is_target_special_symbol (bfd *abfd, asymbol *sym);
40349 +
40350 +#define bfd_is_target_special_symbol(abfd, sym) \
40351 + BFD_SEND (abfd, _bfd_is_target_special_symbol, (abfd, sym))
40352 +
40353 +#define bfd_canonicalize_symtab(abfd, location) \
40354 + BFD_SEND (abfd, _bfd_canonicalize_symtab, (abfd, location))
40355 +
40356 +bfd_boolean bfd_set_symtab
40357 + (bfd *abfd, asymbol **location, unsigned int count);
40358 +
40359 +void bfd_print_symbol_vandf (bfd *abfd, void *file, asymbol *symbol);
40360 +
40361 +#define bfd_make_empty_symbol(abfd) \
40362 + BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd))
40363 +
40364 +asymbol *_bfd_generic_make_empty_symbol (bfd *);
40365 +
40366 +#define bfd_make_debug_symbol(abfd,ptr,size) \
40367 + BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd, ptr, size))
40368 +
40369 +int bfd_decode_symclass (asymbol *symbol);
40370 +
40371 +bfd_boolean bfd_is_undefined_symclass (int symclass);
40372 +
40373 +void bfd_symbol_info (asymbol *symbol, symbol_info *ret);
40374 +
40375 +bfd_boolean bfd_copy_private_symbol_data
40376 + (bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym);
40377 +
40378 +#define bfd_copy_private_symbol_data(ibfd, isymbol, obfd, osymbol) \
40379 + BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
40380 + (ibfd, isymbol, obfd, osymbol))
40381 +
40382 +/* Extracted from bfd.c. */
40383 +struct bfd
40384 +{
40385 + /* A unique identifier of the BFD */
40386 + unsigned int id;
40387 +
40388 + /* The filename the application opened the BFD with. */
40389 + const char *filename;
40390 +
40391 + /* A pointer to the target jump table. */
40392 + const struct bfd_target *xvec;
40393 +
40394 + /* The IOSTREAM, and corresponding IO vector that provide access
40395 + to the file backing the BFD. */
40396 + void *iostream;
40397 + const struct bfd_iovec *iovec;
40398 +
40399 + /* Is the file descriptor being cached? That is, can it be closed as
40400 + needed, and re-opened when accessed later? */
40401 + bfd_boolean cacheable;
40402 +
40403 + /* Marks whether there was a default target specified when the
40404 + BFD was opened. This is used to select which matching algorithm
40405 + to use to choose the back end. */
40406 + bfd_boolean target_defaulted;
40407 +
40408 + /* The caching routines use these to maintain a
40409 + least-recently-used list of BFDs. */
40410 + struct bfd *lru_prev, *lru_next;
40411 +
40412 + /* When a file is closed by the caching routines, BFD retains
40413 + state information on the file here... */
40414 + ufile_ptr where;
40415 +
40416 + /* ... and here: (``once'' means at least once). */
40417 + bfd_boolean opened_once;
40418 +
40419 + /* Set if we have a locally maintained mtime value, rather than
40420 + getting it from the file each time. */
40421 + bfd_boolean mtime_set;
40422 +
40423 + /* File modified time, if mtime_set is TRUE. */
40424 + long mtime;
40425 +
40426 + /* Reserved for an unimplemented file locking extension. */
40427 + int ifd;
40428 +
40429 + /* The format which belongs to the BFD. (object, core, etc.) */
40430 + bfd_format format;
40431 +
40432 + /* The direction with which the BFD was opened. */
40433 + enum bfd_direction
40434 + {
40435 + no_direction = 0,
40436 + read_direction = 1,
40437 + write_direction = 2,
40438 + both_direction = 3
40439 + }
40440 + direction;
40441 +
40442 + /* Format_specific flags. */
40443 + flagword flags;
40444 +
40445 + /* Currently my_archive is tested before adding origin to
40446 + anything. I believe that this can become always an add of
40447 + origin, with origin set to 0 for non archive files. */
40448 + ufile_ptr origin;
40449 +
40450 + /* Remember when output has begun, to stop strange things
40451 + from happening. */
40452 + bfd_boolean output_has_begun;
40453 +
40454 + /* A hash table for section names. */
40455 + struct bfd_hash_table section_htab;
40456 +
40457 + /* Pointer to linked list of sections. */
40458 + struct bfd_section *sections;
40459 +
40460 + /* The last section on the section list. */
40461 + struct bfd_section *section_last;
40462 +
40463 + /* The number of sections. */
40464 + unsigned int section_count;
40465 +
40466 + /* Stuff only useful for object files:
40467 + The start address. */
40468 + bfd_vma start_address;
40469 +
40470 + /* Used for input and output. */
40471 + unsigned int symcount;
40472 +
40473 + /* Symbol table for output BFD (with symcount entries). */
40474 + struct bfd_symbol **outsymbols;
40475 +
40476 + /* Used for slurped dynamic symbol tables. */
40477 + unsigned int dynsymcount;
40478 +
40479 + /* Pointer to structure which contains architecture information. */
40480 + const struct bfd_arch_info *arch_info;
40481 +
40482 + /* Flag set if symbols from this BFD should not be exported. */
40483 + bfd_boolean no_export;
40484 +
40485 + /* Stuff only useful for archives. */
40486 + void *arelt_data;
40487 + struct bfd *my_archive; /* The containing archive BFD. */
40488 + struct bfd *archive_next; /* The next BFD in the archive. */
40489 + struct bfd *archive_head; /* The first BFD in the archive. */
40490 + bfd_boolean has_armap;
40491 +
40492 + /* A chain of BFD structures involved in a link. */
40493 + struct bfd *link_next;
40494 +
40495 + /* A field used by _bfd_generic_link_add_archive_symbols. This will
40496 + be used only for archive elements. */
40497 + int archive_pass;
40498 +
40499 + /* Used by the back end to hold private data. */
40500 + union
40501 + {
40502 + struct aout_data_struct *aout_data;
40503 + struct artdata *aout_ar_data;
40504 + struct _oasys_data *oasys_obj_data;
40505 + struct _oasys_ar_data *oasys_ar_data;
40506 + struct coff_tdata *coff_obj_data;
40507 + struct pe_tdata *pe_obj_data;
40508 + struct xcoff_tdata *xcoff_obj_data;
40509 + struct ecoff_tdata *ecoff_obj_data;
40510 + struct ieee_data_struct *ieee_data;
40511 + struct ieee_ar_data_struct *ieee_ar_data;
40512 + struct srec_data_struct *srec_data;
40513 + struct ihex_data_struct *ihex_data;
40514 + struct tekhex_data_struct *tekhex_data;
40515 + struct elf_obj_tdata *elf_obj_data;
40516 + struct nlm_obj_tdata *nlm_obj_data;
40517 + struct bout_data_struct *bout_data;
40518 + struct mmo_data_struct *mmo_data;
40519 + struct sun_core_struct *sun_core_data;
40520 + struct sco5_core_struct *sco5_core_data;
40521 + struct trad_core_struct *trad_core_data;
40522 + struct som_data_struct *som_data;
40523 + struct hpux_core_struct *hpux_core_data;
40524 + struct hppabsd_core_struct *hppabsd_core_data;
40525 + struct sgi_core_struct *sgi_core_data;
40526 + struct lynx_core_struct *lynx_core_data;
40527 + struct osf_core_struct *osf_core_data;
40528 + struct cisco_core_struct *cisco_core_data;
40529 + struct versados_data_struct *versados_data;
40530 + struct netbsd_core_struct *netbsd_core_data;
40531 + struct mach_o_data_struct *mach_o_data;
40532 + struct mach_o_fat_data_struct *mach_o_fat_data;
40533 + struct bfd_pef_data_struct *pef_data;
40534 + struct bfd_pef_xlib_data_struct *pef_xlib_data;
40535 + struct bfd_sym_data_struct *sym_data;
40536 + void *any;
40537 + }
40538 + tdata;
40539 +
40540 + /* Used by the application to hold private data. */
40541 + void *usrdata;
40542 +
40543 + /* Where all the allocated stuff under this BFD goes. This is a
40544 + struct objalloc *, but we use void * to avoid requiring the inclusion
40545 + of objalloc.h. */
40546 + void *memory;
40547 +};
40548 +
40549 +typedef enum bfd_error
40550 +{
40551 + bfd_error_no_error = 0,
40552 + bfd_error_system_call,
40553 + bfd_error_invalid_target,
40554 + bfd_error_wrong_format,
40555 + bfd_error_wrong_object_format,
40556 + bfd_error_invalid_operation,
40557 + bfd_error_no_memory,
40558 + bfd_error_no_symbols,
40559 + bfd_error_no_armap,
40560 + bfd_error_no_more_archived_files,
40561 + bfd_error_malformed_archive,
40562 + bfd_error_file_not_recognized,
40563 + bfd_error_file_ambiguously_recognized,
40564 + bfd_error_no_contents,
40565 + bfd_error_nonrepresentable_section,
40566 + bfd_error_no_debug_section,
40567 + bfd_error_bad_value,
40568 + bfd_error_file_truncated,
40569 + bfd_error_file_too_big,
40570 + bfd_error_on_input,
40571 + bfd_error_invalid_error_code
40572 +}
40573 +bfd_error_type;
40574 +
40575 +bfd_error_type bfd_get_error (void);
40576 +
40577 +void bfd_set_error (bfd_error_type error_tag, ...);
40578 +
40579 +const char *bfd_errmsg (bfd_error_type error_tag);
40580 +
40581 +void bfd_perror (const char *message);
40582 +
40583 +typedef void (*bfd_error_handler_type) (const char *, ...);
40584 +
40585 +bfd_error_handler_type bfd_set_error_handler (bfd_error_handler_type);
40586 +
40587 +void bfd_set_error_program_name (const char *);
40588 +
40589 +bfd_error_handler_type bfd_get_error_handler (void);
40590 +
40591 +long bfd_get_reloc_upper_bound (bfd *abfd, asection *sect);
40592 +
40593 +long bfd_canonicalize_reloc
40594 + (bfd *abfd, asection *sec, arelent **loc, asymbol **syms);
40595 +
40596 +void bfd_set_reloc
40597 + (bfd *abfd, asection *sec, arelent **rel, unsigned int count);
40598 +
40599 +bfd_boolean bfd_set_file_flags (bfd *abfd, flagword flags);
40600 +
40601 +int bfd_get_arch_size (bfd *abfd);
40602 +
40603 +int bfd_get_sign_extend_vma (bfd *abfd);
40604 +
40605 +bfd_boolean bfd_set_start_address (bfd *abfd, bfd_vma vma);
40606 +
40607 +unsigned int bfd_get_gp_size (bfd *abfd);
40608 +
40609 +void bfd_set_gp_size (bfd *abfd, unsigned int i);
40610 +
40611 +bfd_vma bfd_scan_vma (const char *string, const char **end, int base);
40612 +
40613 +bfd_boolean bfd_copy_private_header_data (bfd *ibfd, bfd *obfd);
40614 +
40615 +#define bfd_copy_private_header_data(ibfd, obfd) \
40616 + BFD_SEND (obfd, _bfd_copy_private_header_data, \
40617 + (ibfd, obfd))
40618 +bfd_boolean bfd_copy_private_bfd_data (bfd *ibfd, bfd *obfd);
40619 +
40620 +#define bfd_copy_private_bfd_data(ibfd, obfd) \
40621 + BFD_SEND (obfd, _bfd_copy_private_bfd_data, \
40622 + (ibfd, obfd))
40623 +bfd_boolean bfd_merge_private_bfd_data (bfd *ibfd, bfd *obfd);
40624 +
40625 +#define bfd_merge_private_bfd_data(ibfd, obfd) \
40626 + BFD_SEND (obfd, _bfd_merge_private_bfd_data, \
40627 + (ibfd, obfd))
40628 +bfd_boolean bfd_set_private_flags (bfd *abfd, flagword flags);
40629 +
40630 +#define bfd_set_private_flags(abfd, flags) \
40631 + BFD_SEND (abfd, _bfd_set_private_flags, (abfd, flags))
40632 +#define bfd_sizeof_headers(abfd, info) \
40633 + BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, info))
40634 +
40635 +#define bfd_find_nearest_line(abfd, sec, syms, off, file, func, line) \
40636 + BFD_SEND (abfd, _bfd_find_nearest_line, \
40637 + (abfd, sec, syms, off, file, func, line))
40638 +
40639 +#define bfd_find_line(abfd, syms, sym, file, line) \
40640 + BFD_SEND (abfd, _bfd_find_line, \
40641 + (abfd, syms, sym, file, line))
40642 +
40643 +#define bfd_find_inliner_info(abfd, file, func, line) \
40644 + BFD_SEND (abfd, _bfd_find_inliner_info, \
40645 + (abfd, file, func, line))
40646 +
40647 +#define bfd_debug_info_start(abfd) \
40648 + BFD_SEND (abfd, _bfd_debug_info_start, (abfd))
40649 +
40650 +#define bfd_debug_info_end(abfd) \
40651 + BFD_SEND (abfd, _bfd_debug_info_end, (abfd))
40652 +
40653 +#define bfd_debug_info_accumulate(abfd, section) \
40654 + BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section))
40655 +
40656 +#define bfd_stat_arch_elt(abfd, stat) \
40657 + BFD_SEND (abfd, _bfd_stat_arch_elt,(abfd, stat))
40658 +
40659 +#define bfd_update_armap_timestamp(abfd) \
40660 + BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd))
40661 +
40662 +#define bfd_set_arch_mach(abfd, arch, mach)\
40663 + BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach))
40664 +
40665 +#define bfd_relax_section(abfd, section, link_info, again) \
40666 + BFD_SEND (abfd, _bfd_relax_section, (abfd, section, link_info, again))
40667 +
40668 +#define bfd_gc_sections(abfd, link_info) \
40669 + BFD_SEND (abfd, _bfd_gc_sections, (abfd, link_info))
40670 +
40671 +#define bfd_merge_sections(abfd, link_info) \
40672 + BFD_SEND (abfd, _bfd_merge_sections, (abfd, link_info))
40673 +
40674 +#define bfd_is_group_section(abfd, sec) \
40675 + BFD_SEND (abfd, _bfd_is_group_section, (abfd, sec))
40676 +
40677 +#define bfd_discard_group(abfd, sec) \
40678 + BFD_SEND (abfd, _bfd_discard_group, (abfd, sec))
40679 +
40680 +#define bfd_link_hash_table_create(abfd) \
40681 + BFD_SEND (abfd, _bfd_link_hash_table_create, (abfd))
40682 +
40683 +#define bfd_link_hash_table_free(abfd, hash) \
40684 + BFD_SEND (abfd, _bfd_link_hash_table_free, (hash))
40685 +
40686 +#define bfd_link_add_symbols(abfd, info) \
40687 + BFD_SEND (abfd, _bfd_link_add_symbols, (abfd, info))
40688 +
40689 +#define bfd_link_just_syms(abfd, sec, info) \
40690 + BFD_SEND (abfd, _bfd_link_just_syms, (sec, info))
40691 +
40692 +#define bfd_final_link(abfd, info) \
40693 + BFD_SEND (abfd, _bfd_final_link, (abfd, info))
40694 +
40695 +#define bfd_free_cached_info(abfd) \
40696 + BFD_SEND (abfd, _bfd_free_cached_info, (abfd))
40697 +
40698 +#define bfd_get_dynamic_symtab_upper_bound(abfd) \
40699 + BFD_SEND (abfd, _bfd_get_dynamic_symtab_upper_bound, (abfd))
40700 +
40701 +#define bfd_print_private_bfd_data(abfd, file)\
40702 + BFD_SEND (abfd, _bfd_print_private_bfd_data, (abfd, file))
40703 +
40704 +#define bfd_canonicalize_dynamic_symtab(abfd, asymbols) \
40705 + BFD_SEND (abfd, _bfd_canonicalize_dynamic_symtab, (abfd, asymbols))
40706 +
40707 +#define bfd_get_synthetic_symtab(abfd, count, syms, dyncount, dynsyms, ret) \
40708 + BFD_SEND (abfd, _bfd_get_synthetic_symtab, (abfd, count, syms, \
40709 + dyncount, dynsyms, ret))
40710 +
40711 +#define bfd_get_dynamic_reloc_upper_bound(abfd) \
40712 + BFD_SEND (abfd, _bfd_get_dynamic_reloc_upper_bound, (abfd))
40713 +
40714 +#define bfd_canonicalize_dynamic_reloc(abfd, arels, asyms) \
40715 + BFD_SEND (abfd, _bfd_canonicalize_dynamic_reloc, (abfd, arels, asyms))
40716 +
40717 +extern bfd_byte *bfd_get_relocated_section_contents
40718 + (bfd *, struct bfd_link_info *, struct bfd_link_order *, bfd_byte *,
40719 + bfd_boolean, asymbol **);
40720 +
40721 +bfd_boolean bfd_alt_mach_code (bfd *abfd, int alternative);
40722 +
40723 +struct bfd_preserve
40724 +{
40725 + void *marker;
40726 + void *tdata;
40727 + flagword flags;
40728 + const struct bfd_arch_info *arch_info;
40729 + struct bfd_section *sections;
40730 + struct bfd_section *section_last;
40731 + unsigned int section_count;
40732 + struct bfd_hash_table section_htab;
40733 +};
40734 +
40735 +bfd_boolean bfd_preserve_save (bfd *, struct bfd_preserve *);
40736 +
40737 +void bfd_preserve_restore (bfd *, struct bfd_preserve *);
40738 +
40739 +void bfd_preserve_finish (bfd *, struct bfd_preserve *);
40740 +
40741 +bfd_vma bfd_emul_get_maxpagesize (const char *);
40742 +
40743 +void bfd_emul_set_maxpagesize (const char *, bfd_vma);
40744 +
40745 +bfd_vma bfd_emul_get_commonpagesize (const char *);
40746 +
40747 +void bfd_emul_set_commonpagesize (const char *, bfd_vma);
40748 +
40749 +char *bfd_demangle (bfd *, const char *, int);
40750 +
40751 +/* Extracted from archive.c. */
40752 +symindex bfd_get_next_mapent
40753 + (bfd *abfd, symindex previous, carsym **sym);
40754 +
40755 +bfd_boolean bfd_set_archive_head (bfd *output, bfd *new_head);
40756 +
40757 +bfd *bfd_openr_next_archived_file (bfd *archive, bfd *previous);
40758 +
40759 +/* Extracted from corefile.c. */
40760 +const char *bfd_core_file_failing_command (bfd *abfd);
40761 +
40762 +int bfd_core_file_failing_signal (bfd *abfd);
40763 +
40764 +bfd_boolean core_file_matches_executable_p
40765 + (bfd *core_bfd, bfd *exec_bfd);
40766 +
40767 +bfd_boolean generic_core_file_matches_executable_p
40768 + (bfd *core_bfd, bfd *exec_bfd);
40769 +
40770 +/* Extracted from targets.c. */
40771 +#define BFD_SEND(bfd, message, arglist) \
40772 + ((*((bfd)->xvec->message)) arglist)
40773 +
40774 +#ifdef DEBUG_BFD_SEND
40775 +#undef BFD_SEND
40776 +#define BFD_SEND(bfd, message, arglist) \
40777 + (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
40778 + ((*((bfd)->xvec->message)) arglist) : \
40779 + (bfd_assert (__FILE__,__LINE__), NULL))
40780 +#endif
40781 +#define BFD_SEND_FMT(bfd, message, arglist) \
40782 + (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist)
40783 +
40784 +#ifdef DEBUG_BFD_SEND
40785 +#undef BFD_SEND_FMT
40786 +#define BFD_SEND_FMT(bfd, message, arglist) \
40787 + (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
40788 + (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist) : \
40789 + (bfd_assert (__FILE__,__LINE__), NULL))
40790 +#endif
40791 +
40792 +enum bfd_flavour
40793 +{
40794 + bfd_target_unknown_flavour,
40795 + bfd_target_aout_flavour,
40796 + bfd_target_coff_flavour,
40797 + bfd_target_ecoff_flavour,
40798 + bfd_target_xcoff_flavour,
40799 + bfd_target_elf_flavour,
40800 + bfd_target_ieee_flavour,
40801 + bfd_target_nlm_flavour,
40802 + bfd_target_oasys_flavour,
40803 + bfd_target_tekhex_flavour,
40804 + bfd_target_srec_flavour,
40805 + bfd_target_ihex_flavour,
40806 + bfd_target_som_flavour,
40807 + bfd_target_os9k_flavour,
40808 + bfd_target_versados_flavour,
40809 + bfd_target_msdos_flavour,
40810 + bfd_target_ovax_flavour,
40811 + bfd_target_evax_flavour,
40812 + bfd_target_mmo_flavour,
40813 + bfd_target_mach_o_flavour,
40814 + bfd_target_pef_flavour,
40815 + bfd_target_pef_xlib_flavour,
40816 + bfd_target_sym_flavour
40817 +};
40818 +
40819 +enum bfd_endian { BFD_ENDIAN_BIG, BFD_ENDIAN_LITTLE, BFD_ENDIAN_UNKNOWN };
40820 +
40821 +/* Forward declaration. */
40822 +typedef struct bfd_link_info _bfd_link_info;
40823 +
40824 +typedef struct bfd_target
40825 +{
40826 + /* Identifies the kind of target, e.g., SunOS4, Ultrix, etc. */
40827 + char *name;
40828 +
40829 + /* The "flavour" of a back end is a general indication about
40830 + the contents of a file. */
40831 + enum bfd_flavour flavour;
40832 +
40833 + /* The order of bytes within the data area of a file. */
40834 + enum bfd_endian byteorder;
40835 +
40836 + /* The order of bytes within the header parts of a file. */
40837 + enum bfd_endian header_byteorder;
40838 +
40839 + /* A mask of all the flags which an executable may have set -
40840 + from the set <<BFD_NO_FLAGS>>, <<HAS_RELOC>>, ...<<D_PAGED>>. */
40841 + flagword object_flags;
40842 +
40843 + /* A mask of all the flags which a section may have set - from
40844 + the set <<SEC_NO_FLAGS>>, <<SEC_ALLOC>>, ...<<SET_NEVER_LOAD>>. */
40845 + flagword section_flags;
40846 +
40847 + /* The character normally found at the front of a symbol.
40848 + (if any), perhaps `_'. */
40849 + char symbol_leading_char;
40850 +
40851 + /* The pad character for file names within an archive header. */
40852 + char ar_pad_char;
40853 +
40854 + /* The maximum number of characters in an archive header. */
40855 + unsigned short ar_max_namelen;
40856 +
40857 + /* Entries for byte swapping for data. These are different from the
40858 + other entry points, since they don't take a BFD as the first argument.
40859 + Certain other handlers could do the same. */
40860 + bfd_uint64_t (*bfd_getx64) (const void *);
40861 + bfd_int64_t (*bfd_getx_signed_64) (const void *);
40862 + void (*bfd_putx64) (bfd_uint64_t, void *);
40863 + bfd_vma (*bfd_getx32) (const void *);
40864 + bfd_signed_vma (*bfd_getx_signed_32) (const void *);
40865 + void (*bfd_putx32) (bfd_vma, void *);
40866 + bfd_vma (*bfd_getx16) (const void *);
40867 + bfd_signed_vma (*bfd_getx_signed_16) (const void *);
40868 + void (*bfd_putx16) (bfd_vma, void *);
40869 +
40870 + /* Byte swapping for the headers. */
40871 + bfd_uint64_t (*bfd_h_getx64) (const void *);
40872 + bfd_int64_t (*bfd_h_getx_signed_64) (const void *);
40873 + void (*bfd_h_putx64) (bfd_uint64_t, void *);
40874 + bfd_vma (*bfd_h_getx32) (const void *);
40875 + bfd_signed_vma (*bfd_h_getx_signed_32) (const void *);
40876 + void (*bfd_h_putx32) (bfd_vma, void *);
40877 + bfd_vma (*bfd_h_getx16) (const void *);
40878 + bfd_signed_vma (*bfd_h_getx_signed_16) (const void *);
40879 + void (*bfd_h_putx16) (bfd_vma, void *);
40880 +
40881 + /* Format dependent routines: these are vectors of entry points
40882 + within the target vector structure, one for each format to check. */
40883 +
40884 + /* Check the format of a file being read. Return a <<bfd_target *>> or zero. */
40885 + const struct bfd_target *(*_bfd_check_format[bfd_type_end]) (bfd *);
40886 +
40887 + /* Set the format of a file being written. */
40888 + bfd_boolean (*_bfd_set_format[bfd_type_end]) (bfd *);
40889 +
40890 + /* Write cached information into a file being written, at <<bfd_close>>. */
40891 + bfd_boolean (*_bfd_write_contents[bfd_type_end]) (bfd *);
40892 +
40893 +
40894 + /* Generic entry points. */
40895 +#define BFD_JUMP_TABLE_GENERIC(NAME) \
40896 + NAME##_close_and_cleanup, \
40897 + NAME##_bfd_free_cached_info, \
40898 + NAME##_new_section_hook, \
40899 + NAME##_get_section_contents, \
40900 + NAME##_get_section_contents_in_window
40901 +
40902 + /* Called when the BFD is being closed to do any necessary cleanup. */
40903 + bfd_boolean (*_close_and_cleanup) (bfd *);
40904 + /* Ask the BFD to free all cached information. */
40905 + bfd_boolean (*_bfd_free_cached_info) (bfd *);
40906 + /* Called when a new section is created. */
40907 + bfd_boolean (*_new_section_hook) (bfd *, sec_ptr);
40908 + /* Read the contents of a section. */
40909 + bfd_boolean (*_bfd_get_section_contents)
40910 + (bfd *, sec_ptr, void *, file_ptr, bfd_size_type);
40911 + bfd_boolean (*_bfd_get_section_contents_in_window)
40912 + (bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type);
40913 +
40914 + /* Entry points to copy private data. */
40915 +#define BFD_JUMP_TABLE_COPY(NAME) \
40916 + NAME##_bfd_copy_private_bfd_data, \
40917 + NAME##_bfd_merge_private_bfd_data, \
40918 + _bfd_generic_init_private_section_data, \
40919 + NAME##_bfd_copy_private_section_data, \
40920 + NAME##_bfd_copy_private_symbol_data, \
40921 + NAME##_bfd_copy_private_header_data, \
40922 + NAME##_bfd_set_private_flags, \
40923 + NAME##_bfd_print_private_bfd_data
40924 +
40925 + /* Called to copy BFD general private data from one object file
40926 + to another. */
40927 + bfd_boolean (*_bfd_copy_private_bfd_data) (bfd *, bfd *);
40928 + /* Called to merge BFD general private data from one object file
40929 + to a common output file when linking. */
40930 + bfd_boolean (*_bfd_merge_private_bfd_data) (bfd *, bfd *);
40931 + /* Called to initialize BFD private section data from one object file
40932 + to another. */
40933 +#define bfd_init_private_section_data(ibfd, isec, obfd, osec, link_info) \
40934 + BFD_SEND (obfd, _bfd_init_private_section_data, (ibfd, isec, obfd, osec, link_info))
40935 + bfd_boolean (*_bfd_init_private_section_data)
40936 + (bfd *, sec_ptr, bfd *, sec_ptr, struct bfd_link_info *);
40937 + /* Called to copy BFD private section data from one object file
40938 + to another. */
40939 + bfd_boolean (*_bfd_copy_private_section_data)
40940 + (bfd *, sec_ptr, bfd *, sec_ptr);
40941 + /* Called to copy BFD private symbol data from one symbol
40942 + to another. */
40943 + bfd_boolean (*_bfd_copy_private_symbol_data)
40944 + (bfd *, asymbol *, bfd *, asymbol *);
40945 + /* Called to copy BFD private header data from one object file
40946 + to another. */
40947 + bfd_boolean (*_bfd_copy_private_header_data)
40948 + (bfd *, bfd *);
40949 + /* Called to set private backend flags. */
40950 + bfd_boolean (*_bfd_set_private_flags) (bfd *, flagword);
40951 +
40952 + /* Called to print private BFD data. */
40953 + bfd_boolean (*_bfd_print_private_bfd_data) (bfd *, void *);
40954 +
40955 + /* Core file entry points. */
40956 +#define BFD_JUMP_TABLE_CORE(NAME) \
40957 + NAME##_core_file_failing_command, \
40958 + NAME##_core_file_failing_signal, \
40959 + NAME##_core_file_matches_executable_p
40960 +
40961 + char * (*_core_file_failing_command) (bfd *);
40962 + int (*_core_file_failing_signal) (bfd *);
40963 + bfd_boolean (*_core_file_matches_executable_p) (bfd *, bfd *);
40964 +
40965 + /* Archive entry points. */
40966 +#define BFD_JUMP_TABLE_ARCHIVE(NAME) \
40967 + NAME##_slurp_armap, \
40968 + NAME##_slurp_extended_name_table, \
40969 + NAME##_construct_extended_name_table, \
40970 + NAME##_truncate_arname, \
40971 + NAME##_write_armap, \
40972 + NAME##_read_ar_hdr, \
40973 + NAME##_openr_next_archived_file, \
40974 + NAME##_get_elt_at_index, \
40975 + NAME##_generic_stat_arch_elt, \
40976 + NAME##_update_armap_timestamp
40977 +
40978 + bfd_boolean (*_bfd_slurp_armap) (bfd *);
40979 + bfd_boolean (*_bfd_slurp_extended_name_table) (bfd *);
40980 + bfd_boolean (*_bfd_construct_extended_name_table)
40981 + (bfd *, char **, bfd_size_type *, const char **);
40982 + void (*_bfd_truncate_arname) (bfd *, const char *, char *);
40983 + bfd_boolean (*write_armap)
40984 + (bfd *, unsigned int, struct orl *, unsigned int, int);
40985 + void * (*_bfd_read_ar_hdr_fn) (bfd *);
40986 + bfd * (*openr_next_archived_file) (bfd *, bfd *);
40987 +#define bfd_get_elt_at_index(b,i) BFD_SEND (b, _bfd_get_elt_at_index, (b,i))
40988 + bfd * (*_bfd_get_elt_at_index) (bfd *, symindex);
40989 + int (*_bfd_stat_arch_elt) (bfd *, struct stat *);
40990 + bfd_boolean (*_bfd_update_armap_timestamp) (bfd *);
40991 +
40992 + /* Entry points used for symbols. */
40993 +#define BFD_JUMP_TABLE_SYMBOLS(NAME) \
40994 + NAME##_get_symtab_upper_bound, \
40995 + NAME##_canonicalize_symtab, \
40996 + NAME##_make_empty_symbol, \
40997 + NAME##_print_symbol, \
40998 + NAME##_get_symbol_info, \
40999 + NAME##_bfd_is_local_label_name, \
41000 + NAME##_bfd_is_target_special_symbol, \
41001 + NAME##_get_lineno, \
41002 + NAME##_find_nearest_line, \
41003 + _bfd_generic_find_line, \
41004 + NAME##_find_inliner_info, \
41005 + NAME##_bfd_make_debug_symbol, \
41006 + NAME##_read_minisymbols, \
41007 + NAME##_minisymbol_to_symbol
41008 +
41009 + long (*_bfd_get_symtab_upper_bound) (bfd *);
41010 + long (*_bfd_canonicalize_symtab)
41011 + (bfd *, struct bfd_symbol **);
41012 + struct bfd_symbol *
41013 + (*_bfd_make_empty_symbol) (bfd *);
41014 + void (*_bfd_print_symbol)
41015 + (bfd *, void *, struct bfd_symbol *, bfd_print_symbol_type);
41016 +#define bfd_print_symbol(b,p,s,e) BFD_SEND (b, _bfd_print_symbol, (b,p,s,e))
41017 + void (*_bfd_get_symbol_info)
41018 + (bfd *, struct bfd_symbol *, symbol_info *);
41019 +#define bfd_get_symbol_info(b,p,e) BFD_SEND (b, _bfd_get_symbol_info, (b,p,e))
41020 + bfd_boolean (*_bfd_is_local_label_name) (bfd *, const char *);
41021 + bfd_boolean (*_bfd_is_target_special_symbol) (bfd *, asymbol *);
41022 + alent * (*_get_lineno) (bfd *, struct bfd_symbol *);
41023 + bfd_boolean (*_bfd_find_nearest_line)
41024 + (bfd *, struct bfd_section *, struct bfd_symbol **, bfd_vma,
41025 + const char **, const char **, unsigned int *);
41026 + bfd_boolean (*_bfd_find_line)
41027 + (bfd *, struct bfd_symbol **, struct bfd_symbol *,
41028 + const char **, unsigned int *);
41029 + bfd_boolean (*_bfd_find_inliner_info)
41030 + (bfd *, const char **, const char **, unsigned int *);
41031 + /* Back-door to allow format-aware applications to create debug symbols
41032 + while using BFD for everything else. Currently used by the assembler
41033 + when creating COFF files. */
41034 + asymbol * (*_bfd_make_debug_symbol)
41035 + (bfd *, void *, unsigned long size);
41036 +#define bfd_read_minisymbols(b, d, m, s) \
41037 + BFD_SEND (b, _read_minisymbols, (b, d, m, s))
41038 + long (*_read_minisymbols)
41039 + (bfd *, bfd_boolean, void **, unsigned int *);
41040 +#define bfd_minisymbol_to_symbol(b, d, m, f) \
41041 + BFD_SEND (b, _minisymbol_to_symbol, (b, d, m, f))
41042 + asymbol * (*_minisymbol_to_symbol)
41043 + (bfd *, bfd_boolean, const void *, asymbol *);
41044 +
41045 + /* Routines for relocs. */
41046 +#define BFD_JUMP_TABLE_RELOCS(NAME) \
41047 + NAME##_get_reloc_upper_bound, \
41048 + NAME##_canonicalize_reloc, \
41049 + NAME##_bfd_reloc_type_lookup, \
41050 + NAME##_bfd_reloc_name_lookup
41051 +
41052 + long (*_get_reloc_upper_bound) (bfd *, sec_ptr);
41053 + long (*_bfd_canonicalize_reloc)
41054 + (bfd *, sec_ptr, arelent **, struct bfd_symbol **);
41055 + /* See documentation on reloc types. */
41056 + reloc_howto_type *
41057 + (*reloc_type_lookup) (bfd *, bfd_reloc_code_real_type);
41058 + reloc_howto_type *
41059 + (*reloc_name_lookup) (bfd *, const char *);
41060 +
41061 +
41062 + /* Routines used when writing an object file. */
41063 +#define BFD_JUMP_TABLE_WRITE(NAME) \
41064 + NAME##_set_arch_mach, \
41065 + NAME##_set_section_contents
41066 +
41067 + bfd_boolean (*_bfd_set_arch_mach)
41068 + (bfd *, enum bfd_architecture, unsigned long);
41069 + bfd_boolean (*_bfd_set_section_contents)
41070 + (bfd *, sec_ptr, const void *, file_ptr, bfd_size_type);
41071 +
41072 + /* Routines used by the linker. */
41073 +#define BFD_JUMP_TABLE_LINK(NAME) \
41074 + NAME##_sizeof_headers, \
41075 + NAME##_bfd_get_relocated_section_contents, \
41076 + NAME##_bfd_relax_section, \
41077 + NAME##_bfd_link_hash_table_create, \
41078 + NAME##_bfd_link_hash_table_free, \
41079 + NAME##_bfd_link_add_symbols, \
41080 + NAME##_bfd_link_just_syms, \
41081 + NAME##_bfd_final_link, \
41082 + NAME##_bfd_link_split_section, \
41083 + NAME##_bfd_gc_sections, \
41084 + NAME##_bfd_merge_sections, \
41085 + NAME##_bfd_is_group_section, \
41086 + NAME##_bfd_discard_group, \
41087 + NAME##_section_already_linked \
41088 +
41089 + int (*_bfd_sizeof_headers) (bfd *, struct bfd_link_info *);
41090 + bfd_byte * (*_bfd_get_relocated_section_contents)
41091 + (bfd *, struct bfd_link_info *, struct bfd_link_order *,
41092 + bfd_byte *, bfd_boolean, struct bfd_symbol **);
41093 +
41094 + bfd_boolean (*_bfd_relax_section)
41095 + (bfd *, struct bfd_section *, struct bfd_link_info *, bfd_boolean *);
41096 +
41097 + /* Create a hash table for the linker. Different backends store
41098 + different information in this table. */
41099 + struct bfd_link_hash_table *
41100 + (*_bfd_link_hash_table_create) (bfd *);
41101 +
41102 + /* Release the memory associated with the linker hash table. */
41103 + void (*_bfd_link_hash_table_free) (struct bfd_link_hash_table *);
41104 +
41105 + /* Add symbols from this object file into the hash table. */
41106 + bfd_boolean (*_bfd_link_add_symbols) (bfd *, struct bfd_link_info *);
41107 +
41108 + /* Indicate that we are only retrieving symbol values from this section. */
41109 + void (*_bfd_link_just_syms) (asection *, struct bfd_link_info *);
41110 +
41111 + /* Do a link based on the link_order structures attached to each
41112 + section of the BFD. */
41113 + bfd_boolean (*_bfd_final_link) (bfd *, struct bfd_link_info *);
41114 +
41115 + /* Should this section be split up into smaller pieces during linking. */
41116 + bfd_boolean (*_bfd_link_split_section) (bfd *, struct bfd_section *);
41117 +
41118 + /* Remove sections that are not referenced from the output. */
41119 + bfd_boolean (*_bfd_gc_sections) (bfd *, struct bfd_link_info *);
41120 +
41121 + /* Attempt to merge SEC_MERGE sections. */
41122 + bfd_boolean (*_bfd_merge_sections) (bfd *, struct bfd_link_info *);
41123 +
41124 + /* Is this section a member of a group? */
41125 + bfd_boolean (*_bfd_is_group_section) (bfd *, const struct bfd_section *);
41126 +
41127 + /* Discard members of a group. */
41128 + bfd_boolean (*_bfd_discard_group) (bfd *, struct bfd_section *);
41129 +
41130 + /* Check if SEC has been already linked during a reloceatable or
41131 + final link. */
41132 + void (*_section_already_linked) (bfd *, struct bfd_section *,
41133 + struct bfd_link_info *);
41134 +
41135 + /* Routines to handle dynamic symbols and relocs. */
41136 +#define BFD_JUMP_TABLE_DYNAMIC(NAME) \
41137 + NAME##_get_dynamic_symtab_upper_bound, \
41138 + NAME##_canonicalize_dynamic_symtab, \
41139 + NAME##_get_synthetic_symtab, \
41140 + NAME##_get_dynamic_reloc_upper_bound, \
41141 + NAME##_canonicalize_dynamic_reloc
41142 +
41143 + /* Get the amount of memory required to hold the dynamic symbols. */
41144 + long (*_bfd_get_dynamic_symtab_upper_bound) (bfd *);
41145 + /* Read in the dynamic symbols. */
41146 + long (*_bfd_canonicalize_dynamic_symtab)
41147 + (bfd *, struct bfd_symbol **);
41148 + /* Create synthetized symbols. */
41149 + long (*_bfd_get_synthetic_symtab)
41150 + (bfd *, long, struct bfd_symbol **, long, struct bfd_symbol **,
41151 + struct bfd_symbol **);
41152 + /* Get the amount of memory required to hold the dynamic relocs. */
41153 + long (*_bfd_get_dynamic_reloc_upper_bound) (bfd *);
41154 + /* Read in the dynamic relocs. */
41155 + long (*_bfd_canonicalize_dynamic_reloc)
41156 + (bfd *, arelent **, struct bfd_symbol **);
41157 +
41158 + /* Opposite endian version of this target. */
41159 + const struct bfd_target * alternative_target;
41160 +
41161 + /* Data for use by back-end routines, which isn't
41162 + generic enough to belong in this structure. */
41163 + const void *backend_data;
41164 +
41165 +} bfd_target;
41166 +
41167 +bfd_boolean bfd_set_default_target (const char *name);
41168 +
41169 +const bfd_target *bfd_find_target (const char *target_name, bfd *abfd);
41170 +
41171 +const char ** bfd_target_list (void);
41172 +
41173 +const bfd_target *bfd_search_for_target
41174 + (int (*search_func) (const bfd_target *, void *),
41175 + void *);
41176 +
41177 +/* Extracted from format.c. */
41178 +bfd_boolean bfd_check_format (bfd *abfd, bfd_format format);
41179 +
41180 +bfd_boolean bfd_check_format_matches
41181 + (bfd *abfd, bfd_format format, char ***matching);
41182 +
41183 +bfd_boolean bfd_set_format (bfd *abfd, bfd_format format);
41184 +
41185 +const char *bfd_format_string (bfd_format format);
41186 +
41187 +/* Extracted from linker.c. */
41188 +bfd_boolean bfd_link_split_section (bfd *abfd, asection *sec);
41189 +
41190 +#define bfd_link_split_section(abfd, sec) \
41191 + BFD_SEND (abfd, _bfd_link_split_section, (abfd, sec))
41192 +
41193 +void bfd_section_already_linked (bfd *abfd, asection *sec,
41194 + struct bfd_link_info *info);
41195 +
41196 +#define bfd_section_already_linked(abfd, sec, info) \
41197 + BFD_SEND (abfd, _section_already_linked, (abfd, sec, info))
41198 +
41199 +/* Extracted from simple.c. */
41200 +bfd_byte *bfd_simple_get_relocated_section_contents
41201 + (bfd *abfd, asection *sec, bfd_byte *outbuf, asymbol **symbol_table);
41202 +
41203 +#ifdef __cplusplus
41204 +}
41205 +#endif
41206 +#endif
41207 --- /dev/null
41208 +++ b/bfd/doc/libbfd.h
41209 @@ -0,0 +1,2074 @@
41210 +/* DO NOT EDIT! -*- buffer-read-only: t -*- This file is automatically
41211 + generated from "libbfd-in.h", "init.c", "libbfd.c", "bfdio.c",
41212 + "bfdwin.c", "cache.c", "reloc.c", "archures.c" and "elf.c".
41213 + Run "make headers" in your build bfd/ to regenerate. */
41214 +
41215 +/* libbfd.h -- Declarations used by bfd library *implementation*.
41216 + (This include file is not for users of the library.)
41217 +
41218 + Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
41219 + 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
41220 + Free Software Foundation, Inc.
41221 +
41222 + Written by Cygnus Support.
41223 +
41224 + This file is part of BFD, the Binary File Descriptor library.
41225 +
41226 + This program is free software; you can redistribute it and/or modify
41227 + it under the terms of the GNU General Public License as published by
41228 + the Free Software Foundation; either version 3 of the License, or
41229 + (at your option) any later version.
41230 +
41231 + This program is distributed in the hope that it will be useful,
41232 + but WITHOUT ANY WARRANTY; without even the implied warranty of
41233 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
41234 + GNU General Public License for more details.
41235 +
41236 + You should have received a copy of the GNU General Public License
41237 + along with this program; if not, write to the Free Software
41238 + Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
41239 + MA 02110-1301, USA. */
41240 +
41241 +#include "hashtab.h"
41242 +
41243 +/* Align an address upward to a boundary, expressed as a number of bytes.
41244 + E.g. align to an 8-byte boundary with argument of 8. Take care never
41245 + to wrap around if the address is within boundary-1 of the end of the
41246 + address space. */
41247 +#define BFD_ALIGN(this, boundary) \
41248 + ((((bfd_vma) (this) + (boundary) - 1) >= (bfd_vma) (this)) \
41249 + ? (((bfd_vma) (this) + ((boundary) - 1)) & ~ (bfd_vma) ((boundary)-1)) \
41250 + : ~ (bfd_vma) 0)
41251 +
41252 +/* If you want to read and write large blocks, you might want to do it
41253 + in quanta of this amount */
41254 +#define DEFAULT_BUFFERSIZE 8192
41255 +
41256 +/* Set a tdata field. Can't use the other macros for this, since they
41257 + do casts, and casting to the left of assignment isn't portable. */
41258 +#define set_tdata(bfd, v) ((bfd)->tdata.any = (v))
41259 +
41260 +/* If BFD_IN_MEMORY is set for a BFD, then the iostream fields points
41261 + to an instance of this structure. */
41262 +
41263 +struct bfd_in_memory
41264 +{
41265 + /* Size of buffer. */
41266 + bfd_size_type size;
41267 + /* Buffer holding contents of BFD. */
41268 + bfd_byte *buffer;
41269 +};
41270 +
41271 +struct section_hash_entry
41272 +{
41273 + struct bfd_hash_entry root;
41274 + asection section;
41275 +};
41276 +
41277 +/* tdata for an archive. For an input archive, cache
41278 + needs to be free()'d. For an output archive, symdefs do. */
41279 +
41280 +struct artdata {
41281 + file_ptr first_file_filepos;
41282 + /* Speed up searching the armap */
41283 + htab_t cache;
41284 + bfd *archive_head; /* Only interesting in output routines */
41285 + carsym *symdefs; /* the symdef entries */
41286 + symindex symdef_count; /* how many there are */
41287 + char *extended_names; /* clever intel extension */
41288 + bfd_size_type extended_names_size; /* Size of extended names */
41289 + /* when more compilers are standard C, this can be a time_t */
41290 + long armap_timestamp; /* Timestamp value written into armap.
41291 + This is used for BSD archives to check
41292 + that the timestamp is recent enough
41293 + for the BSD linker to not complain,
41294 + just before we finish writing an
41295 + archive. */
41296 + file_ptr armap_datepos; /* Position within archive to seek to
41297 + rewrite the date field. */
41298 + void *tdata; /* Backend specific information. */
41299 +};
41300 +
41301 +#define bfd_ardata(bfd) ((bfd)->tdata.aout_ar_data)
41302 +
41303 +/* Goes in bfd's arelt_data slot */
41304 +struct areltdata {
41305 + char * arch_header; /* it's actually a string */
41306 + unsigned int parsed_size; /* octets of filesize not including ar_hdr */
41307 + char *filename; /* null-terminated */
41308 +};
41309 +
41310 +#define arelt_size(bfd) (((struct areltdata *)((bfd)->arelt_data))->parsed_size)
41311 +
41312 +extern void *bfd_malloc
41313 + (bfd_size_type);
41314 +extern void *bfd_realloc
41315 + (void *, bfd_size_type);
41316 +extern void *bfd_zmalloc
41317 + (bfd_size_type);
41318 +extern void *bfd_malloc2
41319 + (bfd_size_type, bfd_size_type);
41320 +extern void *bfd_realloc2
41321 + (void *, bfd_size_type, bfd_size_type);
41322 +extern void *bfd_zmalloc2
41323 + (bfd_size_type, bfd_size_type);
41324 +
41325 +extern void _bfd_default_error_handler (const char *s, ...);
41326 +extern bfd_error_handler_type _bfd_error_handler;
41327 +
41328 +/* These routines allocate and free things on the BFD's objalloc. */
41329 +
41330 +extern void *bfd_alloc
41331 + (bfd *, bfd_size_type);
41332 +extern void *bfd_zalloc
41333 + (bfd *, bfd_size_type);
41334 +extern void *bfd_alloc2
41335 + (bfd *, bfd_size_type, bfd_size_type);
41336 +extern void *bfd_zalloc2
41337 + (bfd *, bfd_size_type, bfd_size_type);
41338 +extern void bfd_release
41339 + (bfd *, void *);
41340 +
41341 +bfd * _bfd_create_empty_archive_element_shell
41342 + (bfd *obfd);
41343 +bfd * _bfd_look_for_bfd_in_cache
41344 + (bfd *, file_ptr);
41345 +bfd_boolean _bfd_add_bfd_to_archive_cache
41346 + (bfd *, file_ptr, bfd *);
41347 +bfd_boolean _bfd_generic_mkarchive
41348 + (bfd *abfd);
41349 +const bfd_target *bfd_generic_archive_p
41350 + (bfd *abfd);
41351 +bfd_boolean bfd_slurp_armap
41352 + (bfd *abfd);
41353 +bfd_boolean bfd_slurp_bsd_armap_f2
41354 + (bfd *abfd);
41355 +#define bfd_slurp_bsd_armap bfd_slurp_armap
41356 +#define bfd_slurp_coff_armap bfd_slurp_armap
41357 +bfd_boolean _bfd_slurp_extended_name_table
41358 + (bfd *abfd);
41359 +extern bfd_boolean _bfd_construct_extended_name_table
41360 + (bfd *, bfd_boolean, char **, bfd_size_type *);
41361 +bfd_boolean _bfd_write_archive_contents
41362 + (bfd *abfd);
41363 +bfd_boolean _bfd_compute_and_write_armap
41364 + (bfd *, unsigned int elength);
41365 +bfd *_bfd_get_elt_at_filepos
41366 + (bfd *archive, file_ptr filepos);
41367 +extern bfd *_bfd_generic_get_elt_at_index
41368 + (bfd *, symindex);
41369 +bfd * _bfd_new_bfd
41370 + (void);
41371 +void _bfd_delete_bfd
41372 + (bfd *);
41373 +bfd_boolean _bfd_free_cached_info
41374 + (bfd *);
41375 +
41376 +bfd_boolean bfd_false
41377 + (bfd *ignore);
41378 +bfd_boolean bfd_true
41379 + (bfd *ignore);
41380 +void *bfd_nullvoidptr
41381 + (bfd *ignore);
41382 +int bfd_0
41383 + (bfd *ignore);
41384 +unsigned int bfd_0u
41385 + (bfd *ignore);
41386 +long bfd_0l
41387 + (bfd *ignore);
41388 +long _bfd_n1
41389 + (bfd *ignore);
41390 +void bfd_void
41391 + (bfd *ignore);
41392 +
41393 +bfd *_bfd_new_bfd_contained_in
41394 + (bfd *);
41395 +const bfd_target *_bfd_dummy_target
41396 + (bfd *abfd);
41397 +
41398 +void bfd_dont_truncate_arname
41399 + (bfd *abfd, const char *filename, char *hdr);
41400 +void bfd_bsd_truncate_arname
41401 + (bfd *abfd, const char *filename, char *hdr);
41402 +void bfd_gnu_truncate_arname
41403 + (bfd *abfd, const char *filename, char *hdr);
41404 +
41405 +bfd_boolean bsd_write_armap
41406 + (bfd *arch, unsigned int elength, struct orl *map, unsigned int orl_count,
41407 + int stridx);
41408 +
41409 +bfd_boolean coff_write_armap
41410 + (bfd *arch, unsigned int elength, struct orl *map, unsigned int orl_count,
41411 + int stridx);
41412 +
41413 +extern void *_bfd_generic_read_ar_hdr
41414 + (bfd *);
41415 +extern void _bfd_ar_spacepad
41416 + (char *, size_t, const char *, long);
41417 +
41418 +extern void *_bfd_generic_read_ar_hdr_mag
41419 + (bfd *, const char *);
41420 +
41421 +bfd * bfd_generic_openr_next_archived_file
41422 + (bfd *archive, bfd *last_file);
41423 +
41424 +int bfd_generic_stat_arch_elt
41425 + (bfd *, struct stat *);
41426 +
41427 +#define _bfd_read_ar_hdr(abfd) \
41428 + BFD_SEND (abfd, _bfd_read_ar_hdr_fn, (abfd))
41429 +\f
41430 +/* Generic routines to use for BFD_JUMP_TABLE_GENERIC. Use
41431 + BFD_JUMP_TABLE_GENERIC (_bfd_generic). */
41432 +
41433 +#define _bfd_generic_close_and_cleanup bfd_true
41434 +#define _bfd_generic_bfd_free_cached_info bfd_true
41435 +extern bfd_boolean _bfd_generic_new_section_hook
41436 + (bfd *, asection *);
41437 +extern bfd_boolean _bfd_generic_get_section_contents
41438 + (bfd *, asection *, void *, file_ptr, bfd_size_type);
41439 +extern bfd_boolean _bfd_generic_get_section_contents_in_window
41440 + (bfd *, asection *, bfd_window *, file_ptr, bfd_size_type);
41441 +
41442 +/* Generic routines to use for BFD_JUMP_TABLE_COPY. Use
41443 + BFD_JUMP_TABLE_COPY (_bfd_generic). */
41444 +
41445 +#define _bfd_generic_bfd_copy_private_bfd_data \
41446 + ((bfd_boolean (*) (bfd *, bfd *)) bfd_true)
41447 +#define _bfd_generic_bfd_merge_private_bfd_data \
41448 + ((bfd_boolean (*) (bfd *, bfd *)) bfd_true)
41449 +#define _bfd_generic_bfd_set_private_flags \
41450 + ((bfd_boolean (*) (bfd *, flagword)) bfd_true)
41451 +#define _bfd_generic_bfd_copy_private_section_data \
41452 + ((bfd_boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true)
41453 +#define _bfd_generic_bfd_copy_private_symbol_data \
41454 + ((bfd_boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true)
41455 +#define _bfd_generic_bfd_copy_private_header_data \
41456 + ((bfd_boolean (*) (bfd *, bfd *)) bfd_true)
41457 +#define _bfd_generic_bfd_print_private_bfd_data \
41458 + ((bfd_boolean (*) (bfd *, void *)) bfd_true)
41459 +
41460 +extern bfd_boolean _bfd_generic_init_private_section_data
41461 + (bfd *, asection *, bfd *, asection *, struct bfd_link_info *);
41462 +
41463 +/* Routines to use for BFD_JUMP_TABLE_CORE when there is no core file
41464 + support. Use BFD_JUMP_TABLE_CORE (_bfd_nocore). */
41465 +
41466 +extern char *_bfd_nocore_core_file_failing_command
41467 + (bfd *);
41468 +extern int _bfd_nocore_core_file_failing_signal
41469 + (bfd *);
41470 +extern bfd_boolean _bfd_nocore_core_file_matches_executable_p
41471 + (bfd *, bfd *);
41472 +
41473 +/* Routines to use for BFD_JUMP_TABLE_ARCHIVE when there is no archive
41474 + file support. Use BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive). */
41475 +
41476 +#define _bfd_noarchive_slurp_armap bfd_false
41477 +#define _bfd_noarchive_slurp_extended_name_table bfd_false
41478 +#define _bfd_noarchive_construct_extended_name_table \
41479 + ((bfd_boolean (*) (bfd *, char **, bfd_size_type *, const char **)) \
41480 + bfd_false)
41481 +#define _bfd_noarchive_truncate_arname \
41482 + ((void (*) (bfd *, const char *, char *)) bfd_void)
41483 +#define _bfd_noarchive_write_armap \
41484 + ((bfd_boolean (*) (bfd *, unsigned int, struct orl *, unsigned int, int)) \
41485 + bfd_false)
41486 +#define _bfd_noarchive_read_ar_hdr bfd_nullvoidptr
41487 +#define _bfd_noarchive_openr_next_archived_file \
41488 + ((bfd *(*) (bfd *, bfd *)) bfd_nullvoidptr)
41489 +#define _bfd_noarchive_get_elt_at_index \
41490 + ((bfd *(*) (bfd *, symindex)) bfd_nullvoidptr)
41491 +#define _bfd_noarchive_generic_stat_arch_elt bfd_generic_stat_arch_elt
41492 +#define _bfd_noarchive_update_armap_timestamp bfd_false
41493 +
41494 +/* Routines to use for BFD_JUMP_TABLE_ARCHIVE to get BSD style
41495 + archives. Use BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_bsd). */
41496 +
41497 +#define _bfd_archive_bsd_slurp_armap bfd_slurp_bsd_armap
41498 +#define _bfd_archive_bsd_slurp_extended_name_table \
41499 + _bfd_slurp_extended_name_table
41500 +extern bfd_boolean _bfd_archive_bsd_construct_extended_name_table
41501 + (bfd *, char **, bfd_size_type *, const char **);
41502 +#define _bfd_archive_bsd_truncate_arname bfd_bsd_truncate_arname
41503 +#define _bfd_archive_bsd_write_armap bsd_write_armap
41504 +#define _bfd_archive_bsd_read_ar_hdr _bfd_generic_read_ar_hdr
41505 +#define _bfd_archive_bsd_openr_next_archived_file \
41506 + bfd_generic_openr_next_archived_file
41507 +#define _bfd_archive_bsd_get_elt_at_index _bfd_generic_get_elt_at_index
41508 +#define _bfd_archive_bsd_generic_stat_arch_elt \
41509 + bfd_generic_stat_arch_elt
41510 +extern bfd_boolean _bfd_archive_bsd_update_armap_timestamp
41511 + (bfd *);
41512 +
41513 +/* Routines to use for BFD_JUMP_TABLE_ARCHIVE to get COFF style
41514 + archives. Use BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_coff). */
41515 +
41516 +#define _bfd_archive_coff_slurp_armap bfd_slurp_coff_armap
41517 +#define _bfd_archive_coff_slurp_extended_name_table \
41518 + _bfd_slurp_extended_name_table
41519 +extern bfd_boolean _bfd_archive_coff_construct_extended_name_table
41520 + (bfd *, char **, bfd_size_type *, const char **);
41521 +#define _bfd_archive_coff_truncate_arname bfd_dont_truncate_arname
41522 +#define _bfd_archive_coff_write_armap coff_write_armap
41523 +#define _bfd_archive_coff_read_ar_hdr _bfd_generic_read_ar_hdr
41524 +#define _bfd_archive_coff_openr_next_archived_file \
41525 + bfd_generic_openr_next_archived_file
41526 +#define _bfd_archive_coff_get_elt_at_index _bfd_generic_get_elt_at_index
41527 +#define _bfd_archive_coff_generic_stat_arch_elt \
41528 + bfd_generic_stat_arch_elt
41529 +#define _bfd_archive_coff_update_armap_timestamp bfd_true
41530 +
41531 +/* Routines to use for BFD_JUMP_TABLE_SYMBOLS where there is no symbol
41532 + support. Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols). */
41533 +
41534 +#define _bfd_nosymbols_get_symtab_upper_bound _bfd_n1
41535 +#define _bfd_nosymbols_canonicalize_symtab \
41536 + ((long (*) (bfd *, asymbol **)) _bfd_n1)
41537 +#define _bfd_nosymbols_make_empty_symbol _bfd_generic_make_empty_symbol
41538 +#define _bfd_nosymbols_print_symbol \
41539 + ((void (*) (bfd *, void *, asymbol *, bfd_print_symbol_type)) bfd_void)
41540 +#define _bfd_nosymbols_get_symbol_info \
41541 + ((void (*) (bfd *, asymbol *, symbol_info *)) bfd_void)
41542 +#define _bfd_nosymbols_bfd_is_local_label_name \
41543 + ((bfd_boolean (*) (bfd *, const char *)) bfd_false)
41544 +#define _bfd_nosymbols_bfd_is_target_special_symbol \
41545 + ((bfd_boolean (*) (bfd *, asymbol *)) bfd_false)
41546 +#define _bfd_nosymbols_get_lineno \
41547 + ((alent *(*) (bfd *, asymbol *)) bfd_nullvoidptr)
41548 +#define _bfd_nosymbols_find_nearest_line \
41549 + ((bfd_boolean (*) (bfd *, asection *, asymbol **, bfd_vma, const char **, \
41550 + const char **, unsigned int *)) \
41551 + bfd_false)
41552 +#define _bfd_nosymbols_find_inliner_info \
41553 + ((bfd_boolean (*) (bfd *, const char **, const char **, unsigned int *)) \
41554 + bfd_false)
41555 +#define _bfd_nosymbols_bfd_make_debug_symbol \
41556 + ((asymbol *(*) (bfd *, void *, unsigned long)) bfd_nullvoidptr)
41557 +#define _bfd_nosymbols_read_minisymbols \
41558 + ((long (*) (bfd *, bfd_boolean, void **, unsigned int *)) _bfd_n1)
41559 +#define _bfd_nosymbols_minisymbol_to_symbol \
41560 + ((asymbol *(*) (bfd *, bfd_boolean, const void *, asymbol *)) \
41561 + bfd_nullvoidptr)
41562 +
41563 +/* Routines to use for BFD_JUMP_TABLE_RELOCS when there is no reloc
41564 + support. Use BFD_JUMP_TABLE_RELOCS (_bfd_norelocs). */
41565 +
41566 +extern long _bfd_norelocs_get_reloc_upper_bound (bfd *, asection *);
41567 +extern long _bfd_norelocs_canonicalize_reloc (bfd *, asection *,
41568 + arelent **, asymbol **);
41569 +#define _bfd_norelocs_bfd_reloc_type_lookup \
41570 + ((reloc_howto_type *(*) (bfd *, bfd_reloc_code_real_type)) bfd_nullvoidptr)
41571 +#define _bfd_norelocs_bfd_reloc_name_lookup \
41572 + ((reloc_howto_type *(*) (bfd *, const char *)) bfd_nullvoidptr)
41573 +
41574 +/* Routines to use for BFD_JUMP_TABLE_WRITE for targets which may not
41575 + be written. Use BFD_JUMP_TABLE_WRITE (_bfd_nowrite). */
41576 +
41577 +#define _bfd_nowrite_set_arch_mach \
41578 + ((bfd_boolean (*) (bfd *, enum bfd_architecture, unsigned long)) \
41579 + bfd_false)
41580 +#define _bfd_nowrite_set_section_contents \
41581 + ((bfd_boolean (*) (bfd *, asection *, const void *, file_ptr, bfd_size_type)) \
41582 + bfd_false)
41583 +
41584 +/* Generic routines to use for BFD_JUMP_TABLE_WRITE. Use
41585 + BFD_JUMP_TABLE_WRITE (_bfd_generic). */
41586 +
41587 +#define _bfd_generic_set_arch_mach bfd_default_set_arch_mach
41588 +extern bfd_boolean _bfd_generic_set_section_contents
41589 + (bfd *, asection *, const void *, file_ptr, bfd_size_type);
41590 +
41591 +/* Routines to use for BFD_JUMP_TABLE_LINK for targets which do not
41592 + support linking. Use BFD_JUMP_TABLE_LINK (_bfd_nolink). */
41593 +
41594 +#define _bfd_nolink_sizeof_headers \
41595 + ((int (*) (bfd *, struct bfd_link_info *)) bfd_0)
41596 +#define _bfd_nolink_bfd_get_relocated_section_contents \
41597 + ((bfd_byte *(*) (bfd *, struct bfd_link_info *, struct bfd_link_order *, \
41598 + bfd_byte *, bfd_boolean, asymbol **)) \
41599 + bfd_nullvoidptr)
41600 +#define _bfd_nolink_bfd_relax_section \
41601 + ((bfd_boolean (*) \
41602 + (bfd *, asection *, struct bfd_link_info *, bfd_boolean *)) \
41603 + bfd_false)
41604 +#define _bfd_nolink_bfd_gc_sections \
41605 + ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) \
41606 + bfd_false)
41607 +#define _bfd_nolink_bfd_merge_sections \
41608 + ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) \
41609 + bfd_false)
41610 +#define _bfd_nolink_bfd_is_group_section \
41611 + ((bfd_boolean (*) (bfd *, const struct bfd_section *)) \
41612 + bfd_false)
41613 +#define _bfd_nolink_bfd_discard_group \
41614 + ((bfd_boolean (*) (bfd *, struct bfd_section *)) \
41615 + bfd_false)
41616 +#define _bfd_nolink_bfd_link_hash_table_create \
41617 + ((struct bfd_link_hash_table *(*) (bfd *)) bfd_nullvoidptr)
41618 +#define _bfd_nolink_bfd_link_hash_table_free \
41619 + ((void (*) (struct bfd_link_hash_table *)) bfd_void)
41620 +#define _bfd_nolink_bfd_link_add_symbols \
41621 + ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) bfd_false)
41622 +#define _bfd_nolink_bfd_link_just_syms \
41623 + ((void (*) (asection *, struct bfd_link_info *)) bfd_void)
41624 +#define _bfd_nolink_bfd_final_link \
41625 + ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) bfd_false)
41626 +#define _bfd_nolink_bfd_link_split_section \
41627 + ((bfd_boolean (*) (bfd *, struct bfd_section *)) bfd_false)
41628 +#define _bfd_nolink_section_already_linked \
41629 + ((void (*) (bfd *, struct bfd_section *, struct bfd_link_info *)) bfd_void)
41630 +
41631 +/* Routines to use for BFD_JUMP_TABLE_DYNAMIC for targets which do not
41632 + have dynamic symbols or relocs. Use BFD_JUMP_TABLE_DYNAMIC
41633 + (_bfd_nodynamic). */
41634 +
41635 +#define _bfd_nodynamic_get_dynamic_symtab_upper_bound _bfd_n1
41636 +#define _bfd_nodynamic_canonicalize_dynamic_symtab \
41637 + ((long (*) (bfd *, asymbol **)) _bfd_n1)
41638 +#define _bfd_nodynamic_get_synthetic_symtab \
41639 + ((long (*) (bfd *, long, asymbol **, long, asymbol **, asymbol **)) _bfd_n1)
41640 +#define _bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_n1
41641 +#define _bfd_nodynamic_canonicalize_dynamic_reloc \
41642 + ((long (*) (bfd *, arelent **, asymbol **)) _bfd_n1)
41643 +\f
41644 +/* Generic routine to determine of the given symbol is a local
41645 + label. */
41646 +extern bfd_boolean bfd_generic_is_local_label_name
41647 + (bfd *, const char *);
41648 +
41649 +/* Generic minisymbol routines. */
41650 +extern long _bfd_generic_read_minisymbols
41651 + (bfd *, bfd_boolean, void **, unsigned int *);
41652 +extern asymbol *_bfd_generic_minisymbol_to_symbol
41653 + (bfd *, bfd_boolean, const void *, asymbol *);
41654 +
41655 +/* Find the nearest line using .stab/.stabstr sections. */
41656 +extern bfd_boolean _bfd_stab_section_find_nearest_line
41657 + (bfd *, asymbol **, asection *, bfd_vma, bfd_boolean *,
41658 + const char **, const char **, unsigned int *, void **);
41659 +
41660 +/* Find the nearest line using DWARF 1 debugging information. */
41661 +extern bfd_boolean _bfd_dwarf1_find_nearest_line
41662 + (bfd *, asection *, asymbol **, bfd_vma, const char **,
41663 + const char **, unsigned int *);
41664 +
41665 +/* Find the nearest line using DWARF 2 debugging information. */
41666 +extern bfd_boolean _bfd_dwarf2_find_nearest_line
41667 + (bfd *, asection *, asymbol **, bfd_vma, const char **, const char **,
41668 + unsigned int *, unsigned int, void **);
41669 +
41670 +/* Find the line using DWARF 2 debugging information. */
41671 +extern bfd_boolean _bfd_dwarf2_find_line
41672 + (bfd *, asymbol **, asymbol *, const char **,
41673 + unsigned int *, unsigned int, void **);
41674 +
41675 +bfd_boolean _bfd_generic_find_line
41676 + (bfd *, asymbol **, asymbol *, const char **, unsigned int *);
41677 +
41678 +/* Find inliner info after calling bfd_find_nearest_line. */
41679 +extern bfd_boolean _bfd_dwarf2_find_inliner_info
41680 + (bfd *, const char **, const char **, unsigned int *, void **);
41681 +
41682 +/* Create a new section entry. */
41683 +extern struct bfd_hash_entry *bfd_section_hash_newfunc
41684 + (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
41685 +
41686 +/* A routine to create entries for a bfd_link_hash_table. */
41687 +extern struct bfd_hash_entry *_bfd_link_hash_newfunc
41688 + (struct bfd_hash_entry *entry, struct bfd_hash_table *table,
41689 + const char *string);
41690 +
41691 +/* Initialize a bfd_link_hash_table. */
41692 +extern bfd_boolean _bfd_link_hash_table_init
41693 + (struct bfd_link_hash_table *, bfd *,
41694 + struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
41695 + struct bfd_hash_table *,
41696 + const char *),
41697 + unsigned int);
41698 +
41699 +/* Generic link hash table creation routine. */
41700 +extern struct bfd_link_hash_table *_bfd_generic_link_hash_table_create
41701 + (bfd *);
41702 +
41703 +/* Generic link hash table destruction routine. */
41704 +extern void _bfd_generic_link_hash_table_free
41705 + (struct bfd_link_hash_table *);
41706 +
41707 +/* Generic add symbol routine. */
41708 +extern bfd_boolean _bfd_generic_link_add_symbols
41709 + (bfd *, struct bfd_link_info *);
41710 +
41711 +/* Generic add symbol routine. This version is used by targets for
41712 + which the linker must collect constructors and destructors by name,
41713 + as the collect2 program does. */
41714 +extern bfd_boolean _bfd_generic_link_add_symbols_collect
41715 + (bfd *, struct bfd_link_info *);
41716 +
41717 +/* Generic archive add symbol routine. */
41718 +extern bfd_boolean _bfd_generic_link_add_archive_symbols
41719 + (bfd *, struct bfd_link_info *,
41720 + bfd_boolean (*) (bfd *, struct bfd_link_info *, bfd_boolean *));
41721 +
41722 +/* Forward declaration to avoid prototype errors. */
41723 +typedef struct bfd_link_hash_entry _bfd_link_hash_entry;
41724 +
41725 +/* Generic routine to add a single symbol. */
41726 +extern bfd_boolean _bfd_generic_link_add_one_symbol
41727 + (struct bfd_link_info *, bfd *, const char *name, flagword,
41728 + asection *, bfd_vma, const char *, bfd_boolean copy,
41729 + bfd_boolean constructor, struct bfd_link_hash_entry **);
41730 +
41731 +/* Generic routine to mark section as supplying symbols only. */
41732 +extern void _bfd_generic_link_just_syms
41733 + (asection *, struct bfd_link_info *);
41734 +
41735 +/* Generic link routine. */
41736 +extern bfd_boolean _bfd_generic_final_link
41737 + (bfd *, struct bfd_link_info *);
41738 +
41739 +extern bfd_boolean _bfd_generic_link_split_section
41740 + (bfd *, struct bfd_section *);
41741 +
41742 +extern void _bfd_generic_section_already_linked
41743 + (bfd *, struct bfd_section *, struct bfd_link_info *);
41744 +
41745 +/* Generic reloc_link_order processing routine. */
41746 +extern bfd_boolean _bfd_generic_reloc_link_order
41747 + (bfd *, struct bfd_link_info *, asection *, struct bfd_link_order *);
41748 +
41749 +/* Default link order processing routine. */
41750 +extern bfd_boolean _bfd_default_link_order
41751 + (bfd *, struct bfd_link_info *, asection *, struct bfd_link_order *);
41752 +
41753 +/* Count the number of reloc entries in a link order list. */
41754 +extern unsigned int _bfd_count_link_order_relocs
41755 + (struct bfd_link_order *);
41756 +
41757 +/* Final link relocation routine. */
41758 +extern bfd_reloc_status_type _bfd_final_link_relocate
41759 + (reloc_howto_type *, bfd *, asection *, bfd_byte *,
41760 + bfd_vma, bfd_vma, bfd_vma);
41761 +
41762 +/* Relocate a particular location by a howto and a value. */
41763 +extern bfd_reloc_status_type _bfd_relocate_contents
41764 + (reloc_howto_type *, bfd *, bfd_vma, bfd_byte *);
41765 +
41766 +/* Clear a given location using a given howto. */
41767 +extern void _bfd_clear_contents (reloc_howto_type *howto, bfd *input_bfd,
41768 + bfd_byte *location);
41769 +
41770 +/* Link stabs in sections in the first pass. */
41771 +
41772 +extern bfd_boolean _bfd_link_section_stabs
41773 + (bfd *, struct stab_info *, asection *, asection *, void **,
41774 + bfd_size_type *);
41775 +
41776 +/* Eliminate stabs for discarded functions and symbols. */
41777 +extern bfd_boolean _bfd_discard_section_stabs
41778 + (bfd *, asection *, void *, bfd_boolean (*) (bfd_vma, void *), void *);
41779 +
41780 +/* Write out the .stab section when linking stabs in sections. */
41781 +
41782 +extern bfd_boolean _bfd_write_section_stabs
41783 + (bfd *, struct stab_info *, asection *, void **, bfd_byte *);
41784 +
41785 +/* Write out the .stabstr string table when linking stabs in sections. */
41786 +
41787 +extern bfd_boolean _bfd_write_stab_strings
41788 + (bfd *, struct stab_info *);
41789 +
41790 +/* Find an offset within a .stab section when linking stabs in
41791 + sections. */
41792 +
41793 +extern bfd_vma _bfd_stab_section_offset
41794 + (asection *, void *, bfd_vma);
41795 +
41796 +/* Register a SEC_MERGE section as a candidate for merging. */
41797 +
41798 +extern bfd_boolean _bfd_add_merge_section
41799 + (bfd *, void **, asection *, void **);
41800 +
41801 +/* Attempt to merge SEC_MERGE sections. */
41802 +
41803 +extern bfd_boolean _bfd_merge_sections
41804 + (bfd *, struct bfd_link_info *, void *, void (*) (bfd *, asection *));
41805 +
41806 +/* Write out a merged section. */
41807 +
41808 +extern bfd_boolean _bfd_write_merged_section
41809 + (bfd *, asection *, void *);
41810 +
41811 +/* Find an offset within a modified SEC_MERGE section. */
41812 +
41813 +extern bfd_vma _bfd_merged_section_offset
41814 + (bfd *, asection **, void *, bfd_vma);
41815 +
41816 +/* Create a string table. */
41817 +extern struct bfd_strtab_hash *_bfd_stringtab_init
41818 + (void);
41819 +
41820 +/* Create an XCOFF .debug section style string table. */
41821 +extern struct bfd_strtab_hash *_bfd_xcoff_stringtab_init
41822 + (void);
41823 +
41824 +/* Free a string table. */
41825 +extern void _bfd_stringtab_free
41826 + (struct bfd_strtab_hash *);
41827 +
41828 +/* Get the size of a string table. */
41829 +extern bfd_size_type _bfd_stringtab_size
41830 + (struct bfd_strtab_hash *);
41831 +
41832 +/* Add a string to a string table. */
41833 +extern bfd_size_type _bfd_stringtab_add
41834 + (struct bfd_strtab_hash *, const char *, bfd_boolean hash, bfd_boolean copy);
41835 +
41836 +/* Write out a string table. */
41837 +extern bfd_boolean _bfd_stringtab_emit
41838 + (bfd *, struct bfd_strtab_hash *);
41839 +
41840 +/* Check that endianness of input and output file match. */
41841 +extern bfd_boolean _bfd_generic_verify_endian_match
41842 + (bfd *, bfd *);
41843 +\f
41844 +/* Macros to tell if bfds are read or write enabled.
41845 +
41846 + Note that bfds open for read may be scribbled into if the fd passed
41847 + to bfd_fdopenr is actually open both for read and write
41848 + simultaneously. However an output bfd will never be open for
41849 + read. Therefore sometimes you want to check bfd_read_p or
41850 + !bfd_read_p, and only sometimes bfd_write_p.
41851 +*/
41852 +
41853 +#define bfd_read_p(abfd) \
41854 + ((abfd)->direction == read_direction || (abfd)->direction == both_direction)
41855 +#define bfd_write_p(abfd) \
41856 + ((abfd)->direction == write_direction || (abfd)->direction == both_direction)
41857 +
41858 +void bfd_assert
41859 + (const char*,int);
41860 +
41861 +#define BFD_ASSERT(x) \
41862 + do { if (!(x)) bfd_assert(__FILE__,__LINE__); } while (0)
41863 +
41864 +#define BFD_FAIL() \
41865 + do { bfd_assert(__FILE__,__LINE__); } while (0)
41866 +
41867 +extern void _bfd_abort
41868 + (const char *, int, const char *) ATTRIBUTE_NORETURN;
41869 +
41870 +/* if gcc >= 2.6, we can give a function name, too */
41871 +#if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 6)
41872 +#define __PRETTY_FUNCTION__ ((char *) NULL)
41873 +#endif
41874 +
41875 +#undef abort
41876 +#define abort() _bfd_abort (__FILE__, __LINE__, __PRETTY_FUNCTION__)
41877 +
41878 +/* Manipulate a system FILE but using BFD's "file_ptr", rather than
41879 + the system "off_t" or "off64_t", as the offset. */
41880 +extern file_ptr real_ftell (FILE *file);
41881 +extern int real_fseek (FILE *file, file_ptr offset, int whence);
41882 +extern FILE *real_fopen (const char *filename, const char *modes);
41883 +
41884 +/* List of supported target vectors, and the default vector (if
41885 + bfd_default_vector[0] is NULL, there is no default). */
41886 +extern const bfd_target * const *bfd_target_vector;
41887 +extern const bfd_target *bfd_default_vector[];
41888 +
41889 +/* List of associated target vectors. */
41890 +extern const bfd_target * const *bfd_associated_vector;
41891 +
41892 +/* Functions shared by the ECOFF and MIPS ELF backends, which have no
41893 + other common header files. */
41894 +
41895 +#if defined(__STDC__) || defined(ALMOST_STDC)
41896 +struct ecoff_find_line;
41897 +#endif
41898 +
41899 +extern bfd_boolean _bfd_ecoff_locate_line
41900 + (bfd *, asection *, bfd_vma, struct ecoff_debug_info * const,
41901 + const struct ecoff_debug_swap * const, struct ecoff_find_line *,
41902 + const char **, const char **, unsigned int *);
41903 +extern bfd_boolean _bfd_ecoff_get_accumulated_pdr
41904 + (void *, bfd_byte *);
41905 +extern bfd_boolean _bfd_ecoff_get_accumulated_sym
41906 + (void *, bfd_byte *);
41907 +extern bfd_boolean _bfd_ecoff_get_accumulated_ss
41908 + (void *, bfd_byte *);
41909 +
41910 +extern bfd_vma _bfd_get_gp_value
41911 + (bfd *);
41912 +extern void _bfd_set_gp_value
41913 + (bfd *, bfd_vma);
41914 +
41915 +/* Function shared by the COFF and ELF SH backends, which have no
41916 + other common header files. */
41917 +
41918 +#ifndef _bfd_sh_align_load_span
41919 +extern bfd_boolean _bfd_sh_align_load_span
41920 + (bfd *, asection *, bfd_byte *,
41921 + bfd_boolean (*) (bfd *, asection *, void *, bfd_byte *, bfd_vma),
41922 + void *, bfd_vma **, bfd_vma *, bfd_vma, bfd_vma, bfd_boolean *);
41923 +#endif
41924 +
41925 +/* This is the shape of the elements inside the already_linked hash
41926 + table. It maps a name onto a list of already_linked elements with
41927 + the same name. */
41928 +
41929 +struct bfd_section_already_linked_hash_entry
41930 +{
41931 + struct bfd_hash_entry root;
41932 + struct bfd_section_already_linked *entry;
41933 +};
41934 +
41935 +struct bfd_section_already_linked
41936 +{
41937 + struct bfd_section_already_linked *next;
41938 + asection *sec;
41939 +};
41940 +
41941 +extern struct bfd_section_already_linked_hash_entry *
41942 + bfd_section_already_linked_table_lookup (const char *);
41943 +extern bfd_boolean bfd_section_already_linked_table_insert
41944 + (struct bfd_section_already_linked_hash_entry *, asection *);
41945 +extern void bfd_section_already_linked_table_traverse
41946 + (bfd_boolean (*) (struct bfd_section_already_linked_hash_entry *,
41947 + void *), void *);
41948 +
41949 +extern bfd_vma read_unsigned_leb128 (bfd *, bfd_byte *, unsigned int *);
41950 +extern bfd_signed_vma read_signed_leb128 (bfd *, bfd_byte *, unsigned int *);
41951 +
41952 +/* Extracted from init.c. */
41953 +/* Extracted from libbfd.c. */
41954 +bfd_boolean bfd_write_bigendian_4byte_int (bfd *, unsigned int);
41955 +
41956 +unsigned int bfd_log2 (bfd_vma x);
41957 +
41958 +/* Extracted from bfdio.c. */
41959 +struct bfd_iovec
41960 +{
41961 + /* To avoid problems with macros, a "b" rather than "f"
41962 + prefix is prepended to each method name. */
41963 + /* Attempt to read/write NBYTES on ABFD's IOSTREAM storing/fetching
41964 + bytes starting at PTR. Return the number of bytes actually
41965 + transfered (a read past end-of-file returns less than NBYTES),
41966 + or -1 (setting <<bfd_error>>) if an error occurs. */
41967 + file_ptr (*bread) (struct bfd *abfd, void *ptr, file_ptr nbytes);
41968 + file_ptr (*bwrite) (struct bfd *abfd, const void *ptr,
41969 + file_ptr nbytes);
41970 + /* Return the current IOSTREAM file offset, or -1 (setting <<bfd_error>>
41971 + if an error occurs. */
41972 + file_ptr (*btell) (struct bfd *abfd);
41973 + /* For the following, on successful completion a value of 0 is returned.
41974 + Otherwise, a value of -1 is returned (and <<bfd_error>> is set). */
41975 + int (*bseek) (struct bfd *abfd, file_ptr offset, int whence);
41976 + int (*bclose) (struct bfd *abfd);
41977 + int (*bflush) (struct bfd *abfd);
41978 + int (*bstat) (struct bfd *abfd, struct stat *sb);
41979 +};
41980 +/* Extracted from bfdwin.c. */
41981 +struct _bfd_window_internal {
41982 + struct _bfd_window_internal *next;
41983 + void *data;
41984 + bfd_size_type size;
41985 + int refcount : 31; /* should be enough... */
41986 + unsigned mapped : 1; /* 1 = mmap, 0 = malloc */
41987 +};
41988 +/* Extracted from cache.c. */
41989 +bfd_boolean bfd_cache_init (bfd *abfd);
41990 +
41991 +bfd_boolean bfd_cache_close (bfd *abfd);
41992 +
41993 +FILE* bfd_open_file (bfd *abfd);
41994 +
41995 +/* Extracted from reloc.c. */
41996 +#ifdef _BFD_MAKE_TABLE_bfd_reloc_code_real
41997 +
41998 +static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
41999 +
42000 + "BFD_RELOC_64",
42001 + "BFD_RELOC_32",
42002 + "BFD_RELOC_26",
42003 + "BFD_RELOC_24",
42004 + "BFD_RELOC_16",
42005 + "BFD_RELOC_14",
42006 + "BFD_RELOC_8",
42007 + "BFD_RELOC_64_PCREL",
42008 + "BFD_RELOC_32_PCREL",
42009 + "BFD_RELOC_24_PCREL",
42010 + "BFD_RELOC_16_PCREL",
42011 + "BFD_RELOC_12_PCREL",
42012 + "BFD_RELOC_8_PCREL",
42013 + "BFD_RELOC_32_SECREL",
42014 + "BFD_RELOC_32_GOT_PCREL",
42015 + "BFD_RELOC_16_GOT_PCREL",
42016 + "BFD_RELOC_8_GOT_PCREL",
42017 + "BFD_RELOC_32_GOTOFF",
42018 + "BFD_RELOC_16_GOTOFF",
42019 + "BFD_RELOC_LO16_GOTOFF",
42020 + "BFD_RELOC_HI16_GOTOFF",
42021 + "BFD_RELOC_HI16_S_GOTOFF",
42022 + "BFD_RELOC_8_GOTOFF",
42023 + "BFD_RELOC_64_PLT_PCREL",
42024 + "BFD_RELOC_32_PLT_PCREL",
42025 + "BFD_RELOC_24_PLT_PCREL",
42026 + "BFD_RELOC_16_PLT_PCREL",
42027 + "BFD_RELOC_8_PLT_PCREL",
42028 + "BFD_RELOC_64_PLTOFF",
42029 + "BFD_RELOC_32_PLTOFF",
42030 + "BFD_RELOC_16_PLTOFF",
42031 + "BFD_RELOC_LO16_PLTOFF",
42032 + "BFD_RELOC_HI16_PLTOFF",
42033 + "BFD_RELOC_HI16_S_PLTOFF",
42034 + "BFD_RELOC_8_PLTOFF",
42035 + "BFD_RELOC_68K_GLOB_DAT",
42036 + "BFD_RELOC_68K_JMP_SLOT",
42037 + "BFD_RELOC_68K_RELATIVE",
42038 + "BFD_RELOC_32_BASEREL",
42039 + "BFD_RELOC_16_BASEREL",
42040 + "BFD_RELOC_LO16_BASEREL",
42041 + "BFD_RELOC_HI16_BASEREL",
42042 + "BFD_RELOC_HI16_S_BASEREL",
42043 + "BFD_RELOC_8_BASEREL",
42044 + "BFD_RELOC_RVA",
42045 + "BFD_RELOC_8_FFnn",
42046 + "BFD_RELOC_32_PCREL_S2",
42047 + "BFD_RELOC_16_PCREL_S2",
42048 + "BFD_RELOC_23_PCREL_S2",
42049 + "BFD_RELOC_HI22",
42050 + "BFD_RELOC_LO10",
42051 + "BFD_RELOC_GPREL16",
42052 + "BFD_RELOC_GPREL32",
42053 + "BFD_RELOC_I960_CALLJ",
42054 + "BFD_RELOC_NONE",
42055 + "BFD_RELOC_SPARC_WDISP22",
42056 + "BFD_RELOC_SPARC22",
42057 + "BFD_RELOC_SPARC13",
42058 + "BFD_RELOC_SPARC_GOT10",
42059 + "BFD_RELOC_SPARC_GOT13",
42060 + "BFD_RELOC_SPARC_GOT22",
42061 + "BFD_RELOC_SPARC_PC10",
42062 + "BFD_RELOC_SPARC_PC22",
42063 + "BFD_RELOC_SPARC_WPLT30",
42064 + "BFD_RELOC_SPARC_COPY",
42065 + "BFD_RELOC_SPARC_GLOB_DAT",
42066 + "BFD_RELOC_SPARC_JMP_SLOT",
42067 + "BFD_RELOC_SPARC_RELATIVE",
42068 + "BFD_RELOC_SPARC_UA16",
42069 + "BFD_RELOC_SPARC_UA32",
42070 + "BFD_RELOC_SPARC_UA64",
42071 + "BFD_RELOC_SPARC_BASE13",
42072 + "BFD_RELOC_SPARC_BASE22",
42073 + "BFD_RELOC_SPARC_10",
42074 + "BFD_RELOC_SPARC_11",
42075 + "BFD_RELOC_SPARC_OLO10",
42076 + "BFD_RELOC_SPARC_HH22",
42077 + "BFD_RELOC_SPARC_HM10",
42078 + "BFD_RELOC_SPARC_LM22",
42079 + "BFD_RELOC_SPARC_PC_HH22",
42080 + "BFD_RELOC_SPARC_PC_HM10",
42081 + "BFD_RELOC_SPARC_PC_LM22",
42082 + "BFD_RELOC_SPARC_WDISP16",
42083 + "BFD_RELOC_SPARC_WDISP19",
42084 + "BFD_RELOC_SPARC_7",
42085 + "BFD_RELOC_SPARC_6",
42086 + "BFD_RELOC_SPARC_5",
42087 + "BFD_RELOC_SPARC_PLT32",
42088 + "BFD_RELOC_SPARC_PLT64",
42089 + "BFD_RELOC_SPARC_HIX22",
42090 + "BFD_RELOC_SPARC_LOX10",
42091 + "BFD_RELOC_SPARC_H44",
42092 + "BFD_RELOC_SPARC_M44",
42093 + "BFD_RELOC_SPARC_L44",
42094 + "BFD_RELOC_SPARC_REGISTER",
42095 + "BFD_RELOC_SPARC_REV32",
42096 + "BFD_RELOC_SPARC_TLS_GD_HI22",
42097 + "BFD_RELOC_SPARC_TLS_GD_LO10",
42098 + "BFD_RELOC_SPARC_TLS_GD_ADD",
42099 + "BFD_RELOC_SPARC_TLS_GD_CALL",
42100 + "BFD_RELOC_SPARC_TLS_LDM_HI22",
42101 + "BFD_RELOC_SPARC_TLS_LDM_LO10",
42102 + "BFD_RELOC_SPARC_TLS_LDM_ADD",
42103 + "BFD_RELOC_SPARC_TLS_LDM_CALL",
42104 + "BFD_RELOC_SPARC_TLS_LDO_HIX22",
42105 + "BFD_RELOC_SPARC_TLS_LDO_LOX10",
42106 + "BFD_RELOC_SPARC_TLS_LDO_ADD",
42107 + "BFD_RELOC_SPARC_TLS_IE_HI22",
42108 + "BFD_RELOC_SPARC_TLS_IE_LO10",
42109 + "BFD_RELOC_SPARC_TLS_IE_LD",
42110 + "BFD_RELOC_SPARC_TLS_IE_LDX",
42111 + "BFD_RELOC_SPARC_TLS_IE_ADD",
42112 + "BFD_RELOC_SPARC_TLS_LE_HIX22",
42113 + "BFD_RELOC_SPARC_TLS_LE_LOX10",
42114 + "BFD_RELOC_SPARC_TLS_DTPMOD32",
42115 + "BFD_RELOC_SPARC_TLS_DTPMOD64",
42116 + "BFD_RELOC_SPARC_TLS_DTPOFF32",
42117 + "BFD_RELOC_SPARC_TLS_DTPOFF64",
42118 + "BFD_RELOC_SPARC_TLS_TPOFF32",
42119 + "BFD_RELOC_SPARC_TLS_TPOFF64",
42120 + "BFD_RELOC_SPU_IMM7",
42121 + "BFD_RELOC_SPU_IMM8",
42122 + "BFD_RELOC_SPU_IMM10",
42123 + "BFD_RELOC_SPU_IMM10W",
42124 + "BFD_RELOC_SPU_IMM16",
42125 + "BFD_RELOC_SPU_IMM16W",
42126 + "BFD_RELOC_SPU_IMM18",
42127 + "BFD_RELOC_SPU_PCREL9a",
42128 + "BFD_RELOC_SPU_PCREL9b",
42129 + "BFD_RELOC_SPU_PCREL16",
42130 + "BFD_RELOC_SPU_LO16",
42131 + "BFD_RELOC_SPU_HI16",
42132 + "BFD_RELOC_SPU_PPU32",
42133 + "BFD_RELOC_SPU_PPU64",
42134 + "BFD_RELOC_ALPHA_GPDISP_HI16",
42135 + "BFD_RELOC_ALPHA_GPDISP_LO16",
42136 + "BFD_RELOC_ALPHA_GPDISP",
42137 + "BFD_RELOC_ALPHA_LITERAL",
42138 + "BFD_RELOC_ALPHA_ELF_LITERAL",
42139 + "BFD_RELOC_ALPHA_LITUSE",
42140 + "BFD_RELOC_ALPHA_HINT",
42141 + "BFD_RELOC_ALPHA_LINKAGE",
42142 + "BFD_RELOC_ALPHA_CODEADDR",
42143 + "BFD_RELOC_ALPHA_GPREL_HI16",
42144 + "BFD_RELOC_ALPHA_GPREL_LO16",
42145 + "BFD_RELOC_ALPHA_BRSGP",
42146 + "BFD_RELOC_ALPHA_TLSGD",
42147 + "BFD_RELOC_ALPHA_TLSLDM",
42148 + "BFD_RELOC_ALPHA_DTPMOD64",
42149 + "BFD_RELOC_ALPHA_GOTDTPREL16",
42150 + "BFD_RELOC_ALPHA_DTPREL64",
42151 + "BFD_RELOC_ALPHA_DTPREL_HI16",
42152 + "BFD_RELOC_ALPHA_DTPREL_LO16",
42153 + "BFD_RELOC_ALPHA_DTPREL16",
42154 + "BFD_RELOC_ALPHA_GOTTPREL16",
42155 + "BFD_RELOC_ALPHA_TPREL64",
42156 + "BFD_RELOC_ALPHA_TPREL_HI16",
42157 + "BFD_RELOC_ALPHA_TPREL_LO16",
42158 + "BFD_RELOC_ALPHA_TPREL16",
42159 + "BFD_RELOC_MIPS_JMP",
42160 + "BFD_RELOC_MIPS16_JMP",
42161 + "BFD_RELOC_MIPS16_GPREL",
42162 + "BFD_RELOC_HI16",
42163 + "BFD_RELOC_HI16_S",
42164 + "BFD_RELOC_LO16",
42165 + "BFD_RELOC_HI16_PCREL",
42166 + "BFD_RELOC_HI16_S_PCREL",
42167 + "BFD_RELOC_LO16_PCREL",
42168 + "BFD_RELOC_MIPS16_HI16",
42169 + "BFD_RELOC_MIPS16_HI16_S",
42170 + "BFD_RELOC_MIPS16_LO16",
42171 + "BFD_RELOC_MIPS_LITERAL",
42172 + "BFD_RELOC_MIPS_GOT16",
42173 + "BFD_RELOC_MIPS_CALL16",
42174 + "BFD_RELOC_MIPS_GOT_HI16",
42175 + "BFD_RELOC_MIPS_GOT_LO16",
42176 + "BFD_RELOC_MIPS_CALL_HI16",
42177 + "BFD_RELOC_MIPS_CALL_LO16",
42178 + "BFD_RELOC_MIPS_SUB",
42179 + "BFD_RELOC_MIPS_GOT_PAGE",
42180 + "BFD_RELOC_MIPS_GOT_OFST",
42181 + "BFD_RELOC_MIPS_GOT_DISP",
42182 + "BFD_RELOC_MIPS_SHIFT5",
42183 + "BFD_RELOC_MIPS_SHIFT6",
42184 + "BFD_RELOC_MIPS_INSERT_A",
42185 + "BFD_RELOC_MIPS_INSERT_B",
42186 + "BFD_RELOC_MIPS_DELETE",
42187 + "BFD_RELOC_MIPS_HIGHEST",
42188 + "BFD_RELOC_MIPS_HIGHER",
42189 + "BFD_RELOC_MIPS_SCN_DISP",
42190 + "BFD_RELOC_MIPS_REL16",
42191 + "BFD_RELOC_MIPS_RELGOT",
42192 + "BFD_RELOC_MIPS_JALR",
42193 + "BFD_RELOC_MIPS_TLS_DTPMOD32",
42194 + "BFD_RELOC_MIPS_TLS_DTPREL32",
42195 + "BFD_RELOC_MIPS_TLS_DTPMOD64",
42196 + "BFD_RELOC_MIPS_TLS_DTPREL64",
42197 + "BFD_RELOC_MIPS_TLS_GD",
42198 + "BFD_RELOC_MIPS_TLS_LDM",
42199 + "BFD_RELOC_MIPS_TLS_DTPREL_HI16",
42200 + "BFD_RELOC_MIPS_TLS_DTPREL_LO16",
42201 + "BFD_RELOC_MIPS_TLS_GOTTPREL",
42202 + "BFD_RELOC_MIPS_TLS_TPREL32",
42203 + "BFD_RELOC_MIPS_TLS_TPREL64",
42204 + "BFD_RELOC_MIPS_TLS_TPREL_HI16",
42205 + "BFD_RELOC_MIPS_TLS_TPREL_LO16",
42206 +
42207 + "BFD_RELOC_MIPS_COPY",
42208 + "BFD_RELOC_MIPS_JUMP_SLOT",
42209 +
42210 + "BFD_RELOC_FRV_LABEL16",
42211 + "BFD_RELOC_FRV_LABEL24",
42212 + "BFD_RELOC_FRV_LO16",
42213 + "BFD_RELOC_FRV_HI16",
42214 + "BFD_RELOC_FRV_GPREL12",
42215 + "BFD_RELOC_FRV_GPRELU12",
42216 + "BFD_RELOC_FRV_GPREL32",
42217 + "BFD_RELOC_FRV_GPRELHI",
42218 + "BFD_RELOC_FRV_GPRELLO",
42219 + "BFD_RELOC_FRV_GOT12",
42220 + "BFD_RELOC_FRV_GOTHI",
42221 + "BFD_RELOC_FRV_GOTLO",
42222 + "BFD_RELOC_FRV_FUNCDESC",
42223 + "BFD_RELOC_FRV_FUNCDESC_GOT12",
42224 + "BFD_RELOC_FRV_FUNCDESC_GOTHI",
42225 + "BFD_RELOC_FRV_FUNCDESC_GOTLO",
42226 + "BFD_RELOC_FRV_FUNCDESC_VALUE",
42227 + "BFD_RELOC_FRV_FUNCDESC_GOTOFF12",
42228 + "BFD_RELOC_FRV_FUNCDESC_GOTOFFHI",
42229 + "BFD_RELOC_FRV_FUNCDESC_GOTOFFLO",
42230 + "BFD_RELOC_FRV_GOTOFF12",
42231 + "BFD_RELOC_FRV_GOTOFFHI",
42232 + "BFD_RELOC_FRV_GOTOFFLO",
42233 + "BFD_RELOC_FRV_GETTLSOFF",
42234 + "BFD_RELOC_FRV_TLSDESC_VALUE",
42235 + "BFD_RELOC_FRV_GOTTLSDESC12",
42236 + "BFD_RELOC_FRV_GOTTLSDESCHI",
42237 + "BFD_RELOC_FRV_GOTTLSDESCLO",
42238 + "BFD_RELOC_FRV_TLSMOFF12",
42239 + "BFD_RELOC_FRV_TLSMOFFHI",
42240 + "BFD_RELOC_FRV_TLSMOFFLO",
42241 + "BFD_RELOC_FRV_GOTTLSOFF12",
42242 + "BFD_RELOC_FRV_GOTTLSOFFHI",
42243 + "BFD_RELOC_FRV_GOTTLSOFFLO",
42244 + "BFD_RELOC_FRV_TLSOFF",
42245 + "BFD_RELOC_FRV_TLSDESC_RELAX",
42246 + "BFD_RELOC_FRV_GETTLSOFF_RELAX",
42247 + "BFD_RELOC_FRV_TLSOFF_RELAX",
42248 + "BFD_RELOC_FRV_TLSMOFF",
42249 +
42250 + "BFD_RELOC_MN10300_GOTOFF24",
42251 + "BFD_RELOC_MN10300_GOT32",
42252 + "BFD_RELOC_MN10300_GOT24",
42253 + "BFD_RELOC_MN10300_GOT16",
42254 + "BFD_RELOC_MN10300_COPY",
42255 + "BFD_RELOC_MN10300_GLOB_DAT",
42256 + "BFD_RELOC_MN10300_JMP_SLOT",
42257 + "BFD_RELOC_MN10300_RELATIVE",
42258 +
42259 + "BFD_RELOC_386_GOT32",
42260 + "BFD_RELOC_386_PLT32",
42261 + "BFD_RELOC_386_COPY",
42262 + "BFD_RELOC_386_GLOB_DAT",
42263 + "BFD_RELOC_386_JUMP_SLOT",
42264 + "BFD_RELOC_386_RELATIVE",
42265 + "BFD_RELOC_386_GOTOFF",
42266 + "BFD_RELOC_386_GOTPC",
42267 + "BFD_RELOC_386_TLS_TPOFF",
42268 + "BFD_RELOC_386_TLS_IE",
42269 + "BFD_RELOC_386_TLS_GOTIE",
42270 + "BFD_RELOC_386_TLS_LE",
42271 + "BFD_RELOC_386_TLS_GD",
42272 + "BFD_RELOC_386_TLS_LDM",
42273 + "BFD_RELOC_386_TLS_LDO_32",
42274 + "BFD_RELOC_386_TLS_IE_32",
42275 + "BFD_RELOC_386_TLS_LE_32",
42276 + "BFD_RELOC_386_TLS_DTPMOD32",
42277 + "BFD_RELOC_386_TLS_DTPOFF32",
42278 + "BFD_RELOC_386_TLS_TPOFF32",
42279 + "BFD_RELOC_386_TLS_GOTDESC",
42280 + "BFD_RELOC_386_TLS_DESC_CALL",
42281 + "BFD_RELOC_386_TLS_DESC",
42282 + "BFD_RELOC_X86_64_GOT32",
42283 + "BFD_RELOC_X86_64_PLT32",
42284 + "BFD_RELOC_X86_64_COPY",
42285 + "BFD_RELOC_X86_64_GLOB_DAT",
42286 + "BFD_RELOC_X86_64_JUMP_SLOT",
42287 + "BFD_RELOC_X86_64_RELATIVE",
42288 + "BFD_RELOC_X86_64_GOTPCREL",
42289 + "BFD_RELOC_X86_64_32S",
42290 + "BFD_RELOC_X86_64_DTPMOD64",
42291 + "BFD_RELOC_X86_64_DTPOFF64",
42292 + "BFD_RELOC_X86_64_TPOFF64",
42293 + "BFD_RELOC_X86_64_TLSGD",
42294 + "BFD_RELOC_X86_64_TLSLD",
42295 + "BFD_RELOC_X86_64_DTPOFF32",
42296 + "BFD_RELOC_X86_64_GOTTPOFF",
42297 + "BFD_RELOC_X86_64_TPOFF32",
42298 + "BFD_RELOC_X86_64_GOTOFF64",
42299 + "BFD_RELOC_X86_64_GOTPC32",
42300 + "BFD_RELOC_X86_64_GOT64",
42301 + "BFD_RELOC_X86_64_GOTPCREL64",
42302 + "BFD_RELOC_X86_64_GOTPC64",
42303 + "BFD_RELOC_X86_64_GOTPLT64",
42304 + "BFD_RELOC_X86_64_PLTOFF64",
42305 + "BFD_RELOC_X86_64_GOTPC32_TLSDESC",
42306 + "BFD_RELOC_X86_64_TLSDESC_CALL",
42307 + "BFD_RELOC_X86_64_TLSDESC",
42308 + "BFD_RELOC_NS32K_IMM_8",
42309 + "BFD_RELOC_NS32K_IMM_16",
42310 + "BFD_RELOC_NS32K_IMM_32",
42311 + "BFD_RELOC_NS32K_IMM_8_PCREL",
42312 + "BFD_RELOC_NS32K_IMM_16_PCREL",
42313 + "BFD_RELOC_NS32K_IMM_32_PCREL",
42314 + "BFD_RELOC_NS32K_DISP_8",
42315 + "BFD_RELOC_NS32K_DISP_16",
42316 + "BFD_RELOC_NS32K_DISP_32",
42317 + "BFD_RELOC_NS32K_DISP_8_PCREL",
42318 + "BFD_RELOC_NS32K_DISP_16_PCREL",
42319 + "BFD_RELOC_NS32K_DISP_32_PCREL",
42320 + "BFD_RELOC_PDP11_DISP_8_PCREL",
42321 + "BFD_RELOC_PDP11_DISP_6_PCREL",
42322 + "BFD_RELOC_PJ_CODE_HI16",
42323 + "BFD_RELOC_PJ_CODE_LO16",
42324 + "BFD_RELOC_PJ_CODE_DIR16",
42325 + "BFD_RELOC_PJ_CODE_DIR32",
42326 + "BFD_RELOC_PJ_CODE_REL16",
42327 + "BFD_RELOC_PJ_CODE_REL32",
42328 + "BFD_RELOC_PPC_B26",
42329 + "BFD_RELOC_PPC_BA26",
42330 + "BFD_RELOC_PPC_TOC16",
42331 + "BFD_RELOC_PPC_B16",
42332 + "BFD_RELOC_PPC_B16_BRTAKEN",
42333 + "BFD_RELOC_PPC_B16_BRNTAKEN",
42334 + "BFD_RELOC_PPC_BA16",
42335 + "BFD_RELOC_PPC_BA16_BRTAKEN",
42336 + "BFD_RELOC_PPC_BA16_BRNTAKEN",
42337 + "BFD_RELOC_PPC_COPY",
42338 + "BFD_RELOC_PPC_GLOB_DAT",
42339 + "BFD_RELOC_PPC_JMP_SLOT",
42340 + "BFD_RELOC_PPC_RELATIVE",
42341 + "BFD_RELOC_PPC_LOCAL24PC",
42342 + "BFD_RELOC_PPC_EMB_NADDR32",
42343 + "BFD_RELOC_PPC_EMB_NADDR16",
42344 + "BFD_RELOC_PPC_EMB_NADDR16_LO",
42345 + "BFD_RELOC_PPC_EMB_NADDR16_HI",
42346 + "BFD_RELOC_PPC_EMB_NADDR16_HA",
42347 + "BFD_RELOC_PPC_EMB_SDAI16",
42348 + "BFD_RELOC_PPC_EMB_SDA2I16",
42349 + "BFD_RELOC_PPC_EMB_SDA2REL",
42350 + "BFD_RELOC_PPC_EMB_SDA21",
42351 + "BFD_RELOC_PPC_EMB_MRKREF",
42352 + "BFD_RELOC_PPC_EMB_RELSEC16",
42353 + "BFD_RELOC_PPC_EMB_RELST_LO",
42354 + "BFD_RELOC_PPC_EMB_RELST_HI",
42355 + "BFD_RELOC_PPC_EMB_RELST_HA",
42356 + "BFD_RELOC_PPC_EMB_BIT_FLD",
42357 + "BFD_RELOC_PPC_EMB_RELSDA",
42358 + "BFD_RELOC_PPC64_HIGHER",
42359 + "BFD_RELOC_PPC64_HIGHER_S",
42360 + "BFD_RELOC_PPC64_HIGHEST",
42361 + "BFD_RELOC_PPC64_HIGHEST_S",
42362 + "BFD_RELOC_PPC64_TOC16_LO",
42363 + "BFD_RELOC_PPC64_TOC16_HI",
42364 + "BFD_RELOC_PPC64_TOC16_HA",
42365 + "BFD_RELOC_PPC64_TOC",
42366 + "BFD_RELOC_PPC64_PLTGOT16",
42367 + "BFD_RELOC_PPC64_PLTGOT16_LO",
42368 + "BFD_RELOC_PPC64_PLTGOT16_HI",
42369 + "BFD_RELOC_PPC64_PLTGOT16_HA",
42370 + "BFD_RELOC_PPC64_ADDR16_DS",
42371 + "BFD_RELOC_PPC64_ADDR16_LO_DS",
42372 + "BFD_RELOC_PPC64_GOT16_DS",
42373 + "BFD_RELOC_PPC64_GOT16_LO_DS",
42374 + "BFD_RELOC_PPC64_PLT16_LO_DS",
42375 + "BFD_RELOC_PPC64_SECTOFF_DS",
42376 + "BFD_RELOC_PPC64_SECTOFF_LO_DS",
42377 + "BFD_RELOC_PPC64_TOC16_DS",
42378 + "BFD_RELOC_PPC64_TOC16_LO_DS",
42379 + "BFD_RELOC_PPC64_PLTGOT16_DS",
42380 + "BFD_RELOC_PPC64_PLTGOT16_LO_DS",
42381 + "BFD_RELOC_PPC_TLS",
42382 + "BFD_RELOC_PPC_DTPMOD",
42383 + "BFD_RELOC_PPC_TPREL16",
42384 + "BFD_RELOC_PPC_TPREL16_LO",
42385 + "BFD_RELOC_PPC_TPREL16_HI",
42386 + "BFD_RELOC_PPC_TPREL16_HA",
42387 + "BFD_RELOC_PPC_TPREL",
42388 + "BFD_RELOC_PPC_DTPREL16",
42389 + "BFD_RELOC_PPC_DTPREL16_LO",
42390 + "BFD_RELOC_PPC_DTPREL16_HI",
42391 + "BFD_RELOC_PPC_DTPREL16_HA",
42392 + "BFD_RELOC_PPC_DTPREL",
42393 + "BFD_RELOC_PPC_GOT_TLSGD16",
42394 + "BFD_RELOC_PPC_GOT_TLSGD16_LO",
42395 + "BFD_RELOC_PPC_GOT_TLSGD16_HI",
42396 + "BFD_RELOC_PPC_GOT_TLSGD16_HA",
42397 + "BFD_RELOC_PPC_GOT_TLSLD16",
42398 + "BFD_RELOC_PPC_GOT_TLSLD16_LO",
42399 + "BFD_RELOC_PPC_GOT_TLSLD16_HI",
42400 + "BFD_RELOC_PPC_GOT_TLSLD16_HA",
42401 + "BFD_RELOC_PPC_GOT_TPREL16",
42402 + "BFD_RELOC_PPC_GOT_TPREL16_LO",
42403 + "BFD_RELOC_PPC_GOT_TPREL16_HI",
42404 + "BFD_RELOC_PPC_GOT_TPREL16_HA",
42405 + "BFD_RELOC_PPC_GOT_DTPREL16",
42406 + "BFD_RELOC_PPC_GOT_DTPREL16_LO",
42407 + "BFD_RELOC_PPC_GOT_DTPREL16_HI",
42408 + "BFD_RELOC_PPC_GOT_DTPREL16_HA",
42409 + "BFD_RELOC_PPC64_TPREL16_DS",
42410 + "BFD_RELOC_PPC64_TPREL16_LO_DS",
42411 + "BFD_RELOC_PPC64_TPREL16_HIGHER",
42412 + "BFD_RELOC_PPC64_TPREL16_HIGHERA",
42413 + "BFD_RELOC_PPC64_TPREL16_HIGHEST",
42414 + "BFD_RELOC_PPC64_TPREL16_HIGHESTA",
42415 + "BFD_RELOC_PPC64_DTPREL16_DS",
42416 + "BFD_RELOC_PPC64_DTPREL16_LO_DS",
42417 + "BFD_RELOC_PPC64_DTPREL16_HIGHER",
42418 + "BFD_RELOC_PPC64_DTPREL16_HIGHERA",
42419 + "BFD_RELOC_PPC64_DTPREL16_HIGHEST",
42420 + "BFD_RELOC_PPC64_DTPREL16_HIGHESTA",
42421 + "BFD_RELOC_I370_D12",
42422 + "BFD_RELOC_CTOR",
42423 + "BFD_RELOC_ARM_PCREL_BRANCH",
42424 + "BFD_RELOC_ARM_PCREL_BLX",
42425 + "BFD_RELOC_THUMB_PCREL_BLX",
42426 + "BFD_RELOC_ARM_PCREL_CALL",
42427 + "BFD_RELOC_ARM_PCREL_JUMP",
42428 + "BFD_RELOC_THUMB_PCREL_BRANCH7",
42429 + "BFD_RELOC_THUMB_PCREL_BRANCH9",
42430 + "BFD_RELOC_THUMB_PCREL_BRANCH12",
42431 + "BFD_RELOC_THUMB_PCREL_BRANCH20",
42432 + "BFD_RELOC_THUMB_PCREL_BRANCH23",
42433 + "BFD_RELOC_THUMB_PCREL_BRANCH25",
42434 + "BFD_RELOC_ARM_OFFSET_IMM",
42435 + "BFD_RELOC_ARM_THUMB_OFFSET",
42436 + "BFD_RELOC_ARM_TARGET1",
42437 + "BFD_RELOC_ARM_ROSEGREL32",
42438 + "BFD_RELOC_ARM_SBREL32",
42439 + "BFD_RELOC_ARM_TARGET2",
42440 + "BFD_RELOC_ARM_PREL31",
42441 + "BFD_RELOC_ARM_MOVW",
42442 + "BFD_RELOC_ARM_MOVT",
42443 + "BFD_RELOC_ARM_MOVW_PCREL",
42444 + "BFD_RELOC_ARM_MOVT_PCREL",
42445 + "BFD_RELOC_ARM_THUMB_MOVW",
42446 + "BFD_RELOC_ARM_THUMB_MOVT",
42447 + "BFD_RELOC_ARM_THUMB_MOVW_PCREL",
42448 + "BFD_RELOC_ARM_THUMB_MOVT_PCREL",
42449 + "BFD_RELOC_ARM_JUMP_SLOT",
42450 + "BFD_RELOC_ARM_GLOB_DAT",
42451 + "BFD_RELOC_ARM_GOT32",
42452 + "BFD_RELOC_ARM_PLT32",
42453 + "BFD_RELOC_ARM_RELATIVE",
42454 + "BFD_RELOC_ARM_GOTOFF",
42455 + "BFD_RELOC_ARM_GOTPC",
42456 + "BFD_RELOC_ARM_TLS_GD32",
42457 + "BFD_RELOC_ARM_TLS_LDO32",
42458 + "BFD_RELOC_ARM_TLS_LDM32",
42459 + "BFD_RELOC_ARM_TLS_DTPOFF32",
42460 + "BFD_RELOC_ARM_TLS_DTPMOD32",
42461 + "BFD_RELOC_ARM_TLS_TPOFF32",
42462 + "BFD_RELOC_ARM_TLS_IE32",
42463 + "BFD_RELOC_ARM_TLS_LE32",
42464 + "BFD_RELOC_ARM_ALU_PC_G0_NC",
42465 + "BFD_RELOC_ARM_ALU_PC_G0",
42466 + "BFD_RELOC_ARM_ALU_PC_G1_NC",
42467 + "BFD_RELOC_ARM_ALU_PC_G1",
42468 + "BFD_RELOC_ARM_ALU_PC_G2",
42469 + "BFD_RELOC_ARM_LDR_PC_G0",
42470 + "BFD_RELOC_ARM_LDR_PC_G1",
42471 + "BFD_RELOC_ARM_LDR_PC_G2",
42472 + "BFD_RELOC_ARM_LDRS_PC_G0",
42473 + "BFD_RELOC_ARM_LDRS_PC_G1",
42474 + "BFD_RELOC_ARM_LDRS_PC_G2",
42475 + "BFD_RELOC_ARM_LDC_PC_G0",
42476 + "BFD_RELOC_ARM_LDC_PC_G1",
42477 + "BFD_RELOC_ARM_LDC_PC_G2",
42478 + "BFD_RELOC_ARM_ALU_SB_G0_NC",
42479 + "BFD_RELOC_ARM_ALU_SB_G0",
42480 + "BFD_RELOC_ARM_ALU_SB_G1_NC",
42481 + "BFD_RELOC_ARM_ALU_SB_G1",
42482 + "BFD_RELOC_ARM_ALU_SB_G2",
42483 + "BFD_RELOC_ARM_LDR_SB_G0",
42484 + "BFD_RELOC_ARM_LDR_SB_G1",
42485 + "BFD_RELOC_ARM_LDR_SB_G2",
42486 + "BFD_RELOC_ARM_LDRS_SB_G0",
42487 + "BFD_RELOC_ARM_LDRS_SB_G1",
42488 + "BFD_RELOC_ARM_LDRS_SB_G2",
42489 + "BFD_RELOC_ARM_LDC_SB_G0",
42490 + "BFD_RELOC_ARM_LDC_SB_G1",
42491 + "BFD_RELOC_ARM_LDC_SB_G2",
42492 + "BFD_RELOC_ARM_IMMEDIATE",
42493 + "BFD_RELOC_ARM_ADRL_IMMEDIATE",
42494 + "BFD_RELOC_ARM_T32_IMMEDIATE",
42495 + "BFD_RELOC_ARM_T32_ADD_IMM",
42496 + "BFD_RELOC_ARM_T32_IMM12",
42497 + "BFD_RELOC_ARM_T32_ADD_PC12",
42498 + "BFD_RELOC_ARM_SHIFT_IMM",
42499 + "BFD_RELOC_ARM_SMC",
42500 + "BFD_RELOC_ARM_SWI",
42501 + "BFD_RELOC_ARM_MULTI",
42502 + "BFD_RELOC_ARM_CP_OFF_IMM",
42503 + "BFD_RELOC_ARM_CP_OFF_IMM_S2",
42504 + "BFD_RELOC_ARM_T32_CP_OFF_IMM",
42505 + "BFD_RELOC_ARM_T32_CP_OFF_IMM_S2",
42506 + "BFD_RELOC_ARM_ADR_IMM",
42507 + "BFD_RELOC_ARM_LDR_IMM",
42508 + "BFD_RELOC_ARM_LITERAL",
42509 + "BFD_RELOC_ARM_IN_POOL",
42510 + "BFD_RELOC_ARM_OFFSET_IMM8",
42511 + "BFD_RELOC_ARM_T32_OFFSET_U8",
42512 + "BFD_RELOC_ARM_T32_OFFSET_IMM",
42513 + "BFD_RELOC_ARM_HWLITERAL",
42514 + "BFD_RELOC_ARM_THUMB_ADD",
42515 + "BFD_RELOC_ARM_THUMB_IMM",
42516 + "BFD_RELOC_ARM_THUMB_SHIFT",
42517 + "BFD_RELOC_SH_PCDISP8BY2",
42518 + "BFD_RELOC_SH_PCDISP12BY2",
42519 + "BFD_RELOC_SH_IMM3",
42520 + "BFD_RELOC_SH_IMM3U",
42521 + "BFD_RELOC_SH_DISP12",
42522 + "BFD_RELOC_SH_DISP12BY2",
42523 + "BFD_RELOC_SH_DISP12BY4",
42524 + "BFD_RELOC_SH_DISP12BY8",
42525 + "BFD_RELOC_SH_DISP20",
42526 + "BFD_RELOC_SH_DISP20BY8",
42527 + "BFD_RELOC_SH_IMM4",
42528 + "BFD_RELOC_SH_IMM4BY2",
42529 + "BFD_RELOC_SH_IMM4BY4",
42530 + "BFD_RELOC_SH_IMM8",
42531 + "BFD_RELOC_SH_IMM8BY2",
42532 + "BFD_RELOC_SH_IMM8BY4",
42533 + "BFD_RELOC_SH_PCRELIMM8BY2",
42534 + "BFD_RELOC_SH_PCRELIMM8BY4",
42535 + "BFD_RELOC_SH_SWITCH16",
42536 + "BFD_RELOC_SH_SWITCH32",
42537 + "BFD_RELOC_SH_USES",
42538 + "BFD_RELOC_SH_COUNT",
42539 + "BFD_RELOC_SH_ALIGN",
42540 + "BFD_RELOC_SH_CODE",
42541 + "BFD_RELOC_SH_DATA",
42542 + "BFD_RELOC_SH_LABEL",
42543 + "BFD_RELOC_SH_LOOP_START",
42544 + "BFD_RELOC_SH_LOOP_END",
42545 + "BFD_RELOC_SH_COPY",
42546 + "BFD_RELOC_SH_GLOB_DAT",
42547 + "BFD_RELOC_SH_JMP_SLOT",
42548 + "BFD_RELOC_SH_RELATIVE",
42549 + "BFD_RELOC_SH_GOTPC",
42550 + "BFD_RELOC_SH_GOT_LOW16",
42551 + "BFD_RELOC_SH_GOT_MEDLOW16",
42552 + "BFD_RELOC_SH_GOT_MEDHI16",
42553 + "BFD_RELOC_SH_GOT_HI16",
42554 + "BFD_RELOC_SH_GOTPLT_LOW16",
42555 + "BFD_RELOC_SH_GOTPLT_MEDLOW16",
42556 + "BFD_RELOC_SH_GOTPLT_MEDHI16",
42557 + "BFD_RELOC_SH_GOTPLT_HI16",
42558 + "BFD_RELOC_SH_PLT_LOW16",
42559 + "BFD_RELOC_SH_PLT_MEDLOW16",
42560 + "BFD_RELOC_SH_PLT_MEDHI16",
42561 + "BFD_RELOC_SH_PLT_HI16",
42562 + "BFD_RELOC_SH_GOTOFF_LOW16",
42563 + "BFD_RELOC_SH_GOTOFF_MEDLOW16",
42564 + "BFD_RELOC_SH_GOTOFF_MEDHI16",
42565 + "BFD_RELOC_SH_GOTOFF_HI16",
42566 + "BFD_RELOC_SH_GOTPC_LOW16",
42567 + "BFD_RELOC_SH_GOTPC_MEDLOW16",
42568 + "BFD_RELOC_SH_GOTPC_MEDHI16",
42569 + "BFD_RELOC_SH_GOTPC_HI16",
42570 + "BFD_RELOC_SH_COPY64",
42571 + "BFD_RELOC_SH_GLOB_DAT64",
42572 + "BFD_RELOC_SH_JMP_SLOT64",
42573 + "BFD_RELOC_SH_RELATIVE64",
42574 + "BFD_RELOC_SH_GOT10BY4",
42575 + "BFD_RELOC_SH_GOT10BY8",
42576 + "BFD_RELOC_SH_GOTPLT10BY4",
42577 + "BFD_RELOC_SH_GOTPLT10BY8",
42578 + "BFD_RELOC_SH_GOTPLT32",
42579 + "BFD_RELOC_SH_SHMEDIA_CODE",
42580 + "BFD_RELOC_SH_IMMU5",
42581 + "BFD_RELOC_SH_IMMS6",
42582 + "BFD_RELOC_SH_IMMS6BY32",
42583 + "BFD_RELOC_SH_IMMU6",
42584 + "BFD_RELOC_SH_IMMS10",
42585 + "BFD_RELOC_SH_IMMS10BY2",
42586 + "BFD_RELOC_SH_IMMS10BY4",
42587 + "BFD_RELOC_SH_IMMS10BY8",
42588 + "BFD_RELOC_SH_IMMS16",
42589 + "BFD_RELOC_SH_IMMU16",
42590 + "BFD_RELOC_SH_IMM_LOW16",
42591 + "BFD_RELOC_SH_IMM_LOW16_PCREL",
42592 + "BFD_RELOC_SH_IMM_MEDLOW16",
42593 + "BFD_RELOC_SH_IMM_MEDLOW16_PCREL",
42594 + "BFD_RELOC_SH_IMM_MEDHI16",
42595 + "BFD_RELOC_SH_IMM_MEDHI16_PCREL",
42596 + "BFD_RELOC_SH_IMM_HI16",
42597 + "BFD_RELOC_SH_IMM_HI16_PCREL",
42598 + "BFD_RELOC_SH_PT_16",
42599 + "BFD_RELOC_SH_TLS_GD_32",
42600 + "BFD_RELOC_SH_TLS_LD_32",
42601 + "BFD_RELOC_SH_TLS_LDO_32",
42602 + "BFD_RELOC_SH_TLS_IE_32",
42603 + "BFD_RELOC_SH_TLS_LE_32",
42604 + "BFD_RELOC_SH_TLS_DTPMOD32",
42605 + "BFD_RELOC_SH_TLS_DTPOFF32",
42606 + "BFD_RELOC_SH_TLS_TPOFF32",
42607 + "BFD_RELOC_ARC_B22_PCREL",
42608 + "BFD_RELOC_ARC_B26",
42609 + "BFD_RELOC_BFIN_16_IMM",
42610 + "BFD_RELOC_BFIN_16_HIGH",
42611 + "BFD_RELOC_BFIN_4_PCREL",
42612 + "BFD_RELOC_BFIN_5_PCREL",
42613 + "BFD_RELOC_BFIN_16_LOW",
42614 + "BFD_RELOC_BFIN_10_PCREL",
42615 + "BFD_RELOC_BFIN_11_PCREL",
42616 + "BFD_RELOC_BFIN_12_PCREL_JUMP",
42617 + "BFD_RELOC_BFIN_12_PCREL_JUMP_S",
42618 + "BFD_RELOC_BFIN_24_PCREL_CALL_X",
42619 + "BFD_RELOC_BFIN_24_PCREL_JUMP_L",
42620 + "BFD_RELOC_BFIN_GOT17M4",
42621 + "BFD_RELOC_BFIN_GOTHI",
42622 + "BFD_RELOC_BFIN_GOTLO",
42623 + "BFD_RELOC_BFIN_FUNCDESC",
42624 + "BFD_RELOC_BFIN_FUNCDESC_GOT17M4",
42625 + "BFD_RELOC_BFIN_FUNCDESC_GOTHI",
42626 + "BFD_RELOC_BFIN_FUNCDESC_GOTLO",
42627 + "BFD_RELOC_BFIN_FUNCDESC_VALUE",
42628 + "BFD_RELOC_BFIN_FUNCDESC_GOTOFF17M4",
42629 + "BFD_RELOC_BFIN_FUNCDESC_GOTOFFHI",
42630 + "BFD_RELOC_BFIN_FUNCDESC_GOTOFFLO",
42631 + "BFD_RELOC_BFIN_GOTOFF17M4",
42632 + "BFD_RELOC_BFIN_GOTOFFHI",
42633 + "BFD_RELOC_BFIN_GOTOFFLO",
42634 + "BFD_RELOC_BFIN_GOT",
42635 + "BFD_RELOC_BFIN_PLTPC",
42636 + "BFD_ARELOC_BFIN_PUSH",
42637 + "BFD_ARELOC_BFIN_CONST",
42638 + "BFD_ARELOC_BFIN_ADD",
42639 + "BFD_ARELOC_BFIN_SUB",
42640 + "BFD_ARELOC_BFIN_MULT",
42641 + "BFD_ARELOC_BFIN_DIV",
42642 + "BFD_ARELOC_BFIN_MOD",
42643 + "BFD_ARELOC_BFIN_LSHIFT",
42644 + "BFD_ARELOC_BFIN_RSHIFT",
42645 + "BFD_ARELOC_BFIN_AND",
42646 + "BFD_ARELOC_BFIN_OR",
42647 + "BFD_ARELOC_BFIN_XOR",
42648 + "BFD_ARELOC_BFIN_LAND",
42649 + "BFD_ARELOC_BFIN_LOR",
42650 + "BFD_ARELOC_BFIN_LEN",
42651 + "BFD_ARELOC_BFIN_NEG",
42652 + "BFD_ARELOC_BFIN_COMP",
42653 + "BFD_ARELOC_BFIN_PAGE",
42654 + "BFD_ARELOC_BFIN_HWPAGE",
42655 + "BFD_ARELOC_BFIN_ADDR",
42656 + "BFD_RELOC_D10V_10_PCREL_R",
42657 + "BFD_RELOC_D10V_10_PCREL_L",
42658 + "BFD_RELOC_D10V_18",
42659 + "BFD_RELOC_D10V_18_PCREL",
42660 + "BFD_RELOC_D30V_6",
42661 + "BFD_RELOC_D30V_9_PCREL",
42662 + "BFD_RELOC_D30V_9_PCREL_R",
42663 + "BFD_RELOC_D30V_15",
42664 + "BFD_RELOC_D30V_15_PCREL",
42665 + "BFD_RELOC_D30V_15_PCREL_R",
42666 + "BFD_RELOC_D30V_21",
42667 + "BFD_RELOC_D30V_21_PCREL",
42668 + "BFD_RELOC_D30V_21_PCREL_R",
42669 + "BFD_RELOC_D30V_32",
42670 + "BFD_RELOC_D30V_32_PCREL",
42671 + "BFD_RELOC_DLX_HI16_S",
42672 + "BFD_RELOC_DLX_LO16",
42673 + "BFD_RELOC_DLX_JMP26",
42674 + "BFD_RELOC_M32C_HI8",
42675 + "BFD_RELOC_M32C_RL_JUMP",
42676 + "BFD_RELOC_M32C_RL_1ADDR",
42677 + "BFD_RELOC_M32C_RL_2ADDR",
42678 + "BFD_RELOC_M32R_24",
42679 + "BFD_RELOC_M32R_10_PCREL",
42680 + "BFD_RELOC_M32R_18_PCREL",
42681 + "BFD_RELOC_M32R_26_PCREL",
42682 + "BFD_RELOC_M32R_HI16_ULO",
42683 + "BFD_RELOC_M32R_HI16_SLO",
42684 + "BFD_RELOC_M32R_LO16",
42685 + "BFD_RELOC_M32R_SDA16",
42686 + "BFD_RELOC_M32R_GOT24",
42687 + "BFD_RELOC_M32R_26_PLTREL",
42688 + "BFD_RELOC_M32R_COPY",
42689 + "BFD_RELOC_M32R_GLOB_DAT",
42690 + "BFD_RELOC_M32R_JMP_SLOT",
42691 + "BFD_RELOC_M32R_RELATIVE",
42692 + "BFD_RELOC_M32R_GOTOFF",
42693 + "BFD_RELOC_M32R_GOTOFF_HI_ULO",
42694 + "BFD_RELOC_M32R_GOTOFF_HI_SLO",
42695 + "BFD_RELOC_M32R_GOTOFF_LO",
42696 + "BFD_RELOC_M32R_GOTPC24",
42697 + "BFD_RELOC_M32R_GOT16_HI_ULO",
42698 + "BFD_RELOC_M32R_GOT16_HI_SLO",
42699 + "BFD_RELOC_M32R_GOT16_LO",
42700 + "BFD_RELOC_M32R_GOTPC_HI_ULO",
42701 + "BFD_RELOC_M32R_GOTPC_HI_SLO",
42702 + "BFD_RELOC_M32R_GOTPC_LO",
42703 + "BFD_RELOC_V850_9_PCREL",
42704 + "BFD_RELOC_V850_22_PCREL",
42705 + "BFD_RELOC_V850_SDA_16_16_OFFSET",
42706 + "BFD_RELOC_V850_SDA_15_16_OFFSET",
42707 + "BFD_RELOC_V850_ZDA_16_16_OFFSET",
42708 + "BFD_RELOC_V850_ZDA_15_16_OFFSET",
42709 + "BFD_RELOC_V850_TDA_6_8_OFFSET",
42710 + "BFD_RELOC_V850_TDA_7_8_OFFSET",
42711 + "BFD_RELOC_V850_TDA_7_7_OFFSET",
42712 + "BFD_RELOC_V850_TDA_16_16_OFFSET",
42713 + "BFD_RELOC_V850_TDA_4_5_OFFSET",
42714 + "BFD_RELOC_V850_TDA_4_4_OFFSET",
42715 + "BFD_RELOC_V850_SDA_16_16_SPLIT_OFFSET",
42716 + "BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET",
42717 + "BFD_RELOC_V850_CALLT_6_7_OFFSET",
42718 + "BFD_RELOC_V850_CALLT_16_16_OFFSET",
42719 + "BFD_RELOC_V850_LONGCALL",
42720 + "BFD_RELOC_V850_LONGJUMP",
42721 + "BFD_RELOC_V850_ALIGN",
42722 + "BFD_RELOC_V850_LO16_SPLIT_OFFSET",
42723 + "BFD_RELOC_MN10300_32_PCREL",
42724 + "BFD_RELOC_MN10300_16_PCREL",
42725 + "BFD_RELOC_TIC30_LDP",
42726 + "BFD_RELOC_TIC54X_PARTLS7",
42727 + "BFD_RELOC_TIC54X_PARTMS9",
42728 + "BFD_RELOC_TIC54X_23",
42729 + "BFD_RELOC_TIC54X_16_OF_23",
42730 + "BFD_RELOC_TIC54X_MS7_OF_23",
42731 + "BFD_RELOC_FR30_48",
42732 + "BFD_RELOC_FR30_20",
42733 + "BFD_RELOC_FR30_6_IN_4",
42734 + "BFD_RELOC_FR30_8_IN_8",
42735 + "BFD_RELOC_FR30_9_IN_8",
42736 + "BFD_RELOC_FR30_10_IN_8",
42737 + "BFD_RELOC_FR30_9_PCREL",
42738 + "BFD_RELOC_FR30_12_PCREL",
42739 + "BFD_RELOC_MCORE_PCREL_IMM8BY4",
42740 + "BFD_RELOC_MCORE_PCREL_IMM11BY2",
42741 + "BFD_RELOC_MCORE_PCREL_IMM4BY2",
42742 + "BFD_RELOC_MCORE_PCREL_32",
42743 + "BFD_RELOC_MCORE_PCREL_JSR_IMM11BY2",
42744 + "BFD_RELOC_MCORE_RVA",
42745 + "BFD_RELOC_MEP_8",
42746 + "BFD_RELOC_MEP_16",
42747 + "BFD_RELOC_MEP_32",
42748 + "BFD_RELOC_MEP_PCREL8A2",
42749 + "BFD_RELOC_MEP_PCREL12A2",
42750 + "BFD_RELOC_MEP_PCREL17A2",
42751 + "BFD_RELOC_MEP_PCREL24A2",
42752 + "BFD_RELOC_MEP_PCABS24A2",
42753 + "BFD_RELOC_MEP_LOW16",
42754 + "BFD_RELOC_MEP_HI16U",
42755 + "BFD_RELOC_MEP_HI16S",
42756 + "BFD_RELOC_MEP_GPREL",
42757 + "BFD_RELOC_MEP_TPREL",
42758 + "BFD_RELOC_MEP_TPREL7",
42759 + "BFD_RELOC_MEP_TPREL7A2",
42760 + "BFD_RELOC_MEP_TPREL7A4",
42761 + "BFD_RELOC_MEP_UIMM24",
42762 + "BFD_RELOC_MEP_ADDR24A4",
42763 + "BFD_RELOC_MEP_GNU_VTINHERIT",
42764 + "BFD_RELOC_MEP_GNU_VTENTRY",
42765 +
42766 + "BFD_RELOC_MMIX_GETA",
42767 + "BFD_RELOC_MMIX_GETA_1",
42768 + "BFD_RELOC_MMIX_GETA_2",
42769 + "BFD_RELOC_MMIX_GETA_3",
42770 + "BFD_RELOC_MMIX_CBRANCH",
42771 + "BFD_RELOC_MMIX_CBRANCH_J",
42772 + "BFD_RELOC_MMIX_CBRANCH_1",
42773 + "BFD_RELOC_MMIX_CBRANCH_2",
42774 + "BFD_RELOC_MMIX_CBRANCH_3",
42775 + "BFD_RELOC_MMIX_PUSHJ",
42776 + "BFD_RELOC_MMIX_PUSHJ_1",
42777 + "BFD_RELOC_MMIX_PUSHJ_2",
42778 + "BFD_RELOC_MMIX_PUSHJ_3",
42779 + "BFD_RELOC_MMIX_PUSHJ_STUBBABLE",
42780 + "BFD_RELOC_MMIX_JMP",
42781 + "BFD_RELOC_MMIX_JMP_1",
42782 + "BFD_RELOC_MMIX_JMP_2",
42783 + "BFD_RELOC_MMIX_JMP_3",
42784 + "BFD_RELOC_MMIX_ADDR19",
42785 + "BFD_RELOC_MMIX_ADDR27",
42786 + "BFD_RELOC_MMIX_REG_OR_BYTE",
42787 + "BFD_RELOC_MMIX_REG",
42788 + "BFD_RELOC_MMIX_BASE_PLUS_OFFSET",
42789 + "BFD_RELOC_MMIX_LOCAL",
42790 + "BFD_RELOC_AVR_7_PCREL",
42791 + "BFD_RELOC_AVR_13_PCREL",
42792 + "BFD_RELOC_AVR_16_PM",
42793 + "BFD_RELOC_AVR_LO8_LDI",
42794 + "BFD_RELOC_AVR_HI8_LDI",
42795 + "BFD_RELOC_AVR_HH8_LDI",
42796 + "BFD_RELOC_AVR_MS8_LDI",
42797 + "BFD_RELOC_AVR_LO8_LDI_NEG",
42798 + "BFD_RELOC_AVR_HI8_LDI_NEG",
42799 + "BFD_RELOC_AVR_HH8_LDI_NEG",
42800 + "BFD_RELOC_AVR_MS8_LDI_NEG",
42801 + "BFD_RELOC_AVR_LO8_LDI_PM",
42802 + "BFD_RELOC_AVR_LO8_LDI_GS",
42803 + "BFD_RELOC_AVR_HI8_LDI_PM",
42804 + "BFD_RELOC_AVR_HI8_LDI_GS",
42805 + "BFD_RELOC_AVR_HH8_LDI_PM",
42806 + "BFD_RELOC_AVR_LO8_LDI_PM_NEG",
42807 + "BFD_RELOC_AVR_HI8_LDI_PM_NEG",
42808 + "BFD_RELOC_AVR_HH8_LDI_PM_NEG",
42809 + "BFD_RELOC_AVR_CALL",
42810 + "BFD_RELOC_AVR_LDI",
42811 + "BFD_RELOC_AVR_6",
42812 + "BFD_RELOC_AVR_6_ADIW",
42813 + "BFD_RELOC_AVR32_DIFF32",
42814 + "BFD_RELOC_AVR32_DIFF16",
42815 + "BFD_RELOC_AVR32_DIFF8",
42816 + "BFD_RELOC_AVR32_GOT32",
42817 + "BFD_RELOC_AVR32_GOT16",
42818 + "BFD_RELOC_AVR32_GOT8",
42819 + "BFD_RELOC_AVR32_21S",
42820 + "BFD_RELOC_AVR32_16U",
42821 + "BFD_RELOC_AVR32_16S",
42822 + "BFD_RELOC_AVR32_SUB5",
42823 + "BFD_RELOC_AVR32_8S_EXT",
42824 + "BFD_RELOC_AVR32_8S",
42825 + "BFD_RELOC_AVR32_15S",
42826 + "BFD_RELOC_AVR32_22H_PCREL",
42827 + "BFD_RELOC_AVR32_18W_PCREL",
42828 + "BFD_RELOC_AVR32_16B_PCREL",
42829 + "BFD_RELOC_AVR32_16N_PCREL",
42830 + "BFD_RELOC_AVR32_14UW_PCREL",
42831 + "BFD_RELOC_AVR32_11H_PCREL",
42832 + "BFD_RELOC_AVR32_10UW_PCREL",
42833 + "BFD_RELOC_AVR32_9H_PCREL",
42834 + "BFD_RELOC_AVR32_9UW_PCREL",
42835 + "BFD_RELOC_AVR32_GOTPC",
42836 + "BFD_RELOC_AVR32_GOTCALL",
42837 + "BFD_RELOC_AVR32_LDA_GOT",
42838 + "BFD_RELOC_AVR32_GOT21S",
42839 + "BFD_RELOC_AVR32_GOT18SW",
42840 + "BFD_RELOC_AVR32_GOT16S",
42841 + "BFD_RELOC_AVR32_32_CPENT",
42842 + "BFD_RELOC_AVR32_CPCALL",
42843 + "BFD_RELOC_AVR32_16_CP",
42844 + "BFD_RELOC_AVR32_9W_CP",
42845 + "BFD_RELOC_AVR32_ALIGN",
42846 + "BFD_RELOC_AVR32_14UW",
42847 + "BFD_RELOC_AVR32_10UW",
42848 + "BFD_RELOC_AVR32_10SW",
42849 + "BFD_RELOC_AVR32_STHH_W",
42850 + "BFD_RELOC_AVR32_7UW",
42851 + "BFD_RELOC_AVR32_6S",
42852 + "BFD_RELOC_AVR32_6UW",
42853 + "BFD_RELOC_AVR32_4UH",
42854 + "BFD_RELOC_AVR32_3U",
42855 + "BFD_RELOC_390_12",
42856 + "BFD_RELOC_390_GOT12",
42857 + "BFD_RELOC_390_PLT32",
42858 + "BFD_RELOC_390_COPY",
42859 + "BFD_RELOC_390_GLOB_DAT",
42860 + "BFD_RELOC_390_JMP_SLOT",
42861 + "BFD_RELOC_390_RELATIVE",
42862 + "BFD_RELOC_390_GOTPC",
42863 + "BFD_RELOC_390_GOT16",
42864 + "BFD_RELOC_390_PC16DBL",
42865 + "BFD_RELOC_390_PLT16DBL",
42866 + "BFD_RELOC_390_PC32DBL",
42867 + "BFD_RELOC_390_PLT32DBL",
42868 + "BFD_RELOC_390_GOTPCDBL",
42869 + "BFD_RELOC_390_GOT64",
42870 + "BFD_RELOC_390_PLT64",
42871 + "BFD_RELOC_390_GOTENT",
42872 + "BFD_RELOC_390_GOTOFF64",
42873 + "BFD_RELOC_390_GOTPLT12",
42874 + "BFD_RELOC_390_GOTPLT16",
42875 + "BFD_RELOC_390_GOTPLT32",
42876 + "BFD_RELOC_390_GOTPLT64",
42877 + "BFD_RELOC_390_GOTPLTENT",
42878 + "BFD_RELOC_390_PLTOFF16",
42879 + "BFD_RELOC_390_PLTOFF32",
42880 + "BFD_RELOC_390_PLTOFF64",
42881 + "BFD_RELOC_390_TLS_LOAD",
42882 + "BFD_RELOC_390_TLS_GDCALL",
42883 + "BFD_RELOC_390_TLS_LDCALL",
42884 + "BFD_RELOC_390_TLS_GD32",
42885 + "BFD_RELOC_390_TLS_GD64",
42886 + "BFD_RELOC_390_TLS_GOTIE12",
42887 + "BFD_RELOC_390_TLS_GOTIE32",
42888 + "BFD_RELOC_390_TLS_GOTIE64",
42889 + "BFD_RELOC_390_TLS_LDM32",
42890 + "BFD_RELOC_390_TLS_LDM64",
42891 + "BFD_RELOC_390_TLS_IE32",
42892 + "BFD_RELOC_390_TLS_IE64",
42893 + "BFD_RELOC_390_TLS_IEENT",
42894 + "BFD_RELOC_390_TLS_LE32",
42895 + "BFD_RELOC_390_TLS_LE64",
42896 + "BFD_RELOC_390_TLS_LDO32",
42897 + "BFD_RELOC_390_TLS_LDO64",
42898 + "BFD_RELOC_390_TLS_DTPMOD",
42899 + "BFD_RELOC_390_TLS_DTPOFF",
42900 + "BFD_RELOC_390_TLS_TPOFF",
42901 + "BFD_RELOC_390_20",
42902 + "BFD_RELOC_390_GOT20",
42903 + "BFD_RELOC_390_GOTPLT20",
42904 + "BFD_RELOC_390_TLS_GOTIE20",
42905 + "BFD_RELOC_SCORE_DUMMY1",
42906 + "BFD_RELOC_SCORE_GPREL15",
42907 + "BFD_RELOC_SCORE_DUMMY2",
42908 + "BFD_RELOC_SCORE_JMP",
42909 + "BFD_RELOC_SCORE_BRANCH",
42910 + "BFD_RELOC_SCORE16_JMP",
42911 + "BFD_RELOC_SCORE16_BRANCH",
42912 + "BFD_RELOC_SCORE_GOT15",
42913 + "BFD_RELOC_SCORE_GOT_LO16",
42914 + "BFD_RELOC_SCORE_CALL15",
42915 + "BFD_RELOC_SCORE_DUMMY_HI16",
42916 + "BFD_RELOC_IP2K_FR9",
42917 + "BFD_RELOC_IP2K_BANK",
42918 + "BFD_RELOC_IP2K_ADDR16CJP",
42919 + "BFD_RELOC_IP2K_PAGE3",
42920 + "BFD_RELOC_IP2K_LO8DATA",
42921 + "BFD_RELOC_IP2K_HI8DATA",
42922 + "BFD_RELOC_IP2K_EX8DATA",
42923 + "BFD_RELOC_IP2K_LO8INSN",
42924 + "BFD_RELOC_IP2K_HI8INSN",
42925 + "BFD_RELOC_IP2K_PC_SKIP",
42926 + "BFD_RELOC_IP2K_TEXT",
42927 + "BFD_RELOC_IP2K_FR_OFFSET",
42928 + "BFD_RELOC_VPE4KMATH_DATA",
42929 + "BFD_RELOC_VPE4KMATH_INSN",
42930 + "BFD_RELOC_VTABLE_INHERIT",
42931 + "BFD_RELOC_VTABLE_ENTRY",
42932 + "BFD_RELOC_IA64_IMM14",
42933 + "BFD_RELOC_IA64_IMM22",
42934 + "BFD_RELOC_IA64_IMM64",
42935 + "BFD_RELOC_IA64_DIR32MSB",
42936 + "BFD_RELOC_IA64_DIR32LSB",
42937 + "BFD_RELOC_IA64_DIR64MSB",
42938 + "BFD_RELOC_IA64_DIR64LSB",
42939 + "BFD_RELOC_IA64_GPREL22",
42940 + "BFD_RELOC_IA64_GPREL64I",
42941 + "BFD_RELOC_IA64_GPREL32MSB",
42942 + "BFD_RELOC_IA64_GPREL32LSB",
42943 + "BFD_RELOC_IA64_GPREL64MSB",
42944 + "BFD_RELOC_IA64_GPREL64LSB",
42945 + "BFD_RELOC_IA64_LTOFF22",
42946 + "BFD_RELOC_IA64_LTOFF64I",
42947 + "BFD_RELOC_IA64_PLTOFF22",
42948 + "BFD_RELOC_IA64_PLTOFF64I",
42949 + "BFD_RELOC_IA64_PLTOFF64MSB",
42950 + "BFD_RELOC_IA64_PLTOFF64LSB",
42951 + "BFD_RELOC_IA64_FPTR64I",
42952 + "BFD_RELOC_IA64_FPTR32MSB",
42953 + "BFD_RELOC_IA64_FPTR32LSB",
42954 + "BFD_RELOC_IA64_FPTR64MSB",
42955 + "BFD_RELOC_IA64_FPTR64LSB",
42956 + "BFD_RELOC_IA64_PCREL21B",
42957 + "BFD_RELOC_IA64_PCREL21BI",
42958 + "BFD_RELOC_IA64_PCREL21M",
42959 + "BFD_RELOC_IA64_PCREL21F",
42960 + "BFD_RELOC_IA64_PCREL22",
42961 + "BFD_RELOC_IA64_PCREL60B",
42962 + "BFD_RELOC_IA64_PCREL64I",
42963 + "BFD_RELOC_IA64_PCREL32MSB",
42964 + "BFD_RELOC_IA64_PCREL32LSB",
42965 + "BFD_RELOC_IA64_PCREL64MSB",
42966 + "BFD_RELOC_IA64_PCREL64LSB",
42967 + "BFD_RELOC_IA64_LTOFF_FPTR22",
42968 + "BFD_RELOC_IA64_LTOFF_FPTR64I",
42969 + "BFD_RELOC_IA64_LTOFF_FPTR32MSB",
42970 + "BFD_RELOC_IA64_LTOFF_FPTR32LSB",
42971 + "BFD_RELOC_IA64_LTOFF_FPTR64MSB",
42972 + "BFD_RELOC_IA64_LTOFF_FPTR64LSB",
42973 + "BFD_RELOC_IA64_SEGREL32MSB",
42974 + "BFD_RELOC_IA64_SEGREL32LSB",
42975 + "BFD_RELOC_IA64_SEGREL64MSB",
42976 + "BFD_RELOC_IA64_SEGREL64LSB",
42977 + "BFD_RELOC_IA64_SECREL32MSB",
42978 + "BFD_RELOC_IA64_SECREL32LSB",
42979 + "BFD_RELOC_IA64_SECREL64MSB",
42980 + "BFD_RELOC_IA64_SECREL64LSB",
42981 + "BFD_RELOC_IA64_REL32MSB",
42982 + "BFD_RELOC_IA64_REL32LSB",
42983 + "BFD_RELOC_IA64_REL64MSB",
42984 + "BFD_RELOC_IA64_REL64LSB",
42985 + "BFD_RELOC_IA64_LTV32MSB",
42986 + "BFD_RELOC_IA64_LTV32LSB",
42987 + "BFD_RELOC_IA64_LTV64MSB",
42988 + "BFD_RELOC_IA64_LTV64LSB",
42989 + "BFD_RELOC_IA64_IPLTMSB",
42990 + "BFD_RELOC_IA64_IPLTLSB",
42991 + "BFD_RELOC_IA64_COPY",
42992 + "BFD_RELOC_IA64_LTOFF22X",
42993 + "BFD_RELOC_IA64_LDXMOV",
42994 + "BFD_RELOC_IA64_TPREL14",
42995 + "BFD_RELOC_IA64_TPREL22",
42996 + "BFD_RELOC_IA64_TPREL64I",
42997 + "BFD_RELOC_IA64_TPREL64MSB",
42998 + "BFD_RELOC_IA64_TPREL64LSB",
42999 + "BFD_RELOC_IA64_LTOFF_TPREL22",
43000 + "BFD_RELOC_IA64_DTPMOD64MSB",
43001 + "BFD_RELOC_IA64_DTPMOD64LSB",
43002 + "BFD_RELOC_IA64_LTOFF_DTPMOD22",
43003 + "BFD_RELOC_IA64_DTPREL14",
43004 + "BFD_RELOC_IA64_DTPREL22",
43005 + "BFD_RELOC_IA64_DTPREL64I",
43006 + "BFD_RELOC_IA64_DTPREL32MSB",
43007 + "BFD_RELOC_IA64_DTPREL32LSB",
43008 + "BFD_RELOC_IA64_DTPREL64MSB",
43009 + "BFD_RELOC_IA64_DTPREL64LSB",
43010 + "BFD_RELOC_IA64_LTOFF_DTPREL22",
43011 + "BFD_RELOC_M68HC11_HI8",
43012 + "BFD_RELOC_M68HC11_LO8",
43013 + "BFD_RELOC_M68HC11_3B",
43014 + "BFD_RELOC_M68HC11_RL_JUMP",
43015 + "BFD_RELOC_M68HC11_RL_GROUP",
43016 + "BFD_RELOC_M68HC11_LO16",
43017 + "BFD_RELOC_M68HC11_PAGE",
43018 + "BFD_RELOC_M68HC11_24",
43019 + "BFD_RELOC_M68HC12_5B",
43020 + "BFD_RELOC_16C_NUM08",
43021 + "BFD_RELOC_16C_NUM08_C",
43022 + "BFD_RELOC_16C_NUM16",
43023 + "BFD_RELOC_16C_NUM16_C",
43024 + "BFD_RELOC_16C_NUM32",
43025 + "BFD_RELOC_16C_NUM32_C",
43026 + "BFD_RELOC_16C_DISP04",
43027 + "BFD_RELOC_16C_DISP04_C",
43028 + "BFD_RELOC_16C_DISP08",
43029 + "BFD_RELOC_16C_DISP08_C",
43030 + "BFD_RELOC_16C_DISP16",
43031 + "BFD_RELOC_16C_DISP16_C",
43032 + "BFD_RELOC_16C_DISP24",
43033 + "BFD_RELOC_16C_DISP24_C",
43034 + "BFD_RELOC_16C_DISP24a",
43035 + "BFD_RELOC_16C_DISP24a_C",
43036 + "BFD_RELOC_16C_REG04",
43037 + "BFD_RELOC_16C_REG04_C",
43038 + "BFD_RELOC_16C_REG04a",
43039 + "BFD_RELOC_16C_REG04a_C",
43040 + "BFD_RELOC_16C_REG14",
43041 + "BFD_RELOC_16C_REG14_C",
43042 + "BFD_RELOC_16C_REG16",
43043 + "BFD_RELOC_16C_REG16_C",
43044 + "BFD_RELOC_16C_REG20",
43045 + "BFD_RELOC_16C_REG20_C",
43046 + "BFD_RELOC_16C_ABS20",
43047 + "BFD_RELOC_16C_ABS20_C",
43048 + "BFD_RELOC_16C_ABS24",
43049 + "BFD_RELOC_16C_ABS24_C",
43050 + "BFD_RELOC_16C_IMM04",
43051 + "BFD_RELOC_16C_IMM04_C",
43052 + "BFD_RELOC_16C_IMM16",
43053 + "BFD_RELOC_16C_IMM16_C",
43054 + "BFD_RELOC_16C_IMM20",
43055 + "BFD_RELOC_16C_IMM20_C",
43056 + "BFD_RELOC_16C_IMM24",
43057 + "BFD_RELOC_16C_IMM24_C",
43058 + "BFD_RELOC_16C_IMM32",
43059 + "BFD_RELOC_16C_IMM32_C",
43060 + "BFD_RELOC_CR16_NUM8",
43061 + "BFD_RELOC_CR16_NUM16",
43062 + "BFD_RELOC_CR16_NUM32",
43063 + "BFD_RELOC_CR16_NUM32a",
43064 + "BFD_RELOC_CR16_REGREL0",
43065 + "BFD_RELOC_CR16_REGREL4",
43066 + "BFD_RELOC_CR16_REGREL4a",
43067 + "BFD_RELOC_CR16_REGREL14",
43068 + "BFD_RELOC_CR16_REGREL14a",
43069 + "BFD_RELOC_CR16_REGREL16",
43070 + "BFD_RELOC_CR16_REGREL20",
43071 + "BFD_RELOC_CR16_REGREL20a",
43072 + "BFD_RELOC_CR16_ABS20",
43073 + "BFD_RELOC_CR16_ABS24",
43074 + "BFD_RELOC_CR16_IMM4",
43075 + "BFD_RELOC_CR16_IMM8",
43076 + "BFD_RELOC_CR16_IMM16",
43077 + "BFD_RELOC_CR16_IMM20",
43078 + "BFD_RELOC_CR16_IMM24",
43079 + "BFD_RELOC_CR16_IMM32",
43080 + "BFD_RELOC_CR16_IMM32a",
43081 + "BFD_RELOC_CR16_DISP4",
43082 + "BFD_RELOC_CR16_DISP8",
43083 + "BFD_RELOC_CR16_DISP16",
43084 + "BFD_RELOC_CR16_DISP20",
43085 + "BFD_RELOC_CR16_DISP24",
43086 + "BFD_RELOC_CR16_DISP24a",
43087 + "BFD_RELOC_CRX_REL4",
43088 + "BFD_RELOC_CRX_REL8",
43089 + "BFD_RELOC_CRX_REL8_CMP",
43090 + "BFD_RELOC_CRX_REL16",
43091 + "BFD_RELOC_CRX_REL24",
43092 + "BFD_RELOC_CRX_REL32",
43093 + "BFD_RELOC_CRX_REGREL12",
43094 + "BFD_RELOC_CRX_REGREL22",
43095 + "BFD_RELOC_CRX_REGREL28",
43096 + "BFD_RELOC_CRX_REGREL32",
43097 + "BFD_RELOC_CRX_ABS16",
43098 + "BFD_RELOC_CRX_ABS32",
43099 + "BFD_RELOC_CRX_NUM8",
43100 + "BFD_RELOC_CRX_NUM16",
43101 + "BFD_RELOC_CRX_NUM32",
43102 + "BFD_RELOC_CRX_IMM16",
43103 + "BFD_RELOC_CRX_IMM32",
43104 + "BFD_RELOC_CRX_SWITCH8",
43105 + "BFD_RELOC_CRX_SWITCH16",
43106 + "BFD_RELOC_CRX_SWITCH32",
43107 + "BFD_RELOC_CRIS_BDISP8",
43108 + "BFD_RELOC_CRIS_UNSIGNED_5",
43109 + "BFD_RELOC_CRIS_SIGNED_6",
43110 + "BFD_RELOC_CRIS_UNSIGNED_6",
43111 + "BFD_RELOC_CRIS_SIGNED_8",
43112 + "BFD_RELOC_CRIS_UNSIGNED_8",
43113 + "BFD_RELOC_CRIS_SIGNED_16",
43114 + "BFD_RELOC_CRIS_UNSIGNED_16",
43115 + "BFD_RELOC_CRIS_LAPCQ_OFFSET",
43116 + "BFD_RELOC_CRIS_UNSIGNED_4",
43117 + "BFD_RELOC_CRIS_COPY",
43118 + "BFD_RELOC_CRIS_GLOB_DAT",
43119 + "BFD_RELOC_CRIS_JUMP_SLOT",
43120 + "BFD_RELOC_CRIS_RELATIVE",
43121 + "BFD_RELOC_CRIS_32_GOT",
43122 + "BFD_RELOC_CRIS_16_GOT",
43123 + "BFD_RELOC_CRIS_32_GOTPLT",
43124 + "BFD_RELOC_CRIS_16_GOTPLT",
43125 + "BFD_RELOC_CRIS_32_GOTREL",
43126 + "BFD_RELOC_CRIS_32_PLT_GOTREL",
43127 + "BFD_RELOC_CRIS_32_PLT_PCREL",
43128 + "BFD_RELOC_860_COPY",
43129 + "BFD_RELOC_860_GLOB_DAT",
43130 + "BFD_RELOC_860_JUMP_SLOT",
43131 + "BFD_RELOC_860_RELATIVE",
43132 + "BFD_RELOC_860_PC26",
43133 + "BFD_RELOC_860_PLT26",
43134 + "BFD_RELOC_860_PC16",
43135 + "BFD_RELOC_860_LOW0",
43136 + "BFD_RELOC_860_SPLIT0",
43137 + "BFD_RELOC_860_LOW1",
43138 + "BFD_RELOC_860_SPLIT1",
43139 + "BFD_RELOC_860_LOW2",
43140 + "BFD_RELOC_860_SPLIT2",
43141 + "BFD_RELOC_860_LOW3",
43142 + "BFD_RELOC_860_LOGOT0",
43143 + "BFD_RELOC_860_SPGOT0",
43144 + "BFD_RELOC_860_LOGOT1",
43145 + "BFD_RELOC_860_SPGOT1",
43146 + "BFD_RELOC_860_LOGOTOFF0",
43147 + "BFD_RELOC_860_SPGOTOFF0",
43148 + "BFD_RELOC_860_LOGOTOFF1",
43149 + "BFD_RELOC_860_SPGOTOFF1",
43150 + "BFD_RELOC_860_LOGOTOFF2",
43151 + "BFD_RELOC_860_LOGOTOFF3",
43152 + "BFD_RELOC_860_LOPC",
43153 + "BFD_RELOC_860_HIGHADJ",
43154 + "BFD_RELOC_860_HAGOT",
43155 + "BFD_RELOC_860_HAGOTOFF",
43156 + "BFD_RELOC_860_HAPC",
43157 + "BFD_RELOC_860_HIGH",
43158 + "BFD_RELOC_860_HIGOT",
43159 + "BFD_RELOC_860_HIGOTOFF",
43160 + "BFD_RELOC_OPENRISC_ABS_26",
43161 + "BFD_RELOC_OPENRISC_REL_26",
43162 + "BFD_RELOC_H8_DIR16A8",
43163 + "BFD_RELOC_H8_DIR16R8",
43164 + "BFD_RELOC_H8_DIR24A8",
43165 + "BFD_RELOC_H8_DIR24R8",
43166 + "BFD_RELOC_H8_DIR32A16",
43167 + "BFD_RELOC_XSTORMY16_REL_12",
43168 + "BFD_RELOC_XSTORMY16_12",
43169 + "BFD_RELOC_XSTORMY16_24",
43170 + "BFD_RELOC_XSTORMY16_FPTR16",
43171 + "BFD_RELOC_RELC",
43172 +
43173 + "BFD_RELOC_XC16X_PAG",
43174 + "BFD_RELOC_XC16X_POF",
43175 + "BFD_RELOC_XC16X_SEG",
43176 + "BFD_RELOC_XC16X_SOF",
43177 + "BFD_RELOC_VAX_GLOB_DAT",
43178 + "BFD_RELOC_VAX_JMP_SLOT",
43179 + "BFD_RELOC_VAX_RELATIVE",
43180 + "BFD_RELOC_MT_PC16",
43181 + "BFD_RELOC_MT_HI16",
43182 + "BFD_RELOC_MT_LO16",
43183 + "BFD_RELOC_MT_GNU_VTINHERIT",
43184 + "BFD_RELOC_MT_GNU_VTENTRY",
43185 + "BFD_RELOC_MT_PCINSN8",
43186 + "BFD_RELOC_MSP430_10_PCREL",
43187 + "BFD_RELOC_MSP430_16_PCREL",
43188 + "BFD_RELOC_MSP430_16",
43189 + "BFD_RELOC_MSP430_16_PCREL_BYTE",
43190 + "BFD_RELOC_MSP430_16_BYTE",
43191 + "BFD_RELOC_MSP430_2X_PCREL",
43192 + "BFD_RELOC_MSP430_RL_PCREL",
43193 + "BFD_RELOC_IQ2000_OFFSET_16",
43194 + "BFD_RELOC_IQ2000_OFFSET_21",
43195 + "BFD_RELOC_IQ2000_UHI16",
43196 + "BFD_RELOC_XTENSA_RTLD",
43197 + "BFD_RELOC_XTENSA_GLOB_DAT",
43198 + "BFD_RELOC_XTENSA_JMP_SLOT",
43199 + "BFD_RELOC_XTENSA_RELATIVE",
43200 + "BFD_RELOC_XTENSA_PLT",
43201 + "BFD_RELOC_XTENSA_DIFF8",
43202 + "BFD_RELOC_XTENSA_DIFF16",
43203 + "BFD_RELOC_XTENSA_DIFF32",
43204 + "BFD_RELOC_XTENSA_SLOT0_OP",
43205 + "BFD_RELOC_XTENSA_SLOT1_OP",
43206 + "BFD_RELOC_XTENSA_SLOT2_OP",
43207 + "BFD_RELOC_XTENSA_SLOT3_OP",
43208 + "BFD_RELOC_XTENSA_SLOT4_OP",
43209 + "BFD_RELOC_XTENSA_SLOT5_OP",
43210 + "BFD_RELOC_XTENSA_SLOT6_OP",
43211 + "BFD_RELOC_XTENSA_SLOT7_OP",
43212 + "BFD_RELOC_XTENSA_SLOT8_OP",
43213 + "BFD_RELOC_XTENSA_SLOT9_OP",
43214 + "BFD_RELOC_XTENSA_SLOT10_OP",
43215 + "BFD_RELOC_XTENSA_SLOT11_OP",
43216 + "BFD_RELOC_XTENSA_SLOT12_OP",
43217 + "BFD_RELOC_XTENSA_SLOT13_OP",
43218 + "BFD_RELOC_XTENSA_SLOT14_OP",
43219 + "BFD_RELOC_XTENSA_SLOT0_ALT",
43220 + "BFD_RELOC_XTENSA_SLOT1_ALT",
43221 + "BFD_RELOC_XTENSA_SLOT2_ALT",
43222 + "BFD_RELOC_XTENSA_SLOT3_ALT",
43223 + "BFD_RELOC_XTENSA_SLOT4_ALT",
43224 + "BFD_RELOC_XTENSA_SLOT5_ALT",
43225 + "BFD_RELOC_XTENSA_SLOT6_ALT",
43226 + "BFD_RELOC_XTENSA_SLOT7_ALT",
43227 + "BFD_RELOC_XTENSA_SLOT8_ALT",
43228 + "BFD_RELOC_XTENSA_SLOT9_ALT",
43229 + "BFD_RELOC_XTENSA_SLOT10_ALT",
43230 + "BFD_RELOC_XTENSA_SLOT11_ALT",
43231 + "BFD_RELOC_XTENSA_SLOT12_ALT",
43232 + "BFD_RELOC_XTENSA_SLOT13_ALT",
43233 + "BFD_RELOC_XTENSA_SLOT14_ALT",
43234 + "BFD_RELOC_XTENSA_OP0",
43235 + "BFD_RELOC_XTENSA_OP1",
43236 + "BFD_RELOC_XTENSA_OP2",
43237 + "BFD_RELOC_XTENSA_ASM_EXPAND",
43238 + "BFD_RELOC_XTENSA_ASM_SIMPLIFY",
43239 + "BFD_RELOC_Z80_DISP8",
43240 + "BFD_RELOC_Z8K_DISP7",
43241 + "BFD_RELOC_Z8K_CALLR",
43242 + "BFD_RELOC_Z8K_IMM4L",
43243 + "@@overflow: BFD_RELOC_UNUSED@@",
43244 +};
43245 +#endif
43246 +
43247 +reloc_howto_type *bfd_default_reloc_type_lookup
43248 + (bfd *abfd, bfd_reloc_code_real_type code);
43249 +
43250 +bfd_boolean bfd_generic_relax_section
43251 + (bfd *abfd,
43252 + asection *section,
43253 + struct bfd_link_info *,
43254 + bfd_boolean *);
43255 +
43256 +bfd_boolean bfd_generic_gc_sections
43257 + (bfd *, struct bfd_link_info *);
43258 +
43259 +bfd_boolean bfd_generic_merge_sections
43260 + (bfd *, struct bfd_link_info *);
43261 +
43262 +bfd_byte *bfd_generic_get_relocated_section_contents
43263 + (bfd *abfd,
43264 + struct bfd_link_info *link_info,
43265 + struct bfd_link_order *link_order,
43266 + bfd_byte *data,
43267 + bfd_boolean relocatable,
43268 + asymbol **symbols);
43269 +
43270 +/* Extracted from archures.c. */
43271 +extern const bfd_arch_info_type bfd_default_arch_struct;
43272 +bfd_boolean bfd_default_set_arch_mach
43273 + (bfd *abfd, enum bfd_architecture arch, unsigned long mach);
43274 +
43275 +const bfd_arch_info_type *bfd_default_compatible
43276 + (const bfd_arch_info_type *a, const bfd_arch_info_type *b);
43277 +
43278 +bfd_boolean bfd_default_scan
43279 + (const struct bfd_arch_info *info, const char *string);
43280 +
43281 +/* Extracted from elf.c. */
43282 +struct elf_internal_shdr *bfd_elf_find_section (bfd *abfd, char *name);
43283 +
43284 --- /dev/null
43285 +++ b/bfd/doc/libcoff.h
43286 @@ -0,0 +1,936 @@
43287 +/* DO NOT EDIT! -*- buffer-read-only: t -*- This file is automatically
43288 + generated from "libcoff-in.h" and "coffcode.h".
43289 + Run "make headers" in your build bfd/ to regenerate. */
43290 +
43291 +/* BFD COFF object file private structure.
43292 + Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
43293 + 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
43294 + Free Software Foundation, Inc.
43295 + Written by Cygnus Support.
43296 +
43297 + This file is part of BFD, the Binary File Descriptor library.
43298 +
43299 + This program is free software; you can redistribute it and/or modify
43300 + it under the terms of the GNU General Public License as published by
43301 + the Free Software Foundation; either version 3 of the License, or
43302 + (at your option) any later version.
43303 +
43304 + This program is distributed in the hope that it will be useful,
43305 + but WITHOUT ANY WARRANTY; without even the implied warranty of
43306 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
43307 + GNU General Public License for more details.
43308 +
43309 + You should have received a copy of the GNU General Public License
43310 + along with this program; if not, write to the Free Software
43311 + Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
43312 + MA 02110-1301, USA. */
43313 +
43314 +#include "bfdlink.h"
43315 +
43316 +/* Object file tdata; access macros. */
43317 +
43318 +#define coff_data(bfd) ((bfd)->tdata.coff_obj_data)
43319 +#define exec_hdr(bfd) (coff_data (bfd)->hdr)
43320 +#define obj_pe(bfd) (coff_data (bfd)->pe)
43321 +#define obj_symbols(bfd) (coff_data (bfd)->symbols)
43322 +#define obj_sym_filepos(bfd) (coff_data (bfd)->sym_filepos)
43323 +#define obj_relocbase(bfd) (coff_data (bfd)->relocbase)
43324 +#define obj_raw_syments(bfd) (coff_data (bfd)->raw_syments)
43325 +#define obj_raw_syment_count(bfd) (coff_data (bfd)->raw_syment_count)
43326 +#define obj_convert(bfd) (coff_data (bfd)->conversion_table)
43327 +#define obj_conv_table_size(bfd) (coff_data (bfd)->conv_table_size)
43328 +#define obj_coff_external_syms(bfd) (coff_data (bfd)->external_syms)
43329 +#define obj_coff_keep_syms(bfd) (coff_data (bfd)->keep_syms)
43330 +#define obj_coff_strings(bfd) (coff_data (bfd)->strings)
43331 +#define obj_coff_keep_strings(bfd) (coff_data (bfd)->keep_strings)
43332 +#define obj_coff_sym_hashes(bfd) (coff_data (bfd)->sym_hashes)
43333 +#define obj_coff_strings_written(bfd) (coff_data (bfd)->strings_written)
43334 +#define obj_coff_local_toc_table(bfd) (coff_data (bfd)->local_toc_sym_map)
43335 +
43336 +/* `Tdata' information kept for COFF files. */
43337 +
43338 +typedef struct coff_tdata
43339 +{
43340 + struct coff_symbol_struct *symbols; /* Symtab for input bfd. */
43341 + unsigned int *conversion_table;
43342 + int conv_table_size;
43343 + file_ptr sym_filepos;
43344 +
43345 + struct coff_ptr_struct *raw_syments;
43346 + unsigned long raw_syment_count;
43347 +
43348 + /* These are only valid once writing has begun. */
43349 + long int relocbase;
43350 +
43351 + /* These members communicate important constants about the symbol table
43352 + to GDB's symbol-reading code. These `constants' unfortunately vary
43353 + from coff implementation to implementation... */
43354 + unsigned local_n_btmask;
43355 + unsigned local_n_btshft;
43356 + unsigned local_n_tmask;
43357 + unsigned local_n_tshift;
43358 + unsigned local_symesz;
43359 + unsigned local_auxesz;
43360 + unsigned local_linesz;
43361 +
43362 + /* The unswapped external symbols. May be NULL. Read by
43363 + _bfd_coff_get_external_symbols. */
43364 + void * external_syms;
43365 + /* If this is TRUE, the external_syms may not be freed. */
43366 + bfd_boolean keep_syms;
43367 +
43368 + /* The string table. May be NULL. Read by
43369 + _bfd_coff_read_string_table. */
43370 + char *strings;
43371 + /* If this is TRUE, the strings may not be freed. */
43372 + bfd_boolean keep_strings;
43373 + /* If this is TRUE, the strings have been written out already. */
43374 + bfd_boolean strings_written;
43375 +
43376 + /* Is this a PE format coff file? */
43377 + int pe;
43378 + /* Used by the COFF backend linker. */
43379 + struct coff_link_hash_entry **sym_hashes;
43380 +
43381 + /* Used by the pe linker for PowerPC. */
43382 + int *local_toc_sym_map;
43383 +
43384 + struct bfd_link_info *link_info;
43385 +
43386 + /* Used by coff_find_nearest_line. */
43387 + void * line_info;
43388 +
43389 + /* A place to stash dwarf2 info for this bfd. */
43390 + void * dwarf2_find_line_info;
43391 +
43392 + /* The timestamp from the COFF file header. */
43393 + long timestamp;
43394 +
43395 + /* Copy of some of the f_flags bits in the COFF filehdr structure,
43396 + used by ARM code. */
43397 + flagword flags;
43398 +
43399 +} coff_data_type;
43400 +
43401 +/* Tdata for pe image files. */
43402 +typedef struct pe_tdata
43403 +{
43404 + coff_data_type coff;
43405 + struct internal_extra_pe_aouthdr pe_opthdr;
43406 + int dll;
43407 + int has_reloc_section;
43408 + bfd_boolean (*in_reloc_p) (bfd *, reloc_howto_type *);
43409 + flagword real_flags;
43410 + int target_subsystem;
43411 + bfd_boolean force_minimum_alignment;
43412 +} pe_data_type;
43413 +
43414 +#define pe_data(bfd) ((bfd)->tdata.pe_obj_data)
43415 +
43416 +/* Tdata for XCOFF files. */
43417 +
43418 +struct xcoff_tdata
43419 +{
43420 + /* Basic COFF information. */
43421 + coff_data_type coff;
43422 +
43423 + /* TRUE if this is an XCOFF64 file. */
43424 + bfd_boolean xcoff64;
43425 +
43426 + /* TRUE if a large a.out header should be generated. */
43427 + bfd_boolean full_aouthdr;
43428 +
43429 + /* TOC value. */
43430 + bfd_vma toc;
43431 +
43432 + /* Index of section holding TOC. */
43433 + int sntoc;
43434 +
43435 + /* Index of section holding entry point. */
43436 + int snentry;
43437 +
43438 + /* .text alignment from optional header. */
43439 + int text_align_power;
43440 +
43441 + /* .data alignment from optional header. */
43442 + int data_align_power;
43443 +
43444 + /* modtype from optional header. */
43445 + short modtype;
43446 +
43447 + /* cputype from optional header. */
43448 + short cputype;
43449 +
43450 + /* maxdata from optional header. */
43451 + bfd_vma maxdata;
43452 +
43453 + /* maxstack from optional header. */
43454 + bfd_vma maxstack;
43455 +
43456 + /* Used by the XCOFF backend linker. */
43457 + asection **csects;
43458 + unsigned long *debug_indices;
43459 + unsigned int import_file_id;
43460 +};
43461 +
43462 +#define xcoff_data(abfd) ((abfd)->tdata.xcoff_obj_data)
43463 +
43464 +/* We take the address of the first element of an asymbol to ensure that the
43465 + macro is only ever applied to an asymbol. */
43466 +#define coffsymbol(asymbol) ((coff_symbol_type *)(&((asymbol)->the_bfd)))
43467 +
43468 +/* The used_by_bfd field of a section may be set to a pointer to this
43469 + structure. */
43470 +
43471 +struct coff_section_tdata
43472 +{
43473 + /* The relocs, swapped into COFF internal form. This may be NULL. */
43474 + struct internal_reloc *relocs;
43475 + /* If this is TRUE, the relocs entry may not be freed. */
43476 + bfd_boolean keep_relocs;
43477 + /* The section contents. This may be NULL. */
43478 + bfd_byte *contents;
43479 + /* If this is TRUE, the contents entry may not be freed. */
43480 + bfd_boolean keep_contents;
43481 + /* Information cached by coff_find_nearest_line. */
43482 + bfd_vma offset;
43483 + unsigned int i;
43484 + const char *function;
43485 + /* Optional information about a COMDAT entry; NULL if not COMDAT. */
43486 + struct coff_comdat_info *comdat;
43487 + int line_base;
43488 + /* A pointer used for .stab linking optimizations. */
43489 + void * stab_info;
43490 + /* Available for individual backends. */
43491 + void * tdata;
43492 +};
43493 +
43494 +/* An accessor macro for the coff_section_tdata structure. */
43495 +#define coff_section_data(abfd, sec) \
43496 + ((struct coff_section_tdata *) (sec)->used_by_bfd)
43497 +
43498 +/* Tdata for sections in XCOFF files. This is used by the linker. */
43499 +
43500 +struct xcoff_section_tdata
43501 +{
43502 + /* Used for XCOFF csects created by the linker; points to the real
43503 + XCOFF section which contains this csect. */
43504 + asection *enclosing;
43505 + /* The lineno_count field for the enclosing section, because we are
43506 + going to clobber it there. */
43507 + unsigned int lineno_count;
43508 + /* The first and one past the last symbol indices for symbols used
43509 + by this csect. */
43510 + unsigned long first_symndx;
43511 + unsigned long last_symndx;
43512 +};
43513 +
43514 +/* An accessor macro the xcoff_section_tdata structure. */
43515 +#define xcoff_section_data(abfd, sec) \
43516 + ((struct xcoff_section_tdata *) coff_section_data ((abfd), (sec))->tdata)
43517 +
43518 +/* Tdata for sections in PE files. */
43519 +
43520 +struct pei_section_tdata
43521 +{
43522 + /* The virtual size of the section. */
43523 + bfd_size_type virt_size;
43524 + /* The PE section flags. */
43525 + long pe_flags;
43526 +};
43527 +
43528 +/* An accessor macro for the pei_section_tdata structure. */
43529 +#define pei_section_data(abfd, sec) \
43530 + ((struct pei_section_tdata *) coff_section_data ((abfd), (sec))->tdata)
43531 +
43532 +/* COFF linker hash table entries. */
43533 +
43534 +struct coff_link_hash_entry
43535 +{
43536 + struct bfd_link_hash_entry root;
43537 +
43538 + /* Symbol index in output file. Set to -1 initially. Set to -2 if
43539 + there is a reloc against this symbol. */
43540 + long indx;
43541 +
43542 + /* Symbol type. */
43543 + unsigned short type;
43544 +
43545 + /* Symbol class. */
43546 + unsigned char class;
43547 +
43548 + /* Number of auxiliary entries. */
43549 + char numaux;
43550 +
43551 + /* BFD to take auxiliary entries from. */
43552 + bfd *auxbfd;
43553 +
43554 + /* Pointer to array of auxiliary entries, if any. */
43555 + union internal_auxent *aux;
43556 +
43557 + /* Flag word; legal values follow. */
43558 + unsigned short coff_link_hash_flags;
43559 + /* Symbol is a PE section symbol. */
43560 +#define COFF_LINK_HASH_PE_SECTION_SYMBOL (01)
43561 +};
43562 +
43563 +/* COFF linker hash table. */
43564 +
43565 +struct coff_link_hash_table
43566 +{
43567 + struct bfd_link_hash_table root;
43568 + /* A pointer to information used to link stabs in sections. */
43569 + struct stab_info stab_info;
43570 +};
43571 +
43572 +/* Look up an entry in a COFF linker hash table. */
43573 +
43574 +#define coff_link_hash_lookup(table, string, create, copy, follow) \
43575 + ((struct coff_link_hash_entry *) \
43576 + bfd_link_hash_lookup (&(table)->root, (string), (create), \
43577 + (copy), (follow)))
43578 +
43579 +/* Traverse a COFF linker hash table. */
43580 +
43581 +#define coff_link_hash_traverse(table, func, info) \
43582 + (bfd_link_hash_traverse \
43583 + (&(table)->root, \
43584 + (bfd_boolean (*) (struct bfd_link_hash_entry *, void *)) (func), \
43585 + (info)))
43586 +
43587 +/* Get the COFF linker hash table from a link_info structure. */
43588 +
43589 +#define coff_hash_table(p) ((struct coff_link_hash_table *) ((p)->hash))
43590 +
43591 +/* Functions in coffgen.c. */
43592 +extern const bfd_target *coff_object_p
43593 + (bfd *);
43594 +extern struct bfd_section *coff_section_from_bfd_index
43595 + (bfd *, int);
43596 +extern long coff_get_symtab_upper_bound
43597 + (bfd *);
43598 +extern long coff_canonicalize_symtab
43599 + (bfd *, asymbol **);
43600 +extern int coff_count_linenumbers
43601 + (bfd *);
43602 +extern struct coff_symbol_struct *coff_symbol_from
43603 + (bfd *, asymbol *);
43604 +extern bfd_boolean coff_renumber_symbols
43605 + (bfd *, int *);
43606 +extern void coff_mangle_symbols
43607 + (bfd *);
43608 +extern bfd_boolean coff_write_symbols
43609 + (bfd *);
43610 +extern bfd_boolean coff_write_linenumbers
43611 + (bfd *);
43612 +extern alent *coff_get_lineno
43613 + (bfd *, asymbol *);
43614 +extern asymbol *coff_section_symbol
43615 + (bfd *, char *);
43616 +extern bfd_boolean _bfd_coff_get_external_symbols
43617 + (bfd *);
43618 +extern const char *_bfd_coff_read_string_table
43619 + (bfd *);
43620 +extern bfd_boolean _bfd_coff_free_symbols
43621 + (bfd *);
43622 +extern struct coff_ptr_struct *coff_get_normalized_symtab
43623 + (bfd *);
43624 +extern long coff_get_reloc_upper_bound
43625 + (bfd *, sec_ptr);
43626 +extern asymbol *coff_make_empty_symbol
43627 + (bfd *);
43628 +extern void coff_print_symbol
43629 + (bfd *, void * filep, asymbol *, bfd_print_symbol_type);
43630 +extern void coff_get_symbol_info
43631 + (bfd *, asymbol *, symbol_info *ret);
43632 +extern bfd_boolean _bfd_coff_is_local_label_name
43633 + (bfd *, const char *);
43634 +extern asymbol *coff_bfd_make_debug_symbol
43635 + (bfd *, void *, unsigned long);
43636 +extern bfd_boolean coff_find_nearest_line
43637 + (bfd *, asection *, asymbol **, bfd_vma, const char **,
43638 + const char **, unsigned int *);
43639 +extern bfd_boolean coff_find_inliner_info
43640 + (bfd *, const char **, const char **, unsigned int *);
43641 +extern int coff_sizeof_headers
43642 + (bfd *, struct bfd_link_info *);
43643 +extern bfd_boolean bfd_coff_reloc16_relax_section
43644 + (bfd *, asection *, struct bfd_link_info *, bfd_boolean *);
43645 +extern bfd_byte *bfd_coff_reloc16_get_relocated_section_contents
43646 + (bfd *, struct bfd_link_info *, struct bfd_link_order *,
43647 + bfd_byte *, bfd_boolean, asymbol **);
43648 +extern bfd_vma bfd_coff_reloc16_get_value
43649 + (arelent *, struct bfd_link_info *, asection *);
43650 +extern void bfd_perform_slip
43651 + (bfd *, unsigned int, asection *, bfd_vma);
43652 +
43653 +/* Functions and types in cofflink.c. */
43654 +
43655 +#define STRING_SIZE_SIZE 4
43656 +
43657 +/* We use a hash table to merge identical enum, struct, and union
43658 + definitions in the linker. */
43659 +
43660 +/* Information we keep for a single element (an enum value, a
43661 + structure or union field) in the debug merge hash table. */
43662 +
43663 +struct coff_debug_merge_element
43664 +{
43665 + /* Next element. */
43666 + struct coff_debug_merge_element *next;
43667 +
43668 + /* Name. */
43669 + const char *name;
43670 +
43671 + /* Type. */
43672 + unsigned int type;
43673 +
43674 + /* Symbol index for complex type. */
43675 + long tagndx;
43676 +};
43677 +
43678 +/* A linked list of debug merge entries for a given name. */
43679 +
43680 +struct coff_debug_merge_type
43681 +{
43682 + /* Next type with the same name. */
43683 + struct coff_debug_merge_type *next;
43684 +
43685 + /* Class of type. */
43686 + int class;
43687 +
43688 + /* Symbol index where this type is defined. */
43689 + long indx;
43690 +
43691 + /* List of elements. */
43692 + struct coff_debug_merge_element *elements;
43693 +};
43694 +
43695 +/* Information we store in the debug merge hash table. */
43696 +
43697 +struct coff_debug_merge_hash_entry
43698 +{
43699 + struct bfd_hash_entry root;
43700 +
43701 + /* A list of types with this name. */
43702 + struct coff_debug_merge_type *types;
43703 +};
43704 +
43705 +/* The debug merge hash table. */
43706 +
43707 +struct coff_debug_merge_hash_table
43708 +{
43709 + struct bfd_hash_table root;
43710 +};
43711 +
43712 +/* Initialize a COFF debug merge hash table. */
43713 +
43714 +#define coff_debug_merge_hash_table_init(table) \
43715 + (bfd_hash_table_init (&(table)->root, _bfd_coff_debug_merge_hash_newfunc, \
43716 + sizeof (struct coff_debug_merge_hash_entry)))
43717 +
43718 +/* Free a COFF debug merge hash table. */
43719 +
43720 +#define coff_debug_merge_hash_table_free(table) \
43721 + (bfd_hash_table_free (&(table)->root))
43722 +
43723 +/* Look up an entry in a COFF debug merge hash table. */
43724 +
43725 +#define coff_debug_merge_hash_lookup(table, string, create, copy) \
43726 + ((struct coff_debug_merge_hash_entry *) \
43727 + bfd_hash_lookup (&(table)->root, (string), (create), (copy)))
43728 +
43729 +/* Information we keep for each section in the output file when doing
43730 + a relocatable link. */
43731 +
43732 +struct coff_link_section_info
43733 +{
43734 + /* The relocs to be output. */
43735 + struct internal_reloc *relocs;
43736 + /* For each reloc against a global symbol whose index was not known
43737 + when the reloc was handled, the global hash table entry. */
43738 + struct coff_link_hash_entry **rel_hashes;
43739 +};
43740 +
43741 +/* Information that we pass around while doing the final link step. */
43742 +
43743 +struct coff_final_link_info
43744 +{
43745 + /* General link information. */
43746 + struct bfd_link_info *info;
43747 + /* Output BFD. */
43748 + bfd *output_bfd;
43749 + /* Used to indicate failure in traversal routine. */
43750 + bfd_boolean failed;
43751 + /* If doing "task linking" set only during the time when we want the
43752 + global symbol writer to convert the storage class of defined global
43753 + symbols from global to static. */
43754 + bfd_boolean global_to_static;
43755 + /* Hash table for long symbol names. */
43756 + struct bfd_strtab_hash *strtab;
43757 + /* When doing a relocatable link, an array of information kept for
43758 + each output section, indexed by the target_index field. */
43759 + struct coff_link_section_info *section_info;
43760 + /* Symbol index of last C_FILE symbol (-1 if none). */
43761 + long last_file_index;
43762 + /* Contents of last C_FILE symbol. */
43763 + struct internal_syment last_file;
43764 + /* Symbol index of first aux entry of last .bf symbol with an empty
43765 + endndx field (-1 if none). */
43766 + long last_bf_index;
43767 + /* Contents of last_bf_index aux entry. */
43768 + union internal_auxent last_bf;
43769 + /* Hash table used to merge debug information. */
43770 + struct coff_debug_merge_hash_table debug_merge;
43771 + /* Buffer large enough to hold swapped symbols of any input file. */
43772 + struct internal_syment *internal_syms;
43773 + /* Buffer large enough to hold sections of symbols of any input file. */
43774 + asection **sec_ptrs;
43775 + /* Buffer large enough to hold output indices of symbols of any
43776 + input file. */
43777 + long *sym_indices;
43778 + /* Buffer large enough to hold output symbols for any input file. */
43779 + bfd_byte *outsyms;
43780 + /* Buffer large enough to hold external line numbers for any input
43781 + section. */
43782 + bfd_byte *linenos;
43783 + /* Buffer large enough to hold any input section. */
43784 + bfd_byte *contents;
43785 + /* Buffer large enough to hold external relocs of any input section. */
43786 + bfd_byte *external_relocs;
43787 + /* Buffer large enough to hold swapped relocs of any input section. */
43788 + struct internal_reloc *internal_relocs;
43789 +};
43790 +
43791 +/* Most COFF variants have no way to record the alignment of a
43792 + section. This struct is used to set a specific alignment based on
43793 + the name of the section. */
43794 +
43795 +struct coff_section_alignment_entry
43796 +{
43797 + /* The section name. */
43798 + const char *name;
43799 +
43800 + /* This is either (unsigned int) -1, indicating that the section
43801 + name must match exactly, or it is the number of letters which
43802 + must match at the start of the name. */
43803 + unsigned int comparison_length;
43804 +
43805 + /* These macros may be used to fill in the first two fields in a
43806 + structure initialization. */
43807 +#define COFF_SECTION_NAME_EXACT_MATCH(name) (name), ((unsigned int) -1)
43808 +#define COFF_SECTION_NAME_PARTIAL_MATCH(name) (name), (sizeof (name) - 1)
43809 +
43810 + /* Only use this entry if the default section alignment for this
43811 + target is at least that much (as a power of two). If this field
43812 + is COFF_ALIGNMENT_FIELD_EMPTY, it should be ignored. */
43813 + unsigned int default_alignment_min;
43814 +
43815 + /* Only use this entry if the default section alignment for this
43816 + target is no greater than this (as a power of two). If this
43817 + field is COFF_ALIGNMENT_FIELD_EMPTY, it should be ignored. */
43818 + unsigned int default_alignment_max;
43819 +
43820 +#define COFF_ALIGNMENT_FIELD_EMPTY ((unsigned int) -1)
43821 +
43822 + /* The desired alignment for this section (as a power of two). */
43823 + unsigned int alignment_power;
43824 +};
43825 +
43826 +extern struct bfd_hash_entry *_bfd_coff_link_hash_newfunc
43827 + (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
43828 +extern bfd_boolean _bfd_coff_link_hash_table_init
43829 + (struct coff_link_hash_table *, bfd *,
43830 + struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
43831 + struct bfd_hash_table *,
43832 + const char *),
43833 + unsigned int);
43834 +extern struct bfd_link_hash_table *_bfd_coff_link_hash_table_create
43835 + (bfd *);
43836 +extern const char *_bfd_coff_internal_syment_name
43837 + (bfd *, const struct internal_syment *, char *);
43838 +extern bfd_boolean _bfd_coff_link_add_symbols
43839 + (bfd *, struct bfd_link_info *);
43840 +extern bfd_boolean _bfd_coff_final_link
43841 + (bfd *, struct bfd_link_info *);
43842 +extern struct internal_reloc *_bfd_coff_read_internal_relocs
43843 + (bfd *, asection *, bfd_boolean, bfd_byte *, bfd_boolean,
43844 + struct internal_reloc *);
43845 +extern bfd_boolean _bfd_coff_generic_relocate_section
43846 + (bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
43847 + struct internal_reloc *, struct internal_syment *, asection **);
43848 +extern struct bfd_hash_entry *_bfd_coff_debug_merge_hash_newfunc
43849 + (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
43850 +extern bfd_boolean _bfd_coff_write_global_sym
43851 + (struct coff_link_hash_entry *, void *);
43852 +extern bfd_boolean _bfd_coff_write_task_globals
43853 + (struct coff_link_hash_entry *, void *);
43854 +extern bfd_boolean _bfd_coff_link_input_bfd
43855 + (struct coff_final_link_info *, bfd *);
43856 +extern bfd_boolean _bfd_coff_reloc_link_order
43857 + (bfd *, struct coff_final_link_info *, asection *,
43858 + struct bfd_link_order *);
43859 +
43860 +
43861 +#define coff_get_section_contents_in_window \
43862 + _bfd_generic_get_section_contents_in_window
43863 +
43864 +/* Functions in xcofflink.c. */
43865 +
43866 +extern long _bfd_xcoff_get_dynamic_symtab_upper_bound
43867 + (bfd *);
43868 +extern long _bfd_xcoff_canonicalize_dynamic_symtab
43869 + (bfd *, asymbol **);
43870 +extern long _bfd_xcoff_get_dynamic_reloc_upper_bound
43871 + (bfd *);
43872 +extern long _bfd_xcoff_canonicalize_dynamic_reloc
43873 + (bfd *, arelent **, asymbol **);
43874 +extern struct bfd_link_hash_table *_bfd_xcoff_bfd_link_hash_table_create
43875 + (bfd *);
43876 +extern void _bfd_xcoff_bfd_link_hash_table_free
43877 + (struct bfd_link_hash_table *);
43878 +extern bfd_boolean _bfd_xcoff_bfd_link_add_symbols
43879 + (bfd *, struct bfd_link_info *);
43880 +extern bfd_boolean _bfd_xcoff_bfd_final_link
43881 + (bfd *, struct bfd_link_info *);
43882 +extern bfd_boolean _bfd_ppc_xcoff_relocate_section
43883 + (bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
43884 + struct internal_reloc *, struct internal_syment *, asection **);
43885 +
43886 +/* Functions in coff-ppc.c. FIXME: These are called be pe.em in the
43887 + linker, and so should start with bfd and be declared in bfd.h. */
43888 +
43889 +extern bfd_boolean ppc_allocate_toc_section
43890 + (struct bfd_link_info *);
43891 +extern bfd_boolean ppc_process_before_allocation
43892 + (bfd *, struct bfd_link_info *);
43893 +
43894 +/* Extracted from coffcode.h. */
43895 +typedef struct coff_ptr_struct
43896 +{
43897 + /* Remembers the offset from the first symbol in the file for
43898 + this symbol. Generated by coff_renumber_symbols. */
43899 + unsigned int offset;
43900 +
43901 + /* Should the value of this symbol be renumbered. Used for
43902 + XCOFF C_BSTAT symbols. Set by coff_slurp_symbol_table. */
43903 + unsigned int fix_value : 1;
43904 +
43905 + /* Should the tag field of this symbol be renumbered.
43906 + Created by coff_pointerize_aux. */
43907 + unsigned int fix_tag : 1;
43908 +
43909 + /* Should the endidx field of this symbol be renumbered.
43910 + Created by coff_pointerize_aux. */
43911 + unsigned int fix_end : 1;
43912 +
43913 + /* Should the x_csect.x_scnlen field be renumbered.
43914 + Created by coff_pointerize_aux. */
43915 + unsigned int fix_scnlen : 1;
43916 +
43917 + /* Fix up an XCOFF C_BINCL/C_EINCL symbol. The value is the
43918 + index into the line number entries. Set by coff_slurp_symbol_table. */
43919 + unsigned int fix_line : 1;
43920 +
43921 + /* The container for the symbol structure as read and translated
43922 + from the file. */
43923 + union
43924 + {
43925 + union internal_auxent auxent;
43926 + struct internal_syment syment;
43927 + } u;
43928 +} combined_entry_type;
43929 +
43930 +
43931 +/* Each canonical asymbol really looks like this: */
43932 +
43933 +typedef struct coff_symbol_struct
43934 +{
43935 + /* The actual symbol which the rest of BFD works with */
43936 + asymbol symbol;
43937 +
43938 + /* A pointer to the hidden information for this symbol */
43939 + combined_entry_type *native;
43940 +
43941 + /* A pointer to the linenumber information for this symbol */
43942 + struct lineno_cache_entry *lineno;
43943 +
43944 + /* Have the line numbers been relocated yet ? */
43945 + bfd_boolean done_lineno;
43946 +} coff_symbol_type;
43947 +/* COFF symbol classifications. */
43948 +
43949 +enum coff_symbol_classification
43950 +{
43951 + /* Global symbol. */
43952 + COFF_SYMBOL_GLOBAL,
43953 + /* Common symbol. */
43954 + COFF_SYMBOL_COMMON,
43955 + /* Undefined symbol. */
43956 + COFF_SYMBOL_UNDEFINED,
43957 + /* Local symbol. */
43958 + COFF_SYMBOL_LOCAL,
43959 + /* PE section symbol. */
43960 + COFF_SYMBOL_PE_SECTION
43961 +};
43962 +
43963 +typedef struct
43964 +{
43965 + void (*_bfd_coff_swap_aux_in)
43966 + (bfd *, void *, int, int, int, int, void *);
43967 +
43968 + void (*_bfd_coff_swap_sym_in)
43969 + (bfd *, void *, void *);
43970 +
43971 + void (*_bfd_coff_swap_lineno_in)
43972 + (bfd *, void *, void *);
43973 +
43974 + unsigned int (*_bfd_coff_swap_aux_out)
43975 + (bfd *, void *, int, int, int, int, void *);
43976 +
43977 + unsigned int (*_bfd_coff_swap_sym_out)
43978 + (bfd *, void *, void *);
43979 +
43980 + unsigned int (*_bfd_coff_swap_lineno_out)
43981 + (bfd *, void *, void *);
43982 +
43983 + unsigned int (*_bfd_coff_swap_reloc_out)
43984 + (bfd *, void *, void *);
43985 +
43986 + unsigned int (*_bfd_coff_swap_filehdr_out)
43987 + (bfd *, void *, void *);
43988 +
43989 + unsigned int (*_bfd_coff_swap_aouthdr_out)
43990 + (bfd *, void *, void *);
43991 +
43992 + unsigned int (*_bfd_coff_swap_scnhdr_out)
43993 + (bfd *, void *, void *);
43994 +
43995 + unsigned int _bfd_filhsz;
43996 + unsigned int _bfd_aoutsz;
43997 + unsigned int _bfd_scnhsz;
43998 + unsigned int _bfd_symesz;
43999 + unsigned int _bfd_auxesz;
44000 + unsigned int _bfd_relsz;
44001 + unsigned int _bfd_linesz;
44002 + unsigned int _bfd_filnmlen;
44003 + bfd_boolean _bfd_coff_long_filenames;
44004 + bfd_boolean _bfd_coff_long_section_names;
44005 + unsigned int _bfd_coff_default_section_alignment_power;
44006 + bfd_boolean _bfd_coff_force_symnames_in_strings;
44007 + unsigned int _bfd_coff_debug_string_prefix_length;
44008 +
44009 + void (*_bfd_coff_swap_filehdr_in)
44010 + (bfd *, void *, void *);
44011 +
44012 + void (*_bfd_coff_swap_aouthdr_in)
44013 + (bfd *, void *, void *);
44014 +
44015 + void (*_bfd_coff_swap_scnhdr_in)
44016 + (bfd *, void *, void *);
44017 +
44018 + void (*_bfd_coff_swap_reloc_in)
44019 + (bfd *abfd, void *, void *);
44020 +
44021 + bfd_boolean (*_bfd_coff_bad_format_hook)
44022 + (bfd *, void *);
44023 +
44024 + bfd_boolean (*_bfd_coff_set_arch_mach_hook)
44025 + (bfd *, void *);
44026 +
44027 + void * (*_bfd_coff_mkobject_hook)
44028 + (bfd *, void *, void *);
44029 +
44030 + bfd_boolean (*_bfd_styp_to_sec_flags_hook)
44031 + (bfd *, void *, const char *, asection *, flagword *);
44032 +
44033 + void (*_bfd_set_alignment_hook)
44034 + (bfd *, asection *, void *);
44035 +
44036 + bfd_boolean (*_bfd_coff_slurp_symbol_table)
44037 + (bfd *);
44038 +
44039 + bfd_boolean (*_bfd_coff_symname_in_debug)
44040 + (bfd *, struct internal_syment *);
44041 +
44042 + bfd_boolean (*_bfd_coff_pointerize_aux_hook)
44043 + (bfd *, combined_entry_type *, combined_entry_type *,
44044 + unsigned int, combined_entry_type *);
44045 +
44046 + bfd_boolean (*_bfd_coff_print_aux)
44047 + (bfd *, FILE *, combined_entry_type *, combined_entry_type *,
44048 + combined_entry_type *, unsigned int);
44049 +
44050 + void (*_bfd_coff_reloc16_extra_cases)
44051 + (bfd *, struct bfd_link_info *, struct bfd_link_order *, arelent *,
44052 + bfd_byte *, unsigned int *, unsigned int *);
44053 +
44054 + int (*_bfd_coff_reloc16_estimate)
44055 + (bfd *, asection *, arelent *, unsigned int,
44056 + struct bfd_link_info *);
44057 +
44058 + enum coff_symbol_classification (*_bfd_coff_classify_symbol)
44059 + (bfd *, struct internal_syment *);
44060 +
44061 + bfd_boolean (*_bfd_coff_compute_section_file_positions)
44062 + (bfd *);
44063 +
44064 + bfd_boolean (*_bfd_coff_start_final_link)
44065 + (bfd *, struct bfd_link_info *);
44066 +
44067 + bfd_boolean (*_bfd_coff_relocate_section)
44068 + (bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
44069 + struct internal_reloc *, struct internal_syment *, asection **);
44070 +
44071 + reloc_howto_type *(*_bfd_coff_rtype_to_howto)
44072 + (bfd *, asection *, struct internal_reloc *,
44073 + struct coff_link_hash_entry *, struct internal_syment *,
44074 + bfd_vma *);
44075 +
44076 + bfd_boolean (*_bfd_coff_adjust_symndx)
44077 + (bfd *, struct bfd_link_info *, bfd *, asection *,
44078 + struct internal_reloc *, bfd_boolean *);
44079 +
44080 + bfd_boolean (*_bfd_coff_link_add_one_symbol)
44081 + (struct bfd_link_info *, bfd *, const char *, flagword,
44082 + asection *, bfd_vma, const char *, bfd_boolean, bfd_boolean,
44083 + struct bfd_link_hash_entry **);
44084 +
44085 + bfd_boolean (*_bfd_coff_link_output_has_begun)
44086 + (bfd *, struct coff_final_link_info *);
44087 +
44088 + bfd_boolean (*_bfd_coff_final_link_postscript)
44089 + (bfd *, struct coff_final_link_info *);
44090 +
44091 +} bfd_coff_backend_data;
44092 +
44093 +#define coff_backend_info(abfd) \
44094 + ((bfd_coff_backend_data *) (abfd)->xvec->backend_data)
44095 +
44096 +#define bfd_coff_swap_aux_in(a,e,t,c,ind,num,i) \
44097 + ((coff_backend_info (a)->_bfd_coff_swap_aux_in) (a,e,t,c,ind,num,i))
44098 +
44099 +#define bfd_coff_swap_sym_in(a,e,i) \
44100 + ((coff_backend_info (a)->_bfd_coff_swap_sym_in) (a,e,i))
44101 +
44102 +#define bfd_coff_swap_lineno_in(a,e,i) \
44103 + ((coff_backend_info ( a)->_bfd_coff_swap_lineno_in) (a,e,i))
44104 +
44105 +#define bfd_coff_swap_reloc_out(abfd, i, o) \
44106 + ((coff_backend_info (abfd)->_bfd_coff_swap_reloc_out) (abfd, i, o))
44107 +
44108 +#define bfd_coff_swap_lineno_out(abfd, i, o) \
44109 + ((coff_backend_info (abfd)->_bfd_coff_swap_lineno_out) (abfd, i, o))
44110 +
44111 +#define bfd_coff_swap_aux_out(a,i,t,c,ind,num,o) \
44112 + ((coff_backend_info (a)->_bfd_coff_swap_aux_out) (a,i,t,c,ind,num,o))
44113 +
44114 +#define bfd_coff_swap_sym_out(abfd, i,o) \
44115 + ((coff_backend_info (abfd)->_bfd_coff_swap_sym_out) (abfd, i, o))
44116 +
44117 +#define bfd_coff_swap_scnhdr_out(abfd, i,o) \
44118 + ((coff_backend_info (abfd)->_bfd_coff_swap_scnhdr_out) (abfd, i, o))
44119 +
44120 +#define bfd_coff_swap_filehdr_out(abfd, i,o) \
44121 + ((coff_backend_info (abfd)->_bfd_coff_swap_filehdr_out) (abfd, i, o))
44122 +
44123 +#define bfd_coff_swap_aouthdr_out(abfd, i,o) \
44124 + ((coff_backend_info (abfd)->_bfd_coff_swap_aouthdr_out) (abfd, i, o))
44125 +
44126 +#define bfd_coff_filhsz(abfd) (coff_backend_info (abfd)->_bfd_filhsz)
44127 +#define bfd_coff_aoutsz(abfd) (coff_backend_info (abfd)->_bfd_aoutsz)
44128 +#define bfd_coff_scnhsz(abfd) (coff_backend_info (abfd)->_bfd_scnhsz)
44129 +#define bfd_coff_symesz(abfd) (coff_backend_info (abfd)->_bfd_symesz)
44130 +#define bfd_coff_auxesz(abfd) (coff_backend_info (abfd)->_bfd_auxesz)
44131 +#define bfd_coff_relsz(abfd) (coff_backend_info (abfd)->_bfd_relsz)
44132 +#define bfd_coff_linesz(abfd) (coff_backend_info (abfd)->_bfd_linesz)
44133 +#define bfd_coff_filnmlen(abfd) (coff_backend_info (abfd)->_bfd_filnmlen)
44134 +#define bfd_coff_long_filenames(abfd) \
44135 + (coff_backend_info (abfd)->_bfd_coff_long_filenames)
44136 +#define bfd_coff_long_section_names(abfd) \
44137 + (coff_backend_info (abfd)->_bfd_coff_long_section_names)
44138 +#define bfd_coff_default_section_alignment_power(abfd) \
44139 + (coff_backend_info (abfd)->_bfd_coff_default_section_alignment_power)
44140 +#define bfd_coff_swap_filehdr_in(abfd, i,o) \
44141 + ((coff_backend_info (abfd)->_bfd_coff_swap_filehdr_in) (abfd, i, o))
44142 +
44143 +#define bfd_coff_swap_aouthdr_in(abfd, i,o) \
44144 + ((coff_backend_info (abfd)->_bfd_coff_swap_aouthdr_in) (abfd, i, o))
44145 +
44146 +#define bfd_coff_swap_scnhdr_in(abfd, i,o) \
44147 + ((coff_backend_info (abfd)->_bfd_coff_swap_scnhdr_in) (abfd, i, o))
44148 +
44149 +#define bfd_coff_swap_reloc_in(abfd, i, o) \
44150 + ((coff_backend_info (abfd)->_bfd_coff_swap_reloc_in) (abfd, i, o))
44151 +
44152 +#define bfd_coff_bad_format_hook(abfd, filehdr) \
44153 + ((coff_backend_info (abfd)->_bfd_coff_bad_format_hook) (abfd, filehdr))
44154 +
44155 +#define bfd_coff_set_arch_mach_hook(abfd, filehdr)\
44156 + ((coff_backend_info (abfd)->_bfd_coff_set_arch_mach_hook) (abfd, filehdr))
44157 +#define bfd_coff_mkobject_hook(abfd, filehdr, aouthdr)\
44158 + ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook)\
44159 + (abfd, filehdr, aouthdr))
44160 +
44161 +#define bfd_coff_styp_to_sec_flags_hook(abfd, scnhdr, name, section, flags_ptr)\
44162 + ((coff_backend_info (abfd)->_bfd_styp_to_sec_flags_hook)\
44163 + (abfd, scnhdr, name, section, flags_ptr))
44164 +
44165 +#define bfd_coff_set_alignment_hook(abfd, sec, scnhdr)\
44166 + ((coff_backend_info (abfd)->_bfd_set_alignment_hook) (abfd, sec, scnhdr))
44167 +
44168 +#define bfd_coff_slurp_symbol_table(abfd)\
44169 + ((coff_backend_info (abfd)->_bfd_coff_slurp_symbol_table) (abfd))
44170 +
44171 +#define bfd_coff_symname_in_debug(abfd, sym)\
44172 + ((coff_backend_info (abfd)->_bfd_coff_symname_in_debug) (abfd, sym))
44173 +
44174 +#define bfd_coff_force_symnames_in_strings(abfd)\
44175 + (coff_backend_info (abfd)->_bfd_coff_force_symnames_in_strings)
44176 +
44177 +#define bfd_coff_debug_string_prefix_length(abfd)\
44178 + (coff_backend_info (abfd)->_bfd_coff_debug_string_prefix_length)
44179 +
44180 +#define bfd_coff_print_aux(abfd, file, base, symbol, aux, indaux)\
44181 + ((coff_backend_info (abfd)->_bfd_coff_print_aux)\
44182 + (abfd, file, base, symbol, aux, indaux))
44183 +
44184 +#define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order,\
44185 + reloc, data, src_ptr, dst_ptr)\
44186 + ((coff_backend_info (abfd)->_bfd_coff_reloc16_extra_cases)\
44187 + (abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr))
44188 +
44189 +#define bfd_coff_reloc16_estimate(abfd, section, reloc, shrink, link_info)\
44190 + ((coff_backend_info (abfd)->_bfd_coff_reloc16_estimate)\
44191 + (abfd, section, reloc, shrink, link_info))
44192 +
44193 +#define bfd_coff_classify_symbol(abfd, sym)\
44194 + ((coff_backend_info (abfd)->_bfd_coff_classify_symbol)\
44195 + (abfd, sym))
44196 +
44197 +#define bfd_coff_compute_section_file_positions(abfd)\
44198 + ((coff_backend_info (abfd)->_bfd_coff_compute_section_file_positions)\
44199 + (abfd))
44200 +
44201 +#define bfd_coff_start_final_link(obfd, info)\
44202 + ((coff_backend_info (obfd)->_bfd_coff_start_final_link)\
44203 + (obfd, info))
44204 +#define bfd_coff_relocate_section(obfd,info,ibfd,o,con,rel,isyms,secs)\
44205 + ((coff_backend_info (ibfd)->_bfd_coff_relocate_section)\
44206 + (obfd, info, ibfd, o, con, rel, isyms, secs))
44207 +#define bfd_coff_rtype_to_howto(abfd, sec, rel, h, sym, addendp)\
44208 + ((coff_backend_info (abfd)->_bfd_coff_rtype_to_howto)\
44209 + (abfd, sec, rel, h, sym, addendp))
44210 +#define bfd_coff_adjust_symndx(obfd, info, ibfd, sec, rel, adjustedp)\
44211 + ((coff_backend_info (abfd)->_bfd_coff_adjust_symndx)\
44212 + (obfd, info, ibfd, sec, rel, adjustedp))
44213 +#define bfd_coff_link_add_one_symbol(info, abfd, name, flags, section,\
44214 + value, string, cp, coll, hashp)\
44215 + ((coff_backend_info (abfd)->_bfd_coff_link_add_one_symbol)\
44216 + (info, abfd, name, flags, section, value, string, cp, coll, hashp))
44217 +
44218 +#define bfd_coff_link_output_has_begun(a,p) \
44219 + ((coff_backend_info (a)->_bfd_coff_link_output_has_begun) (a, p))
44220 +#define bfd_coff_final_link_postscript(a,p) \
44221 + ((coff_backend_info (a)->_bfd_coff_final_link_postscript) (a, p))
44222 +
44223 --- a/bfd/libbfd.h
44224 +++ b/bfd/libbfd.h
44225 @@ -1601,6 +1601,48 @@ static const char *const bfd_reloc_code_
44226 "BFD_RELOC_AVR_LDI",
44227 "BFD_RELOC_AVR_6",
44228 "BFD_RELOC_AVR_6_ADIW",
44229 + "BFD_RELOC_AVR32_DIFF32",
44230 + "BFD_RELOC_AVR32_DIFF16",
44231 + "BFD_RELOC_AVR32_DIFF8",
44232 + "BFD_RELOC_AVR32_GOT32",
44233 + "BFD_RELOC_AVR32_GOT16",
44234 + "BFD_RELOC_AVR32_GOT8",
44235 + "BFD_RELOC_AVR32_21S",
44236 + "BFD_RELOC_AVR32_16U",
44237 + "BFD_RELOC_AVR32_16S",
44238 + "BFD_RELOC_AVR32_SUB5",
44239 + "BFD_RELOC_AVR32_8S_EXT",
44240 + "BFD_RELOC_AVR32_8S",
44241 + "BFD_RELOC_AVR32_15S",
44242 + "BFD_RELOC_AVR32_22H_PCREL",
44243 + "BFD_RELOC_AVR32_18W_PCREL",
44244 + "BFD_RELOC_AVR32_16B_PCREL",
44245 + "BFD_RELOC_AVR32_16N_PCREL",
44246 + "BFD_RELOC_AVR32_14UW_PCREL",
44247 + "BFD_RELOC_AVR32_11H_PCREL",
44248 + "BFD_RELOC_AVR32_10UW_PCREL",
44249 + "BFD_RELOC_AVR32_9H_PCREL",
44250 + "BFD_RELOC_AVR32_9UW_PCREL",
44251 + "BFD_RELOC_AVR32_GOTPC",
44252 + "BFD_RELOC_AVR32_GOTCALL",
44253 + "BFD_RELOC_AVR32_LDA_GOT",
44254 + "BFD_RELOC_AVR32_GOT21S",
44255 + "BFD_RELOC_AVR32_GOT18SW",
44256 + "BFD_RELOC_AVR32_GOT16S",
44257 + "BFD_RELOC_AVR32_32_CPENT",
44258 + "BFD_RELOC_AVR32_CPCALL",
44259 + "BFD_RELOC_AVR32_16_CP",
44260 + "BFD_RELOC_AVR32_9W_CP",
44261 + "BFD_RELOC_AVR32_ALIGN",
44262 + "BFD_RELOC_AVR32_14UW",
44263 + "BFD_RELOC_AVR32_10UW",
44264 + "BFD_RELOC_AVR32_10SW",
44265 + "BFD_RELOC_AVR32_STHH_W",
44266 + "BFD_RELOC_AVR32_7UW",
44267 + "BFD_RELOC_AVR32_6S",
44268 + "BFD_RELOC_AVR32_6UW",
44269 + "BFD_RELOC_AVR32_4UH",
44270 + "BFD_RELOC_AVR32_3U",
44271 "BFD_RELOC_390_12",
44272 "BFD_RELOC_390_GOT12",
44273 "BFD_RELOC_390_PLT32",
44274 --- /dev/null
44275 +++ b/bfd/libtool
44276 @@ -0,0 +1,7871 @@
44277 +#! /bin/bash
44278 +
44279 +# libtool - Provide generalized library-building support services.
44280 +# Generated automatically by config.status (bfd) 2.18
44281 +# Libtool was configured on host hcegtvedt:
44282 +# NOTE: Changes made to this file will be lost: look at ltmain.sh.
44283 +#
44284 +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
44285 +# 2006, 2007, 2008 Free Software Foundation, Inc.
44286 +# Written by Gordon Matzigkeit, 1996
44287 +#
44288 +# This file is part of GNU Libtool.
44289 +#
44290 +# GNU Libtool is free software; you can redistribute it and/or
44291 +# modify it under the terms of the GNU General Public License as
44292 +# published by the Free Software Foundation; either version 2 of
44293 +# the License, or (at your option) any later version.
44294 +#
44295 +# As a special exception to the GNU General Public License,
44296 +# if you distribute this file as part of a program or library that
44297 +# is built using GNU Libtool, you may include this file under the
44298 +# same distribution terms that you use for the rest of that program.
44299 +#
44300 +# GNU Libtool is distributed in the hope that it will be useful,
44301 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
44302 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
44303 +# GNU General Public License for more details.
44304 +#
44305 +# You should have received a copy of the GNU General Public License
44306 +# along with GNU Libtool; see the file COPYING. If not, a copy
44307 +# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
44308 +# obtained by writing to the Free Software Foundation, Inc.,
44309 +# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
44310 +
44311 +
44312 +# The names of the tagged configurations supported by this script.
44313 +available_tags=""
44314 +
44315 +# ### BEGIN LIBTOOL CONFIG
44316 +
44317 +# Whether or not to build shared libraries.
44318 +build_libtool_libs=no
44319 +
44320 +# Which release of libtool.m4 was used?
44321 +macro_version=2.2.4
44322 +macro_revision=1.2976
44323 +
44324 +# Whether or not to build static libraries.
44325 +build_old_libs=yes
44326 +
44327 +# What type of objects to build.
44328 +pic_mode=default
44329 +
44330 +# Whether or not to optimize for fast installation.
44331 +fast_install=needless
44332 +
44333 +# The host system.
44334 +host_alias=i686-pc-linux-gnu
44335 +host=i686-pc-linux-gnu
44336 +host_os=linux-gnu
44337 +
44338 +# The build system.
44339 +build_alias=i686-pc-linux-gnu
44340 +build=i686-pc-linux-gnu
44341 +build_os=linux-gnu
44342 +
44343 +# A sed program that does not truncate output.
44344 +SED="/bin/sed"
44345 +
44346 +# Sed that helps us avoid accidentally triggering echo(1) options like -n.
44347 +Xsed="$SED -e 1s/^X//"
44348 +
44349 +# A grep program that handles long lines.
44350 +GREP="/bin/grep"
44351 +
44352 +# An ERE matcher.
44353 +EGREP="/bin/grep -E"
44354 +
44355 +# A literal string matcher.
44356 +FGREP="/bin/grep -F"
44357 +
44358 +# A BSD- or MS-compatible name lister.
44359 +NM="nm"
44360 +
44361 +# Whether we need soft or hard links.
44362 +LN_S="ln -s"
44363 +
44364 +# What is the maximum length of a command?
44365 +max_cmd_len=805306365
44366 +
44367 +# Object file suffix (normally "o").
44368 +objext=o
44369 +
44370 +# Executable file suffix (normally "").
44371 +exeext=
44372 +
44373 +# whether the shell understands "unset".
44374 +lt_unset=unset
44375 +
44376 +# turn spaces into newlines.
44377 +SP2NL="tr \\040 \\012"
44378 +
44379 +# turn newlines into spaces.
44380 +NL2SP="tr \\015\\012 \\040\\040"
44381 +
44382 +# How to create reloadable object files.
44383 +reload_flag=" -r"
44384 +reload_cmds="\$LD\$reload_flag -o \$output\$reload_objs"
44385 +
44386 +# Method to check whether dependent libraries are shared objects.
44387 +deplibs_check_method="pass_all"
44388 +
44389 +# Command to use when deplibs_check_method == "file_magic".
44390 +file_magic_cmd="\$MAGIC_CMD"
44391 +
44392 +# The archiver.
44393 +AR="ar"
44394 +AR_FLAGS="cru"
44395 +
44396 +# A symbol stripping program.
44397 +STRIP="strip"
44398 +
44399 +# Commands used to install an old-style archive.
44400 +RANLIB="ranlib"
44401 +old_postinstall_cmds="chmod 644 \$oldlib~\$RANLIB \$oldlib"
44402 +old_postuninstall_cmds=""
44403 +
44404 +# A C compiler.
44405 +LTCC="gcc"
44406 +
44407 +# LTCC compiler flags.
44408 +LTCFLAGS="-g -O2"
44409 +
44410 +# Take the output of nm and produce a listing of raw symbols and C names.
44411 +global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[ ][ ]*\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 \\2 \\2/p'"
44412 +
44413 +# Transform the output of nm in a proper C declaration.
44414 +global_symbol_to_cdecl="sed -n -e 's/^T .* \\(.*\\)\$/extern int \\1();/p' -e 's/^[ABCDGIRSTW]* .* \\(.*\\)\$/extern char \\1;/p'"
44415 +
44416 +# Transform the output of nm in a C name address pair.
44417 +global_symbol_to_c_name_address="sed -n -e 's/^: \\([^ ]*\\) \$/ {\\\"\\1\\\", (void *) 0},/p' -e 's/^[ABCDGIRSTW]* \\([^ ]*\\) \\([^ ]*\\)\$/ {\"\\2\", (void *) \\&\\2},/p'"
44418 +
44419 +# Transform the output of nm in a C name address pair when lib prefix is needed.
44420 +global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \\([^ ]*\\) \$/ {\\\"\\1\\\", (void *) 0},/p' -e 's/^[ABCDGIRSTW]* \\([^ ]*\\) \\(lib[^ ]*\\)\$/ {\"\\2\", (void *) \\&\\2},/p' -e 's/^[ABCDGIRSTW]* \\([^ ]*\\) \\([^ ]*\\)\$/ {\"lib\\2\", (void *) \\&\\2},/p'"
44421 +
44422 +# The name of the directory that contains temporary libtool files.
44423 +objdir=.libs
44424 +
44425 +# Shell to use when invoking shell scripts.
44426 +SHELL="/bin/bash"
44427 +
44428 +# An echo program that does not interpret backslashes.
44429 +ECHO="echo"
44430 +
44431 +# Used to examine libraries when file_magic_cmd begins with "file".
44432 +MAGIC_CMD=file
44433 +
44434 +# Must we lock files when doing compilation?
44435 +need_locks="no"
44436 +
44437 +# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
44438 +DSYMUTIL=""
44439 +
44440 +# Tool to change global to local symbols on Mac OS X.
44441 +NMEDIT=""
44442 +
44443 +# Tool to manipulate fat objects and archives on Mac OS X.
44444 +LIPO=""
44445 +
44446 +# ldd/readelf like tool for Mach-O binaries on Mac OS X.
44447 +OTOOL=""
44448 +
44449 +# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
44450 +OTOOL64=""
44451 +
44452 +# Old archive suffix (normally "a").
44453 +libext=a
44454 +
44455 +# Shared library suffix (normally ".so").
44456 +shrext_cmds=".so"
44457 +
44458 +# The commands to extract the exported symbol list from a shared archive.
44459 +extract_expsyms_cmds=""
44460 +
44461 +# Variables whose values should be saved in libtool wrapper scripts and
44462 +# restored at link time.
44463 +variables_saved_for_relink="PATH LD_LIBRARY_PATH LD_RUN_PATH GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
44464 +
44465 +# Do we need the "lib" prefix for modules?
44466 +need_lib_prefix=no
44467 +
44468 +# Do we need a version for libraries?
44469 +need_version=no
44470 +
44471 +# Library versioning type.
44472 +version_type=linux
44473 +
44474 +# Shared library runtime path variable.
44475 +runpath_var=LD_RUN_PATH
44476 +
44477 +# Shared library path variable.
44478 +shlibpath_var=LD_LIBRARY_PATH
44479 +
44480 +# Is shlibpath searched before the hard-coded library search path?
44481 +shlibpath_overrides_runpath=no
44482 +
44483 +# Format of library name prefix.
44484 +libname_spec="lib\$name"
44485 +
44486 +# List of archive names. First name is the real one, the rest are links.
44487 +# The last name is the one that the linker finds with -lNAME
44488 +library_names_spec="\${libname}\${release}\${shared_ext}\$versuffix \${libname}\${release}\${shared_ext}\$major \$libname\${shared_ext}"
44489 +
44490 +# The coded name of the library, if different from the real name.
44491 +soname_spec="\${libname}\${release}\${shared_ext}\$major"
44492 +
44493 +# Command to use after installation of a shared archive.
44494 +postinstall_cmds=""
44495 +
44496 +# Command to use after uninstallation of a shared archive.
44497 +postuninstall_cmds=""
44498 +
44499 +# Commands used to finish a libtool library installation in a directory.
44500 +finish_cmds="PATH=\\\"\\\$PATH:/sbin\\\" ldconfig -n \$libdir"
44501 +
44502 +# As "finish_cmds", except a single script fragment to be evaled but
44503 +# not shown.
44504 +finish_eval=""
44505 +
44506 +# Whether we should hardcode library paths into libraries.
44507 +hardcode_into_libs=yes
44508 +
44509 +# Compile-time system search path for libraries.
44510 +sys_lib_search_path_spec="/usr/lib/gcc/i486-linux-gnu/4.2.4 /usr/lib /lib"
44511 +
44512 +# Run-time system search path for libraries.
44513 +sys_lib_dlsearch_path_spec="/lib /usr/lib /lib/i486-linux-gnu /usr/lib/i486-linux-gnu /usr/lib/alsa-lib /usr/local/lib "
44514 +
44515 +# Whether dlopen is supported.
44516 +dlopen_support=unknown
44517 +
44518 +# Whether dlopen of programs is supported.
44519 +dlopen_self=unknown
44520 +
44521 +# Whether dlopen of statically linked programs is supported.
44522 +dlopen_self_static=unknown
44523 +
44524 +# Commands to strip libraries.
44525 +old_striplib="strip --strip-debug"
44526 +striplib="strip --strip-unneeded"
44527 +
44528 +
44529 +# The linker used to build libraries.
44530 +LD="ld"
44531 +
44532 +# Commands used to build an old-style archive.
44533 +old_archive_cmds="\$AR \$AR_FLAGS \$oldlib\$oldobjs~\$RANLIB \$oldlib"
44534 +
44535 +# A language specific compiler.
44536 +CC="gcc"
44537 +
44538 +# Is the compiler the GNU compiler?
44539 +with_gcc=yes
44540 +
44541 +# Compiler flag to turn off builtin functions.
44542 +no_builtin_flag=" -fno-builtin"
44543 +
44544 +# How to pass a linker flag through the compiler.
44545 +wl="-Wl,"
44546 +
44547 +# Additional compiler flags for building library objects.
44548 +pic_flag=" -fPIC -DPIC"
44549 +
44550 +# Compiler flag to prevent dynamic linking.
44551 +link_static_flag="-static"
44552 +
44553 +# Does compiler simultaneously support -c and -o options?
44554 +compiler_c_o="yes"
44555 +
44556 +# Whether or not to add -lc for building shared libraries.
44557 +build_libtool_need_lc=yes
44558 +
44559 +# Whether or not to disallow shared libs when runtime libs are static.
44560 +allow_libtool_libs_with_static_runtimes=no
44561 +
44562 +# Compiler flag to allow reflexive dlopens.
44563 +export_dynamic_flag_spec="\${wl}--export-dynamic"
44564 +
44565 +# Compiler flag to generate shared objects directly from archives.
44566 +whole_archive_flag_spec="\${wl}--whole-archive\$convenience \${wl}--no-whole-archive"
44567 +
44568 +# Whether the compiler copes with passing no objects directly.
44569 +compiler_needs_object="no"
44570 +
44571 +# Create an old-style archive from a shared archive.
44572 +old_archive_from_new_cmds=""
44573 +
44574 +# Create a temporary old-style archive to link instead of a shared archive.
44575 +old_archive_from_expsyms_cmds=""
44576 +
44577 +# Commands used to build a shared archive.
44578 +archive_cmds="\$CC -shared \$libobjs \$deplibs \$compiler_flags \${wl}-soname \$wl\$soname -o \$lib"
44579 +archive_expsym_cmds="echo \\\"{ global:\\\" > \$output_objdir/\$libname.ver~
44580 + cat \$export_symbols | sed -e \\\"s/\\\\(.*\\\\)/\\\\1;/\\\" >> \$output_objdir/\$libname.ver~
44581 + echo \\\"local: *; };\\\" >> \$output_objdir/\$libname.ver~
44582 + \$CC -shared \$libobjs \$deplibs \$compiler_flags \${wl}-soname \$wl\$soname \${wl}-version-script \${wl}\$output_objdir/\$libname.ver -o \$lib"
44583 +
44584 +# Commands used to build a loadable module if different from building
44585 +# a shared archive.
44586 +module_cmds=""
44587 +module_expsym_cmds=""
44588 +
44589 +# Whether we are building with GNU ld or not.
44590 +with_gnu_ld="yes"
44591 +
44592 +# Flag that allows shared libraries with undefined symbols to be built.
44593 +allow_undefined_flag=""
44594 +
44595 +# Flag that enforces no undefined symbols.
44596 +no_undefined_flag=""
44597 +
44598 +# Flag to hardcode $libdir into a binary during linking.
44599 +# This must work even if $libdir does not exist
44600 +hardcode_libdir_flag_spec="\${wl}-rpath \${wl}\$libdir"
44601 +
44602 +# If ld is used when linking, flag to hardcode $libdir into a binary
44603 +# during linking. This must work even if $libdir does not exist.
44604 +hardcode_libdir_flag_spec_ld=""
44605 +
44606 +# Whether we need a single "-rpath" flag with a separated argument.
44607 +hardcode_libdir_separator=""
44608 +
44609 +# Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
44610 +# DIR into the resulting binary.
44611 +hardcode_direct=no
44612 +
44613 +# Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
44614 +# DIR into the resulting binary and the resulting library dependency is
44615 +# "absolute",i.e impossible to change by setting ${shlibpath_var} if the
44616 +# library is relocated.
44617 +hardcode_direct_absolute=no
44618 +
44619 +# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
44620 +# into the resulting binary.
44621 +hardcode_minus_L=no
44622 +
44623 +# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
44624 +# into the resulting binary.
44625 +hardcode_shlibpath_var=unsupported
44626 +
44627 +# Set to "yes" if building a shared library automatically hardcodes DIR
44628 +# into the library and all subsequent libraries and executables linked
44629 +# against it.
44630 +hardcode_automatic=no
44631 +
44632 +# Set to yes if linker adds runtime paths of dependent libraries
44633 +# to runtime path list.
44634 +inherit_rpath=no
44635 +
44636 +# Whether libtool must link a program against all its dependency libraries.
44637 +link_all_deplibs=unknown
44638 +
44639 +# Fix the shell variable $srcfile for the compiler.
44640 +fix_srcfile_path=""
44641 +
44642 +# Set to "yes" if exported symbols are required.
44643 +always_export_symbols=no
44644 +
44645 +# The commands to list exported symbols.
44646 +export_symbols_cmds="\$NM \$libobjs \$convenience | \$global_symbol_pipe | \$SED 's/.* //' | sort | uniq > \$export_symbols"
44647 +
44648 +# Symbols that should not be listed in the preloaded symbols.
44649 +exclude_expsyms="_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*"
44650 +
44651 +# Symbols that must always be exported.
44652 +include_expsyms=""
44653 +
44654 +# Commands necessary for linking programs (against libraries) with templates.
44655 +prelink_cmds=""
44656 +
44657 +# Specify filename containing input files.
44658 +file_list_spec=""
44659 +
44660 +# How to hardcode a shared library path into an executable.
44661 +hardcode_action=immediate
44662 +
44663 +# ### END LIBTOOL CONFIG
44664 +
44665 +# Generated from ltmain.m4sh; do not edit by hand
44666 +
44667 +# ltmain.sh (GNU libtool 1.2435 2007/03/18 18:44:42) 2.1a
44668 +# Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
44669 +
44670 +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
44671 +# This is free software; see the source for copying conditions. There is NO
44672 +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
44673 +
44674 +# This program is free software; you can redistribute it and/or modify
44675 +# it under the terms of the GNU General Public License as published by
44676 +# the Free Software Foundation; either version 2 of the License, or
44677 +# (at your option) any later version.
44678 +#
44679 +# This program is distributed in the hope that it will be useful, but
44680 +# WITHOUT ANY WARRANTY; without even the implied warranty of
44681 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
44682 +# General Public License for more details.
44683 +#
44684 +# You should have received a copy of the GNU General Public License
44685 +# along with this program; if not, write to the Free Software
44686 +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
44687 +#
44688 +# As a special exception to the GNU General Public License, if you
44689 +# distribute this file as part of a program that contains a
44690 +# configuration script generated by Autoconf, you may include it under
44691 +# the same distribution terms that you use for the rest of that program.
44692 +
44693 +# Usage: $progname [OPTION]... [MODE-ARG]...
44694 +#
44695 +# Provide generalized library-building support services.
44696 +#
44697 +# --config show all configuration variables
44698 +# --debug enable verbose shell tracing
44699 +# -n, --dry-run display commands without modifying any files
44700 +# --features display basic configuration information and exit
44701 +# --mode=MODE use operation mode MODE
44702 +# --preserve-dup-deps don't remove duplicate dependency libraries
44703 +# --quiet, --silent don't print informational messages
44704 +# --tag=TAG use configuration variables from tag TAG
44705 +# -v, --verbose print informational messages (default)
44706 +# --version print version information
44707 +# -h, --help print short or long help message
44708 +#
44709 +# MODE must be one of the following:
44710 +#
44711 +# clean remove files from the build directory
44712 +# compile compile a source file into a libtool object
44713 +# execute automatically set library path, then run a program
44714 +# finish complete the installation of libtool libraries
44715 +# install install libraries or executables
44716 +# link create a library or an executable
44717 +# uninstall remove libraries from an installed directory
44718 +#
44719 +# MODE-ARGS vary depending on the MODE.
44720 +# Try `$progname --help --mode=MODE' for a more detailed description of MODE.
44721 +#
44722 +# When reporting a bug, please describe a test case to reproduce it and
44723 +# include the following information:
44724 +#
44725 +# host-triplet: $host
44726 +# shell: $SHELL
44727 +# compiler: $LTCC
44728 +# compiler flags: $LTCFLAGS
44729 +# linker: $LD (gnu? $with_gnu_ld)
44730 +# $progname: (GNU libtool 1.2435 2007/03/18 18:44:42) 2.1a
44731 +# automake: $automake_version
44732 +# autoconf: $autoconf_version
44733 +#
44734 +# Report bugs to <bug-libtool@gnu.org>.
44735 +
44736 +PROGRAM=ltmain.sh
44737 +PACKAGE=libtool
44738 +VERSION=2.1a
44739 +TIMESTAMP=" 1.2435 2007/03/18 18:44:42"
44740 +package_revision=1.2435
44741 +
44742 +# Be Bourne compatible
44743 +if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
44744 + emulate sh
44745 + NULLCMD=:
44746 + # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
44747 + # is contrary to our usage. Disable this feature.
44748 + alias -g '${1+"$@"}'='"$@"'
44749 + setopt NO_GLOB_SUBST
44750 +else
44751 + case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac
44752 +fi
44753 +BIN_SH=xpg4; export BIN_SH # for Tru64
44754 +DUALCASE=1; export DUALCASE # for MKS sh
44755 +
44756 +# NLS nuisances: We save the old values to restore during execute mode.
44757 +# Only set LANG and LC_ALL to C if already set.
44758 +# These must not be set unconditionally because not all systems understand
44759 +# e.g. LANG=C (notably SCO).
44760 +for lt_var in LANG LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
44761 +do
44762 + eval "if test \"\${$lt_var+set}\" = set; then
44763 + save_$lt_var=\$$lt_var
44764 + $lt_var=C
44765 + export $lt_var
44766 + fi"
44767 +done
44768 +
44769 +$lt_unset CDPATH
44770 +
44771 +
44772 +
44773 +
44774 +
44775 +: ${CP="cp -f"}
44776 +: ${ECHO="echo"}
44777 +: ${EGREP="/bin/grep -E"}
44778 +: ${FGREP="/bin/grep -F"}
44779 +: ${GREP="/bin/grep"}
44780 +: ${LN_S="ln -s"}
44781 +: ${MAKE="make"}
44782 +: ${MKDIR="mkdir"}
44783 +: ${MV="mv -f"}
44784 +: ${RM="rm -f"}
44785 +: ${SED="/bin/sed"}
44786 +: ${SHELL="${CONFIG_SHELL-/bin/sh}"}
44787 +: ${Xsed="$SED -e 1s/^X//"}
44788 +
44789 +# Global variables:
44790 +EXIT_SUCCESS=0
44791 +EXIT_FAILURE=1
44792 +EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing.
44793 +EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake.
44794 +
44795 +exit_status=$EXIT_SUCCESS
44796 +
44797 +# Make sure IFS has a sensible default
44798 +lt_nl='
44799 +'
44800 +IFS=" $lt_nl"
44801 +
44802 +dirname="s,/[^/]*$,,"
44803 +basename="s,^.*/,,"
44804 +
44805 +# Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh
44806 +# is ksh but when the shell is invoked as "sh" and the current value of
44807 +# the _XPG environment variable is not equal to 1 (one), the special
44808 +# positional parameter $0, within a function call, is the name of the
44809 +# function.
44810 +progpath="$0"
44811 +
44812 +# The name of this program:
44813 +# In the unlikely event $progname began with a '-', it would play havoc with
44814 +# func_echo (imagine progname=-n), so we prepend ./ in that case:
44815 +progname=`$ECHO "X$progpath" | $Xsed -e "$basename" -e 's,^-,./-,'`
44816 +
44817 +# Make sure we have an absolute path for reexecution:
44818 +case $progpath in
44819 + [\\/]*|[A-Za-z]:\\*) ;;
44820 + *[\\/]*)
44821 + progdir=`$ECHO "X$progpath" | $Xsed -e "$dirname"`
44822 + progdir=`cd "$progdir" && pwd`
44823 + progpath="$progdir/$progname"
44824 + ;;
44825 + *)
44826 + save_IFS="$IFS"
44827 + IFS=:
44828 + for progdir in $PATH; do
44829 + IFS="$save_IFS"
44830 + test -x "$progdir/$progname" && break
44831 + done
44832 + IFS="$save_IFS"
44833 + test -n "$progdir" || progdir=`pwd`
44834 + progpath="$progdir/$progname"
44835 + ;;
44836 +esac
44837 +
44838 +# Sed substitution that helps us do robust quoting. It backslashifies
44839 +# metacharacters that are still active within double-quoted strings.
44840 +Xsed="${SED}"' -e 1s/^X//'
44841 +sed_quote_subst='s/\([`"$\\]\)/\\\1/g'
44842 +
44843 +# Same as above, but do not quote variable references.
44844 +double_quote_subst='s/\(["`\\]\)/\\\1/g'
44845 +
44846 +# Re-`\' parameter expansions in output of double_quote_subst that were
44847 +# `\'-ed in input to the same. If an odd number of `\' preceded a '$'
44848 +# in input to double_quote_subst, that '$' was protected from expansion.
44849 +# Since each input `\' is now two `\'s, look for any number of runs of
44850 +# four `\'s followed by two `\'s and then a '$'. `\' that '$'.
44851 +bs='\\'
44852 +bs2='\\\\'
44853 +bs4='\\\\\\\\'
44854 +dollar='\$'
44855 +sed_double_backslash="\
44856 + s/$bs4/&\\
44857 +/g
44858 + s/^$bs2$dollar/$bs&/
44859 + s/\\([^$bs]\\)$bs2$dollar/\\1$bs2$bs$dollar/g
44860 + s/\n//g"
44861 +
44862 +# Standard options:
44863 +opt_dry_run=false
44864 +opt_help=false
44865 +opt_quiet=false
44866 +opt_verbose=false
44867 +
44868 +# func_echo arg...
44869 +# Echo program name prefixed message, along with the current mode
44870 +# name if it has been set yet.
44871 +func_echo ()
44872 +{
44873 + $ECHO "$progname${mode+: }$mode: "${1+"$@"}
44874 +}
44875 +
44876 +# func_verbose arg...
44877 +# Echo program name prefixed message in verbose mode only.
44878 +func_verbose ()
44879 +{
44880 + $opt_verbose && func_echo ${1+"$@"}
44881 +
44882 + # A bug in bash halts the script if the last line of a function
44883 + # fails when set -e is in force, so we need another command to
44884 + # work around that:
44885 + :
44886 +}
44887 +
44888 +# func_error arg...
44889 +# Echo program name prefixed message to standard error.
44890 +func_error ()
44891 +{
44892 + $ECHO "$progname${mode+: }$mode: "${1+"$@"} 1>&2
44893 +}
44894 +
44895 +# func_warning arg...
44896 +# Echo program name prefixed warning message to standard error.
44897 +func_warning ()
44898 +{
44899 + $ECHO "$progname${mode+: }$mode: warning: "${1+"$@"} 1>&2
44900 +}
44901 +
44902 +# func_fatal_error arg...
44903 +# Echo program name prefixed message to standard error, and exit.
44904 +func_fatal_error ()
44905 +{
44906 + func_error ${1+"$@"}
44907 + exit $EXIT_FAILURE
44908 +}
44909 +
44910 +# func_fatal_help arg...
44911 +# Echo program name prefixed message to standard error, followed by
44912 +# a help hint, and exit.
44913 +func_fatal_help ()
44914 +{
44915 + func_error ${1+"$@"}
44916 + func_fatal_error "$help"
44917 +}
44918 +help="Try \`$progname --help' for more information." ## default
44919 +
44920 +
44921 +# func_grep expression filename
44922 +# Check whether EXPRESSION matches any line of FILENAME, without output.
44923 +func_grep ()
44924 +{
44925 + $GREP "$1" "$2" >/dev/null 2>&1
44926 +}
44927 +
44928 +
44929 +# func_mkdir_p directory-path
44930 +# Make sure the entire path to DIRECTORY-PATH is available.
44931 +func_mkdir_p ()
44932 +{
44933 + my_directory_path="$1"
44934 + my_dir_list=
44935 +
44936 + if test -n "$my_directory_path" && test "$opt_dry_run" != ":"; then
44937 +
44938 + # Protect directory names starting with `-'
44939 + case $my_directory_path in
44940 + -*) my_directory_path="./$my_directory_path" ;;
44941 + esac
44942 +
44943 + # While some portion of DIR does not yet exist...
44944 + while test ! -d "$my_directory_path"; do
44945 + # ...make a list in topmost first order. Use a colon delimited
44946 + # list incase some portion of path contains whitespace.
44947 + my_dir_list="$my_directory_path:$my_dir_list"
44948 +
44949 + # If the last portion added has no slash in it, the list is done
44950 + case $my_directory_path in */*) ;; *) break ;; esac
44951 +
44952 + # ...otherwise throw away the child directory and loop
44953 + my_directory_path=`$ECHO "X$my_directory_path" | $Xsed -e "$dirname"`
44954 + done
44955 + my_dir_list=`$ECHO "X$my_dir_list" | $Xsed -e 's,:*$,,'`
44956 +
44957 + save_mkdir_p_IFS="$IFS"; IFS=':'
44958 + for my_dir in $my_dir_list; do
44959 + IFS="$save_mkdir_p_IFS"
44960 + # mkdir can fail with a `File exist' error if two processes
44961 + # try to create one of the directories concurrently. Don't
44962 + # stop in that case!
44963 + $MKDIR "$my_dir" 2>/dev/null || :
44964 + done
44965 + IFS="$save_mkdir_p_IFS"
44966 +
44967 + # Bail out if we (or some other process) failed to create a directory.
44968 + test -d "$my_directory_path" || \
44969 + func_fatal_error "Failed to create \`$1'"
44970 + fi
44971 +}
44972 +
44973 +
44974 +# func_mktempdir [string]
44975 +# Make a temporary directory that won't clash with other running
44976 +# libtool processes, and avoids race conditions if possible. If
44977 +# given, STRING is the basename for that directory.
44978 +func_mktempdir ()
44979 +{
44980 + my_template="${TMPDIR-/tmp}/${1-$progname}"
44981 +
44982 + if test "$opt_dry_run" = ":"; then
44983 + # Return a directory name, but don't create it in dry-run mode
44984 + my_tmpdir="${my_template}-$$"
44985 + else
44986 +
44987 + # If mktemp works, use that first and foremost
44988 + my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null`
44989 +
44990 + if test ! -d "$my_tmpdir"; then
44991 + # Failing that, at least try and use $RANDOM to avoid a race
44992 + my_tmpdir="${my_template}-${RANDOM-0}$$"
44993 +
44994 + save_mktempdir_umask=`umask`
44995 + umask 0077
44996 + $MKDIR "$my_tmpdir"
44997 + umask $save_mktempdir_umask
44998 + fi
44999 +
45000 + # If we're not in dry-run mode, bomb out on failure
45001 + test -d "$my_tmpdir" || \
45002 + func_fatal_error "cannot create temporary directory \`$my_tmpdir'"
45003 + fi
45004 +
45005 + $ECHO "X$my_tmpdir" | $Xsed
45006 +}
45007 +
45008 +
45009 +# func_quote_for_eval arg
45010 +# Aesthetically quote ARG to be evaled later.
45011 +# This function returns two values: FUNC_QUOTE_FOR_EVAL_RESULT
45012 +# is double-quoted, suitable for a subsequent eval, whereas
45013 +# FUNC_QUOTE_FOR_EVAL_UNQUOTED_RESULT has merely all characters
45014 +# which are still active within double quotes backslashified.
45015 +func_quote_for_eval ()
45016 +{
45017 + case $1 in
45018 + *[\\\`\"\$]*)
45019 + func_quote_for_eval_unquoted_result=`$ECHO "X$1" | $Xsed -e "$sed_quote_subst"` ;;
45020 + *)
45021 + func_quote_for_eval_unquoted_result="$1" ;;
45022 + esac
45023 +
45024 + case $func_quote_for_eval_unquoted_result in
45025 + # Double-quote args containing shell metacharacters to delay
45026 + # word splitting, command substitution and and variable
45027 + # expansion for a subsequent eval.
45028 + # Many Bourne shells cannot handle close brackets correctly
45029 + # in scan sets, so we specify it separately.
45030 + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
45031 + func_quote_for_eval_result="\"$func_quote_for_eval_unquoted_result\""
45032 + ;;
45033 + *)
45034 + func_quote_for_eval_result="$func_quote_for_eval_unquoted_result"
45035 + esac
45036 +}
45037 +
45038 +
45039 +# func_quote_for_expand arg
45040 +# Aesthetically quote ARG to be evaled later; same as above,
45041 +# but do not quote variable references.
45042 +func_quote_for_expand ()
45043 +{
45044 + case $1 in
45045 + *[\\\`\"]*)
45046 + my_arg=`$ECHO "X$1" | $Xsed \
45047 + -e "$double_quote_subst" -e "$sed_double_backslash"` ;;
45048 + *)
45049 + my_arg="$1" ;;
45050 + esac
45051 +
45052 + case $my_arg in
45053 + # Double-quote args containing shell metacharacters to delay
45054 + # word splitting and command substitution for a subsequent eval.
45055 + # Many Bourne shells cannot handle close brackets correctly
45056 + # in scan sets, so we specify it separately.
45057 + *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"")
45058 + my_arg="\"$my_arg\""
45059 + ;;
45060 + esac
45061 +
45062 + func_quote_for_expand_result="$my_arg"
45063 +}
45064 +
45065 +
45066 +# func_show_eval cmd [fail_exp]
45067 +# Unless opt_silent is true, then output CMD. Then, if opt_dryrun is
45068 +# not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP
45069 +# is given, then evaluate it.
45070 +func_show_eval ()
45071 +{
45072 + my_cmd="$1"
45073 + my_fail_exp="${2-:}"
45074 +
45075 + ${opt_silent-false} || {
45076 + func_quote_for_expand "$my_cmd"
45077 + eval "func_echo $func_quote_for_expand_result"
45078 + }
45079 +
45080 + if ${opt_dry_run-false}; then :; else
45081 + eval "$my_cmd"
45082 + my_status=$?
45083 + if test "$my_status" -eq 0; then :; else
45084 + eval "(exit $my_status); $my_fail_exp"
45085 + fi
45086 + fi
45087 +}
45088 +
45089 +
45090 +
45091 +
45092 +
45093 +# func_version
45094 +# Echo version message to standard output and exit.
45095 +func_version ()
45096 +{
45097 + $SED -n '/^# '$PROGRAM' (GNU /,/# warranty; / {
45098 + s/^# //
45099 + s/^# *$//
45100 + s/\((C)\)[ 0-9,-]*\( [1-9][0-9]*\)/\1\2/
45101 + p
45102 + }' < "$progpath"
45103 + exit $?
45104 +}
45105 +
45106 +# func_usage
45107 +# Echo short help message to standard output and exit.
45108 +func_usage ()
45109 +{
45110 + $SED -n '/^# Usage:/,/# -h/ {
45111 + s/^# //
45112 + s/^# *$//
45113 + s/\$progname/'$progname'/
45114 + p
45115 + }' < "$progpath"
45116 + $ECHO
45117 + $ECHO "run \`$progname --help | more' for full usage"
45118 + exit $?
45119 +}
45120 +
45121 +# func_help
45122 +# Echo long help message to standard output and exit.
45123 +func_help ()
45124 +{
45125 + $SED -n '/^# Usage:/,/# Report bugs to/ {
45126 + s/^# //
45127 + s/^# *$//
45128 + s*\$progname*'$progname'*
45129 + s*\$host*'"$host"'*
45130 + s*\$SHELL*'"$SHELL"'*
45131 + s*\$LTCC*'"$LTCC"'*
45132 + s*\$LTCFLAGS*'"$LTCFLAGS"'*
45133 + s*\$LD*'"$LD"'*
45134 + s/\$with_gnu_ld/'"$with_gnu_ld"'/
45135 + s/\$automake_version/'"`(automake --version) 2>/dev/null |$SED 1q`"'/
45136 + s/\$autoconf_version/'"`(autoconf --version) 2>/dev/null |$SED 1q`"'/
45137 + p
45138 + }' < "$progpath"
45139 + exit $?
45140 +}
45141 +
45142 +# func_missing_arg argname
45143 +# Echo program name prefixed message to standard error and set global
45144 +# exit_cmd.
45145 +func_missing_arg ()
45146 +{
45147 + func_error "missing argument for $1"
45148 + exit_cmd=exit
45149 +}
45150 +
45151 +exit_cmd=:
45152 +
45153 +
45154 +
45155 +
45156 +
45157 +# Check that we have a working $ECHO.
45158 +if test "X$1" = X--no-reexec; then
45159 + # Discard the --no-reexec flag, and continue.
45160 + shift
45161 +elif test "X$1" = X--fallback-echo; then
45162 + # Avoid inline document here, it may be left over
45163 + :
45164 +elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t'; then
45165 + # Yippee, $ECHO works!
45166 + :
45167 +else
45168 + # Restart under the correct shell, and then maybe $ECHO will work.
45169 + exec $SHELL "$progpath" --no-reexec ${1+"$@"}
45170 +fi
45171 +
45172 +if test "X$1" = X--fallback-echo; then
45173 + # used as fallback echo
45174 + shift
45175 + cat <<EOF
45176 +$*
45177 +EOF
45178 + exit $EXIT_SUCCESS
45179 +fi
45180 +
45181 +magic="%%%MAGIC variable%%%"
45182 +
45183 +
45184 +# Global variables.
45185 +# $mode is unset
45186 +nonopt=
45187 +execute_dlfiles=
45188 +preserve_args=
45189 +lo2o="s/\\.lo\$/.${objext}/"
45190 +o2lo="s/\\.${objext}\$/.lo/"
45191 +extracted_archives=
45192 +extracted_serial=0
45193 +
45194 +opt_dry_run=false
45195 +opt_duplicate_deps=false
45196 +opt_silent=false
45197 +opt_debug=:
45198 +
45199 +# If this variable is set in any of the actions, the command in it
45200 +# will be execed at the end. This prevents here-documents from being
45201 +# left over by shells.
45202 +exec_cmd=
45203 +
45204 +# func_fatal_configuration arg...
45205 +# Echo program name prefixed message to standard error, followed by
45206 +# a configuration failure hint, and exit.
45207 +func_fatal_configuration ()
45208 +{
45209 + func_error ${1+"$@"}
45210 + func_error "See the $PACKAGE documentation for more information."
45211 + func_fatal_error "Fatal configuration error."
45212 +}
45213 +
45214 +
45215 +# func_config
45216 +# Display the configuration for all the tags in this script.
45217 +func_config ()
45218 +{
45219 + re_begincf='^# ### BEGIN LIBTOOL'
45220 + re_endcf='^# ### END LIBTOOL'
45221 +
45222 + # Default configuration.
45223 + $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath"
45224 +
45225 + # Now print the configurations for the tags.
45226 + for tagname in $taglist; do
45227 + $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath"
45228 + done
45229 +
45230 + exit $?
45231 +}
45232 +
45233 +# func_features
45234 +# Display the features supported by this script.
45235 +func_features ()
45236 +{
45237 + $ECHO "host: $host"
45238 + if test "$build_libtool_libs" = yes; then
45239 + $ECHO "enable shared libraries"
45240 + else
45241 + $ECHO "disable shared libraries"
45242 + fi
45243 + if test "$build_old_libs" = yes; then
45244 + $ECHO "enable static libraries"
45245 + else
45246 + $ECHO "disable static libraries"
45247 + fi
45248 +
45249 + exit $?
45250 +}
45251 +
45252 +# func_enable_tag tagname
45253 +# Verify that TAGNAME is valid, and either flag an error and exit, or
45254 +# enable the TAGNAME tag. We also add TAGNAME to the global $taglist
45255 +# variable here.
45256 +func_enable_tag ()
45257 +{
45258 + # Global variable:
45259 + tagname="$1"
45260 +
45261 + re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$"
45262 + re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$"
45263 + sed_extractcf="/$re_begincf/,/$re_endcf/p"
45264 +
45265 + # Validate tagname.
45266 + case $tagname in
45267 + *[!-_A-Za-z0-9,/]*)
45268 + func_fatal_error "invalid tag name: $tagname"
45269 + ;;
45270 + esac
45271 +
45272 + # Don't test for the "default" C tag, as we know it's
45273 + # there but not specially marked.
45274 + case $tagname in
45275 + CC) ;;
45276 + *)
45277 + if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then
45278 + taglist="$taglist $tagname"
45279 +
45280 + # Evaluate the configuration. Be careful to quote the path
45281 + # and the sed script, to avoid splitting on whitespace, but
45282 + # also don't use non-portable quotes within backquotes within
45283 + # quotes we have to do it in 2 steps:
45284 + extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"`
45285 + eval "$extractedcf"
45286 + else
45287 + func_error "ignoring unknown tag $tagname"
45288 + fi
45289 + ;;
45290 + esac
45291 +}
45292 +
45293 +
45294 +func_mode_help ()
45295 +{
45296 + # We need to display help for each of the modes.
45297 + case $mode in
45298 + "")
45299 + # Generic help is extracted from the usage comments
45300 + # at the start of this file.
45301 + func_help
45302 + ;;
45303 +
45304 + clean)
45305 + $ECHO \
45306 +"Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE...
45307 +
45308 +Remove files from the build directory.
45309 +
45310 +RM is the name of the program to use to delete files associated with each FILE
45311 +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed
45312 +to RM.
45313 +
45314 +If FILE is a libtool library, object or program, all the files associated
45315 +with it are deleted. Otherwise, only FILE itself is deleted using RM."
45316 + ;;
45317 +
45318 + compile)
45319 + $ECHO \
45320 +"Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE
45321 +
45322 +Compile a source file into a libtool library object.
45323 +
45324 +This mode accepts the following additional options:
45325 +
45326 + -o OUTPUT-FILE set the output file name to OUTPUT-FILE
45327 + -no-suppress do not suppress compiler output for multiple passes
45328 + -prefer-pic try to building PIC objects only
45329 + -prefer-non-pic try to building non-PIC objects only
45330 + -shared do not build a \`.o' file suitable for static linking
45331 + -static only build a \`.o' file suitable for static linking
45332 +
45333 +COMPILE-COMMAND is a command to be used in creating a \`standard' object file
45334 +from the given SOURCEFILE.
45335 +
45336 +The output file name is determined by removing the directory component from
45337 +SOURCEFILE, then substituting the C source code suffix \`.c' with the
45338 +library object suffix, \`.lo'."
45339 + ;;
45340 +
45341 + execute)
45342 + $ECHO \
45343 +"Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]...
45344 +
45345 +Automatically set library path, then run a program.
45346 +
45347 +This mode accepts the following additional options:
45348 +
45349 + -dlopen FILE add the directory containing FILE to the library path
45350 +
45351 +This mode sets the library path environment variable according to \`-dlopen'
45352 +flags.
45353 +
45354 +If any of the ARGS are libtool executable wrappers, then they are translated
45355 +into their corresponding uninstalled binary, and any of their required library
45356 +directories are added to the library path.
45357 +
45358 +Then, COMMAND is executed, with ARGS as arguments."
45359 + ;;
45360 +
45361 + finish)
45362 + $ECHO \
45363 +"Usage: $progname [OPTION]... --mode=finish [LIBDIR]...
45364 +
45365 +Complete the installation of libtool libraries.
45366 +
45367 +Each LIBDIR is a directory that contains libtool libraries.
45368 +
45369 +The commands that this mode executes may require superuser privileges. Use
45370 +the \`--dry-run' option if you just want to see what would be executed."
45371 + ;;
45372 +
45373 + install)
45374 + $ECHO \
45375 +"Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND...
45376 +
45377 +Install executables or libraries.
45378 +
45379 +INSTALL-COMMAND is the installation command. The first component should be
45380 +either the \`install' or \`cp' program.
45381 +
45382 +The following components of INSTALL-COMMAND are treated specially:
45383 +
45384 + -inst-prefix PREFIX-DIR Use PREFIX-DIR as a staging area for installation
45385 +
45386 +The rest of the components are interpreted as arguments to that command (only
45387 +BSD-compatible install options are recognized)."
45388 + ;;
45389 +
45390 + link)
45391 + $ECHO \
45392 +"Usage: $progname [OPTION]... --mode=link LINK-COMMAND...
45393 +
45394 +Link object files or libraries together to form another library, or to
45395 +create an executable program.
45396 +
45397 +LINK-COMMAND is a command using the C compiler that you would use to create
45398 +a program from several object files.
45399 +
45400 +The following components of LINK-COMMAND are treated specially:
45401 +
45402 + -all-static do not do any dynamic linking at all
45403 + -avoid-version do not add a version suffix if possible
45404 + -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime
45405 + -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols
45406 + -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3)
45407 + -export-symbols SYMFILE
45408 + try to export only the symbols listed in SYMFILE
45409 + -export-symbols-regex REGEX
45410 + try to export only the symbols matching REGEX
45411 + -LLIBDIR search LIBDIR for required installed libraries
45412 + -lNAME OUTPUT-FILE requires the installed library libNAME
45413 + -module build a library that can dlopened
45414 + -no-fast-install disable the fast-install mode
45415 + -no-install link a not-installable executable
45416 + -no-undefined declare that a library does not refer to external symbols
45417 + -o OUTPUT-FILE create OUTPUT-FILE from the specified objects
45418 + -objectlist FILE Use a list of object files found in FILE to specify objects
45419 + -precious-files-regex REGEX
45420 + don't remove output files matching REGEX
45421 + -release RELEASE specify package release information
45422 + -rpath LIBDIR the created library will eventually be installed in LIBDIR
45423 + -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries
45424 + -shared only do dynamic linking of libtool libraries
45425 + -shrext SUFFIX override the standard shared library file extension
45426 + -static do not do any dynamic linking of uninstalled libtool libraries
45427 + -static-libtool-libs
45428 + do not do any dynamic linking of libtool libraries
45429 + -version-info CURRENT[:REVISION[:AGE]]
45430 + specify library version info [each variable defaults to 0]
45431 + -weak LIBNAME declare that the target provides the LIBNAME interface
45432 +
45433 +All other options (arguments beginning with \`-') are ignored.
45434 +
45435 +Every other argument is treated as a filename. Files ending in \`.la' are
45436 +treated as uninstalled libtool libraries, other files are standard or library
45437 +object files.
45438 +
45439 +If the OUTPUT-FILE ends in \`.la', then a libtool library is created,
45440 +only library objects (\`.lo' files) may be specified, and \`-rpath' is
45441 +required, except when creating a convenience library.
45442 +
45443 +If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created
45444 +using \`ar' and \`ranlib', or on Windows using \`lib'.
45445 +
45446 +If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file
45447 +is created, otherwise an executable program is created."
45448 + ;;
45449 +
45450 + uninstall)
45451 + $ECHO \
45452 +"Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE...
45453 +
45454 +Remove libraries from an installation directory.
45455 +
45456 +RM is the name of the program to use to delete files associated with each FILE
45457 +(typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed
45458 +to RM.
45459 +
45460 +If FILE is a libtool library, all the files associated with it are deleted.
45461 +Otherwise, only FILE itself is deleted using RM."
45462 + ;;
45463 +
45464 + *)
45465 + func_fatal_help "invalid operation mode \`$mode'"
45466 + ;;
45467 + esac
45468 +
45469 + $ECHO
45470 + $ECHO "Try \`$progname --help' for more information about other modes."
45471 +
45472 + exit $?
45473 +}
45474 +
45475 +# Generated shell functions inserted here.
45476 +
45477 +# func_dirname file append nondir_replacement
45478 +# Compute the dirname of FILE. If nonempty, add APPEND to the result,
45479 +# otherwise set result to NONDIR_REPLACEMENT.
45480 +func_dirname ()
45481 +{
45482 + case ${1} in
45483 + */*) func_dirname_result="${1%/*}${2}" ;;
45484 + * ) func_dirname_result="${3}" ;;
45485 + esac
45486 +}
45487 +
45488 +# func_basename file
45489 +func_basename ()
45490 +{
45491 + func_basename_result="${1##*/}"
45492 +}
45493 +
45494 +# func_dirname_and_basename file append nondir_replacement
45495 +# perform func_basename and func_dirname in a single function
45496 +# call:
45497 +# dirname: Compute the dirname of FILE. If nonempty,
45498 +# add APPEND to the result, otherwise set result
45499 +# to NONDIR_REPLACEMENT.
45500 +# value returned in "$func_dirname_result"
45501 +# basename: Compute filename of FILE.
45502 +# value retuned in "$func_basename_result"
45503 +# Implementation must be kept synchronized with func_dirname
45504 +# and func_basename. For efficiency, we do not delegate to
45505 +# those functions but instead duplicate the functionality here.
45506 +func_dirname_and_basename ()
45507 +{
45508 + case ${1} in
45509 + */*) func_dirname_result="${1%/*}${2}" ;;
45510 + * ) func_dirname_result="${3}" ;;
45511 + esac
45512 + func_basename_result="${1##*/}"
45513 +}
45514 +
45515 +# func_stripname prefix suffix name
45516 +# strip PREFIX and SUFFIX off of NAME.
45517 +# PREFIX and SUFFIX must not contain globbing or regex special
45518 +# characters, hashes, percent signs, but SUFFIX may contain a leading
45519 +# dot (in which case that matches only a dot).
45520 +func_stripname ()
45521 +{
45522 + # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
45523 + # positional parameters, so assign one to ordinary parameter first.
45524 + func_stripname_result=${3}
45525 + func_stripname_result=${func_stripname_result#"${1}"}
45526 + func_stripname_result=${func_stripname_result%"${2}"}
45527 +}
45528 +
45529 +# func_opt_split
45530 +func_opt_split ()
45531 +{
45532 + func_opt_split_opt=${1%%=*}
45533 + func_opt_split_arg=${1#*=}
45534 +}
45535 +
45536 +# func_lo2o object
45537 +func_lo2o ()
45538 +{
45539 + case ${1} in
45540 + *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
45541 + *) func_lo2o_result=${1} ;;
45542 + esac
45543 +}
45544 +
45545 +# func_xform libobj-or-source
45546 +func_xform ()
45547 +{
45548 + func_xform_result=${1%.*}.lo
45549 +}
45550 +
45551 +# func_arith arithmetic-term...
45552 +func_arith ()
45553 +{
45554 + func_arith_result=$(( $* ))
45555 +}
45556 +
45557 +# func_len string
45558 +# STRING may not start with a hyphen.
45559 +func_len ()
45560 +{
45561 + func_len_result=${#1}
45562 +}
45563 +
45564 +
45565 +# func_append var value
45566 +# Append VALUE to the end of shell variable VAR.
45567 +func_append ()
45568 +{
45569 + eval "$1+=\$2"
45570 +}
45571 +# Generated shell functions inserted here.
45572 +
45573 +
45574 +# Parse options once, thoroughly. This comes as soon as possible in
45575 +# the script to make things like `libtool --version' happen quickly.
45576 +{
45577 +
45578 + # Shorthand for --mode=foo, only valid as the first argument
45579 + case $1 in
45580 + clean|clea|cle|cl)
45581 + shift; set dummy --mode clean ${1+"$@"}; shift
45582 + ;;
45583 + compile|compil|compi|comp|com|co|c)
45584 + shift; set dummy --mode compile ${1+"$@"}; shift
45585 + ;;
45586 + execute|execut|execu|exec|exe|ex|e)
45587 + shift; set dummy --mode execute ${1+"$@"}; shift
45588 + ;;
45589 + finish|finis|fini|fin|fi|f)
45590 + shift; set dummy --mode finish ${1+"$@"}; shift
45591 + ;;
45592 + install|instal|insta|inst|ins|in|i)
45593 + shift; set dummy --mode install ${1+"$@"}; shift
45594 + ;;
45595 + link|lin|li|l)
45596 + shift; set dummy --mode link ${1+"$@"}; shift
45597 + ;;
45598 + uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u)
45599 + shift; set dummy --mode uninstall ${1+"$@"}; shift
45600 + ;;
45601 + esac
45602 +
45603 + # Parse non-mode specific arguments:
45604 + while test "$#" -gt 0; do
45605 + opt="$1"
45606 + shift
45607 +
45608 + case $opt in
45609 + --config) func_config ;;
45610 +
45611 + --debug) preserve_args="$preserve_args $opt"
45612 + func_echo "enabling shell trace mode"
45613 + opt_debug='set -x'
45614 + $opt_debug
45615 + ;;
45616 +
45617 + -dlopen) test "$#" -eq 0 && func_missing_arg "$opt" && break
45618 + execute_dlfiles="$execute_dlfiles $1"
45619 + shift
45620 + ;;
45621 +
45622 + --dry-run | -n) opt_dry_run=: ;;
45623 + --features) func_features ;;
45624 + --finish) mode="finish" ;;
45625 +
45626 + --mode) test "$#" -eq 0 && func_missing_arg "$opt" && break
45627 + case $1 in
45628 + # Valid mode arguments:
45629 + clean) ;;
45630 + compile) ;;
45631 + execute) ;;
45632 + finish) ;;
45633 + install) ;;
45634 + link) ;;
45635 + relink) ;;
45636 + uninstall) ;;
45637 +
45638 + # Catch anything else as an error
45639 + *) func_error "invalid argument for $opt"
45640 + exit_cmd=exit
45641 + break
45642 + ;;
45643 + esac
45644 +
45645 + mode="$1"
45646 + shift
45647 + ;;
45648 +
45649 + --preserve-dup-deps)
45650 + opt_duplicate_deps=: ;;
45651 +
45652 + --quiet|--silent) preserve_args="$preserve_args $opt"
45653 + opt_silent=:
45654 + ;;
45655 +
45656 + --verbose| -v) preserve_args="$preserve_args $opt"
45657 + opt_silent=false
45658 + ;;
45659 +
45660 + --tag) test "$#" -eq 0 && func_missing_arg "$opt" && break
45661 + preserve_args="$preserve_args $opt $1"
45662 + func_enable_tag "$1" # tagname is set here
45663 + shift
45664 + ;;
45665 +
45666 + # Separate optargs to long options:
45667 + -dlopen=*|--mode=*|--tag=*)
45668 + func_opt_split "$opt"
45669 + set dummy "$func_opt_split_opt" "$func_opt_split_arg" ${1+"$@"}
45670 + shift
45671 + ;;
45672 +
45673 + -\?|-h) func_usage ;;
45674 + --help) opt_help=: ;;
45675 + --version) func_version ;;
45676 +
45677 + -*) func_fatal_help "unrecognized option \`$opt'" ;;
45678 +
45679 + *) nonopt="$opt"
45680 + break
45681 + ;;
45682 + esac
45683 + done
45684 +
45685 + # Now that we've collected a possible --mode arg, show help if necessary
45686 + $opt_help && func_mode_help
45687 +
45688 + case $host in
45689 + *cygwin* | *mingw* | *pw32*)
45690 + # don't eliminate duplications in $postdeps and $predeps
45691 + opt_duplicate_compiler_generated_deps=:
45692 + ;;
45693 + *)
45694 + opt_duplicate_compiler_generated_deps=$opt_duplicate_deps
45695 + ;;
45696 + esac
45697 +
45698 + # Having warned about all mis-specified options, bail out if
45699 + # anything was wrong.
45700 + $exit_cmd $EXIT_FAILURE
45701 +}
45702 +
45703 +# func_check_version_match
45704 +# Ensure that we are using m4 macros, and libtool script from the same
45705 +# release of libtool.
45706 +func_check_version_match ()
45707 +{
45708 + if test "$package_revision" != "$macro_revision"; then
45709 + if test "$VERSION" != "$macro_version"; then
45710 + if test -z "$macro_version"; then
45711 + cat >&2 <<_LT_EOF
45712 +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the
45713 +$progname: definition of this LT_INIT comes from an older release.
45714 +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
45715 +$progname: and run autoconf again.
45716 +_LT_EOF
45717 + else
45718 + cat >&2 <<_LT_EOF
45719 +$progname: Version mismatch error. This is $PACKAGE $VERSION, but the
45720 +$progname: definition of this LT_INIT comes from $PACKAGE $macro_version.
45721 +$progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION
45722 +$progname: and run autoconf again.
45723 +_LT_EOF
45724 + fi
45725 + else
45726 + cat >&2 <<_LT_EOF
45727 +$progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision,
45728 +$progname: but the definition of this LT_INIT comes from revision $macro_revision.
45729 +$progname: You should recreate aclocal.m4 with macros from revision $package_revision
45730 +$progname: of $PACKAGE $VERSION and run autoconf again.
45731 +_LT_EOF
45732 + fi
45733 +
45734 + exit $EXIT_MISMATCH
45735 + fi
45736 +}
45737 +
45738 +
45739 +## ----------- ##
45740 +## Main. ##
45741 +## ----------- ##
45742 +
45743 +{
45744 + # Sanity checks first:
45745 + func_check_version_match
45746 +
45747 + if test "$build_libtool_libs" != yes && test "$build_old_libs" != yes; then
45748 + func_fatal_configuration "not configured to build any kind of library"
45749 + fi
45750 +
45751 + test -z "$mode" && func_fatal_error "error: you must specify a MODE."
45752 +
45753 +
45754 + # Darwin sucks
45755 + eval std_shrext=\"$shrext_cmds\"
45756 +
45757 +
45758 + # Only execute mode is allowed to have -dlopen flags.
45759 + if test -n "$execute_dlfiles" && test "$mode" != execute; then
45760 + func_error "unrecognized option \`-dlopen'"
45761 + $ECHO "$help" 1>&2
45762 + exit $EXIT_FAILURE
45763 + fi
45764 +
45765 + # Change the help message to a mode-specific one.
45766 + generic_help="$help"
45767 + help="Try \`$progname --help --mode=$mode' for more information."
45768 +}
45769 +
45770 +
45771 +# func_lalib_p file
45772 +# True iff FILE is a libtool `.la' library or `.lo' object file.
45773 +# This function is only a basic sanity check; it will hardly flush out
45774 +# determined imposters.
45775 +func_lalib_p ()
45776 +{
45777 + $SED -e 4q "$1" 2>/dev/null \
45778 + | $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1
45779 +}
45780 +
45781 +# func_lalib_unsafe_p file
45782 +# True iff FILE is a libtool `.la' library or `.lo' object file.
45783 +# This function implements the same check as func_lalib_p without
45784 +# resorting to external programs. To this end, it redirects stdin and
45785 +# closes it afterwards, without saving the original file descriptor.
45786 +# As a safety measure, use it only where a negative result would be
45787 +# fatal anyway. Works if `file' does not exist.
45788 +func_lalib_unsafe_p ()
45789 +{
45790 + lalib_p=no
45791 + if test -r "$1" && exec 5<&1 <"$1"; then
45792 + for lalib_p_l in 1 2 3 4
45793 + do
45794 + read lalib_p_line
45795 + case "$lalib_p_line" in
45796 + \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;;
45797 + esac
45798 + done
45799 + exec 1<&5 5<&-
45800 + fi
45801 + test "$lalib_p" = yes
45802 +}
45803 +
45804 +# func_ltwrapper_p file
45805 +# True iff FILE is a libtool wrapper script.
45806 +# This function is only a basic sanity check; it will hardly flush out
45807 +# determined imposters.
45808 +func_ltwrapper_p ()
45809 +{
45810 + func_lalib_p "$1"
45811 +}
45812 +
45813 +
45814 +# func_execute_cmds commands fail_cmd
45815 +# Execute tilde-delimited COMMANDS.
45816 +# If FAIL_CMD is given, eval that upon failure.
45817 +# FAIL_CMD may read-access the current command in variable CMD!
45818 +func_execute_cmds ()
45819 +{
45820 + $opt_debug
45821 + save_ifs=$IFS; IFS='~'
45822 + for cmd in $1; do
45823 + IFS=$save_ifs
45824 + eval cmd=\"$cmd\"
45825 + func_show_eval "$cmd" "${2-:}"
45826 + done
45827 + IFS=$save_ifs
45828 +}
45829 +
45830 +
45831 +# func_source file
45832 +# Source FILE, adding directory component if necessary.
45833 +# Note that it is not necessary on cygwin/mingw to append a dot to
45834 +# FILE even if both FILE and FILE.exe exist: automatic-append-.exe
45835 +# behavior happens only for exec(3), not for open(2)! Also, sourcing
45836 +# `FILE.' does not work on cygwin managed mounts.
45837 +func_source ()
45838 +{
45839 + $opt_debug
45840 + case $1 in
45841 + */* | *\\*) . "$1" ;;
45842 + *) . "./$1" ;;
45843 + esac
45844 +}
45845 +
45846 +
45847 +# func_win32_libid arg
45848 +# return the library type of file 'arg'
45849 +#
45850 +# Need a lot of goo to handle *both* DLLs and import libs
45851 +# Has to be a shell function in order to 'eat' the argument
45852 +# that is supplied when $file_magic_command is called.
45853 +func_win32_libid ()
45854 +{
45855 + $opt_debug
45856 + win32_libid_type="unknown"
45857 + win32_fileres=`file -L $1 2>/dev/null`
45858 + case $win32_fileres in
45859 + *ar\ archive\ import\ library*) # definitely import
45860 + win32_libid_type="x86 archive import"
45861 + ;;
45862 + *ar\ archive*) # could be an import, or static
45863 + if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null |
45864 + $EGREP 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then
45865 + win32_nmres=`eval $NM -f posix -A $1 |
45866 + $SED -n -e '
45867 + 1,100{
45868 + / I /{
45869 + s,.*,import,
45870 + p
45871 + q
45872 + }
45873 + }'`
45874 + case $win32_nmres in
45875 + import*) win32_libid_type="x86 archive import";;
45876 + *) win32_libid_type="x86 archive static";;
45877 + esac
45878 + fi
45879 + ;;
45880 + *DLL*)
45881 + win32_libid_type="x86 DLL"
45882 + ;;
45883 + *executable*) # but shell scripts are "executable" too...
45884 + case $win32_fileres in
45885 + *MS\ Windows\ PE\ Intel*)
45886 + win32_libid_type="x86 DLL"
45887 + ;;
45888 + esac
45889 + ;;
45890 + esac
45891 + $ECHO "$win32_libid_type"
45892 +}
45893 +
45894 +
45895 +
45896 +# func_infer_tag arg
45897 +# Infer tagged configuration to use if any are available and
45898 +# if one wasn't chosen via the "--tag" command line option.
45899 +# Only attempt this if the compiler in the base compile
45900 +# command doesn't match the default compiler.
45901 +# arg is usually of the form 'gcc ...'
45902 +func_infer_tag ()
45903 +{
45904 + $opt_debug
45905 + if test -n "$available_tags" && test -z "$tagname"; then
45906 + CC_quoted=
45907 + for arg in $CC; do
45908 + func_quote_for_eval "$arg"
45909 + CC_quoted="$CC_quoted $func_quote_for_eval_result"
45910 + done
45911 + case $@ in
45912 + # Blanks in the command may have been stripped by the calling shell,
45913 + # but not from the CC environment variable when configure was run.
45914 + " $CC "* | "$CC "* | " `$ECHO $CC` "* | "`$ECHO $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$ECHO $CC_quoted` "* | "`$ECHO $CC_quoted` "*) ;;
45915 + # Blanks at the start of $base_compile will cause this to fail
45916 + # if we don't check for them as well.
45917 + *)
45918 + for z in $available_tags; do
45919 + if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then
45920 + # Evaluate the configuration.
45921 + eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`"
45922 + CC_quoted=
45923 + for arg in $CC; do
45924 + # Double-quote args containing other shell metacharacters.
45925 + func_quote_for_eval "$arg"
45926 + CC_quoted="$CC_quoted $func_quote_for_eval_result"
45927 + done
45928 + case "$@ " in
45929 + " $CC "* | "$CC "* | " `$ECHO $CC` "* | "`$ECHO $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$ECHO $CC_quoted` "* | "`$ECHO $CC_quoted` "*)
45930 + # The compiler in the base compile command matches
45931 + # the one in the tagged configuration.
45932 + # Assume this is the tagged configuration we want.
45933 + tagname=$z
45934 + break
45935 + ;;
45936 + esac
45937 + fi
45938 + done
45939 + # If $tagname still isn't set, then no tagged configuration
45940 + # was found and let the user know that the "--tag" command
45941 + # line option must be used.
45942 + if test -z "$tagname"; then
45943 + func_echo "unable to infer tagged configuration"
45944 + func_fatal_error "specify a tag with \`--tag'"
45945 +# else
45946 +# func_verbose "using $tagname tagged configuration"
45947 + fi
45948 + ;;
45949 + esac
45950 + fi
45951 +}
45952 +
45953 +
45954 +
45955 +# func_generate_dlsyms outputname originator pic_p
45956 +# Extract symbols from dlprefiles and create ${outputname}S.o with
45957 +# a dlpreopen symbol table.
45958 +func_generate_dlsyms ()
45959 +{
45960 + $opt_debug
45961 + my_outputname="$1"
45962 + my_originator="$2"
45963 + my_pic_p="${3-no}"
45964 + my_prefix=`$ECHO "$my_originator" | sed 's%[^a-zA-Z0-9]%_%g'`
45965 + my_dlsyms=
45966 +
45967 + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
45968 + if test -n "$NM" && test -n "$global_symbol_pipe"; then
45969 + my_dlsyms="${my_outputname}S.c"
45970 + else
45971 + func_error "not configured to extract global symbols from dlpreopened files"
45972 + fi
45973 + fi
45974 +
45975 + if test -n "$my_dlsyms"; then
45976 + case $my_dlsyms in
45977 + "") ;;
45978 + *.c)
45979 + # Discover the nlist of each of the dlfiles.
45980 + nlist="$output_objdir/${my_outputname}.nm"
45981 +
45982 + func_show_eval "$RM $nlist ${nlist}S ${nlist}T"
45983 +
45984 + # Parse the name list into a source file.
45985 + func_echo "creating $output_objdir/$my_dlsyms"
45986 +
45987 + $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\
45988 +/* $my_dlsyms - symbol resolution table for \`$my_outputname' dlsym emulation. */
45989 +/* Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION */
45990 +
45991 +#ifdef __cplusplus
45992 +extern \"C\" {
45993 +#endif
45994 +
45995 +/* External symbol declarations for the compiler. */\
45996 +"
45997 +
45998 + if test "$dlself" = yes; then
45999 + func_echo "generating symbol list for \`$output'"
46000 +
46001 + $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist"
46002 +
46003 + # Add our own program objects to the symbol list.
46004 + progfiles=`$ECHO "X$objs$old_deplibs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
46005 + for progfile in $progfiles; do
46006 + func_echo "extracting global C symbols from \`$progfile'"
46007 + $opt_dry_run || eval "$NM $progfile | $global_symbol_pipe >> '$nlist'"
46008 + done
46009 +
46010 + if test -n "$exclude_expsyms"; then
46011 + $opt_dry_run || {
46012 + eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T'
46013 + eval '$MV "$nlist"T "$nlist"'
46014 + }
46015 + fi
46016 +
46017 + if test -n "$export_symbols_regex"; then
46018 + $opt_dry_run || {
46019 + eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T'
46020 + eval '$MV "$nlist"T "$nlist"'
46021 + }
46022 + fi
46023 +
46024 + # Prepare the list of exported symbols
46025 + if test -z "$export_symbols"; then
46026 + export_symbols="$output_objdir/$outputname.exp"
46027 + $opt_dry_run || {
46028 + $RM $export_symbols
46029 + eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"'
46030 + case $host in
46031 + *cygwin* | *mingw* )
46032 + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
46033 + eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"'
46034 + ;;
46035 + esac
46036 + }
46037 + else
46038 + $opt_dry_run || {
46039 + eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"'
46040 + eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T'
46041 + eval '$MV "$nlist"T "$nlist"'
46042 + case $host in
46043 + *cygwin | *mingw* )
46044 + eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
46045 + eval 'cat "$nlist" >> "$output_objdir/$outputname.def"'
46046 + ;;
46047 + esac
46048 + }
46049 + fi
46050 + fi
46051 +
46052 + for dlprefile in $dlprefiles; do
46053 + func_echo "extracting global C symbols from \`$dlprefile'"
46054 + func_basename "$dlprefile"
46055 + name="$func_basename_result"
46056 + $opt_dry_run || {
46057 + eval '$ECHO ": $name " >> "$nlist"'
46058 + eval "$NM $dlprefile 2>/dev/null | $global_symbol_pipe >> '$nlist'"
46059 + }
46060 + done
46061 +
46062 + $opt_dry_run || {
46063 + # Make sure we have at least an empty file.
46064 + test -f "$nlist" || : > "$nlist"
46065 +
46066 + if test -n "$exclude_expsyms"; then
46067 + $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T
46068 + $MV "$nlist"T "$nlist"
46069 + fi
46070 +
46071 + # Try sorting and uniquifying the output.
46072 + if $GREP -v "^: " < "$nlist" |
46073 + if sort -k 3 </dev/null >/dev/null 2>&1; then
46074 + sort -k 3
46075 + else
46076 + sort +2
46077 + fi |
46078 + uniq > "$nlist"S; then
46079 + :
46080 + else
46081 + $GREP -v "^: " < "$nlist" > "$nlist"S
46082 + fi
46083 +
46084 + if test -f "$nlist"S; then
46085 + eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"'
46086 + else
46087 + $ECHO '/* NONE */' >> "$output_objdir/$my_dlsyms"
46088 + fi
46089 +
46090 + $ECHO >> "$output_objdir/$my_dlsyms" "\
46091 +
46092 +/* The mapping between symbol names and symbols. */
46093 +typedef struct {
46094 + const char *name;
46095 + void *address;
46096 +} lt_dlsymlist;
46097 +"
46098 + case $host in
46099 + *cygwin* | *mingw* )
46100 + $ECHO >> "$output_objdir/$my_dlsyms" "\
46101 +/* DATA imports from DLLs on WIN32 con't be const, because
46102 + runtime relocations are performed -- see ld's documentation
46103 + on pseudo-relocs. */"
46104 + lt_dlsym_const= ;;
46105 + *osf5*)
46106 + echo >> "$output_objdir/$my_dlsyms" "\
46107 +/* This system does not cope well with relocations in const data */"
46108 + lt_dlsym_const= ;;
46109 + *)
46110 + lt_dlsym_const=const ;;
46111 + esac
46112 +
46113 + $ECHO >> "$output_objdir/$my_dlsyms" "\
46114 +extern $lt_dlsym_const lt_dlsymlist
46115 +lt_${my_prefix}_LTX_preloaded_symbols[];
46116 +$lt_dlsym_const lt_dlsymlist
46117 +lt_${my_prefix}_LTX_preloaded_symbols[] =
46118 +{\
46119 + { \"$my_originator\", (void *) 0 },"
46120 +
46121 + eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms"
46122 +
46123 + $ECHO >> "$output_objdir/$my_dlsyms" "\
46124 + {0, (void *) 0}
46125 +};
46126 +
46127 +/* This works around a problem in FreeBSD linker */
46128 +#ifdef FREEBSD_WORKAROUND
46129 +static const void *lt_preloaded_setup() {
46130 + return lt_${my_prefix}_LTX_preloaded_symbols;
46131 +}
46132 +#endif
46133 +
46134 +#ifdef __cplusplus
46135 +}
46136 +#endif\
46137 +"
46138 + } # !$opt_dry_run
46139 +
46140 + pic_flag_for_symtable=
46141 + case "$compile_command " in
46142 + *" -static "*) ;;
46143 + *)
46144 + case $host in
46145 + # compiling the symbol table file with pic_flag works around
46146 + # a FreeBSD bug that causes programs to crash when -lm is
46147 + # linked before any other PIC object. But we must not use
46148 + # pic_flag when linking with -static. The problem exists in
46149 + # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1.
46150 + *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*)
46151 + pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;;
46152 + *-*-hpux*)
46153 + pic_flag_for_symtable=" $pic_flag" ;;
46154 + *)
46155 + if test "X$my_pic_p" != Xno; then
46156 + pic_flag_for_symtable=" $pic_flag"
46157 + fi
46158 + ;;
46159 + esac
46160 + ;;
46161 + esac
46162 + symtab_cflags=
46163 + for arg in $LTCFLAGS; do
46164 + case $arg in
46165 + -pie | -fpie | -fPIE) ;;
46166 + *) symtab_cflags="$symtab_cflags $arg" ;;
46167 + esac
46168 + done
46169 +
46170 + # Now compile the dynamic symbol file.
46171 + func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?'
46172 +
46173 + # Clean up the generated files.
46174 + func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T"'
46175 +
46176 + # Transform the symbol file into the correct name.
46177 + symfileobj="$output_objdir/${my_outputname}S.$objext"
46178 + case $host in
46179 + *cygwin* | *mingw* )
46180 + if test -f "$output_objdir/$my_outputname.def"; then
46181 + compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
46182 + finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"`
46183 + else
46184 + compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
46185 + finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
46186 + fi
46187 + ;;
46188 + *)
46189 + compile_command=`$ECHO "X$compile_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
46190 + finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$symfileobj%"`
46191 + ;;
46192 + esac
46193 + ;;
46194 + *)
46195 + func_fatal_error "unknown suffix for \`$my_dlsyms'"
46196 + ;;
46197 + esac
46198 + else
46199 + # We keep going just in case the user didn't refer to
46200 + # lt_preloaded_symbols. The linker will fail if global_symbol_pipe
46201 + # really was required.
46202 +
46203 + # Nullify the symbol file.
46204 + compile_command=`$ECHO "X$compile_command" | $Xsed -e "s% @SYMFILE@%%"`
46205 + finalize_command=`$ECHO "X$finalize_command" | $Xsed -e "s% @SYMFILE@%%"`
46206 + fi
46207 +}
46208 +
46209 +# func_extract_an_archive dir oldlib
46210 +func_extract_an_archive ()
46211 +{
46212 + $opt_debug
46213 + f_ex_an_ar_dir="$1"; shift
46214 + f_ex_an_ar_oldlib="$1"
46215 + func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \$f_ex_an_ar_oldlib)" 'exit $?'
46216 + if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then
46217 + :
46218 + else
46219 + func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib"
46220 + fi
46221 +}
46222 +
46223 +
46224 +# func_extract_archives gentop oldlib ...
46225 +func_extract_archives ()
46226 +{
46227 + $opt_debug
46228 + my_gentop="$1"; shift
46229 + my_oldlibs=${1+"$@"}
46230 + my_oldobjs=""
46231 + my_xlib=""
46232 + my_xabs=""
46233 + my_xdir=""
46234 +
46235 + for my_xlib in $my_oldlibs; do
46236 + # Extract the objects.
46237 + case $my_xlib in
46238 + [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;;
46239 + *) my_xabs=`pwd`"/$my_xlib" ;;
46240 + esac
46241 + func_basename "$my_xlib"
46242 + my_xlib="$func_basename_result"
46243 + my_xlib_u=$my_xlib
46244 + while :; do
46245 + case " $extracted_archives " in
46246 + *" $my_xlib_u "*)
46247 + extracted_serial=`expr $extracted_serial + 1`
46248 + my_xlib_u=lt$extracted_serial-$my_xlib ;;
46249 + *) break ;;
46250 + esac
46251 + done
46252 + extracted_archives="$extracted_archives $my_xlib_u"
46253 + my_xdir="$my_gentop/$my_xlib_u"
46254 +
46255 + func_mkdir_p "$my_xdir"
46256 +
46257 + case $host in
46258 + *-darwin*)
46259 + func_echo "Extracting $my_xabs"
46260 + # Do not bother doing anything if just a dry run
46261 + $opt_dry_run || {
46262 + darwin_orig_dir=`pwd`
46263 + cd $my_xdir || exit $?
46264 + darwin_archive=$my_xabs
46265 + darwin_curdir=`pwd`
46266 + darwin_base_archive=`basename $darwin_archive`
46267 + darwin_arches=`lipo -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true`
46268 + if test -n "$darwin_arches"; then
46269 + darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'`
46270 + darwin_arch=
46271 + func_echo "$darwin_base_archive has multiple architectures $darwin_arches"
46272 + for darwin_arch in $darwin_arches ; do
46273 + func_mkdir_p "unfat-$$/${darwin_base_archive}-${darwin_arch}"
46274 + lipo -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}"
46275 + cd "unfat-$$/${darwin_base_archive}-${darwin_arch}"
46276 + func_extract_an_archive "`pwd`" "${darwin_base_archive}"
46277 + cd "$darwin_curdir"
46278 + $RM "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}"
46279 + done # $darwin_arches
46280 + ## Okay now we've a bunch of thin objects, gotta fatten them up :)
46281 + darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print| xargs basename | sort -u | $NL2SP`
46282 + darwin_file=
46283 + darwin_files=
46284 + for darwin_file in $darwin_filelist; do
46285 + darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP`
46286 + lipo -create -output "$darwin_file" $darwin_files
46287 + done # $darwin_filelist
46288 + $RM -rf unfat-$$
46289 + cd "$darwin_orig_dir"
46290 + else
46291 + cd $darwin_orig_dir
46292 + func_extract_an_archive "$my_xdir" "$my_xabs"
46293 + fi # $darwin_arches
46294 + } # !$opt_dry_run
46295 + ;;
46296 + *)
46297 + func_extract_an_archive "$my_xdir" "$my_xabs"
46298 + ;;
46299 + esac
46300 + my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP`
46301 + done
46302 +
46303 + func_extract_archives_result="$my_oldobjs"
46304 +}
46305 +
46306 +
46307 +
46308 +# func_write_libtool_object output_name pic_name nonpic_name
46309 +# Create a libtool object file (analogous to a ".la" file),
46310 +# but don't create it if we're doing a dry run.
46311 +func_write_libtool_object ()
46312 +{
46313 + write_libobj=${1}
46314 + if test "$build_libtool_libs" = yes; then
46315 + write_lobj=\'${2}\'
46316 + else
46317 + write_lobj=none
46318 + fi
46319 +
46320 + if test "$build_old_libs" = yes; then
46321 + write_oldobj=\'${3}\'
46322 + else
46323 + write_oldobj=none
46324 + fi
46325 +
46326 + $opt_dry_run || {
46327 + cat >${write_libobj}T <<EOF
46328 +# $write_libobj - a libtool object file
46329 +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
46330 +#
46331 +# Please DO NOT delete this file!
46332 +# It is necessary for linking the library.
46333 +
46334 +# Name of the PIC object.
46335 +pic_object=$write_lobj
46336 +
46337 +# Name of the non-PIC object
46338 +non_pic_object=$write_oldobj
46339 +
46340 +EOF
46341 + mv -f "${write_libobj}T" "${write_libobj}"
46342 + }
46343 +}
46344 +
46345 +# func_mode_compile arg...
46346 +func_mode_compile ()
46347 +{
46348 + $opt_debug
46349 + # Get the compilation command and the source file.
46350 + base_compile=
46351 + srcfile="$nonopt" # always keep a non-empty value in "srcfile"
46352 + suppress_opt=yes
46353 + suppress_output=
46354 + arg_mode=normal
46355 + libobj=
46356 + later=
46357 + pie_flag=
46358 +
46359 + for arg
46360 + do
46361 + case $arg_mode in
46362 + arg )
46363 + # do not "continue". Instead, add this to base_compile
46364 + lastarg="$arg"
46365 + arg_mode=normal
46366 + ;;
46367 +
46368 + target )
46369 + libobj="$arg"
46370 + arg_mode=normal
46371 + continue
46372 + ;;
46373 +
46374 + normal )
46375 + # Accept any command-line options.
46376 + case $arg in
46377 + -o)
46378 + test -n "$libobj" && \
46379 + func_fatal_error "you cannot specify \`-o' more than once"
46380 + arg_mode=target
46381 + continue
46382 + ;;
46383 +
46384 + -pie | -fpie | -fPIE)
46385 + pie_flag="$pie_flag $arg"
46386 + continue
46387 + ;;
46388 +
46389 + -shared | -static | -prefer-pic | -prefer-non-pic)
46390 + later="$later $arg"
46391 + continue
46392 + ;;
46393 +
46394 + -no-suppress)
46395 + suppress_opt=no
46396 + continue
46397 + ;;
46398 +
46399 + -Xcompiler)
46400 + arg_mode=arg # the next one goes into the "base_compile" arg list
46401 + continue # The current "srcfile" will either be retained or
46402 + ;; # replaced later. I would guess that would be a bug.
46403 +
46404 + -Wc,*)
46405 + func_stripname '-Wc,' '' "$arg"
46406 + args=$func_stripname_result
46407 + lastarg=
46408 + save_ifs="$IFS"; IFS=','
46409 + for arg in $args; do
46410 + IFS="$save_ifs"
46411 + func_quote_for_eval "$arg"
46412 + lastarg="$lastarg $func_quote_for_eval_result"
46413 + done
46414 + IFS="$save_ifs"
46415 + func_stripname ' ' '' "$lastarg"
46416 + lastarg=$func_stripname_result
46417 +
46418 + # Add the arguments to base_compile.
46419 + base_compile="$base_compile $lastarg"
46420 + continue
46421 + ;;
46422 +
46423 + *)
46424 + # Accept the current argument as the source file.
46425 + # The previous "srcfile" becomes the current argument.
46426 + #
46427 + lastarg="$srcfile"
46428 + srcfile="$arg"
46429 + ;;
46430 + esac # case $arg
46431 + ;;
46432 + esac # case $arg_mode
46433 +
46434 + # Aesthetically quote the previous argument.
46435 + func_quote_for_eval "$lastarg"
46436 + base_compile="$base_compile $func_quote_for_eval_result"
46437 + done # for arg
46438 +
46439 + case $arg_mode in
46440 + arg)
46441 + func_fatal_error "you must specify an argument for -Xcompile"
46442 + ;;
46443 + target)
46444 + func_fatal_error "you must specify a target with \`-o'"
46445 + ;;
46446 + *)
46447 + # Get the name of the library object.
46448 + test -z "$libobj" && {
46449 + func_basename "$srcfile"
46450 + libobj="$func_basename_result"
46451 + }
46452 + ;;
46453 + esac
46454 +
46455 + # Recognize several different file suffixes.
46456 + # If the user specifies -o file.o, it is replaced with file.lo
46457 + xform='[cCFSifmso]'
46458 + case $libobj in
46459 + *.ada) xform=ada ;;
46460 + *.adb) xform=adb ;;
46461 + *.ads) xform=ads ;;
46462 + *.asm) xform=asm ;;
46463 + *.c++) xform=c++ ;;
46464 + *.cc) xform=cc ;;
46465 + *.ii) xform=ii ;;
46466 + *.class) xform=class ;;
46467 + *.cpp) xform=cpp ;;
46468 + *.cxx) xform=cxx ;;
46469 + *.[fF][09]?) xform='[fF][09].' ;;
46470 + *.for) xform=for ;;
46471 + *.java) xform=java ;;
46472 + *.obj) xform=obj ;;
46473 + esac
46474 +
46475 + libobj=`$ECHO "X$libobj" | $Xsed -e "s/\.$xform$/.lo/"`
46476 +
46477 + case $libobj in
46478 + *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;;
46479 + *)
46480 + func_fatal_error "cannot determine name of library object from \`$libobj'"
46481 + ;;
46482 + esac
46483 +
46484 + func_infer_tag $base_compile
46485 +
46486 + for arg in $later; do
46487 + case $arg in
46488 + -shared)
46489 + test "$build_libtool_libs" != yes && \
46490 + func_fatal_configuration "can not build a shared library"
46491 + build_old_libs=no
46492 + continue
46493 + ;;
46494 +
46495 + -static)
46496 + build_libtool_libs=no
46497 + build_old_libs=yes
46498 + continue
46499 + ;;
46500 +
46501 + -prefer-pic)
46502 + pic_mode=yes
46503 + continue
46504 + ;;
46505 +
46506 + -prefer-non-pic)
46507 + pic_mode=no
46508 + continue
46509 + ;;
46510 + esac
46511 + done
46512 +
46513 + func_quote_for_eval "$libobj"
46514 + test "X$libobj" != "X$func_quote_for_eval_result" \
46515 + && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \
46516 + && func_warning "libobj name \`$libobj' may not contain shell special characters."
46517 + func_basename "$obj"
46518 + objname="$func_basename_result"
46519 + func_dirname "$obj" "/" ""
46520 + xdir="$func_dirname_result"
46521 + lobj=${xdir}$objdir/$objname
46522 +
46523 + test -z "$base_compile" && \
46524 + func_fatal_help "you must specify a compilation command"
46525 +
46526 + # Delete any leftover library objects.
46527 + if test "$build_old_libs" = yes; then
46528 + removelist="$obj $lobj $libobj ${libobj}T"
46529 + else
46530 + removelist="$lobj $libobj ${libobj}T"
46531 + fi
46532 +
46533 + $opt_dry_run || $RM $removelist
46534 + trap "$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE" 1 2 15
46535 +
46536 + # On Cygwin there's no "real" PIC flag so we must build both object types
46537 + case $host_os in
46538 + cygwin* | mingw* | pw32* | os2*)
46539 + pic_mode=default
46540 + ;;
46541 + esac
46542 + if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then
46543 + # non-PIC code in shared libraries is not supported
46544 + pic_mode=default
46545 + fi
46546 +
46547 + # Calculate the filename of the output object if compiler does
46548 + # not support -o with -c
46549 + if test "$compiler_c_o" = no; then
46550 + output_obj=`$ECHO "X$srcfile" | $Xsed -e 's%^.*/%%' -e 's%\.[^.]*$%%'`.${objext}
46551 + lockfile="$output_obj.lock"
46552 + removelist="$removelist $output_obj $lockfile"
46553 + trap "$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE" 1 2 15
46554 + else
46555 + output_obj=
46556 + need_locks=no
46557 + lockfile=
46558 + fi
46559 +
46560 + # Lock this critical section if it is needed
46561 + # We use this script file to make the link, it avoids creating a new file
46562 + if test "$need_locks" = yes; then
46563 + until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do
46564 + func_echo "Waiting for $lockfile to be removed"
46565 + sleep 2
46566 + done
46567 + elif test "$need_locks" = warn; then
46568 + if test -f "$lockfile"; then
46569 + $ECHO "\
46570 +*** ERROR, $lockfile exists and contains:
46571 +`cat $lockfile 2>/dev/null`
46572 +
46573 +This indicates that another process is trying to use the same
46574 +temporary object file, and libtool could not work around it because
46575 +your compiler does not support \`-c' and \`-o' together. If you
46576 +repeat this compilation, it may succeed, by chance, but you had better
46577 +avoid parallel builds (make -j) in this platform, or get a better
46578 +compiler."
46579 +
46580 + $opt_dry_run || $RM $removelist
46581 + exit $EXIT_FAILURE
46582 + fi
46583 + $ECHO "$srcfile" > "$lockfile"
46584 + fi
46585 +
46586 + if test -n "$fix_srcfile_path"; then
46587 + eval srcfile=\"$fix_srcfile_path\"
46588 + fi
46589 + func_quote_for_eval "$srcfile"
46590 + qsrcfile=$func_quote_for_eval_result
46591 +
46592 + $opt_dry_run || $RM "$libobj" "${libobj}T"
46593 +
46594 + # Only build a PIC object if we are building libtool libraries.
46595 + if test "$build_libtool_libs" = yes; then
46596 + # Without this assignment, base_compile gets emptied.
46597 + fbsd_hideous_sh_bug=$base_compile
46598 +
46599 + if test "$pic_mode" != no; then
46600 + command="$base_compile $qsrcfile $pic_flag"
46601 + else
46602 + # Don't build PIC code
46603 + command="$base_compile $qsrcfile"
46604 + fi
46605 +
46606 + func_mkdir_p "$xdir$objdir"
46607 +
46608 + if test -z "$output_obj"; then
46609 + # Place PIC objects in $objdir
46610 + command="$command -o $lobj"
46611 + fi
46612 +
46613 + $opt_dry_run || $RM "$lobj" "$output_obj"
46614 +
46615 + func_show_eval "$command" \
46616 + 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE'
46617 +
46618 + if test "$need_locks" = warn &&
46619 + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then
46620 + $ECHO "\
46621 +*** ERROR, $lockfile contains:
46622 +`cat $lockfile 2>/dev/null`
46623 +
46624 +but it should contain:
46625 +$srcfile
46626 +
46627 +This indicates that another process is trying to use the same
46628 +temporary object file, and libtool could not work around it because
46629 +your compiler does not support \`-c' and \`-o' together. If you
46630 +repeat this compilation, it may succeed, by chance, but you had better
46631 +avoid parallel builds (make -j) in this platform, or get a better
46632 +compiler."
46633 +
46634 + $opt_dry_run || $RM $removelist
46635 + exit $EXIT_FAILURE
46636 + fi
46637 +
46638 + # Just move the object if needed, then go on to compile the next one
46639 + if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then
46640 + func_show_eval '$MV "$output_obj" "$lobj"' \
46641 + 'error=$?; $opt_dry_run || $RM $removelist; exit $error'
46642 + fi
46643 +
46644 + # Allow error messages only from the first compilation.
46645 + if test "$suppress_opt" = yes; then
46646 + suppress_output=' >/dev/null 2>&1'
46647 + fi
46648 + fi
46649 +
46650 + # Only build a position-dependent object if we build old libraries.
46651 + if test "$build_old_libs" = yes; then
46652 + if test "$pic_mode" != yes; then
46653 + # Don't build PIC code
46654 + command="$base_compile $qsrcfile$pie_flag"
46655 + else
46656 + command="$base_compile $qsrcfile $pic_flag"
46657 + fi
46658 + if test "$compiler_c_o" = yes; then
46659 + command="$command -o $obj"
46660 + fi
46661 +
46662 + # Suppress compiler output if we already did a PIC compilation.
46663 + command="$command$suppress_output"
46664 + $opt_dry_run || $RM "$obj" "$output_obj"
46665 + func_show_eval "$command" \
46666 + '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE'
46667 +
46668 + if test "$need_locks" = warn &&
46669 + test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then
46670 + $ECHO "\
46671 +*** ERROR, $lockfile contains:
46672 +`cat $lockfile 2>/dev/null`
46673 +
46674 +but it should contain:
46675 +$srcfile
46676 +
46677 +This indicates that another process is trying to use the same
46678 +temporary object file, and libtool could not work around it because
46679 +your compiler does not support \`-c' and \`-o' together. If you
46680 +repeat this compilation, it may succeed, by chance, but you had better
46681 +avoid parallel builds (make -j) in this platform, or get a better
46682 +compiler."
46683 +
46684 + $opt_dry_run || $RM $removelist
46685 + exit $EXIT_FAILURE
46686 + fi
46687 +
46688 + # Just move the object if needed
46689 + if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then
46690 + func_show_eval '$MV "$output_obj" "$obj"' \
46691 + 'error=$?; $opt_dry_run || $RM $removelist; exit $error'
46692 + fi
46693 + fi
46694 +
46695 + $opt_dry_run || {
46696 + func_write_libtool_object "$libobj" "$objdir/$objname" "$objname"
46697 +
46698 + # Unlock the critical section if it was locked
46699 + if test "$need_locks" != no; then
46700 + $RM "$lockfile"
46701 + fi
46702 + }
46703 +
46704 + exit $EXIT_SUCCESS
46705 +}
46706 +
46707 +test "$mode" = compile && func_mode_compile ${1+"$@"}
46708 +
46709 +
46710 +# func_mode_execute arg...
46711 +func_mode_execute ()
46712 +{
46713 + $opt_debug
46714 + # The first argument is the command name.
46715 + cmd="$nonopt"
46716 + test -z "$cmd" && \
46717 + func_fatal_help "you must specify a COMMAND"
46718 +
46719 + # Handle -dlopen flags immediately.
46720 + for file in $execute_dlfiles; do
46721 + test -f "$file" \
46722 + || func_fatal_help "\`$file' is not a file"
46723 +
46724 + dir=
46725 + case $file in
46726 + *.la)
46727 + # Check to see that this really is a libtool archive.
46728 + func_lalib_unsafe_p "$file" \
46729 + || func_fatal_help "\`$lib' is not a valid libtool archive"
46730 +
46731 + # Read the libtool library.
46732 + dlname=
46733 + library_names=
46734 + func_source "$file"
46735 +
46736 + # Skip this library if it cannot be dlopened.
46737 + if test -z "$dlname"; then
46738 + # Warn if it was a shared library.
46739 + test -n "$library_names" && \
46740 + func_warning "\`$file' was not linked with \`-export-dynamic'"
46741 + continue
46742 + fi
46743 +
46744 + func_dirname "$file" "" "."
46745 + dir="$func_dirname_result"
46746 +
46747 + if test -f "$dir/$objdir/$dlname"; then
46748 + dir="$dir/$objdir"
46749 + else
46750 + if test ! -f "$dir/$dlname"; then
46751 + func_fatal_error "cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'"
46752 + fi
46753 + fi
46754 + ;;
46755 +
46756 + *.lo)
46757 + # Just add the directory containing the .lo file.
46758 + func_dirname "$file" "" "."
46759 + dir="$func_dirname_result"
46760 + ;;
46761 +
46762 + *)
46763 + func_warning "\`-dlopen' is ignored for non-libtool libraries and objects"
46764 + continue
46765 + ;;
46766 + esac
46767 +
46768 + # Get the absolute pathname.
46769 + absdir=`cd "$dir" && pwd`
46770 + test -n "$absdir" && dir="$absdir"
46771 +
46772 + # Now add the directory to shlibpath_var.
46773 + if eval "test -z \"\$$shlibpath_var\""; then
46774 + eval "$shlibpath_var=\"\$dir\""
46775 + else
46776 + eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\""
46777 + fi
46778 + done
46779 +
46780 + # This variable tells wrapper scripts just to set shlibpath_var
46781 + # rather than running their programs.
46782 + libtool_execute_magic="$magic"
46783 +
46784 + # Check if any of the arguments is a wrapper script.
46785 + args=
46786 + for file
46787 + do
46788 + case $file in
46789 + -*) ;;
46790 + *)
46791 + # Do a test to see if this is really a libtool program.
46792 + if func_ltwrapper_p "$file"; then
46793 + func_source "$file"
46794 +
46795 + # Transform arg to wrapped name.
46796 + file="$progdir/$program"
46797 + fi
46798 + ;;
46799 + esac
46800 + # Quote arguments (to preserve shell metacharacters).
46801 + func_quote_for_eval "$file"
46802 + args="$args $func_quote_for_eval_result"
46803 + done
46804 +
46805 + if test "X$opt_dry_run" = Xfalse; then
46806 + if test -n "$shlibpath_var"; then
46807 + # Export the shlibpath_var.
46808 + eval "export $shlibpath_var"
46809 + fi
46810 +
46811 + # Restore saved environment variables
46812 + for lt_var in LANG LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
46813 + do
46814 + eval "if test \"\${save_$lt_var+set}\" = set; then
46815 + $lt_var=\$save_$lt_var; export $lt_var
46816 + else
46817 + $lt_unset $lt_var
46818 + fi"
46819 + done
46820 +
46821 + # Now prepare to actually exec the command.
46822 + exec_cmd="\$cmd$args"
46823 + else
46824 + # Display what would be done.
46825 + if test -n "$shlibpath_var"; then
46826 + eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\""
46827 + $ECHO "export $shlibpath_var"
46828 + fi
46829 + $ECHO "$cmd$args"
46830 + exit $EXIT_SUCCESS
46831 + fi
46832 +}
46833 +
46834 +test "$mode" = execute && func_mode_execute ${1+"$@"}
46835 +
46836 +
46837 +# func_mode_finish arg...
46838 +func_mode_finish ()
46839 +{
46840 + $opt_debug
46841 + libdirs="$nonopt"
46842 + admincmds=
46843 +
46844 + if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
46845 + for dir
46846 + do
46847 + libdirs="$libdirs $dir"
46848 + done
46849 +
46850 + for libdir in $libdirs; do
46851 + if test -n "$finish_cmds"; then
46852 + # Do each command in the finish commands.
46853 + func_execute_cmds "$finish_cmds" 'admincmds="$admincmds
46854 +'"$cmd"'"'
46855 + fi
46856 + if test -n "$finish_eval"; then
46857 + # Do the single finish_eval.
46858 + eval cmds=\"$finish_eval\"
46859 + $opt_dry_run || eval "$cmds" || admincmds="$admincmds
46860 + $cmds"
46861 + fi
46862 + done
46863 + fi
46864 +
46865 + # Exit here if they wanted silent mode.
46866 + $opt_silent && exit $EXIT_SUCCESS
46867 +
46868 + $ECHO "X----------------------------------------------------------------------" | $Xsed
46869 + $ECHO "Libraries have been installed in:"
46870 + for libdir in $libdirs; do
46871 + $ECHO " $libdir"
46872 + done
46873 + $ECHO
46874 + $ECHO "If you ever happen to want to link against installed libraries"
46875 + $ECHO "in a given directory, LIBDIR, you must either use libtool, and"
46876 + $ECHO "specify the full pathname of the library, or use the \`-LLIBDIR'"
46877 + $ECHO "flag during linking and do at least one of the following:"
46878 + if test -n "$shlibpath_var"; then
46879 + $ECHO " - add LIBDIR to the \`$shlibpath_var' environment variable"
46880 + $ECHO " during execution"
46881 + fi
46882 + if test -n "$runpath_var"; then
46883 + $ECHO " - add LIBDIR to the \`$runpath_var' environment variable"
46884 + $ECHO " during linking"
46885 + fi
46886 + if test -n "$hardcode_libdir_flag_spec"; then
46887 + libdir=LIBDIR
46888 + eval flag=\"$hardcode_libdir_flag_spec\"
46889 +
46890 + $ECHO " - use the \`$flag' linker flag"
46891 + fi
46892 + if test -n "$admincmds"; then
46893 + $ECHO " - have your system administrator run these commands:$admincmds"
46894 + fi
46895 + if test -f /etc/ld.so.conf; then
46896 + $ECHO " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
46897 + fi
46898 + $ECHO
46899 +
46900 + $ECHO "See any operating system documentation about shared libraries for"
46901 + case $host in
46902 + solaris2.[6789]|solaris2.1[0-9])
46903 + $ECHO "more information, such as the ld(1), crle(1) and ld.so(8) manual"
46904 + $ECHO "pages."
46905 + ;;
46906 + *)
46907 + $ECHO "more information, such as the ld(1) and ld.so(8) manual pages."
46908 + ;;
46909 + esac
46910 + $ECHO "X----------------------------------------------------------------------" | $Xsed
46911 + exit $EXIT_SUCCESS
46912 +}
46913 +
46914 +test "$mode" = finish && func_mode_finish ${1+"$@"}
46915 +
46916 +
46917 +# func_mode_install arg...
46918 +func_mode_install ()
46919 +{
46920 + $opt_debug
46921 + # There may be an optional sh(1) argument at the beginning of
46922 + # install_prog (especially on Windows NT).
46923 + if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh ||
46924 + # Allow the use of GNU shtool's install command.
46925 + $ECHO "X$nonopt" | $GREP shtool >/dev/null; then
46926 + # Aesthetically quote it.
46927 + func_quote_for_eval "$nonopt"
46928 + install_prog="$func_quote_for_eval_result "
46929 + arg=$1
46930 + shift
46931 + else
46932 + install_prog=
46933 + arg=$nonopt
46934 + fi
46935 +
46936 + # The real first argument should be the name of the installation program.
46937 + # Aesthetically quote it.
46938 + func_quote_for_eval "$arg"
46939 + install_prog="$install_prog$func_quote_for_eval_result"
46940 +
46941 + # We need to accept at least all the BSD install flags.
46942 + dest=
46943 + files=
46944 + opts=
46945 + prev=
46946 + install_type=
46947 + isdir=no
46948 + stripme=
46949 + for arg
46950 + do
46951 + if test -n "$dest"; then
46952 + files="$files $dest"
46953 + dest=$arg
46954 + continue
46955 + fi
46956 +
46957 + case $arg in
46958 + -d) isdir=yes ;;
46959 + -f)
46960 + case " $install_prog " in
46961 + *[\\\ /]cp\ *) ;;
46962 + *) prev=$arg ;;
46963 + esac
46964 + ;;
46965 + -g | -m | -o)
46966 + prev=$arg
46967 + ;;
46968 + -s)
46969 + stripme=" -s"
46970 + continue
46971 + ;;
46972 + -*)
46973 + ;;
46974 + *)
46975 + # If the previous option needed an argument, then skip it.
46976 + if test -n "$prev"; then
46977 + prev=
46978 + else
46979 + dest=$arg
46980 + continue
46981 + fi
46982 + ;;
46983 + esac
46984 +
46985 + # Aesthetically quote the argument.
46986 + func_quote_for_eval "$arg"
46987 + install_prog="$install_prog $func_quote_for_eval_result"
46988 + done
46989 +
46990 + test -z "$install_prog" && \
46991 + func_fatal_help "you must specify an install program"
46992 +
46993 + test -n "$prev" && \
46994 + func_fatal_help "the \`$prev' option requires an argument"
46995 +
46996 + if test -z "$files"; then
46997 + if test -z "$dest"; then
46998 + func_fatal_help "no file or destination specified"
46999 + else
47000 + func_fatal_help "you must specify a destination"
47001 + fi
47002 + fi
47003 +
47004 + # Strip any trailing slash from the destination.
47005 + func_stripname '' '/' "$dest"
47006 + dest=$func_stripname_result
47007 +
47008 + # Check to see that the destination is a directory.
47009 + test -d "$dest" && isdir=yes
47010 + if test "$isdir" = yes; then
47011 + destdir="$dest"
47012 + destname=
47013 + else
47014 + func_dirname "$dest" "" "."
47015 + destdir="$func_dirname_result"
47016 + func_basename "$dest"
47017 + destname="$func_basename_result"
47018 +
47019 + # Not a directory, so check to see that there is only one file specified.
47020 + set dummy $files; shift
47021 + test "$#" -gt 1 && \
47022 + func_fatal_help "\`$dest' is not a directory"
47023 + fi
47024 + case $destdir in
47025 + [\\/]* | [A-Za-z]:[\\/]*) ;;
47026 + *)
47027 + for file in $files; do
47028 + case $file in
47029 + *.lo) ;;
47030 + *)
47031 + func_fatal_help "\`$destdir' must be an absolute directory name"
47032 + ;;
47033 + esac
47034 + done
47035 + ;;
47036 + esac
47037 +
47038 + # This variable tells wrapper scripts just to set variables rather
47039 + # than running their programs.
47040 + libtool_install_magic="$magic"
47041 +
47042 + staticlibs=
47043 + future_libdirs=
47044 + current_libdirs=
47045 + for file in $files; do
47046 +
47047 + # Do each installation.
47048 + case $file in
47049 + *.$libext)
47050 + # Do the static libraries later.
47051 + staticlibs="$staticlibs $file"
47052 + ;;
47053 +
47054 + *.la)
47055 + # Check to see that this really is a libtool archive.
47056 + func_lalib_unsafe_p "$file" \
47057 + || func_fatal_help "\`$file' is not a valid libtool archive"
47058 +
47059 + library_names=
47060 + old_library=
47061 + relink_command=
47062 + func_source "$file"
47063 +
47064 + # Add the libdir to current_libdirs if it is the destination.
47065 + if test "X$destdir" = "X$libdir"; then
47066 + case "$current_libdirs " in
47067 + *" $libdir "*) ;;
47068 + *) current_libdirs="$current_libdirs $libdir" ;;
47069 + esac
47070 + else
47071 + # Note the libdir as a future libdir.
47072 + case "$future_libdirs " in
47073 + *" $libdir "*) ;;
47074 + *) future_libdirs="$future_libdirs $libdir" ;;
47075 + esac
47076 + fi
47077 +
47078 + func_dirname "$file" "/" ""
47079 + dir="$func_dirname_result"
47080 + dir="$dir$objdir"
47081 +
47082 + if test -n "$relink_command"; then
47083 + # Determine the prefix the user has applied to our future dir.
47084 + inst_prefix_dir=`$ECHO "X$destdir" | $Xsed -e "s%$libdir\$%%"`
47085 +
47086 + # Don't allow the user to place us outside of our expected
47087 + # location b/c this prevents finding dependent libraries that
47088 + # are installed to the same prefix.
47089 + # At present, this check doesn't affect windows .dll's that
47090 + # are installed into $libdir/../bin (currently, that works fine)
47091 + # but it's something to keep an eye on.
47092 + test "$inst_prefix_dir" = "$destdir" && \
47093 + func_fatal_error "error: cannot install \`$file' to a directory not ending in $libdir"
47094 +
47095 + if test -n "$inst_prefix_dir"; then
47096 + # Stick the inst_prefix_dir data into the link command.
47097 + relink_command=`$ECHO "X$relink_command" | $Xsed -e "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"`
47098 + else
47099 + relink_command=`$ECHO "X$relink_command" | $Xsed -e "s%@inst_prefix_dir@%%"`
47100 + fi
47101 +
47102 + func_warning "relinking \`$file'"
47103 + func_show_eval "$relink_command" \
47104 + 'func_fatal_error "error: relink \`$file'\'' with the above command before installing it"'
47105 + fi
47106 +
47107 + # See the names of the shared library.
47108 + set dummy $library_names; shift
47109 + if test -n "$1"; then
47110 + realname="$1"
47111 + shift
47112 +
47113 + srcname="$realname"
47114 + test -n "$relink_command" && srcname="$realname"T
47115 +
47116 + # Install the shared library and build the symlinks.
47117 + func_show_eval "$install_prog $dir/$srcname $destdir/$realname" \
47118 + 'exit $?'
47119 + tstripme="$stripme"
47120 + case $host_os in
47121 + cygwin* | mingw* | pw32*)
47122 + case $realname in
47123 + *.dll.a)
47124 + tstripme=""
47125 + ;;
47126 + esac
47127 + ;;
47128 + esac
47129 + if test -n "$tstripme" && test -n "$striplib"; then
47130 + func_show_eval "$striplib $destdir/$realname" 'exit $?'
47131 + fi
47132 +
47133 + if test "$#" -gt 0; then
47134 + # Delete the old symlinks, and create new ones.
47135 + # Try `ln -sf' first, because the `ln' binary might depend on
47136 + # the symlink we replace! Solaris /bin/ln does not understand -f,
47137 + # so we also need to try rm && ln -s.
47138 + for linkname
47139 + do
47140 + test "$linkname" != "$realname" \
47141 + && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })"
47142 + done
47143 + fi
47144 +
47145 + # Do each command in the postinstall commands.
47146 + lib="$destdir/$realname"
47147 + func_execute_cmds "$postinstall_cmds" 'exit $?'
47148 + fi
47149 +
47150 + # Install the pseudo-library for information purposes.
47151 + func_basename "$file"
47152 + name="$func_basename_result"
47153 + instname="$dir/$name"i
47154 + func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
47155 +
47156 + # Maybe install the static library, too.
47157 + test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library"
47158 + ;;
47159 +
47160 + *.lo)
47161 + # Install (i.e. copy) a libtool object.
47162 +
47163 + # Figure out destination file name, if it wasn't already specified.
47164 + if test -n "$destname"; then
47165 + destfile="$destdir/$destname"
47166 + else
47167 + func_basename "$file"
47168 + destfile="$func_basename_result"
47169 + destfile="$destdir/$destfile"
47170 + fi
47171 +
47172 + # Deduce the name of the destination old-style object file.
47173 + case $destfile in
47174 + *.lo)
47175 + func_lo2o "$destfile"
47176 + staticdest=$func_lo2o_result
47177 + ;;
47178 + *.$objext)
47179 + staticdest="$destfile"
47180 + destfile=
47181 + ;;
47182 + *)
47183 + func_fatal_help "cannot copy a libtool object to \`$destfile'"
47184 + ;;
47185 + esac
47186 +
47187 + # Install the libtool object if requested.
47188 + test -n "$destfile" && \
47189 + func_show_eval "$install_prog $file $destfile" 'exit $?'
47190 +
47191 + # Install the old object if enabled.
47192 + if test "$build_old_libs" = yes; then
47193 + # Deduce the name of the old-style object file.
47194 + func_lo2o "$file"
47195 + staticobj=$func_lo2o_result
47196 + func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?'
47197 + fi
47198 + exit $EXIT_SUCCESS
47199 + ;;
47200 +
47201 + *)
47202 + # Figure out destination file name, if it wasn't already specified.
47203 + if test -n "$destname"; then
47204 + destfile="$destdir/$destname"
47205 + else
47206 + func_basename "$file"
47207 + destfile="$func_basename_result"
47208 + destfile="$destdir/$destfile"
47209 + fi
47210 +
47211 + # If the file is missing, and there is a .exe on the end, strip it
47212 + # because it is most likely a libtool script we actually want to
47213 + # install
47214 + stripped_ext=""
47215 + case $file in
47216 + *.exe)
47217 + if test ! -f "$file"; then
47218 + func_stripname '' '.exe' "$file"
47219 + file=$func_stripname_result
47220 + stripped_ext=".exe"
47221 + fi
47222 + ;;
47223 + esac
47224 +
47225 + # Do a test to see if this is really a libtool program.
47226 + case $host in
47227 + *cygwin*|*mingw*)
47228 + func_stripname '' '.exe' "$file"
47229 + wrapper=$func_stripname_result
47230 + ;;
47231 + *)
47232 + wrapper=$file
47233 + ;;
47234 + esac
47235 + if func_ltwrapper_p "$wrapper"; then
47236 + notinst_deplibs=
47237 + relink_command=
47238 +
47239 + func_source "$wrapper"
47240 +
47241 + # Check the variables that should have been set.
47242 + test -z "$generated_by_libtool_version" && \
47243 + func_fatal_error "invalid libtool wrapper script \`$wrapper'"
47244 +
47245 + finalize=yes
47246 + for lib in $notinst_deplibs; do
47247 + # Check to see that each library is installed.
47248 + libdir=
47249 + if test -f "$lib"; then
47250 + func_source "$lib"
47251 + fi
47252 + libfile="$libdir/"`$ECHO "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test
47253 + if test -n "$libdir" && test ! -f "$libfile"; then
47254 + func_warning "\`$lib' has not been installed in \`$libdir'"
47255 + finalize=no
47256 + fi
47257 + done
47258 +
47259 + relink_command=
47260 + func_source "$wrapper"
47261 +
47262 + outputname=
47263 + if test "$fast_install" = no && test -n "$relink_command"; then
47264 + $opt_dry_run || {
47265 + if test "$finalize" = yes; then
47266 + tmpdir=`func_mktempdir`
47267 + func_basename "$file$stripped_ext"
47268 + file="$func_basename_result"
47269 + outputname="$tmpdir/$file"
47270 + # Replace the output file specification.
47271 + relink_command=`$ECHO "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'`
47272 +
47273 + $opt_silent || {
47274 + func_quote_for_expand "$relink_command"
47275 + eval "func_echo $func_quote_for_expand_result"
47276 + }
47277 + if eval "$relink_command"; then :
47278 + else
47279 + func_error "error: relink \`$file' with the above command before installing it"
47280 + $opt_dry_run || ${RM}r "$tmpdir"
47281 + continue
47282 + fi
47283 + file="$outputname"
47284 + else
47285 + func_warning "cannot relink \`$file'"
47286 + fi
47287 + }
47288 + else
47289 + # Install the binary that we compiled earlier.
47290 + file=`$ECHO "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"`
47291 + fi
47292 + fi
47293 +
47294 + # remove .exe since cygwin /usr/bin/install will append another
47295 + # one anyway
47296 + case $install_prog,$host in
47297 + */usr/bin/install*,*cygwin*)
47298 + case $file:$destfile in
47299 + *.exe:*.exe)
47300 + # this is ok
47301 + ;;
47302 + *.exe:*)
47303 + destfile=$destfile.exe
47304 + ;;
47305 + *:*.exe)
47306 + func_stripname '' '.exe' "$destfile"
47307 + destfile=$func_stripname_result
47308 + ;;
47309 + esac
47310 + ;;
47311 + esac
47312 + func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?'
47313 + $opt_dry_run || if test -n "$outputname"; then
47314 + ${RM}r "$tmpdir"
47315 + fi
47316 + ;;
47317 + esac
47318 + done
47319 +
47320 + for file in $staticlibs; do
47321 + func_basename "$file"
47322 + name="$func_basename_result"
47323 +
47324 + # Set up the ranlib parameters.
47325 + oldlib="$destdir/$name"
47326 +
47327 + func_show_eval "$install_prog \$file \$oldlib" 'exit $?'
47328 +
47329 + if test -n "$stripme" && test -n "$old_striplib"; then
47330 + func_show_eval "$old_striplib $oldlib" 'exit $?'
47331 + fi
47332 +
47333 + # Do each command in the postinstall commands.
47334 + func_execute_cmds "$old_postinstall_cmds" 'exit $?'
47335 + done
47336 +
47337 + test -n "$future_libdirs" && \
47338 + func_warning "remember to run \`$progname --finish$future_libdirs'"
47339 +
47340 + if test -n "$current_libdirs"; then
47341 + # Maybe just do a dry run.
47342 + $opt_dry_run && current_libdirs=" -n$current_libdirs"
47343 + exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs'
47344 + else
47345 + exit $EXIT_SUCCESS
47346 + fi
47347 +}
47348 +
47349 +test "$mode" = install && func_mode_install ${1+"$@"}
47350 +
47351 +
47352 +# func_mode_link arg...
47353 +func_mode_link ()
47354 +{
47355 + $opt_debug
47356 + case $host in
47357 + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
47358 + # It is impossible to link a dll without this setting, and
47359 + # we shouldn't force the makefile maintainer to figure out
47360 + # which system we are compiling for in order to pass an extra
47361 + # flag for every libtool invocation.
47362 + # allow_undefined=no
47363 +
47364 + # FIXME: Unfortunately, there are problems with the above when trying
47365 + # to make a dll which has undefined symbols, in which case not
47366 + # even a static library is built. For now, we need to specify
47367 + # -no-undefined on the libtool link line when we can be certain
47368 + # that all symbols are satisfied, otherwise we get a static library.
47369 + allow_undefined=yes
47370 + ;;
47371 + *)
47372 + allow_undefined=yes
47373 + ;;
47374 + esac
47375 + libtool_args=$nonopt
47376 + base_compile="$nonopt $@"
47377 + compile_command=$nonopt
47378 + finalize_command=$nonopt
47379 +
47380 + compile_rpath=
47381 + finalize_rpath=
47382 + compile_shlibpath=
47383 + finalize_shlibpath=
47384 + convenience=
47385 + old_convenience=
47386 + deplibs=
47387 + old_deplibs=
47388 + compiler_flags=
47389 + linker_flags=
47390 + dllsearchpath=
47391 + lib_search_path=`pwd`
47392 + inst_prefix_dir=
47393 + new_inherited_linker_flags=
47394 +
47395 + avoid_version=no
47396 + dlfiles=
47397 + dlprefiles=
47398 + dlself=no
47399 + export_dynamic=no
47400 + export_symbols=
47401 + export_symbols_regex=
47402 + generated=
47403 + libobjs=
47404 + ltlibs=
47405 + module=no
47406 + no_install=no
47407 + objs=
47408 + non_pic_objects=
47409 + precious_files_regex=
47410 + prefer_static_libs=no
47411 + preload=no
47412 + prev=
47413 + prevarg=
47414 + release=
47415 + rpath=
47416 + xrpath=
47417 + perm_rpath=
47418 + temp_rpath=
47419 + thread_safe=no
47420 + vinfo=
47421 + vinfo_number=no
47422 + weak_libs=
47423 + single_module="${wl}-single_module"
47424 + func_infer_tag $base_compile
47425 +
47426 + # We need to know -static, to get the right output filenames.
47427 + for arg
47428 + do
47429 + case $arg in
47430 + -shared)
47431 + test "$build_libtool_libs" != yes && \
47432 + func_fatal_configuration "can not build a shared library"
47433 + build_old_libs=no
47434 + break
47435 + ;;
47436 + -all-static | -static | -static-libtool-libs)
47437 + case $arg in
47438 + -all-static)
47439 + if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then
47440 + func_warning "complete static linking is impossible in this configuration"
47441 + fi
47442 + if test -n "$link_static_flag"; then
47443 + dlopen_self=$dlopen_self_static
47444 + # See comment for -static flag below, for more details.
47445 + func_append compile_command " $link_static_flag"
47446 + func_append finalize_command " $link_static_flag"
47447 + fi
47448 + prefer_static_libs=yes
47449 + ;;
47450 + -static)
47451 + if test -z "$pic_flag" && test -n "$link_static_flag"; then
47452 + dlopen_self=$dlopen_self_static
47453 + fi
47454 + prefer_static_libs=built
47455 + ;;
47456 + -static-libtool-libs)
47457 + if test -z "$pic_flag" && test -n "$link_static_flag"; then
47458 + dlopen_self=$dlopen_self_static
47459 + fi
47460 + prefer_static_libs=yes
47461 + ;;
47462 + esac
47463 + build_libtool_libs=no
47464 + build_old_libs=yes
47465 + break
47466 + ;;
47467 + esac
47468 + done
47469 +
47470 + # See if our shared archives depend on static archives.
47471 + test -n "$old_archive_from_new_cmds" && build_old_libs=yes
47472 +
47473 + # Go through the arguments, transforming them on the way.
47474 + while test "$#" -gt 0; do
47475 + arg="$1"
47476 + shift
47477 + func_quote_for_eval "$arg"
47478 + qarg=$func_quote_for_eval_unquoted_result
47479 + func_append libtool_args " $func_quote_for_eval_result"
47480 +
47481 + # If the previous option needs an argument, assign it.
47482 + if test -n "$prev"; then
47483 + case $prev in
47484 + output)
47485 + func_append compile_command " @OUTPUT@"
47486 + func_append finalize_command " @OUTPUT@"
47487 + ;;
47488 + esac
47489 +
47490 + case $prev in
47491 + dlfiles|dlprefiles)
47492 + if test "$preload" = no; then
47493 + # Add the symbol object into the linking commands.
47494 + func_append compile_command " @SYMFILE@"
47495 + func_append finalize_command " @SYMFILE@"
47496 + preload=yes
47497 + fi
47498 + case $arg in
47499 + *.la | *.lo) ;; # We handle these cases below.
47500 + force)
47501 + if test "$dlself" = no; then
47502 + dlself=needless
47503 + export_dynamic=yes
47504 + fi
47505 + prev=
47506 + continue
47507 + ;;
47508 + self)
47509 + if test "$prev" = dlprefiles; then
47510 + dlself=yes
47511 + elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then
47512 + dlself=yes
47513 + else
47514 + dlself=needless
47515 + export_dynamic=yes
47516 + fi
47517 + prev=
47518 + continue
47519 + ;;
47520 + *)
47521 + if test "$prev" = dlfiles; then
47522 + dlfiles="$dlfiles $arg"
47523 + else
47524 + dlprefiles="$dlprefiles $arg"
47525 + fi
47526 + prev=
47527 + continue
47528 + ;;
47529 + esac
47530 + ;;
47531 + expsyms)
47532 + export_symbols="$arg"
47533 + test -f "$arg" \
47534 + || func_fatal_error "symbol file \`$arg' does not exist"
47535 + prev=
47536 + continue
47537 + ;;
47538 + expsyms_regex)
47539 + export_symbols_regex="$arg"
47540 + prev=
47541 + continue
47542 + ;;
47543 + framework)
47544 + case $host in
47545 + *-*-darwin*)
47546 + case "$deplibs " in
47547 + *" $qarg.ltframework "*) ;;
47548 + *) deplibs="$deplibs $qarg.ltframework" # this is fixed later
47549 + ;;
47550 + esac
47551 + ;;
47552 + esac
47553 + prev=
47554 + continue
47555 + ;;
47556 + inst_prefix)
47557 + inst_prefix_dir="$arg"
47558 + prev=
47559 + continue
47560 + ;;
47561 + objectlist)
47562 + if test -f "$arg"; then
47563 + save_arg=$arg
47564 + moreargs=
47565 + for fil in `cat "$save_arg"`
47566 + do
47567 +# moreargs="$moreargs $fil"
47568 + arg=$fil
47569 + # A libtool-controlled object.
47570 +
47571 + # Check to see that this really is a libtool object.
47572 + if func_lalib_unsafe_p "$arg"; then
47573 + pic_object=
47574 + non_pic_object=
47575 +
47576 + # Read the .lo file
47577 + func_source "$arg"
47578 +
47579 + if test -z "$pic_object" ||
47580 + test -z "$non_pic_object" ||
47581 + test "$pic_object" = none &&
47582 + test "$non_pic_object" = none; then
47583 + func_fatal_error "cannot find name of object for \`$arg'"
47584 + fi
47585 +
47586 + # Extract subdirectory from the argument.
47587 + func_dirname "$arg" "/" ""
47588 + xdir="$func_dirname_result"
47589 +
47590 + if test "$pic_object" != none; then
47591 + # Prepend the subdirectory the object is found in.
47592 + pic_object="$xdir$pic_object"
47593 +
47594 + if test "$prev" = dlfiles; then
47595 + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
47596 + dlfiles="$dlfiles $pic_object"
47597 + prev=
47598 + continue
47599 + else
47600 + # If libtool objects are unsupported, then we need to preload.
47601 + prev=dlprefiles
47602 + fi
47603 + fi
47604 +
47605 + # CHECK ME: I think I busted this. -Ossama
47606 + if test "$prev" = dlprefiles; then
47607 + # Preload the old-style object.
47608 + dlprefiles="$dlprefiles $pic_object"
47609 + prev=
47610 + fi
47611 +
47612 + # A PIC object.
47613 + func_append libobjs " $pic_object"
47614 + arg="$pic_object"
47615 + fi
47616 +
47617 + # Non-PIC object.
47618 + if test "$non_pic_object" != none; then
47619 + # Prepend the subdirectory the object is found in.
47620 + non_pic_object="$xdir$non_pic_object"
47621 +
47622 + # A standard non-PIC object
47623 + func_append non_pic_objects " $non_pic_object"
47624 + if test -z "$pic_object" || test "$pic_object" = none ; then
47625 + arg="$non_pic_object"
47626 + fi
47627 + else
47628 + # If the PIC object exists, use it instead.
47629 + # $xdir was prepended to $pic_object above.
47630 + non_pic_object="$pic_object"
47631 + func_append non_pic_objects " $non_pic_object"
47632 + fi
47633 + else
47634 + # Only an error if not doing a dry-run.
47635 + if $opt_dry_run; then
47636 + # Extract subdirectory from the argument.
47637 + func_dirname "$arg" "/" ""
47638 + xdir="$func_dirname_result"
47639 +
47640 + func_lo2o "$arg"
47641 + pic_object=$xdir$objdir/$func_lo2o_result
47642 + non_pic_object=$xdir$func_lo2o_result
47643 + func_append libobjs " $pic_object"
47644 + func_append non_pic_objects " $non_pic_object"
47645 + else
47646 + func_fatal_error "\`$arg' is not a valid libtool object"
47647 + fi
47648 + fi
47649 + done
47650 + else
47651 + func_fatal_error "link input file \`$arg' does not exist"
47652 + fi
47653 + arg=$save_arg
47654 + prev=
47655 + continue
47656 + ;;
47657 + precious_regex)
47658 + precious_files_regex="$arg"
47659 + prev=
47660 + continue
47661 + ;;
47662 + release)
47663 + release="-$arg"
47664 + prev=
47665 + continue
47666 + ;;
47667 + rpath | xrpath)
47668 + # We need an absolute path.
47669 + case $arg in
47670 + [\\/]* | [A-Za-z]:[\\/]*) ;;
47671 + *)
47672 + func_fatal_error "only absolute run-paths are allowed"
47673 + ;;
47674 + esac
47675 + if test "$prev" = rpath; then
47676 + case "$rpath " in
47677 + *" $arg "*) ;;
47678 + *) rpath="$rpath $arg" ;;
47679 + esac
47680 + else
47681 + case "$xrpath " in
47682 + *" $arg "*) ;;
47683 + *) xrpath="$xrpath $arg" ;;
47684 + esac
47685 + fi
47686 + prev=
47687 + continue
47688 + ;;
47689 + shrext)
47690 + shrext_cmds="$arg"
47691 + prev=
47692 + continue
47693 + ;;
47694 + weak)
47695 + weak_libs="$weak_libs $arg"
47696 + prev=
47697 + continue
47698 + ;;
47699 + xcclinker)
47700 + linker_flags="$linker_flags $qarg"
47701 + compiler_flags="$compiler_flags $qarg"
47702 + prev=
47703 + func_append compile_command " $qarg"
47704 + func_append finalize_command " $qarg"
47705 + continue
47706 + ;;
47707 + xcompiler)
47708 + compiler_flags="$compiler_flags $qarg"
47709 + prev=
47710 + func_append compile_command " $qarg"
47711 + func_append finalize_command " $qarg"
47712 + continue
47713 + ;;
47714 + xlinker)
47715 + linker_flags="$linker_flags $qarg"
47716 + compiler_flags="$compiler_flags $wl$qarg"
47717 + prev=
47718 + func_append compile_command " $wl$qarg"
47719 + func_append finalize_command " $wl$qarg"
47720 + continue
47721 + ;;
47722 + *)
47723 + eval "$prev=\"\$arg\""
47724 + prev=
47725 + continue
47726 + ;;
47727 + esac
47728 + fi # test -n "$prev"
47729 +
47730 + prevarg="$arg"
47731 +
47732 + case $arg in
47733 + -all-static)
47734 + # The effects of -all-static are defined in a previous loop.
47735 + continue
47736 + ;;
47737 +
47738 + -allow-undefined)
47739 + # FIXME: remove this flag sometime in the future.
47740 + func_fatal_error "\`-allow-undefined' must not be used because it is the default"
47741 + ;;
47742 +
47743 + -avoid-version)
47744 + avoid_version=yes
47745 + continue
47746 + ;;
47747 +
47748 + -dlopen)
47749 + prev=dlfiles
47750 + continue
47751 + ;;
47752 +
47753 + -dlpreopen)
47754 + prev=dlprefiles
47755 + continue
47756 + ;;
47757 +
47758 + -export-dynamic)
47759 + export_dynamic=yes
47760 + continue
47761 + ;;
47762 +
47763 + -export-symbols | -export-symbols-regex)
47764 + if test -n "$export_symbols" || test -n "$export_symbols_regex"; then
47765 + func_fatal_error "more than one -exported-symbols argument is not allowed"
47766 + fi
47767 + if test "X$arg" = "X-export-symbols"; then
47768 + prev=expsyms
47769 + else
47770 + prev=expsyms_regex
47771 + fi
47772 + continue
47773 + ;;
47774 +
47775 + -framework)
47776 + prev=framework
47777 + continue
47778 + ;;
47779 +
47780 + -inst-prefix-dir)
47781 + prev=inst_prefix
47782 + continue
47783 + ;;
47784 +
47785 + # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:*
47786 + # so, if we see these flags be careful not to treat them like -L
47787 + -L[A-Z][A-Z]*:*)
47788 + case $with_gcc/$host in
47789 + no/*-*-irix* | /*-*-irix*)
47790 + func_append compile_command " $arg"
47791 + func_append finalize_command " $arg"
47792 + ;;
47793 + esac
47794 + continue
47795 + ;;
47796 +
47797 + -L*)
47798 + func_stripname '-L' '' "$arg"
47799 + dir=$func_stripname_result
47800 + # We need an absolute path.
47801 + case $dir in
47802 + [\\/]* | [A-Za-z]:[\\/]*) ;;
47803 + *)
47804 + absdir=`cd "$dir" && pwd`
47805 + test -z "$absdir" && \
47806 + func_fatal_error "cannot determine absolute directory name of \`$dir'"
47807 + dir="$absdir"
47808 + ;;
47809 + esac
47810 + case "$deplibs " in
47811 + *" -L$dir "*) ;;
47812 + *)
47813 + deplibs="$deplibs -L$dir"
47814 + lib_search_path="$lib_search_path $dir"
47815 + ;;
47816 + esac
47817 + case $host in
47818 + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
47819 + testbindir=`$ECHO "X$dir" | $Xsed -e 's*/lib$*/bin*'`
47820 + case :$dllsearchpath: in
47821 + *":$dir:"*) ;;
47822 + *) dllsearchpath="$dllsearchpath:$dir";;
47823 + esac
47824 + case :$dllsearchpath: in
47825 + *":$testbindir:"*) ;;
47826 + *) dllsearchpath="$dllsearchpath:$testbindir";;
47827 + esac
47828 + ;;
47829 + esac
47830 + continue
47831 + ;;
47832 +
47833 + -l*)
47834 + if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then
47835 + case $host in
47836 + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*)
47837 + # These systems don't actually have a C or math library (as such)
47838 + continue
47839 + ;;
47840 + *-*-os2*)
47841 + # These systems don't actually have a C library (as such)
47842 + test "X$arg" = "X-lc" && continue
47843 + ;;
47844 + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
47845 + # Do not include libc due to us having libc/libc_r.
47846 + test "X$arg" = "X-lc" && continue
47847 + ;;
47848 + *-*-rhapsody* | *-*-darwin1.[012])
47849 + # Rhapsody C and math libraries are in the System framework
47850 + deplibs="$deplibs System.ltframework"
47851 + continue
47852 + ;;
47853 + *-*-sco3.2v5* | *-*-sco5v6*)
47854 + # Causes problems with __ctype
47855 + test "X$arg" = "X-lc" && continue
47856 + ;;
47857 + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*)
47858 + # Compiler inserts libc in the correct place for threads to work
47859 + test "X$arg" = "X-lc" && continue
47860 + ;;
47861 + esac
47862 + elif test "X$arg" = "X-lc_r"; then
47863 + case $host in
47864 + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
47865 + # Do not include libc_r directly, use -pthread flag.
47866 + continue
47867 + ;;
47868 + esac
47869 + fi
47870 + deplibs="$deplibs $arg"
47871 + continue
47872 + ;;
47873 +
47874 + -module)
47875 + module=yes
47876 + continue
47877 + ;;
47878 +
47879 + # Tru64 UNIX uses -model [arg] to determine the layout of C++
47880 + # classes, name mangling, and exception handling.
47881 + # Darwin uses the -arch flag to determine output architecture.
47882 + -model|-arch|-isysroot)
47883 + compiler_flags="$compiler_flags $arg"
47884 + func_append compile_command " $arg"
47885 + func_append finalize_command " $arg"
47886 + prev=xcompiler
47887 + continue
47888 + ;;
47889 +
47890 + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads)
47891 + compiler_flags="$compiler_flags $arg"
47892 + func_append compile_command " $arg"
47893 + func_append finalize_command " $arg"
47894 + case "$new_inherited_linker_flags " in
47895 + *" $arg "*) ;;
47896 + * ) new_inherited_linker_flags="$new_inherited_linker_flags $arg" ;;
47897 + esac
47898 + continue
47899 + ;;
47900 +
47901 + -multi_module)
47902 + single_module="${wl}-multi_module"
47903 + continue
47904 + ;;
47905 +
47906 + -no-fast-install)
47907 + fast_install=no
47908 + continue
47909 + ;;
47910 +
47911 + -no-install)
47912 + case $host in
47913 + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
47914 + # The PATH hackery in wrapper scripts is required on Windows
47915 + # in order for the loader to find any dlls it needs.
47916 + func_warning "\`-no-install' is ignored for $host"
47917 + func_warning "assuming \`-no-fast-install' instead"
47918 + fast_install=no
47919 + ;;
47920 + *) no_install=yes ;;
47921 + esac
47922 + continue
47923 + ;;
47924 +
47925 + -no-undefined)
47926 + allow_undefined=no
47927 + continue
47928 + ;;
47929 +
47930 + -objectlist)
47931 + prev=objectlist
47932 + continue
47933 + ;;
47934 +
47935 + -o) prev=output ;;
47936 +
47937 + -precious-files-regex)
47938 + prev=precious_regex
47939 + continue
47940 + ;;
47941 +
47942 + -release)
47943 + prev=release
47944 + continue
47945 + ;;
47946 +
47947 + -rpath)
47948 + prev=rpath
47949 + continue
47950 + ;;
47951 +
47952 + -R)
47953 + prev=xrpath
47954 + continue
47955 + ;;
47956 +
47957 + -R*)
47958 + func_stripname '-R' '' "$arg"
47959 + dir=$func_stripname_result
47960 + # We need an absolute path.
47961 + case $dir in
47962 + [\\/]* | [A-Za-z]:[\\/]*) ;;
47963 + *)
47964 + func_fatal_error "only absolute run-paths are allowed"
47965 + ;;
47966 + esac
47967 + case "$xrpath " in
47968 + *" $dir "*) ;;
47969 + *) xrpath="$xrpath $dir" ;;
47970 + esac
47971 + continue
47972 + ;;
47973 +
47974 + -shared)
47975 + # The effects of -shared are defined in a previous loop.
47976 + continue
47977 + ;;
47978 +
47979 + -shrext)
47980 + prev=shrext
47981 + continue
47982 + ;;
47983 +
47984 + -static | -static-libtool-libs)
47985 + # The effects of -static are defined in a previous loop.
47986 + # We used to do the same as -all-static on platforms that
47987 + # didn't have a PIC flag, but the assumption that the effects
47988 + # would be equivalent was wrong. It would break on at least
47989 + # Digital Unix and AIX.
47990 + continue
47991 + ;;
47992 +
47993 + -thread-safe)
47994 + thread_safe=yes
47995 + continue
47996 + ;;
47997 +
47998 + -version-info)
47999 + prev=vinfo
48000 + continue
48001 + ;;
48002 +
48003 + -version-number)
48004 + prev=vinfo
48005 + vinfo_number=yes
48006 + continue
48007 + ;;
48008 +
48009 + -weak)
48010 + prev=weak
48011 + continue
48012 + ;;
48013 +
48014 + -Wc,*)
48015 + func_stripname '-Wc,' '' "$arg"
48016 + args=$func_stripname_result
48017 + arg=
48018 + save_ifs="$IFS"; IFS=','
48019 + for flag in $args; do
48020 + IFS="$save_ifs"
48021 + func_quote_for_eval "$flag"
48022 + arg="$arg $wl$func_quote_for_eval_result"
48023 + compiler_flags="$compiler_flags $func_quote_for_eval_result"
48024 + done
48025 + IFS="$save_ifs"
48026 + func_stripname ' ' '' "$arg"
48027 + arg=$func_stripname_result
48028 + ;;
48029 +
48030 + -Wl,*)
48031 + func_stripname '-Wl,' '' "$arg"
48032 + args=$func_stripname_result
48033 + arg=
48034 + save_ifs="$IFS"; IFS=','
48035 + for flag in $args; do
48036 + IFS="$save_ifs"
48037 + func_quote_for_eval "$flag"
48038 + arg="$arg $wl$func_quote_for_eval_result"
48039 + compiler_flags="$compiler_flags $wl$func_quote_for_eval_result"
48040 + linker_flags="$linker_flags $func_quote_for_eval_result"
48041 + done
48042 + IFS="$save_ifs"
48043 + func_stripname ' ' '' "$arg"
48044 + arg=$func_stripname_result
48045 + ;;
48046 +
48047 + -Xcompiler)
48048 + prev=xcompiler
48049 + continue
48050 + ;;
48051 +
48052 + -Xlinker)
48053 + prev=xlinker
48054 + continue
48055 + ;;
48056 +
48057 + -XCClinker)
48058 + prev=xcclinker
48059 + continue
48060 + ;;
48061 +
48062 + # -64, -mips[0-9] enable 64-bit mode on the SGI compiler
48063 + # -r[0-9][0-9]* specifies the processor on the SGI compiler
48064 + # -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler
48065 + # +DA*, +DD* enable 64-bit mode on the HP compiler
48066 + # -q* pass through compiler args for the IBM compiler
48067 + # -m*, -t[45]*, -txscale* pass through architecture-specific
48068 + # compiler args for GCC
48069 + # -F/path gives path to uninstalled frameworks, gcc on darwin
48070 + # -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC
48071 + # @file GCC response files
48072 + -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
48073 + -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*)
48074 + func_quote_for_eval "$arg"
48075 + arg="$func_quote_for_eval_result"
48076 + func_append compile_command " $arg"
48077 + func_append finalize_command " $arg"
48078 + compiler_flags="$compiler_flags $arg"
48079 + continue
48080 + ;;
48081 +
48082 + # Some other compiler flag.
48083 + -* | +*)
48084 + func_quote_for_eval "$arg"
48085 + arg="$func_quote_for_eval_result"
48086 + ;;
48087 +
48088 + *.$objext)
48089 + # A standard object.
48090 + objs="$objs $arg"
48091 + ;;
48092 +
48093 + *.lo)
48094 + # A libtool-controlled object.
48095 +
48096 + # Check to see that this really is a libtool object.
48097 + if func_lalib_unsafe_p "$arg"; then
48098 + pic_object=
48099 + non_pic_object=
48100 +
48101 + # Read the .lo file
48102 + func_source "$arg"
48103 +
48104 + if test -z "$pic_object" ||
48105 + test -z "$non_pic_object" ||
48106 + test "$pic_object" = none &&
48107 + test "$non_pic_object" = none; then
48108 + func_fatal_error "cannot find name of object for \`$arg'"
48109 + fi
48110 +
48111 + # Extract subdirectory from the argument.
48112 + func_dirname "$arg" "/" ""
48113 + xdir="$func_dirname_result"
48114 +
48115 + if test "$pic_object" != none; then
48116 + # Prepend the subdirectory the object is found in.
48117 + pic_object="$xdir$pic_object"
48118 +
48119 + if test "$prev" = dlfiles; then
48120 + if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then
48121 + dlfiles="$dlfiles $pic_object"
48122 + prev=
48123 + continue
48124 + else
48125 + # If libtool objects are unsupported, then we need to preload.
48126 + prev=dlprefiles
48127 + fi
48128 + fi
48129 +
48130 + # CHECK ME: I think I busted this. -Ossama
48131 + if test "$prev" = dlprefiles; then
48132 + # Preload the old-style object.
48133 + dlprefiles="$dlprefiles $pic_object"
48134 + prev=
48135 + fi
48136 +
48137 + # A PIC object.
48138 + func_append libobjs " $pic_object"
48139 + arg="$pic_object"
48140 + fi
48141 +
48142 + # Non-PIC object.
48143 + if test "$non_pic_object" != none; then
48144 + # Prepend the subdirectory the object is found in.
48145 + non_pic_object="$xdir$non_pic_object"
48146 +
48147 + # A standard non-PIC object
48148 + func_append non_pic_objects " $non_pic_object"
48149 + if test -z "$pic_object" || test "$pic_object" = none ; then
48150 + arg="$non_pic_object"
48151 + fi
48152 + else
48153 + # If the PIC object exists, use it instead.
48154 + # $xdir was prepended to $pic_object above.
48155 + non_pic_object="$pic_object"
48156 + func_append non_pic_objects " $non_pic_object"
48157 + fi
48158 + else
48159 + # Only an error if not doing a dry-run.
48160 + if $opt_dry_run; then
48161 + # Extract subdirectory from the argument.
48162 + func_dirname "$arg" "/" ""
48163 + xdir="$func_dirname_result"
48164 +
48165 + func_lo2o "$arg"
48166 + pic_object=$xdir$objdir/$func_lo2o_result
48167 + non_pic_object=$xdir$func_lo2o_result
48168 + func_append libobjs " $pic_object"
48169 + func_append non_pic_objects " $non_pic_object"
48170 + else
48171 + func_fatal_error "\`$arg' is not a valid libtool object"
48172 + fi
48173 + fi
48174 + ;;
48175 +
48176 + *.$libext)
48177 + # An archive.
48178 + deplibs="$deplibs $arg"
48179 + old_deplibs="$old_deplibs $arg"
48180 + continue
48181 + ;;
48182 +
48183 + *.la)
48184 + # A libtool-controlled library.
48185 +
48186 + if test "$prev" = dlfiles; then
48187 + # This library was specified with -dlopen.
48188 + dlfiles="$dlfiles $arg"
48189 + prev=
48190 + elif test "$prev" = dlprefiles; then
48191 + # The library was specified with -dlpreopen.
48192 + dlprefiles="$dlprefiles $arg"
48193 + prev=
48194 + else
48195 + deplibs="$deplibs $arg"
48196 + fi
48197 + continue
48198 + ;;
48199 +
48200 + # Some other compiler argument.
48201 + *)
48202 + # Unknown arguments in both finalize_command and compile_command need
48203 + # to be aesthetically quoted because they are evaled later.
48204 + func_quote_for_eval "$arg"
48205 + arg="$func_quote_for_eval_result"
48206 + ;;
48207 + esac # arg
48208 +
48209 + # Now actually substitute the argument into the commands.
48210 + if test -n "$arg"; then
48211 + func_append compile_command " $arg"
48212 + func_append finalize_command " $arg"
48213 + fi
48214 + done # argument parsing loop
48215 +
48216 + test -n "$prev" && \
48217 + func_fatal_help "the \`$prevarg' option requires an argument"
48218 +
48219 + if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then
48220 + eval arg=\"$export_dynamic_flag_spec\"
48221 + func_append compile_command " $arg"
48222 + func_append finalize_command " $arg"
48223 + fi
48224 +
48225 + oldlibs=
48226 + # calculate the name of the file, without its directory
48227 + func_basename "$output"
48228 + outputname="$func_basename_result"
48229 + libobjs_save="$libobjs"
48230 +
48231 + if test -n "$shlibpath_var"; then
48232 + # get the directories listed in $shlibpath_var
48233 + eval shlib_search_path=\`\$ECHO \"X\${$shlibpath_var}\" \| \$Xsed -e \'s/:/ /g\'\`
48234 + else
48235 + shlib_search_path=
48236 + fi
48237 + eval sys_lib_search_path=\"$sys_lib_search_path_spec\"
48238 + eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\"
48239 +
48240 + func_dirname "$output" "/" ""
48241 + output_objdir="$func_dirname_result$objdir"
48242 + # Create the object directory.
48243 + func_mkdir_p "$output_objdir"
48244 +
48245 + # Determine the type of output
48246 + case $output in
48247 + "")
48248 + func_fatal_help "you must specify an output file"
48249 + ;;
48250 + *.$libext) linkmode=oldlib ;;
48251 + *.lo | *.$objext) linkmode=obj ;;
48252 + *.la) linkmode=lib ;;
48253 + *) linkmode=prog ;; # Anything else should be a program.
48254 + esac
48255 +
48256 + specialdeplibs=
48257 +
48258 + libs=
48259 + # Find all interdependent deplibs by searching for libraries
48260 + # that are linked more than once (e.g. -la -lb -la)
48261 + for deplib in $deplibs; do
48262 + if $opt_duplicate_deps ; then
48263 + case "$libs " in
48264 + *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
48265 + esac
48266 + fi
48267 + libs="$libs $deplib"
48268 + done
48269 +
48270 + if test "$linkmode" = lib; then
48271 + libs="$predeps $libs $compiler_lib_search_path $postdeps"
48272 +
48273 + # Compute libraries that are listed more than once in $predeps
48274 + # $postdeps and mark them as special (i.e., whose duplicates are
48275 + # not to be eliminated).
48276 + pre_post_deps=
48277 + if $opt_duplicate_compiler_generated_deps; then
48278 + for pre_post_dep in $predeps $postdeps; do
48279 + case "$pre_post_deps " in
48280 + *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;;
48281 + esac
48282 + pre_post_deps="$pre_post_deps $pre_post_dep"
48283 + done
48284 + fi
48285 + pre_post_deps=
48286 + fi
48287 +
48288 + deplibs=
48289 + newdependency_libs=
48290 + newlib_search_path=
48291 + need_relink=no # whether we're linking any uninstalled libtool libraries
48292 + notinst_deplibs= # not-installed libtool libraries
48293 + notinst_path= # paths that contain not-installed libtool libraries
48294 +
48295 + case $linkmode in
48296 + lib)
48297 + passes="conv dlpreopen link"
48298 + for file in $dlfiles $dlprefiles; do
48299 + case $file in
48300 + *.la) ;;
48301 + *)
48302 + func_fatal_help "libraries can \`-dlopen' only libtool libraries: $file"
48303 + ;;
48304 + esac
48305 + done
48306 + ;;
48307 + prog)
48308 + compile_deplibs=
48309 + finalize_deplibs=
48310 + alldeplibs=no
48311 + newdlfiles=
48312 + newdlprefiles=
48313 + passes="conv scan dlopen dlpreopen link"
48314 + ;;
48315 + *) passes="conv"
48316 + ;;
48317 + esac
48318 +
48319 + for pass in $passes; do
48320 + # The preopen pass in lib mode reverses $deplibs; put it back here
48321 + # so that -L comes before libs that need it for instance...
48322 + if test "$linkmode,$pass" = "lib,link"; then
48323 + ## FIXME: Find the place where the list is rebuilt in the wrong
48324 + ## order, and fix it there properly
48325 + tmp_deplibs=
48326 + for deplib in $deplibs; do
48327 + tmp_deplibs="$deplib $tmp_deplibs"
48328 + done
48329 + deplibs="$tmp_deplibs"
48330 + fi
48331 +
48332 + if test "$linkmode,$pass" = "lib,link" ||
48333 + test "$linkmode,$pass" = "prog,scan"; then
48334 + libs="$deplibs"
48335 + deplibs=
48336 + fi
48337 + if test "$linkmode" = prog; then
48338 + case $pass in
48339 + dlopen) libs="$dlfiles" ;;
48340 + dlpreopen) libs="$dlprefiles" ;;
48341 + link) libs="$deplibs %DEPLIBS% $dependency_libs" ;;
48342 + esac
48343 + fi
48344 + if test "$linkmode,$pass" = "lib,dlpreopen"; then
48345 + # Collect and forward deplibs of preopened libtool libs
48346 + for lib in $dlprefiles; do
48347 + # Ignore non-libtool-libs
48348 + dependency_libs=
48349 + case $lib in
48350 + *.la) func_source "$lib" ;;
48351 + esac
48352 +
48353 + # Collect preopened libtool deplibs, except any this library
48354 + # has declared as weak libs
48355 + for deplib in $dependency_libs; do
48356 + deplib_base=`$ECHO "X$deplib" | $Xsed -e "$basename"`
48357 + case " $weak_libs " in
48358 + *" $deplib_base "*) ;;
48359 + *) deplibs="$deplibs $deplib" ;;
48360 + esac
48361 + done
48362 + done
48363 + libs="$dlprefiles"
48364 + fi
48365 + if test "$pass" = dlopen; then
48366 + # Collect dlpreopened libraries
48367 + save_deplibs="$deplibs"
48368 + deplibs=
48369 + fi
48370 +
48371 + for deplib in $libs; do
48372 + lib=
48373 + found=no
48374 + case $deplib in
48375 + -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads)
48376 + if test "$linkmode,$pass" = "prog,link"; then
48377 + compile_deplibs="$deplib $compile_deplibs"
48378 + finalize_deplibs="$deplib $finalize_deplibs"
48379 + else
48380 + compiler_flags="$compiler_flags $deplib"
48381 + if test "$linkmode" = lib ; then
48382 + case "$new_inherited_linker_flags " in
48383 + *" $deplib "*) ;;
48384 + * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;;
48385 + esac
48386 + fi
48387 + fi
48388 + continue
48389 + ;;
48390 + -l*)
48391 + if test "$linkmode" != lib && test "$linkmode" != prog; then
48392 + func_warning "\`-l' is ignored for archives/objects"
48393 + continue
48394 + fi
48395 + func_stripname '-l' '' "$deplib"
48396 + name=$func_stripname_result
48397 + for searchdir in $newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path; do
48398 + for search_ext in .la $std_shrext .so .a; do
48399 + # Search the libtool library
48400 + lib="$searchdir/lib${name}${search_ext}"
48401 + if test -f "$lib"; then
48402 + if test "$search_ext" = ".la"; then
48403 + found=yes
48404 + else
48405 + found=no
48406 + fi
48407 + break 2
48408 + fi
48409 + done
48410 + done
48411 + if test "$found" != yes; then
48412 + # deplib doesn't seem to be a libtool library
48413 + if test "$linkmode,$pass" = "prog,link"; then
48414 + compile_deplibs="$deplib $compile_deplibs"
48415 + finalize_deplibs="$deplib $finalize_deplibs"
48416 + else
48417 + deplibs="$deplib $deplibs"
48418 + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
48419 + fi
48420 + continue
48421 + else # deplib is a libtool library
48422 + # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib,
48423 + # We need to do some special things here, and not later.
48424 + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
48425 + case " $predeps $postdeps " in
48426 + *" $deplib "*)
48427 + if func_lalib_p "$lib"; then
48428 + library_names=
48429 + old_library=
48430 + func_source "$lib"
48431 + for l in $old_library $library_names; do
48432 + ll="$l"
48433 + done
48434 + if test "X$ll" = "X$old_library" ; then # only static version available
48435 + found=no
48436 + func_dirname "$lib" "" "."
48437 + ladir="$func_dirname_result"
48438 + lib=$ladir/$old_library
48439 + if test "$linkmode,$pass" = "prog,link"; then
48440 + compile_deplibs="$deplib $compile_deplibs"
48441 + finalize_deplibs="$deplib $finalize_deplibs"
48442 + else
48443 + deplibs="$deplib $deplibs"
48444 + test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
48445 + fi
48446 + continue
48447 + fi
48448 + fi
48449 + ;;
48450 + *) ;;
48451 + esac
48452 + fi
48453 + fi
48454 + ;; # -l
48455 + *.ltframework)
48456 + if test "$linkmode,$pass" = "prog,link"; then
48457 + compile_deplibs="$deplib $compile_deplibs"
48458 + finalize_deplibs="$deplib $finalize_deplibs"
48459 + else
48460 + deplibs="$deplib $deplibs"
48461 + if test "$linkmode" = lib ; then
48462 + case "$new_inherited_linker_flags " in
48463 + *" $deplib "*) ;;
48464 + * ) new_inherited_linker_flags="$new_inherited_linker_flags $deplib" ;;
48465 + esac
48466 + fi
48467 + fi
48468 + continue
48469 + ;;
48470 + -L*)
48471 + case $linkmode in
48472 + lib)
48473 + deplibs="$deplib $deplibs"
48474 + test "$pass" = conv && continue
48475 + newdependency_libs="$deplib $newdependency_libs"
48476 + func_stripname '-L' '' "$deplib"
48477 + newlib_search_path="$newlib_search_path $func_stripname_result"
48478 + ;;
48479 + prog)
48480 + if test "$pass" = conv; then
48481 + deplibs="$deplib $deplibs"
48482 + continue
48483 + fi
48484 + if test "$pass" = scan; then
48485 + deplibs="$deplib $deplibs"
48486 + else
48487 + compile_deplibs="$deplib $compile_deplibs"
48488 + finalize_deplibs="$deplib $finalize_deplibs"
48489 + fi
48490 + func_stripname '-L' '' "$deplib"
48491 + newlib_search_path="$newlib_search_path $func_stripname_result"
48492 + ;;
48493 + *)
48494 + func_warning "\`-L' is ignored for archives/objects"
48495 + ;;
48496 + esac # linkmode
48497 + continue
48498 + ;; # -L
48499 + -R*)
48500 + if test "$pass" = link; then
48501 + func_stripname '-R' '' "$deplib"
48502 + dir=$func_stripname_result
48503 + # Make sure the xrpath contains only unique directories.
48504 + case "$xrpath " in
48505 + *" $dir "*) ;;
48506 + *) xrpath="$xrpath $dir" ;;
48507 + esac
48508 + fi
48509 + deplibs="$deplib $deplibs"
48510 + continue
48511 + ;;
48512 + *.la) lib="$deplib" ;;
48513 + *.$libext)
48514 + if test "$pass" = conv; then
48515 + deplibs="$deplib $deplibs"
48516 + continue
48517 + fi
48518 + case $linkmode in
48519 + lib)
48520 + # Linking convenience modules into shared libraries is allowed,
48521 + # but linking other static libraries is non-portable.
48522 + case " $dlpreconveniencelibs " in
48523 + *" $deplib "*) ;;
48524 + *)
48525 + valid_a_lib=no
48526 + case $deplibs_check_method in
48527 + match_pattern*)
48528 + set dummy $deplibs_check_method; shift
48529 + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
48530 + if eval "\$ECHO \"X$deplib\"" 2>/dev/null | $Xsed -e 10q \
48531 + | $EGREP "$match_pattern_regex" > /dev/null; then
48532 + valid_a_lib=yes
48533 + fi
48534 + ;;
48535 + pass_all)
48536 + valid_a_lib=yes
48537 + ;;
48538 + esac
48539 + if test "$valid_a_lib" != yes; then
48540 + $ECHO
48541 + $ECHO "*** Warning: Trying to link with static lib archive $deplib."
48542 + $ECHO "*** I have the capability to make that library automatically link in when"
48543 + $ECHO "*** you link to this library. But I can only do this if you have a"
48544 + $ECHO "*** shared version of the library, which you do not appear to have"
48545 + $ECHO "*** because the file extensions .$libext of this argument makes me believe"
48546 + $ECHO "*** that it is just a static archive that I should not use here."
48547 + else
48548 + $ECHO
48549 + $ECHO "*** Warning: Linking the shared library $output against the"
48550 + $ECHO "*** static library $deplib is not portable!"
48551 + deplibs="$deplib $deplibs"
48552 + fi
48553 + ;;
48554 + esac
48555 + continue
48556 + ;;
48557 + prog)
48558 + if test "$pass" != link; then
48559 + deplibs="$deplib $deplibs"
48560 + else
48561 + compile_deplibs="$deplib $compile_deplibs"
48562 + finalize_deplibs="$deplib $finalize_deplibs"
48563 + fi
48564 + continue
48565 + ;;
48566 + esac # linkmode
48567 + ;; # *.$libext
48568 + *.lo | *.$objext)
48569 + if test "$pass" = conv; then
48570 + deplibs="$deplib $deplibs"
48571 + elif test "$linkmode" = prog; then
48572 + if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then
48573 + # If there is no dlopen support or we're linking statically,
48574 + # we need to preload.
48575 + newdlprefiles="$newdlprefiles $deplib"
48576 + compile_deplibs="$deplib $compile_deplibs"
48577 + finalize_deplibs="$deplib $finalize_deplibs"
48578 + else
48579 + newdlfiles="$newdlfiles $deplib"
48580 + fi
48581 + fi
48582 + continue
48583 + ;;
48584 + %DEPLIBS%)
48585 + alldeplibs=yes
48586 + continue
48587 + ;;
48588 + esac # case $deplib
48589 +
48590 + if test "$found" = yes || test -f "$lib"; then :
48591 + else
48592 + func_fatal_error "cannot find the library \`$lib' or unhandled argument \`$deplib'"
48593 + fi
48594 +
48595 + # Check to see that this really is a libtool archive.
48596 + func_lalib_unsafe_p "$lib" \
48597 + || func_fatal_error "\`$lib' is not a valid libtool archive"
48598 +
48599 + func_dirname "$lib" "" "."
48600 + ladir="$func_dirname_result"
48601 +
48602 + dlname=
48603 + dlopen=
48604 + dlpreopen=
48605 + libdir=
48606 + library_names=
48607 + old_library=
48608 + inherited_linker_flags=
48609 + # If the library was installed with an old release of libtool,
48610 + # it will not redefine variables installed, or shouldnotlink
48611 + installed=yes
48612 + shouldnotlink=no
48613 + avoidtemprpath=
48614 +
48615 +
48616 + # Read the .la file
48617 + func_source "$lib"
48618 +
48619 + # Convert "-framework foo" to "foo.ltframework"
48620 + if test -n "$inherited_linker_flags"; then
48621 + tmp_inherited_linker_flags=`$ECHO "X$inherited_linker_flags" | $Xsed -e 's/-framework \([^ $]*\)/\1.ltframework/g'`
48622 + for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do
48623 + case " $new_inherited_linker_flags " in
48624 + *" $tmp_inherited_linker_flag "*) ;;
48625 + *) new_inherited_linker_flags="$new_inherited_linker_flags $tmp_inherited_linker_flag";;
48626 + esac
48627 + done
48628 + fi
48629 + dependency_libs=`$ECHO "X $dependency_libs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
48630 + if test "$linkmode,$pass" = "prog,link"; then
48631 + compile_deplibs="$new_inherited_linker_flags $compile_deplibs"
48632 + finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs"
48633 + else
48634 + compiler_flags="$compiler_flags $inherited_linker_flags"
48635 + fi
48636 + if test "$linkmode,$pass" = "lib,link" ||
48637 + test "$linkmode,$pass" = "prog,scan" ||
48638 + { test "$linkmode" != prog && test "$linkmode" != lib; }; then
48639 + test -n "$dlopen" && dlfiles="$dlfiles $dlopen"
48640 + test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen"
48641 + fi
48642 +
48643 + if test "$pass" = conv; then
48644 + # Only check for convenience libraries
48645 + deplibs="$lib $deplibs"
48646 + if test -z "$libdir"; then
48647 + if test -z "$old_library"; then
48648 + func_fatal_error "cannot find name of link library for \`$lib'"
48649 + fi
48650 + # It is a libtool convenience library, so add in its objects.
48651 + convenience="$convenience $ladir/$objdir/$old_library"
48652 + old_convenience="$old_convenience $ladir/$objdir/$old_library"
48653 + elif test "$linkmode" != prog && test "$linkmode" != lib; then
48654 + func_fatal_error "\`$lib' is not a convenience library"
48655 + fi
48656 + tmp_libs=
48657 + for deplib in $dependency_libs; do
48658 + deplibs="$deplib $deplibs"
48659 + if $opt_duplicate_deps ; then
48660 + case "$tmp_libs " in
48661 + *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
48662 + esac
48663 + fi
48664 + tmp_libs="$tmp_libs $deplib"
48665 + done
48666 + continue
48667 + fi # $pass = conv
48668 +
48669 +
48670 + # Get the name of the library we link against.
48671 + linklib=
48672 + for l in $old_library $library_names; do
48673 + linklib="$l"
48674 + done
48675 + if test -z "$linklib"; then
48676 + func_fatal_error "cannot find name of link library for \`$lib'"
48677 + fi
48678 +
48679 + # This library was specified with -dlopen.
48680 + if test "$pass" = dlopen; then
48681 + if test -z "$libdir"; then
48682 + func_fatal_error "cannot -dlopen a convenience library: \`$lib'"
48683 + fi
48684 + if test -z "$dlname" ||
48685 + test "$dlopen_support" != yes ||
48686 + test "$build_libtool_libs" = no; then
48687 + # If there is no dlname, no dlopen support or we're linking
48688 + # statically, we need to preload. We also need to preload any
48689 + # dependent libraries so libltdl's deplib preloader doesn't
48690 + # bomb out in the load deplibs phase.
48691 + dlprefiles="$dlprefiles $lib $dependency_libs"
48692 + else
48693 + newdlfiles="$newdlfiles $lib"
48694 + fi
48695 + continue
48696 + fi # $pass = dlopen
48697 +
48698 + # We need an absolute path.
48699 + case $ladir in
48700 + [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;;
48701 + *)
48702 + abs_ladir=`cd "$ladir" && pwd`
48703 + if test -z "$abs_ladir"; then
48704 + func_warning "cannot determine absolute directory name of \`$ladir'"
48705 + func_warning "passing it literally to the linker, although it might fail"
48706 + abs_ladir="$ladir"
48707 + fi
48708 + ;;
48709 + esac
48710 + func_basename "$lib"
48711 + laname="$func_basename_result"
48712 +
48713 + # Find the relevant object directory and library name.
48714 + if test "X$installed" = Xyes; then
48715 + if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then
48716 + func_warning "library \`$lib' was moved."
48717 + dir="$ladir"
48718 + absdir="$abs_ladir"
48719 + libdir="$abs_ladir"
48720 + else
48721 + dir="$libdir"
48722 + absdir="$libdir"
48723 + fi
48724 + test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes
48725 + else
48726 + if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then
48727 + dir="$ladir"
48728 + absdir="$abs_ladir"
48729 + # Remove this search path later
48730 + notinst_path="$notinst_path $abs_ladir"
48731 + else
48732 + dir="$ladir/$objdir"
48733 + absdir="$abs_ladir/$objdir"
48734 + # Remove this search path later
48735 + notinst_path="$notinst_path $abs_ladir"
48736 + fi
48737 + fi # $installed = yes
48738 + func_stripname 'lib' '.la' "$laname"
48739 + name=$func_stripname_result
48740 +
48741 + # This library was specified with -dlpreopen.
48742 + if test "$pass" = dlpreopen; then
48743 + if test -z "$libdir" && test "$linkmode" = prog; then
48744 + func_fatal_error "only libraries may -dlpreopen a convenience library: \`$lib'"
48745 + fi
48746 + # Prefer using a static library (so that no silly _DYNAMIC symbols
48747 + # are required to link).
48748 + if test -n "$old_library"; then
48749 + newdlprefiles="$newdlprefiles $dir/$old_library"
48750 + # Keep a list of preopened convenience libraries to check
48751 + # that they are being used correctly in the link pass.
48752 + test -z "$libdir" && \
48753 + dlpreconveniencelibs="$dlpreconveniencelibs $dir/$old_library"
48754 + # Otherwise, use the dlname, so that lt_dlopen finds it.
48755 + elif test -n "$dlname"; then
48756 + newdlprefiles="$newdlprefiles $dir/$dlname"
48757 + else
48758 + newdlprefiles="$newdlprefiles $dir/$linklib"
48759 + fi
48760 + fi # $pass = dlpreopen
48761 +
48762 + if test -z "$libdir"; then
48763 + # Link the convenience library
48764 + if test "$linkmode" = lib; then
48765 + deplibs="$dir/$old_library $deplibs"
48766 + elif test "$linkmode,$pass" = "prog,link"; then
48767 + compile_deplibs="$dir/$old_library $compile_deplibs"
48768 + finalize_deplibs="$dir/$old_library $finalize_deplibs"
48769 + else
48770 + deplibs="$lib $deplibs" # used for prog,scan pass
48771 + fi
48772 + continue
48773 + fi
48774 +
48775 +
48776 + if test "$linkmode" = prog && test "$pass" != link; then
48777 + newlib_search_path="$newlib_search_path $ladir"
48778 + deplibs="$lib $deplibs"
48779 +
48780 + linkalldeplibs=no
48781 + if test "$link_all_deplibs" != no || test -z "$library_names" ||
48782 + test "$build_libtool_libs" = no; then
48783 + linkalldeplibs=yes
48784 + fi
48785 +
48786 + tmp_libs=
48787 + for deplib in $dependency_libs; do
48788 + case $deplib in
48789 + -L*) func_stripname '-L' '' "$deplib"
48790 + newlib_search_path="$newlib_search_path $func_stripname_result"
48791 + ;;
48792 + esac
48793 + # Need to link against all dependency_libs?
48794 + if test "$linkalldeplibs" = yes; then
48795 + deplibs="$deplib $deplibs"
48796 + else
48797 + # Need to hardcode shared library paths
48798 + # or/and link against static libraries
48799 + newdependency_libs="$deplib $newdependency_libs"
48800 + fi
48801 + if $opt_duplicate_deps ; then
48802 + case "$tmp_libs " in
48803 + *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
48804 + esac
48805 + fi
48806 + tmp_libs="$tmp_libs $deplib"
48807 + done # for deplib
48808 + continue
48809 + fi # $linkmode = prog...
48810 +
48811 + if test "$linkmode,$pass" = "prog,link"; then
48812 + if test -n "$library_names" &&
48813 + { { test "$prefer_static_libs" = no ||
48814 + test "$prefer_static_libs,$installed" = "built,yes"; } ||
48815 + test -z "$old_library"; }; then
48816 + # We need to hardcode the library path
48817 + if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then
48818 + # Make sure the rpath contains only unique directories.
48819 + case "$temp_rpath:" in
48820 + *"$absdir:"*) ;;
48821 + *) temp_rpath="$temp_rpath$absdir:" ;;
48822 + esac
48823 + fi
48824 +
48825 + # Hardcode the library path.
48826 + # Skip directories that are in the system default run-time
48827 + # search path.
48828 + case " $sys_lib_dlsearch_path " in
48829 + *" $absdir "*) ;;
48830 + *)
48831 + case "$compile_rpath " in
48832 + *" $absdir "*) ;;
48833 + *) compile_rpath="$compile_rpath $absdir"
48834 + esac
48835 + ;;
48836 + esac
48837 + case " $sys_lib_dlsearch_path " in
48838 + *" $libdir "*) ;;
48839 + *)
48840 + case "$finalize_rpath " in
48841 + *" $libdir "*) ;;
48842 + *) finalize_rpath="$finalize_rpath $libdir"
48843 + esac
48844 + ;;
48845 + esac
48846 + fi # $linkmode,$pass = prog,link...
48847 +
48848 + if test "$alldeplibs" = yes &&
48849 + { test "$deplibs_check_method" = pass_all ||
48850 + { test "$build_libtool_libs" = yes &&
48851 + test -n "$library_names"; }; }; then
48852 + # We only need to search for static libraries
48853 + continue
48854 + fi
48855 + fi
48856 +
48857 + link_static=no # Whether the deplib will be linked statically
48858 + use_static_libs=$prefer_static_libs
48859 + if test "$use_static_libs" = built && test "$installed" = yes; then
48860 + use_static_libs=no
48861 + fi
48862 + if test -n "$library_names" &&
48863 + { test "$use_static_libs" = no || test -z "$old_library"; }; then
48864 + case $host in
48865 + *cygwin* | *mingw*)
48866 + # No point in relinking DLLs because paths are not encoded
48867 + notinst_deplibs="$notinst_deplibs $lib"
48868 + need_relink=no
48869 + ;;
48870 + *)
48871 + if test "$installed" = no; then
48872 + notinst_deplibs="$notinst_deplibs $lib"
48873 + need_relink=yes
48874 + fi
48875 + ;;
48876 + esac
48877 + # This is a shared library
48878 +
48879 + # Warn about portability, can't link against -module's on some
48880 + # systems (darwin). Don't bleat about dlopened modules though!
48881 + dlopenmodule=""
48882 + for dlpremoduletest in $dlprefiles; do
48883 + if test "X$dlpremoduletest" = "X$lib"; then
48884 + dlopenmodule="$dlpremoduletest"
48885 + break
48886 + fi
48887 + done
48888 + if test -z "$dlopenmodule" && test "$shouldnotlink" = yes && test "$pass" = link; then
48889 + $ECHO
48890 + if test "$linkmode" = prog; then
48891 + $ECHO "*** Warning: Linking the executable $output against the loadable module"
48892 + else
48893 + $ECHO "*** Warning: Linking the shared library $output against the loadable module"
48894 + fi
48895 + $ECHO "*** $linklib is not portable!"
48896 + fi
48897 + if test "$linkmode" = lib &&
48898 + test "$hardcode_into_libs" = yes; then
48899 + # Hardcode the library path.
48900 + # Skip directories that are in the system default run-time
48901 + # search path.
48902 + case " $sys_lib_dlsearch_path " in
48903 + *" $absdir "*) ;;
48904 + *)
48905 + case "$compile_rpath " in
48906 + *" $absdir "*) ;;
48907 + *) compile_rpath="$compile_rpath $absdir"
48908 + esac
48909 + ;;
48910 + esac
48911 + case " $sys_lib_dlsearch_path " in
48912 + *" $libdir "*) ;;
48913 + *)
48914 + case "$finalize_rpath " in
48915 + *" $libdir "*) ;;
48916 + *) finalize_rpath="$finalize_rpath $libdir"
48917 + esac
48918 + ;;
48919 + esac
48920 + fi
48921 +
48922 + if test -n "$old_archive_from_expsyms_cmds"; then
48923 + # figure out the soname
48924 + set dummy $library_names
48925 + shift
48926 + realname="$1"
48927 + shift
48928 + libname=`eval "\\$ECHO \"$libname_spec\""`
48929 + # use dlname if we got it. it's perfectly good, no?
48930 + if test -n "$dlname"; then
48931 + soname="$dlname"
48932 + elif test -n "$soname_spec"; then
48933 + # bleh windows
48934 + case $host in
48935 + *cygwin* | mingw*)
48936 + major=`expr $current - $age`
48937 + versuffix="-$major"
48938 + ;;
48939 + esac
48940 + eval soname=\"$soname_spec\"
48941 + else
48942 + soname="$realname"
48943 + fi
48944 +
48945 + # Make a new name for the extract_expsyms_cmds to use
48946 + soroot="$soname"
48947 + func_basename "$soroot"
48948 + soname="$func_basename_result"
48949 + func_stripname 'lib' '.dll' "$soname"
48950 + newlib=libimp-$func_stripname_result.a
48951 +
48952 + # If the library has no export list, then create one now
48953 + if test -f "$output_objdir/$soname-def"; then :
48954 + else
48955 + func_echo "extracting exported symbol list from \`$soname'"
48956 + func_execute_cmds "$extract_expsyms_cmds" 'exit $?'
48957 + fi
48958 +
48959 + # Create $newlib
48960 + if test -f "$output_objdir/$newlib"; then :; else
48961 + func_echo "generating import library for \`$soname'"
48962 + func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?'
48963 + fi
48964 + # make sure the library variables are pointing to the new library
48965 + dir=$output_objdir
48966 + linklib=$newlib
48967 + fi # test -n "$old_archive_from_expsyms_cmds"
48968 +
48969 + if test "$linkmode" = prog || test "$mode" != relink; then
48970 + add_shlibpath=
48971 + add_dir=
48972 + add=
48973 + lib_linked=yes
48974 + case $hardcode_action in
48975 + immediate | unsupported)
48976 + if test "$hardcode_direct" = no; then
48977 + add="$dir/$linklib"
48978 + case $host in
48979 + *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;;
48980 + *-*-sysv4*uw2*) add_dir="-L$dir" ;;
48981 + *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \
48982 + *-*-unixware7*) add_dir="-L$dir" ;;
48983 + *-*-darwin* )
48984 + # if the lib is a (non-dlopened) module then we can not
48985 + # link against it, someone is ignoring the earlier warnings
48986 + if /usr/bin/file -L $add 2> /dev/null |
48987 + $GREP ": [^:]* bundle" >/dev/null ; then
48988 + if test "X$dlopenmodule" != "X$lib"; then
48989 + $ECHO "*** Warning: lib $linklib is a module, not a shared library"
48990 + if test -z "$old_library" ; then
48991 + $ECHO
48992 + $ECHO "*** And there doesn't seem to be a static archive available"
48993 + $ECHO "*** The link will probably fail, sorry"
48994 + else
48995 + add="$dir/$old_library"
48996 + fi
48997 + elif test -n "$old_library"; then
48998 + add="$dir/$old_library"
48999 + fi
49000 + fi
49001 + esac
49002 + elif test "$hardcode_minus_L" = no; then
49003 + case $host in
49004 + *-*-sunos*) add_shlibpath="$dir" ;;
49005 + esac
49006 + add_dir="-L$dir"
49007 + add="-l$name"
49008 + elif test "$hardcode_shlibpath_var" = no; then
49009 + add_shlibpath="$dir"
49010 + add="-l$name"
49011 + else
49012 + lib_linked=no
49013 + fi
49014 + ;;
49015 + relink)
49016 + if test "$hardcode_direct" = yes &&
49017 + test "$hardcode_direct_absolute" = no; then
49018 + add="$dir/$linklib"
49019 + elif test "$hardcode_minus_L" = yes; then
49020 + add_dir="-L$dir"
49021 + # Try looking first in the location we're being installed to.
49022 + if test -n "$inst_prefix_dir"; then
49023 + case $libdir in
49024 + [\\/]*)
49025 + add_dir="$add_dir -L$inst_prefix_dir$libdir"
49026 + ;;
49027 + esac
49028 + fi
49029 + add="-l$name"
49030 + elif test "$hardcode_shlibpath_var" = yes; then
49031 + add_shlibpath="$dir"
49032 + add="-l$name"
49033 + else
49034 + lib_linked=no
49035 + fi
49036 + ;;
49037 + *) lib_linked=no ;;
49038 + esac
49039 +
49040 + if test "$lib_linked" != yes; then
49041 + func_fatal_configuration "unsupported hardcode properties"
49042 + fi
49043 +
49044 + if test -n "$add_shlibpath"; then
49045 + case :$compile_shlibpath: in
49046 + *":$add_shlibpath:"*) ;;
49047 + *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;;
49048 + esac
49049 + fi
49050 + if test "$linkmode" = prog; then
49051 + test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs"
49052 + test -n "$add" && compile_deplibs="$add $compile_deplibs"
49053 + else
49054 + test -n "$add_dir" && deplibs="$add_dir $deplibs"
49055 + test -n "$add" && deplibs="$add $deplibs"
49056 + if test "$hardcode_direct" != yes &&
49057 + test "$hardcode_minus_L" != yes &&
49058 + test "$hardcode_shlibpath_var" = yes; then
49059 + case :$finalize_shlibpath: in
49060 + *":$libdir:"*) ;;
49061 + *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;;
49062 + esac
49063 + fi
49064 + fi
49065 + fi
49066 +
49067 + if test "$linkmode" = prog || test "$mode" = relink; then
49068 + add_shlibpath=
49069 + add_dir=
49070 + add=
49071 + # Finalize command for both is simple: just hardcode it.
49072 + if test "$hardcode_direct" = yes &&
49073 + test "$hardcode_direct_absolute" = no; then
49074 + add="$libdir/$linklib"
49075 + elif test "$hardcode_minus_L" = yes; then
49076 + add_dir="-L$libdir"
49077 + add="-l$name"
49078 + elif test "$hardcode_shlibpath_var" = yes; then
49079 + case :$finalize_shlibpath: in
49080 + *":$libdir:"*) ;;
49081 + *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;;
49082 + esac
49083 + add="-l$name"
49084 + elif test "$hardcode_automatic" = yes; then
49085 + if test -n "$inst_prefix_dir" &&
49086 + test -f "$inst_prefix_dir$libdir/$linklib" ; then
49087 + add="$inst_prefix_dir$libdir/$linklib"
49088 + else
49089 + add="$libdir/$linklib"
49090 + fi
49091 + else
49092 + # We cannot seem to hardcode it, guess we'll fake it.
49093 + add_dir="-L$libdir"
49094 + # Try looking first in the location we're being installed to.
49095 + if test -n "$inst_prefix_dir"; then
49096 + case $libdir in
49097 + [\\/]*)
49098 + add_dir="$add_dir -L$inst_prefix_dir$libdir"
49099 + ;;
49100 + esac
49101 + fi
49102 + add="-l$name"
49103 + fi
49104 +
49105 + if test "$linkmode" = prog; then
49106 + test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs"
49107 + test -n "$add" && finalize_deplibs="$add $finalize_deplibs"
49108 + else
49109 + test -n "$add_dir" && deplibs="$add_dir $deplibs"
49110 + test -n "$add" && deplibs="$add $deplibs"
49111 + fi
49112 + fi
49113 + elif test "$linkmode" = prog; then
49114 + # Here we assume that one of hardcode_direct or hardcode_minus_L
49115 + # is not unsupported. This is valid on all known static and
49116 + # shared platforms.
49117 + if test "$hardcode_direct" != unsupported; then
49118 + test -n "$old_library" && linklib="$old_library"
49119 + compile_deplibs="$dir/$linklib $compile_deplibs"
49120 + finalize_deplibs="$dir/$linklib $finalize_deplibs"
49121 + else
49122 + compile_deplibs="-l$name -L$dir $compile_deplibs"
49123 + finalize_deplibs="-l$name -L$dir $finalize_deplibs"
49124 + fi
49125 + elif test "$build_libtool_libs" = yes; then
49126 + # Not a shared library
49127 + if test "$deplibs_check_method" != pass_all; then
49128 + # We're trying link a shared library against a static one
49129 + # but the system doesn't support it.
49130 +
49131 + # Just print a warning and add the library to dependency_libs so
49132 + # that the program can be linked against the static library.
49133 + $ECHO
49134 + $ECHO "*** Warning: This system can not link to static lib archive $lib."
49135 + $ECHO "*** I have the capability to make that library automatically link in when"
49136 + $ECHO "*** you link to this library. But I can only do this if you have a"
49137 + $ECHO "*** shared version of the library, which you do not appear to have."
49138 + if test "$module" = yes; then
49139 + $ECHO "*** But as you try to build a module library, libtool will still create "
49140 + $ECHO "*** a static module, that should work as long as the dlopening application"
49141 + $ECHO "*** is linked with the -dlopen flag to resolve symbols at runtime."
49142 + if test -z "$global_symbol_pipe"; then
49143 + $ECHO
49144 + $ECHO "*** However, this would only work if libtool was able to extract symbol"
49145 + $ECHO "*** lists from a program, using \`nm' or equivalent, but libtool could"
49146 + $ECHO "*** not find such a program. So, this module is probably useless."
49147 + $ECHO "*** \`nm' from GNU binutils and a full rebuild may help."
49148 + fi
49149 + if test "$build_old_libs" = no; then
49150 + build_libtool_libs=module
49151 + build_old_libs=yes
49152 + else
49153 + build_libtool_libs=no
49154 + fi
49155 + fi
49156 + else
49157 + deplibs="$dir/$old_library $deplibs"
49158 + link_static=yes
49159 + fi
49160 + fi # link shared/static library?
49161 +
49162 + if test "$linkmode" = lib; then
49163 + if test -n "$dependency_libs" &&
49164 + { test "$hardcode_into_libs" != yes ||
49165 + test "$build_old_libs" = yes ||
49166 + test "$link_static" = yes; }; then
49167 + # Extract -R from dependency_libs
49168 + temp_deplibs=
49169 + for libdir in $dependency_libs; do
49170 + case $libdir in
49171 + -R*) func_stripname '-R' '' "$libdir"
49172 + temp_xrpath=$func_stripname_result
49173 + case " $xrpath " in
49174 + *" $temp_xrpath "*) ;;
49175 + *) xrpath="$xrpath $temp_xrpath";;
49176 + esac;;
49177 + *) temp_deplibs="$temp_deplibs $libdir";;
49178 + esac
49179 + done
49180 + dependency_libs="$temp_deplibs"
49181 + fi
49182 +
49183 + newlib_search_path="$newlib_search_path $absdir"
49184 + # Link against this library
49185 + test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs"
49186 + # ... and its dependency_libs
49187 + tmp_libs=
49188 + for deplib in $dependency_libs; do
49189 + newdependency_libs="$deplib $newdependency_libs"
49190 + if $opt_duplicate_deps ; then
49191 + case "$tmp_libs " in
49192 + *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;;
49193 + esac
49194 + fi
49195 + tmp_libs="$tmp_libs $deplib"
49196 + done
49197 +
49198 + if test "$link_all_deplibs" != no; then
49199 + # Add the search paths of all dependency libraries
49200 + for deplib in $dependency_libs; do
49201 + case $deplib in
49202 + -L*) path="$deplib" ;;
49203 + *.la)
49204 + func_dirname "$deplib" "" "."
49205 + dir="$func_dirname_result"
49206 + # We need an absolute path.
49207 + case $dir in
49208 + [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;;
49209 + *)
49210 + absdir=`cd "$dir" && pwd`
49211 + if test -z "$absdir"; then
49212 + func_warning "cannot determine absolute directory name of \`$dir'"
49213 + absdir="$dir"
49214 + fi
49215 + ;;
49216 + esac
49217 + if $GREP "^installed=no" $deplib > /dev/null; then
49218 + case $host in
49219 + *-*-darwin*)
49220 + depdepl=
49221 + eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib`
49222 + if test -n "$deplibrary_names" ; then
49223 + for tmp in $deplibrary_names ; do
49224 + depdepl=$tmp
49225 + done
49226 + if test -f "$absdir/$objdir/$depdepl" ; then
49227 + depdepl="$absdir/$objdir/$depdepl"
49228 + darwin_install_name=`otool -L $depdepl | $SED -n -e '3q;2,2p' | $SED -e 's/(.*//'`
49229 + darwin_install_name=`$ECHO $darwin_install_name`
49230 + if test -z "$darwin_install_name"; then
49231 + darwin_install_name=`otool64 -L $depdepl | $SED -n -e '3q;2,2p' | $SED -e 's/(.*//'`
49232 + darwin_install_name=`$ECHO $darwin_install_name`
49233 + fi
49234 + compiler_flags="$compiler_flags ${wl}-dylib_file ${wl}${darwin_install_name}:${depdepl}"
49235 + linker_flags="$linker_flags -dylib_file ${darwin_install_name}:${depdepl}"
49236 + path=
49237 + fi
49238 + fi
49239 + ;;
49240 + *)
49241 + path="-L$absdir/$objdir"
49242 + ;;
49243 + esac
49244 + else
49245 + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
49246 + test -z "$libdir" && \
49247 + func_fatal_error "\`$deplib' is not a valid libtool archive"
49248 + test "$absdir" != "$libdir" && \
49249 + func_warning "\`$deplib' seems to be moved"
49250 +
49251 + path="-L$absdir"
49252 + fi
49253 + ;;
49254 + esac
49255 + case " $deplibs " in
49256 + *" $path "*) ;;
49257 + *) deplibs="$path $deplibs" ;;
49258 + esac
49259 + done
49260 + fi # link_all_deplibs != no
49261 + fi # linkmode = lib
49262 + done # for deplib in $libs
49263 + dependency_libs="$newdependency_libs"
49264 + if test "$pass" = dlpreopen; then
49265 + # Link the dlpreopened libraries before other libraries
49266 + for deplib in $save_deplibs; do
49267 + deplibs="$deplib $deplibs"
49268 + done
49269 + fi
49270 + if test "$pass" != dlopen; then
49271 + if test "$pass" != conv; then
49272 + # Make sure lib_search_path contains only unique directories.
49273 + lib_search_path=
49274 + for dir in $newlib_search_path; do
49275 + case "$lib_search_path " in
49276 + *" $dir "*) ;;
49277 + *) lib_search_path="$lib_search_path $dir" ;;
49278 + esac
49279 + done
49280 + newlib_search_path=
49281 + fi
49282 +
49283 + if test "$linkmode,$pass" != "prog,link"; then
49284 + vars="deplibs"
49285 + else
49286 + vars="compile_deplibs finalize_deplibs"
49287 + fi
49288 + for var in $vars dependency_libs; do
49289 + # Add libraries to $var in reverse order
49290 + eval tmp_libs=\"\$$var\"
49291 + new_libs=
49292 + for deplib in $tmp_libs; do
49293 + # FIXME: Pedantically, this is the right thing to do, so
49294 + # that some nasty dependency loop isn't accidentally
49295 + # broken:
49296 + #new_libs="$deplib $new_libs"
49297 + # Pragmatically, this seems to cause very few problems in
49298 + # practice:
49299 + case $deplib in
49300 + -L*) new_libs="$deplib $new_libs" ;;
49301 + -R*) ;;
49302 + *)
49303 + # And here is the reason: when a library appears more
49304 + # than once as an explicit dependence of a library, or
49305 + # is implicitly linked in more than once by the
49306 + # compiler, it is considered special, and multiple
49307 + # occurrences thereof are not removed. Compare this
49308 + # with having the same library being listed as a
49309 + # dependency of multiple other libraries: in this case,
49310 + # we know (pedantically, we assume) the library does not
49311 + # need to be listed more than once, so we keep only the
49312 + # last copy. This is not always right, but it is rare
49313 + # enough that we require users that really mean to play
49314 + # such unportable linking tricks to link the library
49315 + # using -Wl,-lname, so that libtool does not consider it
49316 + # for duplicate removal.
49317 + case " $specialdeplibs " in
49318 + *" $deplib "*) new_libs="$deplib $new_libs" ;;
49319 + *)
49320 + case " $new_libs " in
49321 + *" $deplib "*) ;;
49322 + *) new_libs="$deplib $new_libs" ;;
49323 + esac
49324 + ;;
49325 + esac
49326 + ;;
49327 + esac
49328 + done
49329 + tmp_libs=
49330 + for deplib in $new_libs; do
49331 + case $deplib in
49332 + -L*)
49333 + case " $tmp_libs " in
49334 + *" $deplib "*) ;;
49335 + *) tmp_libs="$tmp_libs $deplib" ;;
49336 + esac
49337 + ;;
49338 + *) tmp_libs="$tmp_libs $deplib" ;;
49339 + esac
49340 + done
49341 + eval $var=\"$tmp_libs\"
49342 + done # for var
49343 + fi
49344 + # Last step: remove runtime libs from dependency_libs
49345 + # (they stay in deplibs)
49346 + tmp_libs=
49347 + for i in $dependency_libs ; do
49348 + case " $predeps $postdeps $compiler_lib_search_path " in
49349 + *" $i "*)
49350 + i=""
49351 + ;;
49352 + esac
49353 + if test -n "$i" ; then
49354 + tmp_libs="$tmp_libs $i"
49355 + fi
49356 + done
49357 + dependency_libs=$tmp_libs
49358 + done # for pass
49359 + if test "$linkmode" = prog; then
49360 + dlfiles="$newdlfiles"
49361 + fi
49362 + if test "$linkmode" = prog || test "$linkmode" = lib; then
49363 + dlprefiles="$newdlprefiles"
49364 + fi
49365 +
49366 + case $linkmode in
49367 + oldlib)
49368 + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
49369 + func_warning "\`-dlopen' is ignored for archives"
49370 + fi
49371 +
49372 + test -n "$deplibs" && \
49373 + func_warning "\`-l' and \`-L' are ignored for archives"
49374 +
49375 +
49376 + test -n "$rpath" && \
49377 + func_warning "\`-rpath' is ignored for archives"
49378 +
49379 + test -n "$xrpath" && \
49380 + func_warning "\`-R' is ignored for archives"
49381 +
49382 + test -n "$vinfo" && \
49383 + func_warning "\`-version-info/-version-number' is ignored for archives"
49384 +
49385 + test -n "$release" && \
49386 + func_warning "\`-release' is ignored for archives"
49387 +
49388 + test -n "$export_symbols$export_symbols_regex" && \
49389 + func_warning "\`-export-symbols' is ignored for archives"
49390 +
49391 + # Now set the variables for building old libraries.
49392 + build_libtool_libs=no
49393 + oldlibs="$output"
49394 + objs="$objs$old_deplibs"
49395 + ;;
49396 +
49397 + lib)
49398 + # Make sure we only generate libraries of the form `libNAME.la'.
49399 + case $outputname in
49400 + lib*)
49401 + func_stripname 'lib' '.la' "$outputname"
49402 + name=$func_stripname_result
49403 + eval shared_ext=\"$shrext_cmds\"
49404 + eval libname=\"$libname_spec\"
49405 + ;;
49406 + *)
49407 + test "$module" = no && \
49408 + func_fatal_help "libtool library \`$output' must begin with \`lib'"
49409 +
49410 + if test "$need_lib_prefix" != no; then
49411 + # Add the "lib" prefix for modules if required
49412 + func_stripname '' '.la' "$outputname"
49413 + name=$func_stripname_result
49414 + eval shared_ext=\"$shrext_cmds\"
49415 + eval libname=\"$libname_spec\"
49416 + else
49417 + func_stripname '' '.la' "$outputname"
49418 + libname=$func_stripname_result
49419 + fi
49420 + ;;
49421 + esac
49422 +
49423 + if test -n "$objs"; then
49424 + if test "$deplibs_check_method" != pass_all; then
49425 + func_fatal_error "cannot build libtool library \`$output' from non-libtool objects on this host:$objs"
49426 + else
49427 + $ECHO
49428 + $ECHO "*** Warning: Linking the shared library $output against the non-libtool"
49429 + $ECHO "*** objects $objs is not portable!"
49430 + libobjs="$libobjs $objs"
49431 + fi
49432 + fi
49433 +
49434 + test "$dlself" != no && \
49435 + func_warning "\`-dlopen self' is ignored for libtool libraries"
49436 +
49437 + set dummy $rpath
49438 + shift
49439 + test "$#" -gt 1 && \
49440 + func_warning "ignoring multiple \`-rpath's for a libtool library"
49441 +
49442 + install_libdir="$1"
49443 +
49444 + oldlibs=
49445 + if test -z "$rpath"; then
49446 + if test "$build_libtool_libs" = yes; then
49447 + # Building a libtool convenience library.
49448 + # Some compilers have problems with a `.al' extension so
49449 + # convenience libraries should have the same extension an
49450 + # archive normally would.
49451 + oldlibs="$output_objdir/$libname.$libext $oldlibs"
49452 + build_libtool_libs=convenience
49453 + build_old_libs=yes
49454 + fi
49455 +
49456 + test -n "$vinfo" && \
49457 + func_warning "\`-version-info/-version-number' is ignored for convenience libraries"
49458 +
49459 + test -n "$release" && \
49460 + func_warning "\`-release' is ignored for convenience libraries"
49461 + else
49462 +
49463 + # Parse the version information argument.
49464 + save_ifs="$IFS"; IFS=':'
49465 + set dummy $vinfo 0 0 0
49466 + shift
49467 + IFS="$save_ifs"
49468 +
49469 + test -n "$7" && \
49470 + func_fatal_help "too many parameters to \`-version-info'"
49471 +
49472 + # convert absolute version numbers to libtool ages
49473 + # this retains compatibility with .la files and attempts
49474 + # to make the code below a bit more comprehensible
49475 +
49476 + case $vinfo_number in
49477 + yes)
49478 + number_major="$1"
49479 + number_minor="$2"
49480 + number_revision="$3"
49481 + #
49482 + # There are really only two kinds -- those that
49483 + # use the current revision as the major version
49484 + # and those that subtract age and use age as
49485 + # a minor version. But, then there is irix
49486 + # which has an extra 1 added just for fun
49487 + #
49488 + case $version_type in
49489 + darwin|linux|osf|windows|none)
49490 + current=`expr $number_major + $number_minor`
49491 + age="$number_minor"
49492 + revision="$number_revision"
49493 + ;;
49494 + freebsd-aout|freebsd-elf|sunos)
49495 + current="$number_major"
49496 + revision="$number_minor"
49497 + age="0"
49498 + ;;
49499 + irix|nonstopux)
49500 + current=`expr $number_major + $number_minor - 1`
49501 + age="$number_minor"
49502 + revision="$number_minor"
49503 + ;;
49504 + esac
49505 + ;;
49506 + no)
49507 + current="$1"
49508 + revision="$2"
49509 + age="$3"
49510 + ;;
49511 + esac
49512 +
49513 + # Check that each of the things are valid numbers.
49514 + case $current in
49515 + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
49516 + *)
49517 + func_error "CURRENT \`$current' must be a nonnegative integer"
49518 + func_fatal_error "\`$vinfo' is not valid version information"
49519 + ;;
49520 + esac
49521 +
49522 + case $revision in
49523 + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
49524 + *)
49525 + func_error "REVISION \`$revision' must be a nonnegative integer"
49526 + func_fatal_error "\`$vinfo' is not valid version information"
49527 + ;;
49528 + esac
49529 +
49530 + case $age in
49531 + 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;;
49532 + *)
49533 + func_error "AGE \`$age' must be a nonnegative integer"
49534 + func_fatal_error "\`$vinfo' is not valid version information"
49535 + ;;
49536 + esac
49537 +
49538 + if test "$age" -gt "$current"; then
49539 + func_error "AGE \`$age' is greater than the current interface number \`$current'"
49540 + func_fatal_error "\`$vinfo' is not valid version information"
49541 + fi
49542 +
49543 + # Calculate the version variables.
49544 + major=
49545 + versuffix=
49546 + verstring=
49547 + case $version_type in
49548 + none) ;;
49549 +
49550 + darwin)
49551 + # Like Linux, but with the current version available in
49552 + # verstring for coding it into the library header
49553 + major=.`expr $current - $age`
49554 + versuffix="$major.$age.$revision"
49555 + # Darwin ld doesn't like 0 for these options...
49556 + minor_current=`expr $current + 1`
49557 + verstring="-compatibility_version $minor_current -current_version $minor_current.$revision"
49558 + ;;
49559 +
49560 + freebsd-aout)
49561 + major=".$current"
49562 + versuffix=".$current.$revision";
49563 + ;;
49564 +
49565 + freebsd-elf)
49566 + major=".$current"
49567 + versuffix=".$current"
49568 + ;;
49569 +
49570 + irix | nonstopux)
49571 + major=`expr $current - $age + 1`
49572 +
49573 + case $version_type in
49574 + nonstopux) verstring_prefix=nonstopux ;;
49575 + *) verstring_prefix=sgi ;;
49576 + esac
49577 + verstring="$verstring_prefix$major.$revision"
49578 +
49579 + # Add in all the interfaces that we are compatible with.
49580 + loop=$revision
49581 + while test "$loop" -ne 0; do
49582 + iface=`expr $revision - $loop`
49583 + loop=`expr $loop - 1`
49584 + verstring="$verstring_prefix$major.$iface:$verstring"
49585 + done
49586 +
49587 + # Before this point, $major must not contain `.'.
49588 + major=.$major
49589 + versuffix="$major.$revision"
49590 + ;;
49591 +
49592 + linux)
49593 + major=.`expr $current - $age`
49594 + versuffix="$major.$age.$revision"
49595 + ;;
49596 +
49597 + osf)
49598 + major=.`expr $current - $age`
49599 + versuffix=".$current.$age.$revision"
49600 + verstring="$current.$age.$revision"
49601 +
49602 + # Add in all the interfaces that we are compatible with.
49603 + loop=$age
49604 + while test "$loop" -ne 0; do
49605 + iface=`expr $current - $loop`
49606 + loop=`expr $loop - 1`
49607 + verstring="$verstring:${iface}.0"
49608 + done
49609 +
49610 + # Make executables depend on our current version.
49611 + verstring="$verstring:${current}.0"
49612 + ;;
49613 +
49614 + qnx)
49615 + major=".$current"
49616 + versuffix=".$current"
49617 + ;;
49618 +
49619 + sunos)
49620 + major=".$current"
49621 + versuffix=".$current.$revision"
49622 + ;;
49623 +
49624 + windows)
49625 + # Use '-' rather than '.', since we only want one
49626 + # extension on DOS 8.3 filesystems.
49627 + major=`expr $current - $age`
49628 + versuffix="-$major"
49629 + ;;
49630 +
49631 + *)
49632 + func_fatal_configuration "unknown library version type \`$version_type'"
49633 + ;;
49634 + esac
49635 +
49636 + # Clear the version info if we defaulted, and they specified a release.
49637 + if test -z "$vinfo" && test -n "$release"; then
49638 + major=
49639 + case $version_type in
49640 + darwin)
49641 + # we can't check for "0.0" in archive_cmds due to quoting
49642 + # problems, so we reset it completely
49643 + verstring=
49644 + ;;
49645 + *)
49646 + verstring="0.0"
49647 + ;;
49648 + esac
49649 + if test "$need_version" = no; then
49650 + versuffix=
49651 + else
49652 + versuffix=".0.0"
49653 + fi
49654 + fi
49655 +
49656 + # Remove version info from name if versioning should be avoided
49657 + if test "$avoid_version" = yes && test "$need_version" = no; then
49658 + major=
49659 + versuffix=
49660 + verstring=""
49661 + fi
49662 +
49663 + # Check to see if the archive will have undefined symbols.
49664 + if test "$allow_undefined" = yes; then
49665 + if test "$allow_undefined_flag" = unsupported; then
49666 + func_warning "undefined symbols not allowed in $host shared libraries"
49667 + build_libtool_libs=no
49668 + build_old_libs=yes
49669 + fi
49670 + else
49671 + # Don't allow undefined symbols.
49672 + allow_undefined_flag="$no_undefined_flag"
49673 + fi
49674 +
49675 + fi
49676 +
49677 + func_generate_dlsyms "$libname" "$libname" "yes"
49678 + libobjs="$libobjs $symfileobj"
49679 + test "X$libobjs" = "X " && libobjs=
49680 +
49681 + if test "$mode" != relink; then
49682 + # Remove our outputs, but don't remove object files since they
49683 + # may have been created when compiling PIC objects.
49684 + removelist=
49685 + tempremovelist=`$ECHO "$output_objdir/*"`
49686 + for p in $tempremovelist; do
49687 + case $p in
49688 + *.$objext)
49689 + ;;
49690 + $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*)
49691 + if test "X$precious_files_regex" != "X"; then
49692 + if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1
49693 + then
49694 + continue
49695 + fi
49696 + fi
49697 + removelist="$removelist $p"
49698 + ;;
49699 + *) ;;
49700 + esac
49701 + done
49702 + test -n "$removelist" && \
49703 + func_show_eval "${RM}r \$removelist"
49704 + fi
49705 +
49706 + # Now set the variables for building old libraries.
49707 + if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then
49708 + oldlibs="$oldlibs $output_objdir/$libname.$libext"
49709 +
49710 + # Transform .lo files to .o files.
49711 + oldobjs="$objs "`$ECHO "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP`
49712 + fi
49713 +
49714 + # Eliminate all temporary directories.
49715 + #for path in $notinst_path; do
49716 + # lib_search_path=`$ECHO "X$lib_search_path " | $Xsed -e "s% $path % %g"`
49717 + # deplibs=`$ECHO "X$deplibs " | $Xsed -e "s% -L$path % %g"`
49718 + # dependency_libs=`$ECHO "X$dependency_libs " | $Xsed -e "s% -L$path % %g"`
49719 + #done
49720 +
49721 + if test -n "$xrpath"; then
49722 + # If the user specified any rpath flags, then add them.
49723 + temp_xrpath=
49724 + for libdir in $xrpath; do
49725 + temp_xrpath="$temp_xrpath -R$libdir"
49726 + case "$finalize_rpath " in
49727 + *" $libdir "*) ;;
49728 + *) finalize_rpath="$finalize_rpath $libdir" ;;
49729 + esac
49730 + done
49731 + if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then
49732 + dependency_libs="$temp_xrpath $dependency_libs"
49733 + fi
49734 + fi
49735 +
49736 + # Make sure dlfiles contains only unique files that won't be dlpreopened
49737 + old_dlfiles="$dlfiles"
49738 + dlfiles=
49739 + for lib in $old_dlfiles; do
49740 + case " $dlprefiles $dlfiles " in
49741 + *" $lib "*) ;;
49742 + *) dlfiles="$dlfiles $lib" ;;
49743 + esac
49744 + done
49745 +
49746 + # Make sure dlprefiles contains only unique files
49747 + old_dlprefiles="$dlprefiles"
49748 + dlprefiles=
49749 + for lib in $old_dlprefiles; do
49750 + case "$dlprefiles " in
49751 + *" $lib "*) ;;
49752 + *) dlprefiles="$dlprefiles $lib" ;;
49753 + esac
49754 + done
49755 +
49756 + if test "$build_libtool_libs" = yes; then
49757 + if test -n "$rpath"; then
49758 + case $host in
49759 + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*)
49760 + # these systems don't actually have a c library (as such)!
49761 + ;;
49762 + *-*-rhapsody* | *-*-darwin1.[012])
49763 + # Rhapsody C library is in the System framework
49764 + deplibs="$deplibs System.ltframework"
49765 + ;;
49766 + *-*-netbsd*)
49767 + # Don't link with libc until the a.out ld.so is fixed.
49768 + ;;
49769 + *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
49770 + # Do not include libc due to us having libc/libc_r.
49771 + ;;
49772 + *-*-sco3.2v5* | *-*-sco5v6*)
49773 + # Causes problems with __ctype
49774 + ;;
49775 + *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*)
49776 + # Compiler inserts libc in the correct place for threads to work
49777 + ;;
49778 + *)
49779 + # Add libc to deplibs on all other systems if necessary.
49780 + if test "$build_libtool_need_lc" = "yes"; then
49781 + deplibs="$deplibs -lc"
49782 + fi
49783 + ;;
49784 + esac
49785 + fi
49786 +
49787 + # Transform deplibs into only deplibs that can be linked in shared.
49788 + name_save=$name
49789 + libname_save=$libname
49790 + release_save=$release
49791 + versuffix_save=$versuffix
49792 + major_save=$major
49793 + # I'm not sure if I'm treating the release correctly. I think
49794 + # release should show up in the -l (ie -lgmp5) so we don't want to
49795 + # add it in twice. Is that correct?
49796 + release=""
49797 + versuffix=""
49798 + major=""
49799 + newdeplibs=
49800 + droppeddeps=no
49801 + case $deplibs_check_method in
49802 + pass_all)
49803 + # Don't check for shared/static. Everything works.
49804 + # This might be a little naive. We might want to check
49805 + # whether the library exists or not. But this is on
49806 + # osf3 & osf4 and I'm not really sure... Just
49807 + # implementing what was already the behavior.
49808 + newdeplibs=$deplibs
49809 + ;;
49810 + test_compile)
49811 + # This code stresses the "libraries are programs" paradigm to its
49812 + # limits. Maybe even breaks it. We compile a program, linking it
49813 + # against the deplibs as a proxy for the library. Then we can check
49814 + # whether they linked in statically or dynamically with ldd.
49815 + $opt_dry_run || $RM conftest.c
49816 + cat > conftest.c <<EOF
49817 + int main() { return 0; }
49818 +EOF
49819 + $opt_dry_run || $RM conftest
49820 + if $LTCC $LTCFLAGS -o conftest conftest.c $deplibs; then
49821 + ldd_output=`ldd conftest`
49822 + for i in $deplibs; do
49823 + name=`expr $i : '-l\(.*\)'`
49824 + # If $name is empty we are operating on a -L argument.
49825 + if test "$name" != "" && test "$name" != "0"; then
49826 + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
49827 + case " $predeps $postdeps " in
49828 + *" $i "*)
49829 + newdeplibs="$newdeplibs $i"
49830 + i=""
49831 + ;;
49832 + esac
49833 + fi
49834 + if test -n "$i" ; then
49835 + libname=`eval "\\$ECHO \"$libname_spec\""`
49836 + deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
49837 + set dummy $deplib_matches; shift
49838 + deplib_match=$1
49839 + if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
49840 + newdeplibs="$newdeplibs $i"
49841 + else
49842 + droppeddeps=yes
49843 + $ECHO
49844 + $ECHO "*** Warning: dynamic linker does not accept needed library $i."
49845 + $ECHO "*** I have the capability to make that library automatically link in when"
49846 + $ECHO "*** you link to this library. But I can only do this if you have a"
49847 + $ECHO "*** shared version of the library, which I believe you do not have"
49848 + $ECHO "*** because a test_compile did reveal that the linker did not use it for"
49849 + $ECHO "*** its dynamic dependency list that programs get resolved with at runtime."
49850 + fi
49851 + fi
49852 + else
49853 + newdeplibs="$newdeplibs $i"
49854 + fi
49855 + done
49856 + else
49857 + # Error occurred in the first compile. Let's try to salvage
49858 + # the situation: Compile a separate program for each library.
49859 + for i in $deplibs; do
49860 + name=`expr $i : '-l\(.*\)'`
49861 + # If $name is empty we are operating on a -L argument.
49862 + if test "$name" != "" && test "$name" != "0"; then
49863 + $opt_dry_run || $RM conftest
49864 + if $LTCC $LTCFLAGS -o conftest conftest.c $i; then
49865 + ldd_output=`ldd conftest`
49866 + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
49867 + case " $predeps $postdeps " in
49868 + *" $i "*)
49869 + newdeplibs="$newdeplibs $i"
49870 + i=""
49871 + ;;
49872 + esac
49873 + fi
49874 + if test -n "$i" ; then
49875 + libname=`eval "\\$ECHO \"$libname_spec\""`
49876 + deplib_matches=`eval "\\$ECHO \"$library_names_spec\""`
49877 + set dummy $deplib_matches; shift
49878 + deplib_match=$1
49879 + if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0 ; then
49880 + newdeplibs="$newdeplibs $i"
49881 + else
49882 + droppeddeps=yes
49883 + $ECHO
49884 + $ECHO "*** Warning: dynamic linker does not accept needed library $i."
49885 + $ECHO "*** I have the capability to make that library automatically link in when"
49886 + $ECHO "*** you link to this library. But I can only do this if you have a"
49887 + $ECHO "*** shared version of the library, which you do not appear to have"
49888 + $ECHO "*** because a test_compile did reveal that the linker did not use this one"
49889 + $ECHO "*** as a dynamic dependency that programs can get resolved with at runtime."
49890 + fi
49891 + fi
49892 + else
49893 + droppeddeps=yes
49894 + $ECHO
49895 + $ECHO "*** Warning! Library $i is needed by this library but I was not able to"
49896 + $ECHO "*** make it link in! You will probably need to install it or some"
49897 + $ECHO "*** library that it depends on before this library will be fully"
49898 + $ECHO "*** functional. Installing it before continuing would be even better."
49899 + fi
49900 + else
49901 + newdeplibs="$newdeplibs $i"
49902 + fi
49903 + done
49904 + fi
49905 + ;;
49906 + file_magic*)
49907 + set dummy $deplibs_check_method; shift
49908 + file_magic_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
49909 + for a_deplib in $deplibs; do
49910 + name=`expr $a_deplib : '-l\(.*\)'`
49911 + # If $name is empty we are operating on a -L argument.
49912 + if test "$name" != "" && test "$name" != "0"; then
49913 + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
49914 + case " $predeps $postdeps " in
49915 + *" $a_deplib "*)
49916 + newdeplibs="$newdeplibs $a_deplib"
49917 + a_deplib=""
49918 + ;;
49919 + esac
49920 + fi
49921 + if test -n "$a_deplib" ; then
49922 + libname=`eval "\\$ECHO \"$libname_spec\""`
49923 + for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
49924 + potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
49925 + for potent_lib in $potential_libs; do
49926 + # Follow soft links.
49927 + if ls -lLd "$potent_lib" 2>/dev/null |
49928 + $GREP " -> " >/dev/null; then
49929 + continue
49930 + fi
49931 + # The statement above tries to avoid entering an
49932 + # endless loop below, in case of cyclic links.
49933 + # We might still enter an endless loop, since a link
49934 + # loop can be closed while we follow links,
49935 + # but so what?
49936 + potlib="$potent_lib"
49937 + while test -h "$potlib" 2>/dev/null; do
49938 + potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'`
49939 + case $potliblink in
49940 + [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";;
49941 + *) potlib=`$ECHO "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";;
49942 + esac
49943 + done
49944 + if eval $file_magic_cmd \"\$potlib\" 2>/dev/null |
49945 + $SED -e 10q |
49946 + $EGREP "$file_magic_regex" > /dev/null; then
49947 + newdeplibs="$newdeplibs $a_deplib"
49948 + a_deplib=""
49949 + break 2
49950 + fi
49951 + done
49952 + done
49953 + fi
49954 + if test -n "$a_deplib" ; then
49955 + droppeddeps=yes
49956 + $ECHO
49957 + $ECHO "*** Warning: linker path does not have real file for library $a_deplib."
49958 + $ECHO "*** I have the capability to make that library automatically link in when"
49959 + $ECHO "*** you link to this library. But I can only do this if you have a"
49960 + $ECHO "*** shared version of the library, which you do not appear to have"
49961 + $ECHO "*** because I did check the linker path looking for a file starting"
49962 + if test -z "$potlib" ; then
49963 + $ECHO "*** with $libname but no candidates were found. (...for file magic test)"
49964 + else
49965 + $ECHO "*** with $libname and none of the candidates passed a file format test"
49966 + $ECHO "*** using a file magic. Last file checked: $potlib"
49967 + fi
49968 + fi
49969 + else
49970 + # Add a -L argument.
49971 + newdeplibs="$newdeplibs $a_deplib"
49972 + fi
49973 + done # Gone through all deplibs.
49974 + ;;
49975 + match_pattern*)
49976 + set dummy $deplibs_check_method; shift
49977 + match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"`
49978 + for a_deplib in $deplibs; do
49979 + name=`expr $a_deplib : '-l\(.*\)'`
49980 + # If $name is empty we are operating on a -L argument.
49981 + if test -n "$name" && test "$name" != "0"; then
49982 + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
49983 + case " $predeps $postdeps " in
49984 + *" $a_deplib "*)
49985 + newdeplibs="$newdeplibs $a_deplib"
49986 + a_deplib=""
49987 + ;;
49988 + esac
49989 + fi
49990 + if test -n "$a_deplib" ; then
49991 + libname=`eval "\\$ECHO \"$libname_spec\""`
49992 + for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do
49993 + potential_libs=`ls $i/$libname[.-]* 2>/dev/null`
49994 + for potent_lib in $potential_libs; do
49995 + potlib="$potent_lib" # see symlink-check above in file_magic test
49996 + if eval "\$ECHO \"X$potent_lib\"" 2>/dev/null | $Xsed -e 10q | \
49997 + $EGREP "$match_pattern_regex" > /dev/null; then
49998 + newdeplibs="$newdeplibs $a_deplib"
49999 + a_deplib=""
50000 + break 2
50001 + fi
50002 + done
50003 + done
50004 + fi
50005 + if test -n "$a_deplib" ; then
50006 + droppeddeps=yes
50007 + $ECHO
50008 + $ECHO "*** Warning: linker path does not have real file for library $a_deplib."
50009 + $ECHO "*** I have the capability to make that library automatically link in when"
50010 + $ECHO "*** you link to this library. But I can only do this if you have a"
50011 + $ECHO "*** shared version of the library, which you do not appear to have"
50012 + $ECHO "*** because I did check the linker path looking for a file starting"
50013 + if test -z "$potlib" ; then
50014 + $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)"
50015 + else
50016 + $ECHO "*** with $libname and none of the candidates passed a file format test"
50017 + $ECHO "*** using a regex pattern. Last file checked: $potlib"
50018 + fi
50019 + fi
50020 + else
50021 + # Add a -L argument.
50022 + newdeplibs="$newdeplibs $a_deplib"
50023 + fi
50024 + done # Gone through all deplibs.
50025 + ;;
50026 + none | unknown | *)
50027 + newdeplibs=""
50028 + tmp_deplibs=`$ECHO "X $deplibs" | $Xsed \
50029 + -e 's/ -lc$//' -e 's/ -[LR][^ ]*//g'`
50030 + if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
50031 + for i in $predeps $postdeps ; do
50032 + # can't use Xsed below, because $i might contain '/'
50033 + tmp_deplibs=`$ECHO "X $tmp_deplibs" | $Xsed -e "s,$i,,"`
50034 + done
50035 + fi
50036 + if $ECHO "X $tmp_deplibs" | $Xsed -e 's/[ ]//g' |
50037 + $GREP . >/dev/null; then
50038 + $ECHO
50039 + if test "X$deplibs_check_method" = "Xnone"; then
50040 + $ECHO "*** Warning: inter-library dependencies are not supported in this platform."
50041 + else
50042 + $ECHO "*** Warning: inter-library dependencies are not known to be supported."
50043 + fi
50044 + $ECHO "*** All declared inter-library dependencies are being dropped."
50045 + droppeddeps=yes
50046 + fi
50047 + ;;
50048 + esac
50049 + versuffix=$versuffix_save
50050 + major=$major_save
50051 + release=$release_save
50052 + libname=$libname_save
50053 + name=$name_save
50054 +
50055 + case $host in
50056 + *-*-rhapsody* | *-*-darwin1.[012])
50057 + # On Rhapsody replace the C library with the System framework
50058 + newdeplibs=`$ECHO "X $newdeplibs" | $Xsed -e 's/ -lc / System.ltframework /'`
50059 + ;;
50060 + esac
50061 +
50062 + if test "$droppeddeps" = yes; then
50063 + if test "$module" = yes; then
50064 + $ECHO
50065 + $ECHO "*** Warning: libtool could not satisfy all declared inter-library"
50066 + $ECHO "*** dependencies of module $libname. Therefore, libtool will create"
50067 + $ECHO "*** a static module, that should work as long as the dlopening"
50068 + $ECHO "*** application is linked with the -dlopen flag."
50069 + if test -z "$global_symbol_pipe"; then
50070 + $ECHO
50071 + $ECHO "*** However, this would only work if libtool was able to extract symbol"
50072 + $ECHO "*** lists from a program, using \`nm' or equivalent, but libtool could"
50073 + $ECHO "*** not find such a program. So, this module is probably useless."
50074 + $ECHO "*** \`nm' from GNU binutils and a full rebuild may help."
50075 + fi
50076 + if test "$build_old_libs" = no; then
50077 + oldlibs="$output_objdir/$libname.$libext"
50078 + build_libtool_libs=module
50079 + build_old_libs=yes
50080 + else
50081 + build_libtool_libs=no
50082 + fi
50083 + else
50084 + $ECHO "*** The inter-library dependencies that have been dropped here will be"
50085 + $ECHO "*** automatically added whenever a program is linked with this library"
50086 + $ECHO "*** or is declared to -dlopen it."
50087 +
50088 + if test "$allow_undefined" = no; then
50089 + $ECHO
50090 + $ECHO "*** Since this library must not contain undefined symbols,"
50091 + $ECHO "*** because either the platform does not support them or"
50092 + $ECHO "*** it was explicitly requested with -no-undefined,"
50093 + $ECHO "*** libtool will only create a static version of it."
50094 + if test "$build_old_libs" = no; then
50095 + oldlibs="$output_objdir/$libname.$libext"
50096 + build_libtool_libs=module
50097 + build_old_libs=yes
50098 + else
50099 + build_libtool_libs=no
50100 + fi
50101 + fi
50102 + fi
50103 + fi
50104 + # Done checking deplibs!
50105 + deplibs=$newdeplibs
50106 + fi
50107 + # Time to change all our "foo.ltframework" stuff back to "-framework foo"
50108 + case $host in
50109 + *-*-darwin*)
50110 + newdeplibs=`$ECHO "X $newdeplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
50111 + new_inherited_linker_flags=`$ECHO "X $new_inherited_linker_flags" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
50112 + deplibs=`$ECHO "X $deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
50113 + ;;
50114 + esac
50115 +
50116 + # move library search paths that coincide with paths to not yet
50117 + # installed libraries to the beginning of the library search list
50118 + new_libs=
50119 + for path in $notinst_path; do
50120 + case " $new_libs " in
50121 + *" -L$path/$objdir "*) ;;
50122 + *)
50123 + case " $deplibs " in
50124 + *" -L$path/$objdir "*)
50125 + new_libs="$new_libs -L$path/$objdir" ;;
50126 + esac
50127 + ;;
50128 + esac
50129 + done
50130 + for deplib in $deplibs; do
50131 + case $deplib in
50132 + -L*)
50133 + case " $new_libs " in
50134 + *" $deplib "*) ;;
50135 + *) new_libs="$new_libs $deplib" ;;
50136 + esac
50137 + ;;
50138 + *) new_libs="$new_libs $deplib" ;;
50139 + esac
50140 + done
50141 + deplibs="$new_libs"
50142 +
50143 + # All the library-specific variables (install_libdir is set above).
50144 + library_names=
50145 + old_library=
50146 + dlname=
50147 +
50148 + # Test again, we may have decided not to build it any more
50149 + if test "$build_libtool_libs" = yes; then
50150 + if test "$hardcode_into_libs" = yes; then
50151 + # Hardcode the library paths
50152 + hardcode_libdirs=
50153 + dep_rpath=
50154 + rpath="$finalize_rpath"
50155 + test "$mode" != relink && rpath="$compile_rpath$rpath"
50156 + for libdir in $rpath; do
50157 + if test -n "$hardcode_libdir_flag_spec"; then
50158 + if test -n "$hardcode_libdir_separator"; then
50159 + if test -z "$hardcode_libdirs"; then
50160 + hardcode_libdirs="$libdir"
50161 + else
50162 + # Just accumulate the unique libdirs.
50163 + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
50164 + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
50165 + ;;
50166 + *)
50167 + hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir"
50168 + ;;
50169 + esac
50170 + fi
50171 + else
50172 + eval flag=\"$hardcode_libdir_flag_spec\"
50173 + dep_rpath="$dep_rpath $flag"
50174 + fi
50175 + elif test -n "$runpath_var"; then
50176 + case "$perm_rpath " in
50177 + *" $libdir "*) ;;
50178 + *) perm_rpath="$perm_rpath $libdir" ;;
50179 + esac
50180 + fi
50181 + done
50182 + # Substitute the hardcoded libdirs into the rpath.
50183 + if test -n "$hardcode_libdir_separator" &&
50184 + test -n "$hardcode_libdirs"; then
50185 + libdir="$hardcode_libdirs"
50186 + if test -n "$hardcode_libdir_flag_spec_ld"; then
50187 + eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\"
50188 + else
50189 + eval dep_rpath=\"$hardcode_libdir_flag_spec\"
50190 + fi
50191 + fi
50192 + if test -n "$runpath_var" && test -n "$perm_rpath"; then
50193 + # We should set the runpath_var.
50194 + rpath=
50195 + for dir in $perm_rpath; do
50196 + rpath="$rpath$dir:"
50197 + done
50198 + eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var"
50199 + fi
50200 + test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs"
50201 + fi
50202 +
50203 + shlibpath="$finalize_shlibpath"
50204 + test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath"
50205 + if test -n "$shlibpath"; then
50206 + eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var"
50207 + fi
50208 +
50209 + # Get the real and link names of the library.
50210 + eval shared_ext=\"$shrext_cmds\"
50211 + eval library_names=\"$library_names_spec\"
50212 + set dummy $library_names
50213 + shift
50214 + realname="$1"
50215 + shift
50216 +
50217 + if test -n "$soname_spec"; then
50218 + eval soname=\"$soname_spec\"
50219 + else
50220 + soname="$realname"
50221 + fi
50222 + if test -z "$dlname"; then
50223 + dlname=$soname
50224 + fi
50225 +
50226 + lib="$output_objdir/$realname"
50227 + linknames=
50228 + for link
50229 + do
50230 + linknames="$linknames $link"
50231 + done
50232 +
50233 + # Use standard objects if they are pic
50234 + test -z "$pic_flag" && libobjs=`$ECHO "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
50235 + test "X$libobjs" = "X " && libobjs=
50236 +
50237 + delfiles=
50238 + if test -n "$export_symbols" && test -n "$include_expsyms"; then
50239 + $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp"
50240 + export_symbols="$output_objdir/$libname.uexp"
50241 + delfiles="$delfiles $export_symbols"
50242 + fi
50243 +
50244 + orig_export_symbols=
50245 + case $host_os in
50246 + cygwin* | mingw*)
50247 + if test -n "$export_symbols" && test -z "$export_symbols_regex"; then
50248 + # exporting using user supplied symfile
50249 + if test "x`$SED 1q $export_symbols`" != xEXPORTS; then
50250 + # and it's NOT already a .def file. Must figure out
50251 + # which of the given symbols are data symbols and tag
50252 + # them as such. So, trigger use of export_symbols_cmds.
50253 + # export_symbols gets reassigned inside the "prepare
50254 + # the list of exported symbols" if statement, so the
50255 + # include_expsyms logic still works.
50256 + orig_export_symbols="$export_symbols"
50257 + export_symbols=
50258 + always_export_symbols=yes
50259 + fi
50260 + fi
50261 + ;;
50262 + esac
50263 +
50264 + # Prepare the list of exported symbols
50265 + if test -z "$export_symbols"; then
50266 + if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then
50267 + func_echo "generating symbol list for \`$libname.la'"
50268 + export_symbols="$output_objdir/$libname.exp"
50269 + $opt_dry_run || $RM $export_symbols
50270 + cmds=$export_symbols_cmds
50271 + save_ifs="$IFS"; IFS='~'
50272 + for cmd in $cmds; do
50273 + IFS="$save_ifs"
50274 + eval cmd=\"$cmd\"
50275 + if len=`expr "X$cmd" : ".*"` &&
50276 + test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then
50277 + func_show_eval "$cmd" 'exit $?'
50278 + skipped_export=false
50279 + else
50280 + # The command line is too long to execute in one step.
50281 + func_echo "using reloadable object file for export list..."
50282 + skipped_export=:
50283 + # Break out early, otherwise skipped_export may be
50284 + # set to false by a later but shorter cmd.
50285 + break
50286 + fi
50287 + done
50288 + IFS="$save_ifs"
50289 + if test -n "$export_symbols_regex" && test "X$skipped_export" != "X:"; then
50290 + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"'
50291 + func_show_eval '$MV "${export_symbols}T" "$export_symbols"'
50292 + fi
50293 + fi
50294 + fi
50295 +
50296 + if test -n "$export_symbols" && test -n "$include_expsyms"; then
50297 + tmp_export_symbols="$export_symbols"
50298 + test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
50299 + $opt_dry_run || eval '$ECHO "X$include_expsyms" | $Xsed | $SP2NL >> "$tmp_export_symbols"'
50300 + fi
50301 +
50302 + if test "X$skipped_export" != "X:" && test -n "$orig_export_symbols"; then
50303 + # The given exports_symbols file has to be filtered, so filter it.
50304 + func_echo "filter symbol list for \`$libname.la' to tag DATA exports"
50305 + # FIXME: $output_objdir/$libname.filter potentially contains lots of
50306 + # 's' commands which not all seds can handle. GNU sed should be fine
50307 + # though. Also, the filter scales superlinearly with the number of
50308 + # global variables. join(1) would be nice here, but unfortunately
50309 + # isn't a blessed tool.
50310 + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
50311 + delfiles="$delfiles $export_symbols $output_objdir/$libname.filter"
50312 + export_symbols=$output_objdir/$libname.def
50313 + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
50314 + fi
50315 +
50316 + tmp_deplibs=
50317 + for test_deplib in $deplibs; do
50318 + case " $convenience " in
50319 + *" $test_deplib "*) ;;
50320 + *)
50321 + tmp_deplibs="$tmp_deplibs $test_deplib"
50322 + ;;
50323 + esac
50324 + done
50325 + deplibs="$tmp_deplibs"
50326 +
50327 + if test -n "$convenience"; then
50328 + if test -n "$whole_archive_flag_spec" &&
50329 + test "$compiler_needs_object" = yes &&
50330 + test -z "$libobjs"; then
50331 + # extract the archives, so we have objects to list.
50332 + # TODO: could optimize this to just extract one archive.
50333 + whole_archive_flag_spec=
50334 + fi
50335 + if test -n "$whole_archive_flag_spec"; then
50336 + save_libobjs=$libobjs
50337 + eval libobjs=\"\$libobjs $whole_archive_flag_spec\"
50338 + test "X$libobjs" = "X " && libobjs=
50339 + else
50340 + gentop="$output_objdir/${outputname}x"
50341 + generated="$generated $gentop"
50342 +
50343 + func_extract_archives $gentop $convenience
50344 + libobjs="$libobjs $func_extract_archives_result"
50345 + test "X$libobjs" = "X " && libobjs=
50346 + fi
50347 + fi
50348 +
50349 + if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then
50350 + eval flag=\"$thread_safe_flag_spec\"
50351 + linker_flags="$linker_flags $flag"
50352 + fi
50353 +
50354 + # Make a backup of the uninstalled library when relinking
50355 + if test "$mode" = relink; then
50356 + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $?
50357 + fi
50358 +
50359 + # Do each of the archive commands.
50360 + if test "$module" = yes && test -n "$module_cmds" ; then
50361 + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then
50362 + eval test_cmds=\"$module_expsym_cmds\"
50363 + cmds=$module_expsym_cmds
50364 + else
50365 + eval test_cmds=\"$module_cmds\"
50366 + cmds=$module_cmds
50367 + fi
50368 + else
50369 + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then
50370 + eval test_cmds=\"$archive_expsym_cmds\"
50371 + cmds=$archive_expsym_cmds
50372 + else
50373 + eval test_cmds=\"$archive_cmds\"
50374 + cmds=$archive_cmds
50375 + fi
50376 + fi
50377 +
50378 + if test "X$skipped_export" != "X:" &&
50379 + len=`expr "X$test_cmds" : ".*" 2>/dev/null` &&
50380 + test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then
50381 + :
50382 + else
50383 + # The command line is too long to link in one step, link piecewise
50384 + # or, if using GNU ld and skipped_export is not :, use a linker
50385 + # script.
50386 +
50387 + # Save the value of $output and $libobjs because we want to
50388 + # use them later. If we have whole_archive_flag_spec, we
50389 + # want to use save_libobjs as it was before
50390 + # whole_archive_flag_spec was expanded, because we can't
50391 + # assume the linker understands whole_archive_flag_spec.
50392 + # This may have to be revisited, in case too many
50393 + # convenience libraries get linked in and end up exceeding
50394 + # the spec.
50395 + if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then
50396 + save_libobjs=$libobjs
50397 + fi
50398 + save_output=$output
50399 + output_la=`$ECHO "X$output" | $Xsed -e "$basename"`
50400 +
50401 + # Clear the reloadable object creation command queue and
50402 + # initialize k to one.
50403 + test_cmds=
50404 + concat_cmds=
50405 + objlist=
50406 + last_robj=
50407 + k=1
50408 +
50409 + if test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "$with_gnu_ld" = yes; then
50410 + output=${output_objdir}/${output_la}.lnkscript
50411 + func_echo "creating GNU ld script: $output"
50412 + $ECHO 'INPUT (' > $output
50413 + for obj in $save_libobjs
50414 + do
50415 + $ECHO "$obj" >> $output
50416 + done
50417 + $ECHO ')' >> $output
50418 + delfiles="$delfiles $output"
50419 + elif test -n "$save_libobjs" && test "X$skipped_export" != "X:" && test "X$file_list_spec" != X; then
50420 + output=${output_objdir}/${output_la}.lnk
50421 + func_echo "creating linker input file list: $output"
50422 + : > $output
50423 + set x $save_libobjs
50424 + shift
50425 + firstobj=
50426 + if test "$compiler_needs_object" = yes; then
50427 + firstobj="$1 "
50428 + shift
50429 + fi
50430 + for obj
50431 + do
50432 + $ECHO "$obj" >> $output
50433 + done
50434 + delfiles="$delfiles $output"
50435 + output=$firstobj\"$file_list_spec$output\"
50436 + else
50437 + if test -n "$save_libobjs"; then
50438 + func_echo "creating reloadable object files..."
50439 + output=$output_objdir/$output_la-${k}.$objext
50440 + # Loop over the list of objects to be linked.
50441 + for obj in $save_libobjs
50442 + do
50443 + eval test_cmds=\"$reload_cmds $objlist $last_robj\"
50444 + if test "X$objlist" = X ||
50445 + { len=`expr "X$test_cmds" : ".*" 2>/dev/null` &&
50446 + test "$len" -le "$max_cmd_len"; }; then
50447 + objlist="$objlist $obj"
50448 + else
50449 + # The command $test_cmds is almost too long, add a
50450 + # command to the queue.
50451 + if test "$k" -eq 1 ; then
50452 + # The first file doesn't have a previous command to add.
50453 + eval concat_cmds=\"$reload_cmds $objlist $last_robj\"
50454 + else
50455 + # All subsequent reloadable object files will link in
50456 + # the last one created.
50457 + eval concat_cmds=\"\$concat_cmds~$reload_cmds $objlist $last_robj\"
50458 + fi
50459 + last_robj=$output_objdir/$output_la-${k}.$objext
50460 + k=`expr $k + 1`
50461 + output=$output_objdir/$output_la-${k}.$objext
50462 + objlist=$obj
50463 + len=1
50464 + fi
50465 + done
50466 + # Handle the remaining objects by creating one last
50467 + # reloadable object file. All subsequent reloadable object
50468 + # files will link in the last one created.
50469 + test -z "$concat_cmds" || concat_cmds=$concat_cmds~
50470 + eval concat_cmds=\"\${concat_cmds}$reload_cmds $objlist $last_robj\"
50471 +
50472 + # Set up a command to remove the reloadable object files
50473 + # after they are used.
50474 + i=0
50475 + while test "$i" -lt "$k"
50476 + do
50477 + i=`expr $i + 1`
50478 + delfiles="$delfiles $output_objdir/$output_la-${i}.$objext"
50479 + done
50480 + else
50481 + output=
50482 + fi
50483 +
50484 + if ${skipped_export-false}; then
50485 + func_echo "generating symbol list for \`$libname.la'"
50486 + export_symbols="$output_objdir/$libname.exp"
50487 + $opt_dry_run || $RM $export_symbols
50488 + libobjs=$output
50489 + # Append the command to create the export file.
50490 + test -z "$concat_cmds" || concat_cmds=$concat_cmds~
50491 + eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\"
50492 + fi
50493 +
50494 + test -n "$save_libobjs" &&
50495 + func_echo "creating a temporary reloadable object file: $output"
50496 +
50497 + # Loop through the commands generated above and execute them.
50498 + save_ifs="$IFS"; IFS='~'
50499 + for cmd in $concat_cmds; do
50500 + IFS="$save_ifs"
50501 + $opt_silent || {
50502 + func_quote_for_expand "$cmd"
50503 + eval "func_echo $func_quote_for_expand_result"
50504 + }
50505 + $opt_dry_run || eval "$cmd" || {
50506 + lt_exit=$?
50507 +
50508 + # Restore the uninstalled library and exit
50509 + if test "$mode" = relink; then
50510 + ( cd "$output_objdir" && \
50511 + $RM "${realname}T" && \
50512 + $MV "${realname}U" "$realname" )
50513 + fi
50514 +
50515 + exit $lt_exit
50516 + }
50517 + done
50518 + IFS="$save_ifs"
50519 +
50520 + if test -n "$export_symbols_regex" && ${skipped_export-false}; then
50521 + func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"'
50522 + func_show_eval '$MV "${export_symbols}T" "$export_symbols"'
50523 + fi
50524 + fi
50525 +
50526 + if ${skipped_export-false}; then
50527 + if test -n "$export_symbols" && test -n "$include_expsyms"; then
50528 + tmp_export_symbols="$export_symbols"
50529 + test -n "$orig_export_symbols" && tmp_export_symbols="$orig_export_symbols"
50530 + $opt_dry_run || eval '$ECHO "X$include_expsyms" | $Xsed | $SP2NL >> "$tmp_export_symbols"'
50531 + fi
50532 +
50533 + if test -n "$orig_export_symbols"; then
50534 + # The given exports_symbols file has to be filtered, so filter it.
50535 + func_echo "filter symbol list for \`$libname.la' to tag DATA exports"
50536 + # FIXME: $output_objdir/$libname.filter potentially contains lots of
50537 + # 's' commands which not all seds can handle. GNU sed should be fine
50538 + # though. Also, the filter scales superlinearly with the number of
50539 + # global variables. join(1) would be nice here, but unfortunately
50540 + # isn't a blessed tool.
50541 + $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter
50542 + delfiles="$delfiles $export_symbols $output_objdir/$libname.filter"
50543 + export_symbols=$output_objdir/$libname.def
50544 + $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols
50545 + fi
50546 + fi
50547 +
50548 + libobjs=$output
50549 + # Restore the value of output.
50550 + output=$save_output
50551 +
50552 + if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then
50553 + eval libobjs=\"\$libobjs $whole_archive_flag_spec\"
50554 + test "X$libobjs" = "X " && libobjs=
50555 + fi
50556 + # Expand the library linking commands again to reset the
50557 + # value of $libobjs for piecewise linking.
50558 +
50559 + # Do each of the archive commands.
50560 + if test "$module" = yes && test -n "$module_cmds" ; then
50561 + if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then
50562 + cmds=$module_expsym_cmds
50563 + else
50564 + cmds=$module_cmds
50565 + fi
50566 + else
50567 + if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then
50568 + cmds=$archive_expsym_cmds
50569 + else
50570 + cmds=$archive_cmds
50571 + fi
50572 + fi
50573 + fi
50574 +
50575 + if test -n "$delfiles"; then
50576 + # Append the command to remove temporary files to $cmds.
50577 + eval cmds=\"\$cmds~\$RM $delfiles\"
50578 + fi
50579 +
50580 + # Add any objects from preloaded convenience libraries
50581 + if test -n "$dlprefiles"; then
50582 + gentop="$output_objdir/${outputname}x"
50583 + generated="$generated $gentop"
50584 +
50585 + func_extract_archives $gentop $dlprefiles
50586 + libobjs="$libobjs $func_extract_archives_result"
50587 + test "X$libobjs" = "X " && libobjs=
50588 + fi
50589 +
50590 + save_ifs="$IFS"; IFS='~'
50591 + for cmd in $cmds; do
50592 + IFS="$save_ifs"
50593 + eval cmd=\"$cmd\"
50594 + $opt_silent || {
50595 + func_quote_for_expand "$cmd"
50596 + eval "func_echo $func_quote_for_expand_result"
50597 + }
50598 + $opt_dry_run || eval "$cmd" || {
50599 + lt_exit=$?
50600 +
50601 + # Restore the uninstalled library and exit
50602 + if test "$mode" = relink; then
50603 + ( cd "$output_objdir" && \
50604 + $RM "${realname}T" && \
50605 + $MV "${realname}U" "$realname" )
50606 + fi
50607 +
50608 + exit $lt_exit
50609 + }
50610 + done
50611 + IFS="$save_ifs"
50612 +
50613 + # Restore the uninstalled library and exit
50614 + if test "$mode" = relink; then
50615 + $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $?
50616 +
50617 + if test -n "$convenience"; then
50618 + if test -z "$whole_archive_flag_spec"; then
50619 + func_show_eval '${RM}r "$gentop"'
50620 + fi
50621 + fi
50622 +
50623 + exit $EXIT_SUCCESS
50624 + fi
50625 +
50626 + # Create links to the real library.
50627 + for linkname in $linknames; do
50628 + if test "$realname" != "$linkname"; then
50629 + func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?'
50630 + fi
50631 + done
50632 +
50633 + # If -module or -export-dynamic was specified, set the dlname.
50634 + if test "$module" = yes || test "$export_dynamic" = yes; then
50635 + # On all known operating systems, these are identical.
50636 + dlname="$soname"
50637 + fi
50638 + fi
50639 + ;;
50640 +
50641 + obj)
50642 + if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
50643 + func_warning "\`-dlopen' is ignored for objects"
50644 + fi
50645 +
50646 + test -n "$deplibs" && \
50647 + func_warning "\`-l' and \`-L' are ignored for objects"
50648 +
50649 + test -n "$rpath" && \
50650 + func_warning "\`-rpath' is ignored for objects"
50651 +
50652 + test -n "$xrpath" && \
50653 + func_warning "\`-R' is ignored for objects"
50654 +
50655 + test -n "$vinfo" && \
50656 + func_warning "\`-version-info' is ignored for objects"
50657 +
50658 + test -n "$release" && \
50659 + func_warning "\`-release' is ignored for objects"
50660 +
50661 + case $output in
50662 + *.lo)
50663 + test -n "$objs$old_deplibs" && \
50664 + func_fatal_error "cannot build library object \`$output' from non-libtool objects"
50665 +
50666 + libobj=$output
50667 + func_lo2o "$libobj"
50668 + obj=$func_lo2o_result
50669 + ;;
50670 + *)
50671 + libobj=
50672 + obj="$output"
50673 + ;;
50674 + esac
50675 +
50676 + # Delete the old objects.
50677 + $opt_dry_run || $RM $obj $libobj
50678 +
50679 + # Objects from convenience libraries. This assumes
50680 + # single-version convenience libraries. Whenever we create
50681 + # different ones for PIC/non-PIC, this we'll have to duplicate
50682 + # the extraction.
50683 + reload_conv_objs=
50684 + gentop=
50685 + # reload_cmds runs $LD directly, so let us get rid of
50686 + # -Wl from whole_archive_flag_spec and hope we can get by with
50687 + # turning comma into space..
50688 + wl=
50689 +
50690 + if test -n "$convenience"; then
50691 + if test -n "$whole_archive_flag_spec"; then
50692 + eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\"
50693 + reload_conv_objs=$reload_objs\ `$ECHO "X$tmp_whole_archive_flags" | $Xsed -e 's|,| |g'`
50694 + else
50695 + gentop="$output_objdir/${obj}x"
50696 + generated="$generated $gentop"
50697 +
50698 + func_extract_archives $gentop $convenience
50699 + reload_conv_objs="$reload_objs $func_extract_archives_result"
50700 + fi
50701 + fi
50702 +
50703 + # Create the old-style object.
50704 + reload_objs="$objs$old_deplibs "`$ECHO "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}$'/d' -e '/\.lib$/d' -e "$lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test
50705 +
50706 + output="$obj"
50707 + func_execute_cmds "$reload_cmds" 'exit $?'
50708 +
50709 + # Exit if we aren't doing a library object file.
50710 + if test -z "$libobj"; then
50711 + if test -n "$gentop"; then
50712 + func_show_eval '${RM}r "$gentop"'
50713 + fi
50714 +
50715 + exit $EXIT_SUCCESS
50716 + fi
50717 +
50718 + if test "$build_libtool_libs" != yes; then
50719 + if test -n "$gentop"; then
50720 + func_show_eval '${RM}r "$gentop"'
50721 + fi
50722 +
50723 + # Create an invalid libtool object if no PIC, so that we don't
50724 + # accidentally link it into a program.
50725 + # $show "echo timestamp > $libobj"
50726 + # $opt_dry_run || eval "echo timestamp > $libobj" || exit $?
50727 + exit $EXIT_SUCCESS
50728 + fi
50729 +
50730 + if test -n "$pic_flag" || test "$pic_mode" != default; then
50731 + # Only do commands if we really have different PIC objects.
50732 + reload_objs="$libobjs $reload_conv_objs"
50733 + output="$libobj"
50734 + func_execute_cmds "$reload_cmds" 'exit $?'
50735 + fi
50736 +
50737 + if test -n "$gentop"; then
50738 + func_show_eval '${RM}r "$gentop"'
50739 + fi
50740 +
50741 + exit $EXIT_SUCCESS
50742 + ;;
50743 +
50744 + prog)
50745 + case $host in
50746 + *cygwin*) func_stripname '' '.exe' "$output"
50747 + output=$func_stripname_result.exe;;
50748 + esac
50749 + test -n "$vinfo" && \
50750 + func_warning "\`-version-info' is ignored for programs"
50751 +
50752 + test -n "$release" && \
50753 + func_warning "\`-release' is ignored for programs"
50754 +
50755 + test "$preload" = yes \
50756 + && test "$dlopen_support" = unknown \
50757 + && test "$dlopen_self" = unknown \
50758 + && test "$dlopen_self_static" = unknown && \
50759 + func_warning "\`LT_INIT([dlopen])' not used. Assuming no dlopen support."
50760 +
50761 + case $host in
50762 + *-*-rhapsody* | *-*-darwin1.[012])
50763 + # On Rhapsody replace the C library is the System framework
50764 + compile_deplibs=`$ECHO "X $compile_deplibs" | $Xsed -e 's/ -lc / System.ltframework /'`
50765 + finalize_deplibs=`$ECHO "X $finalize_deplibs" | $Xsed -e 's/ -lc / System.ltframework /'`
50766 + ;;
50767 + esac
50768 +
50769 + case $host in
50770 + *-*-darwin*)
50771 + # Don't allow lazy linking, it breaks C++ global constructors
50772 + # But is supposedly fixed on 10.4 or later (yay!).
50773 + if test "$tagname" = CXX ; then
50774 + case ${MACOSX_DEPLOYMENT_TARGET-10.0} in
50775 + 10.[0123])
50776 + compile_command="$compile_command ${wl}-bind_at_load"
50777 + finalize_command="$finalize_command ${wl}-bind_at_load"
50778 + ;;
50779 + esac
50780 + fi
50781 + # Time to change all our "foo.ltframework" stuff back to "-framework foo"
50782 + compile_deplibs=`$ECHO "X $compile_deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
50783 + finalize_deplibs=`$ECHO "X $finalize_deplibs" | $Xsed -e 's% \([^ $]*\).ltframework% -framework \1%g'`
50784 + ;;
50785 + esac
50786 +
50787 +
50788 + # move library search paths that coincide with paths to not yet
50789 + # installed libraries to the beginning of the library search list
50790 + new_libs=
50791 + for path in $notinst_path; do
50792 + case " $new_libs " in
50793 + *" -L$path/$objdir "*) ;;
50794 + *)
50795 + case " $compile_deplibs " in
50796 + *" -L$path/$objdir "*)
50797 + new_libs="$new_libs -L$path/$objdir" ;;
50798 + esac
50799 + ;;
50800 + esac
50801 + done
50802 + for deplib in $compile_deplibs; do
50803 + case $deplib in
50804 + -L*)
50805 + case " $new_libs " in
50806 + *" $deplib "*) ;;
50807 + *) new_libs="$new_libs $deplib" ;;
50808 + esac
50809 + ;;
50810 + *) new_libs="$new_libs $deplib" ;;
50811 + esac
50812 + done
50813 + compile_deplibs="$new_libs"
50814 +
50815 +
50816 + compile_command="$compile_command $compile_deplibs"
50817 + finalize_command="$finalize_command $finalize_deplibs"
50818 +
50819 + if test -n "$rpath$xrpath"; then
50820 + # If the user specified any rpath flags, then add them.
50821 + for libdir in $rpath $xrpath; do
50822 + # This is the magic to use -rpath.
50823 + case "$finalize_rpath " in
50824 + *" $libdir "*) ;;
50825 + *) finalize_rpath="$finalize_rpath $libdir" ;;
50826 + esac
50827 + done
50828 + fi
50829 +
50830 + # Now hardcode the library paths
50831 + rpath=
50832 + hardcode_libdirs=
50833 + for libdir in $compile_rpath $finalize_rpath; do
50834 + if test -n "$hardcode_libdir_flag_spec"; then
50835 + if test -n "$hardcode_libdir_separator"; then
50836 + if test -z "$hardcode_libdirs"; then
50837 + hardcode_libdirs="$libdir"
50838 + else
50839 + # Just accumulate the unique libdirs.
50840 + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
50841 + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
50842 + ;;
50843 + *)
50844 + hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir"
50845 + ;;
50846 + esac
50847 + fi
50848 + else
50849 + eval flag=\"$hardcode_libdir_flag_spec\"
50850 + rpath="$rpath $flag"
50851 + fi
50852 + elif test -n "$runpath_var"; then
50853 + case "$perm_rpath " in
50854 + *" $libdir "*) ;;
50855 + *) perm_rpath="$perm_rpath $libdir" ;;
50856 + esac
50857 + fi
50858 + case $host in
50859 + *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
50860 + testbindir=`${ECHO} "$libdir" | ${SED} -e 's*/lib$*/bin*'`
50861 + case :$dllsearchpath: in
50862 + *":$libdir:"*) ;;
50863 + *) dllsearchpath="$dllsearchpath:$libdir";;
50864 + esac
50865 + case :$dllsearchpath: in
50866 + *":$testbindir:"*) ;;
50867 + *) dllsearchpath="$dllsearchpath:$testbindir";;
50868 + esac
50869 + ;;
50870 + esac
50871 + done
50872 + # Substitute the hardcoded libdirs into the rpath.
50873 + if test -n "$hardcode_libdir_separator" &&
50874 + test -n "$hardcode_libdirs"; then
50875 + libdir="$hardcode_libdirs"
50876 + eval rpath=\" $hardcode_libdir_flag_spec\"
50877 + fi
50878 + compile_rpath="$rpath"
50879 +
50880 + rpath=
50881 + hardcode_libdirs=
50882 + for libdir in $finalize_rpath; do
50883 + if test -n "$hardcode_libdir_flag_spec"; then
50884 + if test -n "$hardcode_libdir_separator"; then
50885 + if test -z "$hardcode_libdirs"; then
50886 + hardcode_libdirs="$libdir"
50887 + else
50888 + # Just accumulate the unique libdirs.
50889 + case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in
50890 + *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*)
50891 + ;;
50892 + *)
50893 + hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir"
50894 + ;;
50895 + esac
50896 + fi
50897 + else
50898 + eval flag=\"$hardcode_libdir_flag_spec\"
50899 + rpath="$rpath $flag"
50900 + fi
50901 + elif test -n "$runpath_var"; then
50902 + case "$finalize_perm_rpath " in
50903 + *" $libdir "*) ;;
50904 + *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;;
50905 + esac
50906 + fi
50907 + done
50908 + # Substitute the hardcoded libdirs into the rpath.
50909 + if test -n "$hardcode_libdir_separator" &&
50910 + test -n "$hardcode_libdirs"; then
50911 + libdir="$hardcode_libdirs"
50912 + eval rpath=\" $hardcode_libdir_flag_spec\"
50913 + fi
50914 + finalize_rpath="$rpath"
50915 +
50916 + if test -n "$libobjs" && test "$build_old_libs" = yes; then
50917 + # Transform all the library objects into standard objects.
50918 + compile_command=`$ECHO "X$compile_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
50919 + finalize_command=`$ECHO "X$finalize_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP`
50920 + fi
50921 +
50922 + func_generate_dlsyms "$outputname" "@PROGRAM@" "no"
50923 +
50924 + # template prelinking step
50925 + if test -n "$prelink_cmds"; then
50926 + func_execute_cmds "$prelink_cmds" 'exit $?'
50927 + fi
50928 +
50929 + wrappers_required=yes
50930 + case $host in
50931 + *cygwin* | *mingw* )
50932 + if test "$build_libtool_libs" != yes; then
50933 + wrappers_required=no
50934 + fi
50935 + ;;
50936 + *)
50937 + if test "$need_relink" = no || test "$build_libtool_libs" != yes; then
50938 + wrappers_required=no
50939 + fi
50940 + ;;
50941 + esac
50942 + if test "$wrappers_required" = no; then
50943 + # Replace the output file specification.
50944 + compile_command=`$ECHO "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'`
50945 + link_command="$compile_command$compile_rpath"
50946 +
50947 + # We have no uninstalled library dependencies, so finalize right now.
50948 + exit_status=0
50949 + func_show_eval "$link_command" 'exit_status=$?'
50950 +
50951 + # Delete the generated files.
50952 + if test -f "$output_objdir/${outputname}S.${objext}"; then
50953 + func_show_eval '$RM "$output_objdir/${outputname}S.${objext}"'
50954 + fi
50955 +
50956 + exit $exit_status
50957 + fi
50958 +
50959 + if test -n "$compile_shlibpath$finalize_shlibpath"; then
50960 + compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command"
50961 + fi
50962 + if test -n "$finalize_shlibpath"; then
50963 + finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command"
50964 + fi
50965 +
50966 + compile_var=
50967 + finalize_var=
50968 + if test -n "$runpath_var"; then
50969 + if test -n "$perm_rpath"; then
50970 + # We should set the runpath_var.
50971 + rpath=
50972 + for dir in $perm_rpath; do
50973 + rpath="$rpath$dir:"
50974 + done
50975 + compile_var="$runpath_var=\"$rpath\$$runpath_var\" "
50976 + fi
50977 + if test -n "$finalize_perm_rpath"; then
50978 + # We should set the runpath_var.
50979 + rpath=
50980 + for dir in $finalize_perm_rpath; do
50981 + rpath="$rpath$dir:"
50982 + done
50983 + finalize_var="$runpath_var=\"$rpath\$$runpath_var\" "
50984 + fi
50985 + fi
50986 +
50987 + if test "$no_install" = yes; then
50988 + # We don't need to create a wrapper script.
50989 + link_command="$compile_var$compile_command$compile_rpath"
50990 + # Replace the output file specification.
50991 + link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'`
50992 + # Delete the old output file.
50993 + $opt_dry_run || $RM $output
50994 + # Link the executable and exit
50995 + func_show_eval "$link_command" 'exit $?'
50996 + exit $EXIT_SUCCESS
50997 + fi
50998 +
50999 + if test "$hardcode_action" = relink; then
51000 + # Fast installation is not supported
51001 + link_command="$compile_var$compile_command$compile_rpath"
51002 + relink_command="$finalize_var$finalize_command$finalize_rpath"
51003 +
51004 + func_warning "this platform does not like uninstalled shared libraries"
51005 + func_warning "\`$output' will be relinked during installation"
51006 + else
51007 + if test "$fast_install" != no; then
51008 + link_command="$finalize_var$compile_command$finalize_rpath"
51009 + if test "$fast_install" = yes; then
51010 + relink_command=`$ECHO "X$compile_var$compile_command$compile_rpath" | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g'`
51011 + else
51012 + # fast_install is set to needless
51013 + relink_command=
51014 + fi
51015 + else
51016 + link_command="$compile_var$compile_command$compile_rpath"
51017 + relink_command="$finalize_var$finalize_command$finalize_rpath"
51018 + fi
51019 + fi
51020 +
51021 + # Replace the output file specification.
51022 + link_command=`$ECHO "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'`
51023 +
51024 + # Delete the old output files.
51025 + $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname
51026 +
51027 + func_show_eval "$link_command" 'exit $?'
51028 +
51029 + # Now create the wrapper script.
51030 + func_echo "creating $output"
51031 +
51032 + # Quote the relink command for shipping.
51033 + if test -n "$relink_command"; then
51034 + # Preserve any variables that may affect compiler behavior
51035 + for var in $variables_saved_for_relink; do
51036 + if eval test -z \"\${$var+set}\"; then
51037 + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command"
51038 + elif eval var_value=\$$var; test -z "$var_value"; then
51039 + relink_command="$var=; export $var; $relink_command"
51040 + else
51041 + func_quote_for_eval "$var_value"
51042 + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command"
51043 + fi
51044 + done
51045 + relink_command="(cd `pwd`; $relink_command)"
51046 + relink_command=`$ECHO "X$relink_command" | $Xsed -e "$sed_quote_subst"`
51047 + fi
51048 +
51049 + # Quote $ECHO for shipping.
51050 + if test "X$ECHO" = "X$SHELL $progpath --fallback-echo"; then
51051 + case $progpath in
51052 + [\\/]* | [A-Za-z]:[\\/]*) qecho="$SHELL $progpath --fallback-echo";;
51053 + *) qecho="$SHELL `pwd`/$progpath --fallback-echo";;
51054 + esac
51055 + qecho=`$ECHO "X$qecho" | $Xsed -e "$sed_quote_subst"`
51056 + else
51057 + qecho=`$ECHO "X$ECHO" | $Xsed -e "$sed_quote_subst"`
51058 + fi
51059 +
51060 + # Only actually do things if not in dry run mode.
51061 + $opt_dry_run || {
51062 + # win32 will think the script is a binary if it has
51063 + # a .exe suffix, so we strip it off here.
51064 + case $output in
51065 + *.exe) func_stripname '' '.exe' "$output"
51066 + output=$func_stripname_result ;;
51067 + esac
51068 + # test for cygwin because mv fails w/o .exe extensions
51069 + case $host in
51070 + *cygwin*)
51071 + exeext=.exe
51072 + func_stripname '' '.exe' "$outputname"
51073 + outputname=$func_stripname_result ;;
51074 + *) exeext= ;;
51075 + esac
51076 + case $host in
51077 + *cygwin* | *mingw* )
51078 + output_name=`basename $output`
51079 + output_path=`dirname $output`
51080 + cwrappersource="$output_path/$objdir/lt-$output_name.c"
51081 + cwrapper="$output_path/$output_name.exe"
51082 + $RM $cwrappersource $cwrapper
51083 + trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15
51084 +
51085 + cat > $cwrappersource <<EOF
51086 +
51087 +/* $cwrappersource - temporary wrapper executable for $objdir/$outputname
51088 + Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
51089 +
51090 + The $output program cannot be directly executed until all the libtool
51091 + libraries that it depends on are installed.
51092 +
51093 + This wrapper executable should never be moved out of the build directory.
51094 + If it is, it will not operate correctly.
51095 +
51096 + Currently, it simply execs the wrapper *script* "/bin/sh $output",
51097 + but could eventually absorb all of the scripts functionality and
51098 + exec $objdir/$outputname directly.
51099 +*/
51100 +EOF
51101 + cat >> $cwrappersource<<"EOF"
51102 +#include <stdio.h>
51103 +#include <stdlib.h>
51104 +#include <unistd.h>
51105 +#include <malloc.h>
51106 +#include <stdarg.h>
51107 +#include <assert.h>
51108 +#include <string.h>
51109 +#include <ctype.h>
51110 +#include <sys/stat.h>
51111 +
51112 +#if defined(PATH_MAX)
51113 +# define LT_PATHMAX PATH_MAX
51114 +#elif defined(MAXPATHLEN)
51115 +# define LT_PATHMAX MAXPATHLEN
51116 +#else
51117 +# define LT_PATHMAX 1024
51118 +#endif
51119 +
51120 +#ifndef DIR_SEPARATOR
51121 +# define DIR_SEPARATOR '/'
51122 +# define PATH_SEPARATOR ':'
51123 +#endif
51124 +
51125 +#if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \
51126 + defined (__OS2__)
51127 +# define HAVE_DOS_BASED_FILE_SYSTEM
51128 +# ifndef DIR_SEPARATOR_2
51129 +# define DIR_SEPARATOR_2 '\\'
51130 +# endif
51131 +# ifndef PATH_SEPARATOR_2
51132 +# define PATH_SEPARATOR_2 ';'
51133 +# endif
51134 +#endif
51135 +
51136 +#ifndef DIR_SEPARATOR_2
51137 +# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR)
51138 +#else /* DIR_SEPARATOR_2 */
51139 +# define IS_DIR_SEPARATOR(ch) \
51140 + (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2))
51141 +#endif /* DIR_SEPARATOR_2 */
51142 +
51143 +#ifndef PATH_SEPARATOR_2
51144 +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR)
51145 +#else /* PATH_SEPARATOR_2 */
51146 +# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2)
51147 +#endif /* PATH_SEPARATOR_2 */
51148 +
51149 +#define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type)))
51150 +#define XFREE(stale) do { \
51151 + if (stale) { free ((void *) stale); stale = 0; } \
51152 +} while (0)
51153 +
51154 +/* -DDEBUG is fairly common in CFLAGS. */
51155 +#undef DEBUG
51156 +#if defined DEBUGWRAPPER
51157 +# define DEBUG(format, ...) fprintf(stderr, format, __VA_ARGS__)
51158 +#else
51159 +# define DEBUG(format, ...)
51160 +#endif
51161 +
51162 +const char *program_name = NULL;
51163 +
51164 +void * xmalloc (size_t num);
51165 +char * xstrdup (const char *string);
51166 +const char * base_name (const char *name);
51167 +char * find_executable(const char *wrapper);
51168 +int check_executable(const char *path);
51169 +char * strendzap(char *str, const char *pat);
51170 +void lt_fatal (const char *message, ...);
51171 +
51172 +int
51173 +main (int argc, char *argv[])
51174 +{
51175 + char **newargz;
51176 + int i;
51177 +
51178 + program_name = (char *) xstrdup (base_name (argv[0]));
51179 + DEBUG("(main) argv[0] : %s\n",argv[0]);
51180 + DEBUG("(main) program_name : %s\n",program_name);
51181 + newargz = XMALLOC(char *, argc+2);
51182 +EOF
51183 +
51184 + cat >> $cwrappersource <<EOF
51185 + newargz[0] = (char *) xstrdup("$SHELL");
51186 +EOF
51187 +
51188 + cat >> $cwrappersource <<"EOF"
51189 + newargz[1] = find_executable(argv[0]);
51190 + if (newargz[1] == NULL)
51191 + lt_fatal("Couldn't find %s", argv[0]);
51192 + DEBUG("(main) found exe at : %s\n",newargz[1]);
51193 + /* we know the script has the same name, without the .exe */
51194 + /* so make sure newargz[1] doesn't end in .exe */
51195 + strendzap(newargz[1],".exe");
51196 + for (i = 1; i < argc; i++)
51197 + newargz[i+1] = xstrdup(argv[i]);
51198 + newargz[argc+1] = NULL;
51199 +
51200 + for (i=0; i<argc+1; i++)
51201 + {
51202 + DEBUG("(main) newargz[%d] : %s\n",i,newargz[i]);
51203 + ;
51204 + }
51205 +
51206 +EOF
51207 +
51208 + case $host_os in
51209 + mingw*)
51210 + cat >> $cwrappersource <<EOF
51211 + execv("$SHELL",(char const **)newargz);
51212 +EOF
51213 + ;;
51214 + *)
51215 + cat >> $cwrappersource <<EOF
51216 + execv("$SHELL",newargz);
51217 +EOF
51218 + ;;
51219 + esac
51220 +
51221 + cat >> $cwrappersource <<"EOF"
51222 + return 127;
51223 +}
51224 +
51225 +void *
51226 +xmalloc (size_t num)
51227 +{
51228 + void * p = (void *) malloc (num);
51229 + if (!p)
51230 + lt_fatal ("Memory exhausted");
51231 +
51232 + return p;
51233 +}
51234 +
51235 +char *
51236 +xstrdup (const char *string)
51237 +{
51238 + return string ? strcpy ((char *) xmalloc (strlen (string) + 1), string) : NULL
51239 +;
51240 +}
51241 +
51242 +const char *
51243 +base_name (const char *name)
51244 +{
51245 + const char *base;
51246 +
51247 +#if defined (HAVE_DOS_BASED_FILE_SYSTEM)
51248 + /* Skip over the disk name in MSDOS pathnames. */
51249 + if (isalpha ((unsigned char)name[0]) && name[1] == ':')
51250 + name += 2;
51251 +#endif
51252 +
51253 + for (base = name; *name; name++)
51254 + if (IS_DIR_SEPARATOR (*name))
51255 + base = name + 1;
51256 + return base;
51257 +}
51258 +
51259 +int
51260 +check_executable(const char * path)
51261 +{
51262 + struct stat st;
51263 +
51264 + DEBUG("(check_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!");
51265 + if ((!path) || (!*path))
51266 + return 0;
51267 +
51268 + if ((stat (path, &st) >= 0) &&
51269 + (
51270 + /* MinGW & native WIN32 do not support S_IXOTH or S_IXGRP */
51271 +#if defined (S_IXOTH)
51272 + ((st.st_mode & S_IXOTH) == S_IXOTH) ||
51273 +#endif
51274 +#if defined (S_IXGRP)
51275 + ((st.st_mode & S_IXGRP) == S_IXGRP) ||
51276 +#endif
51277 + ((st.st_mode & S_IXUSR) == S_IXUSR))
51278 + )
51279 + return 1;
51280 + else
51281 + return 0;
51282 +}
51283 +
51284 +/* Searches for the full path of the wrapper. Returns
51285 + newly allocated full path name if found, NULL otherwise */
51286 +char *
51287 +find_executable (const char* wrapper)
51288 +{
51289 + int has_slash = 0;
51290 + const char* p;
51291 + const char* p_next;
51292 + /* static buffer for getcwd */
51293 + char tmp[LT_PATHMAX + 1];
51294 + int tmp_len;
51295 + char* concat_name;
51296 +
51297 + DEBUG("(find_executable) : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!");
51298 +
51299 + if ((wrapper == NULL) || (*wrapper == '\0'))
51300 + return NULL;
51301 +
51302 + /* Absolute path? */
51303 +#if defined (HAVE_DOS_BASED_FILE_SYSTEM)
51304 + if (isalpha ((unsigned char)wrapper[0]) && wrapper[1] == ':')
51305 + {
51306 + concat_name = xstrdup (wrapper);
51307 + if (check_executable(concat_name))
51308 + return concat_name;
51309 + XFREE(concat_name);
51310 + }
51311 + else
51312 + {
51313 +#endif
51314 + if (IS_DIR_SEPARATOR (wrapper[0]))
51315 + {
51316 + concat_name = xstrdup (wrapper);
51317 + if (check_executable(concat_name))
51318 + return concat_name;
51319 + XFREE(concat_name);
51320 + }
51321 +#if defined (HAVE_DOS_BASED_FILE_SYSTEM)
51322 + }
51323 +#endif
51324 +
51325 + for (p = wrapper; *p; p++)
51326 + if (*p == '/')
51327 + {
51328 + has_slash = 1;
51329 + break;
51330 + }
51331 + if (!has_slash)
51332 + {
51333 + /* no slashes; search PATH */
51334 + const char* path = getenv ("PATH");
51335 + if (path != NULL)
51336 + {
51337 + for (p = path; *p; p = p_next)
51338 + {
51339 + const char* q;
51340 + size_t p_len;
51341 + for (q = p; *q; q++)
51342 + if (IS_PATH_SEPARATOR(*q))
51343 + break;
51344 + p_len = q - p;
51345 + p_next = (*q == '\0' ? q : q + 1);
51346 + if (p_len == 0)
51347 + {
51348 + /* empty path: current directory */
51349 + if (getcwd (tmp, LT_PATHMAX) == NULL)
51350 + lt_fatal ("getcwd failed");
51351 + tmp_len = strlen(tmp);
51352 + concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1);
51353 + memcpy (concat_name, tmp, tmp_len);
51354 + concat_name[tmp_len] = '/';
51355 + strcpy (concat_name + tmp_len + 1, wrapper);
51356 + }
51357 + else
51358 + {
51359 + concat_name = XMALLOC(char, p_len + 1 + strlen(wrapper) + 1);
51360 + memcpy (concat_name, p, p_len);
51361 + concat_name[p_len] = '/';
51362 + strcpy (concat_name + p_len + 1, wrapper);
51363 + }
51364 + if (check_executable(concat_name))
51365 + return concat_name;
51366 + XFREE(concat_name);
51367 + }
51368 + }
51369 + /* not found in PATH; assume curdir */
51370 + }
51371 + /* Relative path | not found in path: prepend cwd */
51372 + if (getcwd (tmp, LT_PATHMAX) == NULL)
51373 + lt_fatal ("getcwd failed");
51374 + tmp_len = strlen(tmp);
51375 + concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1);
51376 + memcpy (concat_name, tmp, tmp_len);
51377 + concat_name[tmp_len] = '/';
51378 + strcpy (concat_name + tmp_len + 1, wrapper);
51379 +
51380 + if (check_executable(concat_name))
51381 + return concat_name;
51382 + XFREE(concat_name);
51383 + return NULL;
51384 +}
51385 +
51386 +char *
51387 +strendzap(char *str, const char *pat)
51388 +{
51389 + size_t len, patlen;
51390 +
51391 + assert(str != NULL);
51392 + assert(pat != NULL);
51393 +
51394 + len = strlen(str);
51395 + patlen = strlen(pat);
51396 +
51397 + if (patlen <= len)
51398 + {
51399 + str += len - patlen;
51400 + if (strcmp(str, pat) == 0)
51401 + *str = '\0';
51402 + }
51403 + return str;
51404 +}
51405 +
51406 +static void
51407 +lt_error_core (int exit_status, const char * mode,
51408 + const char * message, va_list ap)
51409 +{
51410 + fprintf (stderr, "%s: %s: ", program_name, mode);
51411 + vfprintf (stderr, message, ap);
51412 + fprintf (stderr, ".\n");
51413 +
51414 + if (exit_status >= 0)
51415 + exit (exit_status);
51416 +}
51417 +
51418 +void
51419 +lt_fatal (const char *message, ...)
51420 +{
51421 + va_list ap;
51422 + va_start (ap, message);
51423 + lt_error_core (EXIT_FAILURE, "FATAL", message, ap);
51424 + va_end (ap);
51425 +}
51426 +EOF
51427 + # we should really use a build-platform specific compiler
51428 + # here, but OTOH, the wrappers (shell script and this C one)
51429 + # are only useful if you want to execute the "real" binary.
51430 + # Since the "real" binary is built for $host, then this
51431 + # wrapper might as well be built for $host, too.
51432 + $opt_dry_run || $LTCC $LTCFLAGS -s -o $cwrapper $cwrappersource
51433 + ;;
51434 + esac
51435 + $RM $output
51436 + trap "$RM $output; exit $EXIT_FAILURE" 1 2 15
51437 +
51438 + $ECHO > $output "\
51439 +#! $SHELL
51440 +
51441 +# $output - temporary wrapper script for $objdir/$outputname
51442 +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
51443 +#
51444 +# The $output program cannot be directly executed until all the libtool
51445 +# libraries that it depends on are installed.
51446 +#
51447 +# This wrapper script should never be moved out of the build directory.
51448 +# If it is, it will not operate correctly.
51449 +
51450 +# Sed substitution that helps us do robust quoting. It backslashifies
51451 +# metacharacters that are still active within double-quoted strings.
51452 +Xsed='${SED} -e 1s/^X//'
51453 +sed_quote_subst='$sed_quote_subst'
51454 +
51455 +# Be Bourne compatible
51456 +if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then
51457 + emulate sh
51458 + NULLCMD=:
51459 + # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which
51460 + # is contrary to our usage. Disable this feature.
51461 + alias -g '\${1+\"\$@\"}'='\"\$@\"'
51462 + setopt NO_GLOB_SUBST
51463 +else
51464 + case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac
51465 +fi
51466 +BIN_SH=xpg4; export BIN_SH # for Tru64
51467 +DUALCASE=1; export DUALCASE # for MKS sh
51468 +
51469 +# The HP-UX ksh and POSIX shell print the target directory to stdout
51470 +# if CDPATH is set.
51471 +(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
51472 +
51473 +relink_command=\"$relink_command\"
51474 +
51475 +# This environment variable determines our operation mode.
51476 +if test \"\$libtool_install_magic\" = \"$magic\"; then
51477 + # install mode needs the following variables:
51478 + generated_by_libtool_version='$macro_version'
51479 + notinst_deplibs='$notinst_deplibs'
51480 +else
51481 + # When we are sourced in execute mode, \$file and \$ECHO are already set.
51482 + if test \"\$libtool_execute_magic\" != \"$magic\"; then
51483 + ECHO=\"$qecho\"
51484 + file=\"\$0\"
51485 + # Make sure echo works.
51486 + if test \"X\$1\" = X--no-reexec; then
51487 + # Discard the --no-reexec flag, and continue.
51488 + shift
51489 + elif test \"X\`{ \$ECHO '\t'; } 2>/dev/null\`\" = 'X\t'; then
51490 + # Yippee, \$ECHO works!
51491 + :
51492 + else
51493 + # Restart under the correct shell, and then maybe \$ECHO will work.
51494 + exec $SHELL \"\$0\" --no-reexec \${1+\"\$@\"}
51495 + fi
51496 + fi\
51497 +"
51498 + $ECHO >> $output "\
51499 +
51500 + # Find the directory that this script lives in.
51501 + thisdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\`
51502 + test \"x\$thisdir\" = \"x\$file\" && thisdir=.
51503 +
51504 + # Follow symbolic links until we get to the real thisdir.
51505 + file=\`ls -ld \"\$file\" | ${SED} -n 's/.*-> //p'\`
51506 + while test -n \"\$file\"; do
51507 + destdir=\`\$ECHO \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\`
51508 +
51509 + # If there was a directory component, then change thisdir.
51510 + if test \"x\$destdir\" != \"x\$file\"; then
51511 + case \"\$destdir\" in
51512 + [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;;
51513 + *) thisdir=\"\$thisdir/\$destdir\" ;;
51514 + esac
51515 + fi
51516 +
51517 + file=\`\$ECHO \"X\$file\" | \$Xsed -e 's%^.*/%%'\`
51518 + file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\`
51519 + done
51520 +
51521 + # Try to get the absolute directory name.
51522 + absdir=\`cd \"\$thisdir\" && pwd\`
51523 + test -n \"\$absdir\" && thisdir=\"\$absdir\"
51524 +"
51525 +
51526 + if test "$fast_install" = yes; then
51527 + $ECHO >> $output "\
51528 + program=lt-'$outputname'$exeext
51529 + progdir=\"\$thisdir/$objdir\"
51530 +
51531 + if test ! -f \"\$progdir/\$program\" ||
51532 + { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\
51533 + test \"X\$file\" != \"X\$progdir/\$program\"; }; then
51534 +
51535 + file=\"\$\$-\$program\"
51536 +
51537 + if test ! -d \"\$progdir\"; then
51538 + $MKDIR \"\$progdir\"
51539 + else
51540 + $RM \"\$progdir/\$file\"
51541 + fi"
51542 +
51543 + $ECHO >> $output "\
51544 +
51545 + # relink executable if necessary
51546 + if test -n \"\$relink_command\"; then
51547 + if relink_command_output=\`eval \$relink_command 2>&1\`; then :
51548 + else
51549 + $ECHO \"\$relink_command_output\" >&2
51550 + $RM \"\$progdir/\$file\"
51551 + exit 1
51552 + fi
51553 + fi
51554 +
51555 + $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null ||
51556 + { $RM \"\$progdir/\$program\";
51557 + $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; }
51558 + $RM \"\$progdir/\$file\"
51559 + fi"
51560 + else
51561 + $ECHO >> $output "\
51562 + program='$outputname'
51563 + progdir=\"\$thisdir/$objdir\"
51564 +"
51565 + fi
51566 +
51567 + $ECHO >> $output "\
51568 +
51569 + if test -f \"\$progdir/\$program\"; then"
51570 +
51571 + # Export our shlibpath_var if we have one.
51572 + if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then
51573 + $ECHO >> $output "\
51574 + # Add our own library path to $shlibpath_var
51575 + $shlibpath_var=\"$temp_rpath\$$shlibpath_var\"
51576 +
51577 + # Some systems cannot cope with colon-terminated $shlibpath_var
51578 + # The second colon is a workaround for a bug in BeOS R4 sed
51579 + $shlibpath_var=\`\$ECHO \"X\$$shlibpath_var\" | \$Xsed -e 's/::*\$//'\`
51580 +
51581 + export $shlibpath_var
51582 +"
51583 + fi
51584 +
51585 + # fixup the dll searchpath if we need to.
51586 + if test -n "$dllsearchpath"; then
51587 + $ECHO >> $output "\
51588 + # Add the dll search path components to the executable PATH
51589 + PATH=$dllsearchpath:\$PATH
51590 +"
51591 + fi
51592 +
51593 + $ECHO >> $output "\
51594 + if test \"\$libtool_execute_magic\" != \"$magic\"; then
51595 + # Run the actual program with our arguments.
51596 +"
51597 + case $host in
51598 + # Backslashes separate directories on plain windows
51599 + *-*-mingw | *-*-os2*)
51600 + $ECHO >> $output "\
51601 + exec \"\$progdir\\\\\$program\" \${1+\"\$@\"}
51602 +"
51603 + ;;
51604 +
51605 + *)
51606 + $ECHO >> $output "\
51607 + exec \"\$progdir/\$program\" \${1+\"\$@\"}
51608 +"
51609 + ;;
51610 + esac
51611 + $ECHO >> $output "\
51612 + \$ECHO \"\$0: cannot exec \$program \$*\"
51613 + exit 1
51614 + fi
51615 + else
51616 + # The program doesn't exist.
51617 + \$ECHO \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2
51618 + \$ECHO \"This script is just a wrapper for \$program.\" 1>&2
51619 + $ECHO \"See the $PACKAGE documentation for more information.\" 1>&2
51620 + exit 1
51621 + fi
51622 +fi\
51623 +"
51624 + chmod +x $output
51625 + }
51626 + exit $EXIT_SUCCESS
51627 + ;;
51628 + esac
51629 +
51630 + # See if we need to build an old-fashioned archive.
51631 + for oldlib in $oldlibs; do
51632 +
51633 + if test "$build_libtool_libs" = convenience; then
51634 + oldobjs="$libobjs_save $symfileobj"
51635 + addlibs="$convenience"
51636 + build_libtool_libs=no
51637 + else
51638 + if test "$build_libtool_libs" = module; then
51639 + oldobjs="$libobjs_save"
51640 + build_libtool_libs=no
51641 + else
51642 + oldobjs="$old_deplibs $non_pic_objects"
51643 + if test "$preload" = yes && test -f "$symfileobj"; then
51644 + oldobjs="$oldobjs $symfileobj"
51645 + fi
51646 + fi
51647 + addlibs="$old_convenience"
51648 + fi
51649 +
51650 + if test -n "$addlibs"; then
51651 + gentop="$output_objdir/${outputname}x"
51652 + generated="$generated $gentop"
51653 +
51654 + func_extract_archives $gentop $addlibs
51655 + oldobjs="$oldobjs $func_extract_archives_result"
51656 + fi
51657 +
51658 + # Do each command in the archive commands.
51659 + if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then
51660 + cmds=$old_archive_from_new_cmds
51661 + else
51662 +
51663 + # Add any objects from preloaded convenience libraries
51664 + if test -n "$dlprefiles"; then
51665 + gentop="$output_objdir/${outputname}x"
51666 + generated="$generated $gentop"
51667 +
51668 + func_extract_archives $gentop $dlprefiles
51669 + oldobjs="$oldobjs $func_extract_archives_result"
51670 + fi
51671 +
51672 + # POSIX demands no paths to be encoded in archives. We have
51673 + # to avoid creating archives with duplicate basenames if we
51674 + # might have to extract them afterwards, e.g., when creating a
51675 + # static archive out of a convenience library, or when linking
51676 + # the entirety of a libtool archive into another (currently
51677 + # not supported by libtool).
51678 + if (for obj in $oldobjs
51679 + do
51680 + func_basename "$obj"
51681 + $ECHO "$func_basename_result"
51682 + done | sort | sort -uc >/dev/null 2>&1); then
51683 + :
51684 + else
51685 + $ECHO "copying selected object files to avoid basename conflicts..."
51686 + gentop="$output_objdir/${outputname}x"
51687 + generated="$generated $gentop"
51688 + func_mkdir_p "$gentop"
51689 + save_oldobjs=$oldobjs
51690 + oldobjs=
51691 + counter=1
51692 + for obj in $save_oldobjs
51693 + do
51694 + func_basename "$obj"
51695 + objbase="$func_basename_result"
51696 + case " $oldobjs " in
51697 + " ") oldobjs=$obj ;;
51698 + *[\ /]"$objbase "*)
51699 + while :; do
51700 + # Make sure we don't pick an alternate name that also
51701 + # overlaps.
51702 + newobj=lt$counter-$objbase
51703 + counter=`expr $counter + 1`
51704 + case " $oldobjs " in
51705 + *[\ /]"$newobj "*) ;;
51706 + *) if test ! -f "$gentop/$newobj"; then break; fi ;;
51707 + esac
51708 + done
51709 + func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj"
51710 + oldobjs="$oldobjs $gentop/$newobj"
51711 + ;;
51712 + *) oldobjs="$oldobjs $obj" ;;
51713 + esac
51714 + done
51715 + fi
51716 + eval cmds=\"$old_archive_cmds\"
51717 +
51718 + if len=`expr "X$cmds" : ".*" 2>/dev/null` &&
51719 + test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then
51720 + cmds=$old_archive_cmds
51721 + else
51722 + # the command line is too long to link in one step, link in parts
51723 + func_echo "using piecewise archive linking..."
51724 + save_RANLIB=$RANLIB
51725 + RANLIB=:
51726 + objlist=
51727 + concat_cmds=
51728 + save_oldobjs=$oldobjs
51729 + # Is there a better way of finding the last object in the list?
51730 + for obj in $save_oldobjs
51731 + do
51732 + last_oldobj=$obj
51733 + done
51734 + for obj in $save_oldobjs
51735 + do
51736 + oldobjs="$objlist $obj"
51737 + objlist="$objlist $obj"
51738 + eval test_cmds=\"$old_archive_cmds\"
51739 + if len=`expr "X$test_cmds" : ".*" 2>/dev/null` &&
51740 + test "$len" -le "$max_cmd_len"; then
51741 + :
51742 + else
51743 + # the above command should be used before it gets too long
51744 + oldobjs=$objlist
51745 + if test "$obj" = "$last_oldobj" ; then
51746 + RANLIB=$save_RANLIB
51747 + fi
51748 + test -z "$concat_cmds" || concat_cmds=$concat_cmds~
51749 + eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\"
51750 + objlist=
51751 + fi
51752 + done
51753 + RANLIB=$save_RANLIB
51754 + oldobjs=$objlist
51755 + if test "X$oldobjs" = "X" ; then
51756 + eval cmds=\"\$concat_cmds\"
51757 + else
51758 + eval cmds=\"\$concat_cmds~\$old_archive_cmds\"
51759 + fi
51760 + fi
51761 + fi
51762 + func_execute_cmds "$cmds" 'exit $?'
51763 + done
51764 +
51765 + test -n "$generated" && \
51766 + func_show_eval "${RM}r$generated"
51767 +
51768 + # Now create the libtool archive.
51769 + case $output in
51770 + *.la)
51771 + old_library=
51772 + test "$build_old_libs" = yes && old_library="$libname.$libext"
51773 + func_echo "creating $output"
51774 +
51775 + # Preserve any variables that may affect compiler behavior
51776 + for var in $variables_saved_for_relink; do
51777 + if eval test -z \"\${$var+set}\"; then
51778 + relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command"
51779 + elif eval var_value=\$$var; test -z "$var_value"; then
51780 + relink_command="$var=; export $var; $relink_command"
51781 + else
51782 + func_quote_for_eval "$var_value"
51783 + relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command"
51784 + fi
51785 + done
51786 + # Quote the link command for shipping.
51787 + relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)"
51788 + relink_command=`$ECHO "X$relink_command" | $Xsed -e "$sed_quote_subst"`
51789 + if test "$hardcode_automatic" = yes ; then
51790 + relink_command=
51791 + fi
51792 +
51793 + # Only create the output if not a dry run.
51794 + $opt_dry_run || {
51795 + for installed in no yes; do
51796 + if test "$installed" = yes; then
51797 + if test -z "$install_libdir"; then
51798 + break
51799 + fi
51800 + output="$output_objdir/$outputname"i
51801 + # Replace all uninstalled libtool libraries with the installed ones
51802 + newdependency_libs=
51803 + for deplib in $dependency_libs; do
51804 + case $deplib in
51805 + *.la)
51806 + func_basename "$deplib"
51807 + name="$func_basename_result"
51808 + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
51809 + test -z "$libdir" && \
51810 + func_fatal_error "\`$deplib' is not a valid libtool archive"
51811 + newdependency_libs="$newdependency_libs $libdir/$name"
51812 + ;;
51813 + *) newdependency_libs="$newdependency_libs $deplib" ;;
51814 + esac
51815 + done
51816 + dependency_libs="$newdependency_libs"
51817 + newdlfiles=
51818 +
51819 + for lib in $dlfiles; do
51820 + case $lib in
51821 + *.la)
51822 + func_basename "$lib"
51823 + name="$func_basename_result"
51824 + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
51825 + test -z "$libdir" && \
51826 + func_fatal_error "\`$lib' is not a valid libtool archive"
51827 + newdlfiles="$newdlfiles $libdir/$name"
51828 + ;;
51829 + *) newdlfiles="$newdlfiles $lib" ;;
51830 + esac
51831 + done
51832 + dlfiles="$newdlfiles"
51833 + newdlprefiles=
51834 + for lib in $dlprefiles; do
51835 + case $lib in
51836 + *.la)
51837 + # Only pass preopened files to the pseudo-archive (for
51838 + # eventual linking with the app. that links it) if we
51839 + # didn't already link the preopened objects directly into
51840 + # the library:
51841 + func_basename "$lib"
51842 + name="$func_basename_result"
51843 + eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
51844 + test -z "$libdir" && \
51845 + func_fatal_error "\`$lib' is not a valid libtool archive"
51846 + newdlprefiles="$newdlprefiles $libdir/$name"
51847 + ;;
51848 + esac
51849 + done
51850 + dlprefiles="$newdlprefiles"
51851 + else
51852 + newdlfiles=
51853 + for lib in $dlfiles; do
51854 + case $lib in
51855 + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
51856 + *) abs=`pwd`"/$lib" ;;
51857 + esac
51858 + newdlfiles="$newdlfiles $abs"
51859 + done
51860 + dlfiles="$newdlfiles"
51861 + newdlprefiles=
51862 + for lib in $dlprefiles; do
51863 + case $lib in
51864 + [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;;
51865 + *) abs=`pwd`"/$lib" ;;
51866 + esac
51867 + newdlprefiles="$newdlprefiles $abs"
51868 + done
51869 + dlprefiles="$newdlprefiles"
51870 + fi
51871 + $RM $output
51872 + # place dlname in correct position for cygwin
51873 + tdlname=$dlname
51874 + case $host,$output,$installed,$module,$dlname in
51875 + *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;;
51876 + esac
51877 + $ECHO > $output "\
51878 +# $outputname - a libtool library file
51879 +# Generated by $PROGRAM (GNU $PACKAGE$TIMESTAMP) $VERSION
51880 +#
51881 +# Please DO NOT delete this file!
51882 +# It is necessary for linking the library.
51883 +
51884 +# The name that we can dlopen(3).
51885 +dlname='$tdlname'
51886 +
51887 +# Names of this library.
51888 +library_names='$library_names'
51889 +
51890 +# The name of the static archive.
51891 +old_library='$old_library'
51892 +
51893 +# Linker flags that can not go in dependency_libs.
51894 +inherited_linker_flags='$new_inherited_linker_flags'
51895 +
51896 +# Libraries that this one depends upon.
51897 +dependency_libs='$dependency_libs'
51898 +
51899 +# Names of additional weak libraries provided by this library
51900 +weak_library_names='$weak_libs'
51901 +
51902 +# Version information for $libname.
51903 +current=$current
51904 +age=$age
51905 +revision=$revision
51906 +
51907 +# Is this an already installed library?
51908 +installed=$installed
51909 +
51910 +# Should we warn about portability when linking against -modules?
51911 +shouldnotlink=$module
51912 +
51913 +# Files to dlopen/dlpreopen
51914 +dlopen='$dlfiles'
51915 +dlpreopen='$dlprefiles'
51916 +
51917 +# Directory that this library needs to be installed in:
51918 +libdir='$install_libdir'"
51919 + if test "$installed" = no && test "$need_relink" = yes; then
51920 + $ECHO >> $output "\
51921 +relink_command=\"$relink_command\""
51922 + fi
51923 + done
51924 + }
51925 +
51926 + # Do a symbolic link so that the libtool archive can be found in
51927 + # LD_LIBRARY_PATH before the program is installed.
51928 + func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?'
51929 + ;;
51930 + esac
51931 + exit $EXIT_SUCCESS
51932 +}
51933 +
51934 +{ test "$mode" = link || test "$mode" = relink; } &&
51935 + func_mode_link ${1+"$@"}
51936 +
51937 +
51938 +# func_mode_uninstall arg...
51939 +func_mode_uninstall ()
51940 +{
51941 + $opt_debug
51942 + RM="$nonopt"
51943 + files=
51944 + rmforce=
51945 + exit_status=0
51946 +
51947 + # This variable tells wrapper scripts just to set variables rather
51948 + # than running their programs.
51949 + libtool_install_magic="$magic"
51950 +
51951 + for arg
51952 + do
51953 + case $arg in
51954 + -f) RM="$RM $arg"; rmforce=yes ;;
51955 + -*) RM="$RM $arg" ;;
51956 + *) files="$files $arg" ;;
51957 + esac
51958 + done
51959 +
51960 + test -z "$RM" && \
51961 + func_fatal_help "you must specify an RM program"
51962 +
51963 + rmdirs=
51964 +
51965 + origobjdir="$objdir"
51966 + for file in $files; do
51967 + func_dirname "$file" "" "."
51968 + dir="$func_dirname_result"
51969 + if test "X$dir" = X.; then
51970 + objdir="$origobjdir"
51971 + else
51972 + objdir="$dir/$origobjdir"
51973 + fi
51974 + func_basename "$file"
51975 + name="$func_basename_result"
51976 + test "$mode" = uninstall && objdir="$dir"
51977 +
51978 + # Remember objdir for removal later, being careful to avoid duplicates
51979 + if test "$mode" = clean; then
51980 + case " $rmdirs " in
51981 + *" $objdir "*) ;;
51982 + *) rmdirs="$rmdirs $objdir" ;;
51983 + esac
51984 + fi
51985 +
51986 + # Don't error if the file doesn't exist and rm -f was used.
51987 + if { test -L "$file"; } >/dev/null 2>&1 ||
51988 + { test -h "$file"; } >/dev/null 2>&1 ||
51989 + test -f "$file"; then
51990 + :
51991 + elif test -d "$file"; then
51992 + exit_status=1
51993 + continue
51994 + elif test "$rmforce" = yes; then
51995 + continue
51996 + fi
51997 +
51998 + rmfiles="$file"
51999 +
52000 + case $name in
52001 + *.la)
52002 + # Possibly a libtool archive, so verify it.
52003 + if func_lalib_p "$file"; then
52004 + func_source $dir/$name
52005 +
52006 + # Delete the libtool libraries and symlinks.
52007 + for n in $library_names; do
52008 + rmfiles="$rmfiles $objdir/$n"
52009 + done
52010 + test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library"
52011 +
52012 + case "$mode" in
52013 + clean)
52014 + case " $library_names " in
52015 + # " " in the beginning catches empty $dlname
52016 + *" $dlname "*) ;;
52017 + *) rmfiles="$rmfiles $objdir/$dlname" ;;
52018 + esac
52019 + test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i"
52020 + ;;
52021 + uninstall)
52022 + if test -n "$library_names"; then
52023 + # Do each command in the postuninstall commands.
52024 + func_execute_cmds "$postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1'
52025 + fi
52026 +
52027 + if test -n "$old_library"; then
52028 + # Do each command in the old_postuninstall commands.
52029 + func_execute_cmds "$old_postuninstall_cmds" 'test "$rmforce" = yes || exit_status=1'
52030 + fi
52031 + # FIXME: should reinstall the best remaining shared library.
52032 + ;;
52033 + esac
52034 + fi
52035 + ;;
52036 +
52037 + *.lo)
52038 + # Possibly a libtool object, so verify it.
52039 + if func_lalib_p "$file"; then
52040 +
52041 + # Read the .lo file
52042 + func_source $dir/$name
52043 +
52044 + # Add PIC object to the list of files to remove.
52045 + if test -n "$pic_object" &&
52046 + test "$pic_object" != none; then
52047 + rmfiles="$rmfiles $dir/$pic_object"
52048 + fi
52049 +
52050 + # Add non-PIC object to the list of files to remove.
52051 + if test -n "$non_pic_object" &&
52052 + test "$non_pic_object" != none; then
52053 + rmfiles="$rmfiles $dir/$non_pic_object"
52054 + fi
52055 + fi
52056 + ;;
52057 +
52058 + *)
52059 + if test "$mode" = clean ; then
52060 + noexename=$name
52061 + case $file in
52062 + *.exe)
52063 + func_stripname '' '.exe' "$file"
52064 + file=$func_stripname_result
52065 + func_stripname '' '.exe' "$name"
52066 + noexename=$func_stripname_result
52067 + # $file with .exe has already been added to rmfiles,
52068 + # add $file without .exe
52069 + rmfiles="$rmfiles $file"
52070 + ;;
52071 + esac
52072 + # Do a test to see if this is a libtool program.
52073 + if func_ltwrapper_p "$file"; then
52074 + relink_command=
52075 + func_source $dir/$noexename
52076 +
52077 + # note $name still contains .exe if it was in $file originally
52078 + # as does the version of $file that was added into $rmfiles
52079 + rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}"
52080 + if test "$fast_install" = yes && test -n "$relink_command"; then
52081 + rmfiles="$rmfiles $objdir/lt-$name"
52082 + fi
52083 + if test "X$noexename" != "X$name" ; then
52084 + rmfiles="$rmfiles $objdir/lt-${noexename}.c"
52085 + fi
52086 + fi
52087 + fi
52088 + ;;
52089 + esac
52090 + func_show_eval "$RM $rmfiles" 'exit_status=1'
52091 + done
52092 + objdir="$origobjdir"
52093 +
52094 + # Try to remove the ${objdir}s in the directories where we deleted files
52095 + for dir in $rmdirs; do
52096 + if test -d "$dir"; then
52097 + func_show_eval "rmdir $dir >/dev/null 2>&1"
52098 + fi
52099 + done
52100 +
52101 + exit $exit_status
52102 +}
52103 +
52104 +{ test "$mode" = uninstall || test "$mode" = clean; } &&
52105 + func_mode_uninstall ${1+"$@"}
52106 +
52107 +test -z "$mode" && {
52108 + help="$generic_help"
52109 + func_fatal_help "you must specify a MODE"
52110 +}
52111 +
52112 +test -z "$exec_cmd" && \
52113 + func_fatal_help "invalid operation mode \`$mode'"
52114 +
52115 +if test -n "$exec_cmd"; then
52116 + eval exec "$exec_cmd"
52117 + exit $EXIT_FAILURE
52118 +fi
52119 +
52120 +exit $exit_status
52121 +
52122 +
52123 +# The TAGs below are defined such that we never get into a situation
52124 +# in which we disable both kinds of libraries. Given conflicting
52125 +# choices, we go for a static library, that is the most portable,
52126 +# since we can't tell whether shared libraries were disabled because
52127 +# the user asked for that or because the platform doesn't support
52128 +# them. This is particularly important on AIX, because we don't
52129 +# support having both static and shared libraries enabled at the same
52130 +# time on that platform, so we default to a shared-only configuration.
52131 +# If a disable-shared tag is given, we'll fallback to a static-only
52132 +# configuration. But we'll never go from static-only to shared-only.
52133 +
52134 +# ### BEGIN LIBTOOL TAG CONFIG: disable-shared
52135 +build_libtool_libs=no
52136 +build_old_libs=yes
52137 +# ### END LIBTOOL TAG CONFIG: disable-shared
52138 +
52139 +# ### BEGIN LIBTOOL TAG CONFIG: disable-static
52140 +build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac`
52141 +# ### END LIBTOOL TAG CONFIG: disable-static
52142 +
52143 +# Local Variables:
52144 +# mode:shell-script
52145 +# sh-indentation:2
52146 +# End:
52147 +# vi:sw=2
52148 --- a/bfd/Makefile.in
52149 +++ b/bfd/Makefile.in
52150 @@ -312,6 +312,7 @@ ALL_MACHINES = \
52151 cpu-arc.lo \
52152 cpu-arm.lo \
52153 cpu-avr.lo \
52154 + cpu-avr32.lo \
52155 cpu-bfin.lo \
52156 cpu-cr16.lo \
52157 cpu-cr16c.lo \
52158 @@ -493,6 +494,7 @@ BFD32_BACKENDS = \
52159 elf32-arc.lo \
52160 elf32-arm.lo \
52161 elf32-avr.lo \
52162 + elf32-avr32.lo \
52163 elf32-bfin.lo \
52164 elf32-cr16.lo \
52165 elf32-cr16c.lo \
52166 @@ -1908,6 +1910,10 @@ elf32-cr16.lo: elf32-cr16.c $(INCDIR)/fi
52167 $(INCDIR)/hashtab.h $(INCDIR)/libiberty.h elf-bfd.h \
52168 $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
52169 $(INCDIR)/elf/cr16.h $(INCDIR)/elf/reloc-macros.h elf32-target.h
52170 +elf32-avr32.lo: elf32-avr32.c $(INCDIR)/filenames.h elf-bfd.h \
52171 + $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
52172 + $(INCDIR)/bfdlink.h $(INCDIR)/elf/avr32.h $(INCDIR)/elf/reloc-macros.h \
52173 + elf32-target.h
52174 elf32-cr16c.lo: elf32-cr16c.c $(INCDIR)/filenames.h \
52175 $(INCDIR)/hashtab.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/cr16c.h \
52176 $(INCDIR)/elf/reloc-macros.h elf-bfd.h $(INCDIR)/elf/common.h \
52177 --- /dev/null
52178 +++ b/bfd/po/Makefile.in
52179 @@ -0,0 +1,297 @@
52180 +# Makefile for program source directory in GNU NLS utilities package.
52181 +# Copyright (C) 1995, 1996, 1997 by Ulrich Drepper <drepper@gnu.ai.mit.edu>
52182 +# Copyright 2001, 2003, 2006 Free Software Foundation, Inc.
52183 +#
52184 +# This file may be copied and used freely without restrictions. It can
52185 +# be used in projects which are not available under the GNU Public License
52186 +# but which still want to provide support for the GNU gettext functionality.
52187 +# Please note that the actual code is *not* freely available.
52188 +
52189 +PACKAGE = bfd
52190 +VERSION = 2.18
52191 +
52192 +SHELL = /bin/sh
52193 +
52194 +
52195 +srcdir = .
52196 +top_srcdir = ..
52197 +
52198 +top_builddir = ..
52199 +
52200 +prefix = /usr
52201 +exec_prefix = ${prefix}
52202 +datadir = $(prefix)/share
52203 +localedir = $(datadir)/locale
52204 +gnulocaledir = $(prefix)/share/locale
52205 +gettextsrcdir = $(prefix)/share/gettext/po
52206 +subdir = po
52207 +
52208 +DESTDIR =
52209 +
52210 +INSTALL = /usr/bin/install -c
52211 +INSTALL_DATA = ${INSTALL} -m 644
52212 +MKINSTALLDIRS = $(top_builddir)/./../mkinstalldirs
52213 +
52214 +CC = gcc
52215 +GENCAT = gencat
52216 +GMSGFMT = PATH=../src:$$PATH /usr/bin/msgfmt
52217 +MSGFMT = /usr/bin/msgfmt
52218 +XGETTEXT = PATH=../src:$$PATH /usr/bin/xgettext
52219 +MSGMERGE = PATH=../src:$$PATH msgmerge
52220 +
52221 +DEFS = -DHAVE_CONFIG_H
52222 +CFLAGS = -g -O2
52223 +CPPFLAGS =
52224 +
52225 +INCLUDES = -I.. -I$(top_srcdir)/intl
52226 +
52227 +COMPILE = $(CC) -c $(DEFS) $(INCLUDES) $(CPPFLAGS) $(CFLAGS) $(XCFLAGS)
52228 +
52229 +SOURCES = cat-id-tbl.c
52230 +POFILES = @POFILES@
52231 +GMOFILES = @GMOFILES@
52232 +DISTFILES = ChangeLog Makefile.in.in SRC-POTFILES.in BLD-POTFILES.in $(PACKAGE).pot \
52233 +stamp-cat-id $(POFILES) $(GMOFILES) $(SOURCES)
52234 +
52235 +# Note - the following line gets processed by bfd/configure and amended
52236 +# to contain the full list of source dir POTFILES.
52237 +SRC-POTFILES = \
52238 +
52239 +# Note - the following line gets processed by bfd/configure and amended
52240 +# to contain the full list of build dir POTFILES.
52241 +BLD-POTFILES = \
52242 +
52243 +CATALOGS = da.gmo es.gmo fr.gmo ja.gmo ro.gmo rw.gmo sv.gmo tr.gmo vi.gmo zh_CN.gmo da.gmo es.gmo fr.gmo ja.gmo ro.gmo rw.gmo sv.gmo tr.gmo vi.gmo zh_CN.gmo
52244 +CATOBJEXT = .gmo
52245 +INSTOBJEXT = .mo
52246 +
52247 +.SUFFIXES:
52248 +.SUFFIXES: .c .o .po .pox .gmo .mo .msg .cat
52249 +
52250 +.c.o:
52251 + $(COMPILE) $<
52252 +
52253 +.po.pox:
52254 + $(MAKE) $(PACKAGE).pot
52255 + $(MSGMERGE) $< $(srcdir)/$(PACKAGE).pot -o $*.pox
52256 +
52257 +.po.mo:
52258 + $(MSGFMT) -o $@ $<
52259 +
52260 +.po.gmo:
52261 + file=`echo $* | sed 's,.*/,,'`.gmo \
52262 + && rm -f $$file && $(GMSGFMT) -o $$file $<
52263 +
52264 +.po.cat:
52265 + sed -f ../intl/po2msg.sed < $< > $*.msg \
52266 + && rm -f $@ && $(GENCAT) $@ $*.msg
52267 +
52268 +
52269 +all: all-yes
52270 +
52271 +all-yes: $(CATALOGS) # $(PACKAGE).pot
52272 +all-no:
52273 +
52274 +$(srcdir)/$(PACKAGE).pot: $(SRC-POTFILES) $(BLD-POTFILES)
52275 + $(XGETTEXT) --default-domain=$(PACKAGE) \
52276 + --directory=$(top_srcdir) \
52277 + --add-comments --keyword=_ --keyword=N_ \
52278 + --msgid-bugs-address=bug-binutils@gnu.org \
52279 + --files-from=$(srcdir)/SRC-POTFILES.in
52280 + $(XGETTEXT) --default-domain=$(PACKAGE) \
52281 + --directory=.. \
52282 + --directory=. \
52283 + --add-comments --keyword=_ --keyword=N_ \
52284 + --join-existing \
52285 + --msgid-bugs-address=bug-binutils@gnu.org \
52286 + --files-from=$(srcdir)/BLD-POTFILES.in
52287 + rm -f $(srcdir)/$(PACKAGE).pot
52288 + mv $(PACKAGE).po $(srcdir)/$(PACKAGE).pot
52289 +
52290 +$(srcdir)/cat-id-tbl.c: stamp-cat-id; @:
52291 +$(srcdir)/stamp-cat-id: $(PACKAGE).pot
52292 + rm -f cat-id-tbl.tmp
52293 + sed -f ../intl/po2tbl.sed $(srcdir)/$(PACKAGE).pot \
52294 + | sed -e "s/@PACKAGE NAME@/$(PACKAGE)/" > cat-id-tbl.tmp
52295 + if cmp -s cat-id-tbl.tmp $(srcdir)/cat-id-tbl.c; then \
52296 + rm cat-id-tbl.tmp; \
52297 + else \
52298 + echo cat-id-tbl.c changed; \
52299 + rm -f $(srcdir)/cat-id-tbl.c; \
52300 + mv cat-id-tbl.tmp $(srcdir)/cat-id-tbl.c; \
52301 + fi
52302 + cd $(srcdir) && rm -f stamp-cat-id && echo timestamp > stamp-cat-id
52303 +
52304 +
52305 +install: install-exec install-data
52306 +install-exec:
52307 +install-info:
52308 +install-html:
52309 +install-data: install-data-yes
52310 +install-data-no: all
52311 +install-data-yes: all
52312 + if test -r $(MKINSTALLDIRS); then \
52313 + $(MKINSTALLDIRS) $(DESTDIR)$(datadir); \
52314 + else \
52315 + $(top_srcdir)/mkinstalldirs $(DESTDIR)$(datadir); \
52316 + fi
52317 + @catalogs='$(CATALOGS)'; \
52318 + for cat in $$catalogs; do \
52319 + cat=`basename $$cat`; \
52320 + case "$$cat" in \
52321 + *.gmo) destdir=$(gnulocaledir);; \
52322 + *) destdir=$(localedir);; \
52323 + esac; \
52324 + lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
52325 + dir=$(DESTDIR)$$destdir/$$lang/LC_MESSAGES; \
52326 + if test -r $(MKINSTALLDIRS); then \
52327 + $(MKINSTALLDIRS) $$dir; \
52328 + else \
52329 + $(top_srcdir)/mkinstalldirs $$dir; \
52330 + fi; \
52331 + if test -r $$cat; then \
52332 + $(INSTALL_DATA) $$cat $$dir/$(PACKAGE)$(INSTOBJEXT); \
52333 + echo "installing $$cat as $$dir/$(PACKAGE)$(INSTOBJEXT)"; \
52334 + else \
52335 + $(INSTALL_DATA) $(srcdir)/$$cat $$dir/$(PACKAGE)$(INSTOBJEXT); \
52336 + echo "installing $(srcdir)/$$cat as" \
52337 + "$$dir/$(PACKAGE)$(INSTOBJEXT)"; \
52338 + fi; \
52339 + if test -r $$cat.m; then \
52340 + $(INSTALL_DATA) $$cat.m $$dir/$(PACKAGE)$(INSTOBJEXT).m; \
52341 + echo "installing $$cat.m as $$dir/$(PACKAGE)$(INSTOBJEXT).m"; \
52342 + else \
52343 + if test -r $(srcdir)/$$cat.m ; then \
52344 + $(INSTALL_DATA) $(srcdir)/$$cat.m \
52345 + $$dir/$(PACKAGE)$(INSTOBJEXT).m; \
52346 + echo "installing $(srcdir)/$$cat as" \
52347 + "$$dir/$(PACKAGE)$(INSTOBJEXT).m"; \
52348 + else \
52349 + true; \
52350 + fi; \
52351 + fi; \
52352 + done
52353 + if test "$(PACKAGE)" = "gettext"; then \
52354 + if test -r $(MKINSTALLDIRS); then \
52355 + $(MKINSTALLDIRS) $(DESTDIR)$(gettextsrcdir); \
52356 + else \
52357 + $(top_srcdir)/mkinstalldirs $(DESTDIR)$(gettextsrcdir); \
52358 + fi; \
52359 + $(INSTALL_DATA) $(srcdir)/Makefile.in.in \
52360 + $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
52361 + else \
52362 + : ; \
52363 + fi
52364 +
52365 +# Define this as empty until I found a useful application.
52366 +installcheck:
52367 +
52368 +uninstall:
52369 + catalogs='$(CATALOGS)'; \
52370 + for cat in $$catalogs; do \
52371 + cat=`basename $$cat`; \
52372 + lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
52373 + rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
52374 + rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
52375 + rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
52376 + rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
52377 + done
52378 + rm -f $(DESTDIR)$(gettextsrcdir)/po-Makefile.in.in
52379 +
52380 +check: all
52381 +
52382 +cat-id-tbl.o: ../intl/libgettext.h
52383 +
52384 +html dvi pdf ps info tags TAGS ID:
52385 +
52386 +mostlyclean:
52387 + rm -f core core.* *.pox $(PACKAGE).po *.old.po cat-id-tbl.tmp
52388 + rm -fr *.o
52389 +
52390 +clean: mostlyclean
52391 +
52392 +distclean: clean
52393 + rm -f Makefile Makefile.in *.mo *.msg *.cat *.cat.m
52394 + rm -f SRC-POTFILES BLD-POTFILES
52395 +
52396 +maintainer-clean: distclean
52397 + @echo "This command is intended for maintainers to use;"
52398 + @echo "it deletes files that may require special tools to rebuild."
52399 + rm -f $(GMOFILES) SRC-POTFILES.in BLD-POTFILES.in
52400 +
52401 +distdir = ../$(PACKAGE)-$(VERSION)/$(subdir)
52402 +dist distdir: update-po $(DISTFILES)
52403 + dists="$(DISTFILES)"; \
52404 + for file in $$dists; do \
52405 + ln $(srcdir)/$$file $(distdir) 2> /dev/null \
52406 + || cp -p $(srcdir)/$$file $(distdir); \
52407 + done
52408 +
52409 +update-po: Makefile
52410 + $(MAKE) $(PACKAGE).pot
52411 + PATH=`pwd`/../src:$$PATH; \
52412 + cd $(srcdir); \
52413 + catalogs='$(CATALOGS)'; \
52414 + for cat in $$catalogs; do \
52415 + cat=`basename $$cat`; \
52416 + lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
52417 + mv $$lang.po $$lang.old.po; \
52418 + echo "$$lang:"; \
52419 + if $(MSGMERGE) $$lang.old.po $(PACKAGE).pot -o $$lang.po; then \
52420 + rm -f $$lang.old.po; \
52421 + else \
52422 + echo "msgmerge for $$cat failed!"; \
52423 + rm -f $$lang.po; \
52424 + mv $$lang.old.po $$lang.po; \
52425 + fi; \
52426 + done
52427 +
52428 +SRC-POTFILES: SRC-POTFILES.in
52429 + ( if test 'x$(srcdir)' != 'x.'; then \
52430 + posrcprefix='$(top_srcdir)/'; \
52431 + else \
52432 + posrcprefix="../"; \
52433 + fi; \
52434 + rm -f $@-t $@ \
52435 + && (sed -e '/^#/d' \
52436 + -e '/^[ ]*$$/d' \
52437 + -e "s@.*@ $$posrcprefix& \\\\@" < $(srcdir)/$@.in \
52438 + | sed -e '$$s/\\$$//') > $@-t \
52439 + && chmod a-w $@-t \
52440 + && mv $@-t $@ )
52441 +
52442 +BLD-POTFILES: BLD-POTFILES.in
52443 + ( rm -f $@-t $@ \
52444 + && (sed -e '/^#/d' \
52445 + -e '/^[ ]*$$/d' \
52446 + -e "s@.*@ ../& \\\\@" < $(srcdir)/$@.in \
52447 + | sed -e '$$s/\\$$//') > $@-t \
52448 + && chmod a-w $@-t \
52449 + && mv $@-t $@ )
52450 +
52451 +SRC-POTFILES.in: # ../Makefile
52452 + cd .. && $(MAKE) po/SRC-POTFILES.in
52453 +
52454 +BLD-POTFILES.in: # ../Makefile
52455 + cd .. && $(MAKE) po/BLD-POTFILES.in
52456 +
52457 +# Note - The presence of SRC-POTFILES and BLD-POTFILES as dependencies
52458 +# here breaks the implementation of the 'distclean' rule for maintainers.
52459 +# This is because if 'make distclean' is run in the BFD directory, the
52460 +# Makefile there will be deleted before 'distclean' is made here, and so
52461 +# the dependency SRC-POTFILES -> SRC-POTFILES.in -> ../Makefile cannot
52462 +# be satisfied.
52463 +#
52464 +# The SRC-POTFILES and BLD-POTFILES dependencies cannot be removed,
52465 +# however since it is necessary that these files be built during
52466 +# *configure* time, so that configure can insert them into the
52467 +# po/Makefile that it is creating, so that the Makefile will have
52468 +# the correct dependencies.
52469 +Makefile: Make-in ../config.status SRC-POTFILES BLD-POTFILES
52470 + cd .. \
52471 + && CONFIG_FILES=$(subdir)/Makefile.in:$(subdir)/Make-in \
52472 + CONFIG_HEADERS= $(SHELL) ./config.status
52473 +
52474 +# Tell versions [3.59,3.63) of GNU make not to export all variables.
52475 +# Otherwise a system limit (for SysV at least) may be exceeded.
52476 +.NOEXPORT:
52477 --- a/binutils/Makefile.in
52478 +++ b/binutils/Makefile.in
52479 @@ -1327,7 +1327,7 @@ readelf.o: readelf.c sysdep.h $(INCDIR)/
52480 $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h bucomm.h dwarf.h \
52481 $(INCDIR)/elf/common.h $(INCDIR)/elf/external.h $(INCDIR)/elf/internal.h \
52482 $(INCDIR)/elf/h8.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/elf/alpha.h \
52483 - $(INCDIR)/elf/arc.h $(INCDIR)/elf/arm.h $(INCDIR)/elf/avr.h \
52484 + $(INCDIR)/elf/arc.h $(INCDIR)/elf/arm.h $(INCDIR)/elf/avr.h $(INCDIR)/elf/avr32.h\
52485 $(INCDIR)/elf/bfin.h $(INCDIR)/elf/cris.h $(INCDIR)/elf/crx.h \
52486 $(INCDIR)/elf/d10v.h $(INCDIR)/elf/d30v.h $(INCDIR)/elf/dlx.h \
52487 $(INCDIR)/elf/fr30.h $(INCDIR)/elf/frv.h $(INCDIR)/elf/hppa.h \
52488 --- a/ld/Makefile.in
52489 +++ b/ld/Makefile.in
52490 @@ -384,7 +384,34 @@ ALL_EMULATIONS = \
52491 eavr3.o \
52492 eavr4.o \
52493 eavr5.o \
52494 - eavr6.o \
52495 + eavr6.o \
52496 + eavr32elf_ap7000.o \
52497 + eavr32elf_ap7001.o \
52498 + eavr32elf_ap7002.o \
52499 + eavr32elf_ap7200.o \
52500 + eavr32elf_uc3a0128.o \
52501 + eavr32elf_uc3a0256.o \
52502 + eavr32elf_uc3a0512.o \
52503 + eavr32elf_uc3a0512es.o \
52504 + eavr32elf_uc3a1128.o \
52505 + eavr32elf_uc3a1256.o \
52506 + eavr32elf_uc3a1512es.o \
52507 + eavr32elf_uc3a1512.o \
52508 + eavr32elf_uc3a364.o \
52509 + eavr32elf_uc3a364s.o \
52510 + eavr32elf_uc3a3128.o \
52511 + eavr32elf_uc3a3128s.o \
52512 + eavr32elf_uc3a3256.o \
52513 + eavr32elf_uc3a3256s.o \
52514 + eavr32elf_uc3b064.o \
52515 + eavr32elf_uc3b0128.o \
52516 + eavr32elf_uc3b0256es.o \
52517 + eavr32elf_uc3b0256.o \
52518 + eavr32elf_uc3b164.o \
52519 + eavr32elf_uc3b1128.o \
52520 + eavr32elf_uc3b1256es.o \
52521 + eavr32elf_uc3b1256.o \
52522 + eavr32linux.o \
52523 ecoff_i860.o \
52524 ecoff_sparc.o \
52525 eelf32_spu.o \
52526 @@ -1448,6 +1475,114 @@ eavr6.c: $(srcdir)/emulparams/avr6.sh $(
52527 $(ELF_DEPS) $(srcdir)/scripttempl/avr.sc \
52528 ${GEN_DEPENDS}
52529 ${GENSCRIPTS} avr6 "$(tdir_avr2)"
52530 +eavr32elf_ap7000.c: $(srcdir)/emulparams/avr32elf.sh \
52531 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52532 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52533 + ${GENSCRIPTS} avr32elf_ap7000 "$(tdir_avr32)" avr32elf
52534 +eavr32elf_ap7001.c: $(srcdir)/emulparams/avr32elf.sh \
52535 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52536 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52537 + ${GENSCRIPTS} avr32elf_ap7001 "$(tdir_avr32)" avr32elf
52538 +eavr32elf_ap7002.c: $(srcdir)/emulparams/avr32elf.sh \
52539 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52540 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52541 + ${GENSCRIPTS} avr32elf_ap7002 "$(tdir_avr32)" avr32elf
52542 +eavr32elf_ap7200.c: $(srcdir)/emulparams/avr32elf.sh \
52543 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52544 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52545 + ${GENSCRIPTS} avr32elf_ap7200 "$(tdir_avr32)" avr32elf
52546 +eavr32elf_uc3a0128.c: $(srcdir)/emulparams/avr32elf.sh \
52547 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52548 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52549 + ${GENSCRIPTS} avr32elf_uc3a0128 "$(tdir_avr32)" avr32elf
52550 +eavr32elf_uc3a0256.c: $(srcdir)/emulparams/avr32elf.sh \
52551 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52552 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52553 + ${GENSCRIPTS} avr32elf_uc3a0256 "$(tdir_avr32)" avr32elf
52554 +eavr32elf_uc3a0512.c: $(srcdir)/emulparams/avr32elf.sh \
52555 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52556 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52557 + ${GENSCRIPTS} avr32elf_uc3a0512 "$(tdir_avr32)" avr32elf
52558 +eavr32elf_uc3a0512es.c: $(srcdir)/emulparams/avr32elf.sh \
52559 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52560 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52561 + ${GENSCRIPTS} avr32elf_uc3a0512es "$(tdir_avr32)" avr32elf
52562 +eavr32elf_uc3a1128.c: $(srcdir)/emulparams/avr32elf.sh \
52563 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52564 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52565 + ${GENSCRIPTS} avr32elf_uc3a1128 "$(tdir_avr32)" avr32elf
52566 +eavr32elf_uc3a1256.c: $(srcdir)/emulparams/avr32elf.sh \
52567 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52568 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52569 + ${GENSCRIPTS} avr32elf_uc3a1256 "$(tdir_avr32)" avr32elf
52570 +eavr32elf_uc3a1512.c: $(srcdir)/emulparams/avr32elf.sh \
52571 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52572 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52573 + ${GENSCRIPTS} avr32elf_uc3a1512 "$(tdir_avr32)" avr32elf
52574 +eavr32elf_uc3a1512es.c: $(srcdir)/emulparams/avr32elf.sh \
52575 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52576 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52577 + ${GENSCRIPTS} avr32elf_uc3a1512es "$(tdir_avr32)" avr32elf
52578 +eavr32elf_uc3a364.c: $(srcdir)/emulparams/avr32elf.sh \
52579 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52580 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52581 + ${GENSCRIPTS} avr32elf_uc3a364 "$(tdir_avr32)" avr32elf
52582 +eavr32elf_uc3a364s.c: $(srcdir)/emulparams/avr32elf.sh \
52583 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52584 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52585 + ${GENSCRIPTS} avr32elf_uc3a364s "$(tdir_avr32)" avr32elf
52586 +eavr32elf_uc3a3128.c: $(srcdir)/emulparams/avr32elf.sh \
52587 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52588 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52589 + ${GENSCRIPTS} avr32elf_uc3a3128 "$(tdir_avr32)" avr32elf
52590 +eavr32elf_uc3a3128s.c: $(srcdir)/emulparams/avr32elf.sh \
52591 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52592 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52593 + ${GENSCRIPTS} avr32elf_uc3a3128s "$(tdir_avr32)" avr32elf
52594 +eavr32elf_uc3a3256.c: $(srcdir)/emulparams/avr32elf.sh \
52595 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52596 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52597 + ${GENSCRIPTS} avr32elf_uc3a3256 "$(tdir_avr32)" avr32elf
52598 +eavr32elf_uc3a3256s.c: $(srcdir)/emulparams/avr32elf.sh \
52599 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52600 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52601 + ${GENSCRIPTS} avr32elf_uc3a3256s "$(tdir_avr32)" avr32elf
52602 +eavr32elf_uc3b064.c: $(srcdir)/emulparams/avr32elf.sh \
52603 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52604 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52605 + ${GENSCRIPTS} avr32elf_uc3b064 "$(tdir_avr32)" avr32elf
52606 +eavr32elf_uc3b0128.c: $(srcdir)/emulparams/avr32elf.sh \
52607 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52608 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52609 + ${GENSCRIPTS} avr32elf_uc3b0128 "$(tdir_avr32)" avr32elf
52610 +eavr32elf_uc3b0256.c: $(srcdir)/emulparams/avr32elf.sh \
52611 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52612 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52613 + ${GENSCRIPTS} avr32elf_uc3b0256 "$(tdir_avr32)" avr32elf
52614 +eavr32elf_uc3b0256es.c: $(srcdir)/emulparams/avr32elf.sh \
52615 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52616 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52617 + ${GENSCRIPTS} avr32elf_uc3b0256es "$(tdir_avr32)" avr32elf
52618 +eavr32elf_uc3b164.c: $(srcdir)/emulparams/avr32elf.sh \
52619 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52620 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52621 + ${GENSCRIPTS} avr32elf_uc3b164 "$(tdir_avr32)" avr32elf
52622 +eavr32elf_uc3b1128.c: $(srcdir)/emulparams/avr32elf.sh \
52623 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52624 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52625 + ${GENSCRIPTS} avr32elf_uc3b1128 "$(tdir_avr32)" avr32elf
52626 +eavr32elf_uc3b1256.c: $(srcdir)/emulparams/avr32elf.sh \
52627 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52628 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52629 + ${GENSCRIPTS} avr32elf_uc3b1256 "$(tdir_avr32)" avr32elf
52630 +eavr32elf_uc3b1256es.c: $(srcdir)/emulparams/avr32elf.sh \
52631 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52632 + $(srcdir)/scripttempl/elf_xip.sc ${GEN_DEPENDS}
52633 + ${GENSCRIPTS} avr32elf_uc3b1256es "$(tdir_avr32)" avr32elf
52634 +eavr32linux.c: $(srcdir)/emulparams/avr32linux.sh \
52635 + $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/avr32elf.em \
52636 + $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
52637 + ${GENSCRIPTS} avr32linux "$(tdir_avr32)"
52638 ecoff_i860.c: $(srcdir)/emulparams/coff_i860.sh \
52639 $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/i860coff.sc ${GEN_DEPENDS}
52640 ${GENSCRIPTS} coff_i860 "$(tdir_coff_i860)"
52641 @@ -2679,7 +2814,9 @@ install-exec-local: ld-new$(EXEEXT)
52642 || $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) ld-new$(EXEEXT) $(DESTDIR)$(tooldir)/bin/ld$(EXEEXT); \
52643 fi
52644
52645 -install-data-local:
52646 +# We want install to imply install-info as per GNU standards, despite the
52647 +# cygnus option.
52648 +install-data-local: install-info
52649 $(mkinstalldirs) $(DESTDIR)$(scriptdir)/ldscripts
52650 for f in ldscripts/*; do \
52651 $(INSTALL_DATA) $$f $(DESTDIR)$(scriptdir)/$$f ; \
52652 --- /dev/null
52653 +++ b/libiberty/required-list
52654 @@ -0,0 +1 @@
52655 +./regex.o ./cplus-dem.o ./cp-demangle.o ./md5.o ./alloca.o ./argv.o ./choose-temp.o ./concat.o ./cp-demint.o ./dyn-string.o ./fdmatch.o ./fibheap.o ./filename_cmp.o ./floatformat.o ./fnmatch.o ./fopen_unlocked.o ./getopt.o ./getopt1.o ./getpwd.o ./getruntime.o ./hashtab.o ./hex.o ./lbasename.o ./lrealpath.o ./make-relative-prefix.o ./make-temp-file.o ./objalloc.o ./obstack.o ./partition.o ./pexecute.o ./physmem.o ./pex-common.o ./pex-one.o ./pex-unix.o ./safe-ctype.o ./sort.o ./spaces.o ./splay-tree.o ./strerror.o ./strsignal.o ./unlink-if-ordinary.o ./xatexit.o ./xexit.o ./xmalloc.o ./xmemdup.o ./xstrdup.o ./xstrerror.o ./xstrndup.o
52656 --- a/opcodes/configure
52657 +++ b/opcodes/configure
52658 @@ -11418,6 +11418,7 @@ if test x${all_targets} = xfalse ; then
52659 bfd_arc_arch) ta="$ta arc-dis.lo arc-opc.lo arc-ext.lo" ;;
52660 bfd_arm_arch) ta="$ta arm-dis.lo" ;;
52661 bfd_avr_arch) ta="$ta avr-dis.lo" ;;
52662 + bfd_avr32_arch) ta="$ta avr32-asm.lo avr32-dis.lo avr32-opc.lo" ;;
52663 bfd_bfin_arch) ta="$ta bfin-dis.lo" ;;
52664 bfd_cr16_arch) ta="$ta cr16-dis.lo cr16-opc.lo" ;;
52665 bfd_cris_arch) ta="$ta cris-dis.lo cris-opc.lo cgen-bitset.lo" ;;
52666 @@ -11476,7 +11477,7 @@ if test x${all_targets} = xfalse ; then
52667 ta="$ta sh64-dis.lo sh64-opc.lo"
52668 archdefs="$archdefs -DINCLUDE_SHMEDIA"
52669 break;;
52670 - esac;
52671 + esac
52672 done
52673 ta="$ta sh-dis.lo cgen-bitset.lo" ;;
52674 bfd_sparc_arch) ta="$ta sparc-dis.lo sparc-opc.lo" ;;
52675 --- a/opcodes/Makefile.in
52676 +++ b/opcodes/Makefile.in
52677 @@ -257,6 +257,7 @@ LIBIBERTY = ../libiberty/libiberty.a
52678 # Header files.
52679 HFILES = \
52680 cgen-ops.h cgen-types.h \
52681 + avr32-asm.h avr32-opc.h \
52682 fr30-desc.h fr30-opc.h \
52683 frv-desc.h frv-opc.h \
52684 h8500-opc.h \
52685 @@ -291,6 +292,9 @@ CFILES = \
52686 arc-ext.c \
52687 arm-dis.c \
52688 avr-dis.c \
52689 + avr32-asm.c \
52690 + avr32-dis.c \
52691 + avr32-opc.c \
52692 bfin-dis.c \
52693 cgen-asm.c \
52694 cgen-bitset.c \
52695 @@ -445,6 +449,9 @@ ALL_MACHINES = \
52696 arc-ext.lo \
52697 arm-dis.lo \
52698 avr-dis.lo \
52699 + avr32-asm.lo \
52700 + avr32-dis.lo \
52701 + avr32-opc.lo \
52702 bfin-dis.lo \
52703 cgen-asm.lo \
52704 cgen-bitset.lo \
52705 @@ -1225,6 +1232,15 @@ avr-dis.lo: avr-dis.c sysdep.h config.h
52706 $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
52707 opintl.h $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
52708 $(INCDIR)/opcode/avr.h
52709 +avr32-asm.lo: avr32-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
52710 + $(BFD_H) $(INCDIR)/symcat.h avr32-opc.h opintl.h \
52711 + $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
52712 + $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
52713 +avr32-dis.lo: avr32-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
52714 + $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
52715 + avr32-opc.h opintl.h
52716 +avr32-opc.lo: avr32-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
52717 + $(BFD_H) $(INCDIR)/symcat.h avr32-opc.h $(INCDIR)/libiberty.h
52718 bfin-dis.lo: bfin-dis.c $(INCDIR)/opcode/bfin.h $(INCDIR)/dis-asm.h \
52719 $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h
52720 cgen-asm.lo: cgen-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
This page took 2.349628 seconds and 5 git commands to generate.