On Thu, Mar 15, 2012 at 10:32:36PM +1030, Alan Modra wrote:
> The middle of print_insn_powerpc should then look like
[snip]
As suggested, this splits out the opcode lookup, and makes some
further tweaks that speed up powerpc disassembly a few percent.
* ppc-dis.c (PPC_OPC_SEGS, PPC_OP_TO_SEG): Delete.
(powerpc_opcd_indices): Bump array size.
(disassemble_init_powerpc): Set powerpc_opcd_indices entries
corresponding to unused opcodes to following entry.
(lookup_powerpc): New function, extracted and optimised from..
(print_insn_powerpc): ..here.