| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Futhark.Test.Compile
Description
Compiling Futhark programs and running them as servers, as needed for testing and benchmarking, but also by anything else that runs compiled programs.
Synopsis
- newtype FutharkExe = FutharkExe FilePath
- binaryName :: FilePath -> FilePath
- compileProgram :: (MonadIO m, MonadError Text m) => [String] -> FutharkExe -> String -> FilePath -> m (ByteString, ByteString)
- futharkServerCfg :: FilePath -> [String] -> ServerCfg
Documentation
newtype FutharkExe Source #
The futhark executable we are using. This is merely a wrapper
around the underlying file path, because we will be using a lot of
different file paths here, and it is easy to mix them up.
Constructors
| FutharkExe FilePath |
Instances
| Show FutharkExe Source # | |
Defined in Futhark.Test.Compile Methods showsPrec :: Int -> FutharkExe -> ShowS # show :: FutharkExe -> String # showList :: [FutharkExe] -> ShowS # | |
| Eq FutharkExe Source # | |
Defined in Futhark.Test.Compile | |
| Ord FutharkExe Source # | |
Defined in Futhark.Test.Compile Methods compare :: FutharkExe -> FutharkExe -> Ordering # (<) :: FutharkExe -> FutharkExe -> Bool # (<=) :: FutharkExe -> FutharkExe -> Bool # (>) :: FutharkExe -> FutharkExe -> Bool # (>=) :: FutharkExe -> FutharkExe -> Bool # max :: FutharkExe -> FutharkExe -> FutharkExe # min :: FutharkExe -> FutharkExe -> FutharkExe # | |
binaryName :: FilePath -> FilePath Source #
The name we use for compiled programs.
compileProgram :: (MonadIO m, MonadError Text m) => [String] -> FutharkExe -> String -> FilePath -> m (ByteString, ByteString) Source #
compileProgram extra_options futhark backend program compiles
program with the command futhark backend extra-options..., and
returns stdout and stderr of the compiler. Throws an IO exception
containing stderr if compilation fails.