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 v9 11/29] record-btrace: optionally indent function call history


> -----Original Message-----
> From: Pedro Alves [mailto:palves@redhat.com]
> Sent: Thursday, December 19, 2013 7:24 PM
> To: Metzger, Markus T


> On 12/19/2013 04:44 PM, Markus Metzger wrote:
> > Add a new modifier /c to the "record function-call-history" command to
> > indent the function name based on its depth in the call stack.
> >
> > Also reorder the optional fields to have the indentation at the very
> beginning.
> > Prefix the insn range (/i modifier) with "inst ".
> 
> I was a little surprised the manual didn't get an update for this one,
> but I see an /i example is currently lacking.  Can one use both
> /i and /l at the same time ?

Yes.  Does this need to be documented explicitly?


> > Change the range syntax from "begin-end" to "begin,end" to allow
> copy&paste to
> > the "record instruction-history" and "list" commands.
> 
> (This bit seems to be missing in NEWS.  Not sure it was on purpose.)

I'll add it.


> > There is one known bug regarding indentation that results from the fact
> that we
> > have the current instruction already inside the branch trace.  When the
> current
> > instruction is the first (and only) instruction in a function on the outermost
> > level for which we have not seen the call, the indentation starts at level 1
> > with 2 leading spaces.
> 
> Hmm.  Why are we adding known bugs?  I'm not sure I understood it, but
> from
> your description it sounds like the condition should be detectable?

Yes, it is detectable.  You can't fix it up afterwards, though, so you need to
check this when computing the trace for each instruction.  I have not tried
to fix it because I think you wouldn't even notice it in practice.

The fix is relatively easy, so I added it and updated the tests.  Looking back, I
can't really say why I haven't just fixed it right away.

Regards,
Markus.
Intel GmbH
Dornacher Strasse 1
85622 Feldkirchen/Muenchen, Deutschland
Sitz der Gesellschaft: Feldkirchen bei Muenchen
Geschaeftsfuehrer: Christian Lamprechter, Hannes Schwaderer, Douglas Lusk
Registergericht: Muenchen HRB 47456
Ust.-IdNr./VAT Registration No.: DE129385895
Citibank Frankfurt a.M. (BLZ 502 109 00) 600119052


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