Article View: gnu.gdb.bug
Article #308bug in gdb 3.3 on iPSC/2
From: Jim Kingdon
Date: Fri, 27 Oct 1989 15:28
Date: Fri, 27 Oct 1989 15:28
18 lines
1297 bytes
1297 bytes
[GDB cannot find number of arguments for main on i386 because
FRAME_CHAIN_VALID doesn't allow get_prev_frame_info to go into
start.]
I fixed this in the working GDB (i.e. the fix will be in the next
release) by just not having FRAME_NUM_ARGS return the number of
arguments (i.e. return -1) when get_prev_frame_info returns 0. This
is pretty much harmless because main is not a varadic function, so if
you have debugging symbols GDB will know how many arguments it has
from the debugging symbols. If someone wants to see all 3 arguments
to main, no matter how it is declared in the source, it would require
something like a really_get_prev_frame_info in addition to
get_prev_frame_info.
The check for start is necessary, because at least on some machines
there is no way to tell where the bottom of the stack is, so we have
to stop looking when we get to start.
Technical Details
Message-ID:
<8910271528.AA07038@hobbes.ai.mit.edu>Path:
arc1-ca.pugleaf.net!utzoo!telly!attcan!utgpu!watmath!uunet!tut.cis.ohio-state.edu!ai.mit.edu!kingdonReferences:
<616@wang.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!telly!attcan!utgpu!watmath!uunet!tut.cis.ohio-state.edu!ai.mit.edu!kingdon From: kingdon@ai.mit.edu (Jim Kingdon) Newsgroups: gnu.gdb.bug Subject: bug in gdb 3.3 on iPSC/2 Message-ID: <8910271528.AA07038@hobbes.ai.mit.edu> Date: 27 Oct 89 15:28:17 GMT References: <616@wang.UUCP> Sender: daemon@tut.cis.ohio-state.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 18