mirror of
https://github.com/JakeHillion/scx.git
synced 2024-11-30 04:50:24 +00:00
scx_rustland: remove SCX_ENQ_LAST check in is_task_cpu_available()
With commit 49f2e7c
("scx_rustland: enable SCX_OPS_ENQ_LAST") we have
enabled SCX_OPS_ENQ_LAST that seems to save some unnecessary user-space
scheduler activations when the system is mostly idle.
We are also checking for the SCX_ENQ_LAST in the enqueue flags, that
apparently it is not needed and we can achieve the same behavior
dropping this check.
Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
This commit is contained in:
parent
840260141d
commit
0fc46b2be2
@ -335,12 +335,6 @@ static bool is_task_cpu_available(struct task_struct *p, u64 enq_flags)
|
||||
if (is_kthread(p) && p->scx.slice > slice_ns / 2)
|
||||
return true;
|
||||
|
||||
/*
|
||||
* No scheduling required if it's the last task running.
|
||||
*/
|
||||
if (enq_flags & SCX_ENQ_LAST)
|
||||
return true;
|
||||
|
||||
/*
|
||||
* For regular tasks always rely on force_local to determine if we can
|
||||
* bypass the scheduler.
|
||||
|
Loading…
Reference in New Issue
Block a user