Commit Graph

1826 Commits

Author SHA1 Message Date
Dmitrii Gridin b6d373d8e5 Update copyright to 2024 2024-01-05 13:43:17 +00:00
Aleksei.Cherepanov 5150812838 [IC] Add test for potential sam change in kotlin-java interop
JPS tests were fixed on IJ side during implementation of JPS on graph

Relates to KT-21534
2023-12-21 16:09:14 +00:00
Aleksei.Cherepanov f7d93029ff [JPS] Stop depending on a specific implementation of the compiler in some JPS tests
Change base class of AbstractIncrementalCacheVersionChangedTest to abstract one, not related to any specific implementation of compiler because these tests check JPS logic and should not be affected by compiler implementation

^KT-64445 Fixed
2023-12-21 14:21:35 +00:00
Aleksei.Cherepanov 3e41faf91f Add KotlinBuilder 'dumb mode' flag
A new system property was added to enable a 'dumb mode' for KotlinBuilder.
In this mode it is possible to disable IC caches, but don't request rebuild
And all IC trackers will still work

^KT-64305 Fixed


Merge-request: KT-MR-13524
Merged-by: Aleksei Cherepanov <aleksei.cherepanov@jetbrains.com>
2023-12-15 00:20:54 +00:00
Ilya Chernikov ed820d6b57 K2 IC: fix lookup recording for a "red" companion object
#KT-63665 fixed
2023-12-13 13:40:44 +00:00
Ilya Chernikov 6dfcc927f4 IC tests: make exceptions from compiler more visible in tests
otherwise they are easily swallowed by the reporting logic.
This commit was needed to ensure that the problem described in
KT-63665 is reproducible in IC test
But some JS IC logic relies on handling compiler exceptions as a signal
for scope expansions, and the newly introduced exception logging
broke a few tests. To mitigate it, the directive was introduced
to disable exception logging for particular test.
2023-12-13 13:40:44 +00:00
Nataliya.Valtman 4294c7bab7 Add limitation for changed files list for JPS build report
#KT-63549
2023-12-04 18:19:15 +00:00
Ilya Goncharov 08e3cb300a [JS] Migrate tests onto IR compiler with outputDir API instead of outputFile
^KT-61117 fixed
2023-11-29 11:21:56 +00:00
Aleksei.Cherepanov c002af6365 Make plugin classpath serialization path agnostic
This is needed for correct usage of portable caches

^KT-63799 Fixed
2023-11-25 10:46:49 +00:00
Aleksei.Cherepanov ea85b30f88 Make CompilerSettings open to add listeners on IJ side
Workspace Model will return a copy of CompilerSettings instead of reference to the original one. Thats why we need to add listeners on it on IJ side

Relates to KTIJ-24647
2023-11-24 22:58:13 +00:00
Nataliya.Valtman 6bbf5b83c8 Add compiler metrics to JPS build report
#KT-63549: Fixed
2023-11-22 11:30:08 +00:00
Nataliya.Valtman fff089eba8 Fix ClassCastException in JPS statistics ad update log messages
#KT-63594 Fixed
2023-11-21 15:28:27 +00:00
Aleksei.Cherepanov 079343c093 Return the default value if an illegal argument is passed..
..to the TargetPlatform during the import process.

#KTIJ-27718 Fixed


Merge-request: KT-MR-13072
Merged-by: Aleksei Cherepanov <aleksei.cherepanov@jetbrains.com>
2023-11-17 14:46:35 +00:00
Aleksei.Cherepanov 6f3204da0a Stop using IJ's maps in graph implementation of JPS 2023-11-16 08:53:13 +00:00
Aleksei.Cherepanov 431f77ddb4 Disable mappings dump creating for JPS graph
Disable mappings dump for tests when JPS graph implementation is enabled
2023-11-07 13:49:43 +00:00
Evgenii Mazhukin 20af98c776 [Tests] Re-enable K1 IC tests for expect-actual
^KT-60831 fixed
^KT-60831 next step KT-63183


