[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CALOAHbBK9_PTzZRxwcPc8uFSBFMmKq5-xJXeyRAZ91wA5gZ1VQ@mail.gmail.com>
Date: Thu, 8 May 2025 13:56:00 +0800
From: Yafang Shao <laoar.shao@...il.com>
To: Ingo Molnar <mingo@...nel.org>
Cc: Peter Zijlstra <peterz@...radead.org>, ardb@...nel.org, arnd@...db.de, bp@...en8.de,
dwmw@...zon.co.uk, hpa@...or.com, linux-kernel@...r.kernel.org,
michal.lkml@...kovi.net, tglx@...utronix.de, torvalds@...ux-foundation.org,
vkuznets@...hat.com, yamada.masahiro@...ionext.com
Subject: Re: [PATCH 13/15] x86/kconfig/64: Enable popular scheduler, cgroups
and namespaces options in the defconfig
On Thu, May 8, 2025 at 12:23 AM Ingo Molnar <mingo@...nel.org> wrote:
>
>
> * Yafang Shao <laoar.shao@...il.com> wrote:
>
> > On Wed, May 7, 2025 at 3:06 PM Ingo Molnar <mingo@...nel.org> wrote:
> > >
> > >
> > > * Yafang Shao <laoar.shao@...il.com> wrote:
> > >
> > > > Hello Mingo,
> > > >
> > > > > +CONFIG_VIRT_CPU_ACCOUNTING_GEN=y
> > > > > +CONFIG_IRQ_TIME_ACCOUNTING=y
> > > >
> > > > Enabling CONFIG_IRQ_TIME_ACCOUNTING=y can lead to user-visible behavioral
> > > > changes. For more context, please refer to the related discussion here:
> > > > https://lore.kernel.org/all/20241222024734.63894-1-laoar.shao@gmail.com/ .
> > >
> > > Yeah. I actually agree with your series. It (re-)includes IRQ/softirq
> > > time in task CPU usage statistics even under IRQ_TIME_ACCOUNTING=y,
> > > while still keeping the finegrained IRQ/softirq statistics as well,
> > > correct?
> >
> > Correct.
> >
> > >
> > > The Kconfig option is also arguably rather misleading:
> > >
> > > config IRQ_TIME_ACCOUNTING
> > > bool "Fine granularity task level IRQ time accounting"
> > > depends on HAVE_IRQ_TIME_ACCOUNTING && !VIRT_CPU_ACCOUNTING_NATIVE
> > > help
> > > Select this option to enable fine granularity task irq time
> > > accounting. This is done by reading a timestamp on each
> > > transitions between softirq and hardirq state, so there can be a
> > > small performance impact.
> > >
> > > It only warns about a small performance impact, but doesn't warn that
> > > CPU accounting is changed in an incompatible fashion that surprises
> > > tooling...
> >
> > Yes, this breaks our userspace tools.
>
> Okay, so 2 out of your 3 fixes are upstream already:
>
> 763a744e24a8 ("sched: Don't account irq time if sched_clock_irqtime is disabled")
> a6fd16148fdd ("sched, psi: Don't account irq time if sched_clock_irqtime is disabled")
Right.
>
> But we don't have this one yet:
>
> [PATCH v8 4/4] sched: Fix cgroup irq time for CONFIG_IRQ_TIME_ACCOUNTING
>
> https://lore.kernel.org/r/20250103022409.2544-5-laoar.shao@gmail.com
>
> which is also essential to fully fix the tooling regression, right?
This patch resolves the container tooling regression but does not
address tools depending on getrusage() for CPU measurement. The
getrusage() fix will be implemented in a subsequent patch.
>
> I think this last patch fell between the cracks, I didn't see any
> fundamental objections against the fix.
>
> Since the patch does not apply cleanly anymore, mind sending a fresh
> -v9 version against v6.15-rc5 or so?
I will send a new version.
--
Regards
Yafang
Powered by blists - more mailing lists