From: Andrew Cagney <ac131313@redhat.com>
To: Daniel Jacobowitz <drow@mvista.com>
Cc: Mark Kettenis <kettenis@chello.nl>, gdb@sources.redhat.com
Subject: Re: [RFC] Register sets
Date: Tue, 09 Sep 2003 04:21:00 -0000 [thread overview]
Message-ID: <3F5D553E.90607@redhat.com> (raw)
In-Reply-To: <20030905231517.GA17046@nevyn.them.org>
> On Thu, Sep 04, 2003 at 06:59:06PM -0400, Andrew Cagney wrote:
>
>>
>
>> > I'd really rather not enforce that - remote can provide regsets that
>> > BFD doesn't know about, and the ".reg" names would look silly being
>> > defined as part of the remote protocol. My instinct says that the
>> > flexibility is worthwhile so that the two implementation details don't
>> > become coupled.
>> >
>> >I'm with Daniel here. For most OS'es the corefile format isn't under
>> >our control, and some of these formats simply don't make too much
>> >sense. We shouldn't be forced to use those in the remote protocol.
>> >And I don't think BFD should do a transformation on the corefile data
>> >when it turns the register data into a section.
>
>>
>> ... but here there is no suggestion that BFD should transform the
>> corefile data when it is turned into register data, in fact the oposite
>> is true. The intent is for just GDB to know how to pack/unpack these
>> regsets and then have BFD, proc, ptrace and the remote target all xfer
>> uninterpreted bytes. The natural format for those uninterpreted bytes
>> is what ever is specified by the system being debugged.
>
>
> Eh?
>
> The remote protocol is fixed. The core file format is fixed. The
> /proc output format is fixed. They aren't all the same, so I don't
> see what this unity would accomplish - they have to be translated
> around anyway.
I wrote:
> ... but here there is no suggestion that BFD should transform the
>> corefile data when it is turned into register data, in fact the oposite
>> is true. The intent is for just GDB to know how to pack/unpack these
>> regsets and then have BFD, proc, ptrace and the remote target all xfer
>> uninterpreted bytes. The natural format for those uninterpreted bytes
>> is what ever is specified by the system being debugged.
The translation would only need to be done once. As they say, keep it
simple.
>> This would let gdbserver thin down to the point where it only needed to
>> know how to xfer those raw bytes - no need to repack them into a
>> standard G packet.
>>
>> Of course a heavy weight gdbserver could also use this regset code to
>> repack bits into G and other packets before shipping them back to GDB.
>
>
> The lighter-weight version isn't of much interest now - a number of
> other issues have convinced me that lightening the stub further isn't
> the way to go.
The remote protocol has had a long standing conflict between two
different register abstractions:
- the G model - things are just a large raw buffer
- the P model - registers can be individually identified
Truth is, both can and should be accomodated:
- fat stubs that can chat to gdb in terms of specific register numbers
- thin stubs that can just transfer the raw buffer (or part there of)
Trying to select one over the other has been a mistake - they are both
correct and equally valid.
Andrew
next prev parent reply other threads:[~2003-09-09 4:21 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-08-23 22:50 Mark Kettenis
2003-08-24 16:43 ` Daniel Jacobowitz
2003-08-25 22:35 ` Mark Kettenis
2003-08-26 15:49 ` Andrew Cagney
2003-08-26 16:55 ` Daniel Jacobowitz
2003-08-27 3:50 ` Andrew Cagney
2003-08-31 14:04 ` Mark Kettenis
2003-09-02 18:40 ` Andrew Cagney
2003-09-04 21:31 ` Mark Kettenis
2003-09-04 12:55 ` Daniel Jacobowitz
2003-09-04 14:00 ` Andrew Cagney
2003-09-04 14:08 ` Daniel Jacobowitz
2003-09-04 15:04 ` Andrew Cagney
2003-09-04 15:13 ` Daniel Jacobowitz
2003-09-04 22:07 ` Mark Kettenis
2003-09-04 22:05 ` Mark Kettenis
2003-09-04 22:16 ` Andrew Cagney
2003-09-04 22:59 ` Andrew Cagney
2003-09-05 23:15 ` Daniel Jacobowitz
2003-09-09 4:21 ` Andrew Cagney [this message]
2003-09-04 21:58 ` Mark Kettenis
2003-09-06 0:02 ` Jim Blandy
2003-09-06 14:18 ` Mark Kettenis
2003-09-09 4:51 ` Andrew Cagney
2003-09-09 17:15 ` Jim Blandy
2003-09-09 19:16 ` Andrew Cagney
2003-08-29 20:20 ` Mark Kettenis
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=3F5D553E.90607@redhat.com \
--to=ac131313@redhat.com \
--cc=drow@mvista.com \
--cc=gdb@sources.redhat.com \
--cc=kettenis@chello.nl \
/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