This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch v4 03/24] btrace: change branch trace data structure


Hi Markus,

please disregard this mail of mine, you have fixed it by:

   /* The function level in a back trace across the entire branch trace.
-     A caller's level is one higher than the level of its callee.
+     A caller's level is one lower than the level of its callee.


Jan


On Sun, 22 Sep 2013 18:57:20 +0200, Jan Kratochvil wrote:
> On Thu, 12 Sep 2013 22:09:27 +0200, Jan Kratochvil wrote:
> > struct btrace_function
> >   /* The function level in a back trace across the entire branch trace.
> >      A caller's level is one higher than the level of its callee.
> > 
> >      Levels can be negative if we see returns for which we have not seen
> >      the corresponding calls.  The branch trace thread information provides
> >      a fixup to normalize function levels so the smallest level is zero.  */
> >   int level;
> > 
> > should be:
> > -    A caller's level is one higher than the level of its callee.
> > +    A callee's level is one higher than the level of its caller.
> > 
> > as one can see for gdb.btrace/tailcall.exp:
> > 
> > record function-call-history /c 1^M
> > 1       0main^M
> > 2       1  foo^M
> > 3       2    bar^M
> > 4       0main^M
> >         ^
> > 
> > In such case please rename btrace_function->level to something else, such as
> > btrace_function->calls_level or btrace_function->reverse_level etc.
> > as it is the opposite of the related GDB frame_info->level field.
> 
> 
> This part of my mail got somehow lost, I do not see your reply mentioning and
> I also do not see any change for btrace_function.level in the patch series v6.
> 
> 
> Regards,
> Jan


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]