Xcode Too Slow to Work - xcode

I've been searching this question for quite a while but still none of the solutions work, this time I got the error message, Xcode playgrounds don't work and if I make a regular iOS app project and run it in the simulator it will have the loading screen for around 15 minutes and then gives the error message: The operation couldn't be completed. (Match error -308 - (IPC/might) server died)
I've recently tried using my iPhone to run projects which works. Is there and way to make Xcode work normally.
I am using a Mid-2012 MacBook Pro Non-Retina with 4GB RAM.

I had similar errors (if overly slow apps are an error). Your problem is that one process awaits another and has an expire timeout. The other process takes a large time to load.
you might be able to solve this by adding a substantial amount of ram and moving the simulators to a RAM disk, alternately you might upgrade to an ssd.
realistically your best bet is buying new retina MacBook Pro. Thats how I solved it...

Related

Xcode freezes on "fetching app store configuration"

I have mac os mojave and xcode Version 10.1 (10B61). I try build unity3D game. I can successfully build it to iphone 5S device. But when I try submit up to App Store it is not working.
What exactly happens:
On step "fetching app store configuration" xcode freezes. In active monitor I see it as unresponsible application (or something like it). And XCode take almost all free RAM (4.5GB). After sometime (around 20 minutes) mac restart (I have problem with iMac, it restart when use too much RAM, I don't think it related to xcode)
Actually, if I wait long enough (more then 15 minutes) it is start working.
XCode require a lot of RAM + SWAP
Here's an answer for someone who stumbles upon this later, I just want to share what helped me. I also ran into the same problem while trying to distribute a Unity-built game with Xcode (also contains pods).
I work on a MacBook Air 2013 with only 4GB of RAM, so whenever I do anything with Xcode, I first close everything other than Xcode, Finder and Activity Monitor. As soon as I start whatever it is that usually freezes Xcode, I switch to Activity Monitor and track what's happening with the memory.
In the case of freezing while "Fetching App Store Configuration...", the problem appeared to be RAM, more precisely SWAP. I did not have enough memory available on my hard drive, which Xcode tried to use for SWAP and just... well, failed. So I cleaned up my hard drive and finally it went through very smoothly, but it occupied about 9GB of RAM at its peak (5.4GB in SWAP).
So just try to have enough memory available to feed the beast, observe what's happening in Activity Monitor and you should be good.

Xcode 7 slow and sluggish

Since upgrading to xcode 7 and greater, the performance of xcode is terrible. When I click on a class or scroll the code pane it sometimes takes up to 30 seconds before reacting and often I need to force quit xcode and restart.
I have turned off source control and I am not using swift.
I have a new macbook pro with 8gb memory and an SSD. my computer is fast and has no other performance issues.
-UPDATE-
I have cleared derived data and am not using any unusual plugins
Does anyone know what may be the problem? I imagine some build setting is causing this but im not sure which.
The issue is totally with xcode 7.
try to commit/save every time you make some changes, it will increase some performance

Xcode crashes due to low memory and then erases currently open file?

This has happened 3 times now with the previous and current versions of Xcode. It's been nearly catastrophic twice. I have good backups but sometimes I will lose 3 hours of work at a time. I'm on a Macbook Air and the SSD is small so the drive sometimes runs tight and a few open programs will put it over the limit.
This is completely ridiculous for an IDE to do this. Does anyone have a fix?

Xcode uses 16 gigs of RAM in 2 minutes

I'm working on a big project and I have some serious problems with Xcode RAM management. In the informative app I'm working on I have over 90 UIVIewControllers on my storyboard. Once I open my project and go to my storyboard file (just changing labels, zooming in and out etc') it takes less than 2 minutes for Xcode to go from 400MB usage to 8 gigs.
This will only happen while I'm using the storyboard.
This never happened to me in other apps I've managed so I believe it got something to do with the size of this app.
The above was on a new MacBook Pro. To test things out I tested it on a Mac Pro with 16 gigs of RAM. First run, same issue. 16 Gigs of ram is used after less than 2 minutes.
Things I've tried:
Deleting DerivedData (the issue is on 2 different machines so it can't be it but tried it anyway)
Deleting project.xcworkspace
Read about stoping indexing BUT without autocomplete and quick help I'll have nothing to compile anyway
I'm using Xcode 4.6.3
sounds like it is a problem with that version of Xcode. I am using 4.6.3, and have never experienced this, (although the apps I work on are never that big). You should definitely try Xcode 5, even if you cant submit to the appstore, at least you'll be able to work on your app. Then you MIGHT be able to open it in version 4.6.3, and submit it from there, not quite sure it will work, but its worth a shot. Make sure you keep a copy of what you have so far incase your Xcode 5 version wont work in 4.6.3, so you dont loose your work. hope this helps.

iPhone OS: EXC_BAD_ACCESS and xcode freezing while debugging on device?

So usually when EXC_BAD_ACCESS happens when I'm debugging my (largely c++ based) iphone app, I can go over to the GDB window and it'll show me the current stack.
However, for some reason, lately XCode freezes. This happened on both xcode 4 and xcode 3.
By freezing, I mean the wheel of death just spins non-stop, and after a while, the whole OS becomes unresponsive. On many occassions, I had to turn off the mac manually.
Could this be a case of trashing? I'm compiling a 300 files, 150k sloc project on an old 2009 mac mini with only 1GB memory. Could this be the reason? I'm pretty close to just buying a new mac mini with 8GB memory, but it seems a bit unlikely that a 2 year old computer can't handle simple compilation.
Considering I use 2GB of RAM without even loading Xcode, your 1GB could well be a problem.
It also could be a recursive bug that causes the debugger a hell of a lot of work by having an enormous stack trace.
It might be an problem in some infinite while/for loop. Try to set break-point in all such kind of piece of code where while/for loop are used.

Resources