Getting a serial queue when asking for a concurrent one
Getting a serial queue when asking for a concurrent one
- Subject: Getting a serial queue when asking for a concurrent one
- From: Kevin Meaney <email@hidden>
- Date: Thu, 20 Mar 2014 20:05:41 +0000
I'm doing:
myQueue = dispatch_queue_create("myque", DISPATCH_QUEUE_CONCURRENT);
dispatch_set_target_queue(myQueue, dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0));
When I hit a breakpoint in the debugger in when running in myQue I'm informed that the queue "myque" is a serial queue. If I just do:
myQueue = dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0);
Then when I hit the breakpoint I'm informed that the queue is a concurrent queue.
Now the Concurrency Programming Guide documentation says that to get a concurrent queue you use the dispatch_get_global_queue. What I suppose confuses me, is that in the header "queue.h" the notes for dispatch_queue_create for the attr param specify DISPATCH_QUEUE_CONCURRENT and DISPATCH_QUEUE_SERIAL as options.
If I option click on the dispatch_queue_create symbol it informs me that prior to 10.7 the only option for the attr param is DISPATCH_QUEUE_SERIAL.
Kevin
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden