Bug 3590 - Crash on x86_64 CFI register `rflags' (after glibc update)
Summary: Crash on x86_64 CFI register `rflags' (after glibc update)
Status: NEW
Alias: None
Product: frysk
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
: P2 normal
Target Milestone: ---
Assignee: Unassigned
URL:
Keywords:
Depends on:
Blocks: 2936 3076
  Show dependency treegraph
 
Reported: 2006-11-25 16:40 UTC by Jan Kratochvil
Modified: 2006-11-28 16:49 UTC (History)
0 users

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments
Fix (2.55 KB, patch)
2006-11-25 16:44 UTC, Jan Kratochvil
Details | Diff
Fix (the same), only updated ChangeLog (2.56 KB, patch)
2006-11-25 16:49 UTC, Jan Kratochvil
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Kratochvil 2006-11-25 16:40:41 UTC
After extending CFI information of glibc's __restore_rt() in:
https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=217087
(Patch still not accepted, this BZ entry may not be required but I still believe
it is a wanted update nonetheless.)

libunwind started to crash with:
run_cfi_program: Invalid register number 49 in DW_cfa_OFFSET

According to http://www.x86-64.org/documentation/abi.pdf page 55 (56/124) it is
really RFLAGS.

Currently RFLAGS or the other registers are not used by libunwind in any way.
Unfortunately it breaks x86_64 ABI of libunwind (by `UNW_TDEP_CURSOR_LEN') but I
believe any stable ABI is currently not cared of by frysk/non-ia64-libunwind.
Comment 1 Jan Kratochvil 2006-11-25 16:44:51 UTC
Created attachment 1437 [details]
Fix

2006-11-25  Jan Kratochvil  <jan.kratochvil@redhat.com>

	* include/libunwind-x86_64.h (UNW_TDEP_CURSOR_LEN): Increased,
	breaks x86_64 libunwind ABI.
	* include/tdep-x86_64/dwarf-config.h (DWARF_NUM_PRESERVED_REGS):
	Increased to support the full x86_64 AMD ABI registers range.
	* src/x86_64/init.h (common_init): New fields set to `DWARF_NULL_LOC'.
	* src/x86_64/regname.c (DE): Support new register names.
Comment 2 Jan Kratochvil 2006-11-25 16:49:10 UTC
Created attachment 1438 [details]
Fix (the same), only updated ChangeLog

2006-11-25  Jan Kratochvil  <jan.kratochvil@redhat.com>

	* include/libunwind-x86_64.h (UNW_TDEP_CURSOR_LEN): Increased,
	breaks x86_64 libunwind ABI.
	* include/tdep-x86_64/dwarf-config.h (DWARF_NUM_PRESERVED_REGS):
	Increased to support the full x86_64 AMD ABI registers range.
	* src/x86_64/init.h (common_init): New registers get `DWARF_NULL_LOC'.
	* src/x86_64/regname.c (regname): Support the new registers.
	* src/x86_64/unwind_i.h: Likewise.