Diego Roversi <[EMAIL PROTECTED]> writes:

> I think that storeio is the only possibility to put a cache mechanism in
> user space. But I see some drawbacks:
> - memory user for caching can be paged out 

If that happens, you're doing it wrong, I think. You want to use a
special pager for the cache. When the kernel tells the pager to page
out a page in your cache (my understanding of the details on how this
happens is very vague), you don't want to write it to the swap, you
can just throw it away, and reread it from the original location when
it is accessed the next time (ok, that's for read-only access, but
that's the simplest case).

And that's exactly what mmap is supposed to do. I'm not sure what
parts of mmap are done in Mach and how much of it is done in various
hurd components, but I hope you can reuse or at least learn from that
code.

On the other hand, AFAIK, ext2fs *is* already mmapping the entire
device (that's the source of the current limit on partition size), so
I don't know why we're having this problem. Perhaps the general
mmapping mechanisms can be improved to cache better?

Regards,
/Niels

_______________________________________________
Bug-hurd mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/bug-hurd

Reply via email to