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


Groups > linux.kernel > #1482540

Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping out

From Andrea Arcangeli <aarcange@redhat.com>
Newsgroups linux.kernel
Subject Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping out
Date 2016-09-13 16:40 +0200
Message-ID <sgX2p-39g-3@gated-at.bofh.it> (permalink)
References (2 earlier) <sfAKB-7F8-7@gated-at.bofh.it> <sgPex-6r3-5@gated-at.bofh.it> <sgPHz-6Bw-15@gated-at.bofh.it> <sgQ0W-6Y0-29@gated-at.bofh.it> <sgRJp-7Xu-43@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hello,

On Tue, Sep 13, 2016 at 04:53:49PM +0800, Huang, Ying wrote:
> I am glad to discuss my final goal, that is, swapping out/in the full
> THP without splitting.  Why I want to do that is copied as below,

I think that is a fine objective. It wasn't implemented initially just
to keep things simple.

Doing it will reduce swap fragmentation (provided we can find a
physically contiguous piece of to swapout the THP in the first place)
and it will make all other heuristics that tries to keep the swap
space contiguous less relevant and it should increase the swap
bandwidth significantly at least on spindle disks. I personally see it
as a positive that we relay less on those and the readhaead swapin.

> >> >> The disadvantage are:
> >> >> 
> >> >> - Increase the memory pressure when swap in THP.

That is always true with THP enabled to always. It is the tradeoff. It
still cannot use more RAM than userland ever allocated in the vma as
virtual memory. If userland don't ever need such memory it can free it
by zapping the vma and the THP will be splitted. If the vma is zapped
while the THP is natively swapped out, the zapped portion of swap
space shall be released as well. So ultimately userland always
controls the cap on the max virtual memory (ram+swap) the kernel
decides to use with THP enabled to always.

> I think it is important to use 2M pages as much as possible to deal with
> the big memory problem.  Do you agree?

I agree.

Thanks,
Andrea

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


Thread

Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping out "Huang\, Ying" <ying.huang@intel.com> - 2016-09-09 22:40 +0200
  Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping  out Minchan Kim <minchan@kernel.org> - 2016-09-13 08:20 +0200
    Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping out "Huang\, Ying" <ying.huang@intel.com> - 2016-09-13 08:50 +0200
      Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping  out Minchan Kim <minchan@kernel.org> - 2016-09-13 09:10 +0200
        Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping out "Huang\, Ying" <ying.huang@intel.com> - 2016-09-13 11:00 +0200
          Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping  out Minchan Kim <minchan@kernel.org> - 2016-09-13 11:20 +0200
            RE: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping  out "Chen, Tim C" <tim.c.chen@intel.com> - 2016-09-14 02:00 +0200
              Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping  out Minchan Kim <minchan@kernel.org> - 2016-09-19 09:20 +0200
                Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping  out Tim Chen <tim.c.chen@linux.intel.com> - 2016-09-19 18:00 +0200
            Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping out "Huang\, Ying" <ying.huang@intel.com> - 2016-09-18 04:00 +0200
              Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping  out Minchan Kim <minchan@kernel.org> - 2016-09-19 09:10 +0200
                Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping out "Huang\, Ying" <ying.huang@intel.com> - 2016-09-20 05:00 +0200
                Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping out "Huang\, Ying" <ying.huang@intel.com> - 2016-09-20 07:30 +0200
                Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping  out Minchan Kim <minchan@kernel.org> - 2016-09-20 07:40 +0200
          Re: [PATCH -v3 00/10] THP swap: Delay splitting THP during swapping  out Andrea Arcangeli <aarcange@redhat.com> - 2016-09-13 16:40 +0200

csiph-web