mirror of
https://github.com/tobast/libunwind-eh_elf.git
synced 2024-11-30 02:27:38 +01:00
(ia64_pregnum): Rename IA64_REG_RP to IA64_REG_IP.
(ia64_loc_t): New type. For UNW_LOCAL_ONLY, it's a single word, as before. For the generic case, it's a 2-word structure. This provides enough space to encode all necessary info both for 32-bit targets (which require only 4-byte aligned addresses) and for targets which are limited to accessing ucontext_t values via uc_access(3). (ABI_MARKER_LINUX_SIGTRAMP): New macro. (ABI_MARKER_HP_UX_SIGTRAMP): New macro. (struct cursor): Consolidate bsp_loc, bspstore_loc, pfs_loc, rnat_loc, ip_loc, pri_unat_loc, unat_loc, pr_loc, lc_loc, fpsr_loc, r4-r7_loc, b1-b5_loc, f2-f7_loc, and fr_loc[] into loc[] array. Note that there is now a separate PSP-loc (loc[IA64_REG_PSP]) in addition to the cached psp value. Rename sigcontext_loc to sigcontext_addr. Remove is_signal_frame memeber and add abi_marker member instead. Change type of rbs_area[].rnat_loc to ia64_loc_t. (struct ia64_global_unwind_state): Remove preg_index[] array. (Logical change 1.84)
This commit is contained in:
parent
69dc9063ae
commit
ed67c3edb7
1 changed files with 25 additions and 26 deletions
|
@ -47,8 +47,8 @@ enum ia64_pregnum
|
||||||
IA64_REG_BSPSTORE,
|
IA64_REG_BSPSTORE,
|
||||||
IA64_REG_PFS, /* previous function state */
|
IA64_REG_PFS, /* previous function state */
|
||||||
IA64_REG_RNAT,
|
IA64_REG_RNAT,
|
||||||
/* return pointer: */
|
/* instruction pointer: */
|
||||||
IA64_REG_RP,
|
IA64_REG_IP,
|
||||||
|
|
||||||
/* preserved registers: */
|
/* preserved registers: */
|
||||||
IA64_REG_R4, IA64_REG_R5, IA64_REG_R6, IA64_REG_R7,
|
IA64_REG_R4, IA64_REG_R5, IA64_REG_R6, IA64_REG_R7,
|
||||||
|
@ -63,6 +63,20 @@ enum ia64_pregnum
|
||||||
IA64_NUM_PREGS
|
IA64_NUM_PREGS
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#ifdef UNW_LOCAL_ONLY
|
||||||
|
|
||||||
|
typedef unw_word_t ia64_loc_t;
|
||||||
|
|
||||||
|
#else /* !UNW_LOCAL_ONLY */
|
||||||
|
|
||||||
|
typedef struct ia64_loc
|
||||||
|
{
|
||||||
|
unw_word_t w0, w1;
|
||||||
|
}
|
||||||
|
ia64_loc_t;
|
||||||
|
|
||||||
|
#endif /* !UNW_LOCAL_ONLY */
|
||||||
|
|
||||||
#include "ia64/script.h"
|
#include "ia64/script.h"
|
||||||
|
|
||||||
struct unw_addr_space
|
struct unw_addr_space
|
||||||
|
@ -77,6 +91,9 @@ struct unw_addr_space
|
||||||
struct ia64_script_cache global_cache;
|
struct ia64_script_cache global_cache;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#define ABI_MARKER_LINUX_SIGTRAMP ((0 << 8) | 's')
|
||||||
|
#define ABI_MARKER_HP_UX_SIGTRAMP ((1 << 8) | 1)
|
||||||
|
|
||||||
struct cursor
|
struct cursor
|
||||||
{
|
{
|
||||||
void *as_arg; /* argument to address-space callbacks */
|
void *as_arg; /* argument to address-space callbacks */
|
||||||
|
@ -93,32 +110,17 @@ struct cursor
|
||||||
unw_word_t bsp; /* backing store pointer value */
|
unw_word_t bsp; /* backing store pointer value */
|
||||||
unw_word_t sp; /* stack pointer value */
|
unw_word_t sp; /* stack pointer value */
|
||||||
unw_word_t psp; /* previous sp value */
|
unw_word_t psp; /* previous sp value */
|
||||||
unw_word_t cfm_loc; /* cfm save location (or NULL) */
|
ia64_loc_t cfm_loc; /* cfm save location (or NULL) */
|
||||||
|
ia64_loc_t loc[IA64_NUM_PREGS];
|
||||||
/* preserved state: */
|
|
||||||
unw_word_t bsp_loc; /* previous bsp save location */
|
|
||||||
unw_word_t bspstore_loc;
|
|
||||||
unw_word_t pfs_loc;
|
|
||||||
unw_word_t rnat_loc;
|
|
||||||
unw_word_t ip_loc;
|
|
||||||
unw_word_t pri_unat_loc;
|
|
||||||
unw_word_t unat_loc;
|
|
||||||
unw_word_t pr_loc;
|
|
||||||
unw_word_t lc_loc;
|
|
||||||
unw_word_t fpsr_loc;
|
|
||||||
unw_word_t r4_loc, r5_loc, r6_loc, r7_loc;
|
|
||||||
unw_word_t nat4_loc, nat5_loc, nat6_loc, nat7_loc;
|
|
||||||
unw_word_t b1_loc, b2_loc, b3_loc, b4_loc, b5_loc;
|
|
||||||
unw_word_t f2_loc, f3_loc, f4_loc, f5_loc, fr_loc[16];
|
|
||||||
|
|
||||||
unw_word_t eh_args[4]; /* exception handler arguments */
|
unw_word_t eh_args[4]; /* exception handler arguments */
|
||||||
unw_word_t sigcontext_loc; /* location of sigcontext or NULL */
|
unw_word_t sigcontext_addr; /* address of sigcontext or 0 */
|
||||||
unw_word_t is_signal_frame; /* is this a signal trampoline frame? */
|
|
||||||
|
|
||||||
unw_word_t sigcontext_off; /* sigcontext-offset relative to signal sp */
|
unw_word_t sigcontext_off; /* sigcontext-offset relative to signal sp */
|
||||||
|
|
||||||
short hint;
|
short hint;
|
||||||
short prev_script;
|
short prev_script;
|
||||||
|
|
||||||
|
uint16_t abi_marker;;
|
||||||
uint8_t eh_valid_mask;
|
uint8_t eh_valid_mask;
|
||||||
|
|
||||||
int pi_valid : 1; /* is proc_info valid? */
|
int pi_valid : 1; /* is proc_info valid? */
|
||||||
|
@ -139,7 +141,7 @@ struct cursor
|
||||||
{
|
{
|
||||||
unw_word_t end;
|
unw_word_t end;
|
||||||
unw_word_t size;
|
unw_word_t size;
|
||||||
unw_word_t rnat_loc;
|
ia64_loc_t rnat_loc;
|
||||||
}
|
}
|
||||||
rbs_area[96 + 2]; /* 96 stacked regs + 1 extra stack on each side... */
|
rbs_area[96 + 2]; /* 96 stacked regs + 1 extra stack on each side... */
|
||||||
};
|
};
|
||||||
|
@ -152,9 +154,6 @@ struct ia64_global_unwind_state
|
||||||
they're saved). */
|
they're saved). */
|
||||||
const unsigned char save_order[8];
|
const unsigned char save_order[8];
|
||||||
|
|
||||||
/* Index into unw_cursor_t for preserved register i */
|
|
||||||
unsigned short preg_index[IA64_NUM_PREGS];
|
|
||||||
|
|
||||||
unw_word_t r0;
|
unw_word_t r0;
|
||||||
unw_fpreg_t f0, f1_le, f1_be, nat_val_le;
|
unw_fpreg_t f0, f1_le, f1_be, nat_val_le;
|
||||||
unw_fpreg_t nat_val_be, int_val_le, int_val_be;
|
unw_fpreg_t nat_val_be, int_val_le, int_val_be;
|
||||||
|
|
Loading…
Reference in a new issue