From: Changwoo Min <changwoo@igalia.com>
To: Tejun Heo <tj@kernel.org>
Cc: Changwoo Min <multics69@gmail.com>,
void@manifault.com, mingo@redhat.com, peterz@infradead.org,
kernel-dev@igalia.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 2/5] sched_ext: Manage the validity of scx_rq_clock
Date: Fri, 6 Dec 2024 10:50:35 +0900 [thread overview]
Message-ID: <9b6bff28-b5b3-435d-899b-5da8acaa9882@igalia.com> (raw)
In-Reply-To: <Z1CjiYdeYMzxZNuo@slm.duckdns.org>
Hello,
On 24. 12. 5. 03:46, Tejun Heo wrote:
> Hello,
>
> On Wed, Dec 04, 2024 at 10:42:13AM +0900, Changwoo Min wrote:
>> I investigated all sched_ext_ops. Besides these two ops, all the
>> rest are control operations, of which BPF operation should be
>> relatively simple. On the other hand, ops.running() and
>> ops.update_idle() are different from the others since a CPU
>> executes a task or becomes idle, which could be arbitrarily long.
>> So I think refreshing the clock in those cases would be nice.
>> Does it make sense to you?
>
> Hmm... I'm not really following. Both ops.running() and ops.update_idle()
> are called during task switches with rq lock held. I don't see why they'd be
> any different in terms of expected runtime, which should be pretty short,
> compared to any other rq-locked operations.
Originally, what I wanted to say is the rq clock *after*
ops.running() and ops.update_idle() should be invalidated since
task running and idling could be arbitrarily long.
However, after double-checking the scheduler core again, I found
that such invalidations are redundant because anyway rq lock will
be released right after ops.running() and ops.update_idle().
I will remove two redundant invalidation in the next version.
Regards,
Changwoo Min
next prev parent reply other threads:[~2024-12-06 1:51 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-03 14:27 [PATCH v3 0/5] sched_ext: Support high-performance monotonically non-decreasing clock Changwoo Min
2024-12-03 14:27 ` [PATCH v3 1/5] sched_ext: Implement scx_rq_clock_update/stale() Changwoo Min
2024-12-03 23:23 ` Tejun Heo
2024-12-04 1:28 ` Changwoo Min
2024-12-03 14:27 ` [PATCH v3 2/5] sched_ext: Manage the validity of scx_rq_clock Changwoo Min
2024-12-03 23:26 ` Tejun Heo
2024-12-04 1:42 ` Changwoo Min
2024-12-04 18:46 ` Tejun Heo
2024-12-06 1:50 ` Changwoo Min [this message]
2024-12-03 14:28 ` [PATCH v3 3/5] sched_ext: Implement scx_bpf_clock_get_ns() Changwoo Min
2024-12-03 23:37 ` Tejun Heo
2024-12-04 5:17 ` Changwoo Min
2024-12-03 14:28 ` [PATCH v3 4/5] sched_ext: Add scx_bpf_clock_get_ns() for BPF scheduler Changwoo Min
2024-12-03 14:28 ` [PATCH v3 5/5] sched_ext: Replace bpf_ktime_get_ns() to scx_bpf_clock_get_ns() Changwoo Min
2024-12-03 23:40 ` Tejun Heo
2024-12-04 5:41 ` Changwoo Min
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=9b6bff28-b5b3-435d-899b-5da8acaa9882@igalia.com \
--to=changwoo@igalia.com \
--cc=kernel-dev@igalia.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=multics69@gmail.com \
--cc=peterz@infradead.org \
--cc=tj@kernel.org \
--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®