While we're on the subject of mmap tricks, here's another one that may be worth benchmarking. (The trick comes from examining the glibc sources).
If you mmap a large contiguous area of memory that is more than you immediately need, mmap it PROT_NONE. The reason is that Linux won't swap out this memory. When you need to use the memory, you call mprotect PROT_READ|PROT_WRITE (on the part that you need) and use it as normal. Rich. -- Richard Jones Red Hat -- Caml-list mailing list. Subscription management and archives: https://sympa-roc.inria.fr/wws/info/caml-list Beginner's list: http://groups.yahoo.com/group/ocaml_beginners Bug reports: http://caml.inria.fr/bin/caml-bugs
