Commit graph

307 commits

Author SHA1 Message Date
StrikerX3 d60e1cafcb Fix GDB server on Windows 2018-01-23 07:42:23 -02:00
StrikerX3 8adecb5c2d Windows build support with VS 2017 2018-01-20 18:56:30 -02:00
Matt Borgerson 126fbd13a5 Fix issue with GDB breakpoints
This patch fixes an issue with GDB breakpoints where continuing after a
breakpoint would cause an invalid instruction exception. This was due
to how GDB sets soft breakpoints, and how Unicorn records the state
after emulation is halted.

GDB sets soft breakpoints using the single byte `int3` instruction
(CCh).  After the instruction executes, EIP will point to the next
instruction, which is likely to be in the middle of the instruction we
are trying to break on! In this case, roll EIP back by 1 so that when
GDB resumes execution, EIP is will be in the correct place.

An issue with calling kernel functions is also fixed. This was due to
how `hlt` instructions are used to enter kernel functions. If we are
single stepping code, execution will stop before the `hlt` is executed
but the code which looks to see if we are entering a kernel function
would execute and incorrectly calculate the import number.
2017-12-27 14:08:57 -07:00
Matt Borgerson 803f16b752 Update README 2017-12-25 21:37:23 -07:00
Matt Borgerson 94af31d238 Add GDB server to enable CPU debug
This patch adds support for remote debugging of the guest via the GDB
debugger. Once enabled, the emulator will open a TCP socket and wait
for the GDB client to connect upon startup before beginning XBE
execution.
2017-12-22 15:31:59 -07:00
Matt Borgerson 0737574f21 Add basic system framework
This patch adds just enough to initialize the system, load an XBE,
handle a couple of Kernel functions, and render the framebuffer. No
audio, networking, 3D graphics, or even real Kernel functions yet.
2017-12-16 02:32:11 -07:00
Matt Borgerson 16013a6529 Initial commit 2017-12-04 15:23:54 -07:00