Safe Haskell | None |
---|---|
Language | Haskell98 |
- data F
- fromForeignPtr :: Shape sh => sh -> ForeignPtr e -> Array F sh e
- toForeignPtr :: Array F sh e -> ForeignPtr e
- computeIntoS :: (Load r1 sh e, Storable e) => ForeignPtr e -> Array r1 sh e -> IO ()
- computeIntoP :: (Load r1 sh e, Storable e) => ForeignPtr e -> Array r1 sh e -> IO ()
Documentation
Arrays represented as foreign buffers in the C heap.
fromForeignPtr :: Shape sh => sh -> ForeignPtr e -> Array F sh e #
O(1). Wrap a ForeignPtr
as an array.
toForeignPtr :: Array F sh e -> ForeignPtr e #
O(1). Unpack a ForeignPtr
from an array.
computeIntoS :: (Load r1 sh e, Storable e) => ForeignPtr e -> Array r1 sh e -> IO () #
Compute an array sequentially and write the elements into a foreign
buffer without intermediate copying. If you want to copy a
pre-existing manifest array to a foreign buffer then delay
it first.
computeIntoP :: (Load r1 sh e, Storable e) => ForeignPtr e -> Array r1 sh e -> IO () #
Compute an array in parallel and write the elements into a foreign
buffer without intermediate copying. If you want to copy a
pre-existing manifest array to a foreign buffer then delay
it first.