linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Michael Ellerman <patch-notifications@ellerman.id.au>
To: Michael Ellerman <mpe@ellerman.id.au>, linuxppc-dev@ozlabs.org
Cc: juri.lelli@redhat.com, parth@linux.ibm.com, pauld@redhat.com,
	srikar@linux.vnet.ibm.com, ego@linux.vnet.ibm.com,
	Ihor.Pasichnyk@ibm.com, longman@redhat.com
Subject: Re: [PATCH v5 1/2] powerpc/vcpu: Assume dedicated processors as non-preempt
Date: Sat, 14 Dec 2019 08:19:39 +1100 (AEDT)	[thread overview]
Message-ID: <47ZNpg6rD7z9sPW@ozlabs.org> (raw)
In-Reply-To: <20191213035036.6913-1-mpe@ellerman.id.au>

On Fri, 2019-12-13 at 03:50:35 UTC, Michael Ellerman wrote:
> From: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
> 
> With commit 247f2f6f3c70 ("sched/core: Don't schedule threads on
> pre-empted vCPUs"), the scheduler avoids preempted vCPUs to schedule
> tasks on wakeup. This leads to wrong choice of CPU, which in-turn
> leads to larger wakeup latencies. Eventually, it leads to performance
> regression in latency sensitive benchmarks like soltp, schbench etc.
> 
> On Powerpc, vcpu_is_preempted() only looks at yield_count. If the
> yield_count is odd, the vCPU is assumed to be preempted. However
> yield_count is increased whenever the LPAR enters CEDE state (idle).
> So any CPU that has entered CEDE state is assumed to be preempted.
> 
> Even if vCPU of dedicated LPAR is preempted/donated, it should have
> right of first-use since they are supposed to own the vCPU.
...
> 
> Waiman Long suggested using static_keys.
> 
> Fixes: 247f2f6f3c70 ("sched/core: Don't schedule threads on pre-empted vCPUs")
> Cc: stable@vger.kernel.org # v4.18+
> Reported-by: Parth Shah <parth@linux.ibm.com>
> Reported-by: Ihor Pasichnyk <Ihor.Pasichnyk@ibm.com>
> Tested-by: Juri Lelli <juri.lelli@redhat.com>
> Acked-by: Waiman Long <longman@redhat.com>
> Reviewed-by: Gautham R. Shenoy <ego@linux.vnet.ibm.com>
> Signed-off-by: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
> Acked-by: Phil Auld <pauld@redhat.com>
> Reviewed-by: Vaidyanathan Srinivasan <svaidy@linux.ibm.com>
> Tested-by: Parth Shah <parth@linux.ibm.com>
> [mpe: Move the key and setting of the key to pseries/setup.c]
> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>

Series applied to powerpc fixes.

https://git.kernel.org/powerpc/c/14c73bd344da60abaf7da3ea2e7733ddda35bbac

cheers

      parent reply	other threads:[~2019-12-13 21:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-13  3:50 [PATCH v5 1/2] powerpc/vcpu: Assume dedicated processors as non-preempt Michael Ellerman
2019-12-13  3:50 ` [PATCH v5 2/2] powerpc/shared: Use static key to detect shared processor Michael Ellerman
2019-12-13  5:07 ` [PATCH v5 1/2] powerpc/vcpu: Assume dedicated processors as non-preempt Srikar Dronamraju
2019-12-13 10:06   ` Michael Ellerman
2019-12-13 21:19 ` Michael Ellerman [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=47ZNpg6rD7z9sPW@ozlabs.org \
    --to=patch-notifications@ellerman.id.au \
    --cc=Ihor.Pasichnyk@ibm.com \
    --cc=ego@linux.vnet.ibm.com \
    --cc=juri.lelli@redhat.com \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=longman@redhat.com \
    --cc=mpe@ellerman.id.au \
    --cc=parth@linux.ibm.com \
    --cc=pauld@redhat.com \
    --cc=srikar@linux.vnet.ibm.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;
as well as URLs for NNTP newsgroup(s).