Merge-request: KT-MR-12855
Merged-by: Evgenii Mazhukin <evgenii.mazhukin@jetbrains.com>
2023-11-06 19:46:43 +00:00
Kirill Rakhman ef78d4b95a [FIR] Fix deserialization of generic context receivers
We need to pass the local deserialization context so that generic
type parameters can be referenced.

#KT-62607 Fixed
2023-10-27 11:35:22 +00:00
Alexander.Likhachev b460c06907 [BT] Add support for in-process incremental compilation
#KT-61865 Fixed
2023-10-23 13:04:17 +00:00
Alexander Udalov 6219f7fc0d JVM IR: fix detection of enum entries in the same module
Use the new `IrClass.hasEnumEntries` flag added in the previous commit.

 #KT-61208 Fixed
2023-10-16 20:22:20 +00:00
Ilya Goncharov a79324037d [JS] Fix JPS artifacts cordinates 2023-10-16 13:34:37 +00:00
Aleksei.Cherepanov a32c65e4e1 Convert absolute to relative pluginsClasspath..
..to avoid recompilation on build with portable caches

#KT-62256 Fixed


Merge-request: KT-MR-12377
Merged-by: Aleksei Cherepanov <aleksei.cherepanov@jetbrains.com>
2023-10-05 10:25:53 +00:00
Dmitriy Dolovov 78a962f6d2 [KLIB] Deprecate -Xexpect-actual-linker CLI argument
This argument has been finally superseded by `-Xmetadata-klib`.

^KT-61136
2023-10-02 16:21:17 +00:00
Dmitriy Dolovov 848c88b1a5 [KLIB] Lift up -Xmetadata-klib CLI key from Native to Common args
This is a precondition for obsoleting and finally removing
`-Xexpect-actual-linker` CLI key, which became useless since
the removal of ExpectActualTable.

^KT-61136
2023-09-20 22:26:36 +00:00
Mikhail Glukhikh 4133988d62 LV 2.0: temporarily mute 4 incremental MPP tests (KT-60831) 2023-09-19 15:46:29 +00:00
Mikhail Glukhikh e4309c3318 LV 2.0: mute testCircularDependenciesWrongInternalFromTests (KT-61716) 2023-09-19 15:46:29 +00:00
Mikhail Glukhikh 6314183a55 LV 2.0: update diagnostics around visibility checks in JPS tests 2023-09-19 15:46:28 +00:00
Ilya Chernikov 129c1b4f92 IC: temporarily mute lookup tracker test on K2
Test most likely fails due to the missing precise java tracker
See #KT-57147 and #KT-60736 for details
2023-09-19 15:46:28 +00:00
Ilya Chernikov 60603de042 LV20: fix JPS testdata where the error reporting slightly changed 2023-09-19 15:46:27 +00:00
Mikhail Glukhikh ab2053df4b Use K2/PSI in lookup tracker tests, fix test data in accordance with 2.0
#KT-60736 Submitted
2023-09-19 15:46:27 +00:00
Mikhail Glukhikh 2a8b655294 Update tests after switching to LV 2.0
Related to KT-59171
2023-09-19 15:46:27 +00:00
Alexander.Likhachev 357d12fc8e [Build] Move JUnit dependencies into the version catalog
The `kotlin-test` dependencies are left untouched as changing them affects publications, thus these versions are independent from the used inside our build
#KTI-1349 In Progress
2023-09-06 22:47:33 +00:00
Aleksei.Cherepanov 498d2c0bd7 [Workspace model] Add targetPlatform serialization for Kotlin Facet Settings
This commit is needed for adding targetPlatform serialization for Kotlin Facet Settings Workspace Model on IJ side

Merge-request: KT-MR-11953
Merged-by: Aleksei Cherepanov <aleksei.cherepanov@jetbrains.com>
2023-08-30 15:35:12 +00:00
Aleksei.Cherepanov 68af705664 Add import tracker
This tracker reports import directives to IJ's JPS to track changes and detectwehen it is needed to adjust compilation scope.

