Re: loop efficiency & messages
Re: loop efficiency & messages
- Subject: Re: loop efficiency & messages
- From: John Stiles <email@hidden>
- Date: Tue, 22 Mar 2005 14:21:12 -0800
On Mar 22, 2005, at 1:28 PM, Ondra Cada wrote:
Nevertheless, that are not quite important technicalities. What *is* important is that you just do not need this kind of optimization.
Maybe
you don't.
To say that nobody
ever needed to optimize away the cost of objc_msgSend is absurd. If you have a loop that Shark shows as taking a large % of your CPU time, and the loop body isn't doing much work per iteration, then making this kind of optimization could be very worthwhile.
There are a lot of documents that explicitly discuss ways to lower the cost of objc_msgSend; I'm not going to go look them up, but it's stuff like selector caching, etc. I assume these guys wouldn't have gone to the effort of figuring out these techniques just as an exercise, because they were bored. Obviously the message dispatch cost mattered to them at the time.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden