• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Grand Central Dispatch in audio render callback
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Grand Central Dispatch in audio render callback


  • Subject: Re: Grand Central Dispatch in audio render callback
  • From: Support <email@hidden>
  • Date: Fri, 29 Jul 2011 19:50:15 +1000

On 29/07/2011, at 7:16 PM, Robert Bielik wrote:

> Support skrev 2011-07-29 10:57:
>> But with GCD this can be done in parallel rendering each voice into its own sample buffer, e.g.
>>
>> const size_t N = voiceCount;
>> dispatch_queue_tqueue = dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_HIGH, 0);
>> dispatch_apply(N, queue,
>> ^(size_t i) {
>> ClearBuffer(buffer[i], numSamples);
>> voice[i]->Process(buffer[i]);
>> });
>
> Ooh... I shrug when OS functions are called within a real-time rendering callback. I'd say that it is not wise to use it because you're then at the
> whim of the OS, and I don't think that the time for the call is guaranteed to be bounded, which means that eventually (or often) you'll fail to
> meet the deadline for rendering.
>

This is what I was wondering about and it does seem hairy. How heavy the overhead is in scheduling each job and if that can block. In which case how does Logic schedule across multiple cores?

> I don't know if it's that much better (but possibly more controllable) but can't you use Intel Threading Building Blocks instead (http://threadingbuildingblocks.org/) ?

I'm not sure on the implementation of TBB, if it includes ARM or not, or how they handle the job creation overhead. I mean, in both GCD/TBB/OpenMP I guess they ultimately pull a thread out of a thread pool.

regards
peter

 _______________________________________________
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

  • Follow-Ups:
    • Re: Grand Central Dispatch in audio render callback
      • From: andre <email@hidden>
References: 
 >Grand Central Dispatch in audio render callback (From: Support <email@hidden>)
 >Re: Grand Central Dispatch in audio render callback (From: Robert Bielik <email@hidden>)

  • Prev by Date: Re: Grand Central Dispatch in audio render callback
  • Next by Date: Re: Grand Central Dispatch in audio render callback
  • Previous by thread: Re: Grand Central Dispatch in audio render callback
  • Next by thread: Re: Grand Central Dispatch in audio render callback
  • Index(es):
    • Date
    • Thread