all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* other weird gdb-mi problems
@ 2009-08-26  7:49 Miles Bader
  2009-08-26 17:19 ` Eli Zaretskii
  0 siblings, 1 reply; 10+ messages in thread
From: Miles Bader @ 2009-08-26  7:49 UTC (permalink / raw)
  To: emacs-devel

I'm debugging a program, which segfaulted (I think due to stack
overflow); here's the top of the stack:

   (gdb) fr 0
   #0  0x083718ee in IpLoc::shares_outermost_container (this=0x84eb8fc, 
       var=0x84eb894) at IpLoc.h:1021
   1021		  return oc1 == oc2;
   (gdb) ba 5
   #0  0x083718ee in IpLoc::shares_outermost_container (this=0x84eb8fc, 
       var=0x84eb894) at IpLoc.h:1021
   #1  0x08371994 in IpLoc::contains (this=0x84eb8fc, var=0x84eb894)
       at IpLoc.h:1048
   #2  0x0836eb31 in IpLoc::innermost_container (this=0x84eb894, 
       within=0x84e95a4) at IpLoc.cpp:825
   #3  0x08372232 in IpLoc::innermost_container (this=0x84eb894, 
       within=0x84e95a4) at IpLoc.h:803
   #4  0x0836ed94 in print_member_name (cont=0x84e95a4, var=0x84eb894, os=...)
       at IpLoc.cpp:849

Now, let's try moving up the stack:

   (gdb) up
   #1  0x08371994 in IpLoc::contains (this=0x84eb8fc, var=0x84eb894)
       at IpLoc.h:1048
   1048		    && _oc_start <= var->_oc_start && _oc_end >= var->_oc_end);

(**** BUG 1) The transcript output looks ok -- but the source code
window displays the source file/location for frame 0, not for the
current frame!

Now let's try moving to deeper stack frames, using the "up" command:

   (gdb) up
   #1  0x08371994 in IpLoc::contains (this=0x84eb8fc, var=0x84eb894)
       at IpLoc.h:1048
   1048		    && _oc_start <= var->_oc_start && _oc_end >= var->_oc_end);
   (gdb) up
   #1  0x08371994 in IpLoc::contains (this=0x84eb8fc, var=0x84eb894)
       at IpLoc.h:1048
   1048		    && _oc_start <= var->_oc_start && _oc_end >= var->_oc_end);

... wait a minute... why am I still at frame 1?!
"down" is similarly weird:

   (gdb) down
   Bottom (innermost) frame selected; you cannot go down.

 (**** BUG 2) Basically, the "up" and "down" commands seem to always
start from frame 0, not from the current frame.  I can move to a given
frame using "frame N", but that's pretty annoying.  [The source code
window always shows a display for frame 0, no matter what frame is
printed in the transcript windows.]

That's all for now... :)

Thanks,

-Miles

-- 
(\(\
(^.^)
(")")
*This is the cute bunny virus, please copy this into your sig so it can spread.




^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2009-08-28  3:05 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-08-26  7:49 other weird gdb-mi problems Miles Bader
2009-08-26 17:19 ` Eli Zaretskii
2009-08-26 23:27   ` Nick Roberts
2009-08-27  1:49     ` Miles Bader
2009-08-27  1:50     ` Miles Bader
2009-08-27  4:52       ` Nick Roberts
2009-08-27  9:42         ` Miles Bader
2009-08-28  3:05           ` Nick Roberts
2009-08-27 13:57     ` Dmitry Dzhus
2009-08-27 23:36       ` Nick Roberts

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.