This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFC] FRV: Skip call to __main in main()
- From: Daniel Jacobowitz <drow at false dot org>
- To: Kevin Buettner <kevinb at redhat dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Sat, 15 Nov 2008 11:09:40 -0500
- Subject: Re: [RFC] FRV: Skip call to __main in main()
- References: <20081114161353.3495cc1e@mesquite.lan>
On Fri, Nov 14, 2008 at 04:13:53PM -0700, Kevin Buettner wrote:
> For frv-elf (and perhaps other frv targets too), GCC now emits a call
> to __main() in the prologue of main(). The patch below adds code to
> test for this call and to skip over it so that placing a breakpoint in
> main() will correctly cause the breakpoint to be placed on the first
> statement instead of in the prologue.
>
> I submitted a similar patch for PPC a while back and was asked to fix
> the hard-coded constants. However, the convention in frv-tdep.c seems
> to be to use hard-coded constants preceded by a comment block showing
> how the constant was derived. I chose to follow that convention in
> this patch.
No objections here.
Some distant day in the future, I want to convert all of these things
to work on output from libopcodes...
--
Daniel Jacobowitz
CodeSourcery