Re: [PATCH] sched/core: Introduce task_*() helpers for PF_ flags
From: Ingo Molnar
Date: Sat Apr 26 2025 - 14:51:36 EST
* Ingo Molnar <mingo@xxxxxxxxxx> wrote:
> - We might want to add set_task_*() helpers as well, to totally
> encapsulate PF_ uses. Maybe. I dislike how close it is to the
> existing set_tsk*() methods that manipulate TIF_ flags. The
> dichotomy between the TIF_ and PF_ space isn't really sensible these
> days I think on a conceptual level - although merging them is
> probably not practical due to possibly running out of easy 64-bit
> word width.
And yeah, the TIF_ space is per arch to a substantial degree, and is
accessed from assembly code, plus is often operated on atomically,
while the PF_ space is nicely generic and non-atomic - but still we
could do better to express that these two per task flag spaces are
rather similar in purpose, instead of this historic 'task/process'
distinction that isn't actually true.
Thanks,
Ingo