Add property kotlin.build.useIR to enable JVM IR in Kotlin build

Right now this is only supposed to be turned on locally (`./gradlew
-Pkotlin.build.useIR=true ...`), to be able to quickly try how JVM
IR-compiled Kotlin compiler works.
This commit is contained in:
Alexander Udalov
2020-06-30 20:24:00 +02:00
parent 9c36c74357
commit 5340cf5567
2 changed files with 6 additions and 0 deletions
+5
View File
@@ -193,6 +193,7 @@ if (!project.hasProperty("versions.kotlin-native")) {
val intellijUltimateEnabled by extra(project.kotlinBuildProperties.intellijUltimateEnabled)
val effectSystemEnabled by extra(project.getBooleanProperty("kotlin.compiler.effectSystemEnabled") ?: false)
val newInferenceEnabled by extra(project.getBooleanProperty("kotlin.compiler.newInferenceEnabled") ?: false)
val useJvmIrBackend by extra(project.getBooleanProperty("kotlin.build.useIR") ?: false)
val intellijSeparateSdks = project.getBooleanProperty("intellijSeparateSdks") ?: false
@@ -426,6 +427,10 @@ allprojects {
tasks.withType<org.jetbrains.kotlin.gradle.dsl.KotlinJvmCompile> {
kotlinOptions {
freeCompilerArgs = commonCompilerArgs + jvmCompilerArgs
if (useJvmIrBackend) {
useIR = true
}
}
}
+1
View File
@@ -5,6 +5,7 @@ defaultSnapshotVersion=1.4.255-SNAPSHOT
kotlin.compiler.effectSystemEnabled=true
kotlin.compiler.newInferenceEnabled=true
#kotlin.build.useIR=true
#maven.repository.mirror=http://repository.jetbrains.com/remote-repos/
#bootstrap.kotlin.repo=https://dl.bintray.com/kotlin/kotlin-dev
#bootstrap.kotlin.version=1.1.50-dev-1451