| Safe Haskell | None |
|---|---|
| Language | Haskell98 |
Data.Array.Accelerate.Utility.Lift.Run
Description
Simplify running accelerate functions
with multiple curried array and expression arguments.
Documentation
If you have a function:
f :: Exp a -> (Acc b, Acc c) -> (Acc d, Acc e)
you cannot run this immediately using run1,
since run1 expects a function
with a single Acc parameter and a single Acc result.
Using the with function you can just run f as is:
with run1 f :: a -> (b,c) -> (d,e)
with :: C f => ((Acc (Arguments () f) -> Acc (Result f)) -> Arguments () f -> Result f) -> f -> Plain f Source