Go to the documentation of this file.
42 #ifndef __REMOTE_GDB_HH__
43 #define __REMOTE_GDB_HH__
45 #include <sys/signal.h>
51 #include "arch/types.hh"
81 virtual char *
data()
const = 0;
89 virtual size_t size()
const = 0;
114 virtual const std::string
name()
const = 0;
169 template <
void (BaseRemoteGDB::*F)(
int revent)>
308 std::string &encoded)
const;
311 std::string &encoded,
size_t offset,
size_t unencoded_length)
const;
338 read(
addr,
sizeof(T), (
char *)&temp);
static std::map< char, GdbCommand > command_map
static void output(const char *filename)
virtual size_t size() const =0
Return the size of the raw buffer, in bytes (i.e., half of the number of digits in the g/G packet).
bool cmd_set_hw_bkpt(GdbCommand::Context &ctx)
void encodeXferResponse(const std::string &unencoded, std::string &encoded, size_t offset, size_t unencoded_length) const
bool cmd_async_step(GdbCommand::Context &ctx)
virtual ~BaseGdbRegCache()
bool cmd_signal(GdbCommand::Context &ctx)
void encodeBinaryData(const std::string &unencoded, std::string &encoded) const
void connectWrapper(int revent)
void replaceThreadContext(ThreadContext *_tc)
bool cmd_cont(GdbCommand::Context &ctx)
bool cmd_unsupported(GdbCommand::Context &ctx)
void removeHardBreak(Addr addr, size_t len)
bool cmd_set_thread(GdbCommand::Context &ctx)
BaseGdbRegCache(BaseRemoteGDB *g)
void incomingData(int revent)
bool(BaseRemoteGDB::* Func)(Context &ctx)
SocketEvent<&BaseRemoteGDB::incomingData > DataEvent
EventWrapper< BaseRemoteGDB, &BaseRemoteGDB::singleStep > singleStepEvent
bool cmd_mem_r(GdbCommand::Context &ctx)
virtual const std::string name() const =0
Return the name to use in places like DPRINTF.
ThreadContext * context()
void insertSoftBreak(Addr addr, size_t len)
void clearTempBreakpoint(Addr &bkpt)
ThreadContext is the external interface to all thread state for anything outside of the CPU.
void scheduleInstCommitEvent(Event *ev, int delta)
Schedule an event which will be triggered "delta" instructions later.
bool write(Addr addr, size_t size, const char *data)
GdbCommand(const char *_name, Func _func)
virtual BaseGdbRegCache * gdbRegs()=0
void descheduleInstCommitEvent(Event *ev)
Deschedule an instruction count based event.
virtual char * data() const =0
Return the pointer to the raw bytes buffer containing the register values.
bool cmd_mem_w(GdbCommand::Context &ctx)
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
virtual bool acc(Addr addr, size_t len)=0
TrapEvent(BaseRemoteGDB *g)
ConnectEvent * connectEvent
Concrete subclasses of this abstract class represent how the register values are transmitted on the w...
virtual void setRegs(ThreadContext *) const =0
Set the ThreadContext's registers from the values in the raw buffer.
bool cmd_async_cont(GdbCommand::Context &ctx)
bool cmd_detach(GdbCommand::Context &ctx)
virtual bool getXferFeaturesRead(const std::string &annex, std::string &output)
Get an XML target description.
void removeSoftBreak(Addr addr, size_t len)
virtual std::vector< std::string > availableFeatures() const
bool cmd_query_var(GdbCommand::Context &ctx)
bool cmd_clr_hw_bkpt(GdbCommand::Context &ctx)
bool cmd_step(GdbCommand::Context &ctx)
void insertHardBreak(Addr addr, size_t len)
virtual bool checkBpLen(size_t len)
SocketEvent<&BaseRemoteGDB::connectWrapper > ConnectEvent
bool cmd_reg_r(GdbCommand::Context &ctx)
BaseRemoteGDB::TrapEvent trapEvent
BaseGdbRegCache * regCachePtr
void setTempBreakpoint(Addr bkpt)
SocketEvent(BaseRemoteGDB *gdb, int fd, int e)
bool read(Addr addr, size_t size, char *data)
void recv(std::vector< char > &bp)
bool cmd_reg_w(GdbCommand::Context &ctx)
BaseRemoteGDB(System *system, ThreadContext *context, int _port)
Interface to other parts of the simulator.
virtual void getRegs(ThreadContext *)=0
Fill the raw buffer from the registers in the ThreadContext.
void send(const char *data)
Generated on Wed Sep 30 2020 14:02:01 for gem5 by doxygen 1.8.17