Asynchronous effects

03/04/2020
by   Danel Ahman, et al.
0

We explore asynchronous programming with algebraic effects. We complement their conventional synchronous treatment by showing how to naturally also accommodate asynchrony within them, namely, by decoupling the execution of operation calls into signalling that an operation's implementation needs to be executed, and interrupting a running computation with the operation's result, to which the computation can react by installing interrupt handlers. We formalise these ideas in a small core calculus, called λ_ae. We demonstrate the flexibility of λ_ae using examples ranging from a multi-party web application, to preemptive multi-threading, to remote function calls, to a parallel variant of runners of algebraic effects. In addition, the paper is accompanied by a formalisation of λ_ae's type safety proofs in Agda, and a prototype implementation of λ_ae in OCaml.

READ FULL TEXT
POST COMMENT

Comments

There are no comments yet.

Authors

page 6

page 7

page 11

page 17

page 18

page 19

page 22

page 23

10/14/2021

Parallel Algebraic Effect Handlers

Algebraic effects and handlers support composable and structured control...
10/25/2019

Runners in action

Runners of algebraic effects, also known as comodels, provide a mathemat...
01/05/2020

A Diagrammatic Calculus for Algebraic Effects

We introduce a new, diagrammatic notation for representing the result of...
09/12/2018

PARyOpt: A software for Parallel Asynchronous Remote Bayesian Optimization

PARyOpt is a python based implementation of the Bayesian optimization ro...
11/18/2018

Handling polymorphic algebraic effects

Algebraic effects and handlers are a powerful abstraction mechanism to r...
01/20/2020

In-The-Field Monitoring of Functional Calls: Is It Feasible?

Collecting data about the sequences of function calls executed by an app...
12/31/2018

Eff Directly in OCaml

The language Eff is an OCaml-like language serving as a prototype implem...

Code Repositories

ioeffect

An effect monad for Scalaz 7.2


view repo
This week in AI

Get the week's most popular data science and artificial intelligence research sent straight to your inbox every Saturday.