Commit Graph

36 Commits

Author SHA1 Message Date
Konrad `ktoso` Malawski
62155f380d [Distributed] Improve getting return type metadata for distributed invocations
rdar://141313340
2025-02-15 11:27:06 +09:00
Konrad `ktoso` Malawski
41d8962783 Revert "Revert "Revert "[Distributed] remote calls over-retain returned values""" 2024-10-04 06:53:43 +09:00
Konrad `ktoso` Malawski
62b04be2fa Revert "Revert "[Distributed] remote calls over-retain returned values"" 2024-09-21 14:50:35 +09:00
Konrad `ktoso` Malawski
9779137dc9 Revert "[Distributed] remote calls over-retain returned values" 2024-09-21 13:58:43 +09:00
Konrad `ktoso` Malawski
a12420a739 [Distributed] Must deinitialize return value of remoteCall
resolves rdar://136338200
resolves rdar://136313477
2024-09-20 14:33:46 +09:00
Konrad `ktoso` Malawski
e53cd7d079 [Distributed] Handle #isolation param in DA as known to not cross isolation (#75327)
The isolation checker was assuming that one can only be isolated to a
specific var, but that's not true for distributed actors -- because the
default parameter emitted by #isolation is a method call -- converting
the self into an any Actor.

We must handle this in isolation checker in order to avoid thinking
we're crossing isolation boundaries and making methods implicitly async
etc, when we're actually not.

