diff options
author | José Fonseca <[email protected]> | 2009-08-18 10:28:37 +0100 |
---|---|---|
committer | José Fonseca <[email protected]> | 2009-08-29 09:21:33 +0100 |
commit | ee066eaf6d0dd3c771dc3e37390f3665e747af2a (patch) | |
tree | 20fd78fbc8edc943a3c361c47cdadf31e3354c53 /src | |
parent | c5abcac7ef7ebd0167093285b5fc9cf3829c1feb (diff) |
llvmpipe: Allow to dump the disassembly byte code.
Useful as dis86 doesn't disassemble some SSE4 opcodes yet.
Diffstat (limited to 'src')
-rw-r--r-- | src/gallium/drivers/llvmpipe/lp_bld_debug.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_bld_debug.c b/src/gallium/drivers/llvmpipe/lp_bld_debug.c index 49a6065a8cd..f8da1c9f8e7 100644 --- a/src/gallium/drivers/llvmpipe/lp_bld_debug.c +++ b/src/gallium/drivers/llvmpipe/lp_bld_debug.c @@ -53,16 +53,18 @@ lp_disassemble(const void* func) while (ud_disassemble(&ud_obj)) { #ifdef PIPE_ARCH_X86 - debug_printf("%08lx:\t%s\n", - (unsigned long)ud_insn_off(&ud_obj), - ud_insn_asm(&ud_obj)); + debug_printf("%08lx: ", (unsigned long)ud_insn_off(&ud_obj)); #endif #ifdef PIPE_ARCH_X86_64 - debug_printf("%016llx:\t%s\n", - (unsigned long long)ud_insn_off(&ud_obj), - ud_insn_asm(&ud_obj)); + debug_printf("%016llx: ", (unsigned long long)ud_insn_off(&ud_obj)); #endif +#if 0 + debug_printf("%-16s ", ud_insn_hex(&ud_obj)); +#endif + + debug_printf("%s\n", ud_insn_asm(&ud_obj)); + if (ud_obj.mnemonic == UD_Iret) break; } |