saker.build Documentation TaskDoc JavaDoc

Performance comparisons

Saker.build is fast. But don't take our word for it, take our graphs for it!

We'll be showcasing the performance measurements from the saker.java.compiler and the saker.msvc packages.

Java compilation

We've made many efforts to improve both or clean and incremental Java compilation times. As a result, saker.build compiles Java projects 15-70% faster compared to Gradle. For clean builds, the following results were measured:

Clean Java compilation
Test caseSaker.buildGradle
Apache commons library22272698
Large multi-project2013336774
Large monolithic project3125862419

When it comes to clean build performance, saker.build overtakes Gradle in every of the above cases. The difference for smaller projects (Apache commons) may be smaller, but when it comes to large codebases, the advantage is closer to 40-50%.

However, incremental build times matter more when it comes to the edit-build-run development cycle:

Incremental Java compilation
Test caseSaker.buildGradle
Apache commons library7931641
Large multi-project ABI keeping11903541
Large multi-project ABI changing40626979
Large monolithic project12875879

No matter how you structure your codebase, the incremental compilation implementation for Java determines the sources to recompile in a fast and correct way. Saker.build is faster in all cases, providing a quicker feedback for your developers.

C/C++

Saker.build is a general build system, therefore supporting any kind of language for which the build tasks are implemented. We've added support for C/C++ compilation using the MSVC toolchain. As a starter, we measured the performance of how saker.build can manage the scheduling of the compilation tasks. For this, we compared the results to the Ninja build tool.

C/C++ builds
Test caseNinjaSaker.build
Clean build942210209
Incremental single change4686
Incremental every 3rd file change29583511

We can see that saker.build provides similar performance to Ninja. Some overhead is introduced as saker.build runs on the JVM, while Ninja is a native tool specialized on this use-case. Saker.build performs 8-18% slower in the above cases, however, we believe that the configureability and versatility of saker.build makes up for it.

Build clusters

Saker.build supports build clusters which can be used to spread out the build task workloads to different build machines. This feature is relevant when large codebases need to be built and the build tasks are highly parallelizable.

Building C/C++ sources are such a task, as the source files that need to be compiled can be passed to worker machines that perform the compilation. Utilizing multiple machines to execute the build can significantly shorten the time it takes.

For cluster comparison we measured the performance of saker.build against the IncrediBuild tool. The test case distributes 1000 source files and uses 2 worker machines to compile C++ sources.

Distributed compilation
Test caseSaker.buildIncrediBuild
Clean build149321213000
Incremental single change8037600
Incremental every 3rd file change5131375333

Saker.build performs both clean and incremental builds 30% faster than IncrediBuild when build clusters are in play.

Further reading

The above performance measurements have been take from the packages that are used to implement the associated build tasks. See the following articles about each comparions and how they've been conducted: