From: "Alex Bennée" <alex.bennee@linaro.org>
To: Peter Maydell <peter.maydell@linaro.org>
Cc: Paolo Bonzini <pbonzini@redhat.com>,
Ivan Shcherbakov <ivan@sysprogs.com>,
qemu-devel@nongnu.org, armbru@redhat.com, mst@redhat.com
Subject: Re: [PATCH 3/3] whpx: Added support for breakpoints and stepping
Date: Thu, 24 Feb 2022 11:22:10 +0000 [thread overview]
Message-ID: <87v8x433o2.fsf@linaro.org> (raw)
In-Reply-To: <CAFEAcA_y=xRhBoStyxa+UZcyibAzgcJSf+kQO4e0BMrdq4j6Jg@mail.gmail.com>
Peter Maydell <peter.maydell@linaro.org> writes:
> On Wed, 23 Feb 2022 at 20:08, Ivan Shcherbakov <ivan@sysprogs.com> wrote:
>>
>
>> static GDBState gdbserver_state;
>> +static bool gdbserver_is_connected;
>> +
>> +bool gdb_is_connected(void)
>> +{
>> + return gdbserver_is_connected;
>> +}
>
> I haven't looked at the rest of the patch -- but can you explain where
> whpx is different from how other accelerators handle debug such that
> it needs to know whether gdb is connected or not ?
It's backwards from how it should work. I don't know about the other
accelerators but in the KVM case the gdbserver handles the requests for
installing breakpoints and watchpoints and if KVM is enabled passes them
onto the arch specific code.
When QEMU prepares to enter the run loop it checks for the presence of
those things and then can make the arch specific decision about how to
invoke KVM (see kvm_update_guest_debug and friends).
Just the fact you have connected to the gdbserver shouldn't affect how
you run WHPX up until the point there are things you need to trap - i.e.
handling installed breakpoints.
FWIW we rejected a similar patch a few weeks ago that wanted to change
emulation behaviour based on gdbserver connection status.
>
> thanks
> -- PMM
--
Alex Bennée
next prev parent reply other threads:[~2022-02-24 11:29 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-23 5:25 [PATCH 3/3] whpx: Added support for breakpoints and stepping Ivan Shcherbakov
2022-02-23 9:36 ` Paolo Bonzini
2022-02-23 20:05 ` Ivan Shcherbakov
2022-02-24 9:35 ` Peter Maydell
2022-02-24 11:22 ` Alex Bennée [this message]
2022-02-24 15:54 ` Ivan Shcherbakov
2022-02-28 4:31 ` Ivan Shcherbakov
2022-02-28 10:28 ` Alex Bennée
2022-03-01 2:08 ` Ivan Shcherbakov
2022-03-02 2:06 ` Ivan Shcherbakov
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=87v8x433o2.fsf@linaro.org \
--to=alex.bennee@linaro.org \
--cc=armbru@redhat.com \
--cc=ivan@sysprogs.com \
--cc=mst@redhat.com \
--cc=pbonzini@redhat.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).