views:

562

answers:

14

Hello, I need to know what kind of machine is the best for a C# developer with Visual Studio 2008 software. We have a solution with 30 - 40 projects, and every time we build the solution it takes about 2 minutes.

So if a developer builds this application 20 - 30 times a day, we have a lot of waiting time.

Is it the hard drive we need to optimize, CPU or memory? We absolutely need to decrease the build time.

What kind of setup do big companies use for their developers?

Is Visual Studio 2010 make a difference on Visual Studio 2008 on the build time ?

Can people can tell me the real specification needed.

  • Best Motherboard setting
  • Best Memory setting
  • Best SSD setting
  • Best CPU
  • Brand of each component

I would really want people give me the best match with each component. We gone purchase new machine to get more test and renew the developper PC, so before purchase new component i yould like to get opinions.

+16  A: 

The biggest change I've found is to switch to an SSD hard disk. As well as cutting the startup time to a few seconds, this cuts the build time by ~50% for me.

thecoop
Did your install the OS on your SSD drive or only your source files ?
Cédric Boivin
+1, SSD was a huge benefit, reducing my boot-up time to a 1/3 of what it was and cutting my build time in half for a large solution (103 projects)
Dan Bryant
SSD for my main OS, my source files are on a separate non-SSD SATA disk, but you'll get a large speedup if both are on an SSD.
thecoop
@Dan Bryant How long time it's take ?
Cédric Boivin
@Cedric Boivin, boot-up is about 8 seconds (from power on to the system showing some responsiveness) and build time is about 80 seconds (for a full rebuild).
Dan Bryant
@Cedric - I've moved both my OS and my source files to an SSD, and it's all significantly, nay, dramatically faster. Total side note: the OCZ RevoDrives use a native PCI interface (rather than SATA) and so have a significant performance advantage even against normal SSD's. Just make sure your motherboard supports booting to PCI.
Ken Smith
+4  A: 

I'd guess that drive (speed more than size), then memory, then CPU would help more, though possibly memory more than drive. Of course, any one could already be above requirements and still suffer because the other is a bottleneck, so we can't answer definitively just from this.

Logically breaking up the work so that most builds happen on one or two projects rather than the entire solution would help for free. As would making sure the machine was set up well (defragged, reasonable amount of clean space, sensible page file settings, not bogged down with too unused services, not spending more of its time doing to bidding of some nasty little trojan than it is doing what you bought it to do).

Jon Hanna
+10  A: 

Do you HAVE to build all the projects each time? The cheapest and simplest way to reduce build time is to not build as many projects!

Could you not only build the projects that have changed instead? Or take some projects out and put them into .dll's that are referenced? Or even use a build server so that the developers are free to carry on coding?

No matter what system you get, it's still going to take a considerable amount of time to build, and even more so as development continues.

And as for the system, preferably as high spec as you can get! Although most mid to high range systems will do the trick.

w69rdy
+1, at last, this isn't a hardware problem.
Hans Passant
+1  A: 

I would suggest using Visual Studio Team Foundation, and spending money only for one fast server.

Also as others said, SSD hard disk is best choice, fast memory (and I mean fast, not large amount), and decent CPU (don't be fooled by Mhz size, CPU's speed depends on many other things)

kofucii
+1  A: 

As hardware is relatively cheap these days, i use 8 GB, a top 3..5 processor (top 1 and 2 most of the time have a bad speed/cost ratio) and a SSD disk.

Disk doesn't have to be so big, 100 GB should do the trick for windows, VS, Sql and the solution files.

i install everything else (office, paint tools, etc. etc.) at a cheaper (normal) drive.

Michel
so you install vs and sql, and have all the projects on SSD? this may work for me, though they are expensive
Spooks
A: 

Use SSD if you can afford it.

sh_kamalh
A: 

I don't know what are your machines but may be they are not from the Stone age.

1.) I thing good optimization solution is to build only changed projects. It's not necessary to build all existing projects.

2.) If other projects are only used without need any changes during developing the current project you can add only reference to the dynamic libraries.

flyingbear
A: 

If what you are compiling is quite data intensive then I would update the hard disk, get one with quick read and write speeds. SSD drives are good if you can afford it, if not, go for a quick SATA drive.

If what you are compiling is quite complex (many many lines of code) then consider upgrading the memory and processor.

Probably the best bit of advice however is to optimise your code and only compile it when you need to.

RHodgett
+1  A: 

I had a very similar problem on my machine. I now make extensive use of the "Unload Project" and "Reload Project" functionality of visual studio to handle this.

Matthew Bierman
+2  A: 

At our company we always buy Dell Poweredge servers for developers. They are relativly cheap compared with workstations, and have a lot of power to crunch numbers.

You typically get two Xeon processors + 15,000 Rpm SATA drives + lots of ports for memory + a fast bus. The downside is poor peripherals (but we don't care about top end graphic cards for our developers). And like I said the upside is lower costs than a top-end workstation. It is something I have never seen elsewhere, but makes some sense. In my experience, processing power is the key to fast builds. I have never ever waited long for a build to complete since coming to this company.

One suggestion was to use Team Foundation Server and a powerful box. That is also a good suggestion.

jnielsen
Lucky developers. We usually get low end shits ...
Ladislav Mrnka
That's a lot of SATA drives!! ;)
Richard Hein
A: 

What about multicore and/or -processor computer? Does VS use parallel compilation (like I guess Gnu make does)?

Arto Viitanen
I don't think there a switch to compile in parrallel
Cédric Boivin
@Cedric: There's an option setting "Maximum number of parallel project builds" in the "Build and Run" section. At least, it's there in VS2010, don't know about 2008.
TMN
A: 

When you build, see if the CPU is maxed out. If not, don't get more CPU. Find the bottleneck and fix that first.

Dean J
A: 

Something you might try is getting a small (maybe 32G) SSD and putting all your project files on that, then seeing what your build times are. The smaller SSDs are relatively affordable (around US$150 where I shop), and should be simple to install.

One thing I'd recommend first, though is to fire up the resource monitor (available via a button on the task manager "Performance" tab) and do a build. This should help you pinpoint where your bottlenecks are. If you've got 100% memory usage and lots of disk access to the page file, then you need more memory. If your disk queue length trends upwards (indicating that the disk can't keep up with requests), then you need a faster disk. With modern multi-core processors, it's often difficult to max out the CPU, but keep an eye on it anyway.

TMN
+1  A: 

If I were you I would suggest to setup a cloud server like the ones from Amazon (Amazon EC2), and use it for the amount of time that you need it.

You can choose a high-end server and it won't cost you that much.

Khattab