This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: new port


Thank you very much for the tips. You are right.

When I step into the function with stepi:
(1) If I try 'info frame' just before the first instruction, then
results an internal error.
(2) If I try 'info frame' just after the first intsuction, then I get
frame information.

I set up traces to know which functions GDB crosses in my target-tdep.c.
I can tell that skip_prologue is called only after processing the
first instruction,
I think it should be called before, shouldn't it?

Thank you for the HOWTO, I jump on it.

Regards.

Florent

2009/5/14 Anthony Berent <Anthony.Berent@arm.com>:
> Florent,
>
> I have also been porting to a new architecture, and recently solved similar
> problems with next. The way next works is that, after a step, it checks
> whether an extra frame has been added to the stack. If it has, and various
> other checks are satisfied, then it places a breakpoint on the return
> address and runs on. Otherwise it simply stops after the first step.
>
> Try stepping into the function using stepi, stopping at its first
> instruction, and then having a look at the stack frames (using bt and "info
> frames"). If these look wrong then that is probably your problem.
>
> - Anthony
>
> -----Original Message-----
> From: gdb-owner@sourceware.org [mailto:gdb-owner@sourceware.org] On Behalf
> Of Florent DEFAY
> Sent: 14 May 2009 14:24
> To: gdb@sourceware.org
> Subject: new port
>
> Hi,
>
> I work on porting GDB to a new arch.
> I already ported GCC.
>
> I meet some problems, I need help.
>
> At the moment, I can use most of basic GDB commands.
>
> I can set breakpoints and stop on them. I can set breakpoints on function
> names.
> I can step. I can read locals and registers.
>
> When I use the command 'next', it should step and skip functions. The
> problem is that
> indeed it steps but it does not skip functions. It step into the function.
>
> Please help.
>
>
> Regards.
>
> Florent
>
>
>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]