summaryrefslogtreecommitdiff
path: root/packages/base/src/Numeric/Vectorized.hs
diff options
context:
space:
mode:
Diffstat (limited to 'packages/base/src/Numeric/Vectorized.hs')
-rw-r--r--packages/base/src/Numeric/Vectorized.hs12
1 files changed, 11 insertions, 1 deletions
diff --git a/packages/base/src/Numeric/Vectorized.hs b/packages/base/src/Numeric/Vectorized.hs
index 5aebb14..82504a9 100644
--- a/packages/base/src/Numeric/Vectorized.hs
+++ b/packages/base/src/Numeric/Vectorized.hs
@@ -18,7 +18,8 @@ module Numeric.Vectorized (
18 FunCodeSV(..), vectorMapValR, vectorMapValC, vectorMapValF, vectorMapValQ, 18 FunCodeSV(..), vectorMapValR, vectorMapValC, vectorMapValF, vectorMapValQ,
19 FunCodeVV(..), vectorZipR, vectorZipC, vectorZipF, vectorZipQ, 19 FunCodeVV(..), vectorZipR, vectorZipC, vectorZipF, vectorZipQ,
20 vectorScan, saveMatrix, 20 vectorScan, saveMatrix,
21 Seed, RandDist(..), randomVector 21 Seed, RandDist(..), randomVector,
22 sortVector
22) where 23) where
23 24
24import Data.Packed.Internal.Common 25import Data.Packed.Internal.Common
@@ -344,3 +345,12 @@ randomVector seed dist n = unsafePerformIO $ do
344 345
345foreign import ccall unsafe "random_vector" c_random_vector :: CInt -> CInt -> TV 346foreign import ccall unsafe "random_vector" c_random_vector :: CInt -> CInt -> TV
346 347
348--------------------------------------------------------------------------------
349
350sortVector v = unsafePerformIO $ do
351 r <- createVector (dim v)
352 app2 c_sort_values vec v vec r "sortVector"
353 return r
354
355foreign import ccall unsafe "sort_values" c_sort_values :: TVV
356