All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Maydell <peter.maydell@linaro.org>
To: Michael Roth <mdroth@linux.vnet.ibm.com>
Cc: "QEMU Trivial" <qemu-trivial@nongnu.org>,
	"QEMU Developers" <qemu-devel@nongnu.org>,
	"Andreas Färber" <afaerber@suse.de>
Subject: Re: [Qemu-devel] [PATCH] tests: avoid running duplicate qom-tests
Date: Thu, 18 Sep 2014 16:18:08 -0700	[thread overview]
Message-ID: <CAFEAcA-yFgahc7k0tZ5i9O2-tn5g+pzXDUooxTk-gCDQSUZC_A@mail.gmail.com> (raw)
In-Reply-To: <1411081173-14618-1-git-send-email-mdroth@linux.vnet.ibm.com>

On 18 September 2014 15:59, Michael Roth <mdroth@linux.vnet.ibm.com> wrote:
> Since 3687d532 we've been unconditionally adding qom-test to our qtests
> for every arch. However, some archs inherit their tests from Makefile
> variables for other archs, such as i386/x86_64,
> microblaze/microblazeel, and xtensa/xtensaeb. Since these are evaluated
> in a lazy manner, we ultimately end up adding qom-test twice.
>
> In the case x86_64, where we have a large number of machine types that
> we rerun qom-test for, this has lead to a fairly noticeable increase
> in the overall run-time of `make check` (78s vs. 42s on my machine).
> Similar speed-ups are visible for other such archs, but not nearly as
> significant.
>
> Fix this by only adding qom-test to an arch's test list if it's not
> already present.
>
> Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
> ---
>  tests/Makefile | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/tests/Makefile b/tests/Makefile
> index a5e3d0c..9f2a35c 100644
> --- a/tests/Makefile
> +++ b/tests/Makefile
> @@ -192,7 +192,8 @@ check-qtest-xtensaeb-y = $(check-qtest-xtensa-y)
>
>  # qom-test works for all sysemu architectures:
>  $(foreach target,$(SYSEMU_TARGET_LIST), \
> -    $(eval check-qtest-$(target)-y += tests/qom-test$(EXESUF)))
> +       $(if $(findstring tests/qom-test$(EXESUF), $(check-qtest-$(target)-y)),, \
> +               $(eval check-qtest-$(target)-y += tests/qom-test$(EXESUF))))

See also Andreas' suggested fix:
https://lists.gnu.org/archive/html/qemu-devel/2014-04/msg01087.html
and mine:
https://lists.gnu.org/archive/html/qemu-devel/2014-03/msg05771.html

Andreas didn't like my patch because it sorts all the tests
as a side effect, and I didn't like the hard-coded listing
of architectures in Andreas' patch. It looks like maybe your
version will satisfy both of us :-)

Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

thanks
-- PMM

  reply	other threads:[~2014-09-18 23:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-18 22:59 [Qemu-devel] [PATCH] tests: avoid running duplicate qom-tests Michael Roth
2014-09-18 23:18 ` Peter Maydell [this message]
2014-09-24  8:00 ` [Qemu-devel] [Qemu-trivial] " Michael Tokarev

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=CAFEAcA-yFgahc7k0tZ5i9O2-tn5g+pzXDUooxTk-gCDQSUZC_A@mail.gmail.com \
    --to=peter.maydell@linaro.org \
    --cc=afaerber@suse.de \
    --cc=mdroth@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-trivial@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.