linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Hildenbrand <david@redhat.com>
To: Hao Peng <flyingpenghao@gmail.com>
Cc: akpm@linux-foundation.org, linux-mm@kvack.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mm/huge_memory: disable thp if thp page size is too large
Date: Wed, 6 Oct 2021 10:20:20 +0200	[thread overview]
Message-ID: <6813b6fa-5587-7967-1f16-87b1c49084a1@redhat.com> (raw)
In-Reply-To: <CAPm50aKRTg2=WMDw+vWvXA5+wADfSo8Kk-PHpAagftGypArU+g@mail.gmail.com>

On 06.10.21 10:16, Hao Peng wrote:
> On Thu, Sep 30, 2021 at 9:19 PM David Hildenbrand <david@redhat.com> wrote:
>>
>> On 30.09.21 04:14, Hao Peng wrote:
>>> From: Peng Hao <flyingpeng@tencent.com>
>>
>> "disable thp if thp page size is too large" you disable thp if there is
>> not sufficient memory installed in the system (and for that, you use THP
>> size), something doesn't add up here.
>>
> In addition, if THP is enabled, min_free_kbytes will be recalculated.
> At this time,
> min_free_kbytes is calculated based on the size of THP. If the size of
> THP is too l
> arge, OOM will easily be triggered.

Right, I was pointing at the misleading $subject. What about something like:

"mm/huge_memory: disable THP with large THP size on small present memory" ?

>>>
>>> After seting the page size to 64k on ARM64, the supported huge page
>>
>> s/seting/setting/
>>
>> Fortunately, most distributions already switched to 4k, because 512MB
>> THP is pretty much useless, especially on any system that doesn't have
>> memory in the range of hundreds of megabytes or terrabytes.
> But the ARM64 Server distribution version I use, such as CentOS for ARM64,
>   has a page size of 16KB or 64KB.

Yeah, RHEL8 and CENTOS8 are the last remaining "recent distirbutions" 
I'm aware of.


-- 
Thanks,

David / dhildenb


      reply	other threads:[~2021-10-06  8:20 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-30  2:14 [PATCH] mm/huge_memory: disable thp if thp page size is too large Hao Peng
2021-09-30 13:19 ` David Hildenbrand
2021-10-06  8:16   ` Hao Peng
2021-10-06  8:20     ` David Hildenbrand [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6813b6fa-5587-7967-1f16-87b1c49084a1@redhat.com \
    --to=david@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=flyingpenghao@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).