Re: Limiting GCD concurrent queues

2015-05-08 Thread Graham Cox
> On 9 May 2015, at 6:19 am, Ken Thomases wrote: > > You should use an NSOperationQueue. You can set its > maxConcurrentOperationCount. You can add blocks to it using > -addOperationWithBlock: or by instantiating NSBlockOperation objects and > adding those with -addOperation:. Though watc

Re: Limiting GCD concurrent queues

2015-05-08 Thread Carl Hoefs
> On May 8, 2015, at 1:19 PM, Ken Thomases wrote: > > You should use an NSOperationQueue. You can set its > maxConcurrentOperationCount. You can add blocks to it using > -addOperationWithBlock: or by instantiating NSBlockOperation objects and > adding those with -addOperation:. Awesome, th

Re: Limiting GCD concurrent queues

2015-05-08 Thread Ken Thomases
On May 8, 2015, at 1:51 PM, Carl Hoefs wrote: > I need to limit a GCD concurrent queue to a specific number of concurrently > executing tasks (less than the number of cores available). > I was hoping an API like the following might be lurking around somewhere: > >gcdConcQueue = dispatch_qu