static void ia64_linux_supply_fpregset (const struct regset *regset, struct regcache *regcache, int regnum, const void *regs, size_t len) { const gdb_byte f_zero[16] = { 0 }; const gdb_byte f_one[16] = { 0, 0, 0, 0, 0, 0, 0, 0x80, 0xff, 0xff, 0, 0, 0, 0, 0, 0 }; regcache_supply_regset (regset, regcache, regnum, regs, len); /* Kernel generated cores have fr1==0 instead of 1.0. Older GDBs did the same. So ignore whatever might be recorded in fpregset_t for fr0/fr1 and always supply their expected values. */ if (regnum == -1 || regnum == IA64_FR0_REGNUM) regcache_raw_supply (regcache, IA64_FR0_REGNUM, f_zero); if (regnum == -1 || regnum == IA64_FR1_REGNUM) regcache_raw_supply (regcache, IA64_FR1_REGNUM, f_one); }
static void frv_linux_supply_gregset (const struct regset *regset, struct regcache *regcache, int regnum, const void *gregs, size_t len) { int regi; char zerobuf[MAX_REGISTER_SIZE]; memset (zerobuf, 0, MAX_REGISTER_SIZE); /* gr0 always contains 0. Also, the kernel passes the TBR value in this slot. */ regcache_raw_supply (regcache, first_gpr_regnum, zerobuf); /* Fill gr32, ..., gr63 with zeros. */ for (regi = first_gpr_regnum + 32; regi <= last_gpr_regnum; regi++) regcache_raw_supply (regcache, regi, zerobuf); regcache_supply_regset (regset, regcache, regnum, gregs, len); }