|
From: | Steven Raasch |
Subject: | Re: Extracting PC information from QEMU/KVM during single-step |
Date: | Thu, 24 Jun 2021 14:36:32 -0500 |
On Thu, 24 Jun 2021 at 18:09, Steven Raasch <sraasch@gmail.com> wrote:
> NOTE: I do not yet understand how gdb interacts with the virtual machine. I have experience with GDB, but only at a linux app-debug level. I don't grok how gdb on a linux host works with QEMU running a windows guest.
> My *assumption* is that the VM continues to run while an app is being debugged with GDB can be stopped, stepped, etc. If this is the case, I would expect that the VM's sense of time will continue to move forward while the app is paused. This would be an issue for my time-sensitive app.
No, that's not how it works. A gdb connected to QEMU's gdbstub is a
bit like a hardware JTAG debugger connected to a real CPU, if that
helps. When gdb gets control the entire VM is stopped; stepping
steps one instruction of whatever the VM is doing. gdb and the
gdbstub have no understanding of individual processes running
inside the guest OS -- single stepping will happily step through
the app, into interrupt handlers, across the OS context switching
and into other processes, etc.
-- PMM
[Prev in Thread] | Current Thread | [Next in Thread] |