From: Roman Zippel <roman@augan.com>
To: Rik van Riel <riel@conectiva.com.br>
Cc: Linus Torvalds <torvalds@transmeta.com>,
Jamie Lokier <lk@tantalophile.demon.co.uk>,
Ed Tomlinson <tomlins@cam.org>,
Marcelo Tosatti <marcelo@conectiva.com.br>,
linux-mm@kvack.org
Subject: Re: swapout selection change in pre1
Date: Thu, 18 Jan 2001 16:38:54 +0100 [thread overview]
Message-ID: <3A670E0E.5394FFFD@augan.com> (raw)
In-Reply-To: <Pine.LNX.4.31.0101181032150.31432-100000@localhost.localdomain>
Hi,
Rik van Riel wrote:
> > Reverse mapping is basically not simple at all. For each page table entry,
> > you need a
> >
> > struct reverse_map {
> > /* actual pte pointer is implied by location,
> > if you implement this cleverly, but still
> > needed, of course */
> > struct reverse_map *prev, *next;
> > struct vm_struct *vma;
> > };
>
> Actually, you need only 2 pointers per page.
>
> struct reverse_map {
> pte_t * pte;
> struct reverse_map * next;
> };
To keep memory usage low and to still be reasonably fast, we could
restrict the size of a vma to two mmu levels and cache a pointer to the
pmd table in the vma, so you have less to lookup in the page table. It
would also speed up normal mapping/unmapping of entries for
architectures with more than 2 mmu levels. Generic mm code had mostly
only to deal with two mmu levels and e.g could call "pmd =
pmd_alloc_vma(vma, address);" instead of "pgd = pgd_offset(mm, address);
pmd = pmd_alloc(pgd, address);". No idea if this is fast enough for
balancing, but it would simplify other parts. :-)
bye, Roman
--
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:[~2001-01-18 15:38 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-01-13 3:28 Marcelo Tosatti
2001-01-13 8:05 ` Linus Torvalds
2001-01-13 7:41 ` Marcelo Tosatti
2001-01-15 1:22 ` Ed Tomlinson
2001-01-15 2:48 ` Linus Torvalds
2001-01-15 9:24 ` Jamie Lokier
2001-01-15 8:16 ` Marcelo Tosatti
2001-01-15 18:24 ` Linus Torvalds
2001-01-15 18:40 ` Jamie Lokier
2001-01-15 18:55 ` Linus Torvalds
2001-01-15 21:44 ` Jamie Lokier
2001-01-15 21:57 ` Linus Torvalds
2001-01-15 22:36 ` Jamie Lokier
2001-01-17 23:40 ` Rik van Riel
2001-01-18 15:38 ` Roman Zippel [this message]
2001-01-17 7:19 ` Rik van Riel
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=3A670E0E.5394FFFD@augan.com \
--to=roman@augan.com \
--cc=linux-mm@kvack.org \
--cc=lk@tantalophile.demon.co.uk \
--cc=marcelo@conectiva.com.br \
--cc=riel@conectiva.com.br \
--cc=tomlins@cam.org \
--cc=torvalds@transmeta.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