Alexander Dudinsky
86d8ef7e45
Migration HierarchicalMppIT tests to new DSL
...
^KT-50912
2022-03-31 13:24:33 +00:00
Artem Kobzar
c56f06f942
test: change function id in implicit cast test to prevent name clash.
2022-03-31 09:59:46 +00:00
Sergej Jaskiewicz
f7933dc9f4
[JS IR] Verify that we don't generate Unit_getInstance() statements
...
See: KT-51127
2022-03-31 09:46:51 +00:00
Alexander Shabalin
421ad77740
[K/N] Simplify ObjectFactory ^KT-51436
...
Merge-request: KT-MR-5958
Merged-by: Alexander Shabalin <Alexander.Shabalin@jetbrains.com >
2022-03-31 09:43:47 +00:00
Pavel Kunyavskiy
4873f18067
[K/N] Enable definitely not null cast test for native
2022-03-31 09:02:14 +00:00
Elena Lepilkina
cb0acaa469
[K/N][perf] Small fixes for release builds and some type of benchmarks reports
2022-03-31 09:00:46 +00:00
Dmitriy Dolovov
053ddb51ce
[Gradle, Native] Propagate -Xpartial-linkage flag to compiler invocations that build static cache for 3rd-party and user libs
...
^KT-51441
2022-03-30 20:31:31 +03:00
Ilmir Usmanov
7579be6c68
Generate CHECKCAST after ACONST_NULL in coroutines
...
If we do not do this, the state-machine builder will not know the type
of the ACONST_NULL, defaulting to Object, leading to VerifyError.
Alternatively, we could use LVT to deduce the type, but getting types
from LVT is something I got rid of long time ago, and I have no desire
to return it back.
Generating CHECKCAST hints the state-machine builder the type of the
variable avoiding the issue of VerifyError. However, this CHECKCAST
replaces StrictBasicValue.NULL_VALUE with BasicValue in
OptimizationBasicInterpreter. To preserve optimization on not-spilling
known nulls, introduce BasicValues, which represent typed nulls and
create BasicInterpreter, which is aware of them. This way we have the
best of two worlds - we do not spill known nulls, and we know the type
of ACONST_NULL.
#KT-51718 Fixed
2022-03-30 14:27:29 +00:00
Sergey Bogolepov
9b103b35cd
[K/N] Replace destinationDir with destinationDirectory.
...
Breaking change was introduced in e9498c8 .
2022-03-30 12:17:22 +03:00
Ilya Chernikov
5d6e2b57a7
Sort sealed class inheritors to ensure reproducible builds with IC
...
without this sorting the inheritors field in the metadata may depend on
whether some inheritors are compiled in the IC round or not.
2022-03-30 08:35:30 +00:00
Ilya Chernikov
53bc593062
Fix interpreter tests after changing offset calculation
2022-03-30 08:35:21 +00:00
Ilya Chernikov
738c1f34df
FIR2IR: Fix offsets calculation for qualified expressions
2022-03-30 08:35:13 +00:00
Ilya Chernikov
a65c102469
FIR LT: fix modality for default accessors in LT converter
2022-03-30 08:35:06 +00:00
Ilya Chernikov
b3f9e7d361
FIR LT: "fix" tree compare tests by ignoring diagnostic in error types
2022-03-30 08:34:59 +00:00
Ilya Chernikov
c4a29651b0
FIR IC: fix test with behavior different from non-tight cycle variants
2022-03-30 08:34:51 +00:00
Ilya Chernikov
f2ddac3ece
IC: Adopt IC compilation for case then runCompiler adds some dirty files
...
as it is the case for Fir IC compilation.
2022-03-30 08:34:44 +00:00
Ilya Chernikov
27a3c77174
Temporary restore generation state and related PSI-based APIs
...
Changes required on IDE plugin side before applying API changes.
2022-03-30 08:34:36 +00:00
Ilya Chernikov
03cbfea737
FIR LT: Introduce source file abstraction, carry it from parsing to IR
...
along with source lines mapping, allows to "emulate" usage of the
PSI files which allows to extract source file and line mapping info
on every stage from source element.
It makes sense to use this mapping for the error reporting too.
2022-03-30 08:34:30 +00:00
Ilya Chernikov
bd60d4b2a6
FIR LT: Add box inline tests for FIR + LT (failing on SMAP so far)
2022-03-30 08:34:21 +00:00
Ilya Chernikov
ae10346d75
Refactor FIR diagnostics: cleanup and extract position finder
...
for reusing the latter in the inliner for LT-based sources
2022-03-30 08:34:13 +00:00
Ilya Chernikov
25e9de286d
Test infra: adapt blackbox test runner to work with non-psi sources
2022-03-30 08:34:06 +00:00
Ilya Chernikov
2044754628
Backend: remove psi files from generation state
...
pass them explicitly to all destinations. This is a step in attempt to
abstract dependencies on PSI in the GenerationState and related places.
2022-03-30 08:33:59 +00:00
Ilya Chernikov
da41fddabb
Backend: remove codegen factory from generation state
...
use it explicitly. This is a step in attempt to abstract dependencies
on PSI in the GenerationState and related places.
2022-03-30 08:33:51 +00:00
Ilya Chernikov
018782f0c7
FIR CLI: use VFS for LT files loading
...
may improve performance in some cases and is consistent with handling
of PSI files
2022-03-30 08:33:43 +00:00
Ilya Chernikov
506152020d
FIR: fix LT conversion of imports with backticks
2022-03-30 08:33:35 +00:00
Ilya Chernikov
a08e70ae5c
FIR CLI: fix java sources search scope usage
2022-03-30 08:33:27 +00:00
Ilya Chernikov
0df3fde37f
FIR: implement computeOrigin for IR without accessing sources
...
fixes LT compilation too
2022-03-30 08:33:18 +00:00
Ilya Chernikov
973273c6c6
FIR CLI: count lines/files and report events to perfman
2022-03-30 08:33:11 +00:00
Ilya Chernikov
090a451902
FIR: implement proper exit on errors in new cli pipeline
2022-03-30 08:33:03 +00:00
Ilya Chernikov
f89765eb33
Make JDK classpath roots configuration explicit...
...
instead of relying on the "configuration files" parameter.
(in the process of migration from KotlinCoreEnvironment).
2022-03-30 08:32:56 +00:00
Ilya Chernikov
9d2cadc908
[minor] scripting fixes in obsolete and test code...
...
relax acceptedAnnotations extraction rules for obsolete script template
handling code - the previous variant was failing on the typealias
comparison
also reduce warnings and possible exceptions on some test execution
paths
2022-03-30 08:32:48 +00:00
Ilya Chernikov
806bf8a735
IR [minor]: do not assume that ktfile is always accessible
2022-03-30 08:32:40 +00:00
Ilya Chernikov
b27a223b98
IR: use jvm name annotations for package class naming for non-psi cases
2022-03-30 08:32:32 +00:00
Ilya Chernikov
5e007f9179
IR: fix FileClassInfo generation from source-based entry
...
assuming that it's name contains path, symmetrical to the PSI variant
2022-03-30 08:32:24 +00:00
Ilya Chernikov
5abdf93d3b
IC: Add IC test with fix on rename file with only class inside
...
"fails" on JS and JPS tests - the IC logic there is less precise.
2022-03-30 08:32:17 +00:00
Ilya Chernikov
3220900abe
FIR: add tests for IC with LT and new CLI pipeline
2022-03-30 08:32:10 +00:00
Ilya Chernikov
a239f02a30
Add cli argumens for FIR "tight" IC and LightTree usage
2022-03-30 08:32:03 +00:00
Ilya Chernikov
9e32188938
FIR LT: add syntax error reporting to LT2Fir
...
use it in the new pipeline
2022-03-30 08:31:56 +00:00
Ilya Chernikov
2689ebf455
FIR: fix lookup tracking in conflicts checker for LT
...
since it relies on the correct context declaration
2022-03-30 08:31:47 +00:00
Ilya Chernikov
0446a21b46
FIR IC: remove unnecessary lookup tracking in retrun type calc
2022-03-30 08:31:40 +00:00
Ilya Chernikov
2aba465494
FIR IC: provide file sources to lookup where possible
...
because detecting file source by element source is possible for LT
only in some limited cases.
2022-03-30 08:31:33 +00:00
Ilya Chernikov
11d6dccf51
FIR IC: do not record lookup on const - builtin types are not recorded
2022-03-30 08:31:26 +00:00
Ilya Chernikov
a8594e9ce8
Codegen: register i/o File instead of PSI for module mapping...
...
because there are no PSI files in FIR + LT, so missing mapping hurts IC
2022-03-30 08:31:18 +00:00
Ilya Chernikov
275135a1b2
FIR: extend cli pipeline with incremental compilation logic
...
use it in the IncrementalCompilationRunner
2022-03-30 08:31:10 +00:00
Ilya Chernikov
6b61488099
Implement IC caches changes detection logic over frontend metadata
2022-03-30 08:31:02 +00:00
Ilya Chernikov
3ca4fe5f9e
Refactor metadata serialization for using after frontend
...
for "tight" IC cycle
2022-03-30 08:30:54 +00:00
Ilya Chernikov
5cca01a7d2
IR: remove unnecessary reliance on the PSI in inliner
2022-03-30 08:30:46 +00:00
Ilya Chernikov
17bbaf27ea
Fix when expression with binary expression conversion in fir2ir for LT
2022-03-30 08:30:38 +00:00
Ilya Chernikov
2d7af0ce72
Fir2Ir: fix conversion for non-PSI source elements
2022-03-30 08:30:30 +00:00
Ilya Chernikov
5818f0786a
Fix for loop variable detection in fir2ir for LT case
2022-03-30 08:30:24 +00:00