On May 9, 2009, at 9:45 AM, Dan Herman wrote: I just started getting hangs of 5-10 seconds during code indexing in xcode 3.1. As an example:
- I edit a header file and save - Activity Viewer shows xcode indexing the cpp files that include that header - while that indexing is happening, I try typing in an editor window, pulling down a menu, etc. I get a spinning wheel in xcode. Other applications continue to be normally response. - when indexing completes in the Activity Viewer, xcode is normally responsive again
This is on an 8-core Mac Pro... so there's plenty of cores just sitting around waiting to do that re-indexing job without tying up my UI....
Is anyone else seeing anything like this? Any ideas on how to investigate?
What I've tried: - turn off indexing: that indeed makes the hangs cease (is turning it off and back on enough to cause the index to fully rebuild?) - clean build, cleaning dependencies
(One rather weak suspicion... this started happening not long after moving my account from a local one to a mobile account via Portable Home Directories on a local-network Leopard Server 10.5.6; but PHD appears to be working fine, and moreover the xcode project is not in my home directory.)
Do your source code or header files use import or include statements like this?
#import <net/Something.h>
If so, this is a known Xcode bug -- Xcode is erroneously statting the /net directory on your machine, which then waits on network traffic.
This bug is fixed in the next version of Xcode.
If you don't have source code like that, then you'll want to follow Scott's advice, reproduced below.
-- Andrew
On May 9, 2009, at 10:07 AM, Scott Tooker wrote: Using Spin Control, you should be able to capture samples of those short hangs. Then I'd file a bug with steps to reproduce (bonus points for providing a simple project that shows the problem).
Scott
|