Re: iTunes stuttering, and don't shoot me--it might involve Core Audio
Re: iTunes stuttering, and don't shoot me--it might involve Core Audio
- Subject: Re: iTunes stuttering, and don't shoot me--it might involve Core Audio
- From: Steve Checkoway <email@hidden>
- Date: Tue, 9 Aug 2005 15:07:23 -0700
On Aug 9, 2005, at 12:22 PM, Take Vos wrote:
Hi,
> It does raise a question I have been meaning to ask: Is there
some way to
> hint to the OS that in the near future, a particular page of
memory is going
> to be needed so the VM engine could have it ready in physical ram
for the
> next core-audio render cycle?
Yes there is.
First use valloc() function to allocate page aligned memory.
Then use mlock() function to lock this memory, this memory will not
be swapped out, also this function guaranties that all pages
actually point to physical memory.
Use munlock() to unlock this memory and free() to free the memory.
This will prevent the page from being swapped out. If you wish to
merely advise the system that you will be using the page, you can use
madvise(2) with MADV_WILLNEED.
- Steve
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden