From: Con Kolivas <kernel@kolivas.org>
To: Andrew Morton <akpm@osdl.org>
Cc: nigelenki@comcast.net, linux-kernel@vger.kernel.org
Subject: Re: Autoregulate swappiness & inactivation
Date: Thu, 08 Jul 2004 18:27:09 +1000 [thread overview]
Message-ID: <cone.1089275229.304355.4554.502@pc.kolivas.org> (raw)
In-Reply-To: 20040708010842.2064a706.akpm@osdl.org
Andrew Morton writes:
> Con Kolivas <kernel@kolivas.org> wrote:
>>
>> Andrew Morton writes:
>>
>> > Con Kolivas <kernel@kolivas.org> wrote:
>> >>
>> >> Ah what the heck. They can only be knocked back to where they already are.
>> >
>> > hm. You get an eGrump for sending two patchs in one email. Surprisingly
>> > nice numbers though.
>> >
>> > How come vm_swappiness gets squared? That's the mysterious "bias
>> > downwards", yes? What's the theory there?
>>
>> No real world feedback mechanism is linear. As the pressure grows the
>> positive/negative feedback grows exponentially.
>
> That takes me back. The classic control system is PID:
> Proportional/Integral/Derivative - they refer to the way in which the error
> term (output-desired output) is fed back to the input:
>
> Proportional: the bigger the error, the more input drive
>
> Integral: feeding back a bit of the integral of the error prevents
> permanent output skew due to non-infinite forward gain.
>
> Derivative: feeding back -(rate of change) provides damping.
>
> You can live without I and D - the main thing is to feed back the -error.
>
> IOW: linear works just fine :)
/me hides
Umm sorry the control systems I look at are physiological and tend to be
exponential, so ignore me.
> Your answer didn't help me understand the design though.
Ok I'll just describe it. I should have just said that when mapped pages are
low the best seems to be a very low swappiness, but not zero as zero seems
to get bogged down easily (kswapd gets busy and basic things take longer) as
occasionally slipping some pages onto swap helps. Generally it's when what I
called the application pages (blush) get to around 75% that allowing things
to swap at the rate equivalent to swappiness==60 is helpful. Once the mapped
pages went greater than 75% the machine would start bogging down again if
the swappiness remained at 60. I guess I made up the maths to fill the way
the design worked best. Linear brought up the swappiness too easily and
under swap thrash made things worse. It looked nicer but didn't really
behave well.
>> > Please define this new term "application pages"?
>>
>> errm it's fuzzy to say the least. It's the closest I can come to
>> representing what end users understand as "non-cached" pages.
>
> Isn't that mapped pages?
I'm all ears.
>> > Those si_swapinfo() and si_meminfo() calls need to come out of there.
>>
>> I'm game. I had the idea but not the skill. Anyone wanna help me with that?
>
> Need to work out what cen be removed first. The freeswap/totalswap can go.
> That leaves us needing what? totalram and freeram. If the algorithm can
> be flipped over to use nr_mapped, we'd be looking good.
Ok. I need some time to clean up this mess and try and figure out what to do
then.
Con
next prev parent reply other threads:[~2004-07-08 8:27 UTC|newest]
Thread overview: 50+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-07-07 15:16 2.6.7-ck5 Con Kolivas
2004-07-07 15:39 ` 2.6.7-ck5 John Richard Moser
2004-07-07 15:47 ` 2.6.7-ck5 Con Kolivas
2004-07-07 15:53 ` 2.6.7-ck5 Prakash K. Cheemplavam
2004-07-07 16:11 ` 2.6.7-ck5 P
2004-07-07 17:10 ` 2.6.7-ck5 Prakash K. Cheemplavam
2004-07-07 16:17 ` 2.6.7-ck5 Redeeman
2004-07-08 4:38 ` 2.6.7-ck5 Andrew Morton
2004-07-08 6:40 ` [PATCH] Autoregulate swappiness & inactivation Con Kolivas
2004-07-08 6:45 ` Con Kolivas
2004-07-08 7:06 ` [PATCH] " Nick Piggin
2004-07-08 7:12 ` Con Kolivas
2004-07-08 7:31 ` Nick Piggin
2004-07-08 8:03 ` Con Kolivas
2004-07-08 8:12 ` Nick Piggin
2004-07-08 17:06 ` John Richard Moser
2004-07-08 17:14 ` [ck] " Mikhail Ramendik
2004-07-08 17:10 ` [ck] Re: [PATCH] " Mikhail Ramendik
2004-07-09 1:03 ` Nick Piggin
2004-07-08 7:10 ` Andrew Morton
2004-07-08 7:58 ` Con Kolivas
2004-07-08 8:08 ` Andrew Morton
2004-07-08 8:27 ` Con Kolivas [this message]
2004-07-08 10:54 ` FabF
2004-07-09 1:05 ` Con Kolivas
2004-07-09 9:48 ` FabF
2004-07-09 10:43 ` Nick Piggin
2004-07-09 11:14 ` FabF
2004-07-09 11:24 ` Nick Piggin
2004-07-10 9:44 ` FabF
[not found] ` <40EFC076.9050504@yahoo.com.au>
2004-07-10 10:57 ` rss recovery FabF
2004-07-10 12:03 ` Nick Piggin
2004-07-13 13:12 ` FabF
2004-07-08 16:26 ` Autoregulate swappiness & inactivation Timothy Miller
2004-07-08 17:12 ` John Richard Moser
2004-07-08 18:37 ` Timothy Miller
2004-07-08 21:40 ` John Richard Moser
2004-07-09 7:44 ` Felipe Alfaro Solana
2004-07-08 16:24 ` [PATCH] Autotune swappiness Con Kolivas
2004-07-08 16:44 ` Andrew Morton
2004-07-09 0:39 ` Con Kolivas
2004-07-09 1:19 ` [ck] " Kerin Millar
2004-07-09 14:23 ` Martin J. Bligh
2004-07-09 14:26 ` Con Kolivas
2004-07-08 15:57 ` [ck] Re: 2.6.7-ck5 GSehp
2004-07-07 16:45 ` 2.6.7-ck5 John Richard Moser
2004-07-07 17:10 ` 2.6.7-ck5 Prakash K. Cheemplavam
2004-07-07 22:26 ` 2.6.7-ck5 Wes Janzen
2004-07-07 22:53 ` 2.6.7-ck5 Con Kolivas
-- strict thread matches above, loose matches on Subject: below --
2000-01-01 17:31 Autoregulate swappiness & inactivation deepfire
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=cone.1089275229.304355.4554.502@pc.kolivas.org \
--to=kernel@kolivas.org \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nigelenki@comcast.net \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.