Conversation
Beta as of Kotlin 2.4.20. Measured on :shared:linkDebugFrameworkIosSimulatorArm64 with a one-line source edit per run: link time drops from ~11.1s to ~7.9s mean (n=8/7), with tighter variance. Costs one slower priming link and ~22MB under shared/build/kotlin-native-ic-cache. Debug binaries only - release links are unaffected. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014VYXf6KbfXuDuHV4uy3id8
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Summary
Sets
kotlin.incremental.native=trueingradle.properties. This enables incremental compilation of klib artifacts — the klib→binary step of Kotlin/Native — which is Beta as of Kotlin 2.4.20 (Experimental since 1.9.20), and which JetBrains plan to enable by default in a future release.Measured locally on
:shared:linkDebugFrameworkIosSimulatorArm64(warm daemon, one small source edit before each run, per-task times from Gradle--profile, two interleaved off/on rounds):~28% off the link task, with tighter variance. The klib compile step (~2.5s) is unchanged, as expected.
Costs:
shared/build/kotlin-native-ic-cache/debugFramework, per binary, cleared bycleanKotlinNativeLinkgates the IC flags behind!optimized, so release/TestFlight links are unaffectedTest plan
./gradlew :shared:linkDebugFrameworkIosSimulatorArm64green with the flag setshared/build/kotlin-native-ic-cache/debugFramework, 22MB)🤖 Generated with Claude Code
https://claude.ai/code/session_014VYXf6KbfXuDuHV4uy3id8