[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Re: [PATCH v5 18/18] gdbstub: x86: Switch 64/32 bit reg

From: Jan Kiszka
Subject: Re: [Qemu-devel] Re: [PATCH v5 18/18] gdbstub: x86: Switch 64/32 bit registers dynamically
Date: Wed, 19 Nov 2008 00:07:39 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); de; rv: Gecko/20080226 SUSE/ Thunderbird/ Mnenhy/

Paul Brook wrote:
>> The best approach, definitely, would be to teach GDB how to switch the
>> disassembler mode depending on the thread's (or VCPUs) state. But so
>> there is neither a mechanism in GDB for this, nor is GDB even aware of
>> the x86 modes (no tracking of privileged registers). We have some
>> preliminary patches for this, but they are still far away from GDB
>> mainline.
> I'm pretty sure all the infrastructure is there. gdb is able to natively 
> debug 
> 32-bit binaries on a 64-bit host and is able to switch disassembler modes for 
> ARM vs. Thumb.

How is it done on ARM? Maybe that will provide the right pointer for x86.

For fun I recently tried to debug a 32-bit binary on a 64-bit host via
gdbserver - the fun ended as quickly as with qemu. The only way for
switching disassembly mode on x86 that I found is via set arch, and that
switching the register packet format as well.


Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]