From: Dave Hansen <dave.hansen@intel.com>
To: Saravanan D <saravanand@fb.com>,
x86@kernel.org, dave.hansen@linux.intel.com, luto@kernel.org,
peterz@infradead.org, corbet@lwn.net, willy@infradead.org
Cc: 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:17:53 -0800 [thread overview]
Message-ID: <3aec2d10-f4c3-d07a-356f-6f1001679181@intel.com> (raw)
In-Reply-To: <20210128104934.2916679-1-saravanand@fb.com>
On 1/28/21 2:49 AM, Saravanan D wrote:
> +++ b/Documentation/admin-guide/mm/direct_mapping_splits.rst
> @@ -0,0 +1,59 @@
> +.. SPDX-License-Identifier: GPL-2.0
> +
> +=====================
> +Direct Mapping Splits
> +=====================
> +
> +Kernel maps all of physical memory in linear/direct mapped pages with
> +translation of virtual kernel address to physical address is achieved
> +through a simple subtraction of offset. CPUs maintain a cache of these
> +translations on fast caches called TLBs. CPU architectures like x86 allow
> +direct mapping large portions of memory into hugepages (2M, 1G, etc) in
> +various page table levels.
> +
> +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.
Eek. There really doesn't appear to be a place in Documentation/ that
we've documented vmstat entries.
Maybe you can start:
Documentation/admin-guide/mm/vmstat.rst
Also, I don't think we need background on the direct map or TLBs here.
Just get to the point and describe what the files do, don't justify why
they are there.
I also agree with Willy that you should qualify some of the strong
statements (if they remain) in your changelog and documentation>
This:
Maintaining huge direct mapped pages
greatly reduces TLB miss pressure.
for instance isn't universally true. There were CPUs with a very small
number of 1G TLB entries. Using 1G pages on those systems often led to
*GREATER* TLB pressure and lower performance.
next prev parent reply other threads:[~2021-01-28 19:18 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
2021-01-28 16:59 ` Song Liu
2021-01-28 19:17 ` Dave Hansen [this message]
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=3aec2d10-f4c3-d07a-356f-6f1001679181@intel.com \
--to=dave.hansen@intel.com \
--cc=corbet@lwn.net \
--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 \
/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).