x86: Implement a remote GDB stub.
Review Request #2542 - Created Nov. 25, 2014 and submitted
| Information | |
|---|---|
| Gabe Black | |
| gem5 | |
| default | |
| Reviewers | |
| Default | |
Changeset 10600:2f874ecfc989 --------------------------- x86: Implement a remote GDB stub. This stub should allow remote debugging of 32 bit and 64 bit targets. Single stepping seems to work, as do breakpoints. If both breakpoints and single stepping affect an instruction, gdb will stop at the instruction twice before continuing. That's a little surprising, but is generally harmless.
Posted (Dec. 4, 2014, 11:16 a.m.)
-
src/arch/x86/remote_gdb.hh (Diff revision 1) -
this equation could use a comment
-
src/arch/x86/remote_gdb.hh (Diff revision 1) -
same here
-
src/arch/x86/remote_gdb.cc (Diff revision 1) -
Given that these two lines to grab the right comInstEventQueue appear twice here and once in patch 2540, it would be nice to wrap them up in a little helper method on the RemoteGDB object. In fact, adding something like: EventQueue * RemoteGDB::commitQueue() { return context->getCpuPtr()->comInstEventQueue[context->threadId()]; } void RemoteGDB::scheduleCommitEvent(Event *ev, int delta) { EventQueue *eq = commitQueue(); eq->schedule(ev, eq->getCurTick() + delta); } and then doing everything else in terms of these two functions would IMO make the rest of the code much more readable.
Review request changed
Updated (Dec. 5, 2014, 2:45 a.m.)
Description: |
|
|||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 2 (+263 -27) |
Review request changed
Updated (Dec. 5, 2014, 2:46 a.m.)
Description: |
|
||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 3 (+263 -27) |
Ship It!
