Delay in GDB
Leon Pollak
leonp at plris.com
Thu Aug 25 23:30:14 BST 2011
On Thursday 25 August 2011 20:34:57 Niko Sams wrote:
> Hm, sounds like a ugly workaround that only works if you move the mouse
> fast enough...
> Isn't it possible to fix the real cause for the error?
Niko, I am not a guru in gdb/gdbserver and payed about 3 weeks of work trying
to fix this (I thought this is my problem), till I finally found in the
Internet that this is "normal" situation with gdb not to display the mapped
memory and some more. The recommendation was to make a small macro and copy
the desired region into ordinary RAM and then display it. That's what I did.
This is something connected to pthreads and the way gdb reaches the memory.
> What is a "bus error" - who causes this error?
The kernel trace message shows that gdbserver tries to reach the mapped memory
using the memory_remapio function calls, which is incorrect, because this is
RAM and not IO.
It also happens, for example, when I try to watch the 'errno' variable, which
in the case of multithreaded application is actually not a variable, but a
redefined function call.
>
> Niko
>
> On Tue, Aug 23, 2011 at 19:08, Leon Pollak <leonp at plris.com> wrote:
> > Hello, all.
> >
> > I am working with the embedded linux (remote debugging) and encounter the
> > following problem: some variables/elements in the program under debugging
> > can not be displayed by the gdb/gdbserver and cause the "bus error".
> > Such are, for example, mapped memory locations, errno variable and some
> > more. Kdevelop today has a brilliant feature - display the variable
> > value when the cursor hoovers over it. The problem is, that it tries to
> > do this immediately! This means, that even when one passes through this
> > 'problematic' variable on his way to 'normal' variable, it causes the
> > bus error.
> >
> > So, what I ask is some, let's say, 0.5-1s delay between the STOP over the
> > variable and the request to the gdb to show it.
> >
> > Many thanks ahead.
> > --
> > Leon.
> >
> > _______________________________________________
> > kdevelop mailing list
> > kdevelop at kdevelop.org
> > https://barney.cs.uni-potsdam.de/mailman/listinfo/kdevelop
--
Dr.Leon M.Pollak
Director
PLR Information Systems Ltd.
Tel.:+972-98657670 | POB 8130, H'Aomanut 9,
Fax.:+972-98657621 | Poleg Industrial Zone,
Mob.:+972-544739246 | Netanya, 42160, Israel.
More information about the KDevelop
mailing list