qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Slow down with: 'Make "info qom-tree" show children sorted'


From: Daniel P . Berrangé
Subject: Re: Slow down with: 'Make "info qom-tree" show children sorted'
Date: Tue, 7 Jul 2020 13:04:49 +0100
User-agent: Mutt/1.14.3 (2020-06-14)

On Tue, Jul 07, 2020 at 02:00:06PM +0200, Markus Armbruster wrote:
> Paolo Bonzini <pbonzini@redhat.com> writes:
> 
> > On 07/07/20 07:33, Markus Armbruster wrote:
> >> Philippe Mathieu-Daudé <philmd@redhat.com> writes:
> >> 
> >>> On 7/7/20 6:45 AM, Thomas Huth wrote:
> >>>> On 27/05/2020 10.47, Markus Armbruster wrote:
> >>>>> "info qom-tree" prints children in unstable order.  This is a pain
> >>>>> when diffing output for different versions to find change.  Print it
> >>>>> sorted.
> >>>>>
> >>>>> Signed-off-by: Markus Armbruster <armbru@redhat.com>
> >>>>> ---
> >>>>>  qom/qom-hmp-cmds.c | 24 ++++++++++++++++--------
> >>>>>  1 file changed, 16 insertions(+), 8 deletions(-)
> >>>>
> >>>>  Hi Markus,
> >>>>
> >>>> this patch causes a slow down of the qtests which becomes quite massive
> >>>> when e.g. using the ppc64 and thourough testing. When I'm running
> >>>>
> >>>> QTEST_QEMU_BINARY="ppc64-softmmu/qemu-system-ppc64" time \
> >>>> ./tests/qtest/device-introspect-test -m slow | tail -n 10
> >>>>
> >>>> the test runs for ca. 6m40s here before the patch got applied, and for
> >>>> mor than 20 minutes after the patch got applied!
> >> 
> >> That's surprising.
> >
> > It's a bit surprising indeed, but on the other hand using
> > g_queue_insert_sorted results in a quadratic loop.
> 
> The surprising part is that n turns out to be large enough for n^2 to
> matter *that* much.

The test suite as a whole is more like n^3  because it is running
sooooo many repeats of "info qom-tree"

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




reply via email to

[Prev in Thread] Current Thread [Next in Thread]