Commit Graph

97074 Commits

Author SHA1 Message Date
Alexander Korepanov 48daf0befe [JS IR] Take into account file annotations for calculating symbol hashes
^KT-55367 Fixed
2022-12-20 16:04:14 +00:00
Alexander Korepanov 4136189114 [JS IR] Check all signatures of dependent file in IC graph
It is important to check all signatures, because signatures
 can be simultaneously moved between files and modified.
2022-12-20 16:04:14 +00:00
Igor Chevdar 04fcf25ae0 [K/N] Merged CachedLibraries.Dependency into DependenciesTracker 2022-12-20 14:24:55 +00:00
Igor Chevdar c1bc6682fa [K/N] Merged two ways of overriding llvm globals 2022-12-20 14:24:55 +00:00
Igor Chevdar 9732100764 [K/N][IR][codegen] Introduced DependenciesTracker 2022-12-20 14:24:54 +00:00
Igor Chevdar c88ac7cc86 [K/N][IR][codegen] Build per-file dependencies for caches 2022-12-20 14:24:54 +00:00
Igor Chevdar a058fcb628 [K/N][runtime] Do not export ImmutableBlob type info
It's not used by the native runtime
2022-12-20 14:24:54 +00:00
Gleb Lukianets 454e9a6379 [K/N] Fix infinite loop in ObjCExportScope
Merge-request: KT-MR-8024
Merged-by: Gleb Lukianets <Gleb.Lukianets@jetbrains.com>
2022-12-20 12:53:54 +00:00
Mikhail Glukhikh 7a7d93828e Fix MutableOrEmptyList implementation details 2022-12-20 11:04:28 +00:00
Mikhail Glukhikh 761a0f8248 K2: introduce & use (for annotation creation) smartPlus for lists 2022-12-20 11:04:27 +00:00
Mikhail Glukhikh f33f87e3d4 K2: drop unused qualifier in FirJavaTypeRef 2022-12-20 11:04:27 +00:00
Mikhail Glukhikh e9fbeb9be2 K2: use MutableOrEmptyList for context receivers on declaration site 2022-12-20 11:04:27 +00:00
Mikhail Glukhikh d20d63786b K2: use MutableOrEmptyList for type arguments 2022-12-20 11:04:26 +00:00
Mikhail Glukhikh a48610000d K2: introduce & use MutableOrEmptyList.EMPTY singleton 2022-12-20 11:04:26 +00:00
Mikhail Glukhikh ddc786364f K2: use MutableOrEmptyList for context receivers 2022-12-20 11:04:26 +00:00
Mikhail Glukhikh dff71a9602 K2: use MutableOrEmptyList for nonFatalDiagnostics 2022-12-20 11:04:25 +00:00
Mikhail Glukhikh 582b640bec K2: use MutableOrEmptyList for annotations storage in FIR elements 2022-12-20 11:04:25 +00:00
Mikhail Glukhikh be5394e211 Fix minor formatting issue in generated FIR tree 2022-12-20 11:04:24 +00:00
Pavel Kunyavskiy 1cf2f102a2 [K/N] Performance infra fixes 2022-12-20 09:07:20 +00:00
Pavel Kunyavskiy 9f5165dc97 [K/N] Update gradle in performance infra 2022-12-20 09:07:19 +00:00
Pavel Kunyavskiy 2767e95c99 [K/N] Performance infra migration tools 2022-12-20 09:07:19 +00:00
Pavel Punegov b9b2713a96 [K/N][perf] Rewrite UI part to kts 2022-12-20 09:07:18 +00:00
Pavel Punegov 315b59e0d6 [K/N][perf] Rewrite performance server's build
Rewrite to KTS and use JS-IR backend
2022-12-20 09:07:18 +00:00
Pavel Kunyavskiy 09b7c483dd [K/N] Switch to http basic auth in performance infra
^KT-52473
2022-12-20 09:07:17 +00:00
Bogdan Mukvich e97ecc13b0 Cleanup pre-push hook
KTI-673
2022-12-20 08:53:41 +00:00
Dmitriy Novozhilov d75160250d [FIR] Drop transformExtensionReceiver and transformDispatchReceiver from FirQualifiedAccess
After removal of `StoreReceiver` transformers those methods are not used
  anymore, so it's ok to remove them at all
