packages feed

futhask-base 0.2.0.0 → 0.2.1.0

raw patch · 3 files changed

+10/−4 lines, 3 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

+ Futhask.Context: DefaultNumGroups :: Int -> ContextOption
+ Futhask.Context: setDefaultNumGroups :: Context c => Ptr (RawConfig c) -> Int -> IO ()

Files

ChangeLog.md view
@@ -1,4 +1,7 @@ # Changelog for futhask-base ## 0.2.0 Change name of `load` to `loadM`, and add new `load` that emits error instead of wrapping in `Maybe` +## 0.2.1+Fix num_groups context option+ ## Unreleased changes
futhask-base.cabal view
@@ -1,7 +1,7 @@ cabal-version: 1.12  name:           futhask-base-version:        0.2.0.0+version:        0.2.1.0 stability:      experimental category:       FFI synopsis:       Base library for libraries generated by futhask
src/Futhask/Context.hs view
@@ -56,6 +56,7 @@     | DefaultThreadBlockSize Int -- ^GPU backends     | DefaultGridSize Int -- ^GPU backends     | DefaultTileSize Int -- ^GPU backends+    | DefaultNumGroups Int -- ^GPU backends     | Platform String -- ^OpenCL     | BuildOptions [String] -- ^OpenCL     | NvrtcOptions [String] -- ^Cuda@@ -94,6 +95,7 @@     setDefaultThreadBlockSize :: Ptr (RawConfig c) -> Int -> IO ()     setDefaultGridSize    :: Ptr (RawConfig c) -> Int -> IO ()     setDefaultTileSize    :: Ptr (RawConfig c) -> Int -> IO ()+    setDefaultNumGroups   :: Ptr (RawConfig c) -> Int -> IO ()     -- OpenCL options     setPlatform    :: Ptr (RawConfig c) -> CString -> IO ()     --setLoadBinary  :: Ptr (RawConfig c) -> CString -> IO ()@@ -120,9 +122,10 @@     Log i     -> nofin $ setLog     config i     Profile i -> nofin $ setProfile config i     Device s -> nofin $ withCString s (setDevice config)-    DefaultThreadBlockSize s -> nofin $ setDefaultThreadBlockSize config s-    DefaultGridSize s        -> nofin $ setDefaultGridSize        config s-    DefaultTileSize s        -> nofin $ setDefaultTileSize        config s+    DefaultThreadBlockSize s  -> nofin $ setDefaultThreadBlockSize config s+    DefaultGridSize s         -> nofin $ setDefaultGridSize        config s+    DefaultTileSize s         -> nofin $ setDefaultTileSize        config s+    DefaultNumGroups s        -> nofin $ setDefaultNumGroups       config s     Platform p    -> nofin $ withCString p  (setPlatform   config)     BuildOptions os -> nofin $ mapM_ (\o -> withCString o (setBuildOption config)) os     NvrtcOptions os -> nofin $ mapM_ (\o -> withCString o (setNvrtcOption config)) os