This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Add support for the Lattice Mico32 (LM32) architecture
- From: Joel Brobecker <brobecker at adacore dot com>
- To: Jon Beniston <jon at beniston dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Thu, 7 May 2009 09:48:53 -0700
- Subject: Re: [PATCH] Add support for the Lattice Mico32 (LM32) architecture
- References: <266F97CB7CD14C6899877E7D69AA2030@bibi> <20090207041443.GG3676@adacore.com> <26720080D2924381A7049C33A9DEB225@bibi>
Jon,
> 2009-04-15 Jon Beniston <jon@beniston.com>
>
> * MAINTAINERS: Add lm32 target.
> * Makefile.in: Add lm32 dependencies.
> * NEWS: Indicate lm32 is a new target.
> * configure.tgt: Add lm32 targets.
> * lm32-tdep.c: New file.
>
> gdb/testsuite
> 2009-04-15 Jon Beniston <jon@beniston.com>
>
> * gdb.asm/asm-source.exp: Add lm32 target.
This looks good overall. I just had one tiny observation. Please also
double-check with Eli that the NEWS update is OK.
That being said, I'm afraid that you won't be able to commit this patch
until the sim counterpart is approved. This is due to the two dependencies
(one in configure.tgt, and one in lm32-tdep.c) that you have. Have you
heard from the sim maintainers?
> /* Return PC of first non prologue instruction, for the function at the
> specified address. */
>
> static CORE_ADDR
> lm32_skip_prologue (struct gdbarch *gdbarch, CORE_ADDR pc)
> {
> CORE_ADDR func_addr, func_end, limit_pc;
> struct symtab_and_line sal;
> struct lm32_frame_cache frame_info;
> struct trad_frame_saved_reg saved_regs[SIM_LM32_NUM_REGS];
>
> /* See if we can determine the end of the prologue via the symbol table.
> If so, then return either PC, or the PC after the prologue, whichever
> is greater. */
> if (find_pc_partial_function (pc, NULL, &func_addr, &func_end))
You don't need the func_end variable, here, as you can just pass NULL
instead.
--
Joel