diff mbox

[1/6] core/test: run trace test last

Message ID 20170619060138.5314-1-oohall@gmail.com
State Changes Requested
Headers show

Commit Message

Oliver O'Halloran June 19, 2017, 6:01 a.m. UTC
The trace test takes the longest to run and is among the least useful
of the tests. Run it last so we're not stuck waiting for it when
some other test is more interesting.

Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
---
 core/test/Makefile.check | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

Comments

Stewart Smith July 5, 2017, 1:22 a.m. UTC | #1
Oliver O'Halloran <oohall@gmail.com> writes:
> The trace test takes the longest to run and is among the least useful
> of the tests. Run it last so we're not stuck waiting for it when
> some other test is more interesting.
>
> Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
> ---
>  core/test/Makefile.check | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)

Does this change really make a difference? You're running 'make check'
with -j, right?
Oliver O'Halloran July 7, 2017, 1:22 a.m. UTC | #2
On Wed, Jul 5, 2017 at 11:22 AM, Stewart Smith
<stewart@linux.vnet.ibm.com> wrote:
> Oliver O'Halloran <oohall@gmail.com> writes:
>> The trace test takes the longest to run and is among the least useful
>> of the tests. Run it last so we're not stuck waiting for it when
>> some other test is more interesting.
>>
>> Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
>> ---
>>  core/test/Makefile.check | 6 ++++--
>>  1 file changed, 4 insertions(+), 2 deletions(-)
>
> Does this change really make a difference? You're running 'make check'
> with -j, right?

It makes a difference when running on my laptop. It looks like when
`nproc` is less than the number of dependencies of the make target it
still runs them in order. The trace test ties up a core for a while so
moving it to last still speeds things up a bit.

Besides, on a build box with a lot of threads it's sometimes nice to
run it with -j1 just so you don't have to sift through the scroll back
to locate errors.

>
> --
> Stewart Smith
> OPAL Architect, IBM.
>
Stewart Smith July 10, 2017, 9:54 a.m. UTC | #3
Oliver <oohall@gmail.com> writes:
> On Wed, Jul 5, 2017 at 11:22 AM, Stewart Smith
> <stewart@linux.vnet.ibm.com> wrote:
>> Oliver O'Halloran <oohall@gmail.com> writes:
>>> The trace test takes the longest to run and is among the least useful
>>> of the tests. Run it last so we're not stuck waiting for it when
>>> some other test is more interesting.
>>>
>>> Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
>>> ---
>>>  core/test/Makefile.check | 6 ++++--
>>>  1 file changed, 4 insertions(+), 2 deletions(-)
>>
>> Does this change really make a difference? You're running 'make check'
>> with -j, right?
>
> It makes a difference when running on my laptop. It looks like when
> `nproc` is less than the number of dependencies of the make target it
> still runs them in order. The trace test ties up a core for a while so
> moving it to last still speeds things up a bit.

nproc is possibly also a single digit number, which is never a fun place
to be in. Mere double digits seems small and constrained these days...

I didn't see an improvement on my laptop, but then again, I generally 2x
nproc just to make the scheduler work for its dinner.

So, at least currently I don't see this regressing the test time
(although that could just be because we've added a bunch of tests and
duplicated things for p8/p9).

> Besides, on a build box with a lot of threads it's sometimes nice to
> run it with -j1 just so you don't have to sift through the scroll back
> to locate errors.

Yeah, that use case is always valid.
diff mbox

Patch

diff --git a/core/test/Makefile.check b/core/test/Makefile.check
index 355405042a7a..1467a9f6c27c 100644
--- a/core/test/Makefile.check
+++ b/core/test/Makefile.check
@@ -13,13 +13,15 @@  CORE_TEST := \
 	core/test/run-mem_region_reservations \
 	core/test/run-mem_range_is_reserved \
 	core/test/run-nvram-format \
-	core/test/run-trace core/test/run-msg \
 	core/test/run-pel \
 	core/test/run-pool \
 	core/test/run-time-utils \
 	core/test/run-timebase \
 	core/test/run-timer \
-	core/test/run-buddy
+	core/test/run-buddy \
+	core/test/run-msg \
+	core/test/run-trace
+# NB: The trace test takes forever, add new tests ABOVE run-trace
 
 HOSTCFLAGS+=-I . -I include