This fixes failures in performance builds caused by the KT-MR-13291 "Update Gradle to 8.4"
doLast { } block here is necessary as soon as it should be run during the task execution, while without it is a configuration time. Performance builds invoke Gradle several times with different tasks and parameters. The change in the mentioned MR made one of the invocations remove the nativeReports.json file produced earlier.
Merge-request: KT-MR-13496
Merged-by: Pavel Punegov <Pavel.Punegov@jetbrains.com>
It's going to be deprecated in Gradle 8.3
There's currently no way to pass a `org.gradle.api.provider.Provider` to the JavaExec.systemProperty or Test.systemProperty. There's a workaround using `org.gradle.process.CommandLineArgumentProvider`, but I intentionally don't rework these calls as Gradle is going to allow passing providers to configure system properties: https://github.com/gradle/gradle/issues/12247#issuecomment-1568427242
^KTI-1473 In Progress
After bootstrap update and the change that added /usr subdir to
absoluteTargetToolchain
Merge-request: KT-MR-13212
Merged-by: Pavel Punegov <Pavel.Punegov@jetbrains.com>
Fix swiftc path in the performance infrastructure. It has a separate
plugin to regular native-build-tools.
This fixes failures caused by the 3aeca1956e.
See also MR-KT-12948
Merge-request: KT-MR-13130
Merged-by: Pavel Punegov <Pavel.Punegov@jetbrains.com>
This commit specializes the existing Kotlin/Native stdlib ArrayList into
two subclasses:
* ArrayList
* ArraySubList
This avoids repeatedly checking whether a basic ArrayList is created as a
sublist of another ArrayList.
In the iterators, checkForComodification is marked for inlining, since
this significantly improves iterations performance.
A number of benchmarks are added to the native ring benchmark suite, to
test whether the changed runtime type of ArrayList.subList(...) has an
impact.
Remove hack with including sources directories.
shared project directory was removed from native and merged with utils.
Also, remove native/utils inclusion. Bootstrap version is used instead.
The build script manually specifies which directories are parts of
which source sets. And it did that wrong: all directories were just
added to the nativeMain source set.
This was an incorrect configuration (matching expect and actual were
getting into the same source set), and K2 compiler was not really happy
with that.
This commit fixes the correspondence between source sets and source
directories in kotlin-native/performance/framework build script, thus
fixes the build for that benchmark with K2.
Those benchmarks are built with bootstrap KGP and snapshot compiler.
Currently the former is K1, while the latter is K2. As a result, the
build fails because K2 compiler needs -Xfragment-sources argument,
while K1 uses -Xcommon-sources. So KGP passes the latter, while the
compiler expects the former.
Fix this by forcing KGP to use K2 for benchmarks in performance/
This can be reverted once bootstrap is updated to 2.0.0.
Removed TODOs after updating to kotlin bootstrap version with konan.data.dir gradle property changes
Fixed warning of incorrect passing -Xkonan-data-dir arg in konanc from KGP and fixed setting konan-data-dir in SetupConfiguration#setupCommonOptionsForCaches
#KT-60660 Fixed
Merge-request: KT-MR-11299
Merged-by: Dmitrii Krasnov <Dmitrii.Krasnov@jetbrains.com>
3f3f6eb marks all cinterop-generated declarations with
@ExperimentalForeignApi. As a result, all usages of such declarations
have to opt-in explicitly. This commit adds those opt-ins to all
usages in the performance tests.
^KT-58362
Performance project could be opened as a separate project
in the IDEA using this wrapper. To work around any issues
with the build, it should be the same version as
in the Kotlin project.
Before this change `./gradlew help` (with native enabled)
Created immediately: 1322
Created during configuration: 1541
after this change:
Created immediately: 596
Created during configuration: 1509
To know more about configuration avoidance: https://docs.gradle.org/current/userguide/task_configuration_avoidance.html
Add more opt-ins in Samples, tests and Benchmarks.
This is a follow-up to KT-MR-9788
Merge-request: KT-MR-9997
Merged-by: Pavel Punegov <Pavel.Punegov@jetbrains.com>
Adds convention plugin instead of sources inclusion
inside the buildSrc, effectively reducing the amount
of the code to be compiled in buildSrc.
Merge-request: KT-MR-8898
* Replace it with KotlinCompilerVersion
* K/N version should be set now with `deployVersion`.
* Cleanup deprecated functions in older versions
of the Gradle plugin
* Cleanup tests for older versions of compiler downloader
Merge-request: KT-MR-8436
Merged-by: Pavel Punegov <Pavel.Punegov@jetbrains.com>
Move all the code to apply Kotlin bootstrap into settings script plugin
which does following:
- configures based either on the repo root 'local.properties' or on the
root project gradle properties or on the repo root 'gradle.properties'
current type of bootstrap
- automatically adds Kotlin bootstrap repository with
exclusive content, so bootstrap dependencies will not be by mistake
downloaded from other repository
- automatically forces all Kotlin plugins applied in the build to use
bootstrap version
This script should be applied only in project settings.gradle and then
it does all the configuration by itself.
The bootstrap advance to 1.8.20-dev-2904 broke the K/N performance
benchmark build, when built in non-Java8 environments.
Co-authored-by: Troels Lund <troels@google.com>
Merge-request: KOTLIN-MR-576
Merged-by: Pavel Punegov <pavel.punegov@jetbrains.com>
Revert two special entries
Use proper mavenCentral()
Remove remains of jcenter from kotlin-native/
Merge-request: KT-MR-7610
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com>
It looks like net.rubygrapefruit:native-platform:0.14 is not in
plugins.gradle.org repository anymore.
And it's not used anyway.
> Task :buildSrc:generateExternalPluginSpecBuilders FAILED
'''
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':buildSrc:generateExternalPluginSpecBuilders'.
> Could not resolve all files for configuration ':buildSrc:compileClasspath'.
> Could not find native-platform-0.14.jar (net.rubygrapefruit:native-platform:0.14).
Searched in the following locations:
https://cache-redirector.jetbrains.com/plugins.gradle.org/net/rubygrapefruit/native-platform/0.14/native-platform-0.14.jar
'''
Can be reproduced with
```gradle --refresh-dependencies -i tasks -Pkotlin.native.enabled=true```
KTI-986