Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1380667
| From | "Kirill A. Shutemov" <kirill@shutemov.name> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH mmotm 5/5] huge tmpfs: add shmem_pmd_fault() |
| Date | 2016-04-17 02:50 +0200 |
| Message-ID | <roJ4u-3ND-5@gated-at.bofh.it> (permalink) |
| References | <roHP4-30O-1@gated-at.bofh.it> <roI8p-38N-1@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Sat, Apr 16, 2016 at 04:41:33PM -0700, Hugh Dickins wrote: > The pmd_fault() method gives the filesystem an opportunity to place > a trans huge pmd entry at *pmd, before any pagetable is exposed (and > an opportunity to split it on COW fault): now use it for huge tmpfs. > > This patch is a little raw: with more time before LSF/MM, I would > probably want to dress it up better - the shmem_mapping() calls look > a bit ugly; it's odd to want FAULT_FLAG_MAY_HUGE and VM_FAULT_HUGE just > for a private conversation between shmem_fault() and shmem_pmd_fault(); > and there might be a better distribution of work between those two, but > prising apart that series of huge tests is not to be done in a hurry. > > Good for now, presents the new way, but might be improved later. > > This patch still leaves the huge tmpfs map_team_by_pmd() allocating a > pagetable while holding page lock, but other filesystems are no longer > doing so; and we've not yet settled whether huge tmpfs should (like anon > THP) or should not (like DAX) participate in deposit/withdraw protocol. > > Signed-off-by: Hugh Dickins <hughd@google.com> Just for record: I don't like ->pmd_fault() approach because it results in two requests to file system (two shmem_fault() in this case) if we don't have a huge page to map: one for huge page (failed) and then one for small. I think this case should be rather common: all mounts without huge pages enabled. I expect performance regression from this too. -- Kirill A. Shutemov
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH mmotm 1/5] huge tmpfs: try to allocate huge pages split into a team fix Hugh Dickins <hughd@google.com> - 2016-04-17 01:30 +0200
[PATCH mmotm 2/5] huge tmpfs: fix mlocked meminfo track huge unhuge mlocks fix Hugh Dickins <hughd@google.com> - 2016-04-17 01:40 +0200
Re: [PATCH mmotm 2/5] huge tmpfs: fix mlocked meminfo track huge unhuge mlocks fix Stephen Rothwell <sfr@canb.auug.org.au> - 2016-04-21 01:50 +0200
[PATCH mmotm 4/5] huge tmpfs: avoid premature exposure of new pagetable revert Hugh Dickins <hughd@google.com> - 2016-04-17 01:40 +0200
Re: [PATCH mmotm 4/5] huge tmpfs: avoid premature exposure of new pagetable revert Stephen Rothwell <sfr@canb.auug.org.au> - 2016-04-21 02:00 +0200
[PATCH mmotm 3/5] huge tmpfs recovery: tweak shmem_getpage_gfp to fill team fix Hugh Dickins <hughd@google.com> - 2016-04-17 01:40 +0200
Re: [PATCH mmotm 3/5] huge tmpfs recovery: tweak shmem_getpage_gfp to fill team fix Stephen Rothwell <sfr@canb.auug.org.au> - 2016-04-21 02:00 +0200
[PATCH mmotm 5/5] huge tmpfs: add shmem_pmd_fault() Hugh Dickins <hughd@google.com> - 2016-04-17 01:50 +0200
Re: [PATCH mmotm 5/5] huge tmpfs: add shmem_pmd_fault() "Kirill A. Shutemov" <kirill@shutemov.name> - 2016-04-17 02:50 +0200
Re: [PATCH mmotm 5/5] huge tmpfs: add shmem_pmd_fault() Hugh Dickins <hughd@google.com> - 2016-04-17 03:30 +0200
Re: [PATCH mmotm 5/5] huge tmpfs: add shmem_pmd_fault() Stephen Rothwell <sfr@canb.auug.org.au> - 2016-04-21 02:00 +0200
Re: [PATCH mmotm 1/5] huge tmpfs: try to allocate huge pages split into a team fix Stephen Rothwell <sfr@canb.auug.org.au> - 2016-04-21 01:50 +0200
csiph-web