XCode 8.2.1 frequently gets slow

I'm using XCode 8.2.1 (8C1002) on MacBook Pro (MF840) to write some swift code. There is 17G dis space available if anyone interets to know.


Problems:

1. Syntax highlighting frequently fails: At anytime after I type something, there is about 30% chance to break the syntax highlighting and everything except the basic keywords goes white (I'm using the built-in Civic theme, a black-background one), member variables -- white colored, member functions -- white colored, type annotation -- white colored.

3. Issue detector is not responding quickly, sometimes even doesn't respond: This may related to the Problem 1, once syntax highlighting fails, there is not issue reported. Sometimes I even have to Build the project to see if I typed something wrong.

2. Auto completion is lagging: There is a 1% chance of getting immediate auto completion suggestion and remaining 99% is 2-second-delayed suggestion, what would a auto completion worth if it takes 2 seconds to show up? I can type it in 1 sec or less.


It's instinctive -- the swift parser is busy doing something and the subsequent services is not available. But why? why does simply typing a single line inside a function body cause an impact on the whole file?


When all these happens, there is no sign of lack of resource, cpu fan is silent, temperature is low, and the cpu/disk-io load is low regarding to Activity Monitor.

Currently working on a mixed Objective-C and Swift project and I can recognize all the symptoms you describe when editing Swift. When editing Objective-C it's almost stunning how responsive everything becomes. And yeah of course I can understand reasons for there being a difference between the 2 languages but hopefully it's already a top priority task to make Swift editing more tolerable

XCode 8.2.1 frequently gets slow
 
 
Q