From: Andrew Cagney <cagney@gnu.org>
To: Roland McGrath <roland@redhat.com>
Cc: gdb@sources.redhat.com
Subject: Re: remote protocol support for TARGET_OBJECT_AUXV
Date: Fri, 06 Feb 2004 17:02:00 -0000 [thread overview]
Message-ID: <4023C883.6010407@gnu.org> (raw)
In-Reply-To: <200402060249.i162nP8R009810@magilla.sf.frob.com>
> I think these improvements are worth pursuing without delay. However, I
> don't see any reason not to go ahead with the protocol you have proposed in
> the interim, since I can implement that in a few minutes without perturbing
> anything else.
OK. Once we've seen the numbers we can persue this.
>> -> qPartial:<obj>?
>> <- OK -- queries of type <obj> are supported
>> <- "" -- queries of type <obj> are not supported
> What does "supported" here mean exactly? A stub will e.g. support reading
> but not writing, and a very constrained range of "annex" values. If an OK
> response to "qPartial:foo?" just means that you have some chance if you try
> some particular read/write query, is there a particular benefit to that
> over just trying the first query you wanted and taking the empty reply as
> "not supported"?
Good question. In the past GDB has encountered situtations where it
needed to differentiate between the questions:
- operation not supported
- error during supported operation
for instance, with breakpoints, with the current protocol there's no
well defined mechanism for determining if:
-> Z2,0,0 or -> Z2
<- E00
(insert watchpoint,addr,len) fails because:
- 0,0 is an illegal addr,len
- Z2 is, in that stub, considered an illegal Z packet
- the operation is legal, but the hardware failed
The proposal is to fix it with:
-> Z2?
<- OK
so that GDB can explictly differentiate between:
- hardware watchpoints not supported
- error inserting hardware watchpoint
consequently, since then, care as been taken to define a "supported"
query with new packets.
For here, the cases I can think of are:
- new gdb, old stub, packet not recognized
"" must always be returned
- new gdb, new stub, no /proc, or no read(write?) /proc access
Operation attempted, Enn returned
- new gdb, new stub, /proc
Operation attempted, valid response returned
so perhaphs clearly specifying this may prove sufficient. I think that
the main thing is that the spec has to be clear that:
-> qPartial:asdfasdf:...
<- ""
where "asdfasdf" is not "supported" must return "" and not "Enn".
>> a variation being something like:
>> qPartial:obj=<obj>:op=write[:annex=<x-annex>]:offset=<x-offset>:data=<x-data>
>> which makes it more extensible.
>
>
> That is not really any more extensible, I'd say. You can just define new
> tokens after the first or second : to change the details later. This is
> just more verbose, unless it's free form as to the order of parameters.
> Being free form is less desireable because it requires hairy parsing in the
> stub instead of just matching fixed leading strings for the few particular
> requests that are actually supported.
Should additional parameters be needed, it might help. However, yes,
simply specifying a new packet is easier.
Andrew
PS: A contraction would be 'qPart:...".
next prev parent reply other threads:[~2004-02-06 17:02 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <401E5DC0.9020904@gnu.org>
2004-02-04 23:58 ` Roland McGrath
2004-02-05 6:34 ` Eli Zaretskii
2004-02-05 15:54 ` Andrew Cagney
2004-02-06 2:49 ` Roland McGrath
2004-02-06 17:02 ` Andrew Cagney [this message]
2004-02-12 2:12 ` Roland McGrath
2004-02-12 6:26 ` Eli Zaretskii
2004-02-24 23:21 ` Roland McGrath
2004-02-25 5:47 ` Eli Zaretskii
2004-02-25 14:34 ` Daniel Jacobowitz
2004-02-25 15:17 ` Eli Zaretskii
2004-02-25 15:54 ` Andrew Cagney
2004-02-25 16:06 ` Daniel Jacobowitz
2004-02-26 6:14 ` Eli Zaretskii
2004-02-26 14:57 ` Daniel Jacobowitz
2004-02-26 16:57 ` Nathan J. Williams
2004-02-26 18:56 ` Eli Zaretskii
2004-02-12 16:42 ` Andrew Cagney
2004-02-24 23:29 ` Roland McGrath
2004-02-25 5:49 ` Eli Zaretskii
2004-02-25 16:06 ` Andrew Cagney
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=4023C883.6010407@gnu.org \
--to=cagney@gnu.org \
--cc=gdb@sources.redhat.com \
--cc=roland@redhat.com \
/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