lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <umy4kicwvlsaszajo62pcpgptcdqi2yp7pponvlch5h6tirabb@mhhq2en3piel>
Date: Tue, 27 May 2025 17:33:55 +0200
From: Michal Koutný <mkoutny@...e.com>
To: Yafang Shao <laoar.shao@...il.com>
Cc: mingo@...hat.com, peterz@...radead.org, hannes@...xchg.org, 
	juri.lelli@...hat.com, vincent.guittot@...aro.org, dietmar.eggemann@....com, 
	rostedt@...dmis.org, bsegall@...gle.com, mgorman@...e.de, vschneid@...hat.com, 
	surenb@...gle.com, linux-kernel@...r.kernel.org, cgroups@...r.kernel.org, 
	lkp@...el.com, Eric Dumazet <edumazet@...gle.com>
Subject: Re: [PATCH v9 2/2] sched: Annotate sched_clock_irqtime with
 __read_mostly

On Sun, May 11, 2025 at 11:08:00AM +0800, Yafang Shao <laoar.shao@...il.com> wrote:
> Eric reported an issue [0] as follows,
> : rebalance_domains() can attempt to change sched_balance_running
> : more than 350,000 times per second on our servers.
> 
> : If sched_clock_irqtime and sched_balance_running share the
> : same cache line, we see a very high cost on hosts with 480 threads
> : dealing with many interrupts.

I'd say this patch could be independent from the "series".

> While the rebalance_domains() issue has been resolved [1], we should
> proactively annotate sched_clock_irqtime with __read_mostly to prevent
> potential cacheline false sharing. This optimization is particularly
> justified since sched_clock_irqtime is only modified during TSC instability
> events.
> 
> Link: https://lore.kernel.org/all/20250423174634.3009657-1-edumazet@google.com/ [0]
> Link: https://lore.kernel.org/all/20250416035823.1846307-1-tim.c.chen@linux.intel.com/ [1]
> 
> Reported-by: Eric Dumazet <edumazet@...gle.com>
> Debugged-by: Eric Dumazet <edumazet@...gle.com>
> Signed-off-by: Yafang Shao <laoar.shao@...il.com>
> Cc: Eric Dumazet <edumazet@...gle.com>

I can say
Reviewed-by: Michal Koutný <mkoutny@...e.com>

but it'd be good to have also Tested-by: wrt the cache traffic
reduction.

0.02€,
Michal

Download attachment "signature.asc" of type "application/pgp-signature" (229 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