From 9b3c083c83dca517211431bdb3f23fbb6ce5236a Mon Sep 17 00:00:00 2001 From: Michael Snyder Date: Sat, 2 Apr 2005 00:08:14 +0000 Subject: [PATCH] 2005-04-01 Michael Snyder * mn10300-prologue.c (set_movm_offsets): Don't test variable before setting it. * mn10300-tdep.c (mn10300_skip_prologue): Use analyze_prologue instead of skip_prologue_using_sal. --- gdb/ChangeLog | 7 +++++++ gdb/mn10300-prologue.c | 5 ++++- gdb/mn10300-tdep.c | 8 +++++++- 3 files changed, 18 insertions(+), 2 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index ac21981c11b..25f654021d5 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,10 @@ +2005-04-01 Michael Snyder + + * mn10300-prologue.c (set_movm_offsets): Don't test variable + before setting it. + * mn10300-tdep.c (mn10300_skip_prologue): Use analyze_prologue + instead of skip_prologue_using_sal. + 2005-03-31 Kevin Buettner * solib-frv.c (struct lm_info): Add new field ``lm_addr''. diff --git a/gdb/mn10300-prologue.c b/gdb/mn10300-prologue.c index 4875086d4a1..aea1608c33f 100644 --- a/gdb/mn10300-prologue.c +++ b/gdb/mn10300-prologue.c @@ -119,10 +119,13 @@ set_movm_offsets (struct frame_info *fi, int offset = 0; CORE_ADDR base; - if (cache == NULL || fi == NULL) + if (fi == NULL || this_cache == NULL) return; cache = mn10300_frame_unwind_cache (fi, this_cache); + if (cache == NULL) + return; + base = trad_frame_get_this_base (cache); if (movm_args & movm_other_bit) { diff --git a/gdb/mn10300-tdep.c b/gdb/mn10300-tdep.c index bfa4092cdb3..8fa50d0be98 100644 --- a/gdb/mn10300-tdep.c +++ b/gdb/mn10300-tdep.c @@ -295,9 +295,15 @@ mn10300_breakpoint_from_pc (CORE_ADDR *bp_addr, int *bp_size) static CORE_ADDR mn10300_skip_prologue (CORE_ADDR pc) { +#if 0 + CORE_ADDR ret; /* FIXME: not implemented. */ /* First approximation, try simply using skip_prologue_using_sal. */ - return skip_prologue_using_sal (pc); + ret = skip_prologue_using_sal (pc); + return ret ? ret : pc; +#else + return mn10300_analyze_prologue (NULL, NULL, pc); +#endif } /* Simple frame_unwind_cache. -- 2.30.2