34 Replies
      Latest reply: Mar 24, 2017 8:34 AM by zlanglois RSS
      lindner514 Level 1 Level 1 (0 points)

        i downloaded the xcode Version 8.0 (8A218a) yesterday and my xcode editor became extremely slow. i can type in a complete line before i see anything on the screen and then the screen displays one character at a time at less than one character per second. the file i am editing i about 1.1 MB. this all worked perfectly before the update. i have tried a new file and copying my old file into it, but that didn't work. the current line highlighting is new as well.

        thanks,

        tom lindner

        FILE:

        kind: C Source

        size: 1,090,739 bytes (1.1 MB on disk)

        MAC:

        MacBook Pro (Retina, 15-inch, Early 2013)

        2.8 GHz Intel Core i7

        16 GB 1600 MHz DDR3

        Intel HD Graphics 4000 1536 MB

        OS:

        OS X El Capitan

        Version 10.11.6 (15G1004)

        • Re: Xcode 8 Editing very slow
          KMT Level 8 Level 8 (6,930 points)

          How much free space on your drive right now?

          • Re: Xcode 8 Editing very slow
            bcallaha Apple Staff Apple Staff (0 points)

            Sounds like a bug in Xcode. We can't be sure until we investigate though.

             

            Please file a new problem using bugreport.apple.com You can gather the information we need by running `sysdianose Xcode` in Terminal while the Xcode is being slow.

              • Re: Xcode 8 Editing very slow
                formbound Level 1 Level 1 (0 points)

                bcallaha,

                 

                With a completely new machine, a 15" Touchbar MacBook Pro from late 2016, these are some of the issues i'm experiencing:

                 

                • Random errors when running on device (An unknown error occurred)
                • Debugger breakpoints on the wrong places,  printing out statements is SLOWER than recompiling the entire product
                • Simply typing in the Xcode editor is slow. Each character comes with a few ms to a few 100 ms delay
                • Autocompletion is effectively useless seeing how slow it is
                • Xcode keeps recompiling not only the current target, but also its dependencies, even though no changes has been made
                • Xcode crashes randomly, and inconsistently several times per day
                • Scrolling through code is laggy, even on a low-resolution screen
                • Animation of opening and closing panels never exceed 2-5 fps
                • Xcode stating that devices are locked, when they in fact are not

                 

                I could go on forever about how the developer experience in Xcode has become so terrible, i sometimes feel like stop developing for iOS as it just keep going downhill. About filing a report on bugreport.apple.com – my radar about Simulator performance took months to even get a reply – i doubts that i will ever get a response on it.

                 

                Feeling quite pesimistic about the future of development on Apple platforms if you cannot even resolve issues regarding developer experience.

                You're not even that responsive in the forums – sounds like the chain of communication up to the actual Xcode developers is broken.

                 

                I'm upset, especially since there are literally thousands of us who could help with the Xcode issues.

              • Re: Xcode 8 Editing very slow
                marraez Level 1 Level 1 (0 points)

                Same problem here and I have 900 GB free Space on a 1Tb Fusion Drive with 16 Gb ram. On xcode 7 it was amazing speed on storyboard, now I can go to take coffe while opens it every time i change from text editor to it.

                • Re: Xcode 8 Editing very slow
                  Mihael Level 1 Level 1 (0 points)

                  I have this problem too. Extremely slow syntax highlighting, editing, replacing in global search, etc.

                  I have 90Gb free space on my MBPr 13" 2015 SSD.

                  • Re: Xcode 8 Editing very slow
                    martinfloresalvarez Level 1 Level 1 (0 points)

                    The same happens to me. is impossible to work , it remains dumbfounded 10 - 15 minutes.

                     

                    311.39 GB free

                    16 mb of RAM

                    xocde 8

                     

                    what append?????

                    • Re: Xcode 8 Editing very slow
                      RendElements Level 1 Level 1 (0 points)

                      Concur with lindner514.

                      I'm seeing huge performance drop-off of Xcode 8 vs old Xcode 7. (I didn't download the beta's as running production code and waited for GM - lesson learned here.. should have tested earlier on 8)

                      IDE syntax highlighting is also slow, and the whole user interface is generally laggy. Seems to be Indexing the project more often, and chews the laptop battery quickly (fan kicks in when compiling)

                      Need to somehow roll back to Xcode 7.

                      * bcallaha - 'sysdiagnose Xcode', left out the 'g'

                       

                      29.79 GB free disk

                      16 GB RAM

                      MBP 15", mid 2012

                      • Re: Xcode 8 Editing very slow
                        marnixalsemgeest Level 1 Level 1 (0 points)

                        I have the same problem. XCode is really crashing every 5 minutes now. First while editing you notice it cannot keep up with the intellisense and makes my Macbook take off like an airplane. After a few minutes Xcode hangs and I need to kill it and restart. 

                        Is there a workaround? because like this I cannot do my job.

                        • Re: Xcode 8 Editing very slow
                          nico419 Level 1 Level 1 (0 points)

                          I have the same issue with XCode 8, does it seem to be stuck on building/indexing everytime you type something in the editor?

                           

                          I've tried to clean the 2 following folder and it seems to speed the build/indexing up. Not as fast as Xcode 7, though.

                          ~/Library/Developer/Xcode/DerivedData/*

                          ~/Library/Caches/com.apple.dt.Xcode/*

                          • Re: Xcode 8 Editing very slow
                            Woody Huang Level 1 Level 1 (0 points)

                            Same problem here. It seem that the code syntax highlighting is taking forever. By checking the Activity Monitor, I can see that the SourceKitService takes over 100% of CPU.

                            • Re: Xcode 8 Editing very slow
                              lindner514 Level 1 Level 1 (0 points)

                              just got the update to Version 8.1 (8B62) ... still not fixed

                                • Re: Xcode 8 Editing very slow
                                  jmf Level 1 Level 1 (0 points)

                                  Just to echo that 8.1 is very slow on my mid-2015 MacBook Pro retina 15" with 2.8GHZ i7 and 16 GB RAM with 74GB on SSD drive available. Can't believe a machine I bought less than a year ago is too slow to run Xcode 8.

                                • Re: Xcode 8 Editing very slow
                                  frodriguezc Level 1 Level 1 (0 points)

                                  I'm having the same problem, yesterday I've fully formatted my iMac and Xcode still can't load a nearly empty storyboard!!

                                  Mid-2015 iMac 5k

                                  Intel Core i5

                                  3,3 GHz

                                  32 GB Ram

                                  960 GB HDD still available..


                                  • Re: Xcode 8 Editing very slow
                                    AISU Tech Level 1 Level 1 (0 points)

                                    I didn't have this problem until today. Last time I used Xcode was 5 days ago and it was running fine.

                                     

                                    I can't believe this problem is still unresolved since September!

                                    Very frustrating.

                                      • Re: Xcode 8 Editing very slow
                                        benstockdesign Level 1 Level 1 (0 points)

                                        I'm running Xcode 8.2 (8C38), and I can confirm that there has been no fix. I can't even use Xcode anymore. I barely type anything, and all text turns white and autocomplete never shows up. I don't even know what to do at this point. :-(

                                      • Re: Xcode 8 Editing very slow
                                        S1148 Level 1 Level 1 (0 points)

                                        I am facing same problem with my Xcode8.0. Its very difficult to code with such slow IDE.

                                        • Re: Xcode 8 Editing very slow
                                          lindner514 Level 1 Level 1 (0 points)

                                          just got the update to Version 8.2 (8C38) ... still not fixed

                                          • Re: Xcode 8 Editing very slow
                                            FirstString Level 1 Level 1 (0 points)

                                            Facing the same issue with version 8.2 (8C38) - latest build of Xcode 7.x did not exibit this behavior. This is general across the board while editing either a source file or a interface builder file. Xcode becomes unresponsive for at least 5-10 minutes, then decides to allow one click, then hangs again for another 5-10 minutes. An endless loop.

                                             

                                            [UPDATE]: Found out that by disabling "Use Trait Variations" on the XIB files the performance returned across both the source files and XIB files. Though this only happend after I watched my views "dance". Literally in real time the widgets in the parent view bounced back and forth within the viewable bounds for a minute. The most bizzare thing I have ever seen developing an interface.

                                             

                                            [UPDATE]: Additional performance boost to almost no delay was setting "Top Bar" and "Bottom Bar" to "Inferred" rather than specifying an option. When anything other than "Inferred" was selected, Xcode came to a halt. This is definitely a bug within Xcode and degrades the IDE functionality.

                                            • Re: Xcode 8 Editing very slow
                                              MangoArmy Level 1 Level 1 (0 points)

                                              Same issue here, Version 8.2.1 (8C1002). 30 Gigs free harddrive, 8 gigs Ram. It's taking upto a minute to identify a syntax error (typing fals instead of false for example). EXTREMELY painful to work with.

                                               

                                              Upgraded from 7 last night, prior to the update I had no issues and had zero lag.

                                              • Re: Xcode 8 Editing very slow
                                                MangoArmy Level 1 Level 1 (0 points)

                                                I have a similar issue, and found a solution on StackOverflow that seems to be working for me. (http://stackoverflow.com/questions/41455511/how-do-you-get-xcode8-to-respond-faster?noredirect=1#comment70117716_41455511) which is the Q/A I posted earlier today. In short, add a UserDefined Setting to your project as: SWIFT_WHOLE_MODULE_OPTIMIZATION = YES

                                                 

                                                This gave me an immidiate solution to my lag issues. I can't explain the how or the why, but I'll take the fix so long as it doesn't revert back tomorrow!

                                                • Re: Xcode 8 Editing very slow
                                                  razvan-paul Level 1 Level 1 (0 points)

                                                  Same thing here, Xcode 8.1. I have tried the following solutions:

                                                   

                                                  http://stackoverflow.com/questions/26151954/sourcekitservice-consumes-cpu-and-grinds-xcode-to-a-halt

                                                  http://stackoverflow.com/questions/41455511/how-do-you-get-xcode8-to-respond-faster?noredirect=1#comment70117716_41455511

                                                  http://stackoverflow.com/questions/36212368/xcode-7-3-is-excruciatingly-slow-when-loading-storyboard-ib

                                                   

                                                  Macbook Air Early 2015, 80 GB free, 4GB RAM (But I don't have anything else opened when working). Bought new at the end of 2015. It's impossible to go from the swiftness and greatness of Xcode 7 to this miserable version. The XIB file I'm trying to open in Xcode 8 is simply frozen, I can't tap any button.

                                                   

                                                  However, I confirm the "Top Bar", "Bottom Bar" bug! I switched to Inferred and the IB is smoother now. Still, the overall experience is quite bad, the lag is clearly visible from the previous versions.

                                                  • Re: Xcode 8 Editing very slow
                                                    tiratjj Level 1 Level 1 (0 points)

                                                    I also have the same issue. My xCode is 8.2.1 (8C1002). It consumes too much time when compiling to device. But it s normal in simulator!

                                                    • Re: Xcode 8 Editing very slow
                                                      tuneri Level 1 Level 1 (0 points)

                                                      Same here! Why hasn't this been fixed yet..Apple come on!

                                                      Version 8.2.1 (8C1002) Xcode becomes very laggy after project build for both device/simulator.

                                                      • Re: Xcode 8 Editing very slow
                                                        Valentin Kalchev Level 1 Level 1 (0 points)

                                                        Same problem - MacBook Pro (Retina, 13-inch, Early 2015) 2.7 GHz i5 8GB running Xcode Version 8.2.1 (8C1002)

                                                        • Re: Xcode 8 Editing very slow
                                                          Luca9307 Level 1 Level 1 (0 points)

                                                          Same problem -  iMac (5k Late 2014)  4 GHz i7 32GB running Xcode Version 8.2.1 (8C1002)

                                                          • Re: Xcode 8 Editing very slow
                                                            smoothcode Level 1 Level 1 (0 points)

                                                            Just started having the same problem, like hitting a brick wall. The editor became unusable. Tried exiting xcode & restarting but slowness persists.

                                                             

                                                            The slowness seems to be related to the length of the source code file. The editor is very slow when editing a .m file with about 6300 lines, but still responsive with source files of a few hundred lines. Will try splitting source into smaller files, but that may be difficult to do in some cases.

                                                             

                                                            Model Name: MacBook Pro (late 2013)

                                                              Model Identifier: MacBookPro11,1

                                                              Memory: 8 GB

                                                              OS: MacOS Sierra, 10.12.3

                                                            • Re: Xcode 8 Editing very slow
                                                              zlanglois Level 1 Level 1 (0 points)

                                                              Same issue on 8.2.1 (8C1002) running on MBP/Mid-2015/2.2GHz i7/16GB ram. I open a .xib from Xamarin using the option to "Right click > Open with... > Xcode Interface Builder". It opens the .xib, starts indexing, then there is a massive drop in performance. I can barely select items to delete from the .xib, I tried dragging a View from the lower right. Constraining views on the page is virtually impossible since even the mouse cursor lags.

                                                               

                                                              There is no reason this should bog down to an excruciating crawl. It's basically impossible to use. I tried downgrading back to 7.3.1, but Xamarin recently had an update that must have broken communication between the latest Xamarin build and 7.3.1, so now I'm forced to use 8.2.1. This is the worst.

                                                               

                                                              EDIT:

                                                              On further investigation, it was the specific .xib I was working with. In the Simulated Metrics for the view, the "Top Bar" property was set to "Opaque Navigation Bar". Setting that option to "None" increased performance from -1000x to 1x. I have no idea why.