resolves rdar://131874709
2024-07-19 09:47:24 +09:00
Konrad `ktoso` Malawski
168bc7b454 [Concurrency] Fix how we obtain DA-as-A conformance for cross module
Resolves rdar://127206143
2024-05-28 13:37:21 +09:00
Konrad `ktoso` Malawski
7cd9063ba5 [Distributed] Diagnose missing import also for funcs in extensions
Resolves rdar://125813581
2024-04-09 17:08:27 +09:00
Konrad `ktoso` Malawski
b7ff16baf7 [Distributed] Only synthesize Codable for DA where the ID is Codable (#72081) 2024-03-07 22:40:00 -08:00
Konrad `ktoso` Malawski
c56a1e8be7 [Distributed] Handle mangling thunks in extensions with generic AS and $Stubs (#71914) 2024-02-29 04:22:00 -08:00
Konrad `ktoso` Malawski
e9c7f3c382 [Distributed] Target identifiers for protocol calls (#70928) 2024-02-16 07:19:20 -08:00
Konrad `ktoso` Malawski
037df0130f [Distributed] PoC using a property wrapper on distributed func param for validation 2023-06-30 11:28:27 +09:00
Konrad `ktoso` Malawski
cd3e243ff8 [Distributed] Ensure decoded classes get refcounted down to 0 from decoding 2023-05-19 23:29:49 +02:00
Konrad `ktoso` Malawski
629ac65eb0 [Distributed] better test for SIL lifetime with AddressOnly types 2023-02-21 14:20:52 +09:00
Konrad `ktoso` Malawski
dadf3011f9 cleanups 2022-04-18 16:53:44 -07:00
Konrad `ktoso` Malawski
79ad9278b2 [Distributed] Retain adhoc decodeNextArgument in distributed thunk 2022-04-18 16:53:10 -07:00
Konrad `ktoso` Malawski
8d3e7d91c0 [Distributed] ResultHandler.onReturn must be ad-hoc because SerializationRequirement (#41916)
* [Distributed] Invoke handler.onReturn ad hoc via ast synthesized func

* reformat and cleanup

* remove unused var
2022-03-24 21:44:37 +09:00
Konrad `ktoso` Malawski
5a5d1ba2e6 [Distributed] Implement RemoteCallArgument 2022-03-17 22:55:09 +09:00
Konrad `ktoso` Malawski
ea29723466 [Distributed] Add name parameter to recordArgument for better interop 2022-03-17 20:05:31 +09:00
Konrad `ktoso` Malawski
8c13370242 [Distributed] rename _Distributed to underscoreless module 2022-03-16 08:35:35 +09:00
Konrad `ktoso` Malawski
4fa0855907 [Distributed] RemoteCallTarget now pretty prints and hides mangled names 2022-03-15 17:34:04 +09:00
Konrad `ktoso` Malawski
94c0e522b0 Merge pull request #41415 from xedin/dist-generic-accessors
[Distributed] Remove class-bound restriction from target invocation decoder
2022-02-17 23:10:10 +09:00
Pavel Yaskevich
7c9ccb1346 [Distributed] NFC: Adjust test-cases for account for new decoder handling 2022-02-16 20:32:33 -08:00
Konrad `ktoso` Malawski
b02f9c7a97 [Distributed] ad-hoc req for decodeNextArgument & onReturns
fixup
2022-02-16 08:18:30 +09:00
Konrad `ktoso` Malawski
bffd956033 [Distributed] improve ad-hoc requirement typechecking 2022-02-11 19:25:48 +09:00
Konrad `ktoso` Malawski
b19e073bc4 [Distributed] Unlock all tests rdar://88228867 2022-02-03 06:18:54 +09:00
Konrad `ktoso` Malawski
48db739db0 [Distributed] Record generic substitution types for invocation 2022-02-02 18:12:32 +09:00
Pavel Yaskevich
d5c9a4b5b3 [Distributed] NFC: Add SerializationRequirement conformance to decoder in tests 2022-01-31 00:37:59 -08:00
Pavel Yaskevich
c3cafcc1ab [Distributed] NFC: Split FakeInvocation into Encoder and Decoder and adjust tests 2022-01-29 14:33:41 -08:00
Pavel Yaskevich
d0fdf20552 [Distributed] Runtime: Switch to use argument decoder instead of heterogeneous buffer 2022-01-29 14:33:41 -08:00
Pavel Yaskevich
8bff147227 [Distributed] Remove extraneous DistributedTargetInvocationArgumentDecoder 2022-01-29 14:33:41 -08:00
Konrad `ktoso` Malawski
6a0164d16f [Distributed] Reuse fake actor systems more in tests 2022-01-28 21:21:08 +09:00
Konrad `ktoso` Malawski
7f427c9ca5 [Distributed] implement "roundtrip" tests and AS 2022-01-28 18:50:40 +09:00
Konrad `ktoso` Malawski
4bf2a92bda [Distributed] Remove @_dynamic replacements; impl remoteCall ad-hoc reqs
Squashed commit of the following:

commit e5a05ffe44
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Thu Jan 27 17:45:31 2022 +0900

    cleanup

commit 1f751cea5a
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Thu Jan 27 14:50:33 2022 +0900

    cleanups

commit c632f3215d
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Thu Jan 27 14:01:09 2022 +0900

    add test for generic from actor decl

commit 09b8bd50a7
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Thu Jan 27 14:00:58 2022 +0900

    cleanups

commit 31f4d0cffd
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Thu Jan 27 11:40:51 2022 +0900

    fix test

commit ad4db2fb6c
Merge: 97227edcca 07e2dfda56
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 26 23:31:41 2022 +0900

    Merge branch 'main' into wip-zzz

commit 97227edcca
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 26 21:01:25 2022 +0900

    remove @_dynamic methods!

    fix tests

commit 1c79344dbb
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 19 12:51:09 2022 +0900

    cleanup

    wip

    stuck

    fixed the stack cleanups

    cleanups pretty good now

    weird load

    rki

    works

    remove hack

    add take + throw + return

    fix test

    more tests fixed

    more tests fixed

    more tests fixed

commit 3ed494c175
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Tue Jan 18 21:09:28 2022 +0900

    stack issues in SIL verification

commit 5cf43a7f86
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Tue Jan 18 09:19:51 2022 +0900

    about to call the remoteCall

    goot to return, but missing subs

commit df8e47122a
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Thu Jan 13 14:09:49 2022 +0900

    [Distributed] Refactor Invocation to Decoder/Encoder

    getting there

    done-recording

    working on the string init

    stuck trying to get String initializer SILFunction

    created the remote call target

commit fc7bd62f32
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 12 23:01:14 2022 +0900

    [Distributed] Pass arguments from Invocation to HBuffer

commit cafc2cc058
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 12 22:08:47 2022 +0900

    works

commit a7d01837ff
Author: Pavel Yaskevich <pyaskevich@apple.com>
Date:   Tue Jan 11 15:48:58 2022 -0800

    [Distributed] Adjust interface of `swift_distributed_execute_target`

    Since this is a special function, `calleeContext` doesn't point to
    a direct parent but instead both parent context (uninitialized)
    and resume function are passed as last arguments which means that
    `callContext` has to act as an intermediate context in call to accessor.

commit c1f830be27
Author: Pavel Yaskevich <pyaskevich@apple.com>
Date:   Tue Jan 11 17:00:08 2022 -0800

    [Distributed] Drop optionality from result buffer in `_executeDistributedTarget`

    `RawPointer?` is lowered into a two arguments since it's a struct,
    to make it easy let's just allocate an empty pointer for `Void` result.

commit c83c2c37b6
Author: Pavel Yaskevich <pyaskevich@apple.com>
Date:   Tue Jan 11 17:02:45 2022 -0800

    [Distributed] NFC: Update _remoteCall test-case to check multiple different result types

commit 29e7cf50e4
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 12 21:32:37 2022 +0900

    wip

commit 9128ecc6f8
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 12 20:46:20 2022 +0900

    wip

commit a6b2a62a67
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 12 20:38:22 2022 +0900

    wip

commit 8b188f0d43
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 12 16:55:10 2022 +0900

    wip

commit 3796bec2b9
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Jan 12 16:55:02 2022 +0900

    wip

commit 0ffc68b5ef
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Tue Jan 11 21:44:58 2022 +0900

    [Distributed] Implementing ad-hoc protocol requirements

commit 78862575e4
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Thu Jan 6 18:03:54 2022 +0900

    cleanup

commit 5f4ab89e25
Merge: 24a628e7c0 fdda6f2ee4
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Thu Jan 6 15:51:39 2022 +0900

    Merge branch 'main' into wip-impl-execute-swift

commit 24a628e7c0
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Thu Jan 6 15:33:21 2022 +0900

    wip

commit 69e7fed09d
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Dec 22 06:36:45 2021 +0900

    [Distributed] comment out distributed_actor_remoteCall for now

commit 376733a9f6
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Tue Dec 21 16:00:06 2021 +0900

    reimplement distributed get type info impls

commit 74ab47886a
Author: Konrad `ktoso` Malawski <konrad_malawski@apple.com>
Date:   Wed Dec 15 21:37:08 2021 +0900

    [Distributed] Implement func metadata and executeDistributedTarget

    dont expose new entrypoints

    able to get all the way to calling _execute
2022-01-27 17:51:43 +09:00
Konrad `ktoso` Malawski
ef14ff15e8 [Distributed] Refactor Invocation to Decoder/Encoder 2022-01-13 18:27:18 +09:00
Konrad `ktoso` Malawski
cee89ec541 [Distributed] DistributedActorSystem renaming and redesign (#40387)
* [Distributed] towards DistributedActorSystem; synthesize the id earlier, since Identifiable.id

* Fix execute signature to what Pavel is working with

* funcs are ok in sil

* fixed lifetime of id in inits

* fix distributed_actor_deinit

* distributed_actor_local

* update more tests

fixing tests

fix TBD test

fix Serialization/distributed

fix irgen test

Fix null pointer crashes

* prevent issues with null func ptrs and fix Distributed prorotocol test

* fix deinit sil test
2021-12-13 11:29:25 +09:00