Re: Audio stuttering under CPU load
Re: Audio stuttering under CPU load
- Subject: Re: Audio stuttering under CPU load
- From: Paul Davis <email@hidden>
- Date: Tue, 9 Feb 2010 18:23:38 -0500
On Tue, Feb 9, 2010 at 6:08 PM, Bertrand, Pierre-Luc
<email@hidden> wrote:
> Right !
>
> But I'm pretty confident that there is an assembler instruction in ARM
> equivalent to 'inc eax'. You are correct in Java though that the
> behavior is not as expected because of the thread caching :)
no, its not related to that at all. its related to processor level
reordering of instructions. on modern cpu's you cannot assume that in
the following code:
> Thanks for the warning though.
>
> Pierre-Luc
>
> -----Original Message-----
> From: Paul Davis [mailto:email@hidden]
> Sent: Tuesday, February 09, 2010 5:45 PM
> To: Bertrand, Pierre-Luc
> Cc: Doug Wyatt; email@hidden
> Subject: Re: Audio stuttering under CPU load
>
> On Tue, Feb 9, 2010 at 4:07 PM, Bertrand, Pierre-Luc
> <email@hidden> wrote:
>> Hi,
>>
>> Thanks for the reply. I considered your proposal and modified my
> locking
>> mechanism.
>>
>> Now I only lock to signal the processing thread to start processing a
>> chunk of 800ms. I use a queue that does not lock but rather base its
>> concurrency correctness on the atomicity of integer++.
>
> integer arithmetic is atomic on x86 but it is not guaranteed to be
> ordered the way you expect without the use of explicit memory
> barriers.
>
_______________________________________________
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