Glasgow Parallel Haskell
Download Current Developments Activity reports GPH Language Papers Algorithms Mailing List Parallel Programming FTP server

The GPH Language

Glasgow Parallel Haskell, or GPH for short, is a non-strict parallel functional programming language. GPH is an extension of Haskell, adding a primitive for parallel composition par, that is used together with sequential composition seq to express how a program should be evaluated in parallel.

Download

Glasgow Parallel Haskell (GPH) is implemented as a special setup of the Glasgow Haskell Compiler (GHC). Recent GPH versions are available as source or binary bundles from our FTP server (see below). You must also download and install PVM (Parallel Virtual Machine), if you want to execute programs on several processors.

GUM

The latest stable implementation of GPH is GUM-4.06.2 (see Announcement). It is available as source distribution and as a binary snapshot for SuSe 8.2 and RedHat 8.0. A slightly older version GUM-4.06 is available as source bundle or a binary snapshot for RedHat 7.0 Intel Linux (libc2.1). The stable branch is available from the GHC CVS repository via tag gum-4-06.

The unstable branch of development is GUM-6.6 and it is currently being tested on a Beowulf cluster. The unstable branch is available as a source bundle upon request to the mailing list.

Ports to other architectures (available on request):

GranSim

The latest version of the parallelism simulator is GranSim 3.02, implementing GPH on top of Haskell 1.4. It has not been ported to the new GHC 5.xx runtime system, yet, and there are no plans for a port in the near future. A snapshot of GranSim 3.02 on an Intel Redhat 7.3 platform is available on the FTP server. This bundle is courtesy of Jost Berthold.

Tools

We also have tar balls containing GPH example programs and a set of visualisation tools.

FTP server

All files are available from the GPH FTP server.

Documentation

Installation

Before starting to install one of the bundles, check README.GUM for general installation notes. More specific instructions for installing a binary snapshot can be found in INSTALL.GUM. A log file of an installation from source is also available. For general instructions on how to build GHC from source, see the Building Guide on the GHC web pages.

GPH Programming

To learn more about how to program in GPH check the on-line version of the Gentle Introduction to GPH. It's still very drafty but might be useful for newcomers to GPH. Also check the parallelism section of the updated GHC User's Guide for GUM 4.06. An in-depth discussion of our preferred programming methodology is given in paper on Evaluation Strategies. See also the Manuals section of the GPH papers page.

Papers

The following web page gives a list of selected papers covering all aspects of GPH. On other pages, recent papers and papers on architecture independence are available.

Current Developments

The main direction in developing the parallel runtime-system further is towards architecture-independent parallelism. We are at the moment extending the GUM system with new mechanisms for load balancing and work distribution in order to improve the performance on high-latency machines. This work is summarised in a separate web page on architecture-independent parallelism.

Another strand of research is improved performance prediction of GPH. We are currently working on an operational semantics for GPH, which will allow us to predict the amount of parallelism generated by a particular evaluation strategy.

Closely related to GPH is a new language designed for the distributed execution of Haskell programs: GdH (Glasgow distributed Haskell). We have just finished a first implementation of GdH and tried it on a couple of distributed applications. At the moment we are investigating possibilities of adding fault tolerance to this system. You can find details at the GdH Home Page.

Activity reports


GPH Algorithms Repository

The parallel algorithms library for GPH is rather dated by now but still available. To get a set of test programs better download the following source bundle of test programs for GUM-4.06.

Mailing List

The GPH mailing list exists to keep people informed about the use and implementation of the GPH programming language: gph@macs.hw.ac.uk.

To join/leave the mailing list, or look up the archives, visit this web page.

Developing Parallel Programs

The great thing about GPH is that it's so easy to take a sequential program written in Haskell, and add par and seq annotations to make it parallel. However, to get the best parallelism out of your code isn't always trivial, so tools and libraries have been developed to make the process easier. Here's a recommended list of things to help with program development:

GranSimFor simulating GPH on a single processor;
StrategiesA library that provides better abstraction and common parallel strategies;
ProfilingTo visually show the behaviour of your parallel program.
Guidelines on developing large parallel functional programs with GPH are in the following paper:

Engineering Large Parallel Functional Programs
Hans-Wolfgang Loidl and Phil Trinder, IFL, 1997.

Evaluation Strategies

Annotating a program with par and seq can obfuscate the code. A more advanced means of abstraction is possible that allows the structure to remain intact, but with additional suffixes that describe its parallel execution. This new abstraction is provided by using higher-order functions, that have been dubbed evaluation strategies. A library of common parallel programming strategies has been developed, and is described in the paper:

Algorithm + Strategy = Parallelism, HTML
Kevin Hammond, Hans-Wolfgang Loidl, Simon Peyton Jones, and Phil Trinder, JFP 8(1), 1998.

Simulating Parallelism (GranSim)

