 | dph-base-0.3: Basic Definitions for Data-Parallel Haskell. | Contents | Index |
|
| Data.Array.Parallel.Stream | | Portability | non-portable (existentials) | | Stability | internal | | Maintainer | Roman Leshchinskiy <rl@cse.unsw.edu.au> |
|
|
|
| Description |
| This module defined the interface to the stream library used for loop
fusion.
|
|
| Synopsis |
|
|
|
| Documentation |
|
| data Step s a |
| Constructors | | Instances | |
|
|
| data Stream a |
|
|
| emptyS :: Stream a |
| Empty stream
|
|
| singletonS :: a -> Stream a |
| Singleton stream
|
|
| consS :: a -> Stream a -> Stream a |
| Construction
|
|
| replicateS :: Int -> a -> Stream a |
| Replication
|
|
| replicateEachS :: Int -> Stream (Int :*: a) -> Stream a |
| Given a stream of (length,value) pairs and the sum of the lengths,
replicate each value to the given length.
|
|
| (+++) :: Stream a -> Stream a -> Stream a |
| Concatenation
|
|
| indexedS :: Stream a -> Stream (Int :*: a) |
| Associate each element in the Stream with its index
|
|
| tailS :: Stream a -> Stream a |
| Yield the tail of a stream
|
|
| enumFromToS :: Int -> Int -> Stream Int |
| Yield an enumerated stream
|
|
| enumFromThenToS :: Int -> Int -> Int -> Stream Int |
| Yield an enumerated stream using a specific step
|
|
| enumFromStepLenS :: Int -> Int -> Int -> Stream Int |
|
| enumFromToEachS :: Int -> Stream (Int :*: Int) -> Stream Int |
enumFromToEachS [k1 :*: m1, ..., kn :*: mn] = [k1,...,m1,...,kn,...,mn] |
|
| toStream :: [a] -> Stream a |
| Convert a list to a Stream
|
|
| fromStream :: Stream a -> [a] |
| Generate a list from a Stream
|
|
| mapS :: (a -> b) -> Stream a -> Stream b |
| Mapping
|
|
| filterS :: (a -> Bool) -> Stream a -> Stream a |
| Filtering
|
|
| foldS :: (b -> a -> b) -> b -> Stream a -> b |
| Folding
|
|
| fold1MaybeS :: (a -> a -> a) -> Stream a -> MaybeS a |
| Yield NothingS if the Stream is empty and fold it otherwise.
|
|
| scanS :: (b -> a -> b) -> b -> Stream a -> Stream b |
| Scanning
|
|
| scan1S :: (a -> a -> a) -> Stream a -> Stream a |
| Scan over a non-empty Stream
|
|
| mapAccumS :: (acc -> a -> acc :*: b) -> acc -> Stream a -> Stream b |
|
| zipWithS :: (a -> b -> c) -> Stream a -> Stream b -> Stream c |
| Zipping
|
|
| zipWith3S :: (a -> b -> c -> d) -> Stream a -> Stream b -> Stream c -> Stream d |
|
| zipS :: Stream a -> Stream b -> Stream (a :*: b) |
|
| combineS :: Stream Bool -> Stream a -> Stream a -> Stream a |
|
| findS :: (a -> Bool) -> Stream a -> Maybe a |
|
| findIndexS :: (a -> Bool) -> Stream a -> Maybe Int |
|
| randomS :: (RandomGen g, Random a) => Int -> g -> Stream a |
|
| randomRS :: (RandomGen g, Random a) => Int -> (a, a) -> g -> Stream a |
|
| data SStream a |
|
|
| segmentS :: Stream Int -> Stream a -> SStream a |
|
| foldValuesSS :: (a -> b -> a) -> a -> SStream b -> Stream a |
|
| fold1ValuesSS :: (a -> a -> a) -> SStream a -> Stream a |
|
| combineSS :: Stream Bool -> SStream a -> SStream a -> Stream a |
|
| (^+++^) :: SStream a -> SStream a -> Stream a |
|
| Produced by Haddock version 2.3.0 |