All of lore.kernel.org
 help / color / mirror / Atom feed
From: Steven Raasch <sraasch@gmail.com>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: Extracting PC information from QEMU/KVM during single-step
Date: Thu, 24 Jun 2021 14:36:32 -0500	[thread overview]
Message-ID: <CA+5M2MChKqjHEYEb2dD1B=BtxYr0vSVSDu=GpyDb=7M6+g5h6A@mail.gmail.com> (raw)
In-Reply-To: <CAFEAcA-VVwVvPC0qSWZc0c8evWO9FyBO7FqtjrE=HOK1d0GayQ@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1362 bytes --]

Peter -

Thanks for the clarification, that makes perfect sense.

In this case, using GDB is clearly the best way to go about the tracing.

I appreciate your time!

-S

On Thu, Jun 24, 2021 at 1:51 PM Peter Maydell <peter.maydell@linaro.org>
wrote:

> 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
>

[-- Attachment #2: Type: text/html, Size: 1857 bytes --]

      reply	other threads:[~2021-06-24 19:38 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-23 20:14 Extracting PC information from QEMU/KVM during single-step Steven Raasch
2021-06-24  1:45 ` Alexander Bulekov
2021-06-24 13:49   ` Steven Raasch
2021-06-24 14:41     ` Alexander Bulekov
2021-06-24 16:22 ` Peter Maydell
2021-06-24 17:08   ` Steven Raasch
2021-06-24 18:51     ` Peter Maydell
2021-06-24 19:36       ` Steven Raasch [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CA+5M2MChKqjHEYEb2dD1B=BtxYr0vSVSDu=GpyDb=7M6+g5h6A@mail.gmail.com' \
    --to=sraasch@gmail.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.