[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 22/22] qapi: introduce x-query-opcount QMP command
From: |
Daniel P . Berrangé |
Subject: |
Re: [PATCH v4 22/22] qapi: introduce x-query-opcount QMP command |
Date: |
Mon, 1 Nov 2021 15:58:38 +0000 |
User-agent: |
Mutt/2.0.7 (2021-05-04) |
On Thu, Oct 28, 2021 at 07:08:13PM +0200, Philippe Mathieu-Daudé wrote:
> On 10/28/21 17:54, Daniel P. Berrangé wrote:
> > This is a counterpart to the HMP "info opcount" command. It is being
> > added with an "x-" prefix because this QMP command is intended as an
> > ad hoc debugging tool and will thus not be modelled in QAPI as fully
> > structured data, nor will it have long term guaranteed stability.
> > The existing HMP command is rewritten to call the QMP command.
> >
> > Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
> > ---
> > accel/tcg/cpu-exec.c | 14 ++++++++++++++
> > accel/tcg/hmp.c | 7 +------
> > accel/tcg/translate-all.c | 4 ++--
> > include/exec/cpu-all.h | 2 +-
> > include/tcg/tcg.h | 2 +-
> > qapi/machine.json | 13 +++++++++++++
> > tcg/tcg.c | 10 +++++-----
> > tests/qtest/qmp-cmd-test.c | 1 +
> > 8 files changed, 38 insertions(+), 15 deletions(-)
> >
> > diff --git a/accel/tcg/cpu-exec.c b/accel/tcg/cpu-exec.c
> > index 4212645cb6..7a7e813207 100644
> > --- a/accel/tcg/cpu-exec.c
> > +++ b/accel/tcg/cpu-exec.c
> > @@ -1066,4 +1066,18 @@ HumanReadableText *qmp_x_query_jit(Error **errp)
> > return human_readable_text_from_str(buf);
> > }
> >
> > +HumanReadableText *qmp_x_query_opcount(Error **errp)
> > +{
> > + g_autoptr(GString) buf = g_string_new("");
> > +
> > + if (!tcg_enabled()) {
> > + error_setg(errp, "JIT information is only available with
> > accel=tcg");
>
> s/JIT/Opcode count/ ? Otherwise,
Opps, yes.
> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [PATCH v4 22/22] qapi: introduce x-query-opcount QMP command,
Daniel P . Berrangé <=