2

I've got MacBook Pro 2011, 15" i7 2GHz 8GB Ram 1333 MHz OS X Lion 10.7.2 all updates installed released to this date. I have done everything what I can to minimize RAM consumpsion and the only problem I've got at this point is when I run Xcode. I had 4gigs of RAM, than bought 8 gigs and always 've got 10-30 MB of free memory after 3-5 minutes of Xcode running and PAGE INS are 300MB - 700MB. I tried to switch to 32-bit running mode but no change. Can anybody help me please?

Mysiaq
  • 555
  • 4
  • 13

1 Answers1

1

Yes. One way is to disable indexing, another is to reduce the number of build processes. These are hidden preferences in Xcode 4 which I have detailed here:

Hidden Features of Xcode 4

I've also made a pretty extensive write up for improving and working with Xcode's resource issues:

Why are xcodebuild and Xcode 4.2 so slow?

Community
  • 1
  • 1
justin
  • 104,054
  • 14
  • 179
  • 226
  • I did what you post at 1st link, but still the same situation. I also tried reinstall xcode, but no change. Could it help to reinstall OS X, or is it waste of time? I've got really big project, (thousands lines of code c++\openGL\objective-c mixed) and waiting each time to build for 15-20 minutes is unacceptable. Code completion is, in my opinion, key feature in big projects, I really cannot 've got everything in my head and this slows me down ... – Mysiaq Oct 28 '11 at 08:38
  • @Mysiac I just added this to my post: *Note that you should quit Xcode, set the preference values as desired, changes take effect when you restart Xcode.* Was Xcode by chance launched when you set the preferences? – justin Oct 28 '11 at 08:51
  • @Mysiac Reinstalling OS X is not likely to 'fix' anything. FWIW, I am booted into a nearly identical setup as you (17"MBP, 2.2, 8GB, OSX.7.2, Xc4.2 4D199) - also working with large c++ and objc++ projects (100s of KSLOC). Xcode 4 is just slow and resource hungry. The RAM Disk works very well, but you should also manage your dependencies like a large project (if you are not already) and when you can, implement things as c++ rather than objc++ because objc++ is quite slow (to compile). – justin Oct 28 '11 at 08:59
  • Yes, I've got Xcode closed before running the command, after running the command I've restarted system for sure, but still no affect to RAM consumption. I think that project is managed good, I've got multiple targets for core functions (c++) also for libraries (c++) but I need to make native iOS frontend/interface (another target) so I have to use objective-c. I've setup all dependencies, prefix headers etc. The same project with the same configuration running on OS X 10.6 and half of RAM is running much better than on mine OS X 10.7 ... – Mysiaq Oct 28 '11 at 09:19
  • @Mysiaq Ok. Did it require half the memory on OSX.6.x with Xc3 (expected) or Xc4 (not expected, also a resource hog relative to Xc3)? – justin Oct 28 '11 at 10:07
  • Oh wow. I did not notice that here, probably because the Lion+Hardware update happened at the same time - yikes! – justin Oct 28 '11 at 10:49
  • Ok, thx. I'll keep investigating and hope that next update, OS X/Xcode whtvr, will fix this issue ... – Mysiaq Oct 28 '11 at 11:01