On Sun, Oct 08, 2023 at 07:10:01PM +0800, brookxu wrote:Thanks, agree with you, I try do it in other ways :)
But it's 80 bytes 'nobody' will use. And arguably we should do the sameYes, this way will increase about 80 bytes for task_struct, about 0.85% of@@ -1331,7 +1332,7 @@ struct task_struct {Yeah, no.
struct page_frag task_frag;
#ifdef CONFIG_TASK_DELAY_ACCT
- struct task_delay_info *delays;
+ struct task_delay_info delays;
#endif
size of task_struct, I think this just like sched_statistics, so that can
better support dynamically enable through sysctl.
with schedstats, that's default disabled and again, that's per-task
storage nobody ever uses.
Per this argument we can grow task_struct indefinitely until it
collapses in on itself by the sheer weight of it's information density.
Every additional field will be a smaller fraction of the total.
Yes, it makes it all a little more cumbersome, but we should really not
burden everybody with the load of some.
Surely there is another solution... ?