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 PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Thu, 23 Sep 2021 12:36:37 +0200 From: Thomas Gleixner <tglx@...utronix.de> To: Vlastimil Babka <vbabka@...e.cz>, Peter Zijlstra <peterz@...radead.org> Cc: Nicolas Saenz Julienne <nsaenzju@...hat.com>, akpm@...ux-foundation.org, frederic@...nel.org, linux-kernel@...r.kernel.org, linux-mm@...ck.org, cl@...ux.com, juri.lelli@...hat.com, mingo@...hat.com, mtosatti@...hat.com, nilal@...hat.com, mgorman@...e.de, ppandit@...hat.com, williams@...hat.com, bigeasy@...utronix.de, anna-maria@...utronix.de, linux-rt-users@...r.kernel.org Subject: Re: [PATCH 0/6] mm: Remote LRU per-cpu pagevec cache/per-cpu page list drain support Vlastimil, On Thu, Sep 23 2021 at 09:12, Vlastimil Babka wrote: > On 9/23/21 00:09, Thomas Gleixner wrote: >> local_lock() -> preempt_disable() >> local_lock_irq() -> local_irq_disable() >> ... > > Yes, to be clean, this would have to be a new primitive, not just an abused > local lock. It would just look similar to the RT version (a percpu array of > spinlocks), so for this patchset it would allow not to have two such locks > side be side (local + spin) while only one is being used. For maximum > flexibility the initialization would take a CONFIG_ (or something > compile-time bool) that when false would make the !RT version an empty > struct and "locking" would rely on preempt/irq disable (just as with !RT > local_lock). If compile-time true it would take a static key to decide on > boot whether the !RT version only does the preepmt/irq disable or actually > takes the lock. > > But as you say below, it's too much complexity for questionable benefit. > > But maybe this can all be avoided anyway, as I recalled what we do for > vmstat already (IIUC). See quiet_vmstat() - when cpu enters the nohz mode, > it flushes per-cpu vmstat diffs and then there's no reason to further > disturb the cpu to do that while it's on NOHZ mode. We could do the same for > lru pagevecs and pcplists? I'm not sure about this. I like the idea of being able to offload things to housekeeping CPUs not only in the full isolation case. A good example is RCU which allows to offload all RCU processing to some other CPU(s), which is useful even w/o full isolation. The synchronous quiescing on entering NOHZ full mode is a cute workaround but for one it makes entering NOHZ full more expensive and it does not necessarily provide good isolation guarantees under all circumstances, while a full remote processing definitely does. I think it's at least worthwhile to investigate. Thanks, tglx
Powered by blists - more mailing lists