Programming with LVars, by example
LVars are monotonically growing, lattice-based data structures for deterministic parallel programming. LVish is a Haskell library for programming with LVars. This repository contains toy examples of programs that use LVars and LVish, as well as a few that don't use LVars but are there for illustrative purposes.
The code has been tested to build against GHC 7.8.1, 7.8.2, and 7.8.3. You should probably use one of those.
You can install LVish
from Hackage by running
cabal install lvish (perhaps preceded by
cabal update). That will
install the most recently released version, which, as of this writing,
If you want the newest, unreleased version of LVish -- which has more cool features than the 1.x releases do -- you'll have to install it from git. I recommend the following:
- Make sure you've pulled the
concurrent-skiplistsubmodules. Something like
git submodule update --initshould work. (
lvarscontains the LVish library and some of its friends;
concurrent-skiplistis one of LVish's dependencies.)
- Go into the
- Create a new sandbox in that directory with
cabal sandbox init.
cabal install -j ../lvars/haskell/par-classes/ ../lvars/haskell/par-collections/ ../lvars/haskell/par-transformers/ ../concurrent-skiplist/ happy alex.
cabal install ../lvars/haskell/lvish/and cross your fingers.
The usual caveats about research code apply: Parts of it are broken. The API will change. It will eat your laundry.