Xtensa GDB port -- revised patch

Maxim Grigoriev maxim@tensilica.com
Thu Sep 28 01:07:00 GMT 2006


After some investigation, it turns out that the get_fp_num() function, 
which was "grubbing around in the private data structures of the symbol 
reader", is not needed at all.  Perhaps that code was left over from an 
earlier version of GDB. Stack unwinding on Xtensa can be done using the 
register windows -- it requires neither prologue analysis to find the 
frame pointer nor DWARF unwind info.  The only thing the get_fp_num() 
function was used for was identifying frames, but it seems like we can 
just use the stack pointer for the frame ID.  (Is that right?)  I've 
changed the code to do this and it appears to work fine: no DejaGnu 
regression has been detected, and manual testing on alloca-tests hasn't 
exposed anything.

The other suggestions that I've received so far were easy to use and 
I've done that.  By the way, I also removed the line to use the 
dwarf2_frame_sniffer, because DWARF unwind info is not currently used 
for Xtensa.

The revised patch is attached.

CHANGELOG:

gdb/

2006-09-27  Maxim Grigoriev  <maxim@tensilica.com>

    * NEWS: New port to Xtensa.
    * Makefile.in: Add dependencies for Xtensa files.
    * configure.tgt (xtensa*, xtensa*-*-elf*): New.
    * configure.host (xtensa*-*-elf*): New.
    * config/xtensa/xtensa.mt: New file.
    * xtensa-config.c: New file.
    * xtensa-tdep.h: New file.
    * xtensa-tdep.c: New file.

gdb/doc/

2006-09-27  Maxim Grigoriev  <maxim@tensilica.com>

    * gdb.texinfo: (Contributors): Add contributors of Xtensa port.

Maxim Grigoriev
Tensilica, Inc.
3255-6 Scott Boulevard
Santa Clara, CA 95054-3013
(w) 408-566-1770




-------------- next part --------------
A non-text attachment was scrubbed...
Name: xtensa-patch.diff
Type: text/x-patch
Size: 85584 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/gdb-patches/attachments/20060928/a4b479e7/attachment.bin>


More information about the Gdb-patches mailing list