Re: [PATCH] mm: remove redundant if overhead

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Sep 11, 2024 at 09:14:10AM +0800, zhiguojiang wrote:
> 在 2024/9/11 0:03, Matthew Wilcox 写道:
> > On Tue, Sep 10, 2024 at 10:39:45PM +0800, Zhiguo Jiang wrote:
> > > Remove redundant if judgment overhead.
> > It's not redundant; it avoids dirtying the cacheline if the folio
> > is already marked as dirty.

> Ok, Is it necessary to add comments here to explain and avoid readers'
> misunderstandings? E.g. 'Avoid dirtying the cacheline if the folio is
> already marked as dirty.'

No, it's a fairly common pattern to test-and-test-and-set(or clear)




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux