add an experimental feature DeferSendableChecking to defer the sendable checking of some sites. For now, only diagnostics corresponding to non-sendable arguments passed to calls with unsatisfied isolation are deferred. A SIL pass SendNonSendable is added to emit the deferred diagnostics, and ApplyExpr is appropriately enriched to make that deferral possible.

This commit is contained in:
jturcotti
2023-06-30 11:57:13 -07:00
parent cb61903d8c
commit aa9f1a3584
12 changed files with 342 additions and 60 deletions

View File

@@ -132,6 +132,7 @@ static void addMandatoryDiagnosticOptPipeline(SILPassPipelinePlan &P) {
P.addAddressLowering();
P.addFlowIsolation();
P.addSendNonSendable();
// Automatic differentiation: canonicalize all differentiability witnesses
// and `differentiable_function` instructions.