/* Ravenscar SPARC target support.
- Copyright (C) 2004-2019 Free Software Foundation, Inc.
+ Copyright (C) 2004-2022 Free Software Foundation, Inc.
This file is part of GDB.
#include "inferior.h"
#include "ravenscar-thread.h"
#include "sparc-ravenscar-thread.h"
+#include "gdbarch.h"
struct sparc_ravenscar_ops : public ravenscar_arch_ops
{
static void
supply_register_at_address (struct regcache *regcache, int regnum,
- CORE_ADDR register_addr)
+ CORE_ADDR register_addr)
{
struct gdbarch *gdbarch = regcache->arch ();
int buf_size = register_size (gdbarch, regnum);
for (current_regnum = 0; current_regnum < num_regs; current_regnum ++)
{
if (register_in_thread_descriptor_p (current_regnum))
- {
- current_address = thread_descriptor_address
- + sparc_register_offsets [current_regnum];
- supply_register_at_address (regcache, current_regnum,
- current_address);
- }
+ {
+ current_address = thread_descriptor_address
+ + sparc_register_offsets [current_regnum];
+ supply_register_at_address (regcache, current_regnum,
+ current_address);
+ }
else if (register_on_stack_p (current_regnum))
- {
- current_address = stack_address
- + sparc_register_offsets [current_regnum];
- supply_register_at_address (regcache, current_regnum,
- current_address);
- }
+ {
+ current_address = stack_address
+ + sparc_register_offsets [current_regnum];
+ supply_register_at_address (regcache, current_regnum,
+ current_address);
+ }
}
}
else if (register_on_stack_p (regnum))
{
regcache_cooked_read_unsigned (regcache, SPARC_SP_REGNUM,
- ®ister_address);
+ ®ister_address);
register_address += sparc_register_offsets [regnum];
}
else
regcache->raw_collect (regnum, buf);
write_memory (register_address,
- buf,
- buf_size);
+ buf,
+ buf_size);
}
static struct sparc_ravenscar_ops sparc_ravenscar_ops;