This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [PATCH] sh-tdep.c: delete unneeded function.
- From: Elena Zannoni <ezannoni at redhat dot com>
- To: Michael Snyder <msnyder at redhat dot com>
- Cc: Elena Zannoni <ezannoni at redhat dot com>, gdb-patches at sources dot redhat dot com
- Date: Thu, 9 Oct 2003 21:50:41 -0400
- Subject: Re: [PATCH] sh-tdep.c: delete unneeded function.
- References: <16261.46068.56352.920472@localhost.redhat.com><3F85FA02.7020906@redhat.com>
Michael Snyder writes:
> Elena Zannoni wrote:
> > This function is not used for sh, because it is only called for
> > targets that have the call dummy location set as ON_STACK. SH uses
> > AT_ENTRY_POINT.
> >
> > elena
> >
> >
> > 2003-10-09 Elena Zannoni <ezannoni@redhat.com>
> >
> > * sh-tdep.c (sh_gdbarch_init): Delete setting of push_dummy_code.
> > (sh_gdbarch_init): Delete function, it's only used for dummy calls
>
> Shouldn't that last be (sh_push_dummy_code):?
Grrr, yes, thanks.
elena
>
> > on stack.
> >
> > Index: sh-tdep.c
> > ===================================================================
> > RCS file: /cvs/uberbaum/gdb/sh-tdep.c,v
> > retrieving revision 1.145
> > diff -u -p -r1.145 sh-tdep.c
> > --- sh-tdep.c 3 Oct 2003 08:13:37 -0000 1.145
> > +++ sh-tdep.c 9 Oct 2003 17:36:22 -0000
> > @@ -266,22 +266,6 @@ sh_breakpoint_from_pc (CORE_ADDR *pcptr,
> > return breakpoint;
> > }
> >
> > -static CORE_ADDR
> > -sh_push_dummy_code (struct gdbarch *gdbarch,
> > - CORE_ADDR sp, CORE_ADDR funaddr, int using_gcc,
> > - struct value **args, int nargs,
> > - struct type *value_type,
> > - CORE_ADDR *real_pc, CORE_ADDR *bp_addr)
> > -{
> > - /* Allocate space sufficient for a breakpoint. */
> > - sp = (sp - 2) & ~1;
> > - /* Store the address of that breakpoint */
> > - *bp_addr = sp;
> > - /* sh always starts the call at the callee's entry point. */
> > - *real_pc = funaddr;
> > - return sp;
> > -}
> > -
> > /* Prologue looks like
> > mov.l r14,@-r15
> > sts.l pr,@-r15
> > @@ -2032,7 +2016,6 @@ sh_gdbarch_init (struct gdbarch_info inf
> > set_gdbarch_decr_pc_after_break (gdbarch, 0);
> > set_gdbarch_function_start_offset (gdbarch, 0);
> >
> > - set_gdbarch_push_dummy_code (gdbarch, sh_push_dummy_code);
> > set_gdbarch_push_dummy_call (gdbarch, sh_push_dummy_call_nofpu);
> >
> > set_gdbarch_frame_args_skip (gdbarch, 0);
> >
>