1 /* Select disassembly routine for specified architecture.
2 Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
3 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
72 enum bfd_architecture a = bfd_get_arch (abfd);
73 disassembler_ftype disassemble;
77 /* If you add a case to this table, also add it to the
78 ARCH_all definition right above this function. */
81 /* As far as I know we only handle big-endian 29k objects. */
82 disassemble = print_insn_big_a29k;
87 disassemble = print_insn_alpha;
93 disassemble = arc_get_disassembler (abfd);
99 if (bfd_big_endian (abfd))
100 disassemble = print_insn_big_arm;
102 disassemble = print_insn_little_arm;
107 disassemble = print_insn_avr;
112 disassemble = cris_get_disassembler (abfd);
117 disassemble = print_insn_d10v;
122 disassemble = print_insn_d30v;
127 if (bfd_get_mach(abfd) == bfd_mach_h8300h)
128 disassemble = print_insn_h8300h;
129 else if (bfd_get_mach(abfd) == bfd_mach_h8300s)
130 disassemble = print_insn_h8300s;
132 disassemble = print_insn_h8300;
137 disassemble = print_insn_h8500;
142 disassemble = print_insn_hppa;
147 disassemble = print_insn_i370;
152 if (bfd_get_mach (abfd) == bfd_mach_i386_i386_intel_syntax
153 || bfd_get_mach (abfd) == bfd_mach_x86_64_intel_syntax)
154 disassemble = print_insn_i386_intel;
156 disassemble = print_insn_i386_att;
161 disassemble = print_insn_i860;
166 disassemble = print_insn_i960;
171 disassemble = print_insn_ia64;
176 disassemble = print_insn_fr30;
181 disassemble = print_insn_m32r;
184 #if defined(ARCH_m68hc11) || defined(ARCH_m68hc12)
185 case bfd_arch_m68hc11:
186 disassemble = print_insn_m68hc11;
188 case bfd_arch_m68hc12:
189 disassemble = print_insn_m68hc12;
194 disassemble = print_insn_m68k;
199 disassemble = print_insn_m88k;
204 disassemble = print_insn_ns32k;
209 disassemble = print_insn_mcore;
214 if (bfd_big_endian (abfd))
215 disassemble = print_insn_big_mips;
217 disassemble = print_insn_little_mips;
221 case bfd_arch_mn10200:
222 disassemble = print_insn_mn10200;
226 case bfd_arch_mn10300:
227 disassemble = print_insn_mn10300;
231 case bfd_arch_openrisc:
232 disassemble = print_insn_openrisc;
237 disassemble = print_insn_pdp11;
242 disassemble = print_insn_pj;
246 case bfd_arch_powerpc:
247 if (bfd_big_endian (abfd))
248 disassemble = print_insn_big_powerpc;
250 disassemble = print_insn_little_powerpc;
254 case bfd_arch_rs6000:
255 if (bfd_get_mach (abfd) == bfd_mach_ppc_620)
256 disassemble = print_insn_big_powerpc;
258 disassemble = print_insn_rs6000;
263 disassemble = print_insn_s390;
268 if (bfd_big_endian (abfd))
269 disassemble = print_insn_sh;
271 disassemble = print_insn_shl;
276 disassemble = print_insn_sparc;
281 disassemble = print_insn_tic30;
285 case bfd_arch_tic54x:
286 disassemble = print_insn_tic54x;
291 disassemble = print_insn_tic80;
296 disassemble = print_insn_v850;
301 disassemble = print_insn_w65;
306 if (bfd_get_mach(abfd) == bfd_mach_z8001)
307 disassemble = print_insn_z8001;
309 disassemble = print_insn_z8002;
314 disassemble = print_insn_vax;
324 disassembler_usage (stream)
325 FILE * stream ATTRIBUTE_UNUSED;
328 print_arm_disassembler_options (stream);