I have to compile java code frequently, especially stuff like GWT which take ages to complete. I cannot avoid that overhead but I want to minimize it down with better hardware. Which factor will make these kind of compilation as fast as possible? (I know it's a little subjective, but when it comes to compilation, I'm sure that some factors are more important than the others).
For example, I think a Dual Core that runs at 3.6 GHz/Core may be faster than a Quad Core that runs at 2.8 Ghz/Core when It comes to compilation (especially when java code / GWT code compilation is currently single threaded).
So, what kind of factors should I consider when purchasing hardware with regards to this specific problem?
Edit:
I find it quite general when talking about these compilation without referring to my specific situation. I'm dealing with GWT & Scala compilation, which is damn slower, although I don't observe a high load over my hard disk during compilation.
Should I make it faster with CPU of 4+ cores of 2.4Ghz or CPU of 2 cores of 3.4Ghz? Will dual 2GB of DDR3 RAM make it faster or a dual 4GB DDR2 make it faster? Will RAID 0 make a big difference?
RAM and a fast Hard Disk in this case. In the case of latest C++ compilers CPU is also a factor.
Memory is certainly going to be a factor. If the compiler can't keep necessary state in physical memory you're going to take a huge hit in page swaps.
Memory and hard drive speed are the most important things. If you compile frequently, more memory should mean more files are accessed from the cache rather than from the file. Writing time is generally HD dependent, and compiling Java usually means writing a lot of separate files.
The file system that you use can have a huge impact here, so can defragmenting your disk.
If memory and HD are not bottlenecks, then the number of cores in your CPU might matter, if your environment is smart enough to make us of them (IMHO most environments do a poor job here).
Also, as with teapots and boiling water, a compiler that is being watched takes longer to compile.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With