From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
To: "Emilio G. Cota" <cota@braap.org>
Cc: qemu-devel@nongnu.org, Paolo Bonzini <pbonzini@redhat.com>,
Peter Crosthwaite <crosthwaite.peter@gmail.com>,
Richard Henderson <rth@twiddle.net>, Stefan Weil <sw@weilnetz.de>,
Markus Armbruster <armbru@redhat.com>,
Peter Xu <peterx@redhat.com>
Subject: Re: [Qemu-devel] [PATCH 2/3] monitor: show sync profiling info with 'info sync'
Date: Tue, 14 Aug 2018 10:43:47 +0100 [thread overview]
Message-ID: <20180814094347.GE2580@work-vm> (raw)
In-Reply-To: <20180813171132.21939-3-cota@braap.org>
* Emilio G. Cota (cota@braap.org) wrote:
> Signed-off-by: Emilio G. Cota <cota@braap.org>
> ---
> monitor.c | 7 +++++++
> hmp-commands-info.hx | 16 ++++++++++++++++
> 2 files changed, 23 insertions(+)
>
> diff --git a/monitor.c b/monitor.c
> index 77861e96af..66d8d85b97 100644
> --- a/monitor.c
> +++ b/monitor.c
> @@ -1454,6 +1454,13 @@ static void hmp_info_opcount(Monitor *mon, const QDict *qdict)
> }
> #endif
>
> +static void hmp_info_sync(Monitor *mon, const QDict *qdict)
> +{
> + int64_t max = qdict_get_try_int(qdict, "max", 10);
> +
> + qsp_report((FILE *)mon, monitor_fprintf, max);
> +}
> +
> static void hmp_info_history(Monitor *mon, const QDict *qdict)
> {
> int i;
> diff --git a/hmp-commands-info.hx b/hmp-commands-info.hx
> index 70639f656a..56a3249bad 100644
> --- a/hmp-commands-info.hx
> +++ b/hmp-commands-info.hx
> @@ -297,6 +297,22 @@ STEXI
> @item info opcount
> @findex info opcount
> Show dynamic compiler opcode counters
> +ETEXI
> +
> + {
> + .name = "sync",
> + .args_type = "max:i?",
> + .params = "[max]",
> + .help = "show sync profiling info for "
> + "up to max entries (default: 10). "
> + "Entries are sorted by wait time.",
> + .cmd = hmp_info_sync,
> + },
> +
> +STEXI
> +@item info sync
> +@findex sync
> +Show sync profiling info.
> ETEXI
>
> {
As long as this is just for devs I'm OK with this from the HMP side;
however, if you want to automate the display or wire it to other
tools then you should probably wire it up via QMP.
Dave
> --
> 2.17.1
>
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK
next prev parent reply other threads:[~2018-08-14 9:43 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-13 17:11 [Qemu-devel] [PATCH 0/3] synchronization profiler Emilio G. Cota
2018-08-13 17:11 ` [Qemu-devel] [PATCH 1/3] qsp: QEMU's Synchronization Profiler Emilio G. Cota
2018-08-14 8:13 ` Paolo Bonzini
2018-08-15 0:44 ` Emilio G. Cota
2018-08-15 4:29 ` Markus Armbruster
2018-08-15 3:09 ` Fam Zheng
2018-08-15 4:53 ` Emilio G. Cota
2018-08-15 7:04 ` Fam Zheng
2018-08-15 23:55 ` Emilio G. Cota
2018-08-16 4:29 ` Emilio G. Cota
2018-08-16 4:36 ` Fam Zheng
2018-08-13 17:11 ` [Qemu-devel] [PATCH 2/3] monitor: show sync profiling info with 'info sync' Emilio G. Cota
2018-08-14 8:14 ` Paolo Bonzini
2018-08-15 1:26 ` Emilio G. Cota
2018-08-16 13:20 ` Peter Xu
2018-08-14 9:43 ` Dr. David Alan Gilbert [this message]
2018-08-15 1:33 ` Emilio G. Cota
2018-08-14 16:03 ` Markus Armbruster
2018-08-13 17:11 ` [Qemu-devel] [PATCH 3/3] qsp: track BQL callers directly Emilio G. Cota
2018-08-15 23:30 ` [Qemu-devel] [PATCH 0/3] synchronization profiler no-reply
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=20180814094347.GE2580@work-vm \
--to=dgilbert@redhat.com \
--cc=armbru@redhat.com \
--cc=cota@braap.org \
--cc=crosthwaite.peter@gmail.com \
--cc=pbonzini@redhat.com \
--cc=peterx@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=rth@twiddle.net \
--cc=sw@weilnetz.de \
/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).