开发者

What hardware improvements should we make to speed up our build machine?

开发者 https://www.devze.com 2023-01-17 05:44 出处:网络
We have a build machine running in our development department, which we\'ve set开发者_StackOverflow社区 up to build continuously throughout the working day.

We have a build machine running in our development department, which we've set开发者_StackOverflow社区 up to build continuously throughout the working day. What this does is:

  • Deletes the source code previously checked out (5 minutes)
  • Does a clean checkout from subversion (15 minutes)
  • Builds a whole bunch of C++ and .NET code (35 minutes)
  • Builds installers and run unit tests (5 minutes)

Given the above, what sort of impact would adding different hardware have on improving the time it takes to do the above?

For example - I was thinking about using an SSD for the harddisk as compiling involves a lot of random disk access.

The subversion server is currently a virtual machine - would switching it to be a physical machine help the slow checkout?

What impact would upgrading from a Core 2 Duo processor to an i7 make?

Any other suggestions on speeding up the above?


One trick that might speed up the SVN checkout process could be to have a working copy on the build machine, update the working copy and do a svn export from the working copy to the build directory. This should reduce the load on the SVN server and reduce network traffic.

Another trick to reduce the first 5 minutes of cleaning could be to move the old build dir to a temp folder on the same disk and then use another background task to delete the old build dir when the main build completes (could be a nightly cleanup task).


I think you've made good suggestions yourself. Definitely add a faster hard-drive (SSD or otherwise) and upgrade the CPU as well. I think your code repository (Subversion) should definitely be on a physical machine, ideally separate from your build machine. I think you'll notice a big difference after upgrading the hardware. Also, make sure the machine doesn't have any other large tasks running at the same time as the build tasks (e.g. virus scanning) so that the build tasks aren't slowed down.

How is your build machine setup to execute its tasks? Are you using continuous integration software? Is the machine itself a server or just a regular desktop machine?


Another way to speed up SVN is to use binary protocol instead of HTTP.

It looks like the build time is the most time consuming part - that's the best candidate for optimization. What about parallel build spread over other machines in the office - products like Incredibuild might significantly improve compilation time.

0

精彩评论

暂无评论...
验证码 换一张
取 消