Memory allocation with no swap
-
Hello! I'm working on an application where a binary file must be loaded and should be kept in memory during all execution. I guess that keeping data in physical memory and avoid memory swap on virtual memory is not possible. Is it a way to keep the whole address space that concerns my application in physical memory? Thank you for any information ! Frédéric. C++/MFC/SQL developer.
-
Hello! I'm working on an application where a binary file must be loaded and should be kept in memory during all execution. I guess that keeping data in physical memory and avoid memory swap on virtual memory is not possible. Is it a way to keep the whole address space that concerns my application in physical memory? Thank you for any information ! Frédéric. C++/MFC/SQL developer.
For NT-based systems, seems like
[MmProbeAndLockPages](http://msdn.microsoft.com/library/default.asp?url=/library/en-us/kmarch/hh/kmarch/k106_8ble.asp)
is the API you're after. For 95 and relatives, have a look atLinPageLock
in the DDK documentation. Joaquín M López Muñoz Telefónica, Investigación y Desarrollo