2022-12-20 08:12:10 +00:00
Dmitriy Novozhilov 02e327277e [FIR] Report VAL_REASSIGNMENT on assign to non-local vals
In this commit reporting on member properties in init section of class
  is not supported (see KT-55528)

^KT-55493 Fixed
2022-12-20 08:12:09 +00:00
Dmitriy Novozhilov e87a064cdd [FIR] Report VARIABLE_EXPECTED on assign to this 2022-12-20 08:12:09 +00:00
Dmitriy Novozhilov 9ccbf8639d [FIR] Add dispatchReceiverType to FirAnonymousInitializer
This is needed to add ability to quickly find class to which initializer
  belongs
2022-12-20 08:12:09 +00:00
Dmitriy Novozhilov edd7468d5b [FIR] Get rid of StoreType transformer 2022-12-20 08:12:08 +00:00
Dmitriy Novozhilov 4ba92f66c0 [FIR] Get rid of TransformImplicitType transformer 2022-12-20 08:12:08 +00:00
Dmitriy Novozhilov f8ef55ad16 [FIR] Get rid of StoreNameReference and StoreCalleeReference
All usages of it are replaced with `replaceCalleeReference`
2022-12-20 08:12:08 +00:00
Dmitriy Novozhilov 3f8beb0b52 [FIR] Get rid of StoreReceiver
All usages of it are replaced with `replaceXXXReceiver`
2022-12-20 08:12:07 +00:00
Dmitriy Novozhilov d45ae59d33 [FIR] Add methods to replace dispatch and extension receivers 2022-12-20 08:12:07 +00:00
Dmitriy Novozhilov 4bddb27ca3 [FIR] Get rid of candidateSymbol in FirNamedReference
`candidateSymbol` has any reasonable meaning only for references with
  not completed candidate, so this property is moved from FirNamedReference
  to new node FirNamedReferenceWithCandidateSymbol, which has real
  implementation only in :resolve module (`FirNamedReferenceWithCandidate`)
2022-12-20 08:12:07 +00:00
Sergey Bogolepov 366edcfe3c [K/N] Drop obsolete static driver 2022-12-20 06:30:36 +00:00
Sergey Bogolepov 7706ad8cb3 [K/N] Enable dynamic and static output for dynamic driver 2022-12-20 06:30:36 +00:00
Yahor Berdnikau 2e5981eb94 Fix eager Kotlin/JVM task configuration on Gradle 7.3+
^KT-54836 Fixed
2022-12-19 21:00:12 +00:00
Sergej Jaskiewicz f8e6c59600 Add compatibility aliases for declarations moved from other packages
1539d7ef1a brought some package names in
sync with the directory layout. However, this broke some third-party
code that used classes from those packages.

The new compatibility aliases allow that code to continue to compile.
Deprecation warnings will be emitted, suggesting to replace the imported
packages with new ones.
2022-12-19 19:42:05 +00:00
Sergey Bogolepov f5fa8f2b83 [CODEOWNERS] K2NativeCompilerArguments.kt to native team 2022-12-19 17:41:48 +00:00
Abduqodiri Qurbonzoda fb31a29c39 [K/N] Fix stack overflow in regex when a quantifier is matched many times
Motivation:

Users often expect simple patterns, like `[a]+` or `[^a]+`, to work fast
and without any problems, even with long strings.
Char class from the first pattern matches only 'a' and gets wrapped into
LeafQuantifierSet, and works fine with long strings indeed.
Char class from the second pattern, however, matches any character
except 'a', including supplementary code points. So, the number of chars
it consumes is not known beforehand. There is no optimization for such
char classes, and if they are matched multiple times, the stack memory
gets exhausted.

