diff options
author | Andrew Cagney <cagney@redhat.com> | 2002-06-08 18:30:14 +0000 |
---|---|---|
committer | Andrew Cagney <cagney@redhat.com> | 2002-06-08 18:30:14 +0000 |
commit | ca0d0b529b519a4fce724bc6e6191632f78e7525 (patch) | |
tree | f0193dfb615e8ae4337bbcabce71959d48ff8c51 /gdb/blockframe.c | |
parent | 2af496cb215cdfc34badb8bd5c50eb372ba4caeb (diff) | |
download | gdb-ca0d0b529b519a4fce724bc6e6191632f78e7525.zip gdb-ca0d0b529b519a4fce724bc6e6191632f78e7525.tar.gz gdb-ca0d0b529b519a4fce724bc6e6191632f78e7525.tar.bz2 |
* gdbarch.sh (FRAME_CHAIN_VALID): Set default to
generic_func_frame_chain_valid.
* gdbarch.h, gdbarch.c: Re-generate.
* blockframe.c (generic_func_frame_chain_valid): Only check
PC_IN_CALL_DUMMY when generic dummy frames. Don't worry about
passing FP to PC_IN_CALL_DUMMY.
Fix PR gdb/360.
Diffstat (limited to 'gdb/blockframe.c')
-rw-r--r-- | gdb/blockframe.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/gdb/blockframe.c b/gdb/blockframe.c index deeda4c..526184e 100644 --- a/gdb/blockframe.c +++ b/gdb/blockframe.c @@ -414,6 +414,15 @@ get_prev_frame (struct frame_info *next_frame) start go curfluy than have an abort called from main not show main. */ address = FRAME_CHAIN (next_frame); + + /* FIXME: cagney/2002-06-08: There should be two tests here. + The first would check for a valid frame chain based on a user + selectable policy. The default being ``stop at main'' (as + implemented by generic_func_frame_chain_valid()). Other + policies would be available - stop at NULL, .... The second + test, if provided by the target architecture, would check for + more exotic cases - most target architectures wouldn't bother + with this second case. */ if (!FRAME_CHAIN_VALID (address, next_frame)) return 0; } @@ -1298,7 +1307,8 @@ generic_file_frame_chain_valid (CORE_ADDR fp, struct frame_info *fi) int generic_func_frame_chain_valid (CORE_ADDR fp, struct frame_info *fi) { - if (PC_IN_CALL_DUMMY ((fi)->pc, fp, fp)) + if (USE_GENERIC_DUMMY_FRAMES + && PC_IN_CALL_DUMMY ((fi)->pc, 0, 0)) return 1; /* don't prune CALL_DUMMY frames */ else /* fall back to default algorithm (see frame.h) */ return (fp != 0 |