From: Andrea Arcangeli <andrea@suse.de>
To: "Stephen C. Tweedie" <sct@redhat.com>
Cc: Marcelo Tosatti <marcelo@conectiva.com.br>,
Rik van Riel <riel@conectiva.com.br>, Jens Axboe <axboe@suse.de>,
Alan Cox <alan@redhat.com>,
Derek Martin <derek@cerberus.ne.mediaone.net>,
Linux Kernel <linux-kernel@vger.rutgers.edu>,
linux-mm@kvack.org, "David S. Miller" <davem@redhat.com>
Subject: Re: [PATCH] 2.2.17pre7 VM enhancement Re: I/O performance on 2.4.0-test2
Date: Tue, 11 Jul 2000 18:17:25 +0200 (CEST) [thread overview]
Message-ID: <Pine.LNX.4.21.0007111756200.3644-100000@inspiron.random> (raw)
In-Reply-To: <20000711125006.S1054@redhat.com>
On Tue, 11 Jul 2000, Stephen C. Tweedie wrote:
>Hi,
>
>On Sun, Jul 09, 2000 at 10:31:46PM +0200, Andrea Arcangeli wrote:
>>
>> Think what happens if we shrink lru_mapped first.
>
>It's not supposed to work that way.
Think if I shrink the lru_mapped first. you could have 100mbyte of clean
and unmapped cache and before shrinking it you would unmap `vi`. So you
would unmap/swapout vi from memory while you still have 100mbyte of
freeable cache. Isn't that broken? The other way around is much more sane.
With the other way around as worse you will have zero fs cache and you'll
run just like DOS.
The object of this simple example is to show that the lrus have different
priorities. These priorities will probably change in function of the
workload of course but we can try to take care of that.
>> Note I'm not thinking to fallback into lru_mapped when lru_cache is empty,
>> but probably doing something like, free 3 times from lru_cache and 1 from
>> lru_mapped could work. The 3 times should be a dynamic variable that
>> changes in function of the pressure that we have in the lru_cache.
>
>No, the mechanism would be that we only free pages from the scavenge
>or cache lists. The mapped list contains only pages which _can't_ be
>freed. [..]
We will be _able_ free them on the fly instead. The only point of the
page2ptechain reverse lookup is to be able to free them on the fly and
nothing else.
>[..] The dynamic memory pressure is used to maintain a goal for the
>number of pages in the cache list, and to achieve that goal, we
>perform aging on the mapped list. Pages which reach age zero can be
>unmapped and added to the cache list, from where they can be
>reclaimed.
>
>In other words, the queues naturally assist us in breaking apart the
>jobs of freeing pages and aging mappings.
I see what you plan to do. Fact is that I'm not convinced it's necessary
and I prefer to have a dynamic falling back algorithms between caches that
will avoid me to have additional lru lists and additional refile between
lrus. Also I will be able to say when I did progress because my progress
will _always_ correspond to a page freed (so I'll remove the unrobusteness
of the current swap_out completly).
>> I think it's better to have a global LRU_DIRTY (composed by any dirty
>> object) and to let kupdate to flush not only the old dirty buffers, but
>> also the old dirty pages.
>
>We _must_ have separate dirty behaviour for dirty VM pages and for
>writeback pages. Think about a large simulation filling most of main
>memory with dirty anon pages --- we don't want write throttling to
>kick in and swap out all of that memory! But for writeback data ---
Good point (I was always thinking about MAP_SHARED but MAP_ANON is dirty
in the same way indeed). So I think at first step I'll left the dirty
pages into the lru_mapped lru. With the locked-pages-out-of-the-lru trick
I could reinsert them to the bottom of the lru (old pages) when the I/O is
completed so that we could free them without rolling the lru again.
Andrea
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux.eu.org/Linux-MM/
next prev parent reply other threads:[~2000-07-11 16:17 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20000629114407.A3914@redhat.com>
[not found] ` <Pine.LNX.4.21.0006291330520.1713-100000@inspiron.random>
2000-06-29 13:00 ` Stephen C. Tweedie
2000-07-06 10:35 ` Andrea Arcangeli
2000-07-06 13:29 ` Stephen C. Tweedie
2000-07-09 17:11 ` Swap clustering with new VM Marcelo Tosatti
2000-07-09 20:53 ` Andrea Arcangeli
2000-07-11 9:36 ` Stephen C. Tweedie
2000-07-09 20:31 ` [PATCH] 2.2.17pre7 VM enhancement Re: I/O performance on 2.4.0-test2 Andrea Arcangeli
2000-07-11 11:50 ` Stephen C. Tweedie
2000-07-11 16:17 ` Andrea Arcangeli [this message]
2000-07-11 16:36 ` Juan J. Quintela
2000-07-11 17:33 ` Andrea Arcangeli
2000-07-11 17:45 ` Rik van Riel
2000-07-11 17:54 ` Andrea Arcangeli
2000-07-11 18:03 ` Juan J. Quintela
2000-07-11 19:32 ` Andrea Arcangeli
2000-07-12 0:05 ` John Alvord
2000-07-12 0:52 ` Andrea Arcangeli
2000-07-12 18:02 ` Rik van Riel
2000-07-14 8:51 ` Stephen C. Tweedie
2000-07-11 17:32 ` Rik van Riel
2000-07-11 17:41 ` Andrea Arcangeli
2000-07-11 17:47 ` Rik van Riel
2000-07-11 18:00 ` Andrea Arcangeli
2000-07-11 18:06 ` Rik van Riel
2000-07-17 7:09 ` [PATCH] 2.2.17pre7 VM enhancement Re: I/O performance on Yannis Smaragdakis
2000-07-17 9:28 ` Stephen C. Tweedie
2000-07-17 13:01 ` James Manning
2000-07-17 14:32 ` Scott F. Kaplan
2000-07-17 14:53 ` Rik van Riel
2000-07-17 16:44 ` Manfred Spraul
2000-07-17 17:02 ` Rik van Riel
2000-07-17 18:55 ` Yannis Smaragdakis
2000-07-17 19:57 ` John Fremlin
2000-07-17 14:46 ` Alan Cox
2000-07-17 14:55 ` Scott F. Kaplan
2000-07-17 15:31 ` Rik van Riel
2000-07-14 9:01 ` [PATCH] 2.2.17pre7 VM enhancement Re: I/O performance on 2.4.0-test2 Stephen C. Tweedie
2000-07-11 18:13 ` Juan J. Quintela
2000-07-11 20:57 ` Roger Larsson
2000-07-11 22:49 ` Juan J. Quintela
2000-07-12 16:01 ` Kev
2000-07-06 13:54 ` [PATCH] 2.2.17pre7 VM enhancement Re: I/O performance on2.4.0-test2 Roman Zippel
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=Pine.LNX.4.21.0007111756200.3644-100000@inspiron.random \
--to=andrea@suse.de \
--cc=alan@redhat.com \
--cc=axboe@suse.de \
--cc=davem@redhat.com \
--cc=derek@cerberus.ne.mediaone.net \
--cc=linux-kernel@vger.rutgers.edu \
--cc=linux-mm@kvack.org \
--cc=marcelo@conectiva.com.br \
--cc=riel@conectiva.com.br \
--cc=sct@redhat.com \
/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