Write a Blog >>
GPCE 2016
Mon 31 October - Tue 1 November 2016 Amsterdam, Netherlands
co-located with SPLASH 2016
Mon 31 Oct 2016 14:30 - 15:00 at Zürich 1 - Generative Programming II Chair(s): Ulrik Pagh Schultz

In today’s web applications asynchronous requests to remote services using callbacks or futures are omnipresent. The continuation of such a non-blocking task is represented as a callback function that will later be called with the result of the request. This style of programming where the remainder of a computation is captured in a continuation function is called continuation-passing style (CPS). This style of programming can quickly lead to a phenomenon called “callback hell”, which has a negative impact on the maintainability of applications that employ this style. Several alternatives to callbacks are therefore gaining traction within the web domain. For example, there are a number of frameworks that rely on automatically transforming code, written without callbacks in a direct sequential style, into the continuation-passing style. However, these frameworks often employ a conservative approach in which each function call is transformed into CPS. Even when they do a selective transformation they will often encapsulate the entire remainder of the computation in the continuation. This conservative approach can sequentialise requests that could otherwise be run in parallel. So-called delimited continuations can remedy, but require special marks that have to be manually inserted in the code for marking the beginning and end of the continuation. In this paper we propose an alternative strategy in which we apply a selective and delimited CPS transformation that operates on a Program Dependence Graph instead to find the limits of each continuation. We implement this strategy in JavaScript and demonstrate its applicability to various web programming scenarios.

Slides (gpce16.pdf)1.25MiB

Mon 31 Oct
Times are displayed in time zone: Amsterdam, Berlin, Bern, Rome, Stockholm, Vienna change

13:30 - 15:10
Generative Programming IIGPCE at Zürich 1
Chair(s): Ulrik Pagh SchultzUniversity of Southern Denmark
Actor Profiling in Virtual Execution Environments
Andrea RosàUniversità della Svizzera italiana, Lydia Y. ChenIBM Research Lab Zurich, Walter BinderUniversity of Lugano
Bootstrapping Domain-Specific Meta-Languages in Language Workbenches
Gabriël KonatDelft University of Technology, Sebastian ErdwegDelft University of Technology, Netherlands, Eelco VisserDelft University of Technology, Netherlands
Link to publication DOI Pre-print Media Attached
Dependence-Driven Delimited CPS Transformation for JavaScript
Laure PhilipsSoftware Languages Lab, Joeri De KosterVrije Universiteit Brussel, Belgium, Wolfgang De MeuterVrije Universiteit Brussel, Belgium, Coen De RooverVrije Universiteit Brussel, Belgium
File Attached