Re: Status Bits and Super Pages

Marcus Brinkmann <[email protected]>
Newsgroups gmane.comp.micro-kernel.l4.l4ka.general
Message-ID <87fy2axy7j.wl%marcus.brinkmann__39138.1631525748$1187872455$gmane$org@ruhr-uni-bochum.de>
At Thu, 23 Aug 2007 13:20:00 +0200,
Neal H. Walfield wrote:
> 
> Hi,
> 
> I'm writing a memory manager and in order to make eviction decisions,
> I want to use the status bits.  Because I'm a good citizen, I've
> written my memory manager to get the largest mappings possible from
> sigma0.  My resource manager, however, sub-divides these pages and
> maps them to clients.
> 
> I suspect (but please confirm) that my resource manager is only able
> to get the status bits for the mappings that it received from its
> pager, not the mappings it sent to its clients.  That is, if it got a
> 64MB fpage from sigma0, even though it may have only handed out 4KB
> pages to clients, there is only a single status bit available to it:
> the one for the 64MB page.  Is this interpretation correct?

As far as I remember it, yes, this is correct.
 
> If so, it seems that if I want status bits for the pages that the
> resource manager maps to its clients, then I have to be careful to
> only map pages of the same size as the ones the manager has.  I
> imagine that I can request new mappings from sigma0 as appropriate,

Or insert an intermediate task.

> but this basically defeats the advantage of having mapped the
> superpages to begin with--most mappings will be small and thus the
> address space with quickly be filled with small mappings.  Plus, with
> this approach, there is the overhead of the cost of the unmap and
> re-map operations.

Yes.  However, there is a related problem that you can not unmap
selectively.  I vaguely remember that Espen had a selective unmap
proposal at some time as a small modification to the L4 X.2 interface.
But I don't remember any details.  Whatever that proposal was should
also provide an opportunity to do selective status bit checking,
shouldn't it?

Thanks,
Marcus
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.