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] [day] [month] [year] [list]
Date: Fri, 8 Mar 2024 14:46:33 +0100
From: David Hildenbrand <david@...hat.com>
To: Ryan Roberts <ryan.roberts@....com>, Barry Song <21cnbao@...il.com>,
 akpm@...ux-foundation.org, linux-mm@...ck.org
Cc: minchan@...nel.org, fengwei.yin@...el.com, linux-kernel@...r.kernel.org,
 mhocko@...e.com, peterx@...hat.com, shy828301@...il.com,
 songmuchun@...edance.com, wangkefeng.wang@...wei.com, xiehuan09@...il.com,
 zokeefe@...gle.com, chrisl@...nel.org, yuzhao@...gle.com,
 Barry Song <v-songbaohua@...o.com>, Lance Yang <ioworker0@...il.com>
Subject: Re: [PATCH v2] mm: prohibit the last subpage from reusing the entire
 large folio

On 08.03.24 14:45, Ryan Roberts wrote:
> On 08/03/2024 13:24, David Hildenbrand wrote:
>>>>> This patch migrates the last subpage to a small folio and immediately
>>>>> returns the large folio to the system. It benefits both memory availability
>>>>> and anti-fragmentation.
>>>>
>>>> It might be controversial optimization, and as Ryan said, there, are likely
>>>> other cases where we'd want to migrate off-of a thp if possible earlier.
>>>
>>> Personally, I think there might also be cases where you want to copy/reuse the
>>> entire large folio. If you're application is using 16K THPs perhaps it's a
>>> bigger win to just treat it like a base page? I expect the cost/benefit will
>>> change as the THP size increases?
>>
>> Yes, I think for small folios (i.e., 16KiB) it will be rather easy to make a
>> decision. The larger the folio, the larger the page fault latency due to
>> scanning, copying, modifying, which can easily turn undesirable.
>>
>> At least when it comes to page reuse, I have some simple backup plans for small
>> folios if I won't be able to make progress with my other approach.
> 
> Do you mean "small large folios" here? i.e. order >= 1? If so, great!

*smaller*, yes :)

-- 
Cheers,

David / dhildenb


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