linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Zi Yan <ziy@nvidia.com>
To: Dave Hansen <dave.hansen@intel.com>
Cc: Saravanan D <saravanand@fb.com>,
	Xing Zhengjun <zhengjun.xing@linux.intel.com>, <x86@kernel.org>,
	<dave.hansen@linux.intel.com>, <luto@kernel.org>,
	<peterz@infradead.org>, <corbet@lwn.net>, <willy@infradead.org>,
	<linux-kernel@vger.kernel.org>, <kernel-team@fb.com>,
	<linux-doc@vger.kernel.org>, <linux-mm@kvack.org>,
	<songliubraving@fb.com>
Subject: Re: [PATCH V5] x86/mm: Tracking linear mapping split events
Date: Thu, 28 Jan 2021 11:56:05 -0500	[thread overview]
Message-ID: <33B5B608-4D74-4221-AB0F-AEEBA170AF84@nvidia.com> (raw)
In-Reply-To: <15a29679-ea0b-d1c8-1a1f-698d3db35293@intel.com>

[-- Attachment #1: Type: text/plain, Size: 1716 bytes --]

On 28 Jan 2021, at 11:41, Dave Hansen wrote:

> On 1/28/21 8:33 AM, Zi Yan wrote:
>>> One of the many lasting (as we don't coalesce back) sources for
>>> huge page splits is tracing as the granular page
>>> attribute/permission changes would force the kernel to split code
>>> segments mapped to huge pages to smaller ones thereby increasing
>>> the probability of TLB miss/reload even after tracing has been
>>> stopped.
>> It is interesting to see this statement saying splitting kernel
>> direct mappings causes performance loss, when Zhengjun (cc’d) from
>> Intel recently posted a kernel direct mapping performance report[1]
>> saying 1GB mappings are good but not much better than 2MB and 4KB
>> mappings.
>
> No, that's not what the report said.
>
> *Overall*, there is no clear winner between 4k, 2M and 1G.  In other
> words, no one page size is best for *ALL* workloads.
>
> There were *ABSOLUTELY* individual workloads in those tests that saw
> significant deltas between the direct map sizes.  There are also
> real-world workloads that feel the impact here.

Yes, it is what I understand from the report. But this patch says
“
Maintaining huge direct mapped pages greatly reduces TLB miss pressure.
The splintering of huge direct pages into smaller ones does result in
a measurable performance hit caused by frequent TLB miss and reloads.
”,

indicating large mappings (2MB, 1GB) are generally better. It is
different from what the report said, right?

The above text could be improved to make sure readers get both sides
of the story and not get afraid of performance loss after seeing
a lot of direct_map_xxx_splits events.



—
Best Regards,
Yan Zi

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 854 bytes --]

  reply	other threads:[~2021-01-28 16:56 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <a936a943-9d8f-7e3c-af38-1c99ae176e1f@intel.com>
     [not found] ` <20210128043547.1560435-1-saravanand@fb.com>
2021-01-28  4:51   ` [PATCH V4] x86/mm: Tracking linear mapping split events Matthew Wilcox
2021-01-28 10:49     ` [PATCH V5] " Saravanan D
2021-01-28 15:04       ` Matthew Wilcox
2021-01-28 19:49         ` Saravanan D
2021-01-28 16:33       ` Zi Yan
2021-01-28 16:41         ` Dave Hansen
2021-01-28 16:56           ` Zi Yan [this message]
2021-01-28 16:59         ` Song Liu
2021-01-28 19:17       ` Dave Hansen
2021-01-28 21:20         ` Saravanan D
2021-01-28 23:34           ` [PATCH V6] " Saravanan D
2021-01-28 23:41             ` Tejun Heo
2021-01-29 19:27             ` Johannes Weiner
2021-02-08 23:17               ` Saravanan D
2021-02-08 23:30             ` Dave Hansen

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=33B5B608-4D74-4221-AB0F-AEEBA170AF84@nvidia.com \
    --to=ziy@nvidia.com \
    --cc=corbet@lwn.net \
    --cc=dave.hansen@intel.com \
    --cc=dave.hansen@linux.intel.com \
    --cc=kernel-team@fb.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=luto@kernel.org \
    --cc=peterz@infradead.org \
    --cc=saravanand@fb.com \
    --cc=songliubraving@fb.com \
    --cc=willy@infradead.org \
    --cc=x86@kernel.org \
    --cc=zhengjun.xing@linux.intel.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 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).