Re: NSMachPort vs. NSMessagePort
Re: NSMachPort vs. NSMessagePort
- Subject: Re: NSMachPort vs. NSMessagePort
- From: Chris Kane <email@hidden>
- Date: Wed, 30 May 2007 20:38:03 -0700
If you're going to use one, use NSMachPort. There is no advantage to
NSMessagePort.
I would not use Distributed Objects for inter-thread communication
myself. The same amount of hassle as setting up something else (just
different hassle), and additional overhead to slow things down.
Chris Kane
Cocoa Frameworks, Apple
On May 30, 2007, at 6:42 PM, Gerriet M. Denkmann wrote:
What is the difference between these two?
In which situations should I prefer one over the other?
The context: a NSDocument based Cocoa app with main thread and a
background working thread for each document, which sit around using
a NSRunLoop waiting for requests.
All worker threads access a common MyDataStore object rather often
(up to 100 000 times per computation) so using NSConnection
(Distributed Objects) seems not such a good idea.
OS X 10.4.9
Gerriet.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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