mirror of
https://github.com/tobast/libunwind-eh_elf.git
synced 2024-11-26 09:07:38 +01:00
Auto merged
2005/05/17 14:14:23-07:00 hp.com!davidm (tdep_access_reg): Access AR.EC via ec_loc instead of cfm_loc. (Logical change 1.293)
This commit is contained in:
parent
26fdb45d76
commit
8a1e0a2bcd
1 changed files with 7 additions and 5 deletions
|
@ -323,8 +323,8 @@ tdep_access_reg (struct cursor *c, unw_regnum_t reg, unw_word_t *valp,
|
|||
int write)
|
||||
{
|
||||
ia64_loc_t loc, reg_loc, nat_loc;
|
||||
unw_word_t nat, mask, val;
|
||||
int ret, readonly = 0;
|
||||
unw_word_t nat, mask;
|
||||
uint8_t nat_bitnr;
|
||||
|
||||
switch (reg)
|
||||
|
@ -418,15 +418,17 @@ tdep_access_reg (struct cursor *c, unw_regnum_t reg, unw_word_t *valp,
|
|||
return update_nat (c, nat_loc, mask, valp, write);
|
||||
|
||||
case UNW_IA64_AR_EC:
|
||||
if ((ret = ia64_get (c, c->ec_loc, &val)) < 0)
|
||||
return ret;
|
||||
|
||||
if (write)
|
||||
{
|
||||
c->cfm = ((c->cfm & ~((unw_word_t) 0x3f << 52))
|
||||
| ((*valp & 0x3f) << 52));
|
||||
return ia64_put (c, c->cfm_loc, c->cfm);
|
||||
val = ((val & ~((unw_word_t) 0x3f << 52)) | ((*valp & 0x3f) << 52));
|
||||
return ia64_put (c, c->ec_loc, val);
|
||||
}
|
||||
else
|
||||
{
|
||||
*valp = (c->cfm >> 52) & 0x3f;
|
||||
*valp = (val >> 52) & 0x3f;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue