Papers and presentations about transactional memory in Haskell

Other papers about STM and Haskell:

Haskell and transactional memory

In April 2010 I was fortunate to have the opportunity to address an group of 100+ Haskell enthusiasts in Tokyo. Here are O'Reilly wrote up the meeting. Here's the translation into English:
150 Haskeller were excited! "Haskellers Meeting 2010 Spring" was held in IIJ conference room, Kanda, Tokyo on April 16th. Simon Peyton Jones who is admired by Haskellers and also one of the authors of "Beautiful Code" gave a talk on "Haskell and Software Transaction Memory". This is a same topic described in chapter 24 of "Beautiful code" and chapter 28 of "Real World Haskell". The presentation of Simon-san was so attractive and wonderful just like he'd made legendary speech "How to give a good research talk". All we could sense his love for Haskell through his talk. Subsequently, Kazu Yamamoto who is the translation supervisor of our book "PGP" (unfortunately it is out of print) talked about "Experience on implementing a Web server in Haskell", and Nobuo Yamashita, who is one of the translators of "Real World Haskell" gave a speech of "Yet Another Purely Functional Expression for Interaction". The room was filled excitement because of Haskeller's terrible heat though the outside was so chilly that it snowed first time in 41 years for middle April.

At the same time, Simon-san is also an interviewee of "Masterminds of Programming" which is our new book. This is an interview collection of creators of influential programming languages. Simon-san appears in chapter 8 HASKELL with Paul Hudak and Philip Wadler. The Japanese version will be published this fall if everything goes well. Don't miss it!

Beautiful concurrency

Simon Peyton Jones. This is a chapter for the book "Beautiful code", edited by Greg Wilson, O'Reilly 2007. Abstract The free lunch is over. We have grown used to the idea that our programs will go faster when we buy a next-generation processor, but that time has passed. While that next-generation chip will have more CPUs, each individual CPU will be no faster than the previous year's model. If we want our program to run faster, we must learn to write parallel programs.

Parallel programs execute in a non-deterministic way, so they are hard to test, and bugs can be almost impossible to reproduce. If we want to write parallel programs that work reliably, we must pay particular attention to beauty. Sadly, parallel program are often less beautiful than their sequential cousins; in particular they are, as we shall see, less modular.

In this chapter I describe Software Transactional Memory (STM), a promising new approach to programming shared-memory parallel processors. Although still in its infancy, STM seems to support modular programs in a way that current technology does not. By the time we are done, I hope you will be as enthusiastic as I am about STM. It is not a solution to every problem, but it is a beautiful and inspiring attack on the daunting ramparts of concurrency.

Composable memory transactions

Tim Harris, Simon Marlow, Simon Peyton Jones, and Maurice Herlihy. ACM Conference on Principles and Practice of Parallel Programming 2005 (PPoPP'05). Abstract. Writing concurrent programs is notoriously difficult, and is of increasing practical importance. A particular source of concern is that even correctly-implemented concurrency abstractions cannot be composed together to form larger abstractions. In this paper we present a new concurrency model, based on transactional memory, that offers far richer composition. All the usual benefits of transactional memory are present (e.g. freedom from deadlock), but in addition we describe new modular forms of blocking and choice that have been inaccessible in earlier work. We've updated the original "Composable memory transactions" paper by fixing a couple of typos in the semantics. More importantly, it also includes an Appendix that describes a more consistent semantics for exceptions; this is what we propose to implement in GHC 6.6.

Lock -Free Data Structures using STMs in Haskell

Anthony Discolo, Tim Harris, Simon Marlow, Simon Peyton Jones, and Satnam Singh. Eighth International Symposium on Functional and Logic Programming, April 2006 (FLOPS'06). Abstract. This paper explores the feasibility of re-expressing concurrent algorithms with explicit locks in terms of lock free code written using Haskell's implementation of Software Transactional Memory (STM). Preliminary experimental results are presented which show that for multi-processor systems the simpler lock free implementations offer competitive or superior performance when compared to their corresponding the lock based implementations.

Transactional memory with data invariants

Tim Harris and Simon Peyton Jones. First ACM SIGPLAN Workshop on Languages, Compilers, and Hardware Support for Transactional Computing (TRANSACT'06), 11 June 2006, Ottawa, Canada. Abstract. This paper introduces a mechanism for asserting invariants that are maintained by a program that uses atomic memory transactions. The idea is simple: a programmer writes check E where E is an expression that should be preserved by every atomic update for the remainder of the program's execution. We have extended STM Haskell to dynamically evaluate check statements atomically with the user's updates: the result is that we can identify precisely which update is the first one to break an invariant.