Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1503028

Re: [PATCH] shmem: avoid huge pages for small files

From Michal Hocko <mhocko@kernel.org>
Newsgroups linux.kernel
Subject Re: [PATCH] shmem: avoid huge pages for small files
Date 2016-10-18 16:30 +0200
Message-ID <stDyW-2Sj-7@gated-at.bofh.it> (permalink)
References <stf3A-3nA-13@gated-at.bofh.it> <stfmW-3uj-19@gated-at.bofh.it> <stgVI-4zx-41@gated-at.bofh.it> <sthyq-4Nc-51@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Mon 17-10-16 17:55:40, Kirill A. Shutemov wrote:
> On Mon, Oct 17, 2016 at 04:12:46PM +0200, Michal Hocko wrote:
> > On Mon 17-10-16 15:30:21, Kirill A. Shutemov wrote:
[...]
> > > We add two handle to specify minimal file size for huge pages:
> > > 
> > >   - mount option 'huge_min_size';
> > > 
> > >   - sysfs file /sys/kernel/mm/transparent_hugepage/shmem_min_size for
> > >     in-kernel tmpfs mountpoint;
> > 
> > Could you explain who might like to change the minimum value (other than
> > disable the feautre for the mount point) and for what reason?
> 
> Depending on how well CPU microarchitecture deals with huge pages, you
> might need to set it higher in order to balance out overhead with benefit
> of huge pages.

I am not sure this is a good argument. How do a user know and what will
help to make that decision? Why we cannot autotune that? In other words,
adding new knobs just in case turned out to be a bad idea in the past.

> In other case, if it's known in advance that specific mount would be
> populated with large files, you might want to set it to zero to get huge
> pages allocated from the beginning.

Cannot we use [mf]advise for that purpose?
-- 
Michal Hocko
SUSE Labs

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] shmem: avoid huge pages for small files "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> - 2016-10-17 14:20 +0200
  Re: [PATCH] shmem: avoid huge pages for small files "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com> - 2016-10-17 14:40 +0200
    Re: [PATCH] shmem: avoid huge pages for small files Michal Hocko <mhocko@kernel.org> - 2016-10-17 16:20 +0200
      Re: [PATCH] shmem: avoid huge pages for small files "Kirill A. Shutemov" <kirill@shutemov.name> - 2016-10-17 17:00 +0200
        Re: [PATCH] shmem: avoid huge pages for small files Michal Hocko <mhocko@kernel.org> - 2016-10-18 16:30 +0200
          Re: [PATCH] shmem: avoid huge pages for small files "Kirill A. Shutemov" <kirill@shutemov.name> - 2016-10-18 16:40 +0200
            Re: [PATCH] shmem: avoid huge pages for small files Michal Hocko <mhocko@kernel.org> - 2016-10-18 20:40 +0200
              Re: [PATCH] shmem: avoid huge pages for small files Hugh Dickins <hughd@google.com> - 2016-10-19 20:20 +0200
                Re: [PATCH] shmem: avoid huge pages for small files "Kirill A. Shutemov" <kirill@shutemov.name> - 2016-10-20 12:50 +0200
                Re: [PATCH] shmem: avoid huge pages for small files Dave Chinner <david@fromorbit.com> - 2016-10-21 00:50 +0200
                Re: [PATCH] shmem: avoid huge pages for small files Andi Kleen <ak@linux.intel.com> - 2016-10-21 04:10 +0200
                Re: [PATCH] shmem: avoid huge pages for small files Dave Chinner <david@fromorbit.com> - 2016-10-21 07:10 +0200
                Re: [PATCH] shmem: avoid huge pages for small files "Kirill A. Shutemov" <kirill@shutemov.name> - 2016-10-21 17:10 +0200
                Re: [PATCH] shmem: avoid huge pages for small files Michal Hocko <mhocko@kernel.org> - 2016-10-21 17:20 +0200
                Re: [PATCH] shmem: avoid huge pages for small files Dave Chinner <david@fromorbit.com> - 2016-10-22 01:00 +0200
                Re: [PATCH] shmem: avoid huge pages for small files "Kirill A. Shutemov" <kirill@shutemov.name> - 2016-10-22 01:40 +0200
                Re: [PATCH] shmem: avoid huge pages for small files Dave Hansen <dave.hansen@intel.com> - 2016-10-24 22:40 +0200
                Re: [PATCH] shmem: avoid huge pages for small files Dave Chinner <david@fromorbit.com> - 2016-10-25 07:30 +0200

csiph-web