All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ankur Arora <ankur.a.arora@oracle.com>
To: Joao Martins <joao.m.martins@oracle.com>
Cc: Mateusz Guzik <mjguzik@gmail.com>,
	Frank van der Linden <fvdl@google.com>,
	linux-mm@kvack.org, akpm@linux-foundation.org,
	Muchun Song <muchun.song@linux.dev>,
	Miaohe Lin <linmiaohe@huawei.com>,
	Oscar Salvador <osalvador@suse.de>,
	David Hildenbrand <david@redhat.com>,
	Peter Xu <peterx@redhat.com>,
	linux-kernel@vger.kernel.org,
	Ankur Arora <ankur.a.arora@oracle.com>
Subject: Re: [PATCH] mm/hugetlb: optionally pre-zero hugetlb pages
Date: Tue, 03 Dec 2024 16:06:41 -0800	[thread overview]
Message-ID: <87iks0cnvy.fsf@oracle.com> (raw)
In-Reply-To: <4d5c9ad7-6898-4f14-8974-126306e62db7@oracle.com>


Joao Martins <joao.m.martins@oracle.com> writes:

> On 02/12/2024 21:58, Mateusz Guzik wrote:
>> On Mon, Dec 02, 2024 at 08:20:58PM +0000, Frank van der Linden wrote:
>>> Fresh hugetlb pages are zeroed out when they are faulted in,
>>> just like with all other page types. This can take up a good
>>> amount of time for larger page sizes (e.g. around 40
>>> milliseconds for a 1G page on a recent AMD-based system).
>>>
>>> This normally isn't a problem, since hugetlb pages are typically
>>> mapped by the application for a long time, and the initial
>>> delay when touching them isn't much of an issue.
>>>
>>> However, there are some use cases where a large number of hugetlb
>>> pages are touched when an application (such as a VM backed by these
>>> pages) starts. For 256 1G pages and 40ms per page, this would take
>>> 10 seconds, a noticeable delay.
>>
>> The current huge page zeroing code is not that great to begin with.
>>
>> There was a patchset posted some time ago to remedy at least some of it:
>> https://lore.kernel.org/all/20230830184958.2333078-1-ankur.a.arora@oracle.com/
>>
>> but it apparently fell through the cracks.
>>
>
> It didn't fell through the cracks for sure
>
> Just had a detour into preempt=auto before resuming the main work. But that
> seems to be done in the last merge window with the lazy preempt stuff. I think
> Ankur was planning on following that series above soon-ish.
>
> Adding him here, such that he keeps me honest :)

Thanks for Ccing Joao.

--
ankur


  reply	other threads:[~2024-12-04  0:06 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-02 20:20 [PATCH] mm/hugetlb: optionally pre-zero hugetlb pages Frank van der Linden
2024-12-02 21:58 ` Mateusz Guzik
2024-12-02 22:50   ` Frank van der Linden
2024-12-03 12:06     ` Michal Hocko
2024-12-03 12:17       ` David Hildenbrand
2024-12-03 14:26       ` Joao Martins
2024-12-03 15:57         ` Mateusz Guzik
2024-12-03 16:17           ` Mateusz Guzik
2024-12-03 16:21           ` Joao Martins
2024-12-03 18:43         ` Frank van der Linden
2024-12-03 20:15           ` Frank van der Linden
2024-12-03 14:02   ` Joao Martins
2024-12-04  0:06     ` Ankur Arora [this message]
2024-12-04  0:05   ` Ankur Arora
2024-12-04 17:01     ` Frank van der Linden
2024-12-04 19:57       ` Ankur Arora
2024-12-02 22:07 ` kernel test robot

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=87iks0cnvy.fsf@oracle.com \
    --to=ankur.a.arora@oracle.com \
    --cc=akpm@linux-foundation.org \
    --cc=david@redhat.com \
    --cc=fvdl@google.com \
    --cc=joao.m.martins@oracle.com \
    --cc=linmiaohe@huawei.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mjguzik@gmail.com \
    --cc=muchun.song@linux.dev \
    --cc=osalvador@suse.de \
    --cc=peterx@redhat.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.