#KT-44835 Fixed
2023-08-30 12:42:39 +00:00
Aleksei.Cherepanov b27aef2c61 Add test
#KT-44835 In Progress
2023-08-30 12:42:39 +00:00
Mikhail Glukhikh c4fbbe7338 Fix old JS BE tests in MultiplatformJpsTestWithGenerated by using K1 2023-08-25 08:57:53 +00:00
Mikhail Glukhikh 64d8df0a61 Use language version 1.9 in JsProtoComparisonTestGenerated 2023-08-25 08:57:53 +00:00
Aleksei.Cherepanov feeddc4ea3 Extract interface from KotinFacetSettings 2023-08-22 14:02:33 +00:00
Kirill Rakhman 43180597fe [FIR] Fix generic sam conversion in call completion
#KT-60903 Fixed
2023-08-21 10:35:42 +00:00
Hung Nguyen 894ba9ab80 [IC] Relocatable IC caches for projects with custom buildDir
IC caches often contain file paths. To make them relocatable, we need
to convert these file paths into relative paths, relative to a base
directory.
  - If the file paths are source files, we can use the root project
    directory as base.
  - If the file paths are class files, we should use the classes
    directory as base (before this commit, we used the root project
    directory in both cases, that's why we hit KT-58547).

The key changes in this commit include:
  - RelocatableFileToPathConverter: converts paths to relative paths
  - IncrementalCompilationContext: contains 2 different path converters,
    one for source files and one for class files
  - SourceToOutputFilesMap: maps source files to class files using the
    above path converters
  - IncrementalCompilerRunner: creates the path converters based on file
    locations

Test: RelocatableFileToPathConverterTest unit test
      SourceToOutputFilesMapTest unit test
      BuildCacheRelocationIT.testCustomBuildDirectory integration test
^KT-58547 Fixed
2023-08-16 13:40:19 +00:00
Ilya Gorbunov 69a87efdd9 js.tests: change paths to kotlin-stdlib-js.klib
Change the expected klib name of stdlib

KT-56106
2023-08-03 14:47:20 +00:00
Nataliya.Valtman fb04356829 Add JPS iteration metric
#KT-58026 In progress


Co-authored-by: Nataliya Valtman <Nataliya.Valtman@jetbrains.com>


Merge-request: KT-MR-11365
Merged-by: Aleksei Cherepanov <aleksei.cherepanov@jetbrains.com>
2023-07-31 09:15:28 +00:00
Aleksei.Cherepanov 6ac76aa3e9 Fix passing K2 language version to K1 multimodule tests
After splitting K1 and K2 tests some multimodule tests in K1 configuration were still running with 2.0 language version. The reason was in misconfiguration of complex multimodule projects - they don't apply override of compiler arguments. This fix added such arguments update.

#KT-60589 Fixed
2023-07-27 14:15:49 +00:00
Aleksei.Cherepanov f6963d04e9 Run K1 configuration on TC with languageVersion="1.9"
KotlinVersion is overrided on TC, so we need to rely on LanguageVersion

#KT-60589 Fixed
2023-07-27 14:15:49 +00:00
Nataliya.Valtman ed2dd4b2ae Split Gradle and JPS metrics
#KT-58026 In progress
2023-07-27 11:18:54 +00:00
Mikhail Glukhikh 834bd1a71c K1/K2: split incremental JPS tests properly (relates to KT-59171) 2023-07-20 10:57:45 +00:00
Ilya Goncharov 8c014baa28 [JS] Fix JPS tests with js part 2023-06-29 14:25:45 +00:00
Ilya Goncharov a0f86d8dd6 [JS] Remove JS legacy lookup tracker tests 2023-06-29 14:25:45 +00:00
Troels Bjerre Lund 111bb461a9 CLI: Change kotlin reflection to java reflection
The command line argument parser is using between 0.25s and 0.5s
(depending on platform) on finding annotated properties. This fix
replaces the slow kotlin reflection with java reflection, which is an
order of magnitude faster.

 #KT-58183 Fixed
2023-06-27 08:34:40 +00:00
Alexander.Likhachev 1005d0244a [BT] Move KotlinLogger to the bt-api package
#KT-57398 In Progress
2023-06-23 12:34:23 +00:00
Alexander Udalov 60016d3e5b Remove obsolete compiler flag -Xuse-ir 2023-05-30 14:46:09 +00:00