* builtin-regs.c (value_of_builtin_reg): Correctly calculate the
builtin reg number.
This commit is contained in:
parent
942e7dd911
commit
3e3f273960
2 changed files with 6 additions and 1 deletions
|
@ -1,3 +1,8 @@
|
|||
2002-05-13 Richard Earnshaw <rearnsha@arm.com>
|
||||
|
||||
* builtin-regs.c (value_of_builtin_reg): Correctly calculate the
|
||||
builtin reg number.
|
||||
|
||||
2002-05-13 Daniel Jacobowitz <drow@mvista.com>
|
||||
|
||||
* ax-gdb.c (gen_sign_extend, gen_fetch, gen_usual_unary)
|
||||
|
|
|
@ -71,7 +71,7 @@ builtin_reg_map_name_to_regnum (const char *name, int len)
|
|||
struct value *
|
||||
value_of_builtin_reg (int regnum, struct frame_info *frame)
|
||||
{
|
||||
int reg = regnum - NUM_REGS + NUM_PSEUDO_REGS;
|
||||
int reg = regnum - (NUM_REGS + NUM_PSEUDO_REGS);
|
||||
gdb_assert (reg >= 0 && reg < nr_builtin_regs);
|
||||
return builtin_regs[reg].value (frame);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue