* [doc/tracepoint] Add a note for assigning values of inferior to trace state variables
@ 2011-09-16 9:07 Hui Zhu
2011-09-16 9:48 ` Eli Zaretskii
2011-09-16 12:26 ` Pedro Alves
0 siblings, 2 replies; 6+ messages in thread
From: Hui Zhu @ 2011-09-16 9:07 UTC (permalink / raw)
To: gdb-patches ml; +Cc: Eli Zaretskii
Hi,
I talk about a bug about assigning values of inferior to trace state variables
http://sources.redhat.com/ml/gdb/2011-07/msg00009.html
this issue can be handle by convert value to (uint64_t), for example:
teval $tmp=(uint64_t)a
So I make a patch to update the doc.
Please help me review it.
Thanks,
Hui
2011-09-16 Hui Zhu <teawater@gmail.com>
* gdb.texinfo (Tracepoint Action Lists): Add a note for assigning
values of inferior to trace state variables.
---
doc/gdb.texinfo | 6 ++++++
1 file changed, 6 insertions(+)
--- a/doc/gdb.texinfo
+++ b/doc/gdb.texinfo
@@ -10321,6 +10321,12 @@ are discarded, so this is mainly useful
state variables (@pxref{Trace State Variables}) without adding those
values to the trace buffer, as would be the case if the @code{collect}
action were used.
+Please note that if you want assigning values of inferior to trace state
+variables, please convert it to unsigned 64bit first. For example:
+
+@smallexample
+>teval $c=(uint64_t)jiffies_64
+@end smallexample
@kindex while-stepping @r{(tracepoints)}
@item while-stepping @var{n}
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [doc/tracepoint] Add a note for assigning values of inferior to trace state variables
2011-09-16 9:07 [doc/tracepoint] Add a note for assigning values of inferior to trace state variables Hui Zhu
@ 2011-09-16 9:48 ` Eli Zaretskii
2011-09-16 20:37 ` Joel Brobecker
2011-09-16 12:26 ` Pedro Alves
1 sibling, 1 reply; 6+ messages in thread
From: Eli Zaretskii @ 2011-09-16 9:48 UTC (permalink / raw)
To: Hui Zhu; +Cc: gdb-patches
> From: Hui Zhu <teawater@gmail.com>
> Date: Fri, 16 Sep 2011 16:56:36 +0800
> Cc: Eli Zaretskii <eliz@gnu.org>
>
> I talk about a bug about assigning values of inferior to trace state variables
> http://sources.redhat.com/ml/gdb/2011-07/msg00009.html
That thread died with Tom asking for details. Was the issue resolved
off-list?
> this issue can be handle by convert value to (uint64_t), for example:
> teval $tmp=(uint64_t)a
Isn't this specific to the platform where this runs? I don't think we
should have platform-specific information, and such minor details at
that, in general sections.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [doc/tracepoint] Add a note for assigning values of inferior to trace state variables
2011-09-16 9:07 [doc/tracepoint] Add a note for assigning values of inferior to trace state variables Hui Zhu
2011-09-16 9:48 ` Eli Zaretskii
@ 2011-09-16 12:26 ` Pedro Alves
1 sibling, 0 replies; 6+ messages in thread
From: Pedro Alves @ 2011-09-16 12:26 UTC (permalink / raw)
To: gdb-patches; +Cc: Hui Zhu, Eli Zaretskii
On Friday 16 September 2011 09:56:36, Hui Zhu wrote:
> I talk about a bug about assigning values of inferior to trace state variables
> http://sources.redhat.com/ml/gdb/2011-07/msg00009.html
>
> this issue can be handle by convert value to (uint64_t), for example:
> teval $tmp=(uint64_t)a
Note trace state variables are signed, not unsigned.
--
Pedro Alves
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [doc/tracepoint] Add a note for assigning values of inferior to trace state variables
2011-09-16 9:48 ` Eli Zaretskii
@ 2011-09-16 20:37 ` Joel Brobecker
2011-09-17 14:40 ` Hui Zhu
0 siblings, 1 reply; 6+ messages in thread
From: Joel Brobecker @ 2011-09-16 20:37 UTC (permalink / raw)
To: Eli Zaretskii; +Cc: Hui Zhu, gdb-patches
> > this issue can be handle by convert value to (uint64_t), for example:
> > teval $tmp=(uint64_t)a
>
> Isn't this specific to the platform where this runs? I don't think we
> should have platform-specific information, and such minor details at
> that, in general sections.
One of the things that struck me when I read the diff is that
I asked myself why this conversion is necessary. The patch is
only a small piece of the documentation, so perhaps the reasons
are clear already. But otherwise, it might be worth explaining.
--
Joel
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [doc/tracepoint] Add a note for assigning values of inferior to trace state variables
2011-09-16 20:37 ` Joel Brobecker
@ 2011-09-17 14:40 ` Hui Zhu
2011-09-21 17:01 ` Pedro Alves
0 siblings, 1 reply; 6+ messages in thread
From: Hui Zhu @ 2011-09-17 14:40 UTC (permalink / raw)
To: Joel Brobecker, Eli Zaretskii, gdb-patches ml, Pedro Alves
The issue is:
2d000b setv
260003 reg
1620 ext
27 end
Setv before put value to the stack.
After convert will OK.
Do you have idea on it?
Thanks,
Hui
On Sat, Sep 17, 2011 at 04:27, Joel Brobecker <brobecker@adacore.com> wrote:
>> > this issue can be handle by convert value to (uint64_t), for example:
>> > teval $tmp=(uint64_t)a
>>
>> Isn't this specific to the platform where this runs? I don't think we
>> should have platform-specific information, and such minor details at
>> that, in general sections.
>
> One of the things that struck me when I read the diff is that
> I asked myself why this conversion is necessary. The patch is
> only a small piece of the documentation, so perhaps the reasons
> are clear already. But otherwise, it might be worth explaining.
>
> --
> Joel
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [doc/tracepoint] Add a note for assigning values of inferior to trace state variables
2011-09-17 14:40 ` Hui Zhu
@ 2011-09-21 17:01 ` Pedro Alves
0 siblings, 0 replies; 6+ messages in thread
From: Pedro Alves @ 2011-09-21 17:01 UTC (permalink / raw)
To: Hui Zhu; +Cc: Joel Brobecker, Eli Zaretskii, gdb-patches ml
On Saturday 17 September 2011 15:34:33, Hui Zhu wrote:
> The issue is:
> 2d000b setv
> 260003 reg
> 1620 ext
> 27 end
>
> Setv before put value to the stack.
>
> After convert will OK.
>
> Do you have idea on it?
I still don't understand the problem. :-( Please show with
e.g., `maint agent-eval' what you think is wrong, and what you
think should be happening.
--
Pedro Alves
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2011-09-21 17:00 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-16 9:07 [doc/tracepoint] Add a note for assigning values of inferior to trace state variables Hui Zhu
2011-09-16 9:48 ` Eli Zaretskii
2011-09-16 20:37 ` Joel Brobecker
2011-09-17 14:40 ` Hui Zhu
2011-09-21 17:01 ` Pedro Alves
2011-09-16 12:26 ` Pedro Alves
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox