Serkan Basaran
|
Re: Debugger strange behaviour
|
Serkan Basaran
01/03/2013 8:47 AM
post98350
|
Re: Debugger strange behaviour
Thanks for your interest.
Yes, debugger goes on correctly.
I haven't tried that on another platform.
> Does gdb continue stepping correctly, i.e. is showing the wrong line
> number the only bad thing that happened?
>
> Wrong line info has been seen before. There are cases where line
> information is very confusing especially in the case as you show in the
> sample. "result" is known to be zero at compile time. In this case, even
> at O0 gcc will emit strange line info.
>
> You will also see strange things in constructs like
>
> for (;;) {
> ...
> }
>
> In some cases, setting a breakpoint at 'for' statement line will yield
> breakpoint that never triggers.
>
> I'm sure there can be more.
>
> This is also architecture specific and if this is happening on arm it is
> not necessarily reproducible on x86 and vice versa.
>
> ---
> Aleksandar
>
|
|
|