Modification:

Introduce FixedLengthQuantifierSet node.
The node represents quantifier over constructs that consume a fixed
amount of characters for a given string and index. Such constructs don't
need backtracking to find a different match. Thus, it is possible for
the node to avoid recursion when matching multiple times.

Result:

Fixes KT-46211, KT-35508 and probably KT-39789. Reproducer for the
latter issue is no longer available, but error stacktrace resembles
those of the other issues.
2022-12-19 16:40:51 +00:00
Abduqodiri Qurbonzoda 6e50bbee3b [K/N] Set mayContainSupplCodepoints flag only when alt is updated
Motivation:

Calling AbstractCharClass.setNegative always leads to
mayContainSupplCodepoints being `true`, even when `alt` is already
equal to the argument. Given that CharClass always calls setNegative
with its constructor parameter - `negative`, mayContainSupplCodepoints
always gets set. i.e. `[a]` will have mayContainSupplCodepoints set.
mayContainSupplCodepoints affects what node (RangeSet or SupplementaryRangeSet)
wraps this char class. See Pattern.processRangeSet.
RangeSet is better optimized and avoids recursion when it is quantified.

Modification:

Set `mayContainSupplCodepoints` flag only when `alt` is updated.
When `alt` is updated, this char class gets inverted, hence now may
contain supplementary code points.
Otherwise, content of this char class does not change, i.e. no new
supplementary code points is added.

Result:

Fixes KT-46211.
2022-12-19 16:40:51 +00:00
Abduqodiri Qurbonzoda d7f166eda3 [K/N] Remove unused SupplementaryCharSet in regex
Motivation:

The node was never used. Perhaps, it was copied from apache harmony
but ultimately, despite possible performance impact, SequenceSet was
used instead. See Pattern.processCharSet and AbstractSet.first.
The performance impact wouldn't be noticeable anyway.

Modification:

Keeping unused code in project is not a good practice, so get rid of it.

Result:

Less code to maintain.
2022-12-19 16:40:50 +00:00
Yahor Berdnikau dc4ddebe2f Change compiler/daemon owner to Kotlin Build Tools 2022-12-19 15:58:05 +00:00
Nikolay Krasko 74dd31d00a Call additional publishToMavenLocal in maven build scripts and enable info
'publish' do not publish all artifacts to maven local and maven
fails because of it as it can't find dependencies.

KTI-729
2022-12-19 14:40:52 +00:00
Mads Ager d87ed38cbf [Kotlin/Native] Avoid jni overhead when optimizing bitcode.
The phase to eliminate redundant function prologue safepoints
was written in Kotlin which meant that it was performing a lot
of jni calls. Moving the simple optimization to C code speeds
things up dramatically.

On a large project this reduces the time for this phase from
11.8 seconds to 1.4 seconds.
2022-12-19 11:13:24 +00:00
Evgeniy.Zhelenskiy 53b98503ed [IR] Support MFVC properties without backing fields
Signed-off-by: Evgeniy.Zhelenskiy <Evgeniy.Zhelenskiy@jetbrains.com>

#KT-1179
2022-12-18 22:11:23 +00:00
Sergey.Shanshin 5e01669e23 Added saving SerialInfo annotations to the enum class
Resolves Kotlin/kotlinx.serialization#2121

Merge-request: KT-MR-8019
Merged-by: Sergey Shanshin <Sergey.Shanshin@jetbrains.com>
2022-12-18 19:22:16 +00:00
Ilya Chernikov 88d140527f Scripting: optimize check for allowed scripts on init 2022-12-18 16:49:41 +00:00
Vyacheslav Gerasimov 9ca24b6965 Build: Remove parcelize tests from compilerPluginTest root task 2022-12-18 13:51:23 +01:00