From: Jan Kiszka <jan.kiszka@web.de>
To: Paul Brook <paul@codesourcery.com>
Cc: Andreas Schultz <aschultz@warp10.net>,
qemu-devel@nongnu.org, kvm@vger.kernel.org
Subject: Re: [Qemu-devel] Re: gdbstub: packet reply is too long
Date: Sun, 21 Dec 2008 00:44:04 +0100 [thread overview]
Message-ID: <494D8344.8010203@web.de> (raw)
In-Reply-To: <200812202246.39036.paul@codesourcery.com>
[-- Attachment #1: Type: text/plain, Size: 2167 bytes --]
Paul Brook wrote:
>> Do those archs also have multiple register layouts that are coupled to
>> those different instruction sets? Do they switch the instruction sets
>> via 'set arch'?
>
> No, but neither does x86. You just need to teach gdb how to debug 32-bit code
> on a 64-bit target.
And that means setting current_gdbarch while keeping target_gdbarch -
that's where reality (existing gdb code) bites us. Again, I'm not
arguing against fixing this, I'm arguing in keeping qemu's workaround
until this is done. I will look into the gdb part, but one after the other.
>
>> I think x86 is (historically) special here.
>
> I think it's just that noone's made the effort to fix this problem.
>
>> Fixing this (once understood what are all the problems preventing a fix
>> for several years now) is one thing, keeping the workaround for current
>> gdb in qemu is, IMHO, another. Right now we don't have a gdb fix in
>> sight, so I'm simply voting for reintroducing the workaround. That's
>> all. We can kill it or make it optional once the issue is solved. But we
>> should _not_ do this _before_ it is solved, causing only pain to people
>> who just want to use the gdbstub.
>
> I don't buy this argument. You already have to tell gdb which mode to work in,
> so I don't see any reason why you shouldn't also tell qemu.
Sorry, this doesn't parse for me. What mechanism for qemu do you have in
mind precisely?
However, do we agree now that we have to adopt qemu to make it work with
current gdb?
>
> Recent GDB interrogate the target when they connect, and the target describes
> the registers it has. This isn't currently implemented on x86 in qemu, but
> I'm pretty sure it'd be incompatible with dynamic switching.
I haven't checked gdb /wrt this protocol and x86 in details yet. But as
far as I understand it, it does negotiation during startup. I wouldn't
be surprised that all what the backend told gdb becomes pointless once
you type "set arch i386". But this seems to be an orthogonal issue. Of
course, we would have to communicate x86-64 capabilities this way, not
the mode-dependent set.
Jan
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 257 bytes --]
next prev parent reply other threads:[~2008-12-20 23:45 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1229776952.22890.2.camel@ws-aschultz>
2008-12-20 15:49 ` [Qemu-devel] Re: gdbstub: packet reply is too long Jan Kiszka
2008-12-20 20:35 ` Paul Brook
2008-12-20 21:00 ` Jan Kiszka
2008-12-20 21:03 ` Paul Brook
2008-12-20 21:22 ` Jan Kiszka
2008-12-20 21:34 ` Paul Brook
2008-12-20 21:55 ` Jan Kiszka
2008-12-20 22:08 ` Paul Brook
2008-12-20 22:34 ` Jan Kiszka
2008-12-20 22:46 ` Paul Brook
2008-12-20 23:44 ` Jan Kiszka [this message]
2008-12-26 23:30 ` Daniel Jacobowitz
2008-12-29 14:58 ` Jan Kiszka
2008-12-30 22:43 ` Daniel Jacobowitz
2009-01-02 12:53 ` Jan Kiszka
2009-01-03 1:53 ` Jamie Lokier
2009-01-04 13:50 ` Jan Kiszka
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=494D8344.8010203@web.de \
--to=jan.kiszka@web.de \
--cc=aschultz@warp10.net \
--cc=kvm@vger.kernel.org \
--cc=paul@codesourcery.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).