[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZxEPDMUnYlAy3r3_@casper.infradead.org>
Date: Thu, 17 Oct 2024 14:20:12 +0100
From: Matthew Wilcox <willy@...radead.org>
To: lizhe.67@...edance.com
Cc: akpm@...ux-foundation.org, boqun.feng@...il.com,
linux-kernel@...r.kernel.org, linux-mm@...ck.org,
longman@...hat.com, mingo@...hat.com, peterz@...radead.org,
will@...nel.org
Subject: Re: [RFC 2/2] khugepaged: use upgrade_read() to optimize
collapse_huge_page
On Thu, Oct 17, 2024 at 02:18:41PM +0800, lizhe.67@...edance.com wrote:
> On Wed, 16 Oct 2024 12:53:15 +0100, willy@...radead.org wrote:
>
> >On Wed, Oct 16, 2024 at 12:36:00PM +0800, lizhe.67@...edance.com wrote:
> >> From: Li Zhe <lizhe.67@...edance.com>
> >>
> >> In function collapse_huge_page(), we drop mmap read lock and get
> >> mmap write lock to prevent most accesses to pagetables. There is
> >> a small time window to allow other tasks to acquire the mmap lock.
> >> With the use of upgrade_read(), we don't need to check vma and pmd
> >> again in most cases.
> >
> >This is clearly a performance optimisation. So you must have some
> >numebrs that justify this, please include them.
>
> Yes, I will add the relevant data to v2 patch.
How about telling us all now so we know whether to continue discussing
this?
Powered by blists - more mailing lists