/* Target-dependent code for SPARC systems running NetBSD.
- Copyright 2002 Free Software Foundation, Inc.
+ Copyright 2002, 2003 Free Software Foundation, Inc.
Contributed by Wasabi Systems, Inc.
This file is part of GDB.
#include "value.h"
#include "osabi.h"
+#include "gdb_string.h"
+
+#include "sparc-tdep.h"
#include "sparcnbsd-tdep.h"
#include "nbsd-tdep.h"
if (regno == PC_REGNUM || regno == -1)
supply_register (PC_REGNUM, regs + REG32_OFFSET_PC);
- if (regno == NPC_REGNUM || regno == -1)
- supply_register (NPC_REGNUM, regs + REG32_OFFSET_NPC);
+ if (regno == DEPRECATED_NPC_REGNUM || regno == -1)
+ supply_register (DEPRECATED_NPC_REGNUM, regs + REG32_OFFSET_NPC);
if (regno == Y_REGNUM || regno == -1)
supply_register (Y_REGNUM, regs + REG32_OFFSET_Y);
if (regno == PC_REGNUM || regno == -1)
supply_register (PC_REGNUM, regs + REG64_OFFSET_PC);
- if (regno == NPC_REGNUM || regno == -1)
- supply_register (NPC_REGNUM, regs + REG64_OFFSET_NPC);
+ if (regno == DEPRECATED_NPC_REGNUM || regno == -1)
+ supply_register (DEPRECATED_NPC_REGNUM, regs + REG64_OFFSET_NPC);
if (regno == Y_REGNUM || regno == -1)
{
if (regno == PC_REGNUM || regno == -1)
regcache_collect (PC_REGNUM, regs + REG32_OFFSET_PC);
- if (regno == NPC_REGNUM || regno == -1)
- regcache_collect (NPC_REGNUM, regs + REG32_OFFSET_NPC);
+ if (regno == DEPRECATED_NPC_REGNUM || regno == -1)
+ regcache_collect (DEPRECATED_NPC_REGNUM, regs + REG32_OFFSET_NPC);
if (regno == Y_REGNUM || regno == -1)
regcache_collect (Y_REGNUM, regs + REG32_OFFSET_Y);
if (regno == PC_REGNUM || regno == -1)
regcache_collect (PC_REGNUM, regs + REG64_OFFSET_PC);
- if (regno == NPC_REGNUM || regno == -1)
- regcache_collect (NPC_REGNUM, regs + REG64_OFFSET_NPC);
+ if (regno == DEPRECATED_NPC_REGNUM || regno == -1)
+ regcache_collect (DEPRECATED_NPC_REGNUM, regs + REG64_OFFSET_NPC);
if (regno == Y_REGNUM || regno == -1)
regcache_collect (Y_REGNUM, regs + REG64_OFFSET_Y);
if (target_read_memory (jb_addr + 12, buf, sizeof (buf)))
return 0;
- *pc = extract_address (buf, sizeof (buf));
+ *pc = extract_unsigned_integer (buf, sizeof (buf));
return 1;
}
if (target_read_memory (jb_addr + 16, buf, sizeof (buf)))
return 0;
- *pc = extract_address (buf, sizeof (buf));
+ *pc = extract_unsigned_integer (buf, sizeof (buf));
return 1;
}