All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jiri Olsa <jolsa@redhat.com>
To: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Jiri Olsa <jolsa@kernel.org>, Namhyung Kim <namhyung@kernel.org>,
	Adrian Hunter <adrian.hunter@intel.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 1/1] perf build-test: Honour JOBS to override detection of
Date: Mon, 30 Mar 2020 15:16:33 +0200	[thread overview]
Message-ID: <20200330131633.GD2361248@krava> (raw)
In-Reply-To: <20200330130301.GA31702@kernel.org>

On Mon, Mar 30, 2020 at 10:03:01AM -0300, Arnaldo Carvalho de Melo wrote:
> Jiri,
> 
> 	Ack?

yep ;-)

Acked-by: Jiri Olsa <jolsa@kernel.org>

jirka

> 
> ----
> 
> When one does:
> 
>   $ make -C tools/perf build-test
> 
> The makefile in tools/perf/tests/ will, just like the main one, detect
> how many cores are in the system and use it with -j.
> 
> Sometimes we may need to override that, for instance, when using
> icecream or distcc to use multiple machines in the build process, then
> we need to, as with the main makefile, use:
> 
>   $ make JOBS=N -C tools/perf build-test
> 
> Fix the tests makefile to honour that.
> 
> Cc: Adrian Hunter <adrian.hunter@intel.com>
> Cc: Jiri Olsa <jolsa@kernel.org>
> Cc: Namhyung Kim <namhyung@kernel.org>
> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
> ---
>  tools/perf/tests/make | 10 +++++++---
>  1 file changed, 7 insertions(+), 3 deletions(-)
> 
> diff --git a/tools/perf/tests/make b/tools/perf/tests/make
> index c850d1664c56..5d0c3a9c47a1 100644
> --- a/tools/perf/tests/make
> +++ b/tools/perf/tests/make
> @@ -28,9 +28,13 @@ endif
>  
>  PARALLEL_OPT=
>  ifeq ($(SET_PARALLEL),1)
> -  cores := $(shell (getconf _NPROCESSORS_ONLN || egrep -c '^processor|^CPU[0-9]' /proc/cpuinfo) 2>/dev/null)
> -  ifeq ($(cores),0)
> -    cores := 1
> +  ifeq ($(JOBS),)
> +    cores := $(shell (getconf _NPROCESSORS_ONLN || egrep -c '^processor|^CPU[0-9]' /proc/cpuinfo) 2>/dev/null)
> +    ifeq ($(cores),0)
> +      cores := 1
> +    endif
> +  else
> +    cores=$(JOBS)
>    endif
>    PARALLEL_OPT="-j$(cores)"
>  endif
> -- 
> 2.25.1
> 


  reply	other threads:[~2020-03-30 13:16 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-30 13:03 [PATCH 1/1] perf build-test: Honour JOBS to override detection of Arnaldo Carvalho de Melo
2020-03-30 13:16 ` Jiri Olsa [this message]
2020-04-04  8:41 ` [tip: perf/urgent] perf build-test: Honour JOBS to override detection of number of cores tip-bot2 for Arnaldo Carvalho de Melo

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=20200330131633.GD2361248@krava \
    --to=jolsa@redhat.com \
    --cc=acme@kernel.org \
    --cc=adrian.hunter@intel.com \
    --cc=jolsa@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=namhyung@kernel.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.