I have been using the native extension for Gradle inside an actual project
for a couple months. The biggest limitation I'm seeing is the inflexibility
of the compile task when compared to other build tool in the industry. The
--parallel switch works great for concurrent execution of tasks. When it
comes to the compile task, all files are compiled one after the other. The
native compiler are quite slow especially when it comes to compiling C++
templates. As a comparison, my dev box is mostly idle while compiling with
Gradle as oppose to a fairly important load when compiling Visual Studio.

The main use case of this feature is the speed up of the compilation
process for the native extension. To highlight how this feature is
important, I will point out that some company where I previously worked at
use system like Incredibuild to perform parallel distributed compilation.
Even with such system, the compilation was still pretty time consuming. In
it's present form, Gradle is not suitable in term of speed for those
scenario. I talked to a couple Gradleware engineers during Gradle Summit
2014 and some insane features are planed to address this problem.
Unfortunately, a quicker solution is needed in order to speed up the
adoption of Gradle as a native build tool. I also want this feature to be
in accordance to the long term Gradle road map.

I would like to start the discussion for contributing this into Gradle.
>From my limiting knowledge of Gradle here are a couple open issues I have.
I hope some brilliant minds from Gradleware can share there wisdom on where
to move forward with this feature.

Open issues
 - What is the current road map for such feature.
   - This could also be used in any language which require compilation such
as Java.
   - Allowing custom implementation of this feature could allow a company
to plug Gradle in there current Incredibuild infrastructure or any other
distributed framework.
 - How this feature fits with the --parallel flag?
 - How the number of parallel compilation unit will be configure aka number
of files that can be compiled in parallel?
 - Should this feature be always on by default or have a toggle flag?

Reply via email to