1 /* Select disassembly routine for specified architecture.
2 Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
3 2004, 2005 Free Software Foundation, Inc.
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */
76 #define ARCH_xstormy16
81 #define INCLUDE_SHMEDIA
85 #include "m32c-desc.h"
92 enum bfd_architecture a = bfd_get_arch (abfd);
93 disassembler_ftype disassemble;
97 /* If you add a case to this table, also add it to the
98 ARCH_all definition right above this function. */
101 disassemble = print_insn_alpha;
107 disassemble = arc_get_disassembler (abfd);
113 if (bfd_big_endian (abfd))
114 disassemble = print_insn_big_arm;
116 disassemble = print_insn_little_arm;
121 disassemble = print_insn_avr;
126 disassemble = print_insn_bfin;
131 disassemble = cris_get_disassembler (abfd);
136 disassemble = print_insn_crx;
141 disassemble = print_insn_d10v;
146 disassemble = print_insn_d30v;
151 /* As far as I know we only handle big-endian DLX objects. */
152 disassemble = print_insn_dlx;
157 if (bfd_get_mach (abfd) == bfd_mach_h8300h
158 || bfd_get_mach (abfd) == bfd_mach_h8300hn)
159 disassemble = print_insn_h8300h;
160 else if (bfd_get_mach (abfd) == bfd_mach_h8300s
161 || bfd_get_mach (abfd) == bfd_mach_h8300sn
162 || bfd_get_mach (abfd) == bfd_mach_h8300sx
163 || bfd_get_mach (abfd) == bfd_mach_h8300sxn)
164 disassemble = print_insn_h8300s;
166 disassemble = print_insn_h8300;
171 disassemble = print_insn_h8500;
176 disassemble = print_insn_hppa;
181 disassemble = print_insn_i370;
186 disassemble = print_insn_i386;
191 disassemble = print_insn_i860;
196 disassemble = print_insn_i960;
201 disassemble = print_insn_ia64;
206 disassemble = print_insn_ip2k;
211 disassemble = print_insn_fr30;
216 disassemble = print_insn_m32r;
219 #if defined(ARCH_m68hc11) || defined(ARCH_m68hc12)
220 case bfd_arch_m68hc11:
221 disassemble = print_insn_m68hc11;
223 case bfd_arch_m68hc12:
224 disassemble = print_insn_m68hc12;
229 disassemble = print_insn_m68k;
234 disassemble = print_insn_m88k;
239 disassemble = print_insn_maxq_little;
244 disassemble = print_insn_mt;
248 case bfd_arch_msp430:
249 disassemble = print_insn_msp430;
254 disassemble = print_insn_ns32k;
259 disassemble = print_insn_mcore;
264 if (bfd_big_endian (abfd))
265 disassemble = print_insn_big_mips;
267 disassemble = print_insn_little_mips;
272 disassemble = print_insn_mmix;
276 case bfd_arch_mn10200:
277 disassemble = print_insn_mn10200;
281 case bfd_arch_mn10300:
282 disassemble = print_insn_mn10300;
286 case bfd_arch_openrisc:
287 disassemble = print_insn_openrisc;
292 if (bfd_big_endian (abfd))
293 disassemble = print_insn_big_or32;
295 disassemble = print_insn_little_or32;
300 disassemble = print_insn_pdp11;
305 disassemble = print_insn_pj;
309 case bfd_arch_powerpc:
310 if (bfd_big_endian (abfd))
311 disassemble = print_insn_big_powerpc;
313 disassemble = print_insn_little_powerpc;
317 case bfd_arch_rs6000:
318 if (bfd_get_mach (abfd) == bfd_mach_ppc_620)
319 disassemble = print_insn_big_powerpc;
321 disassemble = print_insn_rs6000;
326 disassemble = print_insn_s390;
331 disassemble = print_insn_sh;
336 disassemble = print_insn_sparc;
341 disassemble = print_insn_tic30;
346 disassemble = print_insn_tic4x;
350 case bfd_arch_tic54x:
351 disassemble = print_insn_tic54x;
356 disassemble = print_insn_tic80;
361 disassemble = print_insn_v850;
366 disassemble = print_insn_w65;
369 #ifdef ARCH_xstormy16
370 case bfd_arch_xstormy16:
371 disassemble = print_insn_xstormy16;
376 disassemble = print_insn_xc16x;
380 case bfd_arch_xtensa:
381 disassemble = print_insn_xtensa;
386 disassemble = print_insn_z80;
391 if (bfd_get_mach(abfd) == bfd_mach_z8001)
392 disassemble = print_insn_z8001;
394 disassemble = print_insn_z8002;
399 disassemble = print_insn_vax;
404 disassemble = print_insn_frv;
408 case bfd_arch_iq2000:
409 disassemble = print_insn_iq2000;
414 disassemble = print_insn_m32c;
424 disassembler_usage (stream)
425 FILE * stream ATTRIBUTE_UNUSED;
428 print_arm_disassembler_options (stream);
431 print_mips_disassembler_options (stream);
434 print_ppc_disassembler_options (stream);
441 disassemble_init_for_target (struct disassemble_info * info)
450 info->symbol_is_valid = arm_symbol_is_valid;
451 info->disassembler_needs_relocs = TRUE;
456 info->skip_zeroes = 16;
461 info->skip_zeroes = 32;
466 info->endian = BFD_ENDIAN_BIG;
467 if (! info->insn_sets)
469 info->insn_sets = cgen_bitset_create (ISA_MAX);
470 if (info->mach == bfd_mach_m16c)
471 cgen_bitset_set (info->insn_sets, ISA_M16C);
473 cgen_bitset_set (info->insn_sets, ISA_M32C);