gem5  v21.1.0.2
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
remote_gdb.hh
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2018 ARM Limited
3  *
4  * The license below extends only to copyright in the software and shall
5  * not be construed as granting a license to any other intellectual
6  * property including but not limited to intellectual property relating
7  * to a hardware implementation of the functionality of the software
8  * licensed hereunder. You may use the software subject to the license
9  * terms below provided that you ensure that this notice is replicated
10  * unmodified and in its entirety in all distributions of the software,
11  * modified or unmodified, in source code or in binary form.
12  *
13  * Copyright 2015 LabWare
14  * Copyright 2014 Google, Inc.
15  * Copyright (c) 2002-2005 The Regents of The University of Michigan
16  * All rights reserved.
17  *
18  * Redistribution and use in source and binary forms, with or without
19  * modification, are permitted provided that the following conditions are
20  * met: redistributions of source code must retain the above copyright
21  * notice, this list of conditions and the following disclaimer;
22  * redistributions in binary form must reproduce the above copyright
23  * notice, this list of conditions and the following disclaimer in the
24  * documentation and/or other materials provided with the distribution;
25  * neither the name of the copyright holders nor the names of its
26  * contributors may be used to endorse or promote products derived from
27  * this software without specific prior written permission.
28  *
29  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
30  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
31  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
32  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
33  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
34  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
35  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
36  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
37  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
38  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
39  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
40  */
41 
42 #ifndef __REMOTE_GDB_HH__
43 #define __REMOTE_GDB_HH__
44 
45 #include <sys/signal.h>
46 
47 #include <cstdint>
48 #include <exception>
49 #include <map>
50 #include <string>
51 #include <vector>
52 
53 #include "arch/pcstate.hh"
54 #include "base/cprintf.hh"
55 #include "base/pollevent.hh"
56 #include "base/socket.hh"
57 #include "base/types.hh"
58 #include "cpu/pc_event.hh"
59 #include "sim/debug.hh"
60 #include "sim/eventq.hh"
61 
62 /*
63  * This file implements a client for the GDB remote serial protocol as
64  * described in this official documentation:
65  *
66  * https://sourceware.org/gdb/current/onlinedocs/gdb/Remote-Protocol.html
67  */
68 
69 namespace gem5
70 {
71 
72 class System;
73 class ThreadContext;
74 
75 class BaseRemoteGDB;
76 class HardBreakpoint;
77 
86 {
87  public:
88 
96  virtual char *data() const = 0;
97 
104  virtual size_t size() const = 0;
105 
111  virtual void getRegs(ThreadContext*) = 0;
112 
119  virtual void setRegs(ThreadContext*) const = 0;
120 
129  virtual const std::string name() const = 0;
130 
135  {}
137  {}
138 
139  protected:
141 };
142 
143 class BaseRemoteGDB
144 {
145  friend class HardBreakpoint;
146  public:
147 
157  virtual ~BaseRemoteGDB();
158 
159  std::string name();
160 
161  void listen();
162  void connect();
163 
164  int port() const;
165 
166  void attach(int fd);
167  void detach();
168  bool isAttached() { return attached; }
169 
170  void addThreadContext(ThreadContext *_tc);
173 
174  bool trap(ContextID id, int type);
175  // end of api_remote_gdb
177 
178  template <class GDBStub, class ...Args>
179  static BaseRemoteGDB *
180  build(Args... args)
181  {
182  int port = getRemoteGDBPort();
183  if (port)
184  return new GDBStub(args..., port);
185  else
186  return nullptr;
187  }
188 
189  private:
190  /*
191  * Connection to the external GDB.
192  */
193  void incomingData(int revent);
194  void connectWrapper(int revent) { connect(); }
195 
196  template <void (BaseRemoteGDB::*F)(int revent)>
197  class SocketEvent : public PollEvent
198  {
199  protected:
201 
202  public:
204  PollEvent(fd, e), gdb(gdb)
205  {}
206 
207  void process(int revent) { (gdb->*F)(revent); }
208  };
209 
212 
213  friend ConnectEvent;
214  friend DataEvent;
215 
218 
220  int _port;
221 
222  // The socket commands come in through.
223  int fd;
224 
225  // Transfer data to/from GDB.
226  uint8_t getbyte();
227  void putbyte(uint8_t b);
228 
229  void recv(std::vector<char> &bp);
230  void send(const char *data);
231  void send(const std::string &data) { send(data.c_str()); }
232 
233  template <typename ...Args>
234  void
235  send(const char *format, const Args &...args)
236  {
237  send(csprintf(format, args...));
238  }
239 
240  /*
241  * Simulator side debugger state.
242  */
243  bool active = false;
244  bool attached = false;
245  bool threadSwitching = false;
246 
248 
249  std::map<ContextID, ThreadContext *> threads;
250  ThreadContext *tc = nullptr;
251 
253 
254  class TrapEvent : public Event
255  {
256  protected:
257  int _type;
260 
261  public:
263  {}
264 
265  void type(int t) { _type = t; }
266  void id(ContextID id) { _id = id; }
267  void process() { gdb->trap(_id, _type); }
268  } trapEvent;
269 
270  /*
271  * The interface to the simulated system.
272  */
273  // Machine memory.
274  bool read(Addr addr, size_t size, char *data);
275  bool write(Addr addr, size_t size, const char *data);
276 
277  template <class T> T read(Addr addr);
278  template <class T> void write(Addr addr, T data);
279 
280  // Single step.
281  void singleStep();
283 
284  void clearSingleStep();
285  void setSingleStep();
286 
288  void scheduleInstCommitEvent(Event *ev, int delta);
291 
292  // Breakpoints.
293  void insertSoftBreak(Addr addr, size_t len);
294  void removeSoftBreak(Addr addr, size_t len);
295  void insertHardBreak(Addr addr, size_t len);
296  void removeHardBreak(Addr addr, size_t len);
297 
298  /*
299  * GDB commands.
300  */
301  struct GdbCommand
302  {
303  public:
304  struct Context
305  {
306  const GdbCommand *cmd;
307  char cmdByte;
308  int type;
309  char *data;
310  int len;
311  };
312 
313  typedef bool (BaseRemoteGDB::*Func)(Context &ctx);
314 
315  const char * const name;
316  const Func func;
317 
318  GdbCommand(const char *_name, Func _func) : name(_name), func(_func) {}
319  };
320 
321  static std::map<char, GdbCommand> commandMap;
322 
324 
325  bool cmdSignal(GdbCommand::Context &ctx);
326  bool cmdCont(GdbCommand::Context &ctx);
328  bool cmdDetach(GdbCommand::Context &ctx);
329  bool cmdRegR(GdbCommand::Context &ctx);
330  bool cmdRegW(GdbCommand::Context &ctx);
332  bool cmdMemR(GdbCommand::Context &ctx);
333  bool cmdMemW(GdbCommand::Context &ctx);
334  bool cmdQueryVar(GdbCommand::Context &ctx);
335  bool cmdStep(GdbCommand::Context &ctx);
340 
342  {
343  struct Context
344  {
345  const std::string &name;
347 
348  Context(const std::string &_name) : name(_name) {}
349  };
350 
351  using Func = void (BaseRemoteGDB::*)(Context &ctx);
352 
353  const char * const argSep;
354  const Func func;
355 
356  QuerySetCommand(Func _func, const char *_argSep=nullptr) :
357  argSep(_argSep), func(_func)
358  {}
359  };
360 
361  static std::map<std::string, QuerySetCommand> queryMap;
362 
363  void queryC(QuerySetCommand::Context &ctx);
366 
367  size_t threadInfoIdx = 0;
370 
371  protected:
372  ThreadContext *context() { return tc; }
373  System *system() { return sys; }
374 
375  void encodeBinaryData(const std::string &unencoded,
376  std::string &encoded) const;
377 
378  void encodeXferResponse(const std::string &unencoded,
379  std::string &encoded, size_t offset, size_t unencoded_length) const;
380 
381  // To be implemented by subclasses.
382  virtual bool checkBpLen(size_t len);
383 
384  virtual BaseGdbRegCache *gdbRegs() = 0;
385 
386  virtual bool acc(Addr addr, size_t len) = 0;
387 
389 
397  virtual bool getXferFeaturesRead(const std::string &annex,
398  std::string &output);
399 };
400 
401 template <class T>
402 inline T
404 {
405  T temp;
406  read(addr, sizeof(T), (char *)&temp);
407  return temp;
408 }
409 
410 template <class T>
411 inline void
413 {
414  write(addr, sizeof(T), (const char *)&data);
415 }
416 
417 } // namespace gem5
418 
419 #endif /* __REMOTE_GDB_H__ */
gem5::BaseRemoteGDB::incomingData
void incomingData(int revent)
Definition: remote_gdb.cc:567
gem5::BaseRemoteGDB::queryXfer
void queryXfer(QuerySetCommand::Context &ctx)
Definition: remote_gdb.cc:1091
socket.hh
gem5::BaseRemoteGDB::cmdUnsupported
bool cmdUnsupported(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:887
gem5::BaseRemoteGDB::active
bool active
Definition: remote_gdb.hh:243
gem5::ArmISA::len
Bitfield< 18, 16 > len
Definition: misc_types.hh:444
gem5::BaseRemoteGDB::isAttached
bool isAttached()
Definition: remote_gdb.hh:168
gem5::BaseRemoteGDB::GdbCommand::Context::type
int type
Definition: remote_gdb.hh:308
gem5::BaseRemoteGDB::cmdDumpPageTable
bool cmdDumpPageTable(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:1225
gem5::BaseRemoteGDB::TrapEvent::_type
int _type
Definition: remote_gdb.hh:257
gem5::ArmISA::format
Bitfield< 31, 29 > format
Definition: misc_types.hh:646
gem5::BaseRemoteGDB::cmdSetThread
bool cmdSetThread(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:959
gem5::BaseRemoteGDB::insertSoftBreak
void insertSoftBreak(Addr addr, size_t len)
Definition: remote_gdb.cc:748
gem5::EventWrapper
Definition: eventq.hh:1084
data
const char data[]
Definition: circlebuf.test.cc:48
gem5::BaseRemoteGDB::listen
void listen()
Definition: remote_gdb.cc:374
gem5::BaseRemoteGDB::singleStepEvent
EventWrapper< BaseRemoteGDB, &BaseRemoteGDB::singleStep > singleStepEvent
Definition: remote_gdb.hh:282
gem5::BaseRemoteGDB::GdbCommand::name
const char *const name
Definition: remote_gdb.hh:315
gem5::BaseRemoteGDB::gdbRegs
virtual BaseGdbRegCache * gdbRegs()=0
gem5::BaseRemoteGDB::QuerySetCommand::Context::name
const std::string & name
Definition: remote_gdb.hh:345
gem5::BaseRemoteGDB::cmdRegR
bool cmdRegR(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:935
gem5::output
static void output(const char *filename)
Definition: debug.cc:66
gem5::BaseRemoteGDB::encodeBinaryData
void encodeBinaryData(const std::string &unencoded, std::string &encoded) const
Definition: remote_gdb.cc:1200
gem5::BaseRemoteGDB::GdbCommand::Func
bool(BaseRemoteGDB::* Func)(Context &ctx)
Definition: remote_gdb.hh:313
gem5::BaseRemoteGDB::putbyte
void putbyte(uint8_t b)
Definition: remote_gdb.cc:595
gem5::BaseRemoteGDB::build
static BaseRemoteGDB * build(Args... args)
Definition: remote_gdb.hh:180
gem5::BaseGdbRegCache::name
virtual const std::string name() const =0
Return the name to use in places like DPRINTF.
gem5::BaseRemoteGDB::scheduleInstCommitEvent
void scheduleInstCommitEvent(Event *ev, int delta)
Schedule an event which will be triggered "delta" instructions later.
Definition: remote_gdb.cc:800
gem5::BaseRemoteGDB::QuerySetCommand
Definition: remote_gdb.hh:341
gem5::BaseRemoteGDB::ConnectEvent
friend ConnectEvent
Definition: remote_gdb.hh:213
gem5::BaseRemoteGDB::fd
int fd
Definition: remote_gdb.hh:223
gem5::BaseRemoteGDB::listener
ListenSocket listener
Definition: remote_gdb.hh:219
gem5::ListenSocket
Definition: socket.hh:35
gem5::BaseRemoteGDB::commandMap
static std::map< char, GdbCommand > commandMap
Definition: remote_gdb.hh:321
gem5::BaseRemoteGDB::queryC
void queryC(QuerySetCommand::Context &ctx)
Definition: remote_gdb.cc:1072
gem5::ArmISA::e
Bitfield< 9 > e
Definition: misc_types.hh:64
gem5::BaseRemoteGDB::TrapEvent
Definition: remote_gdb.hh:254
gem5::BaseRemoteGDB::acc
virtual bool acc(Addr addr, size_t len)=0
gem5::BaseRemoteGDB::send
void send(const char *format, const Args &...args)
Definition: remote_gdb.hh:235
std::vector< char >
gem5::csprintf
std::string csprintf(const char *format, const Args &...args)
Definition: cprintf.hh:161
gem5::BaseRemoteGDB::DataEvent
SocketEvent<&BaseRemoteGDB::incomingData > DataEvent
Definition: remote_gdb.hh:211
gem5::BaseRemoteGDB::cmdMemW
bool cmdMemW(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:1024
gem5::BaseRemoteGDB::TrapEvent::_id
ContextID _id
Definition: remote_gdb.hh:258
gem5::PollEvent
Definition: pollevent.hh:43
gem5::BaseRemoteGDB::GdbCommand::Context::data
char * data
Definition: remote_gdb.hh:309
gem5::BaseRemoteGDB::sys
System * sys
Definition: remote_gdb.hh:247
gem5::BaseRemoteGDB::cmdStep
bool cmdStep(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:1245
gem5::BaseGdbRegCache
Concrete subclasses of this abstract class represent how the register values are transmitted on the w...
Definition: remote_gdb.hh:85
gem5::BaseRemoteGDB::SocketEvent::gdb
BaseRemoteGDB * gdb
Definition: remote_gdb.hh:200
gem5::BaseRemoteGDB::BaseRemoteGDB
BaseRemoteGDB(System *system, int _port)
Interface to other parts of the simulator.
Definition: remote_gdb.cc:356
gem5::HardBreakpoint
Definition: remote_gdb.cc:167
gem5::BaseRemoteGDB::GdbCommand::Context::cmd
const GdbCommand * cmd
Definition: remote_gdb.hh:306
gem5::BaseRemoteGDB::SocketEvent
Definition: remote_gdb.hh:197
gem5::BaseRemoteGDB::attach
void attach(int fd)
Definition: remote_gdb.cc:418
gem5::BaseRemoteGDB::port
int port() const
Definition: remote_gdb.cc:410
gem5::BaseGdbRegCache::getRegs
virtual void getRegs(ThreadContext *)=0
Fill the raw buffer from the registers in the ThreadContext.
gem5::BaseRemoteGDB::GdbCommand::GdbCommand
GdbCommand(const char *_name, Func _func)
Definition: remote_gdb.hh:318
gem5::BaseRemoteGDB::TrapEvent::gdb
BaseRemoteGDB * gdb
Definition: remote_gdb.hh:259
gem5::BaseRemoteGDB::GdbCommand::func
const Func func
Definition: remote_gdb.hh:316
gem5::BaseRemoteGDB::removeHardBreak
void removeHardBreak(Addr addr, size_t len)
Definition: remote_gdb.cc:781
gem5::BaseRemoteGDB::encodeXferResponse
void encodeXferResponse(const std::string &unencoded, std::string &encoded, size_t offset, size_t unencoded_length) const
Definition: remote_gdb.cc:1214
gem5::System
Definition: system.hh:77
gem5::BaseRemoteGDB::availableFeatures
virtual std::vector< std::string > availableFeatures() const
Definition: remote_gdb.cc:1187
gem5::ArmISA::b
Bitfield< 7 > b
Definition: misc_types.hh:381
gem5::ThreadContext
ThreadContext is the external interface to all thread state for anything outside of the CPU.
Definition: thread_context.hh:93
gem5::BaseRemoteGDB::QuerySetCommand::argSep
const char *const argSep
Definition: remote_gdb.hh:353
gem5::BaseRemoteGDB::removeSoftBreak
void removeSoftBreak(Addr addr, size_t len)
Definition: remote_gdb.cc:757
gem5::BaseRemoteGDB::TrapEvent::process
void process()
Definition: remote_gdb.hh:267
gem5::BaseRemoteGDB::tc
ThreadContext * tc
Definition: remote_gdb.hh:250
gem5::Event
Definition: eventq.hh:251
gem5::BaseRemoteGDB::cmdSignal
bool cmdSignal(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:896
debug.hh
pollevent.hh
gem5::BaseRemoteGDB::setSingleStep
void setSingleStep()
Definition: remote_gdb.cc:741
gem5::X86ISA::type
type
Definition: misc.hh:733
gem5::BaseRemoteGDB::SocketEvent::process
void process(int revent)
Definition: remote_gdb.hh:207
gem5::BaseRemoteGDB::name
std::string name()
Definition: remote_gdb.cc:368
gem5::BaseRemoteGDB::DataEvent
friend DataEvent
Definition: remote_gdb.hh:214
gem5::BaseRemoteGDB::connectWrapper
void connectWrapper(int revent)
Definition: remote_gdb.hh:194
gem5::BaseRemoteGDB::cmdAsyncCont
bool cmdAsyncCont(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:915
gem5::BaseGdbRegCache::size
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).
gem5::BaseRemoteGDB::_port
int _port
Definition: remote_gdb.hh:220
gem5::ArmISA::offset
Bitfield< 23, 0 > offset
Definition: types.hh:144
gem5::BaseGdbRegCache::data
virtual char * data() const =0
Return the pointer to the raw bytes buffer containing the register values.
gem5::BaseRemoteGDB::send
void send(const std::string &data)
Definition: remote_gdb.hh:231
cprintf.hh
gem5::BaseGdbRegCache::gdb
BaseRemoteGDB * gdb
Definition: remote_gdb.hh:140
gem5::BaseRemoteGDB::querySupported
void querySupported(QuerySetCommand::Context &ctx)
Definition: remote_gdb.cc:1078
gem5::BaseRemoteGDB::trapEvent
gem5::BaseRemoteGDB::TrapEvent trapEvent
gem5::BaseRemoteGDB::QuerySetCommand::Context
Definition: remote_gdb.hh:343
gem5::ArmISA::t
Bitfield< 5 > t
Definition: misc_types.hh:70
gem5::BaseRemoteGDB::replaceThreadContext
void replaceThreadContext(ThreadContext *tc)
Definition: remote_gdb.hh:54
gem5::BaseRemoteGDB::cmdRegW
bool cmdRegW(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:945
gem5::getRemoteGDBPort
int getRemoteGDBPort()
Definition: debug.cc:120
gem5::BaseGdbRegCache::BaseGdbRegCache
BaseGdbRegCache(BaseRemoteGDB *g)
Definition: remote_gdb.hh:134
gem5::BaseRemoteGDB::getXferFeaturesRead
virtual bool getXferFeaturesRead(const std::string &annex, std::string &output)
Get an XML target description.
Definition: remote_gdb.cc:1193
gem5::MipsISA::g
Bitfield< 4 > g
Definition: dt_constants.hh:86
gem5::Addr
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
Definition: types.hh:147
gem5::BaseRemoteGDB::write
bool write(Addr addr, size_t size, const char *data)
Definition: remote_gdb.cc:709
gem5::BaseRemoteGDB::clearSingleStep
void clearSingleStep()
Definition: remote_gdb.cc:735
gem5::BaseRemoteGDB::detach
void detach()
Definition: remote_gdb.cc:430
gem5::BaseRemoteGDB::TrapEvent::id
void id(ContextID id)
Definition: remote_gdb.hh:266
gem5::BaseRemoteGDB::QuerySetCommand::QuerySetCommand
QuerySetCommand(Func _func, const char *_argSep=nullptr)
Definition: remote_gdb.hh:356
gem5::BaseRemoteGDB::ConnectEvent
SocketEvent<&BaseRemoteGDB::connectWrapper > ConnectEvent
Definition: remote_gdb.hh:210
gem5::BaseRemoteGDB::regCachePtr
BaseGdbRegCache * regCachePtr
Definition: remote_gdb.hh:252
gem5::BaseRemoteGDB::GdbCommand::Context
Definition: remote_gdb.hh:304
gem5::BaseRemoteGDB::TrapEvent::type
void type(int t)
Definition: remote_gdb.hh:265
gem5::BaseRemoteGDB::selectThreadContext
bool selectThreadContext(ContextID id)
Definition: remote_gdb.cc:466
gem5::BaseRemoteGDB::trap
bool trap(ContextID id, int type)
Definition: remote_gdb.hh:55
gem5::BaseRemoteGDB::cmdClrHwBkpt
bool cmdClrHwBkpt(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:1257
gem5::BaseRemoteGDB::cmdSetHwBkpt
bool cmdSetHwBkpt(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:1290
gem5::BaseRemoteGDB::connectEvent
ConnectEvent * connectEvent
Definition: remote_gdb.hh:216
gem5::BaseGdbRegCache::setRegs
virtual void setRegs(ThreadContext *) const =0
Set the ThreadContext's registers from the values in the raw buffer.
gem5::BaseRemoteGDB::send
void send(const char *data)
Definition: remote_gdb.cc:657
pc_event.hh
types.hh
gem5::BaseRemoteGDB::read
bool read(Addr addr, size_t size, char *data)
Definition: remote_gdb.cc:686
gem5::BaseRemoteGDB::descheduleInstCommitEvent
void descheduleInstCommitEvent(Event *ev)
Deschedule an instruction count based event.
Definition: remote_gdb.cc:815
gem5::BaseRemoteGDB::threadSwitching
bool threadSwitching
Definition: remote_gdb.hh:245
gem5::BaseRemoteGDB::QuerySetCommand::func
const Func func
Definition: remote_gdb.hh:354
gem5::BaseRemoteGDB::queryMap
static std::map< std::string, QuerySetCommand > queryMap
Definition: remote_gdb.hh:361
gem5::BaseRemoteGDB::recv
void recv(std::vector< char > &bp)
Definition: remote_gdb.cc:605
gem5::BaseRemoteGDB::cmdDetach
bool cmdDetach(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:928
gem5::ContextID
int ContextID
Globally unique thread context ID.
Definition: types.hh:246
gem5::BaseRemoteGDB::addThreadContext
void addThreadContext(ThreadContext *_tc)
Definition: remote_gdb.cc:443
gem5::BaseRemoteGDB::QuerySetCommand::Context::args
std::vector< std::string > args
Definition: remote_gdb.hh:346
gem5::BaseRemoteGDB::checkBpLen
virtual bool checkBpLen(size_t len)
Definition: remote_gdb.cc:881
gem5::BaseRemoteGDB::cmdMemR
bool cmdMemR(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:1000
gem5::BaseRemoteGDB::~BaseRemoteGDB
virtual ~BaseRemoteGDB()
Definition: remote_gdb.hh:57
gem5::BaseRemoteGDB::GdbCommand
Definition: remote_gdb.hh:301
gem5::BaseRemoteGDB::context
ThreadContext * context()
Definition: remote_gdb.hh:372
gem5::BaseRemoteGDB::QuerySetCommand::Context::Context
Context(const std::string &_name)
Definition: remote_gdb.hh:348
gem5::BaseRemoteGDB::system
System * system()
Definition: remote_gdb.hh:373
gem5::BaseRemoteGDB::singleStep
void singleStep()
Definition: remote_gdb.cc:727
gem5::BaseRemoteGDB
Definition: remote_gdb.hh:48
gem5::BaseRemoteGDB::SocketEvent::SocketEvent
SocketEvent(BaseRemoteGDB *gdb, int fd, int e)
Definition: remote_gdb.hh:203
gem5::BaseRemoteGDB::GdbCommand::Context::cmdByte
char cmdByte
Definition: remote_gdb.hh:307
gem5::BaseRemoteGDB::queryFThreadInfo
void queryFThreadInfo(QuerySetCommand::Context &ctx)
Definition: remote_gdb.cc:1132
gem5::BaseRemoteGDB::cmdCont
bool cmdCont(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:903
gem5::BaseRemoteGDB::threads
std::map< ContextID, ThreadContext * > threads
Definition: remote_gdb.hh:249
gem5
Reference material can be found at the JEDEC website: UFS standard http://www.jedec....
Definition: decoder.cc:40
gem5::BaseRemoteGDB::connect
void connect()
Definition: remote_gdb.cc:394
gem5::BaseRemoteGDB::insertHardBreak
void insertHardBreak(Addr addr, size_t len)
Definition: remote_gdb.cc:766
gem5::BaseRemoteGDB::dataEvent
DataEvent * dataEvent
Definition: remote_gdb.hh:217
gem5::BaseRemoteGDB::cmdAsyncStep
bool cmdAsyncStep(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:1232
gem5::BaseRemoteGDB::attached
bool attached
Definition: remote_gdb.hh:244
gem5::BaseRemoteGDB::threadInfoIdx
size_t threadInfoIdx
Definition: remote_gdb.hh:367
gem5::BaseRemoteGDB::cmdQueryVar
bool cmdQueryVar(GdbCommand::Context &ctx)
Definition: remote_gdb.cc:1152
gem5::BaseRemoteGDB::QuerySetCommand::Func
void(BaseRemoteGDB::*)(Context &ctx) Func
Definition: remote_gdb.hh:351
gem5::BaseGdbRegCache::~BaseGdbRegCache
virtual ~BaseGdbRegCache()
Definition: remote_gdb.hh:136
gem5::BaseRemoteGDB::TrapEvent::TrapEvent
TrapEvent(BaseRemoteGDB *g)
Definition: remote_gdb.hh:262
gem5::BaseRemoteGDB::querySThreadInfo
void querySThreadInfo(QuerySetCommand::Context &ctx)
Definition: remote_gdb.cc:1139
gem5::BaseRemoteGDB::GdbCommand::Context::len
int len
Definition: remote_gdb.hh:310
gem5::X86ISA::addr
Bitfield< 3 > addr
Definition: types.hh:84
gem5::BaseRemoteGDB::getbyte
uint8_t getbyte()
Definition: remote_gdb.cc:585
eventq.hh

Generated on Tue Sep 21 2021 12:24:45 for gem5 by doxygen 1.8.17