Pavel Punegov
d5bdc7cf8e
[K/N][test] Fix sample that uses watchos_x86 target
...
Simply replace it with watchos_x64
2023-06-15 14:07:42 +00:00
Dmitriy Dolovov
72525a22a6
[KLIB] Extract "ir_provider" manifest property name as a const val
2023-06-15 11:07:30 +00:00
Ivan Kylchik
0021a5f655
[K2] Save inlined java field into special InlineConstTracker
2023-06-14 19:02:39 +00:00
Abduqodiri Qurbonzoda
193aa0f935
Align the Boolean.hashCode() value across platforms
...
Boolean.hashCode() should return 1231/1237 for true/false correspondingly.
As a part of efforts to stabilize Native stdlib.
2023-06-14 08:19:46 +00:00
Alexander Shabalin
da1fde2477
[K/N] Enable custom allocator by default ^KT-55364
2023-06-13 10:22:04 +00:00
Dmitriy Novozhilov
ba41e8ec38
[IR] Use common expect/actual matching algorithm in IR actualizer
...
^KT-58578 Fixed
2023-06-10 07:33:29 +00:00
Alexander Shabalin
7815eec7c1
[K/N] Rework GC switches with better naming
...
Additionally, deprecate -Xgc in favour of a new binary option "gc".
This will allow setting gc right in gradle.properties
Merge-request: KT-MR-10498
Merged-by: Alexander Shabalin <Alexander.Shabalin@jetbrains.com >
2023-06-09 12:04:19 +00:00
Pavel Kunyavskiy
456783436c
[K/N] Fix cast to NativePtr mis-compilation
...
^KT-59022
2023-06-08 10:40:29 +00:00
Svyatoslav Scherbina
1bf3d55bdf
Native: add detachObjCObject internal function for Obj-C objects
...
For a Kotlin wrapper of an Objective-C object, this functions zeroes
and releases the strong reference from the Kotlin wrapper to the
Objective-C object.
Usually, such a release happens only when the Kotlin wrapper is GCed.
So using this function can help that happen sooner.
^KT-59134
2023-06-07 11:57:54 +00:00
Igor Chevdar
74a97ba730
[K/N][tests] Fixed a filecheck test
2023-06-07 05:22:49 +00:00
cristiangarcia
46d113605b
Adopt configuration-avoidance where possible
...
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
2023-06-06 14:27:42 +00:00
Vladimir Sukharev
37adc99b9a
[K/N] Don't pass -language_version to the second stage of new test system.
...
^KT-56182
Merge-request: KT-MR-10414
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-06-05 17:59:16 +00:00
Pavel Kunyavskiy
f2520a9cb7
[K/N] Rework is checks and as casts codegeneration
...
^KT-58707
^KT-59022
2023-06-05 08:56:17 +00:00
Ivan Kylchik
b9856320cf
[IR] Rename fqName to packageFqName for IrPackageFragment
2023-06-02 16:38:04 +00:00
Alexander Shabalin
aea8bac7d2
[K/N] Do not compile for deprecated targets and legacy MM
...
^KT-56533
^KT-58853
2023-05-30 16:44:58 +00:00
Vladimir Sukharev
5bf51318eb
[K2/N] Exit compilation on errors at first stage
...
^KT-56855
Merge-request: KT-MR-10344
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-29 10:38:28 +00:00
Igor Chevdar
d9b0f2a75c
[K/N] Refactored RedundantCoercionsCleaner
...
#KT-58654 Fixed
2023-05-29 06:13:09 +00:00
Igor Chevdar
1ae0350ca5
[K/N][tests] Added some file-check tests on KT-58654
2023-05-29 06:13:09 +00:00
Vladimir Sukharev
1b1cfd45a0
[K2/N] Turn off IR verification for failed test interop_objc_smoke
...
This reverts commit 62901e22ec .
^KT-57716
Merge-request: KT-MR-10351
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-26 14:11:16 +00:00
Sergey Bogolepov
89be94f123
[K/N] Fix KT-58839
...
Do not export extensions of classes that are
hidden from the generated Objective-C API.
Merge-request: KT-MR-10330
Merged-by: Sergey Bogolepov <sergey.bogolepov@jetbrains.com >
2023-05-25 15:17:18 +00:00
Vladimir Sukharev
74c57e6057
[K2/N] Compile to native binary in two stages
...
^KT-56855 Fixed
Merge-request: KT-MR-10219
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-24 13:07:12 +00:00
Vladimir Sukharev
62901e22ec
[K2/N] Turn on IR verification for passed tests
...
^KT-57716 Fixed
Merge-request: KT-MR-10300
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-24 12:23:00 +00:00
Vladimir Sukharev
fde8909e6f
[K2/N] IntegerLiteralType coercion only to unsigned integer types
...
^KT-57484 Fixed
Merge-request: KT-MR-10270
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-24 07:56:14 +00:00
Nikolay Lunyak
00e8dc1c39
[FIR] KT-58444: Don't run IR generation when compiling native shared
...
Normally during metadata compilation we use
`K2MetadataCompiler` and it serializes
metadata to klibs without generating IR.
Native shared compilation uses the K2Native
compiler, which generates klibs based on both
the fir and fir2ir information.
It would be nice to reuse `K2MetadataCompiler`
for native shared, but currently it has no
support for the commonizer, and also reads
the stdlib metadata from a jar instead of a
klib, and there's no simple idiomatic way
to pass the `distribution.klib` value down
to `KLibResolverHelper` (native compilation
has some commonized dependencies, and they
explicitly depend on `stdlib`, so we must
resolve it this way or strip it away to be
able to use the metadata jar instead). There
may be other issues, I only digged a bit.
Instead, this change modifies the K2Native
in such a way that it can generate klibs
with metadata without fir2ir info.
Note that this change does not fix KT-58139,
because KT-58139 fails due to performing the
constants evaluation directly during the
metadata serialization when the needed info
does (and, as I was told, should) not exist
(namely, valid property initializers).
^KT-58444 Fixed
2023-05-23 15:59:41 +00:00
Igor Chevdar
55632f5df2
[K/N][runtime] Used internal isInstance
2023-05-22 12:49:58 +00:00
cristiangarcia
d32d5346a2
Fix gradle deprecations in Kotlin Native
...
Merge-request: KT-MR-10267
Merged-by: Cristian Garcia <Cristian.Garcia-Marin@jetbrains.com >
2023-05-22 12:39:57 +00:00
Vladimir Sukharev
4705207263
[K2/N] Fix lost diagnostics
...
^KT-58065
Merge-request: KT-MR-10264
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-22 09:18:04 +00:00
Vladimir Sukharev
363c56e226
[K2/N] Export C adapters for non-root packages
...
^KT-56182
Merge-request: KT-MR-10160
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-19 11:40:59 +00:00
Sergey Bogolepov
c57c34525f
[K/N] KT-58562: Implement frontend checkers for HiddenFromObjC on classes
2023-05-19 11:33:17 +00:00
Vladimir Sukharev
6a8981372b
[K2/N] Read KDoc strings from LightTree nodes
...
^KT-56090
Merge-request: KT-MR-9613
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-17 08:12:39 +00:00
Nikolay Lunyak
c57d9097c2
[FIR] Add the syntax tree suffix to buildResolveAndCheckFir
2023-05-16 12:11:47 +00:00
Nikolay Lunyak
90651c5851
[FIR] KT-58065: Support LT in K2Native
2023-05-16 12:11:46 +00:00
Vladimir Sukharev
bbe1e708f9
[K2/N] Rewrite mpp tests from old native infra to new
...
^KT-58543
Merge-request: KT-MR-10065
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-16 08:41:39 +00:00
Kirill Rakhman
e2dafdb5b9
[Native/Tests] Add explicit import for SharedImmutable
...
This fixes an overload resolution ambiguity in K2.
#KT-56272
2023-05-11 13:10:34 +00:00
Igor Chevdar
2f24c6df80
[K/N] Added isSubtype intrinsic
2023-05-11 09:30:18 +00:00
Igor Chevdar
67b65ec56a
[K/N] Reformat
2023-05-11 09:30:18 +00:00
Igor Chevdar
96c142569d
[K/N] Slight devirtualization improvement
...
Make devirtualization not by an actual receiver type but rather
by an actual virtual method implementation (which sometimes can be better)
2023-05-11 09:30:18 +00:00
Igor Chevdar
1ef81c005e
[K/N][tests] Fixed a test for KT-55938
...
Used in the test cache directory should be prepared before the test
2023-05-10 13:12:09 +00:00
Sergej Jaskiewicz
93d1932ccb
[IR] Make IrReturnTargetSymbol a sealed interface
2023-05-10 11:51:26 +00:00
Sergej Jaskiewicz
6c211f3a39
[IR] Make IrFunctionSymbol a sealed interface
2023-05-10 11:51:26 +00:00
Sergej Jaskiewicz
1a371350ea
[IR] Make IrClassifierSymbol a sealed interface
2023-05-10 11:51:25 +00:00
Troels Bjerre Lund
388634e47d
[K/N] custom-alloc: Encode consecutive free blocks ^KT-55364
...
Co-authored-by: Troels Lund <troels@google.com >
Merge-request: KOTLIN-MR-662
Merged-by: Alexander Shabalin <alexander.shabalin@jetbrains.com >
2023-05-10 09:45:14 +00:00
Igor Chevdar
e4f30589a4
[K/N] Incremental compilation of per-file caches
2023-05-10 08:37:32 +00:00
Igor Chevdar
74864ba1d0
[K/N][codegen] Trampoline to call virtual functions to reduce dependencies coupling
2023-05-10 08:37:32 +00:00
Igor Chevdar
281296fc2a
[K/N] Rely on file fqName & path instead of unstable index
2023-05-10 08:37:32 +00:00
Igor Chevdar
f90db20512
[K/N][caches] Added klib hash computing and storing
2023-05-10 08:37:32 +00:00
Igor Chevdar
a8135c60ce
[K/N] Turn on optimistic escape analysis
...
For new MM (with tracing GC), it is safe to turn it on
2023-05-10 05:51:52 +00:00
Vladimir Sukharev
c6d9821ef0
[K2/N] Rework testStdlibFramework to avoid compiler crash due to KT-58459
...
^KT-58459
Merge-request: KT-MR-10043
Merged-by: Vladimir Sukharev <Vladimir.Sukharev@jetbrains.com >
2023-05-09 16:52:04 +00:00
Pavel Punegov
5a95d919c7
[K/N] Add kotlinx.cinterop.ExperimentalForeignApi opt-ins
...
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 >
2023-05-09 09:39:40 +00:00
Pavel Kunyavskiy
11e1bcca1d
[K/N] Avoid using deprecated functions in data class generated methods
...
^KT-58267
2023-05-09 09:18:42 +00:00