Commit Graph

75 Commits

Author SHA1 Message Date
Konrad `ktoso` Malawski
1675669e43 Revert "[Distributed] workaround for LocalTestingDAS crashes;"
This reverts commit bcd0f64e91.
2022-05-08 19:37:24 +09:00
Konrad `ktoso` Malawski
bcd0f64e91 [Distributed] workaround for LocalTestingDAS crashes;
This happens to work, but is not a real fix; we are not handling well
types declared in a library evolution enabled library, which this DAS
is. Without this, at runtime, we crash in LocalTestingDAS using actor
initializers
2022-05-07 07:28:55 +09:00
Konrad `ktoso` Malawski
90e034f1dc [Distributed] Diagnose missing inout on remoteCall decls 2022-05-05 07:09:03 +09:00
Konrad `ktoso` Malawski
e01bcc470f [Distributed] SILGen must consistently use prop get requests 2022-04-23 07:49:54 +09:00
Konrad `ktoso` Malawski
317fdd0740 [Distributed] Guard ID synthesis from synthesizing the property multiple times; e.g. during multi module builds 2022-04-22 23:18:16 +09:00
Konrad `ktoso` Malawski
4e2c059e20 review feedback, cleanup getting decode func 2022-04-18 16:53:47 -07:00
Konrad `ktoso` Malawski
870c712bd0 fix protocols 2022-04-18 16:53:13 -07:00
Konrad `ktoso` Malawski
79ad9278b2 [Distributed] Retain adhoc decodeNextArgument in distributed thunk 2022-04-18 16:53:10 -07:00
Konrad `ktoso` Malawski
8d8c652ebf Merge pull request #42348 from ktoso/ban-non-protocol-serialization-reqs
[Distributed] Require that SerReq can only be used with protocols
2022-04-16 09:36:16 +09:00
Konrad `ktoso` Malawski
45eaf3393d [Distributed] Require that SerReq can only be used with protocols 2022-04-14 00:25:51 +09:00
Konrad `ktoso` Malawski
edd5880a59 [Distributed] SerializationReq must be associated type on DA 2022-04-13 21:52:15 +09:00
Konrad `ktoso` Malawski
fa5321877e [Distributed] Remove unused request, small cleanup 2022-03-25 21:53:10 +09:00
Pavel Yaskevich
2025b44902 [Distributed] Fix ActorSystem requests on protocols that conform to DistributedActor 2022-03-25 16:27:06 +09: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
6d502fc042 [Distributed] Implicit Codable conformance for Dist Actors
[Witness] implement dump() on witness
2022-03-11 18:07:14 +09:00
Konrad `ktoso` Malawski
5ab8e0834d [Distributed] Reimplement distributed call thunks completely in AST (#41616)
* [Distributed] dist actor always has default executor (currently)

* [Distributed] extra test for missing makeEncoder

* [DistributedDecl] Add DistributedActorSystem to known SDK types

* [DistributedActor] ok progress on getting the system via witness

* [Distributed] allow hop-to `let any: any X` where X is DistActor

* [Distributed] AST: Add an accessor to determine whether type is distributed actor

- Classes have specialized method on their declarations
- Archetypes and existentials check their conformances for
  presence of `DistributedActor` protocol.

* [Distributed] AST: Account for distributed members declared in class extensions

`getConcreteReplacementForProtocolActorSystemType` should use `getSelfClassDecl`
otherwise it wouldn't be able to find actor if the member is declared in an extension.

* [Distributed] fix ad-hoc requirement checks for 'mutating'

[PreChecker] LookupDC might be null, so account for that

* [Distributed] Completed AST synthesis for dist thunk

* [Distributed][ASTDumper] print pretty distributed in right color in AST dumps

* wip on making the local/remote calls

* using the _local to mark the localCall as known local

* [Distributed] fix passing Never when not throwing

* fix lifetime of mangled string

* [Distributed] Implement recordGenericSubstitution

* [Distributed] Dont add .

* [Distributed] dont emit thunk when func broken

* [Distributed] fix tests; cleanups

* [Distributed] cleanup, move is... funcs to DistributedDecl

* [Distributed] Remove SILGen for distributed thunks, it is in Sema now!

* [Distributed]  no need to check stored props in protocols

* remote not used flag

* fix mangling test

* [Distributed] Synthesis: Don't re-use AST nodes for `decodeArgument` references

* [Distributed] Synthesis: Make sure that each thunk parameter has an internal name

* [Distributed/Synthesis] NFC: Add a comment regarding empty internal parameter names

* [Distributed] NFC: Adjust distributed thunk manglings in the accessor section test-cases

* cleanup

* [Distributed] NFC: Adjust distributed thunk manglings in the accessor thunk test-cases

* review follow ups

* xfail some linux tests for now so we can land the AST thunk

* Update distributed_actor_remote_functions.swift

Co-authored-by: Pavel Yaskevich <xedin@apache.org>
2022-03-10 23:58:23 +09:00
Konrad `ktoso` Malawski
b02f9c7a97 [Distributed] ad-hoc req for decodeNextArgument & onReturns
fixup
2022-02-16 08:18:30 +09:00
Konrad `ktoso` Malawski
1caa0b1de0 [Distributed] Handle reqs on DistributedTargetInvocationEncoder 2022-02-14 22:08:16 +09:00
Konrad `ktoso` Malawski
005743c92c [Distributed] implement adhoc requirements properly for Encoder 2022-02-14 16:14:41 +09:00
Konrad `ktoso` Malawski
0fec1b31da [Distributed] Implement ad-hoc checks for
DistributedTargetInvocationEncoder
2022-02-11 19:26:18 +09:00
Konrad `ktoso` Malawski
c7e3af84e4 [Distributed] Handle composite types in SerializationRequirement 2022-02-11 19:26:18 +09:00
Konrad `ktoso` Malawski
12932c7b3c [Distributed] Introduce DistributedDecl.h for greater reuse 2022-02-11 19:25:57 +09:00
Konrad `ktoso` Malawski
bffd956033 [Distributed] improve ad-hoc requirement typechecking 2022-02-11 19:25:48 +09:00