Add ccache support to Dockerfiles and build workflow#892
Add ccache support to Dockerfiles and build workflow#892lukovdm wants to merge 15 commits intostormchecker:masterfrom
Conversation
|
It seems like using ccache together with precompiled headers (PCH) does not really work. You get a really low ccache hit rate like this: I have done a quick benchmark (on a 24 core machine) of turning PCH on and off with and without a warm cache. These are the results:
So with a cold cache disabling PCH costs time. But with a warm cache all compile calls actually hit the cache, and it is thus much faster. Most time was taken up by the dependencies. For the GitHub actions CI we would always have a warmish cache, and thus it seems like it would be worth it to me to disable PCH for them. For people building storm themselves I don't know, it depends on how much we value cold cache builds versus warm cache builds. |
…kflow; add benchmark script for compile time analysis
|
Nice idea @lukovdm! I think it is good to try to decrease the building times in the CI. Some thoughts:
|
|
Thanks for the questions.
Also, some GitHub workflows are not properly caching yet, but the once that are, are running in 4-10 minutes. |
|
Thanks for the detailed answers. One thing I noticed looking at the latest CI run, for example here is that carl and sylvan seem to be rebuild each time. I think that might be due to the way how we configure the fetchcontent. |
|
Thanks Luko! Do you have any profiling of the compilation process with a warm start? We do have some ways of profiling storm compilation processes and it would be nice to know where the time is lost. I second Matthias: For the main branch, PCH seems preferable, in particular as I care about the cold start compile time a lot. (Although this is shifting with more people using binaries). If your goal is to speedup the CI, I think it also really gets time to exclude some tests --, for runs where the CI is failing during compilation, that probably doesn't matter that much, but we sometimes have to wait for CI as we cannot run too many things in parallel... |
|
I opened a discussion for a CI revision #894 |
|
Related to #763 |
|
Thanks for the investigation. Looks like spot will be recompiled any time. I think we should figure out why this is happening and whether we can prevent this. |
|
I got spot to use ccache and this helped quite a bit again. These benchmarks also have ass tests enabled:
|
|
Ok, what I gather from this are a few questios:
|
|
Regarding spot: We could
|
Things to try:
|


The PR CI actions where slowing me down quite a bit thus I investigated a bit into how it could be sped up. I added caching of the homebrew downloads and added ccache in all builds with a github cached ccache.