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: [RFA] Fix "break foo" when `foo's prologue ends before line table


On Mon, May 11, 2009 at 11:49:10PM +0300, Eli Zaretskii wrote:
> Are such rearrangements permitted?  I mean, are we talking about a
> real-life situation here?

Definitely.  This happens all the time.

> > Do you really want "break foo" to break on the line where a () is
> > called?
> 
> It's hard to say, really.  There are arguments for both, but I
> personally tend to think that stopping on the call to `a' is what I'd
> want.
> 
> What do others think?

I agree with Pedro.  When the compiler moves something into the
prologue, generally, we try to stop on it - even if the prologue is
not yet finished.

> > /* The order of entries in the linetable is significant.  They should
> >    be sorted by increasing values of the pc field.
> 
> Well, granted, I've seen that comment.  But (a) are we sure all of our
> comments are necessarily accurate to rely on them?, and (b) it
> continues to say

This data structure relies on being sorted by PC.  You can see e.g. in
find_pc_sect_line.

-- 
Daniel Jacobowitz
CodeSourcery


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