public inbox for gdb@sourceware.org
 help / color / mirror / Atom feed
* tracepoint.c memory range requests
@ 2005-11-19  1:38 Jim Blandy
  2005-11-19  2:07 ` Michael Snyder
  0 siblings, 1 reply; 3+ messages in thread
From: Jim Blandy @ 2005-11-19  1:38 UTC (permalink / raw)
  To: Michael Snyder; +Cc: gdb

Looking at the code in tracepoint.c:stringify_collection_list, it
seems that memory ranges with absolute addresses end up having the
form MFFFFFFFF,<start>,<len>.  This is because "%X" always treats its
argument as unsigned.  So the number of F's depends on sizeof
(unsigned int).

I know that we spent some effort keeping the packets small.  Since
there are, as far as we know, no stubs that support tracepoints in
active use, may I change that to send '-' instead of the F's?

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: tracepoint.c memory range requests
  2005-11-19  1:38 tracepoint.c memory range requests Jim Blandy
@ 2005-11-19  2:07 ` Michael Snyder
  2005-11-19  4:39   ` Jim Blandy
  0 siblings, 1 reply; 3+ messages in thread
From: Michael Snyder @ 2005-11-19  2:07 UTC (permalink / raw)
  To: Jim Blandy; +Cc: gdb

Jim Blandy wrote:
> Looking at the code in tracepoint.c:stringify_collection_list, it
> seems that memory ranges with absolute addresses end up having the
> form MFFFFFFFF,<start>,<len>.  This is because "%X" always treats its
> argument as unsigned.  So the number of F's depends on sizeof
> (unsigned int).
> 
> I know that we spent some effort keeping the packets small.  Since
> there are, as far as we know, no stubs that support tracepoints in
> active use, may I change that to send '-' instead of the F's?

Actually, there may be such a stub -- there's been at least
one guy posting questions about target tracepoint implementation
this year.

Is the purpose just to make the packet smaller?

The intent was for that number to be the value negative one,
so changing it to "M-1,<start>,<len>" wouldn't be entirely
unreasonable.  The comments in gdb refer to it as "-1",
(when they don't mistakenly refer to it as "0").

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: tracepoint.c memory range requests
  2005-11-19  2:07 ` Michael Snyder
@ 2005-11-19  4:39   ` Jim Blandy
  0 siblings, 0 replies; 3+ messages in thread
From: Jim Blandy @ 2005-11-19  4:39 UTC (permalink / raw)
  To: Michael Snyder; +Cc: gdb

On 11/18/05, Michael Snyder <msnyder@redhat.com> wrote:
> Actually, there may be such a stub -- there's been at least
> one guy posting questions about target tracepoint implementation
> this year.
>
> Is the purpose just to make the packet smaller?

Yeah.

> The intent was for that number to be the value negative one,
> so changing it to "M-1,<start>,<len>" wouldn't be entirely
> unreasonable.  The comments in gdb refer to it as "-1",
> (when they don't mistakenly refer to it as "0").

Okay.  I'll make the code behave that way, and document it that way.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2005-11-19  4:39 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-11-19  1:38 tracepoint.c memory range requests Jim Blandy
2005-11-19  2:07 ` Michael Snyder
2005-11-19  4:39   ` Jim Blandy

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 read-only IMAP folder(s) and NNTP newsgroup(s).