stream-fusion: Faster Haskell lists using stream fusion

[ bsd3, data, library ] [ Propose Tags ] [ Report a vulnerability ]

This package provides the standard Haskell list library reimplemented to allow stream fusion. This should in general provide faster list operations, and faster code for list-heavy programs. See the paper Stream Fusion: From Lists to Streams to Nothing at All, Coutts, Leshchinskiy and Stewart, 2007. To use, simply import Data.List.Stream in place of Data.List, and hide list functions from the Prelude.


[Skip to Readme]

Downloads

Note: This package has metadata revisions in the cabal description newer than included in the tarball. To unpack the package including the revisions, use 'cabal get'.

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions [RSS] 0.1, 0.1.1, 0.1.2, 0.1.2.1, 0.1.2.2, 0.1.2.3, 0.1.2.4, 0.1.2.5
Dependencies base (>=3 && <4.8) [details]
Tested with ghc ==7.6.1
License BSD-3-Clause
Author Duncan Coutts, Don Stewart
Maintainer duncan.coutts@worc.ox.ac.uk, dons00@gmail.com
Revised Revision 1 made by HerbertValerioRiedel at 2017-06-10T08:09:29Z
Category Data
Home page http://hackage.haskell.org/trac/ghc/ticket/915
Source repo head: darcs get http://code.haskell.org/~dons/code/stream-fusion
Uploaded by DonaldStewart at 2013-01-12T22:04:58Z
Distributions
Reverse Dependencies 7 direct, 2014 indirect [details]
Downloads 9022 total (16 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs uploaded by user
Build status unknown [no reports yet]

Readme for stream-fusion-0.1.2.5

[back to package description]
                          Stream fusible lists

Faster lists using stream fusion.

The abstract from the paper:

    This paper presents an automatic deforestation system, \emph{stream
    fusion}, based on equational transformations, that fuses a wider
    range of functions than existing short-cut fusion systems. In
    particular, stream fusion is able to fuse zips, left folds and
    functions over nested lists, including list comprehensions. A
    distinguishing feature of the framework is its simplicity: by
    transforming list functions to expose their structure, intermediate
    values are eliminated by general purpose compiler optimisations.

    We have reimplemented the Haskell standard List library on top of
    our framework, providing stream fusion for Haskell lists. By
    allowing a wider range of functions to fuse, we see an increase in
    the number of occurrences of fusion in typical Haskell programs. We
    present benchmarks documenting time and space improvements.

Building:

  $ runhaskell Setup.lhs configure --prefix=/home/dons
  $ runhaskell Setup.lhs build
  $ runhaskell Setup.lhs install

Use:

  import Data.List.Stream

and use as you would for normal lists.
Compile with ghc -O2 for best results.