edenskel-2.0.0.0: Semi-explicit parallel programming skeleton library

Portabilitynot portable
Stabilitybeta
Maintainereden@mathematik.uni-marburg.de
Safe HaskellNone

Control.Parallel.Eden.Iteration

Contents

Description

This Haskell module defines iteration skeletons for Eden.

Depends on the Eden Compiler.

Eden Project

Synopsis

Iteration Skeletons

iterUntilAtSource

Arguments

:: (Trans wl, Trans t, Trans sr) 
=> Places

where to instatiate

-> (inp -> ([wl], [t], ml))

input transformation function

-> (wl -> t -> (sr, wl))

worker function

-> (ml -> [sr] -> Either r ([t], ml))

combine function

-> inp

input

-> r

result

This is the basic implementation, using places for explicit process | placement of the worker processes.

iterUntilSource

Arguments

:: (Trans wl, Trans t, Trans sr) 
=> (inp -> ([wl], [t], ml))

input transformation function

-> (wl -> t -> (sr, wl))

worker function

-> (ml -> [sr] -> Either r ([t], ml))

combine function

-> inp

input

-> r

result

The iterUntil skeleton is an iterated map skeleton. Each worker function transforms one local worker state and one task per iteration. The result is the next local state and the iterations result, which is send back to the master. The master transforms the output of all tasks of one iteration and a local master state into the worker inputs of the next iteration and a new master state using the combine function (output: Right tasks masterState) or decides to terminate the iteration (output: Left result). The input transformation function generates all initial worker states and initial worker tasks and the initial master state from the skeleton.