#include "gdbsupport/common-regcache.h"
#include "gdbsupport/function-view.h"
-#include <forward_list>
struct regcache;
struct regset;
/* A (register_number, register_value) pair. */
-typedef struct cached_reg
+struct cached_reg_t
{
int num;
gdb_byte *data;
-} cached_reg_t;
+};
/* Buffer of registers. */
debug. */
void debug_print_register (const char *func, int regno);
- static void regcache_thread_ptid_changed (ptid_t old_ptid, ptid_t new_ptid);
protected:
regcache (process_stratum_target *target, gdbarch *gdbarch,
const address_space *aspace);
- static std::forward_list<regcache *> current_regcache;
-
private:
/* Helper function for transfer_regset. Copies across a single register. */
get_thread_arch_aspace_regcache (process_stratum_target *target, ptid_t ptid,
struct gdbarch *gdbarch,
struct address_space *aspace);
-
- friend void
- registers_changed_ptid (process_stratum_target *target, ptid_t ptid);
};
+using regcache_up = std::unique_ptr<regcache>;
+
class readonly_detached_regcache : public readable_regcache
{
public: