Messages in this thread | | | From | Benno Senoner <> | Subject | Re: can't mlockall() more than 128MB, is this a kernel limitation? | Date | Wed, 9 Aug 2000 00:09:39 +0200 |
| |
On Tue, 08 Aug 2000, David Hinds wrote: > Actually, since the present test is only done on the number of pages > to be locked at the time of the system call, it is nearly worthless. > You can already mlock more pages than the "limit": just do mlockall() > with MCL_FUTURE, and allocate your big block of memory afterwards.
Ah, thanks, I always wondered what malloc() would return if at program start we issued an mlockall(MCL_CURRENT|MCL_FUTURE) and then started to malloc() large chunks of mem until we ran out of memory. In theory malloc() should fail if the OS cannot guarantee that the the memory resides in physical ram. (even if enough VM is available) Is this actually true ?
(A simple test app could answer this, but I haven't tried yet)
Benno.
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |