int store_p) override;
};
-/* Fill GDB's register array with the general-purpose, pc and badv
+/* Fill GDB's register array with the general-purpose, orig_a0, pc and badv
register values from the current thread. */
static void
}
}
-/* Store to the current thread the valid general-purpose, pc and badv
+/* Store to the current thread the valid general-purpose, orig_a0, pc and badv
register values in the GDB's register array. */
static void
for (i = 1; i < 32; i++)
collect_register (regcache, i, *regset + i);
+ collect_register (regcache, LOONGARCH_ORIG_A0_REGNUM, *regset + LOONGARCH_ORIG_A0_REGNUM);
collect_register (regcache, LOONGARCH_PC_REGNUM, *regset + LOONGARCH_PC_REGNUM);
collect_register (regcache, LOONGARCH_BADV_REGNUM, *regset + LOONGARCH_BADV_REGNUM);
}
supply_register_zeroed (regcache, 0);
for (i = 1; i < 32; i++)
supply_register (regcache, i, *regset + i);
+ supply_register (regcache, LOONGARCH_ORIG_A0_REGNUM, *regset + LOONGARCH_ORIG_A0_REGNUM);
supply_register (regcache, LOONGARCH_PC_REGNUM, *regset + LOONGARCH_PC_REGNUM);
supply_register (regcache, LOONGARCH_BADV_REGNUM, *regset + LOONGARCH_BADV_REGNUM);
}