sh: Add support for DWARF GNU extensions
authorMatt Fleming <matt@console-pimps.org>
Sun, 16 Aug 2009 00:44:33 +0000 (01:44 +0100)
committerMatt Fleming <matt@console-pimps.org>
Sun, 16 Aug 2009 11:48:53 +0000 (12:48 +0100)
commitcd7246f0e2747bd2b43d25d0f63f05db182a62c0
tree729c855c6e17a35b8467161baeeb6431765cf372
parentb955873bf530ee4b80e6c8b734521ad07cbaed7e
sh: Add support for DWARF GNU extensions

Also, remove the "fix" to DW_CFA_def_cfa_register where we reset the
frame's cfa_offset to 0. This action is incorrect when handling
DW_CFA_def_cfa_register as the DWARF spec specifically states that the
previous contents of cfa_offset should be used with the new
register. The reason that I thought cfa_offset should be reset to 0 was
because it was being assigned a bogus value prior to executing the
DW_CFA_def_cfa_register op. It turns out that the bogus cfa_offset value
came from interpreting .cfi_escape pseudo-ops (those used by the GNU
extensions) as CFA_DW_def_cfa ops.

Signed-off-by: Matt Fleming <matt@console-pimps.org>
arch/sh/include/asm/dwarf.h
arch/sh/kernel/dwarf.c