filename | src/x86dasm/x86dasm.h |
changeset | 1091:186558374345 |
prev | 968:6fb1481859a4 |
next | 1094:d2324eb67223 |
author | nkeynes |
date | Tue Dec 15 08:46:37 2009 +1000 (14 years ago) |
permissions | -rw-r--r-- |
last change | Add side-by-side x86+sh4 disassembly output Print SH4 state information and disassembly of the current block when crashing. Fix delay slot instruction in conditional branch not being marked as a delay-slot instruction in the branch-not-taken path. Rename REG_* defines in cpu.h to avoid conflict with translation defs |
file | annotate | diff | log | raw |
nkeynes@362 | 1 | /** |
nkeynes@561 | 2 | * $Id$ |
nkeynes@362 | 3 | * |
nkeynes@362 | 4 | * Wrapper around i386-dis to supply the same behaviour as the other |
nkeynes@362 | 5 | * disassembly functions. |
nkeynes@362 | 6 | * |
nkeynes@362 | 7 | * Copyright (c) 2005 Nathan Keynes. |
nkeynes@362 | 8 | * |
nkeynes@362 | 9 | * This program is free software; you can redistribute it and/or modify |
nkeynes@362 | 10 | * it under the terms of the GNU General Public License as published by |
nkeynes@362 | 11 | * the Free Software Foundation; either version 2 of the License, or |
nkeynes@362 | 12 | * (at your option) any later version. |
nkeynes@362 | 13 | * |
nkeynes@362 | 14 | * This program is distributed in the hope that it will be useful, |
nkeynes@362 | 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
nkeynes@362 | 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
nkeynes@362 | 17 | * GNU General Public License for more details. |
nkeynes@362 | 18 | */ |
nkeynes@362 | 19 | |
nkeynes@476 | 20 | #include <stdio.h> |
nkeynes@362 | 21 | #include "cpu.h" |
nkeynes@362 | 22 | #include "mem.h" |
nkeynes@362 | 23 | extern const struct cpu_desc_struct x86_cpu_desc; |
nkeynes@362 | 24 | |
nkeynes@365 | 25 | typedef struct x86_symbol { |
nkeynes@365 | 26 | const char *name; |
nkeynes@365 | 27 | void *ptr; |
nkeynes@365 | 28 | } x86_symbol; |
nkeynes@365 | 29 | |
nkeynes@376 | 30 | void x86_disasm_block( FILE *out, void *block, uint32_t len ); |
nkeynes@365 | 31 | void x86_set_symtab( x86_symbol *symtab, int num_symbols ); |
nkeynes@1091 | 32 | void x86_disasm_init(); |
nkeynes@925 | 33 | uintptr_t x86_disasm_instruction( uintptr_t pc, char *buf, int len, char *opcode ); |
nkeynes@968 | 34 | void x86_print_symbolic_operand( char *buf, int hex, unsigned int disp ); |
.