    -- | @futhark multicore@
    module Futhark.CLI.Multicore (main) where

    import Futhark.Actions (compileMulticoreAction)
    import Futhark.Compiler.CLI
    import Futhark.Passes (mcmemPipeline)

    -- | Run @futhark multicore@.
    main :: String -> [String] -> IO ()
    main :: String -> [String] -> IO ()
    main = ()
    -> [CompilerOption ()]
    -> String
    -> String
    -> Pipeline SOACS MCMem
    -> (FutharkConfig
        -> () -> CompilerMode -> String -> Prog MCMem -> FutharkM ())
    -> String
    -> [String]
    -> IO ()
    forall cfg rep.
    cfg
    -> [CompilerOption cfg]
    -> String
    -> String
    -> Pipeline SOACS rep
    -> (FutharkConfig
        -> cfg -> CompilerMode -> String -> Prog rep -> FutharkM ())
    -> String
    -> [String]
    -> IO ()
    compilerMain
      ()
      []
      String
    "Compile to multicore C"
      String
    "Generate multicore C code from optimised Futhark program."
      Pipeline SOACS MCMem
    mcmemPipeline
      ((FutharkConfig
      -> () -> CompilerMode -> String -> Prog MCMem -> FutharkM ())
     -> String -> [String] -> IO ())
    -> (FutharkConfig
        -> () -> CompilerMode -> String -> Prog MCMem -> FutharkM ())
    -> String
    -> [String]
    -> IO ()
    forall a b. (a -> b) -> a -> b
    $ \FutharkConfig
    fcfg () CompilerMode
    mode String
    outpath Prog MCMem
    prog ->
        Action MCMem -> Prog MCMem -> FutharkM ()
    forall rep. Action rep -> Prog rep -> FutharkM ()
    actionProcedure (FutharkConfig -> CompilerMode -> String -> Action MCMem
    compileMulticoreAction FutharkConfig
    fcfg CompilerMode
    mode String
    outpath) Prog MCMem
    prog