[Qemu-devel] [PATCH 2/2] qmp: document query-cpus performance issue

Luiz Capitulino posted 2 patches 8 years ago
There is a newer version of this series
[Qemu-devel] [PATCH 2/2] qmp: document query-cpus performance issue
Posted by Luiz Capitulino 8 years ago
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
---
 qapi-schema.json | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/qapi-schema.json b/qapi-schema.json
index 82d6f12b53..0665a14dba 100644
--- a/qapi-schema.json
+++ b/qapi-schema.json
@@ -526,6 +526,10 @@
 #
 # Returns a list of information about each virtual CPU.
 #
+# WARNING: This command incurs a performance penalty for latency
+#          sensitive workloads and hence it's not recommended to
+#          to be used in production. Use query-cpus-fast instead
+#
 # Returns: a list of @CpuInfo for each virtual CPU
 #
 # Since: 0.14.0
-- 
2.14.3


Re: [Qemu-devel] [PATCH 2/2] qmp: document query-cpus performance issue
Posted by Eric Blake 8 years ago
On 02/07/2018 11:50 AM, Luiz Capitulino wrote:
> Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
> ---
>   qapi-schema.json | 4 ++++
>   1 file changed, 4 insertions(+)
> 
> diff --git a/qapi-schema.json b/qapi-schema.json
> index 82d6f12b53..0665a14dba 100644
> --- a/qapi-schema.json
> +++ b/qapi-schema.json
> @@ -526,6 +526,10 @@
>   #
>   # Returns a list of information about each virtual CPU.
>   #
> +# WARNING: This command incurs a performance penalty for latency
> +#          sensitive workloads and hence it's not recommended to
> +#          to be used in production. Use query-cpus-fast instead
> +#

Ah, I asked for this on 1/2.  You could squash these.

I didn't review the code, just the interface, so if you squash them, you 
can add the weaker:

Acked-by: Eric Blake <eblake@redhat.com>

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org

Re: [Qemu-devel] [PATCH 2/2] qmp: document query-cpus performance issue
Posted by Luiz Capitulino 8 years ago
On Wed, 7 Feb 2018 12:50:59 -0600
Eric Blake <eblake@redhat.com> wrote:

> On 02/07/2018 11:50 AM, Luiz Capitulino wrote:
> > Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
> > ---
> >   qapi-schema.json | 4 ++++
> >   1 file changed, 4 insertions(+)
> > 
> > diff --git a/qapi-schema.json b/qapi-schema.json
> > index 82d6f12b53..0665a14dba 100644
> > --- a/qapi-schema.json
> > +++ b/qapi-schema.json
> > @@ -526,6 +526,10 @@
> >   #
> >   # Returns a list of information about each virtual CPU.
> >   #
> > +# WARNING: This command incurs a performance penalty for latency
> > +#          sensitive workloads and hence it's not recommended to
> > +#          to be used in production. Use query-cpus-fast instead
> > +#  
> 
> Ah, I asked for this on 1/2.  You could squash these.
> 
> I didn't review the code, just the interface, so if you squash them, you 
> can add the weaker:
> 
> Acked-by: Eric Blake <eblake@redhat.com>

OK, I'll wait for more review and do the changes you requested.

Re: [Qemu-devel] [PATCH 2/2] qmp: document query-cpus performance issue
Posted by Daniel P. Berrangé 8 years ago
On Wed, Feb 07, 2018 at 12:50:14PM -0500, Luiz Capitulino wrote:
> Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
> ---
>  qapi-schema.json | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/qapi-schema.json b/qapi-schema.json
> index 82d6f12b53..0665a14dba 100644
> --- a/qapi-schema.json
> +++ b/qapi-schema.json
> @@ -526,6 +526,10 @@
>  #
>  # Returns a list of information about each virtual CPU.
>  #
> +# WARNING: This command incurs a performance penalty for latency
> +#          sensitive workloads and hence it's not recommended to
> +#          to be used in production. Use query-cpus-fast instead

I suggest being more explicit about exactly what the problem is, so people
understand implications if they choose to still use it. ie

  This command causes vCPU threads to exit to userspace, which causes
  an small interruption guest CPU execution. This will have a negative
  impact on realtime guests and other latency sensitive guest workloads.
  It is recommended to use query-cpus-fast instead of this command to
  avoid the vCPU interruption.

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

Re: [Qemu-devel] [PATCH 2/2] qmp: document query-cpus performance issue
Posted by Luiz Capitulino 8 years ago
On Thu, 8 Feb 2018 09:29:28 +0000
Daniel P. Berrangé <berrange@redhat.com> wrote:

> On Wed, Feb 07, 2018 at 12:50:14PM -0500, Luiz Capitulino wrote:
> > Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
> > ---
> >  qapi-schema.json | 4 ++++
> >  1 file changed, 4 insertions(+)
> > 
> > diff --git a/qapi-schema.json b/qapi-schema.json
> > index 82d6f12b53..0665a14dba 100644
> > --- a/qapi-schema.json
> > +++ b/qapi-schema.json
> > @@ -526,6 +526,10 @@
> >  #
> >  # Returns a list of information about each virtual CPU.
> >  #
> > +# WARNING: This command incurs a performance penalty for latency
> > +#          sensitive workloads and hence it's not recommended to
> > +#          to be used in production. Use query-cpus-fast instead  
> 
> I suggest being more explicit about exactly what the problem is, so people
> understand implications if they choose to still use it. ie

I'll add your text.

> 
>   This command causes vCPU threads to exit to userspace, which causes
>   an small interruption guest CPU execution. This will have a negative
>   impact on realtime guests and other latency sensitive guest workloads.
>   It is recommended to use query-cpus-fast instead of this command to
>   avoid the vCPU interruption.
> 
> Regards,
> Daniel