mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Tejun Heo <tj@kernel.org>
To: David Vernet <void@manifault.com>
Cc: linux-kernel@vger.kernel.org, sched-ext@meta.com,
	kernel-team@meta.com, Waiman Long <llong@redhat.com>
Subject: Re: [PATCH for-6.12-fixes] sched_ext: Remove unnecessary cpu_relax()
Date: Mon, 14 Oct 2024 13:24:57 -1000	[thread overview]
Message-ID: <Zw2oSWEJ8LJG6454@slm.duckdns.org> (raw)
In-Reply-To: <20241014175830.5108-1-void@manifault.com>

On Mon, Oct 14, 2024 at 12:58:30PM -0500, David Vernet wrote:
> As described in commit b07996c7abac ("sched_ext: Don't hold
> scx_tasks_lock for too long"), we're doing a cond_resched() every 32
> calls to scx_task_iter_next() to avoid RCU and other stalls. That commit
> also added a cpu_relax() to the codepath where we drop and reacquire the
> lock, but as Waiman described in [0], cpu_relax() should only be
> necessary in busy loops to avoid pounding on a cacheline (or to allow a
> hypertwin to more fully utilize a core).
> 
> Let's remove the unnecessary cpu_relax().
> 
> [0]: https://lore.kernel.org/all/35b3889b-904a-4d26-981f-c8aa1557a7c7@redhat.com/
> 
> Cc: Waiman Long <llong@redhat.com>
> Signed-off-by: David Vernet <void@manifault.com>

Applied to sched_ext/for-6.12-fixes.

Thanks.

-- 
tejun

      reply	other threads:[~2024-10-14 23:24 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-14 17:58 David Vernet
2024-10-14 23:24 ` Tejun Heo [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=Zw2oSWEJ8LJG6454@slm.duckdns.org \
    --to=tj@kernel.org \
    --cc=kernel-team@meta.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=llong@redhat.com \
    --cc=sched-ext@meta.com \
    --cc=void@manifault.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

all inboxes | Powered by JetHome®