Before running programs on a parallel machine, it is recommended that you first simulate your code on a single processor. The simulator called GranSim allows you to control a whole variety of parameters, including message latency, and collects more detailed execution profiles than the real parallel implementation does. When developing programs it is particularly useful to get GranSim to simulate an ideal architecture, i.e. a machine with infinite processors, and no communication cost. More details can be found on GranSim's homepage, and in the user 's guide:

GranSim user's guide, HTML
Hans-Wolfgang Loidl, 1996.

Parallel Execution (GUM)

GUM is the name of the runtime system that provides support on real parallel architectures. Communication between processors is facilitated by using the message-passing library PVM in a Unix environment. Since abstract C is used as the intermediate language, GPH is available on any architecture that provides both gcc and PVM. GUM has also been ported to other message-passing libraries such as MPI and Thinking Machines CMMD, although these ports have not been released. The following paper fully describes GUM:

GUM: a portable parallel implementation of Haskell.
Kevin Hammond, Jim Mattson, Andrew Partridge, Simon Peyton Jones, and Phil Trinder, PLDI, 1996.

Ports

GUM is currently available on the following parallel architectures:

Architecture Constructor(s)
Shared-memory
multiprocessor
Sun Solaris Glasgow folk
Networks of
workstations
Sun Solaris
DEC Alpha
Intel Linux Ed Barry
Distributed-memory
multiprocessor
Thinking Machines CM5 Kei Davis

Please let us know if you you have ported GPH to any other platforms not listed here by e-mailing gph@macs.hw.ac.uk.

Profiling

Both GranSim and GUM produce log files which are profiles of the parallel execution of a program. These log files can be converted to PostScript with scripts that are included with the GPH compiler. Some examples can be found on the GranSim homepage.

Applications

The following papers all describe large applications that have been written with GPH:

Parallelising a Large Functional Program; Or: Keeping LOLITA Busy
Hans-Wolfgang Loidl, Richard Morgan, Phil Trinder, Sanjay Poria, Chris Cooper, Simon Peyton Jones, and Roberto Garigliano, IFL, 1997.

A Case Study of Data-intensive Programs in Parallel Haskell
Phil Trinder, Kevin Hammond, Hans-Wolfgang Loidl, Simon Peyton Jones, and J. Wu, Glasgow FP Workshop, 1996.

LinSolv: a Case Study in Strategic Parallelism
Hans-Wolfgang Loidl, Glasgow FP Workshop, 1997.

Naira: A Parallel 2 Haskell Compiler
Sahala Junaidu, Tony Davie, and Kevin Hammond, IFL, 1997.

Refining a Parallel Algorithm For Calculating Bowings
Cordy Hall, Hans-Wolfgang Loidl, Phil Trinder, Kevin Hammond, and John O'Donnell, Glasgow FP Workshop, 1997.

People

The following list includes past and present developers, users, and people that have a serious interest in GPH.

Abyd Al Zain ceeatia@macs.hw.ac.uk
Clem Baker-Finch clem@ise.canberra.edu.au
Kei Davis kei@lanl.gov
Andre Rauber Du Bois dubois@macs.hw.ac.uk
Cordy Hall cvh@dcs.gla.ac.uk
Jon Hall J.G.Hall@open.ac.uk
Kevin Hammond kh@dcs.st-and.ac.uk
Hans-Wolfgang Loidl hwloidl@tcs.ifi.lmu.de
Rita Loogen loogen@mathematik.uni-marburg.de
John O'Donnell jtod@dcs.gla.ac.uk
Simon Peyton Jones simonpj@microsoft.com
Robert Pointon rpointon@macs.hw.ac.uk
Phil Trinder trinder@macs.hw.ac.uk

Projects

APART 624
The APART project focusses on achieving architecture-independent parallelism with GPH and extensions to the current runtime-system.

APSET
APSET is a project being carried out at the Open University and Heriot-Watt University to provide better profiling tools for GPH.

Eden
Eden is a parallel functional language that is being implemented by extending GHC.

Instances generator for Haskell
A Haskell preprocessor that is particularly useful for generating instances of the class NFData, that is used by evaluation strategies.

Workshops

Glasgow FP Workshops
The functional programming group at Glasgow organises an annual workshop covering all aspects of functional programming.

IFL
The International Workshop on Functional Languages has been held annually since 1989, and covers research related to the implementation of functional languages. Here are some links to IFL workshops: Norwich 1994, Bonn 1996, St. Andrews 1997, London 1998, Aachen 2000, Stockholm 2001.

SCOFPIG
The Scottish Functional Parallel Interest Group is an informal collection of researchers that are interested in parallel functional programming. Meetings are held two or three times a year at a Scottish University.

Scottish FP Workshops
The Scottish Universities that are active in functional programming organise an annual workshop. Participation is open, and the workshop covers all aspects of functional programming.


Haskell | GHC | GranSim

Valid HTML 4.0!

gph@macs.hw.ac.uk

Last modified: Mon Aug 6 22:26:03 2007