From: Andi Shyti <andi.shyti@linux.intel.com>
To: Nirmoy Das <nirmoy.das@intel.com>
Cc: intel-gfx@lists.freedesktop.org, Chris Wilson <chris@chris-wilson.co.uk>
Subject: Re: [Intel-gfx] [PATCH] drm/i915/selftests: Reduce oversaturation of request smoketesting
Date: Thu, 3 Nov 2022 11:20:19 +0100 [thread overview]
Message-ID: <Y2OV45FrQWZFZZ0V@ashyti-mobl2.lan> (raw)
In-Reply-To: <20221102155709.31717-1-nirmoy.das@intel.com>
Hi Nirmoy,
On Wed, Nov 02, 2022 at 04:57:09PM +0100, Nirmoy Das wrote:
> From: Chris Wilson <chris@chris-wilson.co.uk>
>
> The goal in launching the request smoketest is to have sufficient tasks
> running across the system such that we are likely to detect concurrency
> issues. We aim to have 2 tasks using the same engine, gt, device (each
> level of locking around submission and signaling) running at the same
> time. While tasks may not be running all the time as they synchronise
> with the gpu, they will be running most of the time, in which case
> having many more tasks than cores available is wasteful (and
> dramatically increases the workload causing excess runtime). Aim to
> limit the number of tasks such that there is at least 2 running per
> engine, spreading surplus cores around the engines (rather than running
> a task per core per engine.)
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Pushed in intel-drm-gt-next.
Thanks,
Andi
> ---
> drivers/gpu/drm/i915/selftests/i915_request.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/selftests/i915_request.c b/drivers/gpu/drm/i915/selftests/i915_request.c
> index a46350c37e9d..4380473ceb98 100644
> --- a/drivers/gpu/drm/i915/selftests/i915_request.c
> +++ b/drivers/gpu/drm/i915/selftests/i915_request.c
> @@ -1710,7 +1710,8 @@ static int live_breadcrumbs_smoketest(void *arg)
> {
> struct drm_i915_private *i915 = arg;
> const unsigned int nengines = num_uabi_engines(i915);
> - const unsigned int ncpus = num_online_cpus();
> + const unsigned int ncpus = /* saturate with nengines * ncpus */
> + max_t(int, 2, DIV_ROUND_UP(num_online_cpus(), nengines));
> unsigned long num_waits, num_fences;
> struct intel_engine_cs *engine;
> struct smoke_thread *threads;
> @@ -1782,7 +1783,7 @@ static int live_breadcrumbs_smoketest(void *arg)
> goto out_flush;
> }
> /* One ring interleaved between requests from all cpus */
> - smoke[idx].max_batch /= num_online_cpus() + 1;
> + smoke[idx].max_batch /= ncpus + 1;
> pr_debug("Limiting batches to %d requests on %s\n",
> smoke[idx].max_batch, engine->name);
>
> --
> 2.38.0
prev parent reply other threads:[~2022-11-03 10:20 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-02 15:57 [Intel-gfx] [PATCH] drm/i915/selftests: Reduce oversaturation of request smoketesting Nirmoy Das
2022-11-02 17:30 ` Tvrtko Ursulin
2022-11-02 18:15 ` [Intel-gfx] ✓ Fi.CI.BAT: success for " Patchwork
2022-11-02 23:38 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
2022-11-03 8:45 ` Das, Nirmoy
2022-11-03 8:43 ` [Intel-gfx] [PATCH] " Das, Nirmoy
2022-11-03 10:20 ` Andi Shyti [this message]
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=Y2OV45FrQWZFZZ0V@ashyti-mobl2.lan \
--to=andi.shyti@linux.intel.com \
--cc=chris@chris-wilson.co.uk \
--cc=intel-gfx@lists.freedesktop.org \
--cc=nirmoy.das@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox