Re: How to know when memory pages are swapped?
site_archiver@lists.apple.com Delivered-To: Darwin-dev@lists.apple.com Le 4 mai 05, à 22:06, Godfrey van der Linden a écrit : Cheers Godfrey On 05/04/2005, at 12:12 , Stéphane Letz wrote: Hi, from the #include <Kernel/sys/mman.h> __BEGIN_DECLS #ifdef _P1003_1B_VISIBLE int mlockall __P((int)); int munlockall __P((void)); #endif /* _P1003_1B_VISIBLE */ int mlock __P((const void *, size_t)); #ifndef _MMAP_DECLARED #define _MMAP_DECLARED void * mmap __P((void *, size_t, int, int, int, off_t)); #endif Thanks Regards Stephane Letz _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... No. We have been asked for this functionality quite a number of times but there really is no good way for the kernel to notify and heat up code in a client app when it chooses to page out some data. I have to ask, what are you trying to achieve? There is usually someway of achieving a very similar effect. In there any way for an application to be "notified" when one of the memory pages it uses is swapped on the disk? Is there a way to install an handler for "page-out" event? I need to avoid page to be swapped because they are accessed in a real-time audio thread. I finally found that mlock/munlock functions are available for user space code. Is this correct? What is this _P1003_1B_VISIBLE defined for actually? is this for kernel code only? This email sent to site_archiver@lists.apple.com
participants (1)
-
Stéphane Letz