Some ballpark figures on compilation times with Ko...
# kotlin-native
n
Some ballpark figures on compilation times with Kotlin 1.3.70 on a Kotlin Native project ( https://gitlab.com/napperley/ncurses-hello ) targeting linuxX64, which uses a statically linked C library (ncurses): • Fresh Compile (from a clean build): 21s 648ms (around 10s faster than Kotlin 1.3.61) • Compile From Incremental Change (of one line): 5s 750ms (around 25s faster than Kotlin 1.3.61) Compilation was done on a laptop (ThinkPad T480) that uses a Intel i5-8250U 8th Gen (Kaby Lake) CPU (4 cores, 8 hyper threads), and a Samsung 860 Evo SSD.
👍 13
d
Great, this implies not only faster general compilation, but that incremental compilation is 'working at all' in Kotlin/Native 👏 Certainly in K/N 1.3.61 my iOS Framework compiles seemed to be full length, every time (particularly painful when only compiling a cross project K/MP library dependency for the sake of an Android parent project!).
n
Note that I did the incremental compilation test only twice with both results producing around the same number. So the results are probably not a fluke, although I will need to do the test two more times to confirm.
Below are the incremental compilation test results (after four runs): • 6s 275ms • 5s 344ms • 4s 974ms • 4s 199ms Average Incremental Compilation Time: 5s 198ms
Definitely looks like the Kotlin Native compiler supports incremental compilation simple smile , at least with the linuxX64 target. There may be some other targets supported for incremental compilation.
s
We don’t support incremental compilation :) The reason for these number is Gradle compiler daemon.
😞 2
n
Did look like incremental compilation, although you are right. Can easily throw the numbers off when the Gradle compiler daemon needs to warm up.
Regardless of which way a person looks at the numbers the compilation speed is a significant improvement compared to the previous Kotlin version. However there is still a long way to go to have compilation times that are short enough to make software prototyping using the Kotlin Native compiler, and Gradle feasible.
👍 2
s
Sure, we continue to work on making Native compiler faster :)
👍 4