edenmodules-1.2.0.0: Semi-explicit parallel programming library

Copyright(c) Philipps Universitaet Marburg 2005-2010
LicenseBSD-style (see the file LICENSE)
Maintainereden@mathematik.uni-marburg.de
Stabilitybeta
Portabilitynot portable
Safe HaskellNone
LanguageHaskell98

Control.Parallel.Eden.Edi

Description

The low-level parallel functional language: EDen Implementation language

This module defines a thin layer of type-checking wrappers over the parallel primitives implemented in ParPrim.hs.

Depends on the Eden Compiler.

Eden Group Marburg

Synopsis

Documentation

fork :: IO () -> IO () Source

spawnProcessAt :: Int -> IO () -> IO () Source

spawnArgsProcessAt :: NFData a => Int -> (a -> IO ()) -> a -> IO () Source

data ChanName' a Source

Instances

createCs :: Int -> IO ([ChanName' a], [a]) Source

sendWith :: Strategy a -> ChanName' a -> a -> IO () Source

sendNF :: NFData a => ChanName' a -> a -> IO () Source

sendStreamWith :: (a -> ()) -> ChanName' [a] -> [a] -> IO () Source

sendNFStream :: NFData a => ChanName' [a] -> [a] -> IO () Source

class NFData a where Source

A class of types that can be fully evaluated.

Since: 1.1.0.0

Minimal complete definition

Nothing

Methods

rnf :: a -> () Source

rnf should reduce its argument to normal form (that is, fully evaluate all sub-components), and then return '()'.

The default implementation of rnf is

rnf a = a `seq` ()

which may be convenient when defining instances for data types with no unevaluated fields (e.g. enumerations).

Instances

NFData Bool 
NFData Char 
NFData Double 
NFData Float 
NFData Int 
NFData Int8 
NFData Int16 
NFData Int32 
NFData Int64 
NFData Integer 
NFData Word 
NFData Word8 
NFData Word16 
NFData Word32 
NFData Word64 
NFData () 
NFData Version

Since: 1.3.0.0

NFData a => NFData [a] 
(Integral a, NFData a) => NFData (Ratio a) 
NFData (Fixed a)

Since: 1.3.0.0

(RealFloat a, NFData a) => NFData (Complex a) 
NFData a => NFData (Maybe a) 
NFData (ChanName' a) 
NFData (a -> b)

This instance is for convenience and consistency with seq. This assumes that WHNF is equivalent to NF for functions.

Since: 1.3.0.0

(NFData a, NFData b) => NFData (Either a b) 
(NFData a, NFData b) => NFData (a, b) 
(Ix a, NFData a, NFData b) => NFData (Array a b) 
(NFData k, NFData a) => NFData (Map k a) 
(NFData a, NFData b, NFData c) => NFData (a, b, c) 
(NFData a, NFData b, NFData c, NFData d) => NFData (a, b, c, d) 
(NFData a1, NFData a2, NFData a3, NFData a4, NFData a5) => NFData (a1, a2, a3, a4, a5) 
(NFData a1, NFData a2, NFData a3, NFData a4, NFData a5, NFData a6) => NFData (a1, a2, a3, a4, a5, a6) 
(NFData a1, NFData a2, NFData a3, NFData a4, NFData a5, NFData a6, NFData a7) => NFData (a1, a2, a3, a4, a5, a6, a7) 
(NFData a1, NFData a2, NFData a3, NFData a4, NFData a5, NFData a6, NFData a7, NFData a8) => NFData (a1, a2, a3, a4, a5, a6, a7, a8) 
(NFData a1, NFData a2, NFData a3, NFData a4, NFData a5, NFData a6, NFData a7, NFData a8, NFData a9) => NFData (a1, a2, a3, a4, a5, a6, a7, a8, a9) 

using :: a -> Strategy a -> a infixl 0 Source

Evaluate a value using the given strategy.

r0 :: Strategy a Source

r0 performs *no* evaluation.

rseq :: Strategy a Source

rseq evaluates its argument to weak head normal form.

rdeepseq :: NFData a => Strategy a Source

rdeepseq fully evaluates its argument. Relies on class NFData from module Control.DeepSeq.

seqList :: Strategy a -> Strategy [a] Source

Evaluate each element of a list according to the given strategy. This function is a specialisation of seqFoldable to lists.

seqFoldable :: Foldable t => Strategy a -> Strategy (t a) Source

Evaluate the elements of a foldable data structure according to the given strategy.