Compilation times, a survey

I am wondering what compilation times do you guys typically deal with when working on JUCE plugins.
This is pretty unscientific as this does vary a lot from project to project, but I think the big picture could be interesting nonetheless.

Here are my figures:

JUCE: 7.0.7
OS: Windows 10
Compiler: Visual Studio 2022
CPU: i3-8100B
RAM: 32GB
Project: the usual JUCE modules, no external libraries, around 100 classes and 15k lines of specific code (mostly headers-only code)

Times:

  • Release full optimization, no LTO, incremental (one file touched): 9 sec
  • Release full optimization, no LTO, full rebuild: 60 sec
  • Debug no optimization, no LTO, incremental (one file touched): 9 sec
  • Debug no optimization, no LTO, full rebuild: 30 sec
1 Like

bump :slight_smile:

As you say it’s going to vary loads from project to project, and from machine to machine so it’s tricky to do any meaningful comparison.

It’s also going to vary a lot based on your programming style - i.e. do you use a lot of templates and other constexpr stuff? Do you have loads of binary files that need to be bundled? Are we counting project generation, and compiling tests, etc.?

In general though, on CI our builds take 5 mins on macOS and 10 mins on Windows. That includes the CMake generate and a bunch of other stuff so the actual compilation time is only about 50% of that (2.5mins - 5mins). Then there’s also all the signing, norarization etc. so in total, from the moment you push to the moment you have a releasable artifact, it’s ~18mins average.

1 Like

Thanks!
What is your typical compilation time for increment debug builds?

This depends also on the structure of your solution. You probably get faster incremental compile times if you separate some parts of your application with headers that do not contain any code. I think otherwise all classes that import the modified header have to recompile too. I can imagine that it always compiles all your 100 classes because of this.
Maybe you can find out more about it if you check the modification date of the obj files in the build folder after compiling. Just a wild guess.