52

I recently updated my MacBook Pro (2.3 GHz Intel Core i5) from Lion to Mountain Lion and simultaneously upgraded Xcode to the latest 4.5 version. I've experienced one very irritating problem. While programming I'm used to have a couple of tabs opened at a time. Ever since I updated, each time I switch tabs, Xcode freezes up for a bit (a couple of seconds). Does anyone have a suggestion to solve this problem?

I followed a tip on deleting project.xcworkspace to improve performance. Which seamed to help, but only for a short period of time.

5
  • 4
    I get the same problem. Xcode recreates the project.xcworkspace quickly so this would only be temporary.
    – pho0
    Sep 27, 2012 at 21:40
  • Same symptoms as you, rMBP, 10.8.2. Sep 28, 2012 at 17:51
  • Same here - very frustrating. Not just tab switching, but also opening search and a variety of other things. Using the tip in the linked answer fixes it until I add a new tab, then it's back to 5+second tab switching (on iMac 4xi5 3.1GHz, 10.8.2) Sep 29, 2012 at 18:52
  • same here... really terrible. Oct 1, 2012 at 14:04
  • 3
    It has been reported in apple forums and it looks like they are working on it. Hope it will be resolved soon. Meanwhile... you can use windows instead of tabs. It's ugly, but seems to work.
    – Luis
    Oct 1, 2012 at 17:32

4 Answers 4

8

It's a common issue and was fixed in XCode 4.5.1.

https://devforums.apple.com/thread/167765?tstart=0

2
  • 2
    itunes.apple.com/us/app/xcode/id497799835?mt=12 ~~~ XCode 4.5.1 ~ confirming "tab-changing-lag" back to acceptable level.
    – dklt
    Oct 10, 2012 at 5:57
  • 3
    Is still very slow on 4.6.1. It should be instant, right now is more like almost 1 second.
    – mskw
    Apr 7, 2013 at 16:16
2

If you have multiple partitions (maybe a backup of Lion was kept) ensure that xcode really comes from the Mountain Lion partition.

The App Store App update for Xcode seems to take the first Xcode.app it finds and will apply any update to that version. In my case it updated the (inactive) Lion partition, even so I booted from the ML partition. xcode-select did not complain when I tried to change it to the ML version.

So I ended up doing the great housekeeping:

  • do a chmod 000 /Volume/<old Lion partition>/Applications/Xcode.app
  • installed a fresh copy on Xcode.app into /Applications
  • verify the destination of the dock icon (must point to the ML Xcode.app)

My Xcode is now fast as before and it remains fast. You can get the Xcode dmg and the command line tools from https://developer.apple.com/downloads/index.action. I don't think there is a difference in the binaries, but with the DMG I could see where I dropped the Xcode.app.

1

I found your question before I discovered a partial solution.

As of today, I find XCode 4.6.1 GUI dog slow for my taste, specially considering that I run on a one year old mac, SSD, compile to a 2GB RAM disk and still have 6GB RAM left. Even Eclipse runs lightning fast compared to XCode

4.5.1 did improve something, but after a long time using XCode I do not have any hope for some of its problems being solved ever.

That being said, I have noticed that "Live issues", the main tool bar and all the panels slow down tab switching to same degree. The biggest offender so far are the navigator panels.

Once I got used to a minimalistic Xcode window, layout some specific task tabs, keep a separate window for xibs and learned the shortcuts to enable/disable the panels, I no longer suffer so much with XCode responsiveness, but there is still some lag that can be clearly felt.

-2

Check that there is not heavy coding on ViewWillDisappear. Also if you have NSURLConnection or any other having delegate methods should not get called while switching tabs.

1
  • 1
    This is a problem while using the developer tool (Xcode), not while running the code.
    – Anden87
    Oct 3, 2012 at 14:46

Your Answer

Reminder: Answers generated by Artificial Intelligence tools are not allowed on Stack Overflow. Learn more

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.