+2018-01-22 Yao Qi <yao.qi@linaro.org>
+
+ * aarch64-tdep.c (aarch64_pseudo_read_value): Call regcache
+ method raw_read instead of regcache_raw_read.
+ * amd64-tdep.c (amd64_pseudo_register_read_value): Likewise.
+ * arm-tdep.c (arm_neon_quad_read): Likewise.
+ * avr-tdep.c (avr_pseudo_register_read): Likewise.
+ * bfin-tdep.c (bfin_pseudo_register_read): Likewise.
+ * frv-tdep.c (frv_pseudo_register_read): Likewise.
+ * h8300-tdep.c (h8300_pseudo_register_read): Likewise.
+ * i386-tdep.c (i386_mmx_regnum_to_fp_regnum): Likewise.
+ (i386_pseudo_register_read_into_value): Likewise.
+ * mep-tdep.c (mep_pseudo_cr32_read): Likewise.
+ * msp430-tdep.c (msp430_pseudo_register_read): Likewise.
+ * nds32-tdep.c (nds32_pseudo_register_read): Likewise.
+ * rl78-tdep.c (rl78_pseudo_register_read): Likewise.
+ * s390-linux-tdep.c (s390_pseudo_register_read): Likewise.
+ * sparc-tdep.c (sparc32_pseudo_register_read): Likewise.
+ * sparc64-tdep.c (sparc64_pseudo_register_read): Likewise.
+ * spu-tdep.c (spu_pseudo_register_read_spu): Likewise.
+ * xtensa-tdep.c (xtensa_pseudo_register_read): Likewise.
+
2018-01-22 Yao Qi <yao.qi@linaro.org>
* Makefile.in (ALL_TARGET_OBS): Remove mt-tdep.o.
unsigned v_regnum;
v_regnum = AARCH64_V0_REGNUM + regnum - AARCH64_Q0_REGNUM;
- status = regcache_raw_read (regcache, v_regnum, reg_buf);
+ status = regcache->raw_read (v_regnum, reg_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0,
TYPE_LENGTH (value_type (result_value)));
unsigned v_regnum;
v_regnum = AARCH64_V0_REGNUM + regnum - AARCH64_D0_REGNUM;
- status = regcache_raw_read (regcache, v_regnum, reg_buf);
+ status = regcache->raw_read (v_regnum, reg_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0,
TYPE_LENGTH (value_type (result_value)));
unsigned v_regnum;
v_regnum = AARCH64_V0_REGNUM + regnum - AARCH64_S0_REGNUM;
- status = regcache_raw_read (regcache, v_regnum, reg_buf);
+ status = regcache->raw_read (v_regnum, reg_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0,
TYPE_LENGTH (value_type (result_value)));
unsigned v_regnum;
v_regnum = AARCH64_V0_REGNUM + regnum - AARCH64_H0_REGNUM;
- status = regcache_raw_read (regcache, v_regnum, reg_buf);
+ status = regcache->raw_read (v_regnum, reg_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0,
TYPE_LENGTH (value_type (result_value)));
unsigned v_regnum;
v_regnum = AARCH64_V0_REGNUM + regnum - AARCH64_B0_REGNUM;
- status = regcache_raw_read (regcache, v_regnum, reg_buf);
+ status = regcache->raw_read (v_regnum, reg_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0,
TYPE_LENGTH (value_type (result_value)));
if (gpnum >= AMD64_NUM_LOWER_BYTE_REGS)
{
/* Special handling for AH, BH, CH, DH. */
- status = regcache_raw_read (regcache,
- gpnum - AMD64_NUM_LOWER_BYTE_REGS,
- raw_buf);
+ status = regcache->raw_read (gpnum - AMD64_NUM_LOWER_BYTE_REGS,
+ raw_buf);
if (status == REG_VALID)
memcpy (buf, raw_buf + 1, 1);
else
}
else
{
- status = regcache_raw_read (regcache, gpnum, raw_buf);
+ status = regcache->raw_read (gpnum, raw_buf);
if (status == REG_VALID)
memcpy (buf, raw_buf, 1);
else
{
int gpnum = regnum - tdep->eax_regnum;
/* Extract (always little endian). */
- status = regcache_raw_read (regcache, gpnum, raw_buf);
+ status = regcache->raw_read (gpnum, raw_buf);
if (status == REG_VALID)
memcpy (buf, raw_buf, 4);
else
else
offset = 0;
- status = regcache_raw_read (regcache, double_regnum, reg_buf);
+ status = regcache->raw_read (double_regnum, reg_buf);
if (status != REG_VALID)
return status;
memcpy (buf + offset, reg_buf, 8);
offset = 8 - offset;
- status = regcache_raw_read (regcache, double_regnum + 1, reg_buf);
+ status = regcache->raw_read (double_regnum + 1, reg_buf);
if (status != REG_VALID)
return status;
memcpy (buf + offset, reg_buf, 8);
double_regnum = user_reg_map_name_to_regnum (gdbarch, name_buf,
strlen (name_buf));
- status = regcache_raw_read (regcache, double_regnum, reg_buf);
+ status = regcache->raw_read (double_regnum, reg_buf);
if (status == REG_VALID)
memcpy (buf, reg_buf + offset, 4);
return status;
switch (regnum)
{
case AVR_PSEUDO_PC_REGNUM:
- status = regcache_raw_read_unsigned (regcache, AVR_PC_REGNUM, &val);
+ status = regcache->raw_read (AVR_PC_REGNUM, &val);
if (status != REG_VALID)
return status;
val >>= 1;
_("invalid register number %d"), regnum);
/* Extract the CC bit from the ASTAT register. */
- status = regcache_raw_read (regcache, BFIN_ASTAT_REGNUM, buf);
+ status = regcache->raw_read (BFIN_ASTAT_REGNUM, buf);
if (status == REG_VALID)
{
buffer[1] = buffer[2] = buffer[3] = 0;
if (reg == iacc0_regnum)
{
- status = regcache_raw_read (regcache, iacc0h_regnum, buffer);
+ status = regcache->raw_read (iacc0h_regnum, buffer);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, iacc0l_regnum, (bfd_byte *) buffer + 4);
+ status = regcache->raw_read (iacc0l_regnum, (bfd_byte *) buffer + 4);
}
else if (accg0_regnum <= reg && reg <= accg7_regnum)
{
int byte_num = (reg - accg0_regnum) % 4;
gdb_byte buf[4];
- status = regcache_raw_read (regcache, raw_regnum, buf);
+ status = regcache->raw_read (raw_regnum, buf);
if (status == REG_VALID)
{
memset (buffer, 0, 4);
enum register_status status;
ULONGEST val;
- status = regcache_raw_read_unsigned (regcache, raw_regno, &val);
+ status = regcache->raw_read (raw_regno, &val);
if (status == REG_VALID)
store_unsigned_integer (buf,
register_size (gdbarch, pseudo_regno),
regno, E_EXR_REGNUM);
}
else
- return regcache_raw_read (regcache, regno, buf);
+ return regcache->raw_read (regno, buf);
}
static void
ULONGEST tmp;
enum register_status status;
- status = regcache_raw_read_unsigned (regcache, regnum, &tmp);
+ status = regcache->raw_read (regnum, &tmp);
if (status == REG_VALID)
{
if (regnum == HPPA_PCOQ_HEAD_REGNUM || regnum == HPPA_PCOQ_TAIL_REGNUM)
int tos;
mmxreg = regnum - tdep->mm0_regnum;
- regcache_raw_read_unsigned (regcache, I387_FSTAT_REGNUM (tdep), &fstat);
+ regcache->raw_read (I387_FSTAT_REGNUM (tdep), &fstat);
tos = (fstat >> 11) & 0x7;
fpreg = (mmxreg + tos) % 8;
int fpnum = i386_mmx_regnum_to_fp_regnum (regcache, regnum);
/* Extract (always little endian). */
- status = regcache_raw_read (regcache, fpnum, raw_buf);
+ status = regcache->raw_read (fpnum, raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0,
TYPE_LENGTH (value_type (result_value)));
regnum -= tdep->bnd0_regnum;
/* Extract (always little endian). Read lower 128bits. */
- status = regcache_raw_read (regcache,
- I387_BND0R_REGNUM (tdep) + regnum,
- raw_buf);
+ status = regcache->raw_read (I387_BND0R_REGNUM (tdep) + regnum,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0, 16);
else
regnum -= tdep->k0_regnum;
/* Extract (always little endian). */
- status = regcache_raw_read (regcache,
- tdep->k0_regnum + regnum,
- raw_buf);
+ status = regcache->raw_read (tdep->k0_regnum + regnum, raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0, 8);
else
if (regnum < num_lower_zmm_regs)
{
/* Extract (always little endian). Read lower 128bits. */
- status = regcache_raw_read (regcache,
- I387_XMM0_REGNUM (tdep) + regnum,
- raw_buf);
+ status = regcache->raw_read (I387_XMM0_REGNUM (tdep) + regnum,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0, 16);
else
memcpy (buf, raw_buf, 16);
/* Extract (always little endian). Read upper 128bits. */
- status = regcache_raw_read (regcache,
- tdep->ymm0h_regnum + regnum,
- raw_buf);
+ status = regcache->raw_read (tdep->ymm0h_regnum + regnum,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 16, 16);
else
else
{
/* Extract (always little endian). Read lower 128bits. */
- status = regcache_raw_read (regcache,
- I387_XMM16_REGNUM (tdep) + regnum
- - num_lower_zmm_regs,
- raw_buf);
+ status = regcache->raw_read (I387_XMM16_REGNUM (tdep) + regnum
+ - num_lower_zmm_regs,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0, 16);
else
memcpy (buf, raw_buf, 16);
/* Extract (always little endian). Read upper 128bits. */
- status = regcache_raw_read (regcache,
- I387_YMM16H_REGNUM (tdep) + regnum
- - num_lower_zmm_regs,
- raw_buf);
+ status = regcache->raw_read (I387_YMM16H_REGNUM (tdep) + regnum
+ - num_lower_zmm_regs,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 16, 16);
else
}
/* Read upper 256bits. */
- status = regcache_raw_read (regcache,
- tdep->zmm0h_regnum + regnum,
- raw_buf);
+ status = regcache->raw_read (tdep->zmm0h_regnum + regnum,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 32, 32);
else
regnum -= tdep->ymm0_regnum;
/* Extract (always little endian). Read lower 128bits. */
- status = regcache_raw_read (regcache,
- I387_XMM0_REGNUM (tdep) + regnum,
- raw_buf);
+ status = regcache->raw_read (I387_XMM0_REGNUM (tdep) + regnum,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0, 16);
else
memcpy (buf, raw_buf, 16);
/* Read upper 128bits. */
- status = regcache_raw_read (regcache,
- tdep->ymm0h_regnum + regnum,
- raw_buf);
+ status = regcache->raw_read (tdep->ymm0h_regnum + regnum,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 16, 32);
else
{
regnum -= tdep->ymm16_regnum;
/* Extract (always little endian). Read lower 128bits. */
- status = regcache_raw_read (regcache,
- I387_XMM16_REGNUM (tdep) + regnum,
- raw_buf);
+ status = regcache->raw_read (I387_XMM16_REGNUM (tdep) + regnum,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0, 16);
else
memcpy (buf, raw_buf, 16);
/* Read upper 128bits. */
- status = regcache_raw_read (regcache,
- tdep->ymm16h_regnum + regnum,
- raw_buf);
+ status = regcache->raw_read (tdep->ymm16h_regnum + regnum,
+ raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 16, 16);
else
int gpnum = regnum - tdep->ax_regnum;
/* Extract (always little endian). */
- status = regcache_raw_read (regcache, gpnum, raw_buf);
+ status = regcache->raw_read (gpnum, raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0,
TYPE_LENGTH (value_type (result_value)));
/* Extract (always little endian). We read both lower and
upper registers. */
- status = regcache_raw_read (regcache, gpnum % 4, raw_buf);
+ status = regcache->raw_read (gpnum % 4, raw_buf);
if (status != REG_VALID)
mark_value_bytes_unavailable (result_value, 0,
TYPE_LENGTH (value_type (result_value)));
static enum register_status
m32c_raw_read (struct m32c_reg *reg, struct regcache *cache, gdb_byte *buf)
{
- return regcache_raw_read (cache, reg->num, buf);
+ return cache->raw_read (reg->num, buf);
}
{
struct gdbarch_tdep *tdep = gdbarch_tdep (cache->arch ());
ULONGEST flg;
- regcache_raw_read_unsigned (cache, tdep->flg->num, &flg);
+
+ cache->raw_read (tdep->flg->num, &flg);
return flg & 0xffff;
}
m32c_banked_read (struct m32c_reg *reg, struct regcache *cache, gdb_byte *buf)
{
struct m32c_reg *bank_reg = m32c_banked_register (reg, cache);
- return regcache_raw_read (cache, bank_reg->num, buf);
+ return cache->raw_read (bank_reg->num, buf);
}
memset (buf, 0, TYPE_LENGTH (reg->type));
m32c_find_part (reg, &offset, &len);
- return regcache_cooked_read_part (cache, reg->rx->num, offset, len, buf);
+ return cache->cooked_read_part (reg->rx->num, offset, len, buf);
}
gdb_assert (TYPE_LENGTH (register_type (gdbarch, rawnum)) == sizeof (buf64));
gdb_assert (TYPE_LENGTH (register_type (gdbarch, cookednum)) == 4);
- status = regcache_raw_read (regcache, rawnum, buf64);
+ status = regcache->raw_read (rawnum, buf64);
if (status == REG_VALID)
{
/* Slow, but legible. */
int cookednum,
gdb_byte *buf)
{
- return regcache_raw_read (regcache, mep_pseudo_to_raw[cookednum], buf);
+ return regcache->raw_read (mep_pseudo_to_raw[cookednum], buf);
}
{
if (IS_CSR_REGNUM (cookednum)
|| IS_CCR_REGNUM (cookednum))
- return regcache_raw_read (regcache, mep_pseudo_to_raw[cookednum], buf);
+ return regcache->raw_read (mep_pseudo_to_raw[cookednum], buf);
else if (IS_CR32_REGNUM (cookednum)
|| IS_FP_CR32_REGNUM (cookednum))
return mep_pseudo_cr32_read (gdbarch, regcache, cookednum, buf);
gdb_assert (cookednum >= gdbarch_num_regs (gdbarch)
&& cookednum < 2 * gdbarch_num_regs (gdbarch));
if (register_size (gdbarch, rawnum) == register_size (gdbarch, cookednum))
- return regcache_raw_read (regcache, rawnum, buf);
+ return regcache->raw_read (rawnum, buf);
else if (register_size (gdbarch, rawnum) >
register_size (gdbarch, cookednum))
{
if (gdbarch_tdep (gdbarch)->mips64_transfers_32bit_regs_p)
- return regcache_raw_read_part (regcache, rawnum, 0, 4, buf);
+ return regcache->raw_read_part (rawnum, 0, 4, buf);
else
{
enum bfd_endian byte_order = gdbarch_byte_order (gdbarch);
LONGEST regval;
enum register_status status;
- status = regcache_raw_read_signed (regcache, rawnum, ®val);
+ status = regcache->raw_read (rawnum, ®val);
if (status == REG_VALID)
store_signed_integer (buf, 4, byte_order, regval);
return status;
int regsize = register_size (gdbarch, regnum);
int raw_regnum = regnum - MSP430_NUM_REGS;
- status = regcache_raw_read_unsigned (regcache, raw_regnum, &val);
+ status = regcache->raw_read (raw_regnum, &val);
if (status == REG_VALID)
store_unsigned_integer (buffer, regsize, byte_order, val);
offset = (regnum & 1) ? 0 : 4;
fdr_regnum = NDS32_FD0_REGNUM + (regnum >> 1);
- status = regcache_raw_read (regcache, fdr_regnum, reg_buf);
+ status = regcache->raw_read (fdr_regnum, reg_buf);
if (status == REG_VALID)
memcpy (buf, reg_buf + offset, 4);
int raw_regnum = RL78_RAW_BANK0_R0_REGNUM
+ (reg - RL78_BANK0_R0_REGNUM);
- status = regcache_raw_read (regcache, raw_regnum, buffer);
+ status = regcache->raw_read (raw_regnum, buffer);
}
else if (RL78_BANK0_RP0_REGNUM <= reg && reg <= RL78_BANK3_RP3_REGNUM)
{
int raw_regnum = 2 * (reg - RL78_BANK0_RP0_REGNUM)
+ RL78_RAW_BANK0_R0_REGNUM;
- status = regcache_raw_read (regcache, raw_regnum, buffer);
+ status = regcache->raw_read (raw_regnum, buffer);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, raw_regnum + 1, buffer + 1);
+ status = regcache->raw_read (raw_regnum + 1, buffer + 1);
}
else if (RL78_BANK0_RP0_PTR_REGNUM <= reg && reg <= RL78_BANK3_RP3_PTR_REGNUM)
{
int raw_regnum = 2 * (reg - RL78_BANK0_RP0_PTR_REGNUM)
+ RL78_RAW_BANK0_R0_REGNUM;
- status = regcache_raw_read (regcache, raw_regnum, buffer);
+ status = regcache->raw_read (raw_regnum, buffer);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, raw_regnum + 1, buffer + 1);
+ status = regcache->raw_read (raw_regnum + 1, buffer + 1);
}
else if (reg == RL78_SP_REGNUM)
{
- status = regcache_raw_read (regcache, RL78_SPL_REGNUM, buffer);
+ status = regcache->raw_read (RL78_SPL_REGNUM, buffer);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, RL78_SPH_REGNUM, buffer + 1);
+ status = regcache->raw_read (RL78_SPH_REGNUM, buffer + 1);
}
else if (reg == RL78_PC_REGNUM)
{
gdb_byte rawbuf[4];
- status = regcache_raw_read (regcache, RL78_RAW_PC_REGNUM, rawbuf);
+ status = regcache->raw_read (RL78_RAW_PC_REGNUM, rawbuf);
memcpy (buffer, rawbuf, 3);
}
else if (RL78_X_REGNUM <= reg && reg <= RL78_H_REGNUM)
{
ULONGEST psw;
- status = regcache_raw_read_unsigned (regcache, RL78_PSW_REGNUM, &psw);
+ status = regcache->raw_read (RL78_PSW_REGNUM, &psw);
if (status == REG_VALID)
{
/* RSB0 is at bit 3; RSBS1 is at bit 5. */
int bank = ((psw >> 3) & 1) | ((psw >> 4) & 1);
int raw_regnum = RL78_RAW_BANK0_R0_REGNUM + bank * RL78_REGS_PER_BANK
+ (reg - RL78_X_REGNUM);
- status = regcache_raw_read (regcache, raw_regnum, buffer);
+ status = regcache->raw_read (raw_regnum, buffer);
}
}
else if (RL78_AX_REGNUM <= reg && reg <= RL78_HL_REGNUM)
{
ULONGEST psw;
- status = regcache_raw_read_unsigned (regcache, RL78_PSW_REGNUM, &psw);
+ status = regcache->raw_read (RL78_PSW_REGNUM, &psw);
if (status == REG_VALID)
{
/* RSB0 is at bit 3; RSBS1 is at bit 5. */
int bank = ((psw >> 3) & 1) | ((psw >> 4) & 1);
int raw_regnum = RL78_RAW_BANK0_R0_REGNUM + bank * RL78_REGS_PER_BANK
+ 2 * (reg - RL78_AX_REGNUM);
- status = regcache_raw_read (regcache, raw_regnum, buffer);
+ status = regcache->raw_read (raw_regnum, buffer);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, raw_regnum + 1,
- buffer + 1);
+ status = regcache->raw_read (raw_regnum + 1, buffer + 1);
}
}
else
if (gdbarch_byte_order (gdbarch) == BFD_ENDIAN_BIG)
{
/* Read two FP registers to form a whole dl register. */
- status = regcache_raw_read (regcache, tdep->ppc_fp0_regnum +
- 2 * reg_index, buffer);
+ status = regcache->raw_read (tdep->ppc_fp0_regnum +
+ 2 * reg_index, buffer);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, tdep->ppc_fp0_regnum +
- 2 * reg_index + 1, buffer + 8);
+ status = regcache->raw_read (tdep->ppc_fp0_regnum +
+ 2 * reg_index + 1, buffer + 8);
}
else
{
- status = regcache_raw_read (regcache, tdep->ppc_fp0_regnum +
- 2 * reg_index + 1, buffer);
+ status = regcache->raw_read (tdep->ppc_fp0_regnum +
+ 2 * reg_index + 1, buffer);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, tdep->ppc_fp0_regnum +
- 2 * reg_index, buffer + 8);
+ status = regcache->raw_read (tdep->ppc_fp0_regnum +
+ 2 * reg_index, buffer + 8);
}
return status;
/* Read the portion that overlaps the VMX registers. */
if (reg_index > 31)
- status = regcache_raw_read (regcache, tdep->ppc_vr0_regnum +
- reg_index - 32, buffer);
+ status = regcache->raw_read (tdep->ppc_vr0_regnum +
+ reg_index - 32, buffer);
else
/* Read the portion that overlaps the FPR registers. */
if (gdbarch_byte_order (gdbarch) == BFD_ENDIAN_BIG)
{
- status = regcache_raw_read (regcache, tdep->ppc_fp0_regnum +
- reg_index, buffer);
+ status = regcache->raw_read (tdep->ppc_fp0_regnum +
+ reg_index, buffer);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, tdep->ppc_vsr0_upper_regnum +
- reg_index, buffer + 8);
+ status = regcache->raw_read (tdep->ppc_vsr0_upper_regnum +
+ reg_index, buffer + 8);
}
else
{
- status = regcache_raw_read (regcache, tdep->ppc_fp0_regnum +
- reg_index, buffer + 8);
+ status = regcache->raw_read (tdep->ppc_fp0_regnum +
+ reg_index, buffer + 8);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, tdep->ppc_vsr0_upper_regnum +
- reg_index, buffer);
+ status = regcache->raw_read (tdep->ppc_vsr0_upper_regnum +
+ reg_index, buffer);
}
return status;
{
enum register_status status;
- status = regcache_raw_read_unsigned (regcache, S390_PSWA_REGNUM, &val);
+ status = regcache->raw_read (S390_PSWA_REGNUM, &val);
if (status == REG_VALID)
{
if (register_size (gdbarch, S390_PSWA_REGNUM) == 4)
{
enum register_status status;
- status = regcache_raw_read_unsigned (regcache, S390_PSWM_REGNUM, &val);
+ status = regcache->raw_read (S390_PSWM_REGNUM, &val);
if (status == REG_VALID)
{
if (register_size (gdbarch, S390_PSWA_REGNUM) == 4)
regnum -= tdep->gpr_full_regnum;
- status = regcache_raw_read_unsigned (regcache, S390_R0_REGNUM + regnum, &val);
+ status = regcache->raw_read (S390_R0_REGNUM + regnum, &val);
if (status == REG_VALID)
- status = regcache_raw_read_unsigned (regcache, S390_R0_UPPER_REGNUM + regnum,
- &val_upper);
+ status = regcache->raw_read (S390_R0_UPPER_REGNUM + regnum,
+ &val_upper);
if (status == REG_VALID)
{
val |= val_upper << 32;
regnum -= tdep->v0_full_regnum;
- status = regcache_raw_read (regcache, S390_F0_REGNUM + regnum, buf);
+ status = regcache->raw_read (S390_F0_REGNUM + regnum, buf);
if (status == REG_VALID)
- status = regcache_raw_read (regcache,
- S390_V0_LOWER_REGNUM + regnum, buf + 8);
+ status = regcache->raw_read (S390_V0_LOWER_REGNUM + regnum, buf + 8);
return status;
}
gdb_byte *b;
b = buffer + register_size (gdbarch, base_regnum) * portion;
- status = regcache_raw_read (regcache, base_regnum + portion, b);
+ status = regcache->raw_read (base_regnum + portion, b);
if (status != REG_VALID)
return status;
}
enum register_status status;
if (reg_nr == PSEUDO_BANK_REGNUM)
- return regcache_raw_read (regcache, BANK_REGNUM, buffer);
+ return regcache->raw_read (BANK_REGNUM, buffer);
else if (reg_nr >= DR0_REGNUM && reg_nr <= DR_LAST_REGNUM)
{
/* Enough space for two float registers. */
gdb_byte *b;
b = buffer + register_size (gdbarch, base_regnum) * portion;
- status = regcache_raw_read (regcache, base_regnum + portion, b);
+ status = regcache->raw_read (base_regnum + portion, b);
if (status != REG_VALID)
return status;
}
base_regnum = sh64_compact_reg_base_num (gdbarch, reg_nr);
/* Build the value in the provided buffer. */
- status = regcache_raw_read (regcache, base_regnum, temp_buffer);
+ status = regcache->raw_read (base_regnum, temp_buffer);
if (status != REG_VALID)
return status;
if (gdbarch_byte_order (gdbarch) == BFD_ENDIAN_BIG)
/* Build the value in the provided buffer. */
/* Floating point registers map 1-1 to the media fp regs,
they have the same size and endianness. */
- return regcache_raw_read (regcache, base_regnum, buffer);
+ return regcache->raw_read (base_regnum, buffer);
}
else if (reg_nr >= DR0_C_REGNUM
/* FPUL_C register is floating point register 32,
same size, same endianness. */
- return regcache_raw_read (regcache, base_regnum, buffer);
+ return regcache->raw_read (base_regnum, buffer);
}
else
gdb_assert_not_reached ("invalid pseudo register number");
gdb_assert (regnum >= SPARC32_D0_REGNUM && regnum <= SPARC32_D30_REGNUM);
regnum = SPARC_F0_REGNUM + 2 * (regnum - SPARC32_D0_REGNUM);
- status = regcache_raw_read (regcache, regnum, buf);
+ status = regcache->raw_read (regnum, buf);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, regnum + 1, buf + 4);
+ status = regcache->raw_read (regnum + 1, buf + 4);
return status;
}
if (regnum >= SPARC64_D0_REGNUM && regnum <= SPARC64_D30_REGNUM)
{
regnum = SPARC_F0_REGNUM + 2 * (regnum - SPARC64_D0_REGNUM);
- status = regcache_raw_read (regcache, regnum, buf);
+ status = regcache->raw_read (regnum, buf);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, regnum + 1, buf + 4);
+ status = regcache->raw_read (regnum + 1, buf + 4);
return status;
}
else if (regnum >= SPARC64_D32_REGNUM && regnum <= SPARC64_D62_REGNUM)
{
regnum = SPARC64_F32_REGNUM + (regnum - SPARC64_D32_REGNUM);
- return regcache_raw_read (regcache, regnum, buf);
+ return regcache->raw_read (regnum, buf);
}
else if (regnum >= SPARC64_Q0_REGNUM && regnum <= SPARC64_Q28_REGNUM)
{
regnum = SPARC_F0_REGNUM + 4 * (regnum - SPARC64_Q0_REGNUM);
- status = regcache_raw_read (regcache, regnum, buf);
+ status = regcache->raw_read (regnum, buf);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, regnum + 1, buf + 4);
+ status = regcache->raw_read (regnum + 1, buf + 4);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, regnum + 2, buf + 8);
+ status = regcache->raw_read (regnum + 2, buf + 8);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, regnum + 3, buf + 12);
+ status = regcache->raw_read (regnum + 3, buf + 12);
return status;
}
{
regnum = SPARC64_F32_REGNUM + 2 * (regnum - SPARC64_Q32_REGNUM);
- status = regcache_raw_read (regcache, regnum, buf);
+ status = regcache->raw_read (regnum, buf);
if (status == REG_VALID)
- status = regcache_raw_read (regcache, regnum + 1, buf + 8);
+ status = regcache->raw_read (regnum + 1, buf + 8);
return status;
}
{
ULONGEST state;
- status = regcache_raw_read_unsigned (regcache, SPARC64_STATE_REGNUM, &state);
+ status = regcache->raw_read (SPARC64_STATE_REGNUM, &state);
if (status != REG_VALID)
return status;
ULONGEST id;
ULONGEST ul;
- status = regcache_raw_read_unsigned (regcache, SPU_ID_REGNUM, &id);
+ status = regcache->raw_read (SPU_ID_REGNUM, &id);
if (status != REG_VALID)
return status;
xsnprintf (annex, sizeof annex, "%d/%s", (int) id, regname);
switch (regnum)
{
case SPU_SP_REGNUM:
- status = regcache_raw_read (regcache, SPU_RAW_SP_REGNUM, reg);
+ status = regcache->raw_read (SPU_RAW_SP_REGNUM, reg);
if (status != REG_VALID)
return status;
memcpy (buf, reg, 4);
return status;
case SPU_FPSCR_REGNUM:
- status = regcache_raw_read_unsigned (regcache, SPU_ID_REGNUM, &id);
+ status = regcache->raw_read (SPU_ID_REGNUM, &id);
if (status != REG_VALID)
return status;
xsnprintf (annex, sizeof annex, "%d/fpcr", (int) id);
ULONGEST value;
enum register_status status;
- status = regcache_raw_read_unsigned (regcache,
- gdbarch_tdep (gdbarch)->wb_regnum,
- &value);
+ status = regcache->raw_read (gdbarch_tdep (gdbarch)->wb_regnum,
+ &value);
if (status != REG_VALID)
return status;
regnum = arreg_number (gdbarch, regnum, value);
/* We can always read non-pseudo registers. */
if (regnum >= 0 && regnum < gdbarch_num_regs (gdbarch))
- return regcache_raw_read (regcache, regnum, buffer);
+ return regcache->raw_read (regnum, buffer);
/* We have to find out how to deal with priveleged registers.
Let's treat them as pseudo-registers, but we cannot read/write them. */
return xtensa_register_read_masked (regcache, reg, buffer);
/* Assume that we can read the register. */
- return regcache_raw_read (regcache, regnum, buffer);
+ return regcache->raw_read (regnum, buffer);
}
else
internal_error (__FILE__, __LINE__,