Re: using grand central dispatch with c++ for inter-thread communication
site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:subject:mime-version :content-type:from:in-reply-to:date:cc:content-transfer-encoding :message-id:references:to:x-mailer; bh=7SyVHoqB86xO4Co9RvZM+PW4IiUdhGU+MyNr0UBl+EU=; b=naR2Iz3TAebzbZbeGm4kGs5erIoUyoayRZbE2MA9uJDgdki6uE8tH9nY6N0BZuYaIA DG+3b+LDiG7VicFdn/SvT83+O1Xv+lYtACjRmgydmsJWZ8wW46/turu7wApvlNE2YocR Vxb5UqL6afDIeO/IUHpXNJqIeInTmO/T+1Bs4= Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; b=abRONEIdzJPsTxGRUeNNQe5et/n4GTBvte+ljJZhv1VeWJL3ob3LgQOx8eddkUQpoY xTgcP7OGbCX07enb+wM5vHOKuQPLU2JBa/t5VKMBnwDDOUV6WDhbn38dhsedv+PPIKxg 3HTrrbzkoxcVKfa30T5g0VUeA04ODaDUvwJXk= On Apr 21, 2010, at 4:14 PM, Brian Bechtel wrote:
Wouldn't pointing directly to the article be more efficient?
<http://wagerlabs.com/grand-central-dispatch-c-and-inter-thread-com>
A bit of context is probably due... I wrote a user land USB driver and packaged it in a framework. The framework starts the driver in a new thread upon initialization. I needed the separate thread and needed a way to talk to it. I explored Mach ports but these turned out to be too painful. Grand Central Dispatch, on the other hand, turned out to be the answer to my prayers. I can shuffle code and data back with no problems whatsoever. As a bonus, my API calls are queued and serialized for me so I don't need to lock portions of the driver for concurrent access. --- http://es.linkedin.com/in/joelreymont http://twitter.com/wagerlabs _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... This email sent to site_archiver@lists.apple.com
participants (1)
-
Joel Reymont