This is the mail archive of the gdb-patches@sources.redhat.com 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]

Re: RFC: Avoid calling XXX_skip_prologue for assembly code


> Fred Fish <fnf@www.ninemoons.com> writes:
> 
>> There is little point in attempting to skip over prologues if we
>> already know for a fact that the source language is assembly.
>> 
>> In fact, attempting to do so may actually be incorrect if the user has
>> taken the output of the compiler, used that as the basis for his code,
>> and hand optimized it in some way to produce an assembly version.
>> There could still be prologue code in the hand crafted version.
> 
> 
> Would you be willing to try gdb.asm/asm-source.exp against a D10V sim
> with this change?  I'm pretty sure your change is going to break that
> test.  If so, you could fix the failure by changing the test to set
> the breakpoint after the `enter' sequences.
> 
> If you can take care of that, and add a comment indicating why
> assembly language is a special case, then I approve of this change.

Can someone confirm/deny this from me:

> Anyway, I suspect (is this true?) that this patch would make ``break vfprintf'' and ``break *vfprintf'' identical.  That in turn could mean that a backtrace from a debug info free file such as libc.a:vfprintf() might not work.

To put it another way, it would mean that for files with no debug info 
``break *foo'' and ``break foo'' would have the same affect.

(As they say it is all comming back to me) I think this gets dragged out 
and debated regularly.  If the two forms are made identical the ability 
to selectivly choose the breakpoint behavour is removed.

Does anyone know the motivation behind the patch?

Andrew





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