futhark 0.25.31 → 0.25.32
raw patch · 160 files changed
+4686/−4095 lines, 160 filesdep +criteriondep ~basedep ~futhark-datadep ~srclocPVP: major bump suggested
API removals or changes: PVP suggests a major version bump
Dependencies added: criterion
Dependency ranges changed: base, futhark-data, srcloc
API changes (from Hackage documentation)
- Futhark.AD.Derivatives: pdBinOp :: BinOp -> PrimExp VName -> PrimExp VName -> (PrimExp VName, PrimExp VName)
- Futhark.AD.Derivatives: pdBuiltin :: Name -> [PrimExp VName] -> Maybe [PrimExp VName]
- Futhark.AD.Derivatives: pdUnOp :: UnOp -> PrimExp VName -> PrimExp VName
- Futhark.AD.Fwd: fwdJVP :: MonadFreshNames m => Scope SOACS -> Lambda SOACS -> m (Lambda SOACS)
- Futhark.AD.Fwd: instance Control.Monad.State.Class.MonadState Futhark.AD.Fwd.RState Futhark.AD.Fwd.ADM
- Futhark.AD.Fwd: instance Futhark.AD.Fwd.TanBuilder (Futhark.IR.Syntax.Core.Param (Futhark.IR.Syntax.Core.TypeBase s u))
- Futhark.AD.Fwd: instance Futhark.AD.Fwd.TanBuilder (Futhark.IR.Syntax.Core.PatElem (Futhark.IR.Syntax.Core.TypeBase s u))
- Futhark.AD.Fwd: instance Futhark.AD.Fwd.Tangent (Futhark.IR.Syntax.Core.TypeBase s u)
- Futhark.AD.Fwd: instance Futhark.AD.Fwd.Tangent Futhark.IR.Syntax.Core.SubExp
- Futhark.AD.Fwd: instance Futhark.AD.Fwd.Tangent Futhark.IR.Syntax.SubExpRes
- Futhark.AD.Fwd: instance Futhark.AD.Fwd.Tangent Language.Futhark.Core.VName
- Futhark.AD.Fwd: instance Futhark.AD.Fwd.Tangent a => Futhark.AD.Fwd.TanBuilder (Futhark.IR.Syntax.Core.Param (Futhark.IR.Syntax.Core.TypeBase s u), a)
- Futhark.AD.Fwd: instance Futhark.Builder.Class.MonadBuilder Futhark.AD.Fwd.ADM
- Futhark.AD.Fwd: instance Futhark.IR.Prop.Scope.HasScope Futhark.IR.SOACS.SOACS Futhark.AD.Fwd.ADM
- Futhark.AD.Fwd: instance Futhark.IR.Prop.Scope.LocalScope Futhark.IR.SOACS.SOACS Futhark.AD.Fwd.ADM
- Futhark.AD.Fwd: instance Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.State.Strict.State Futhark.AD.Fwd.RState)
- Futhark.AD.Fwd: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.AD.Fwd.ADM
- Futhark.AD.Fwd: instance GHC.Base.Applicative Futhark.AD.Fwd.ADM
- Futhark.AD.Fwd: instance GHC.Base.Functor Futhark.AD.Fwd.ADM
- Futhark.AD.Fwd: instance GHC.Base.Monad Futhark.AD.Fwd.ADM
- Futhark.AD.Rev: revVJP :: MonadFreshNames m => Scope SOACS -> Lambda SOACS -> m (Lambda SOACS)
- Futhark.AD.Rev.Hist: diffAddHist :: VjpOps -> VName -> StmAux () -> SubExp -> Lambda SOACS -> SubExp -> VName -> VName -> SubExp -> SubExp -> VName -> ADM () -> ADM ()
- Futhark.AD.Rev.Hist: diffHist :: VjpOps -> [VName] -> StmAux () -> SubExp -> Lambda SOACS -> [SubExp] -> [VName] -> [SubExp] -> SubExp -> [VName] -> ADM () -> ADM ()
- Futhark.AD.Rev.Hist: diffMinMaxHist :: VjpOps -> VName -> StmAux () -> SubExp -> BinOp -> SubExp -> VName -> VName -> SubExp -> SubExp -> VName -> ADM () -> ADM ()
- Futhark.AD.Rev.Hist: diffMulHist :: VjpOps -> VName -> StmAux () -> SubExp -> BinOp -> SubExp -> VName -> VName -> SubExp -> SubExp -> VName -> ADM () -> ADM ()
- Futhark.AD.Rev.Hist: diffVecHist :: VjpOps -> VName -> StmAux () -> SubExp -> Lambda SOACS -> VName -> VName -> VName -> SubExp -> SubExp -> VName -> ADM () -> ADM ()
- Futhark.AD.Rev.Loop: diffLoop :: (Stms SOACS -> ADM ()) -> Pat Type -> StmAux () -> Exp SOACS -> ADM () -> ADM ()
- Futhark.AD.Rev.Loop: instance Data.Foldable.Foldable Futhark.AD.Rev.Loop.LoopInfo
- Futhark.AD.Rev.Loop: instance Data.Traversable.Traversable Futhark.AD.Rev.Loop.LoopInfo
- Futhark.AD.Rev.Loop: instance GHC.Base.Functor Futhark.AD.Rev.Loop.LoopInfo
- Futhark.AD.Rev.Loop: instance GHC.Show.Show a => GHC.Show.Show (Futhark.AD.Rev.Loop.LoopInfo a)
- Futhark.AD.Rev.Loop: stripmineStms :: Stms SOACS -> ADM (Stms SOACS)
- Futhark.AD.Rev.Map: vjpMap :: VjpOps -> [Adj] -> StmAux () -> SubExp -> Lambda SOACS -> [VName] -> ADM ()
- Futhark.AD.Rev.Monad: AdjSparse :: Sparse -> Adj
- Futhark.AD.Rev.Monad: AdjVal :: SubExp -> Adj
- Futhark.AD.Rev.Monad: AdjZero :: Shape -> PrimType -> Adj
- Futhark.AD.Rev.Monad: AssumeBounds :: InBounds
- Futhark.AD.Rev.Monad: CheckBounds :: Maybe SubExp -> InBounds
- Futhark.AD.Rev.Monad: OutOfBounds :: InBounds
- Futhark.AD.Rev.Monad: RState :: Map VName Adj -> Substitutions -> Substitutions -> VNameSource -> RState
- Futhark.AD.Rev.Monad: Sparse :: Shape -> PrimType -> [(InBounds, SubExp, SubExp)] -> Sparse
- Futhark.AD.Rev.Monad: VjpOps :: ([Adj] -> [VName] -> Lambda SOACS -> ADM (Lambda SOACS)) -> (Stm SOACS -> ADM () -> ADM ()) -> VjpOps
- Futhark.AD.Rev.Monad: [sparseIdxVals] :: Sparse -> [(InBounds, SubExp, SubExp)]
- Futhark.AD.Rev.Monad: [sparseShape] :: Sparse -> Shape
- Futhark.AD.Rev.Monad: [sparseType] :: Sparse -> PrimType
- Futhark.AD.Rev.Monad: [stateAdjs] :: RState -> Map VName Adj
- Futhark.AD.Rev.Monad: [stateLoopTape] :: RState -> Substitutions
- Futhark.AD.Rev.Monad: [stateNameSource] :: RState -> VNameSource
- Futhark.AD.Rev.Monad: [stateSubsts] :: RState -> Substitutions
- Futhark.AD.Rev.Monad: [vjpLambda] :: VjpOps -> [Adj] -> [VName] -> Lambda SOACS -> ADM (Lambda SOACS)
- Futhark.AD.Rev.Monad: [vjpStm] :: VjpOps -> Stm SOACS -> ADM () -> ADM ()
- Futhark.AD.Rev.Monad: addLambda :: Type -> ADM (Lambda SOACS)
- Futhark.AD.Rev.Monad: addSubstitution :: VName -> VName -> ADM ()
- Futhark.AD.Rev.Monad: adjFromParam :: Param t -> Adj
- Futhark.AD.Rev.Monad: adjFromVar :: VName -> Adj
- Futhark.AD.Rev.Monad: adjVName :: VName -> ADM VName
- Futhark.AD.Rev.Monad: adjVal :: Adj -> ADM VName
- Futhark.AD.Rev.Monad: adjsReps :: [Adj] -> ([SubExp], [SubExp] -> [Adj])
- Futhark.AD.Rev.Monad: copyConsumedArrsInBody :: [VName] -> Body SOACS -> ADM Substitutions
- Futhark.AD.Rev.Monad: copyConsumedArrsInStm :: Stm SOACS -> ADM (Substitutions, Stms SOACS)
- Futhark.AD.Rev.Monad: data ADM a
- Futhark.AD.Rev.Monad: data Adj
- Futhark.AD.Rev.Monad: data InBounds
- Futhark.AD.Rev.Monad: data RState
- Futhark.AD.Rev.Monad: data Sparse
- Futhark.AD.Rev.Monad: data VjpOps
- Futhark.AD.Rev.Monad: insAdj :: VName -> VName -> ADM ()
- Futhark.AD.Rev.Monad: instance Control.Monad.State.Class.MonadState Futhark.AD.Rev.Monad.RState Futhark.AD.Rev.Monad.ADM
- Futhark.AD.Rev.Monad: instance Futhark.Builder.Class.MonadBuilder Futhark.AD.Rev.Monad.ADM
- Futhark.AD.Rev.Monad: instance Futhark.IR.Prop.Scope.HasScope Futhark.IR.SOACS.SOACS Futhark.AD.Rev.Monad.ADM
- Futhark.AD.Rev.Monad: instance Futhark.IR.Prop.Scope.LocalScope Futhark.IR.SOACS.SOACS Futhark.AD.Rev.Monad.ADM
- Futhark.AD.Rev.Monad: instance Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.State.Strict.State Futhark.AD.Rev.Monad.RState)
- Futhark.AD.Rev.Monad: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.AD.Rev.Monad.ADM
- Futhark.AD.Rev.Monad: instance Futhark.Transform.Substitute.Substitute Futhark.AD.Rev.Monad.Adj
- Futhark.AD.Rev.Monad: instance GHC.Base.Applicative Futhark.AD.Rev.Monad.ADM
- Futhark.AD.Rev.Monad: instance GHC.Base.Functor Futhark.AD.Rev.Monad.ADM
- Futhark.AD.Rev.Monad: instance GHC.Base.Monad Futhark.AD.Rev.Monad.ADM
- Futhark.AD.Rev.Monad: instance GHC.Classes.Eq Futhark.AD.Rev.Monad.Adj
- Futhark.AD.Rev.Monad: instance GHC.Classes.Eq Futhark.AD.Rev.Monad.InBounds
- Futhark.AD.Rev.Monad: instance GHC.Classes.Eq Futhark.AD.Rev.Monad.Sparse
- Futhark.AD.Rev.Monad: instance GHC.Classes.Ord Futhark.AD.Rev.Monad.Adj
- Futhark.AD.Rev.Monad: instance GHC.Classes.Ord Futhark.AD.Rev.Monad.InBounds
- Futhark.AD.Rev.Monad: instance GHC.Classes.Ord Futhark.AD.Rev.Monad.Sparse
- Futhark.AD.Rev.Monad: instance GHC.Show.Show Futhark.AD.Rev.Monad.Adj
- Futhark.AD.Rev.Monad: instance GHC.Show.Show Futhark.AD.Rev.Monad.InBounds
- Futhark.AD.Rev.Monad: instance GHC.Show.Show Futhark.AD.Rev.Monad.Sparse
- Futhark.AD.Rev.Monad: isActive :: VName -> ADM Bool
- Futhark.AD.Rev.Monad: lookupAdj :: VName -> ADM Adj
- Futhark.AD.Rev.Monad: lookupAdjVal :: VName -> ADM VName
- Futhark.AD.Rev.Monad: lookupLoopTape :: VName -> ADM (Maybe VName)
- Futhark.AD.Rev.Monad: noAdjsFor :: Names -> ADM a -> ADM a
- Futhark.AD.Rev.Monad: oneExp :: Type -> Exp rep
- Futhark.AD.Rev.Monad: renameLoopTape :: Substitutions -> ADM ()
- Futhark.AD.Rev.Monad: returnSweepCode :: ADM a -> ADM a
- Futhark.AD.Rev.Monad: runADM :: MonadFreshNames m => ADM a -> m a
- Futhark.AD.Rev.Monad: setAdj :: VName -> Adj -> ADM ()
- Futhark.AD.Rev.Monad: setLoopTape :: VName -> VName -> ADM ()
- Futhark.AD.Rev.Monad: subAD :: ADM a -> ADM a
- Futhark.AD.Rev.Monad: subSubsts :: ADM a -> ADM a
- Futhark.AD.Rev.Monad: substLoopTape :: VName -> VName -> ADM ()
- Futhark.AD.Rev.Monad: tabNest :: Int -> [VName] -> ([VName] -> [VName] -> ADM [VName]) -> ADM [VName]
- Futhark.AD.Rev.Monad: unitAdjOfType :: Type -> ADM Adj
- Futhark.AD.Rev.Monad: updateAdj :: VName -> VName -> ADM ()
- Futhark.AD.Rev.Monad: updateAdjIndex :: VName -> (InBounds, SubExp) -> SubExp -> ADM ()
- Futhark.AD.Rev.Monad: updateAdjSlice :: Slice SubExp -> VName -> VName -> ADM ()
- Futhark.AD.Rev.Monad: updateSubExpAdj :: SubExp -> VName -> ADM ()
- Futhark.AD.Rev.Monad: zeroExp :: Type -> Exp rep
- Futhark.AD.Rev.Reduce: diffMinMaxReduce :: VjpOps -> VName -> StmAux () -> SubExp -> BinOp -> SubExp -> VName -> ADM () -> ADM ()
- Futhark.AD.Rev.Reduce: diffMulReduce :: VjpOps -> VName -> StmAux () -> SubExp -> BinOp -> SubExp -> VName -> ADM () -> ADM ()
- Futhark.AD.Rev.Reduce: diffReduce :: VjpOps -> [VName] -> SubExp -> [VName] -> Reduce SOACS -> ADM ()
- Futhark.AD.Rev.Reduce: diffVecReduce :: VjpOps -> Pat Type -> StmAux () -> SubExp -> Commutativity -> Lambda SOACS -> VName -> VName -> ADM () -> ADM ()
- Futhark.AD.Rev.SOAC: vjpSOAC :: VjpOps -> Pat Type -> StmAux () -> SOAC SOACS -> ADM () -> ADM ()
- Futhark.AD.Rev.Scan: diffScan :: VjpOps -> [VName] -> SubExp -> [VName] -> Scan SOACS -> ADM ()
- Futhark.AD.Rev.Scan: diffScanAdd :: VjpOps -> VName -> SubExp -> Lambda SOACS -> SubExp -> VName -> ADM ()
- Futhark.AD.Rev.Scan: diffScanVec :: VjpOps -> [VName] -> StmAux () -> SubExp -> Lambda SOACS -> [SubExp] -> [VName] -> ADM () -> ADM ()
- Futhark.AD.Rev.Scan: instance GHC.Show.Show Futhark.AD.Rev.Scan.ScanAlgo
- Futhark.AD.Rev.Scan: instance GHC.Show.Show Futhark.AD.Rev.Scan.Special
- Futhark.AD.Rev.Scan: instance GHC.Show.Show Futhark.AD.Rev.Scan.SpecialCase
- Futhark.AD.Rev.Scatter: vjpScatter :: VjpOps -> Pat Type -> StmAux () -> (SubExp, [VName], Lambda SOACS, [(Shape, Int, VName)]) -> ADM () -> ADM ()
- Futhark.Actions: callGraphAction :: Action SOACS
- Futhark.Actions: compileCAction :: FutharkConfig -> CompilerMode -> FilePath -> Action SeqMem
- Futhark.Actions: compileCUDAAction :: FutharkConfig -> CompilerMode -> FilePath -> Action GPUMem
- Futhark.Actions: compileCtoWASMAction :: FutharkConfig -> CompilerMode -> FilePath -> Action SeqMem
- Futhark.Actions: compileHIPAction :: FutharkConfig -> CompilerMode -> FilePath -> Action GPUMem
- Futhark.Actions: compileMulticoreAction :: FutharkConfig -> CompilerMode -> FilePath -> Action MCMem
- Futhark.Actions: compileMulticoreToISPCAction :: FutharkConfig -> CompilerMode -> FilePath -> Action MCMem
- Futhark.Actions: compileMulticoreToWASMAction :: FutharkConfig -> CompilerMode -> FilePath -> Action MCMem
- Futhark.Actions: compileOpenCLAction :: FutharkConfig -> CompilerMode -> FilePath -> Action GPUMem
- Futhark.Actions: compilePyOpenCLAction :: FutharkConfig -> CompilerMode -> FilePath -> Action GPUMem
- Futhark.Actions: compilePythonAction :: FutharkConfig -> CompilerMode -> FilePath -> Action SeqMem
- Futhark.Actions: impCodeGenAction :: Action SeqMem
- Futhark.Actions: kernelImpCodeGenAction :: Action GPUMem
- Futhark.Actions: metricsAction :: OpMetrics (Op rep) => Action rep
- Futhark.Actions: multicoreImpCodeGenAction :: Action MCMem
- Futhark.Actions: printAction :: ASTRep rep => Action rep
- Futhark.Actions: printAliasesAction :: AliasableRep rep => Action rep
- Futhark.Actions: printFusionGraph :: Action SOACS
- Futhark.Actions: printInterferenceGPU :: Action GPUMem
- Futhark.Actions: printLastUseGPU :: Action GPUMem
- Futhark.Actions: printMemAliasGPU :: Action GPUMem
- Futhark.Actions: printMemoryAccessAnalysis :: Analyse rep => Action rep
- Futhark.Analysis.AccessPattern: CondBodyName :: VName -> BodyType
- Futhark.Analysis.AccessPattern: ConstType :: VarType
- Futhark.Analysis.AccessPattern: Context :: Map VName (VariableInfo rep) -> Map IndexExprName (ArrayName, [VName], [DimAccess rep]) -> [BodyType] -> Int -> Context (rep :: k)
- Futhark.Analysis.AccessPattern: Dependency :: Int -> VarType -> Dependency
- Futhark.Analysis.AccessPattern: DimAccess :: Map VName Dependency -> Maybe VName -> DimAccess (rep :: k)
- Futhark.Analysis.AccessPattern: LoopBodyName :: VName -> BodyType
- Futhark.Analysis.AccessPattern: LoopVar :: VarType
- Futhark.Analysis.AccessPattern: SegOpName :: SegOpName -> BodyType
- Futhark.Analysis.AccessPattern: SegmentedHist :: VName -> SegOpName
- Futhark.Analysis.AccessPattern: SegmentedMap :: VName -> SegOpName
- Futhark.Analysis.AccessPattern: SegmentedRed :: VName -> SegOpName
- Futhark.Analysis.AccessPattern: SegmentedScan :: VName -> SegOpName
- Futhark.Analysis.AccessPattern: ThreadID :: VarType
- Futhark.Analysis.AccessPattern: Variable :: VarType
- Futhark.Analysis.AccessPattern: VariableInfo :: Names -> Int -> [BodyType] -> VarType -> VariableInfo (rep :: k)
- Futhark.Analysis.AccessPattern: [assignments] :: Context (rep :: k) -> Map VName (VariableInfo rep)
- Futhark.Analysis.AccessPattern: [currentLevel] :: Context (rep :: k) -> Int
- Futhark.Analysis.AccessPattern: [dependencies] :: DimAccess (rep :: k) -> Map VName Dependency
- Futhark.Analysis.AccessPattern: [deps] :: VariableInfo (rep :: k) -> Names
- Futhark.Analysis.AccessPattern: [level] :: VariableInfo (rep :: k) -> Int
- Futhark.Analysis.AccessPattern: [lvl] :: Dependency -> Int
- Futhark.Analysis.AccessPattern: [originalVar] :: DimAccess (rep :: k) -> Maybe VName
- Futhark.Analysis.AccessPattern: [parents] :: Context (rep :: k) -> [BodyType]
- Futhark.Analysis.AccessPattern: [parents_nest] :: VariableInfo (rep :: k) -> [BodyType]
- Futhark.Analysis.AccessPattern: [slices] :: Context (rep :: k) -> Map IndexExprName (ArrayName, [VName], [DimAccess rep])
- Futhark.Analysis.AccessPattern: [varType] :: Dependency -> VarType
- Futhark.Analysis.AccessPattern: [variableType] :: VariableInfo (rep :: k) -> VarType
- Futhark.Analysis.AccessPattern: analyseDimAccesses :: Analyse rep => Prog rep -> IndexTable rep
- Futhark.Analysis.AccessPattern: analyseFunction :: Analyse rep => FunDef rep -> IndexTable rep
- Futhark.Analysis.AccessPattern: analyseIndex :: forall {k} (rep :: k). Context rep -> [VName] -> VName -> [DimIndex SubExp] -> (Context rep, IndexTable rep)
- Futhark.Analysis.AccessPattern: analysisPropagateByTransitivity :: forall {k} (rep :: k). IndexTable rep -> IndexTable rep
- Futhark.Analysis.AccessPattern: class Analyse rep
- Futhark.Analysis.AccessPattern: data BodyType
- Futhark.Analysis.AccessPattern: data Context (rep :: k)
- Futhark.Analysis.AccessPattern: data Dependency
- Futhark.Analysis.AccessPattern: data DimAccess (rep :: k)
- Futhark.Analysis.AccessPattern: data SegOpName
- Futhark.Analysis.AccessPattern: data VarType
- Futhark.Analysis.AccessPattern: data VariableInfo (rep :: k)
- Futhark.Analysis.AccessPattern: instance Futhark.Analysis.AccessPattern.Analyse Futhark.IR.GPU.GPU
- Futhark.Analysis.AccessPattern: instance Futhark.Analysis.AccessPattern.Analyse Futhark.IR.GPUMem.GPUMem
- Futhark.Analysis.AccessPattern: instance Futhark.Analysis.AccessPattern.Analyse Futhark.IR.MC.MC
- Futhark.Analysis.AccessPattern: instance Futhark.Analysis.AccessPattern.Analyse Futhark.IR.MCMem.MCMem
- Futhark.Analysis.AccessPattern: instance Futhark.Analysis.AccessPattern.Analyse Futhark.IR.SOACS.SOACS
- Futhark.Analysis.AccessPattern: instance Futhark.Analysis.AccessPattern.Analyse Futhark.IR.Seq.Seq
- Futhark.Analysis.AccessPattern: instance Futhark.Analysis.AccessPattern.Analyse Futhark.IR.SeqMem.SeqMem
- Futhark.Analysis.AccessPattern: instance GHC.Classes.Eq Futhark.Analysis.AccessPattern.BodyType
- Futhark.Analysis.AccessPattern: instance GHC.Classes.Eq Futhark.Analysis.AccessPattern.Dependency
- Futhark.Analysis.AccessPattern: instance GHC.Classes.Eq Futhark.Analysis.AccessPattern.SegOpName
- Futhark.Analysis.AccessPattern: instance GHC.Classes.Eq Futhark.Analysis.AccessPattern.VarType
- Futhark.Analysis.AccessPattern: instance GHC.Classes.Ord Futhark.Analysis.AccessPattern.BodyType
- Futhark.Analysis.AccessPattern: instance GHC.Classes.Ord Futhark.Analysis.AccessPattern.SegOpName
- Futhark.Analysis.AccessPattern: instance GHC.Show.Show Futhark.Analysis.AccessPattern.BodyType
- Futhark.Analysis.AccessPattern: instance GHC.Show.Show Futhark.Analysis.AccessPattern.Dependency
- Futhark.Analysis.AccessPattern: instance GHC.Show.Show Futhark.Analysis.AccessPattern.SegOpName
- Futhark.Analysis.AccessPattern: instance GHC.Show.Show Futhark.Analysis.AccessPattern.VarType
- Futhark.Analysis.AccessPattern: instance Prettyprinter.Internal.Pretty Futhark.Analysis.AccessPattern.BodyType
- Futhark.Analysis.AccessPattern: instance Prettyprinter.Internal.Pretty Futhark.Analysis.AccessPattern.SegOpName
- Futhark.Analysis.AccessPattern: instance Prettyprinter.Internal.Pretty Futhark.Analysis.AccessPattern.VarType
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Base.Monoid (Futhark.Analysis.AccessPattern.Context rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Base.Monoid (Futhark.Analysis.AccessPattern.DimAccess rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Base.Semigroup (Futhark.Analysis.AccessPattern.Context rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Base.Semigroup (Futhark.Analysis.AccessPattern.DimAccess rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Classes.Eq (Futhark.Analysis.AccessPattern.Context rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Classes.Eq (Futhark.Analysis.AccessPattern.DimAccess rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Classes.Eq (Futhark.Analysis.AccessPattern.VariableInfo rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Show.Show (Futhark.Analysis.AccessPattern.Context rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Show.Show (Futhark.Analysis.AccessPattern.DimAccess rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). GHC.Show.Show (Futhark.Analysis.AccessPattern.VariableInfo rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). Prettyprinter.Internal.Pretty (Futhark.Analysis.AccessPattern.DimAccess rep)
- Futhark.Analysis.AccessPattern: instance forall k (rep :: k). Prettyprinter.Internal.Pretty (Futhark.Analysis.AccessPattern.IndexTable rep)
- Futhark.Analysis.AccessPattern: isCounter :: VarType -> Bool
- Futhark.Analysis.AccessPattern: isInvariant :: forall {k} (rep :: k). DimAccess rep -> Bool
- Futhark.Analysis.AccessPattern: type ArrayName = (VName, [BodyType], [Int])
- Futhark.Analysis.AccessPattern: type IndexExprName = VName
- Futhark.Analysis.AccessPattern: type IndexTable (rep :: k) = Map SegOpName Map ArrayName Map IndexExprName [DimAccess rep]
- Futhark.Analysis.AccessPattern: vnameFromSegOp :: SegOpName -> VName
- Futhark.Analysis.AlgSimplify: Prod :: Bool -> [Exp] -> Prod
- Futhark.Analysis.AlgSimplify: [atoms] :: Prod -> [Exp]
- Futhark.Analysis.AlgSimplify: [negated] :: Prod -> Bool
- Futhark.Analysis.AlgSimplify: add :: SofP -> SofP -> SofP
- Futhark.Analysis.AlgSimplify: compareComplexity :: SofP -> SofP -> Ordering
- Futhark.Analysis.AlgSimplify: data Prod
- Futhark.Analysis.AlgSimplify: instance GHC.Classes.Eq Futhark.Analysis.AlgSimplify.Prod
- Futhark.Analysis.AlgSimplify: instance GHC.Classes.Ord Futhark.Analysis.AlgSimplify.Prod
- Futhark.Analysis.AlgSimplify: instance GHC.Show.Show Futhark.Analysis.AlgSimplify.Prod
- Futhark.Analysis.AlgSimplify: isMultipleOf :: Prod -> [Exp] -> Bool
- Futhark.Analysis.AlgSimplify: lessThanish :: [(VName, PrimExp VName)] -> Names -> TPrimExp Int64 VName -> TPrimExp Int64 VName -> Bool
- Futhark.Analysis.AlgSimplify: maybeDivide :: Prod -> Prod -> Maybe Prod
- Futhark.Analysis.AlgSimplify: negate :: Prod -> Prod
- Futhark.Analysis.AlgSimplify: prodToExp :: Prod -> Exp
- Futhark.Analysis.AlgSimplify: removeLessThans :: SofP -> [(SubExp, PrimExp VName)] -> SofP
- Futhark.Analysis.AlgSimplify: simplify :: Exp -> Exp
- Futhark.Analysis.AlgSimplify: simplify' :: TExp -> TExp
- Futhark.Analysis.AlgSimplify: simplify0 :: Exp -> SofP
- Futhark.Analysis.AlgSimplify: simplifySofP :: SofP -> SofP
- Futhark.Analysis.AlgSimplify: simplifySofP' :: SofP -> SofP
- Futhark.Analysis.AlgSimplify: sub :: SofP -> SofP -> SofP
- Futhark.Analysis.AlgSimplify: sumOfProducts :: Exp -> SofP
- Futhark.Analysis.AlgSimplify: sumToExp :: SofP -> Exp
- Futhark.Analysis.AlgSimplify: type SofP = [Prod]
- Futhark.Analysis.Alias: aliasAnalysis :: AliasableRep rep => Prog rep -> Prog (Aliases rep)
- Futhark.Analysis.Alias: analyseBody :: AliasableRep rep => AliasTable -> Body rep -> Body (Aliases rep)
- Futhark.Analysis.Alias: analyseExp :: AliasableRep rep => AliasTable -> Exp rep -> Exp (Aliases rep)
- Futhark.Analysis.Alias: analyseFun :: AliasableRep rep => FunDef rep -> FunDef (Aliases rep)
- Futhark.Analysis.Alias: analyseLambda :: AliasableRep rep => AliasTable -> Lambda rep -> Lambda (Aliases rep)
- Futhark.Analysis.Alias: analyseStm :: AliasableRep rep => AliasTable -> Stm rep -> Stm (Aliases rep)
- Futhark.Analysis.Alias: analyseStms :: AliasableRep rep => AliasTable -> Stms rep -> (Stms (Aliases rep), AliasesAndConsumed)
- Futhark.Analysis.Alias: type AliasableRep rep = (ASTRep rep, RephraseOp OpC rep, CanBeAliased OpC rep, AliasedOp OpC rep, ASTConstraints OpC rep Aliases rep)
- Futhark.Analysis.CallGraph: allCalledBy :: Name -> CallGraph -> Set Name
- Futhark.Analysis.CallGraph: buildCallGraph :: Prog SOACS -> CallGraph
- Futhark.Analysis.CallGraph: calledByConsts :: Name -> CallGraph -> Bool
- Futhark.Analysis.CallGraph: calls :: Name -> Name -> CallGraph -> Bool
- Futhark.Analysis.CallGraph: data CallGraph
- Futhark.Analysis.CallGraph: instance GHC.Base.Monoid Futhark.Analysis.CallGraph.FunCalls
- Futhark.Analysis.CallGraph: instance GHC.Base.Semigroup Futhark.Analysis.CallGraph.FunCalls
- Futhark.Analysis.CallGraph: instance GHC.Classes.Eq Futhark.Analysis.CallGraph.CallGraph
- Futhark.Analysis.CallGraph: instance GHC.Classes.Eq Futhark.Analysis.CallGraph.FunCalls
- Futhark.Analysis.CallGraph: instance GHC.Classes.Ord Futhark.Analysis.CallGraph.CallGraph
- Futhark.Analysis.CallGraph: instance GHC.Classes.Ord Futhark.Analysis.CallGraph.FunCalls
- Futhark.Analysis.CallGraph: instance GHC.Show.Show Futhark.Analysis.CallGraph.CallGraph
- Futhark.Analysis.CallGraph: instance GHC.Show.Show Futhark.Analysis.CallGraph.FunCalls
- Futhark.Analysis.CallGraph: instance Prettyprinter.Internal.Pretty Futhark.Analysis.CallGraph.CallGraph
- Futhark.Analysis.CallGraph: instance Prettyprinter.Internal.Pretty Futhark.Analysis.CallGraph.FunCalls
- Futhark.Analysis.CallGraph: isFunInCallGraph :: Name -> CallGraph -> Bool
- Futhark.Analysis.CallGraph: numOccurences :: CallGraph -> Map Name Int
- Futhark.Analysis.DataDependencies: dataDependencies :: ASTRep rep => Body rep -> Dependencies
- Futhark.Analysis.DataDependencies: depsOf :: Dependencies -> SubExp -> Names
- Futhark.Analysis.DataDependencies: depsOf' :: SubExp -> Names
- Futhark.Analysis.DataDependencies: depsOfArrays :: SubExp -> [VName] -> [Names]
- Futhark.Analysis.DataDependencies: depsOfShape :: Shape -> Names
- Futhark.Analysis.DataDependencies: findNecessaryForReturned :: (Param dec -> Bool) -> [(Param dec, SubExp)] -> Map VName Names -> Names
- Futhark.Analysis.DataDependencies: lambdaDependencies :: ASTRep rep => Dependencies -> Lambda rep -> [Names] -> [Names]
- Futhark.Analysis.DataDependencies: reductionDependencies :: ASTRep rep => Dependencies -> Lambda rep -> [SubExp] -> [Names] -> [Names]
- Futhark.Analysis.DataDependencies: type Dependencies = Map VName Names
- Futhark.Analysis.HORep.MapNest: MapNest :: SubExp -> Lambda SOACS -> [Nesting] -> [Input] -> MapNest
- Futhark.Analysis.HORep.MapNest: Nesting :: [VName] -> [VName] -> [Type] -> SubExp -> Nesting
- Futhark.Analysis.HORep.MapNest: [mapNestInput] :: MapNest -> [Input]
- Futhark.Analysis.HORep.MapNest: [mapNestLambda] :: MapNest -> Lambda SOACS
- Futhark.Analysis.HORep.MapNest: [mapNestNestings] :: MapNest -> [Nesting]
- Futhark.Analysis.HORep.MapNest: [mapNestWidth] :: MapNest -> SubExp
- Futhark.Analysis.HORep.MapNest: [nestingParamNames] :: Nesting -> [VName]
- Futhark.Analysis.HORep.MapNest: [nestingResult] :: Nesting -> [VName]
- Futhark.Analysis.HORep.MapNest: [nestingReturnType] :: Nesting -> [Type]
- Futhark.Analysis.HORep.MapNest: [nestingWidth] :: Nesting -> SubExp
- Futhark.Analysis.HORep.MapNest: data MapNest
- Futhark.Analysis.HORep.MapNest: data Nesting
- Futhark.Analysis.HORep.MapNest: depth :: MapNest -> Int
- Futhark.Analysis.HORep.MapNest: fromSOAC :: (MonadFreshNames m, LocalScope SOACS m) => SOAC SOACS -> m (Maybe MapNest)
- Futhark.Analysis.HORep.MapNest: inputs :: MapNest -> [Input]
- Futhark.Analysis.HORep.MapNest: instance GHC.Classes.Eq Futhark.Analysis.HORep.MapNest.Nesting
- Futhark.Analysis.HORep.MapNest: instance GHC.Classes.Ord Futhark.Analysis.HORep.MapNest.Nesting
- Futhark.Analysis.HORep.MapNest: instance GHC.Show.Show Futhark.Analysis.HORep.MapNest.MapNest
- Futhark.Analysis.HORep.MapNest: instance GHC.Show.Show Futhark.Analysis.HORep.MapNest.Nesting
- Futhark.Analysis.HORep.MapNest: params :: MapNest -> [VName]
- Futhark.Analysis.HORep.MapNest: reshape :: MonadFreshNames m => StmAux () -> Shape -> MapNest -> m MapNest
- Futhark.Analysis.HORep.MapNest: setInputs :: [Input] -> MapNest -> MapNest
- Futhark.Analysis.HORep.MapNest: toSOAC :: (MonadFreshNames m, HasScope SOACS m) => MapNest -> m (SOAC SOACS)
- Futhark.Analysis.HORep.MapNest: typeOf :: MapNest -> [Type]
- Futhark.Analysis.HORep.SOAC: (:<) :: ArrayTransform -> ArrayTransforms -> ViewF
- Futhark.Analysis.HORep.SOAC: (:>) :: ArrayTransforms -> ArrayTransform -> ViewL
- Futhark.Analysis.HORep.SOAC: (<|) :: ArrayTransform -> ArrayTransforms -> ArrayTransforms
- Futhark.Analysis.HORep.SOAC: (|>) :: ArrayTransforms -> ArrayTransform -> ArrayTransforms
- Futhark.Analysis.HORep.SOAC: EmptyF :: ViewF
- Futhark.Analysis.HORep.SOAC: EmptyL :: ViewL
- Futhark.Analysis.HORep.SOAC: Hist :: SubExp -> [Input] -> [HistOp rep] -> Lambda rep -> SOAC rep
- Futhark.Analysis.HORep.SOAC: Index :: StmAux () -> Slice SubExp -> ArrayTransform
- Futhark.Analysis.HORep.SOAC: Input :: ArrayTransforms -> VName -> Type -> Input
- Futhark.Analysis.HORep.SOAC: NotSOAC :: NotSOAC
- Futhark.Analysis.HORep.SOAC: Rearrange :: StmAux () -> [Int] -> ArrayTransform
- Futhark.Analysis.HORep.SOAC: Replicate :: StmAux () -> Shape -> ArrayTransform
- Futhark.Analysis.HORep.SOAC: Reshape :: StmAux () -> NewShape SubExp -> ArrayTransform
- Futhark.Analysis.HORep.SOAC: Scatter :: SubExp -> [Input] -> ScatterSpec VName -> Lambda rep -> SOAC rep
- Futhark.Analysis.HORep.SOAC: Screma :: SubExp -> [Input] -> ScremaForm rep -> SOAC rep
- Futhark.Analysis.HORep.SOAC: ScremaForm :: Lambda rep -> [Scan rep] -> [Reduce rep] -> ScremaForm rep
- Futhark.Analysis.HORep.SOAC: Stream :: SubExp -> [Input] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.Analysis.HORep.SOAC: [scremaLambda] :: ScremaForm rep -> Lambda rep
- Futhark.Analysis.HORep.SOAC: [scremaReduces] :: ScremaForm rep -> [Reduce rep]
- Futhark.Analysis.HORep.SOAC: [scremaScans] :: ScremaForm rep -> [Scan rep]
- Futhark.Analysis.HORep.SOAC: addInitialTransforms :: ArrayTransforms -> Input -> Input
- Futhark.Analysis.HORep.SOAC: addTransform :: ArrayTransform -> Input -> Input
- Futhark.Analysis.HORep.SOAC: applyTransforms :: MonadBuilder m => ArrayTransforms -> VName -> m VName
- Futhark.Analysis.HORep.SOAC: data ArrayTransform
- Futhark.Analysis.HORep.SOAC: data ArrayTransforms
- Futhark.Analysis.HORep.SOAC: data Input
- Futhark.Analysis.HORep.SOAC: data NotSOAC
- Futhark.Analysis.HORep.SOAC: data SOAC rep
- Futhark.Analysis.HORep.SOAC: data ScremaForm rep
- Futhark.Analysis.HORep.SOAC: data ViewF
- Futhark.Analysis.HORep.SOAC: data ViewL
- Futhark.Analysis.HORep.SOAC: fromExp :: (Op rep ~ SOAC rep, HasScope rep m) => Exp rep -> m (Either NotSOAC (SOAC rep))
- Futhark.Analysis.HORep.SOAC: identInput :: Ident -> Input
- Futhark.Analysis.HORep.SOAC: inputArray :: Input -> VName
- Futhark.Analysis.HORep.SOAC: inputRank :: Input -> Int
- Futhark.Analysis.HORep.SOAC: inputRowType :: Input -> Type
- Futhark.Analysis.HORep.SOAC: inputTransforms :: Input -> ArrayTransforms
- Futhark.Analysis.HORep.SOAC: inputType :: Input -> Type
- Futhark.Analysis.HORep.SOAC: inputs :: SOAC rep -> [Input]
- Futhark.Analysis.HORep.SOAC: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.Analysis.HORep.SOAC.SOAC rep)
- Futhark.Analysis.HORep.SOAC: instance Futhark.IR.Prop.Names.FreeIn Futhark.Analysis.HORep.SOAC.ArrayTransform
- Futhark.Analysis.HORep.SOAC: instance Futhark.IR.Prop.Names.FreeIn Futhark.Analysis.HORep.SOAC.ArrayTransforms
- Futhark.Analysis.HORep.SOAC: instance Futhark.IR.Prop.Names.FreeIn Futhark.Analysis.HORep.SOAC.Input
- Futhark.Analysis.HORep.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.Analysis.HORep.SOAC.SOAC rep)
- Futhark.Analysis.HORep.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.Analysis.HORep.SOAC.SOAC rep)
- Futhark.Analysis.HORep.SOAC: instance Futhark.Transform.Substitute.Substitute Futhark.Analysis.HORep.SOAC.ArrayTransform
- Futhark.Analysis.HORep.SOAC: instance Futhark.Transform.Substitute.Substitute Futhark.Analysis.HORep.SOAC.ArrayTransforms
- Futhark.Analysis.HORep.SOAC: instance Futhark.Transform.Substitute.Substitute Futhark.Analysis.HORep.SOAC.Input
- Futhark.Analysis.HORep.SOAC: instance GHC.Base.Monoid Futhark.Analysis.HORep.SOAC.ArrayTransforms
- Futhark.Analysis.HORep.SOAC: instance GHC.Base.Semigroup Futhark.Analysis.HORep.SOAC.ArrayTransforms
- Futhark.Analysis.HORep.SOAC: instance GHC.Classes.Eq Futhark.Analysis.HORep.SOAC.ArrayTransform
- Futhark.Analysis.HORep.SOAC: instance GHC.Classes.Eq Futhark.Analysis.HORep.SOAC.ArrayTransforms
- Futhark.Analysis.HORep.SOAC: instance GHC.Classes.Eq Futhark.Analysis.HORep.SOAC.Input
- Futhark.Analysis.HORep.SOAC: instance GHC.Classes.Ord Futhark.Analysis.HORep.SOAC.ArrayTransform
- Futhark.Analysis.HORep.SOAC: instance GHC.Classes.Ord Futhark.Analysis.HORep.SOAC.ArrayTransforms
- Futhark.Analysis.HORep.SOAC: instance GHC.Classes.Ord Futhark.Analysis.HORep.SOAC.Input
- Futhark.Analysis.HORep.SOAC: instance GHC.Show.Show Futhark.Analysis.HORep.SOAC.ArrayTransform
- Futhark.Analysis.HORep.SOAC: instance GHC.Show.Show Futhark.Analysis.HORep.SOAC.ArrayTransforms
- Futhark.Analysis.HORep.SOAC: instance GHC.Show.Show Futhark.Analysis.HORep.SOAC.Input
- Futhark.Analysis.HORep.SOAC: instance GHC.Show.Show Futhark.Analysis.HORep.SOAC.NotSOAC
- Futhark.Analysis.HORep.SOAC: instance Prettyprinter.Internal.Pretty Futhark.Analysis.HORep.SOAC.ArrayTransform
- Futhark.Analysis.HORep.SOAC: instance Prettyprinter.Internal.Pretty Futhark.Analysis.HORep.SOAC.Input
- Futhark.Analysis.HORep.SOAC: isVarInput :: Input -> Maybe VName
- Futhark.Analysis.HORep.SOAC: isVarishInput :: Input -> Maybe VName
- Futhark.Analysis.HORep.SOAC: lambda :: SOAC rep -> Lambda rep
- Futhark.Analysis.HORep.SOAC: noTransforms :: ArrayTransforms
- Futhark.Analysis.HORep.SOAC: nullTransforms :: ArrayTransforms -> Bool
- Futhark.Analysis.HORep.SOAC: setInputs :: [Input] -> SOAC rep -> SOAC rep
- Futhark.Analysis.HORep.SOAC: setLambda :: Lambda rep -> SOAC rep -> SOAC rep
- Futhark.Analysis.HORep.SOAC: soacToStream :: (HasScope rep m, MonadFreshNames m, Buildable rep, BuilderOps rep, Op rep ~ SOAC rep) => SOAC rep -> m (SOAC rep, [Ident])
- Futhark.Analysis.HORep.SOAC: toExp :: (MonadBuilder m, Op (Rep m) ~ SOAC (Rep m)) => SOAC (Rep m) -> m (Exp (Rep m))
- Futhark.Analysis.HORep.SOAC: toSOAC :: MonadBuilder m => SOAC (Rep m) -> m (SOAC (Rep m))
- Futhark.Analysis.HORep.SOAC: transformFromExp :: StmAux () -> Exp rep -> Maybe (VName, ArrayTransform)
- Futhark.Analysis.HORep.SOAC: transformRows :: ArrayTransforms -> Input -> Input
- Futhark.Analysis.HORep.SOAC: transformToExp :: (Monad m, HasScope rep m) => ArrayTransform -> VName -> m (StmAux (), Exp rep)
- Futhark.Analysis.HORep.SOAC: transposeInput :: Int -> Int -> Input -> Input
- Futhark.Analysis.HORep.SOAC: typeOf :: SOAC rep -> [Type]
- Futhark.Analysis.HORep.SOAC: varInput :: HasScope t f => VName -> f Input
- Futhark.Analysis.HORep.SOAC: viewf :: ArrayTransforms -> ViewF
- Futhark.Analysis.HORep.SOAC: viewl :: ArrayTransforms -> ViewL
- Futhark.Analysis.HORep.SOAC: width :: SOAC rep -> SubExp
- Futhark.Analysis.Interference: analyseProgGPU :: Prog GPUMem -> Graph VName
- Futhark.Analysis.Interference: type Graph a = Set (a, a)
- Futhark.Analysis.LastUse: instance Control.Monad.Reader.Class.MonadReader (Futhark.Analysis.LastUse.LastUseReader rep) (Futhark.Analysis.LastUse.LastUseM rep)
- Futhark.Analysis.LastUse: instance Control.Monad.State.Class.MonadState Futhark.Analysis.LastUse.AliasTab (Futhark.Analysis.LastUse.LastUseM rep)
- Futhark.Analysis.LastUse: instance Futhark.IR.Rep.RepTypes (Futhark.IR.Aliases.Aliases rep) => Futhark.IR.Prop.Scope.HasScope (Futhark.IR.Aliases.Aliases rep) (Futhark.Analysis.LastUse.LastUseM rep)
- Futhark.Analysis.LastUse: instance Futhark.IR.Rep.RepTypes (Futhark.IR.Aliases.Aliases rep) => Futhark.IR.Prop.Scope.LocalScope (Futhark.IR.Aliases.Aliases rep) (Futhark.Analysis.LastUse.LastUseM rep)
- Futhark.Analysis.LastUse: instance GHC.Base.Applicative (Futhark.Analysis.LastUse.LastUseM rep)
- Futhark.Analysis.LastUse: instance GHC.Base.Functor (Futhark.Analysis.LastUse.LastUseM rep)
- Futhark.Analysis.LastUse: instance GHC.Base.Monad (Futhark.Analysis.LastUse.LastUseM rep)
- Futhark.Analysis.LastUse: lastUseGPUMem :: Prog (Aliases GPUMem) -> LUTabProg
- Futhark.Analysis.LastUse: lastUseMCMem :: Prog (Aliases MCMem) -> LUTabProg
- Futhark.Analysis.LastUse: lastUseSeqMem :: Prog (Aliases SeqMem) -> LUTabProg
- Futhark.Analysis.LastUse: type LUTabFun = Map VName Names
- Futhark.Analysis.LastUse: type LUTabProg = (LUTabFun, Map Name LUTabFun)
- Futhark.Analysis.MemAlias: aliasesOf :: MemAliases -> VName -> Names
- Futhark.Analysis.MemAlias: analyzeGPUMem :: Prog GPUMem -> (MemAliases, Map Name MemAliases)
- Futhark.Analysis.MemAlias: analyzeSeqMem :: Prog SeqMem -> (MemAliases, Map Name MemAliases)
- Futhark.Analysis.MemAlias: data MemAliases
- Futhark.Analysis.MemAlias: instance GHC.Base.Monoid Futhark.Analysis.MemAlias.MemAliases
- Futhark.Analysis.MemAlias: instance GHC.Base.Semigroup Futhark.Analysis.MemAlias.MemAliases
- Futhark.Analysis.MemAlias: instance GHC.Classes.Eq Futhark.Analysis.MemAlias.MemAliases
- Futhark.Analysis.MemAlias: instance GHC.Show.Show Futhark.Analysis.MemAlias.MemAliases
- Futhark.Analysis.MemAlias: instance Prettyprinter.Internal.Pretty Futhark.Analysis.MemAlias.MemAliases
- Futhark.Analysis.Metrics: AstMetrics :: Map Text Int -> AstMetrics
- Futhark.Analysis.Metrics: bodyMetrics :: OpMetrics (Op rep) => Body rep -> MetricsM ()
- Futhark.Analysis.Metrics: class OpMetrics op
- Futhark.Analysis.Metrics: data MetricsM a
- Futhark.Analysis.Metrics: inside :: Text -> MetricsM () -> MetricsM ()
- Futhark.Analysis.Metrics: instance Control.Monad.Writer.Class.MonadWriter Futhark.Analysis.Metrics.CountMetrics Futhark.Analysis.Metrics.MetricsM
- Futhark.Analysis.Metrics: instance Futhark.Analysis.Metrics.OpMetrics a => Futhark.Analysis.Metrics.OpMetrics (GHC.Maybe.Maybe a)
- Futhark.Analysis.Metrics: instance GHC.Base.Applicative Futhark.Analysis.Metrics.MetricsM
- Futhark.Analysis.Metrics: instance GHC.Base.Functor Futhark.Analysis.Metrics.MetricsM
- Futhark.Analysis.Metrics: instance GHC.Base.Monad Futhark.Analysis.Metrics.MetricsM
- Futhark.Analysis.Metrics: instance GHC.Base.Monoid Futhark.Analysis.Metrics.CountMetrics
- Futhark.Analysis.Metrics: instance GHC.Base.Semigroup Futhark.Analysis.Metrics.CountMetrics
- Futhark.Analysis.Metrics: instance forall k (rep :: k). Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.Rep.NoOp rep)
- Futhark.Analysis.Metrics: lambdaMetrics :: OpMetrics (Op rep) => Lambda rep -> MetricsM ()
- Futhark.Analysis.Metrics: newtype AstMetrics
- Futhark.Analysis.Metrics: opMetrics :: OpMetrics op => op -> MetricsM ()
- Futhark.Analysis.Metrics: progMetrics :: OpMetrics (Op rep) => Prog rep -> AstMetrics
- Futhark.Analysis.Metrics: seen :: Text -> MetricsM ()
- Futhark.Analysis.Metrics: stmMetrics :: OpMetrics (Op rep) => Stm rep -> MetricsM ()
- Futhark.Analysis.Metrics.Type: AstMetrics :: Map Text Int -> AstMetrics
- Futhark.Analysis.Metrics.Type: instance GHC.Read.Read Futhark.Analysis.Metrics.Type.AstMetrics
- Futhark.Analysis.Metrics.Type: instance GHC.Show.Show Futhark.Analysis.Metrics.Type.AstMetrics
- Futhark.Analysis.Metrics.Type: newtype AstMetrics
- Futhark.Analysis.PrimExp: (.&&.) :: Eq v => TPrimExp Bool v -> TPrimExp Bool v -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: (.&.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp t v
- Futhark.Analysis.PrimExp: (.<.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: (.<<.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp t v
- Futhark.Analysis.PrimExp: (.<=.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: (.==.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: (.>.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: (.>=.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: (.>>.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp t v
- Futhark.Analysis.PrimExp: (.^.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp t v
- Futhark.Analysis.PrimExp: (.|.) :: forall {k} v (t :: k). Eq v => TPrimExp t v -> TPrimExp t v -> TPrimExp t v
- Futhark.Analysis.PrimExp: (.||.) :: Eq v => TPrimExp Bool v -> TPrimExp Bool v -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: (~*~) :: PrimExp v -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: (~+~) :: PrimExp v -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: (~-~) :: PrimExp v -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: (~/~) :: PrimExp v -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: (~==~) :: PrimExp v -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: BinOpExp :: BinOp -> PrimExp v -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: CmpOpExp :: CmpOp -> PrimExp v -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: ConvOpExp :: ConvOp -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: FunExp :: Text -> [PrimExp v] -> PrimType -> PrimExp v
- Futhark.Analysis.PrimExp: LeafExp :: v -> PrimType -> PrimExp v
- Futhark.Analysis.PrimExp: TPrimExp :: PrimExp v -> TPrimExp (t :: k) v
- Futhark.Analysis.PrimExp: UnOpExp :: UnOp -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: ValueExp :: PrimValue -> PrimExp v
- Futhark.Analysis.PrimExp: [untyped] :: TPrimExp (t :: k) v -> PrimExp v
- Futhark.Analysis.PrimExp: bNot :: TPrimExp Bool v -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: class NumExp t => FloatExp (t :: k)
- Futhark.Analysis.PrimExp: class NumExp t => IntExp (t :: k)
- Futhark.Analysis.PrimExp: class NumExp (t :: k)
- Futhark.Analysis.PrimExp: coerceIntPrimExp :: IntType -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: condExp :: forall {k} v (t :: k). TPrimExp Bool v -> TPrimExp t v -> TPrimExp t v -> TPrimExp t v
- Futhark.Analysis.PrimExp: constFoldPrimExp :: PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: data PrimExp v
- Futhark.Analysis.PrimExp: evalPrimExp :: (Pretty v, MonadFail m) => (v -> m PrimValue) -> PrimExp v -> m PrimValue
- Futhark.Analysis.PrimExp: expFloatType :: FloatExp t => TPrimExp t v -> FloatType
- Futhark.Analysis.PrimExp: expIntType :: IntExp t => TPrimExp t v -> IntType
- Futhark.Analysis.PrimExp: fMax16 :: TPrimExp Half v -> TPrimExp Half v -> TPrimExp Half v
- Futhark.Analysis.PrimExp: fMax32 :: TPrimExp Float v -> TPrimExp Float v -> TPrimExp Float v
- Futhark.Analysis.PrimExp: fMax64 :: TPrimExp Double v -> TPrimExp Double v -> TPrimExp Double v
- Futhark.Analysis.PrimExp: fMin16 :: TPrimExp Half v -> TPrimExp Half v -> TPrimExp Half v
- Futhark.Analysis.PrimExp: fMin32 :: TPrimExp Float v -> TPrimExp Float v -> TPrimExp Float v
- Futhark.Analysis.PrimExp: fMin64 :: TPrimExp Double v -> TPrimExp Double v -> TPrimExp Double v
- Futhark.Analysis.PrimExp: false :: TPrimExp Bool v
- Futhark.Analysis.PrimExp: fromBool :: Bool -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: fromBoolExp :: NumExp t => TPrimExp Bool v -> TPrimExp t v
- Futhark.Analysis.PrimExp: fromInteger' :: NumExp t => Integer -> TPrimExp t v
- Futhark.Analysis.PrimExp: fromRational' :: FloatExp t => Rational -> TPrimExp t v
- Futhark.Analysis.PrimExp: infix 4 ~==~
- Futhark.Analysis.PrimExp: infix 6 ~-~
- Futhark.Analysis.PrimExp: infix 7 ~/~
- Futhark.Analysis.PrimExp: infixr 2 .||.
- Futhark.Analysis.PrimExp: infixr 3 .&&.
- Futhark.Analysis.PrimExp: instance Data.Foldable.Foldable Futhark.Analysis.PrimExp.PrimExp
- Futhark.Analysis.PrimExp: instance Data.Traversable.Traversable Futhark.Analysis.PrimExp.PrimExp
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.FloatExp GHC.Types.Double
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.FloatExp GHC.Types.Float
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.FloatExp Numeric.Half.Internal.Half
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.IntExp GHC.Int.Int16
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.IntExp GHC.Int.Int32
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.IntExp GHC.Int.Int64
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.IntExp GHC.Int.Int8
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.NumExp GHC.Int.Int16
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.NumExp GHC.Int.Int32
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.NumExp GHC.Int.Int64
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.NumExp GHC.Int.Int8
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.NumExp GHC.Types.Double
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.NumExp GHC.Types.Float
- Futhark.Analysis.PrimExp: instance Futhark.Analysis.PrimExp.NumExp Numeric.Half.Internal.Half
- Futhark.Analysis.PrimExp: instance Futhark.IR.Prop.Names.FreeIn v => Futhark.IR.Prop.Names.FreeIn (Futhark.Analysis.PrimExp.PrimExp v)
- Futhark.Analysis.PrimExp: instance GHC.Base.Functor Futhark.Analysis.PrimExp.PrimExp
- Futhark.Analysis.PrimExp: instance GHC.Classes.Eq v => GHC.Classes.Eq (Futhark.Analysis.PrimExp.PrimExp v)
- Futhark.Analysis.PrimExp: instance GHC.Classes.Ord v => GHC.Classes.Ord (Futhark.Analysis.PrimExp.PrimExp v)
- Futhark.Analysis.PrimExp: instance GHC.Show.Show v => GHC.Show.Show (Futhark.Analysis.PrimExp.PrimExp v)
- Futhark.Analysis.PrimExp: instance Prettyprinter.Internal.Pretty v => GHC.Float.Floating (Futhark.Analysis.PrimExp.TPrimExp GHC.Types.Double v)
- Futhark.Analysis.PrimExp: instance Prettyprinter.Internal.Pretty v => GHC.Float.Floating (Futhark.Analysis.PrimExp.TPrimExp GHC.Types.Float v)
- Futhark.Analysis.PrimExp: instance Prettyprinter.Internal.Pretty v => GHC.Float.Floating (Futhark.Analysis.PrimExp.TPrimExp Numeric.Half.Internal.Half v)
- Futhark.Analysis.PrimExp: instance Prettyprinter.Internal.Pretty v => Prettyprinter.Internal.Pretty (Futhark.Analysis.PrimExp.PrimExp v)
- Futhark.Analysis.PrimExp: instance forall k (t :: k) v. (Futhark.Analysis.PrimExp.FloatExp t, Prettyprinter.Internal.Pretty v) => GHC.Real.Fractional (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Analysis.PrimExp: instance forall k (t :: k) v. (Futhark.Analysis.PrimExp.IntExp t, Prettyprinter.Internal.Pretty v) => Futhark.Util.IntegralExp.IntegralExp (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Analysis.PrimExp: instance forall k (t :: k) v. (Futhark.Analysis.PrimExp.NumExp t, Prettyprinter.Internal.Pretty v) => GHC.Num.Num (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Analysis.PrimExp: instance forall k (t :: k) v. GHC.Classes.Eq v => GHC.Classes.Eq (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Analysis.PrimExp: instance forall k (t :: k) v. GHC.Classes.Ord v => GHC.Classes.Ord (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Analysis.PrimExp: instance forall k (t :: k) v. GHC.Show.Show v => GHC.Show.Show (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Analysis.PrimExp: instance forall k (t :: k). Data.Foldable.Foldable (Futhark.Analysis.PrimExp.TPrimExp t)
- Futhark.Analysis.PrimExp: instance forall k (t :: k). Data.Traversable.Traversable (Futhark.Analysis.PrimExp.TPrimExp t)
- Futhark.Analysis.PrimExp: instance forall k (t :: k). GHC.Base.Functor (Futhark.Analysis.PrimExp.TPrimExp t)
- Futhark.Analysis.PrimExp: instance forall k v (t :: k). Futhark.IR.Prop.Names.FreeIn v => Futhark.IR.Prop.Names.FreeIn (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Analysis.PrimExp: instance forall k v (t :: k). Prettyprinter.Internal.Pretty v => Prettyprinter.Internal.Pretty (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Analysis.PrimExp: isBool :: PrimExp v -> TPrimExp Bool v
- Futhark.Analysis.PrimExp: isF16 :: PrimExp v -> TPrimExp Half v
- Futhark.Analysis.PrimExp: isF32 :: PrimExp v -> TPrimExp Float v
- Futhark.Analysis.PrimExp: isF64 :: PrimExp v -> TPrimExp Double v
- Futhark.Analysis.PrimExp: isInt16 :: PrimExp v -> TPrimExp Int16 v
- Futhark.Analysis.PrimExp: isInt32 :: PrimExp v -> TPrimExp Int32 v
- Futhark.Analysis.PrimExp: isInt64 :: PrimExp v -> TPrimExp Int64 v
- Futhark.Analysis.PrimExp: isInt8 :: PrimExp v -> TPrimExp Int8 v
- Futhark.Analysis.PrimExp: leafExpTypes :: Ord a => PrimExp a -> Set (a, PrimType)
- Futhark.Analysis.PrimExp: newtype TPrimExp (t :: k) v
- Futhark.Analysis.PrimExp: primExpSizeAtLeast :: Int -> PrimExp v -> Bool
- Futhark.Analysis.PrimExp: primExpType :: PrimExp v -> PrimType
- Futhark.Analysis.PrimExp: sExt :: IntType -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: sExt32 :: forall {k} (t :: k) v. IntExp t => TPrimExp t v -> TPrimExp Int32 v
- Futhark.Analysis.PrimExp: sExt64 :: forall {k} (t :: k) v. IntExp t => TPrimExp t v -> TPrimExp Int64 v
- Futhark.Analysis.PrimExp: sExtAs :: forall {k1} {k2} (to :: k1) (from :: k2) v. (IntExp to, IntExp from) => TPrimExp from v -> TPrimExp to v -> TPrimExp to v
- Futhark.Analysis.PrimExp: sMax32 :: TPrimExp Int32 v -> TPrimExp Int32 v -> TPrimExp Int32 v
- Futhark.Analysis.PrimExp: sMax64 :: TPrimExp Int64 v -> TPrimExp Int64 v -> TPrimExp Int64 v
- Futhark.Analysis.PrimExp: sMin32 :: TPrimExp Int32 v -> TPrimExp Int32 v -> TPrimExp Int32 v
- Futhark.Analysis.PrimExp: sMin64 :: TPrimExp Int64 v -> TPrimExp Int64 v -> TPrimExp Int64 v
- Futhark.Analysis.PrimExp: true :: TPrimExp Bool v
- Futhark.Analysis.PrimExp: zExt :: IntType -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp: zExt32 :: forall {k} (t :: k) v. IntExp t => TPrimExp t v -> TPrimExp Int32 v
- Futhark.Analysis.PrimExp: zExt64 :: forall {k} (t :: k) v. IntExp t => TPrimExp t v -> TPrimExp Int64 v
- Futhark.Analysis.PrimExp.Convert: f32le :: a -> TPrimExp Float a
- Futhark.Analysis.PrimExp.Convert: f32pe :: SubExp -> TPrimExp Float VName
- Futhark.Analysis.PrimExp.Convert: f64le :: a -> TPrimExp Double a
- Futhark.Analysis.PrimExp.Convert: f64pe :: SubExp -> TPrimExp Double VName
- Futhark.Analysis.PrimExp.Convert: instance Futhark.Construct.ToExp v => Futhark.Construct.ToExp (Futhark.Analysis.PrimExp.PrimExp v)
- Futhark.Analysis.PrimExp.Convert: instance forall k v (t :: k). Futhark.Construct.ToExp v => Futhark.Construct.ToExp (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Analysis.PrimExp.Convert: le32 :: a -> TPrimExp Int32 a
- Futhark.Analysis.PrimExp.Convert: le64 :: a -> TPrimExp Int64 a
- Futhark.Analysis.PrimExp.Convert: pe32 :: SubExp -> TPrimExp Int32 VName
- Futhark.Analysis.PrimExp.Convert: pe64 :: SubExp -> TPrimExp Int64 VName
- Futhark.Analysis.PrimExp.Convert: primExpFromExp :: (MonadFail m, RepTypes rep) => (VName -> m (PrimExp v)) -> Exp rep -> m (PrimExp v)
- Futhark.Analysis.PrimExp.Convert: primExpFromSubExp :: PrimType -> SubExp -> PrimExp VName
- Futhark.Analysis.PrimExp.Convert: primExpFromSubExpM :: Applicative m => (VName -> m (PrimExp v)) -> SubExp -> m (PrimExp v)
- Futhark.Analysis.PrimExp.Convert: primExpSlice :: Slice SubExp -> Slice (TPrimExp Int64 VName)
- Futhark.Analysis.PrimExp.Convert: replaceInPrimExp :: (a -> PrimType -> PrimExp b) -> PrimExp a -> PrimExp b
- Futhark.Analysis.PrimExp.Convert: replaceInPrimExpM :: Monad m => (a -> PrimType -> m (PrimExp b)) -> PrimExp a -> m (PrimExp b)
- Futhark.Analysis.PrimExp.Convert: subExpSlice :: MonadBuilder m => Slice (TPrimExp Int64 VName) -> m (Slice SubExp)
- Futhark.Analysis.PrimExp.Convert: substituteInPrimExp :: Ord v => Map v (PrimExp v) -> PrimExp v -> PrimExp v
- Futhark.Analysis.PrimExp.Parse: pPrimExp :: PrimType -> Parsec Void Text v -> Parsec Void Text (PrimExp v)
- Futhark.Analysis.PrimExp.Parse: pPrimValue :: Parsec Void Text PrimValue
- Futhark.Analysis.PrimExp.Simplify: simplifyExtPrimExp :: SimplifiableRep rep => PrimExp (Ext VName) -> SimpleM rep (PrimExp (Ext VName))
- Futhark.Analysis.PrimExp.Simplify: simplifyPrimExp :: SimplifiableRep rep => PrimExp VName -> SimpleM rep (PrimExp VName)
- Futhark.Analysis.PrimExp.Table: class PrimExpAnalysis rep
- Futhark.Analysis.PrimExp.Table: instance Futhark.Analysis.PrimExp.Table.PrimExpAnalysis Futhark.IR.GPU.GPU
- Futhark.Analysis.PrimExp.Table: instance Futhark.Analysis.PrimExp.Table.PrimExpAnalysis Futhark.IR.MC.MC
- Futhark.Analysis.PrimExp.Table: opPrimExp :: PrimExpAnalysis rep => Scope rep -> Op rep -> State PrimExpTable ()
- Futhark.Analysis.PrimExp.Table: primExpTable :: (PrimExpAnalysis rep, RepTypes rep) => Prog rep -> PrimExpTable
- Futhark.Analysis.PrimExp.Table: stmToPrimExps :: (PrimExpAnalysis rep, RepTypes rep) => Scope rep -> Stm rep -> State PrimExpTable ()
- Futhark.Analysis.PrimExp.Table: type PrimExpTable = Map VName Maybe PrimExp VName
- Futhark.Analysis.SymbolTable: Indexed :: Certs -> PrimExp VName -> Indexed
- Futhark.Analysis.SymbolTable: IndexedArray :: Certs -> VName -> [TPrimExp Int64 VName] -> Indexed
- Futhark.Analysis.SymbolTable: aliases :: VName -> VName -> SymbolTable rep -> Bool
- Futhark.Analysis.SymbolTable: available :: VName -> SymbolTable rep -> Bool
- Futhark.Analysis.SymbolTable: class IndexOp op
- Futhark.Analysis.SymbolTable: consume :: VName -> SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: data Entry rep
- Futhark.Analysis.SymbolTable: data Indexed
- Futhark.Analysis.SymbolTable: data SymbolTable rep
- Futhark.Analysis.SymbolTable: deepen :: SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: elem :: VName -> SymbolTable rep -> Bool
- Futhark.Analysis.SymbolTable: empty :: SymbolTable rep
- Futhark.Analysis.SymbolTable: entryAccInput :: Entry rep -> Maybe (WithAccInput rep)
- Futhark.Analysis.SymbolTable: entryDepth :: Entry rep -> Int
- Futhark.Analysis.SymbolTable: entryFParam :: Entry rep -> Maybe (FParamInfo rep)
- Futhark.Analysis.SymbolTable: entryIsSize :: Entry rep -> Bool
- Futhark.Analysis.SymbolTable: entryLParam :: Entry rep -> Maybe (LParamInfo rep)
- Futhark.Analysis.SymbolTable: entryLetBoundDec :: Entry rep -> Maybe (LetDec rep)
- Futhark.Analysis.SymbolTable: entryStm :: Entry rep -> Maybe (Stm rep)
- Futhark.Analysis.SymbolTable: fromScope :: ASTRep rep => Scope rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: hideCertified :: Names -> SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: index :: VName -> [SubExp] -> SymbolTable rep -> Maybe Indexed
- Futhark.Analysis.SymbolTable: index' :: VName -> [TPrimExp Int64 VName] -> SymbolTable rep -> Maybe Indexed
- Futhark.Analysis.SymbolTable: indexOp :: (IndexOp op, ASTRep rep, IndexOp (Op rep)) => SymbolTable rep -> Int -> op -> [TPrimExp Int64 VName] -> Maybe Indexed
- Futhark.Analysis.SymbolTable: indexedAddCerts :: Certs -> Indexed -> Indexed
- Futhark.Analysis.SymbolTable: insertFParams :: ASTRep rep => [FParam rep] -> SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: insertLParam :: ASTRep rep => LParam rep -> SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: insertLoopMerge :: ASTRep rep => [(FParam rep, SubExp, SubExpRes)] -> SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: insertLoopVar :: ASTRep rep => VName -> IntType -> SubExp -> SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: insertStm :: (IndexOp (Op rep), Aliased rep) => Stm rep -> SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: insertStms :: (IndexOp (Op rep), Aliased rep) => Stms rep -> SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Types.Typed (Futhark.Analysis.SymbolTable.Entry rep)
- Futhark.Analysis.SymbolTable: instance Futhark.IR.Prop.Names.FreeIn Futhark.Analysis.SymbolTable.Indexed
- Futhark.Analysis.SymbolTable: instance GHC.Base.Monoid (Futhark.Analysis.SymbolTable.SymbolTable rep)
- Futhark.Analysis.SymbolTable: instance GHC.Base.Semigroup (Futhark.Analysis.SymbolTable.SymbolTable rep)
- Futhark.Analysis.SymbolTable: instance forall k (rep :: k). Futhark.Analysis.SymbolTable.IndexOp (Futhark.IR.Rep.NoOp rep)
- Futhark.Analysis.SymbolTable: lookup :: VName -> SymbolTable rep -> Maybe (Entry rep)
- Futhark.Analysis.SymbolTable: lookupAliases :: VName -> SymbolTable rep -> Names
- Futhark.Analysis.SymbolTable: lookupBasicOp :: VName -> SymbolTable rep -> Maybe (BasicOp, Certs)
- Futhark.Analysis.SymbolTable: lookupExp :: VName -> SymbolTable rep -> Maybe (Exp rep, Certs)
- Futhark.Analysis.SymbolTable: lookupLoopParam :: VName -> SymbolTable rep -> Maybe (SubExp, SubExp)
- Futhark.Analysis.SymbolTable: lookupLoopVar :: VName -> SymbolTable rep -> Maybe SubExp
- Futhark.Analysis.SymbolTable: lookupStm :: VName -> SymbolTable rep -> Maybe (Stm rep)
- Futhark.Analysis.SymbolTable: lookupSubExp :: VName -> SymbolTable rep -> Maybe (SubExp, Certs)
- Futhark.Analysis.SymbolTable: lookupType :: ASTRep rep => VName -> SymbolTable rep -> Maybe Type
- Futhark.Analysis.SymbolTable: noteAccTokens :: [(VName, WithAccInput rep)] -> SymbolTable rep -> SymbolTable rep
- Futhark.Analysis.SymbolTable: subExpAvailable :: SubExp -> SymbolTable rep -> Bool
- Futhark.Analysis.SymbolTable: toScope :: SymbolTable rep -> Scope rep
- Futhark.Analysis.UsageTable: consumedU :: Usages
- Futhark.Analysis.UsageTable: consumedUsage :: VName -> UsageTable
- Futhark.Analysis.UsageTable: data UsageTable
- Futhark.Analysis.UsageTable: data Usages
- Futhark.Analysis.UsageTable: expand :: (VName -> Names) -> UsageTable -> UsageTable
- Futhark.Analysis.UsageTable: inResultUsage :: VName -> UsageTable
- Futhark.Analysis.UsageTable: instance GHC.Base.Monoid Futhark.Analysis.UsageTable.UsageTable
- Futhark.Analysis.UsageTable: instance GHC.Base.Monoid Futhark.Analysis.UsageTable.Usages
- Futhark.Analysis.UsageTable: instance GHC.Base.Semigroup Futhark.Analysis.UsageTable.UsageTable
- Futhark.Analysis.UsageTable: instance GHC.Base.Semigroup Futhark.Analysis.UsageTable.Usages
- Futhark.Analysis.UsageTable: instance GHC.Classes.Eq Futhark.Analysis.UsageTable.UsageTable
- Futhark.Analysis.UsageTable: instance GHC.Classes.Eq Futhark.Analysis.UsageTable.Usages
- Futhark.Analysis.UsageTable: instance GHC.Classes.Ord Futhark.Analysis.UsageTable.Usages
- Futhark.Analysis.UsageTable: instance GHC.Show.Show Futhark.Analysis.UsageTable.UsageTable
- Futhark.Analysis.UsageTable: instance GHC.Show.Show Futhark.Analysis.UsageTable.Usages
- Futhark.Analysis.UsageTable: isConsumed :: VName -> UsageTable -> Bool
- Futhark.Analysis.UsageTable: isInResult :: VName -> UsageTable -> Bool
- Futhark.Analysis.UsageTable: isSize :: VName -> UsageTable -> Bool
- Futhark.Analysis.UsageTable: isUsedDirectly :: VName -> UsageTable -> Bool
- Futhark.Analysis.UsageTable: lookup :: VName -> UsageTable -> Maybe Usages
- Futhark.Analysis.UsageTable: presentU :: Usages
- Futhark.Analysis.UsageTable: sizeUsage :: VName -> UsageTable
- Futhark.Analysis.UsageTable: sizeUsages :: Names -> UsageTable
- Futhark.Analysis.UsageTable: usage :: VName -> Usages -> UsageTable
- Futhark.Analysis.UsageTable: usageInPat :: FreeIn t => Pat t -> UsageTable
- Futhark.Analysis.UsageTable: usageInStm :: Aliased rep => Stm rep -> UsageTable
- Futhark.Analysis.UsageTable: usages :: Names -> UsageTable
- Futhark.Analysis.UsageTable: used :: VName -> UsageTable -> Bool
- Futhark.Analysis.UsageTable: without :: UsageTable -> [VName] -> UsageTable
- Futhark.Analysis.UsageTable: withoutU :: Usages -> Usages -> Usages
- Futhark.Bench: BenchResult :: FilePath -> [DataResult] -> BenchResult
- Futhark.Bench: CompileOptions :: String -> String -> [String] -> CompileOptions
- Futhark.Bench: DataResult :: Text -> Either Text Result -> DataResult
- Futhark.Bench: Result :: [RunResult] -> Map Text Int -> Maybe Text -> Maybe ProfilingReport -> Result
- Futhark.Bench: RunOptions :: Int -> NominalDiffTime -> Int -> Int -> Bool -> NominalDiffTime -> ((Int, Maybe Double) -> IO ()) -> Bool -> RunOptions
- Futhark.Bench: RunResult :: Int -> RunResult
- Futhark.Bench: [benchResultProg] :: BenchResult -> FilePath
- Futhark.Bench: [benchResultResults] :: BenchResult -> [DataResult]
- Futhark.Bench: [compBackend] :: CompileOptions -> String
- Futhark.Bench: [compFuthark] :: CompileOptions -> String
- Futhark.Bench: [compOptions] :: CompileOptions -> [String]
- Futhark.Bench: [memoryMap] :: Result -> Map Text Int
- Futhark.Bench: [report] :: Result -> Maybe ProfilingReport
- Futhark.Bench: [runConvergenceMaxTime] :: RunOptions -> NominalDiffTime
- Futhark.Bench: [runConvergencePhase] :: RunOptions -> Bool
- Futhark.Bench: [runMicroseconds] :: RunResult -> Int
- Futhark.Bench: [runMinRuns] :: RunOptions -> Int
- Futhark.Bench: [runMinTime] :: RunOptions -> NominalDiffTime
- Futhark.Bench: [runProfile] :: RunOptions -> Bool
- Futhark.Bench: [runResultAction] :: RunOptions -> (Int, Maybe Double) -> IO ()
- Futhark.Bench: [runResults] :: Result -> [RunResult]
- Futhark.Bench: [runTimeout] :: RunOptions -> Int
- Futhark.Bench: [runVerbose] :: RunOptions -> Int
- Futhark.Bench: [stdErr] :: Result -> Maybe Text
- Futhark.Bench: benchmarkDataset :: Server -> RunOptions -> FutharkExe -> FilePath -> Text -> Values -> Maybe Success -> FilePath -> IO (Either Text ([RunResult], Text, ProfilingReport))
- Futhark.Bench: binaryName :: FilePath -> FilePath
- Futhark.Bench: data BenchResult
- Futhark.Bench: data CompileOptions
- Futhark.Bench: data DataResult
- Futhark.Bench: data Result
- Futhark.Bench: data RunOptions
- Futhark.Bench: decodeBenchResults :: ByteString -> Either String [BenchResult]
- Futhark.Bench: encodeBenchResults :: [BenchResult] -> ByteString
- Futhark.Bench: instance Data.Aeson.Types.FromJSON.FromJSON Futhark.Bench.BenchResults
- Futhark.Bench: instance Data.Aeson.Types.FromJSON.FromJSON Futhark.Bench.DataResults
- Futhark.Bench: instance Data.Aeson.Types.FromJSON.FromJSON Futhark.Bench.Result
- Futhark.Bench: instance Data.Aeson.Types.FromJSON.FromJSON Futhark.Bench.RunResult
- Futhark.Bench: instance Data.Aeson.Types.ToJSON.ToJSON Futhark.Bench.BenchResults
- Futhark.Bench: instance Data.Aeson.Types.ToJSON.ToJSON Futhark.Bench.DataResults
- Futhark.Bench: instance Data.Aeson.Types.ToJSON.ToJSON Futhark.Bench.Result
- Futhark.Bench: instance Data.Aeson.Types.ToJSON.ToJSON Futhark.Bench.RunResult
- Futhark.Bench: instance GHC.Classes.Eq Futhark.Bench.BenchResult
- Futhark.Bench: instance GHC.Classes.Eq Futhark.Bench.DataResult
- Futhark.Bench: instance GHC.Classes.Eq Futhark.Bench.Result
- Futhark.Bench: instance GHC.Classes.Eq Futhark.Bench.RunResult
- Futhark.Bench: instance GHC.Show.Show Futhark.Bench.BenchResult
- Futhark.Bench: instance GHC.Show.Show Futhark.Bench.DataResult
- Futhark.Bench: instance GHC.Show.Show Futhark.Bench.Result
- Futhark.Bench: instance GHC.Show.Show Futhark.Bench.RunResult
- Futhark.Bench: newtype RunResult
- Futhark.Bench: prepareBenchmarkProgram :: MonadIO m => Maybe Int -> CompileOptions -> FilePath -> [InputOutputs] -> m (Either (String, Maybe ByteString) ())
- Futhark.Builder: ($dmmkBodyB) :: (BuilderOps rep, MonadBuilder m, Buildable rep) => Stms rep -> Result -> m (Body rep)
- Futhark.Builder: ($dmmkExpDecB) :: (BuilderOps rep, MonadBuilder m, Buildable rep) => Pat (LetDec rep) -> Exp rep -> m (ExpDec rep)
- Futhark.Builder: ($dmmkLetNamesB) :: (BuilderOps rep, MonadBuilder m, Rep m ~ rep, Buildable rep) => [VName] -> Exp rep -> m (Stm rep)
- Futhark.Builder: class ASTRep rep => BuilderOps rep
- Futhark.Builder: data BuilderT rep (m :: Type -> Type) a
- Futhark.Builder: instance (Futhark.IR.Prop.ASTRep rep, GHC.Base.Monad m) => Futhark.IR.Prop.Scope.HasScope rep (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance (Futhark.IR.Prop.ASTRep rep, GHC.Base.Monad m) => Futhark.IR.Prop.Scope.LocalScope rep (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance (Futhark.MonadFreshNames.MonadFreshNames m, Futhark.Builder.BuilderOps rep) => Futhark.Builder.Class.MonadBuilder (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance Control.Monad.Error.Class.MonadError e m => Control.Monad.Error.Class.MonadError e (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance Control.Monad.Reader.Class.MonadReader r m => Control.Monad.Reader.Class.MonadReader r (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance Control.Monad.State.Class.MonadState s m => Control.Monad.State.Class.MonadState s (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance Control.Monad.Trans.Class.MonadTrans (Futhark.Builder.BuilderT rep)
- Futhark.Builder: instance Control.Monad.Writer.Class.MonadWriter w m => Control.Monad.Writer.Class.MonadWriter w (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance Futhark.MonadFreshNames.MonadFreshNames m => Futhark.MonadFreshNames.MonadFreshNames (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance GHC.Base.Functor m => GHC.Base.Functor (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance GHC.Base.Monad m => GHC.Base.Applicative (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: instance GHC.Base.Monad m => GHC.Base.Monad (Futhark.Builder.BuilderT rep m)
- Futhark.Builder: mkBodyB :: (BuilderOps rep, MonadBuilder m, Rep m ~ rep) => Stms rep -> Result -> m (Body rep)
- Futhark.Builder: mkExpDecB :: (BuilderOps rep, MonadBuilder m, Rep m ~ rep) => Pat (LetDec rep) -> Exp rep -> m (ExpDec rep)
- Futhark.Builder: mkLetNamesB :: (BuilderOps rep, MonadBuilder m, Rep m ~ rep) => [VName] -> Exp rep -> m (Stm rep)
- Futhark.Builder: runBodyBuilder :: (Buildable rep, MonadFreshNames m, HasScope somerep m, SameScope somerep rep) => Builder rep Result -> m (Body rep)
- Futhark.Builder: runBuilder :: (MonadFreshNames m, HasScope somerep m, SameScope somerep rep) => Builder rep a -> m (a, Stms rep)
- Futhark.Builder: runBuilderT :: MonadFreshNames m => BuilderT rep m a -> Scope rep -> m (a, Stms rep)
- Futhark.Builder: runBuilderT' :: (MonadFreshNames m, HasScope somerep m, SameScope somerep rep) => BuilderT rep m a -> m (a, Stms rep)
- Futhark.Builder: runBuilderT'_ :: (MonadFreshNames m, HasScope somerep m, SameScope somerep rep) => BuilderT rep m a -> m (Stms rep)
- Futhark.Builder: runBuilderT_ :: MonadFreshNames m => BuilderT rep m () -> Scope rep -> m (Stms rep)
- Futhark.Builder: runBuilder_ :: (MonadFreshNames m, HasScope somerep m, SameScope somerep rep) => Builder rep a -> m (Stms rep)
- Futhark.Builder: runLambdaBuilder :: (Buildable rep, MonadFreshNames m, HasScope somerep m, SameScope somerep rep) => [LParam rep] -> Builder rep Result -> m (Lambda rep)
- Futhark.Builder: type Builder rep = BuilderT rep State VNameSource
- Futhark.Builder.Class: addStm :: MonadBuilder m => Stm (Rep m) -> m ()
- Futhark.Builder.Class: addStms :: MonadBuilder m => Stms (Rep m) -> m ()
- Futhark.Builder.Class: attributing :: MonadBuilder m => Attrs -> m a -> m a
- Futhark.Builder.Class: auxing :: MonadBuilder m => StmAux anyrep -> m a -> m a
- Futhark.Builder.Class: bodyBind :: MonadBuilder m => Body (Rep m) -> m Result
- Futhark.Builder.Class: certifying :: MonadBuilder m => Certs -> m a -> m a
- Futhark.Builder.Class: class (ASTRep rep, FParamInfo rep ~ DeclType, LParamInfo rep ~ Type, RetType rep ~ DeclExtType, BranchType rep ~ ExtType) => Buildable rep
- Futhark.Builder.Class: class (ASTRep Rep m, MonadFreshNames m, Applicative m, Monad m, LocalScope Rep m m) => MonadBuilder (m :: Type -> Type) where {
- Futhark.Builder.Class: collectStms :: MonadBuilder m => m a -> m (a, Stms (Rep m))
- Futhark.Builder.Class: collectStms_ :: MonadBuilder m => m a -> m (Stms (Rep m))
- Futhark.Builder.Class: insertStm :: Buildable rep => Stm rep -> Body rep -> Body rep
- Futhark.Builder.Class: insertStms :: Buildable rep => Stms rep -> Body rep -> Body rep
- Futhark.Builder.Class: letBind :: MonadBuilder m => Pat (LetDec (Rep m)) -> Exp (Rep m) -> m ()
- Futhark.Builder.Class: letBindNames :: MonadBuilder m => [VName] -> Exp (Rep m) -> m ()
- Futhark.Builder.Class: mkBody :: Buildable rep => Stms rep -> Result -> Body rep
- Futhark.Builder.Class: mkBodyM :: MonadBuilder m => Stms (Rep m) -> Result -> m (Body (Rep m))
- Futhark.Builder.Class: mkExpDec :: Buildable rep => Pat (LetDec rep) -> Exp rep -> ExpDec rep
- Futhark.Builder.Class: mkExpDecM :: MonadBuilder m => Pat (LetDec (Rep m)) -> Exp (Rep m) -> m (ExpDec (Rep m))
- Futhark.Builder.Class: mkExpPat :: Buildable rep => [Ident] -> Exp rep -> Pat (LetDec rep)
- Futhark.Builder.Class: mkLet :: Buildable rep => [Ident] -> Exp rep -> Stm rep
- Futhark.Builder.Class: mkLet' :: Buildable rep => [Ident] -> StmAux a -> Exp rep -> Stm rep
- Futhark.Builder.Class: mkLetNames :: (Buildable rep, MonadFreshNames m, HasScope rep m) => [VName] -> Exp rep -> m (Stm rep)
- Futhark.Builder.Class: mkLetNamesM :: MonadBuilder m => [VName] -> Exp (Rep m) -> m (Stm (Rep m))
- Futhark.Builder.Class: type Rep (m :: Type -> Type);
- Futhark.Builder.Class: }
- Futhark.CLI.Autotune: instance GHC.Show.Show Futhark.CLI.Autotune.DatasetResult
- Futhark.CLI.Autotune: main :: String -> [String] -> IO ()
- Futhark.CLI.Bench: instance GHC.Classes.Eq Futhark.CLI.Bench.SkipReason
- Futhark.CLI.Bench: main :: String -> [String] -> IO ()
- Futhark.CLI.Benchcmp: instance GHC.Show.Show Futhark.CLI.Benchcmp.SpeedUp
- Futhark.CLI.Benchcmp: main :: String -> [String] -> IO ()
- Futhark.CLI.C: main :: String -> [String] -> IO ()
- Futhark.CLI.CUDA: main :: String -> [String] -> IO ()
- Futhark.CLI.Check: main :: String -> [String] -> IO ()
- Futhark.CLI.Datacmp: main :: String -> [String] -> IO ()
- Futhark.CLI.Dataset: instance GHC.Classes.Eq Futhark.CLI.Dataset.OutputFormat
- Futhark.CLI.Dataset: instance GHC.Classes.Ord Futhark.CLI.Dataset.OutputFormat
- Futhark.CLI.Dataset: instance GHC.Show.Show Futhark.CLI.Dataset.OutputFormat
- Futhark.CLI.Dataset: instance System.Random.Internal.UniformRange Numeric.Half.Internal.Half
- Futhark.CLI.Dataset: main :: String -> [String] -> IO ()
- Futhark.CLI.Defs: main :: String -> [String] -> IO ()
- Futhark.CLI.Dev: instance Futhark.CLI.Dev.Representation Futhark.CLI.Dev.UntypedAction
- Futhark.CLI.Dev: instance Futhark.CLI.Dev.Representation Futhark.CLI.Dev.UntypedPassState
- Futhark.CLI.Dev: instance Prettyprinter.Internal.Pretty Futhark.CLI.Dev.UntypedPassState
- Futhark.CLI.Dev: main :: String -> [String] -> IO ()
- Futhark.CLI.Doc: main :: String -> [String] -> IO ()
- Futhark.CLI.Eval: main :: String -> [String] -> IO ()
- Futhark.CLI.Fmt: main :: String -> [String] -> IO ()
- Futhark.CLI.HIP: main :: String -> [String] -> IO ()
- Futhark.CLI.LSP: main :: String -> [String] -> IO ()
- Futhark.CLI.Literate: Options :: String -> Maybe FilePath -> [String] -> [String] -> Bool -> Maybe FilePath -> Int -> Bool -> Bool -> [Either FilePath Text] -> Options
- Futhark.CLI.Literate: [scriptBackend] :: Options -> String
- Futhark.CLI.Literate: [scriptBinary] :: Options -> Bool
- Futhark.CLI.Literate: [scriptCompilerOptions] :: Options -> [String]
- Futhark.CLI.Literate: [scriptExps] :: Options -> [Either FilePath Text]
- Futhark.CLI.Literate: [scriptExtraOptions] :: Options -> [String]
- Futhark.CLI.Literate: [scriptFuthark] :: Options -> Maybe FilePath
- Futhark.CLI.Literate: [scriptOutput] :: Options -> Maybe FilePath
- Futhark.CLI.Literate: [scriptSkipCompilation] :: Options -> Bool
- Futhark.CLI.Literate: [scriptStopOnError] :: Options -> Bool
- Futhark.CLI.Literate: [scriptVerbose] :: Options -> Int
- Futhark.CLI.Literate: data Options
- Futhark.CLI.Literate: initialOptions :: Options
- Futhark.CLI.Literate: instance Control.Monad.Error.Class.MonadError Data.Text.Internal.Text Futhark.CLI.Literate.ScriptM
- Futhark.CLI.Literate: instance Control.Monad.Fail.MonadFail Futhark.CLI.Literate.ScriptM
- Futhark.CLI.Literate: instance Control.Monad.IO.Class.MonadIO Futhark.CLI.Literate.ScriptM
- Futhark.CLI.Literate: instance Control.Monad.State.Class.MonadState Futhark.CLI.Literate.State Futhark.CLI.Literate.ScriptM
- Futhark.CLI.Literate: instance GHC.Base.Applicative Futhark.CLI.Literate.ScriptM
- Futhark.CLI.Literate: instance GHC.Base.Functor Futhark.CLI.Literate.ScriptM
- Futhark.CLI.Literate: instance GHC.Base.Monad Futhark.CLI.Literate.ScriptM
- Futhark.CLI.Literate: instance GHC.Classes.Eq Futhark.CLI.Literate.Failure
- Futhark.CLI.Literate: instance GHC.Classes.Ord Futhark.CLI.Literate.Failure
- Futhark.CLI.Literate: instance GHC.Show.Show Futhark.CLI.Literate.AudioParams
- Futhark.CLI.Literate: instance GHC.Show.Show Futhark.CLI.Literate.Block
- Futhark.CLI.Literate: instance GHC.Show.Show Futhark.CLI.Literate.Directive
- Futhark.CLI.Literate: instance GHC.Show.Show Futhark.CLI.Literate.Failure
- Futhark.CLI.Literate: instance GHC.Show.Show Futhark.CLI.Literate.ImgParams
- Futhark.CLI.Literate: instance GHC.Show.Show Futhark.CLI.Literate.VideoParams
- Futhark.CLI.Literate: instance Prettyprinter.Internal.Pretty Futhark.CLI.Literate.Directive
- Futhark.CLI.Literate: main :: String -> [String] -> IO ()
- Futhark.CLI.Literate: prepareServer :: FilePath -> Options -> (ScriptServer -> IO a) -> IO a
- Futhark.CLI.Literate: scriptCommandLineOptions :: [FunOptDescr Options]
- Futhark.CLI.Main: main :: IO ()
- Futhark.CLI.Misc: mainCheckSyntax :: String -> [String] -> IO ()
- Futhark.CLI.Misc: mainDataget :: String -> [String] -> IO ()
- Futhark.CLI.Misc: mainHash :: String -> [String] -> IO ()
- Futhark.CLI.Misc: mainImports :: String -> [String] -> IO ()
- Futhark.CLI.Misc: mainThanks :: String -> [String] -> IO ()
- Futhark.CLI.Misc: mainTokens :: String -> [String] -> IO ()
- Futhark.CLI.Multicore: main :: String -> [String] -> IO ()
- Futhark.CLI.MulticoreISPC: main :: String -> [String] -> IO ()
- Futhark.CLI.MulticoreWASM: main :: String -> [String] -> IO ()
- Futhark.CLI.OpenCL: main :: String -> [String] -> IO ()
- Futhark.CLI.Pkg: instance Control.Monad.Fail.MonadFail Futhark.CLI.Pkg.PkgM
- Futhark.CLI.Pkg: instance Control.Monad.IO.Class.MonadIO Futhark.CLI.Pkg.PkgM
- Futhark.CLI.Pkg: instance Control.Monad.Reader.Class.MonadReader Futhark.CLI.Pkg.PkgConfig Futhark.CLI.Pkg.PkgM
- Futhark.CLI.Pkg: instance Futhark.Pkg.Info.MonadPkgRegistry Futhark.CLI.Pkg.PkgM
- Futhark.CLI.Pkg: instance Futhark.Util.Log.MonadLogger Futhark.CLI.Pkg.PkgM
- Futhark.CLI.Pkg: instance GHC.Base.Applicative Futhark.CLI.Pkg.PkgM
- Futhark.CLI.Pkg: instance GHC.Base.Functor Futhark.CLI.Pkg.PkgM
- Futhark.CLI.Pkg: instance GHC.Base.Monad Futhark.CLI.Pkg.PkgM
- Futhark.CLI.Pkg: main :: String -> [String] -> IO ()
- Futhark.CLI.Profile: main :: String -> [String] -> IO ()
- Futhark.CLI.PyOpenCL: main :: String -> [String] -> IO ()
- Futhark.CLI.Python: main :: String -> [String] -> IO ()
- Futhark.CLI.Query: main :: String -> [String] -> IO ()
- Futhark.CLI.REPL: instance Control.Monad.Error.Class.MonadError Futhark.CLI.REPL.StopReason Futhark.CLI.REPL.FutharkiM
- Futhark.CLI.REPL: instance Control.Monad.IO.Class.MonadIO Futhark.CLI.REPL.FutharkiM
- Futhark.CLI.REPL: instance Control.Monad.State.Class.MonadState Futhark.CLI.REPL.FutharkiState Futhark.CLI.REPL.FutharkiM
- Futhark.CLI.REPL: instance GHC.Base.Applicative Futhark.CLI.REPL.FutharkiM
- Futhark.CLI.REPL: instance GHC.Base.Functor Futhark.CLI.REPL.FutharkiM
- Futhark.CLI.REPL: instance GHC.Base.Monad Futhark.CLI.REPL.FutharkiM
- Futhark.CLI.REPL: main :: String -> [String] -> IO ()
- Futhark.CLI.Run: main :: String -> [String] -> IO ()
- Futhark.CLI.Script: main :: String -> [String] -> IO ()
- Futhark.CLI.Test: instance GHC.Classes.Eq Futhark.CLI.Test.TestCase
- Futhark.CLI.Test: instance GHC.Classes.Eq Futhark.CLI.Test.TestMode
- Futhark.CLI.Test: instance GHC.Classes.Eq Futhark.CLI.Test.TestResult
- Futhark.CLI.Test: instance GHC.Classes.Ord Futhark.CLI.Test.TestCase
- Futhark.CLI.Test: instance GHC.Show.Show Futhark.CLI.Test.ProgConfig
- Futhark.CLI.Test: instance GHC.Show.Show Futhark.CLI.Test.TestCase
- Futhark.CLI.Test: instance GHC.Show.Show Futhark.CLI.Test.TestMode
- Futhark.CLI.Test: instance GHC.Show.Show Futhark.CLI.Test.TestResult
- Futhark.CLI.Test: main :: String -> [String] -> IO ()
- Futhark.CLI.WASM: main :: String -> [String] -> IO ()
- Futhark.CodeGen.Backends.CCUDA: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.CCUDA: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.CCUDA: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.CCUDA: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.CCUDA: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.CCUDA: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.CCUDA: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.CCUDA: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.CCUDA: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.CCUDA: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.CCUDA: compileProg :: MonadFreshNames m => Text -> Prog GPUMem -> m (Warnings, CParts)
- Futhark.CodeGen.Backends.CCUDA: data CParts
- Futhark.CodeGen.Backends.COpenCL: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.COpenCL: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.COpenCL: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.COpenCL: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.COpenCL: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.COpenCL: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.COpenCL: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.COpenCL: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.COpenCL: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.COpenCL: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.COpenCL: compileProg :: MonadFreshNames m => Text -> Prog GPUMem -> m (Warnings, CParts)
- Futhark.CodeGen.Backends.COpenCL: data CParts
- Futhark.CodeGen.Backends.GPU: generateGPUBoilerplate :: Text -> [(Name, KernelConstExp)] -> Text -> [Name] -> [PrimType] -> [FailureMsg] -> CompilerM OpenCL () ()
- Futhark.CodeGen.Backends.GPU: gpuOperations :: Operations OpenCL ()
- Futhark.CodeGen.Backends.GPU: gpuOptions :: [Option]
- Futhark.CodeGen.Backends.GenericC: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.GenericC: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericC: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericC: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericC: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericC: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericC: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericC: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.GenericC: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.GenericC: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.GenericC: compileProg :: MonadFreshNames m => Text -> Text -> ParamMap -> Operations op () -> CompilerM op () () -> Text -> (Space, [Space]) -> [Option] -> Definitions op -> m CParts
- Futhark.CodeGen.Backends.GenericC: compileProg' :: MonadFreshNames m => Text -> Text -> ParamMap -> Operations op s -> s -> CompilerM op s () -> Text -> (Space, [Space]) -> [Option] -> Definitions op -> m (CParts, CompilerState s)
- Futhark.CodeGen.Backends.GenericC: data CParts
- Futhark.CodeGen.Backends.GenericC: defaultOperations :: Operations op s
- Futhark.CodeGen.Backends.GenericC: type ParamMap = Map Name (SizeClass, Set Name)
- Futhark.CodeGen.Backends.GenericC.CLI: cliDefs :: [Option] -> Manifest -> Text
- Futhark.CodeGen.Backends.GenericC.Code: compileArg :: Arg -> CompilerM op s Exp
- Futhark.CodeGen.Backends.GenericC.Code: compileCode :: Code op -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Code: compileCopy :: PrimType -> [Count Elements (TExp Int64)] -> (VName, Space) -> (Count Elements (TExp Int64), [Count Elements (TExp Int64)]) -> (VName, Space) -> (Count Elements (TExp Int64), [Count Elements (TExp Int64)]) -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Code: compileCopyWith :: [Count Elements (TExp Int64)] -> (Exp -> Exp -> CompilerM op s ()) -> (Count Elements (TExp Int64), [Count Elements (TExp Int64)]) -> (Exp -> CompilerM op s Exp) -> (Count Elements (TExp Int64), [Count Elements (TExp Int64)]) -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Code: compileDest :: VName -> CompilerM op s (VName, [Stm])
- Futhark.CodeGen.Backends.GenericC.Code: compileExp :: Exp -> CompilerM op s Exp
- Futhark.CodeGen.Backends.GenericC.Code: compilePrimExp :: Monad m => (v -> m Exp) -> PrimExp v -> m Exp
- Futhark.CodeGen.Backends.GenericC.Code: errorMsgString :: ErrorMsg Exp -> CompilerM op s (String, [Exp])
- Futhark.CodeGen.Backends.GenericC.Code: instance forall k (t :: k). Language.C.Quote.Base.ToExp (Futhark.CodeGen.ImpCode.TExp t)
- Futhark.CodeGen.Backends.GenericC.Code: linearCode :: Code op -> [Code op]
- Futhark.CodeGen.Backends.GenericC.EntryPoints: onEntryPoint :: [BlockItem] -> [Name] -> Name -> Function op -> CompilerM op s (Maybe (Definition, (Text, EntryPoint)))
- Futhark.CodeGen.Backends.GenericC.Fun: compileFun :: [BlockItem] -> [Param] -> (Name, Function op) -> CompilerM op s (Definition, Func)
- Futhark.CodeGen.Backends.GenericC.Fun: compileVoidFun :: [BlockItem] -> (Name, Function op) -> CompilerM op s (Definition, Func)
- Futhark.CodeGen.Backends.GenericC.Monad: ArrayDecl :: Name -> HeaderSection
- Futhark.CodeGen.Backends.GenericC.Monad: CompilerEnv :: Operations op s -> Map Exp VName -> CompilerEnv op s
- Futhark.CodeGen.Backends.GenericC.Monad: CompilerState :: Map ArrayType Publicness -> DList Definition -> VNameSource -> s -> Map HeaderSection (DList Definition) -> DList Definition -> DList (Id, Type, Maybe Exp, Maybe (Stm, Stm)) -> DList BlockItem -> [(VName, Space)] -> DList BlockItem -> CompilerState s
- Futhark.CodeGen.Backends.GenericC.Monad: CopyBarrier :: CopyBarrier
- Futhark.CodeGen.Backends.GenericC.Monad: CopyNoBarrier :: CopyBarrier
- Futhark.CodeGen.Backends.GenericC.Monad: EntryDecl :: HeaderSection
- Futhark.CodeGen.Backends.GenericC.Monad: InitDecl :: HeaderSection
- Futhark.CodeGen.Backends.GenericC.Monad: MiscDecl :: HeaderSection
- Futhark.CodeGen.Backends.GenericC.Monad: OpaqueDecl :: Name -> HeaderSection
- Futhark.CodeGen.Backends.GenericC.Monad: OpaqueTypeDecl :: Name -> HeaderSection
- Futhark.CodeGen.Backends.GenericC.Monad: Operations :: WriteScalar op s -> ReadScalar op s -> Allocate op s -> Deallocate op s -> Copy op s -> MemoryType op s -> OpCompiler op s -> ErrorCompiler op s -> CallCompiler op s -> Map (Space, Space) (DoCopy op s) -> Bool -> ([BlockItem], [BlockItem]) -> Operations op s
- Futhark.CodeGen.Backends.GenericC.Monad: Private :: Publicness
- Futhark.CodeGen.Backends.GenericC.Monad: Public :: Publicness
- Futhark.CodeGen.Backends.GenericC.Monad: [compArrayTypes] :: CompilerState s -> Map ArrayType Publicness
- Futhark.CodeGen.Backends.GenericC.Monad: [compClearItems] :: CompilerState s -> DList BlockItem
- Futhark.CodeGen.Backends.GenericC.Monad: [compCtxFields] :: CompilerState s -> DList (Id, Type, Maybe Exp, Maybe (Stm, Stm))
- Futhark.CodeGen.Backends.GenericC.Monad: [compDeclaredMem] :: CompilerState s -> [(VName, Space)]
- Futhark.CodeGen.Backends.GenericC.Monad: [compEarlyDecls] :: CompilerState s -> DList Definition
- Futhark.CodeGen.Backends.GenericC.Monad: [compHeaderDecls] :: CompilerState s -> Map HeaderSection (DList Definition)
- Futhark.CodeGen.Backends.GenericC.Monad: [compItems] :: CompilerState s -> DList BlockItem
- Futhark.CodeGen.Backends.GenericC.Monad: [compLibDecls] :: CompilerState s -> DList Definition
- Futhark.CodeGen.Backends.GenericC.Monad: [compNameSrc] :: CompilerState s -> VNameSource
- Futhark.CodeGen.Backends.GenericC.Monad: [compUserState] :: CompilerState s -> s
- Futhark.CodeGen.Backends.GenericC.Monad: [envCachedMem] :: CompilerEnv op s -> Map Exp VName
- Futhark.CodeGen.Backends.GenericC.Monad: [envOperations] :: CompilerEnv op s -> Operations op s
- Futhark.CodeGen.Backends.GenericC.Monad: [opsAllocate] :: Operations op s -> Allocate op s
- Futhark.CodeGen.Backends.GenericC.Monad: [opsCall] :: Operations op s -> CallCompiler op s
- Futhark.CodeGen.Backends.GenericC.Monad: [opsCompiler] :: Operations op s -> OpCompiler op s
- Futhark.CodeGen.Backends.GenericC.Monad: [opsCopies] :: Operations op s -> Map (Space, Space) (DoCopy op s)
- Futhark.CodeGen.Backends.GenericC.Monad: [opsCopy] :: Operations op s -> Copy op s
- Futhark.CodeGen.Backends.GenericC.Monad: [opsCritical] :: Operations op s -> ([BlockItem], [BlockItem])
- Futhark.CodeGen.Backends.GenericC.Monad: [opsDeallocate] :: Operations op s -> Deallocate op s
- Futhark.CodeGen.Backends.GenericC.Monad: [opsError] :: Operations op s -> ErrorCompiler op s
- Futhark.CodeGen.Backends.GenericC.Monad: [opsFatMemory] :: Operations op s -> Bool
- Futhark.CodeGen.Backends.GenericC.Monad: [opsMemoryType] :: Operations op s -> MemoryType op s
- Futhark.CodeGen.Backends.GenericC.Monad: [opsReadScalar] :: Operations op s -> ReadScalar op s
- Futhark.CodeGen.Backends.GenericC.Monad: [opsWriteScalar] :: Operations op s -> WriteScalar op s
- Futhark.CodeGen.Backends.GenericC.Monad: allocMem :: (ToExp a, ToExp b) => a -> b -> Space -> Stm -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: allocRawMem :: (ToExp a, ToExp b, ToExp c) => a -> b -> Space -> c -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: cacheMem :: ToExp a => a -> CompilerM op s (Maybe VName)
- Futhark.CodeGen.Backends.GenericC.Monad: cachingMemory :: Map VName Space -> ([BlockItem] -> [Stm] -> CompilerM op s a) -> CompilerM op s a
- Futhark.CodeGen.Backends.GenericC.Monad: collect :: CompilerM op s () -> CompilerM op s [BlockItem]
- Futhark.CodeGen.Backends.GenericC.Monad: collect' :: CompilerM op s a -> CompilerM op s (a, [BlockItem])
- Futhark.CodeGen.Backends.GenericC.Monad: configType :: CompilerM op s Type
- Futhark.CodeGen.Backends.GenericC.Monad: contextField :: Id -> Type -> Maybe Exp -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: contextFieldDyn :: Id -> Type -> Stm -> Stm -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: contextType :: CompilerM op s Type
- Futhark.CodeGen.Backends.GenericC.Monad: copyMemoryDefaultSpace :: Exp -> Exp -> Exp -> Exp -> Exp -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: criticalSection :: Operations op s -> [BlockItem] -> [BlockItem]
- Futhark.CodeGen.Backends.GenericC.Monad: data CompilerEnv op s
- Futhark.CodeGen.Backends.GenericC.Monad: data CompilerM op s a
- Futhark.CodeGen.Backends.GenericC.Monad: data CompilerState s
- Futhark.CodeGen.Backends.GenericC.Monad: data CopyBarrier
- Futhark.CodeGen.Backends.GenericC.Monad: data HeaderSection
- Futhark.CodeGen.Backends.GenericC.Monad: data Operations op s
- Futhark.CodeGen.Backends.GenericC.Monad: data Publicness
- Futhark.CodeGen.Backends.GenericC.Monad: decl :: InitGroup -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: declAllocatedMem :: CompilerM op s [BlockItem]
- Futhark.CodeGen.Backends.GenericC.Monad: declMem :: VName -> Space -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: derefPointer :: Exp -> Exp -> Type -> Exp
- Futhark.CodeGen.Backends.GenericC.Monad: earlyDecl :: Definition -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: fatMemAlloc :: Space -> String
- Futhark.CodeGen.Backends.GenericC.Monad: fatMemSet :: Space -> String
- Futhark.CodeGen.Backends.GenericC.Monad: fatMemType :: Space -> Type
- Futhark.CodeGen.Backends.GenericC.Monad: fatMemUnRef :: Space -> String
- Futhark.CodeGen.Backends.GenericC.Monad: fatMemory :: Space -> CompilerM op s Bool
- Futhark.CodeGen.Backends.GenericC.Monad: freeAllocatedMem :: CompilerM op s [BlockItem]
- Futhark.CodeGen.Backends.GenericC.Monad: freeRawMem :: (ToExp a, ToExp b, ToExp c) => a -> b -> Space -> c -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: generateProgramStruct :: CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: getUserState :: CompilerM op s s
- Futhark.CodeGen.Backends.GenericC.Monad: headerDecl :: HeaderSection -> Definition -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: inNewFunction :: CompilerM op s a -> CompilerM op s a
- Futhark.CodeGen.Backends.GenericC.Monad: instance Control.Monad.Reader.Class.MonadReader (Futhark.CodeGen.Backends.GenericC.Monad.CompilerEnv op s) (Futhark.CodeGen.Backends.GenericC.Monad.CompilerM op s)
- Futhark.CodeGen.Backends.GenericC.Monad: instance Control.Monad.State.Class.MonadState (Futhark.CodeGen.Backends.GenericC.Monad.CompilerState s) (Futhark.CodeGen.Backends.GenericC.Monad.CompilerM op s)
- Futhark.CodeGen.Backends.GenericC.Monad: instance Futhark.MonadFreshNames.MonadFreshNames (Futhark.CodeGen.Backends.GenericC.Monad.CompilerM op s)
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Base.Applicative (Futhark.CodeGen.Backends.GenericC.Monad.CompilerM op s)
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Base.Functor (Futhark.CodeGen.Backends.GenericC.Monad.CompilerM op s)
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Base.Monad (Futhark.CodeGen.Backends.GenericC.Monad.CompilerM op s)
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericC.Monad.CopyBarrier
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericC.Monad.HeaderSection
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericC.Monad.Publicness
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Classes.Ord Futhark.CodeGen.Backends.GenericC.Monad.HeaderSection
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Classes.Ord Futhark.CodeGen.Backends.GenericC.Monad.Publicness
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericC.Monad.CopyBarrier
- Futhark.CodeGen.Backends.GenericC.Monad: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericC.Monad.Publicness
- Futhark.CodeGen.Backends.GenericC.Monad: item :: BlockItem -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: items :: [BlockItem] -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: libDecl :: Definition -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: memToCType :: VName -> Space -> CompilerM op s Type
- Futhark.CodeGen.Backends.GenericC.Monad: modifyUserState :: (s -> s) -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: onClear :: BlockItem -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: publicDef :: Text -> HeaderSection -> (Text -> (Definition, Definition)) -> CompilerM op s Text
- Futhark.CodeGen.Backends.GenericC.Monad: publicDef_ :: Text -> HeaderSection -> (Text -> (Definition, Definition)) -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: publicName :: Text -> CompilerM op s Text
- Futhark.CodeGen.Backends.GenericC.Monad: rawMem :: VName -> CompilerM op s Exp
- Futhark.CodeGen.Backends.GenericC.Monad: rawMemCType :: Space -> CompilerM op s Type
- Futhark.CodeGen.Backends.GenericC.Monad: readScalarPointerWithQuals :: PointerQuals -> ReadScalar op s
- Futhark.CodeGen.Backends.GenericC.Monad: resetMem :: ToExp a => a -> Space -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: runCompilerM :: Operations op s -> VNameSource -> s -> CompilerM op s a -> (a, CompilerState s)
- Futhark.CodeGen.Backends.GenericC.Monad: setMem :: (ToExp a, ToExp b) => a -> b -> Space -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: stm :: Stm -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: stms :: [Stm] -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: type Allocate op s = Exp -> Exp -> Exp -> SpaceId -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: type CallCompiler op s = [VName] -> Name -> [Exp] -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: type Copy op s = CopyBarrier -> Exp -> Exp -> Space -> Exp -> Exp -> Space -> Exp -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: type Deallocate op s = Exp -> Exp -> Exp -> SpaceId -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: type DoCopy op s = CopyBarrier -> PrimType -> [Count Elements Exp] -> Exp -> (Count Elements Exp, [Count Elements Exp]) -> Exp -> (Count Elements Exp, [Count Elements Exp]) -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: type ErrorCompiler op s = ErrorMsg Exp -> String -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: type MemoryType op s = SpaceId -> CompilerM op s Type
- Futhark.CodeGen.Backends.GenericC.Monad: type OpCompiler op s = op -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: type PointerQuals = String -> [TypeQual]
- Futhark.CodeGen.Backends.GenericC.Monad: type ReadScalar op s = Exp -> Exp -> Type -> SpaceId -> Volatility -> CompilerM op s Exp
- Futhark.CodeGen.Backends.GenericC.Monad: type WriteScalar op s = Exp -> Exp -> Type -> SpaceId -> Volatility -> Exp -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: unRefMem :: ToExp a => a -> Space -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericC.Monad: volQuals :: Volatility -> [TypeQual]
- Futhark.CodeGen.Backends.GenericC.Monad: writeScalarPointerWithQuals :: PointerQuals -> WriteScalar op s
- Futhark.CodeGen.Backends.GenericC.Options: NoArgument :: OptionArgument
- Futhark.CodeGen.Backends.GenericC.Options: Option :: String -> Maybe Char -> OptionArgument -> String -> Stm -> Option
- Futhark.CodeGen.Backends.GenericC.Options: OptionalArgument :: OptionArgument
- Futhark.CodeGen.Backends.GenericC.Options: RequiredArgument :: String -> OptionArgument
- Futhark.CodeGen.Backends.GenericC.Options: [optionAction] :: Option -> Stm
- Futhark.CodeGen.Backends.GenericC.Options: [optionArgument] :: Option -> OptionArgument
- Futhark.CodeGen.Backends.GenericC.Options: [optionDescription] :: Option -> String
- Futhark.CodeGen.Backends.GenericC.Options: [optionLongName] :: Option -> String
- Futhark.CodeGen.Backends.GenericC.Options: [optionShortName] :: Option -> Maybe Char
- Futhark.CodeGen.Backends.GenericC.Options: data Option
- Futhark.CodeGen.Backends.GenericC.Options: data OptionArgument
- Futhark.CodeGen.Backends.GenericC.Options: generateOptionParser :: String -> [Option] -> Func
- Futhark.CodeGen.Backends.GenericC.Pretty: definitionsText :: [Definition] -> Text
- Futhark.CodeGen.Backends.GenericC.Pretty: expText :: Exp -> Text
- Futhark.CodeGen.Backends.GenericC.Pretty: funcText :: Func -> Text
- Futhark.CodeGen.Backends.GenericC.Pretty: funcsText :: [Func] -> Text
- Futhark.CodeGen.Backends.GenericC.Pretty: idText :: Id -> Text
- Futhark.CodeGen.Backends.GenericC.Pretty: typeText :: Type -> Text
- Futhark.CodeGen.Backends.GenericC.Server: serverDefs :: [Option] -> Manifest -> Text
- Futhark.CodeGen.Backends.GenericC.Types: generateAPITypes :: Space -> OpaqueTypes -> CompilerM op s (Map Text Type)
- Futhark.CodeGen.Backends.GenericC.Types: opaqueToCType :: Name -> CompilerM op s Type
- Futhark.CodeGen.Backends.GenericC.Types: valueTypeToCType :: Publicness -> ValueType -> CompilerM op s Type
- Futhark.CodeGen.Backends.GenericPython: CompilerEnv :: Operations op s -> Map String PyExp -> CompilerEnv op s
- Futhark.CodeGen.Backends.GenericPython: CompilerM :: RWS (CompilerEnv op s) [PyStmt] (CompilerState s) a -> CompilerM op s a
- Futhark.CodeGen.Backends.GenericPython: CompilerState :: VNameSource -> [PyStmt] -> s -> CompilerState s
- Futhark.CodeGen.Backends.GenericPython: Constructor :: [String] -> [PyStmt] -> Constructor
- Futhark.CodeGen.Backends.GenericPython: Operations :: WriteScalar op s -> ReadScalar op s -> Allocate op s -> Map (Space, Space) (DoCopy op s) -> OpCompiler op s -> EntryOutput op s -> EntryInput op s -> Operations op s
- Futhark.CodeGen.Backends.GenericPython: [compInit] :: CompilerState s -> [PyStmt]
- Futhark.CodeGen.Backends.GenericPython: [compNameSrc] :: CompilerState s -> VNameSource
- Futhark.CodeGen.Backends.GenericPython: [compUserState] :: CompilerState s -> s
- Futhark.CodeGen.Backends.GenericPython: [envOperations] :: CompilerEnv op s -> Operations op s
- Futhark.CodeGen.Backends.GenericPython: [envVarExp] :: CompilerEnv op s -> Map String PyExp
- Futhark.CodeGen.Backends.GenericPython: [opsAllocate] :: Operations op s -> Allocate op s
- Futhark.CodeGen.Backends.GenericPython: [opsCompiler] :: Operations op s -> OpCompiler op s
- Futhark.CodeGen.Backends.GenericPython: [opsCopies] :: Operations op s -> Map (Space, Space) (DoCopy op s)
- Futhark.CodeGen.Backends.GenericPython: [opsEntryInput] :: Operations op s -> EntryInput op s
- Futhark.CodeGen.Backends.GenericPython: [opsEntryOutput] :: Operations op s -> EntryOutput op s
- Futhark.CodeGen.Backends.GenericPython: [opsReadScalar] :: Operations op s -> ReadScalar op s
- Futhark.CodeGen.Backends.GenericPython: [opsWriteScalar] :: Operations op s -> WriteScalar op s
- Futhark.CodeGen.Backends.GenericPython: atInit :: PyStmt -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython: collect :: CompilerM op s () -> CompilerM op s [PyStmt]
- Futhark.CodeGen.Backends.GenericPython: collect' :: CompilerM op s a -> CompilerM op s (a, [PyStmt])
- Futhark.CodeGen.Backends.GenericPython: compileCode :: Code op -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython: compileDim :: DimSize -> CompilerM op s PyExp
- Futhark.CodeGen.Backends.GenericPython: compileExp :: Exp -> CompilerM op s PyExp
- Futhark.CodeGen.Backends.GenericPython: compileName :: VName -> String
- Futhark.CodeGen.Backends.GenericPython: compilePrimExp :: Monad m => (v -> m PyExp) -> PrimExp v -> m PyExp
- Futhark.CodeGen.Backends.GenericPython: compilePrimToExtNp :: PrimType -> Signedness -> String
- Futhark.CodeGen.Backends.GenericPython: compilePrimToNp :: PrimType -> String
- Futhark.CodeGen.Backends.GenericPython: compilePrimType :: PrimType -> String
- Futhark.CodeGen.Backends.GenericPython: compilePrimValue :: PrimValue -> PyExp
- Futhark.CodeGen.Backends.GenericPython: compileProg :: MonadFreshNames m => CompilerMode -> String -> Constructor -> [PyStmt] -> [PyStmt] -> Operations op s -> s -> [PyStmt] -> [Option] -> Definitions op -> m Text
- Futhark.CodeGen.Backends.GenericPython: compileVar :: VName -> CompilerM op s PyExp
- Futhark.CodeGen.Backends.GenericPython: data CompilerEnv op s
- Futhark.CodeGen.Backends.GenericPython: data CompilerMode
- Futhark.CodeGen.Backends.GenericPython: data CompilerState s
- Futhark.CodeGen.Backends.GenericPython: data Constructor
- Futhark.CodeGen.Backends.GenericPython: data Operations op s
- Futhark.CodeGen.Backends.GenericPython: defaultOperations :: Operations op s
- Futhark.CodeGen.Backends.GenericPython: emptyConstructor :: Constructor
- Futhark.CodeGen.Backends.GenericPython: fromStorage :: PrimType -> PyExp -> PyExp
- Futhark.CodeGen.Backends.GenericPython: instance Control.Monad.Reader.Class.MonadReader (Futhark.CodeGen.Backends.GenericPython.CompilerEnv op s) (Futhark.CodeGen.Backends.GenericPython.CompilerM op s)
- Futhark.CodeGen.Backends.GenericPython: instance Control.Monad.State.Class.MonadState (Futhark.CodeGen.Backends.GenericPython.CompilerState s) (Futhark.CodeGen.Backends.GenericPython.CompilerM op s)
- Futhark.CodeGen.Backends.GenericPython: instance Control.Monad.Writer.Class.MonadWriter [Futhark.CodeGen.Backends.GenericPython.AST.PyStmt] (Futhark.CodeGen.Backends.GenericPython.CompilerM op s)
- Futhark.CodeGen.Backends.GenericPython: instance Futhark.MonadFreshNames.MonadFreshNames (Futhark.CodeGen.Backends.GenericPython.CompilerM op s)
- Futhark.CodeGen.Backends.GenericPython: instance GHC.Base.Applicative (Futhark.CodeGen.Backends.GenericPython.CompilerM op s)
- Futhark.CodeGen.Backends.GenericPython: instance GHC.Base.Functor (Futhark.CodeGen.Backends.GenericPython.CompilerM op s)
- Futhark.CodeGen.Backends.GenericPython: instance GHC.Base.Monad (Futhark.CodeGen.Backends.GenericPython.CompilerM op s)
- Futhark.CodeGen.Backends.GenericPython: newtype CompilerM op s a
- Futhark.CodeGen.Backends.GenericPython: simpleCall :: String -> [PyExp] -> PyExp
- Futhark.CodeGen.Backends.GenericPython: stm :: PyStmt -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython: toStorage :: PrimType -> PyExp -> PyExp
- Futhark.CodeGen.Backends.GenericPython: type Allocate op s = PyExp -> PyExp -> SpaceId -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython: type Copy op s = PyExp -> PyExp -> Space -> PyExp -> PyExp -> Space -> PyExp -> PrimType -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython: type DoCopy op s = PrimType -> [Count Elements PyExp] -> PyExp -> (Count Elements PyExp, [Count Elements PyExp]) -> PyExp -> (Count Elements PyExp, [Count Elements PyExp]) -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython: type EntryInput op s = PyExp -> SpaceId -> PrimType -> Signedness -> [DimSize] -> PyExp -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython: type EntryOutput op s = VName -> SpaceId -> PrimType -> Signedness -> [DimSize] -> CompilerM op s PyExp
- Futhark.CodeGen.Backends.GenericPython: type OpCompiler op s = op -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython: type ReadScalar op s = PyExp -> PyExp -> PrimType -> SpaceId -> CompilerM op s PyExp
- Futhark.CodeGen.Backends.GenericPython: type WriteScalar op s = PyExp -> PyExp -> PrimType -> SpaceId -> PyExp -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython: unpackDim :: PyExp -> DimSize -> Int32 -> CompilerM op s ()
- Futhark.CodeGen.Backends.GenericPython.AST: Arg :: PyExp -> PyArg
- Futhark.CodeGen.Backends.GenericPython.AST: ArgKeyword :: String -> PyExp -> PyArg
- Futhark.CodeGen.Backends.GenericPython.AST: Assert :: PyExp -> PyExp -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: Assign :: PyExp -> PyExp -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: AssignOp :: String -> PyExp -> PyExp -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: BinOp :: String -> PyExp -> PyExp -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Bool :: Bool -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Call :: PyExp -> [PyArg] -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Catch :: PyExp -> [PyStmt] -> PyExcept
- Futhark.CodeGen.Backends.GenericPython.AST: Class :: String -> [PyStmt] -> PyClassDef
- Futhark.CodeGen.Backends.GenericPython.AST: ClassDef :: PyClassDef -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: Comment :: String -> [PyStmt] -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: Cond :: PyExp -> PyExp -> PyExp -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Def :: String -> [String] -> [PyStmt] -> PyFunDef
- Futhark.CodeGen.Backends.GenericPython.AST: Dict :: [(PyExp, PyExp)] -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Escape :: Text -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: Exp :: PyExp -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: Field :: PyExp -> String -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Float :: Double -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: For :: String -> PyExp -> [PyStmt] -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: FunDef :: PyFunDef -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: IdxExp :: PyExp -> PyIdx
- Futhark.CodeGen.Backends.GenericPython.AST: IdxRange :: PyExp -> PyExp -> PyIdx
- Futhark.CodeGen.Backends.GenericPython.AST: If :: PyExp -> [PyStmt] -> [PyStmt] -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: Import :: String -> Maybe String -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: Index :: PyExp -> PyIdx -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Integer :: Integer -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Lambda :: String -> PyExp -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: List :: [PyExp] -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: None :: PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Pass :: PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: PyProg :: [PyStmt] -> PyProg
- Futhark.CodeGen.Backends.GenericPython.AST: Raise :: PyExp -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: RawStringLiteral :: Text -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Return :: PyExp -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: String :: Text -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Try :: [PyStmt] -> [PyExcept] -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: Tuple :: [PyExp] -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: UnOp :: String -> PyExp -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: Var :: String -> PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: While :: PyExp -> [PyStmt] -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: With :: PyExp -> [PyStmt] -> PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: data PyArg
- Futhark.CodeGen.Backends.GenericPython.AST: data PyClassDef
- Futhark.CodeGen.Backends.GenericPython.AST: data PyExcept
- Futhark.CodeGen.Backends.GenericPython.AST: data PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: data PyFunDef
- Futhark.CodeGen.Backends.GenericPython.AST: data PyIdx
- Futhark.CodeGen.Backends.GenericPython.AST: data PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericPython.AST.PyArg
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericPython.AST.PyClassDef
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericPython.AST.PyExcept
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericPython.AST.PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericPython.AST.PyFunDef
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericPython.AST.PyIdx
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericPython.AST.PyProg
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericPython.AST.PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Classes.Eq Futhark.CodeGen.Backends.GenericPython.AST.UnOp
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericPython.AST.PyArg
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericPython.AST.PyClassDef
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericPython.AST.PyExcept
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericPython.AST.PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericPython.AST.PyFunDef
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericPython.AST.PyIdx
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericPython.AST.PyProg
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericPython.AST.PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: instance GHC.Show.Show Futhark.CodeGen.Backends.GenericPython.AST.UnOp
- Futhark.CodeGen.Backends.GenericPython.AST: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.Backends.GenericPython.AST.PyArg
- Futhark.CodeGen.Backends.GenericPython.AST: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.Backends.GenericPython.AST.PyClassDef
- Futhark.CodeGen.Backends.GenericPython.AST: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.Backends.GenericPython.AST.PyExcept
- Futhark.CodeGen.Backends.GenericPython.AST: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.Backends.GenericPython.AST.PyExp
- Futhark.CodeGen.Backends.GenericPython.AST: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.Backends.GenericPython.AST.PyFunDef
- Futhark.CodeGen.Backends.GenericPython.AST: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.Backends.GenericPython.AST.PyIdx
- Futhark.CodeGen.Backends.GenericPython.AST: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.Backends.GenericPython.AST.PyProg
- Futhark.CodeGen.Backends.GenericPython.AST: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.Backends.GenericPython.AST.PyStmt
- Futhark.CodeGen.Backends.GenericPython.AST: newtype PyProg
- Futhark.CodeGen.Backends.GenericPython.Options: NoArgument :: OptionArgument
- Futhark.CodeGen.Backends.GenericPython.Options: Option :: Text -> Maybe Char -> OptionArgument -> [PyStmt] -> Option
- Futhark.CodeGen.Backends.GenericPython.Options: OptionalArgument :: OptionArgument
- Futhark.CodeGen.Backends.GenericPython.Options: RequiredArgument :: String -> OptionArgument
- Futhark.CodeGen.Backends.GenericPython.Options: [optionAction] :: Option -> [PyStmt]
- Futhark.CodeGen.Backends.GenericPython.Options: [optionArgument] :: Option -> OptionArgument
- Futhark.CodeGen.Backends.GenericPython.Options: [optionLongName] :: Option -> Text
- Futhark.CodeGen.Backends.GenericPython.Options: [optionShortName] :: Option -> Maybe Char
- Futhark.CodeGen.Backends.GenericPython.Options: data Option
- Futhark.CodeGen.Backends.GenericPython.Options: data OptionArgument
- Futhark.CodeGen.Backends.GenericPython.Options: generateOptionParser :: [Option] -> [PyStmt]
- Futhark.CodeGen.Backends.GenericWASM: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.GenericWASM: JSEntryPoint :: String -> [EntryPointType] -> [EntryPointType] -> JSEntryPoint
- Futhark.CodeGen.Backends.GenericWASM: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericWASM: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericWASM: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericWASM: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericWASM: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericWASM: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.GenericWASM: [name] :: JSEntryPoint -> String
- Futhark.CodeGen.Backends.GenericWASM: [parameters] :: JSEntryPoint -> [EntryPointType]
- Futhark.CodeGen.Backends.GenericWASM: [ret] :: JSEntryPoint -> [EntryPointType]
- Futhark.CodeGen.Backends.GenericWASM: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.GenericWASM: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.GenericWASM: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.GenericWASM: data CParts
- Futhark.CodeGen.Backends.GenericWASM: data JSEntryPoint
- Futhark.CodeGen.Backends.GenericWASM: emccExportNames :: [JSEntryPoint] -> [String]
- Futhark.CodeGen.Backends.GenericWASM: extToString :: ExternalValue -> String
- Futhark.CodeGen.Backends.GenericWASM: javascriptWrapper :: [JSEntryPoint] -> Text
- Futhark.CodeGen.Backends.GenericWASM: libraryExports :: Text
- Futhark.CodeGen.Backends.GenericWASM: runServer :: Text
- Futhark.CodeGen.Backends.GenericWASM: type EntryPointType = String
- Futhark.CodeGen.Backends.HIP: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.HIP: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.HIP: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.HIP: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.HIP: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.HIP: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.HIP: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.HIP: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.HIP: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.HIP: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.HIP: compileProg :: MonadFreshNames m => Text -> Prog GPUMem -> m (Warnings, CParts)
- Futhark.CodeGen.Backends.HIP: data CParts
- Futhark.CodeGen.Backends.MulticoreC: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.MulticoreC: MemBlock :: ValueType
- Futhark.CodeGen.Backends.MulticoreC: Prim :: PrimType -> ValueType
- Futhark.CodeGen.Backends.MulticoreC: RawMem :: ValueType
- Futhark.CodeGen.Backends.MulticoreC: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreC: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreC: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreC: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreC: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreC: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreC: addTimingFields :: Name -> CompilerM op s ()
- Futhark.CodeGen.Backends.MulticoreC: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreC: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.MulticoreC: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreC: atomicOps :: AtomicOp -> (Type -> VName -> CompilerM op s Type) -> CompilerM op s ()
- Futhark.CodeGen.Backends.MulticoreC: cliOptions :: [Option]
- Futhark.CodeGen.Backends.MulticoreC: closureFreeStructField :: VName -> Name
- Futhark.CodeGen.Backends.MulticoreC: compileOp :: OpCompiler Multicore s
- Futhark.CodeGen.Backends.MulticoreC: compileProg :: MonadFreshNames m => Text -> Prog MCMem -> m (Warnings, CParts)
- Futhark.CodeGen.Backends.MulticoreC: data CParts
- Futhark.CodeGen.Backends.MulticoreC: data ValueType
- Futhark.CodeGen.Backends.MulticoreC: functionIterations :: Name -> Id
- Futhark.CodeGen.Backends.MulticoreC: functionTiming :: Name -> Id
- Futhark.CodeGen.Backends.MulticoreC: generateParLoopFn :: ToIdent a => Map VName Space -> String -> MCCode -> a -> [(VName, (Type, ValueType))] -> [(VName, (Type, ValueType))] -> CompilerM Multicore s Name
- Futhark.CodeGen.Backends.MulticoreC: multicoreDef :: DefSpecifier s
- Futhark.CodeGen.Backends.MulticoreC: multicoreName :: String -> CompilerM op s Name
- Futhark.CodeGen.Backends.MulticoreC: operations :: Operations Multicore s
- Futhark.CodeGen.Backends.MulticoreC: paramToCType :: Param -> CompilerM op s (Type, ValueType)
- Futhark.CodeGen.Backends.MulticoreC: prepareTaskStruct :: DefSpecifier s -> String -> [VName] -> [(Type, ValueType)] -> [VName] -> [(Type, ValueType)] -> CompilerM Multicore s Name
- Futhark.CodeGen.Backends.MulticoreC: type DefSpecifier s = String -> Name -> CompilerM Multicore s Definition -> CompilerM Multicore s Name
- Futhark.CodeGen.Backends.MulticoreC.Boilerplate: generateBoilerplate :: CompilerM op s ()
- Futhark.CodeGen.Backends.MulticoreISPC: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.MulticoreISPC: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreISPC: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreISPC: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreISPC: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreISPC: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreISPC: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreISPC: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreISPC: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.MulticoreISPC: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreISPC: compileProg :: MonadFreshNames m => Text -> Prog MCMem -> m (Warnings, (CParts, Text))
- Futhark.CodeGen.Backends.MulticoreISPC: data CParts
- Futhark.CodeGen.Backends.MulticoreISPC: data ISPCState
- Futhark.CodeGen.Backends.MulticoreISPC: instance Control.Monad.Reader.Class.MonadReader Futhark.IR.Prop.Names.Names Futhark.CodeGen.Backends.MulticoreISPC.VariabilityM
- Futhark.CodeGen.Backends.MulticoreISPC: instance Control.Monad.State.Class.MonadState Futhark.CodeGen.Backends.MulticoreISPC.Dependencies Futhark.CodeGen.Backends.MulticoreISPC.VariabilityM
- Futhark.CodeGen.Backends.MulticoreISPC: instance GHC.Base.Applicative Futhark.CodeGen.Backends.MulticoreISPC.VariabilityM
- Futhark.CodeGen.Backends.MulticoreISPC: instance GHC.Base.Functor Futhark.CodeGen.Backends.MulticoreISPC.VariabilityM
- Futhark.CodeGen.Backends.MulticoreISPC: instance GHC.Base.Monad Futhark.CodeGen.Backends.MulticoreISPC.VariabilityM
- Futhark.CodeGen.Backends.MulticoreISPC: instance GHC.Classes.Eq Futhark.CodeGen.Backends.MulticoreISPC.Variability
- Futhark.CodeGen.Backends.MulticoreISPC: instance GHC.Classes.Ord Futhark.CodeGen.Backends.MulticoreISPC.Variability
- Futhark.CodeGen.Backends.MulticoreISPC: instance GHC.Show.Show Futhark.CodeGen.Backends.MulticoreISPC.Variability
- Futhark.CodeGen.Backends.MulticoreISPC: operations :: Operations Multicore ISPCState
- Futhark.CodeGen.Backends.MulticoreWASM: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.MulticoreWASM: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreWASM: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreWASM: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreWASM: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreWASM: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreWASM: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreWASM: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreWASM: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.MulticoreWASM: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.MulticoreWASM: compileProg :: MonadFreshNames m => Text -> Prog MCMem -> m (Warnings, (CParts, Text, [String]))
- Futhark.CodeGen.Backends.MulticoreWASM: data CParts
- Futhark.CodeGen.Backends.MulticoreWASM: libraryExports :: Text
- Futhark.CodeGen.Backends.MulticoreWASM: runServer :: Text
- Futhark.CodeGen.Backends.PyOpenCL: compileProg :: MonadFreshNames m => CompilerMode -> String -> Prog GPUMem -> m (Warnings, Text)
- Futhark.CodeGen.Backends.PyOpenCL.Boilerplate: openClInit :: [(Name, KernelConstExp)] -> [PrimType] -> String -> ParamMap -> [FailureMsg] -> Text
- Futhark.CodeGen.Backends.SequentialC: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.SequentialC: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialC: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialC: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialC: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialC: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialC: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialC: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialC: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.SequentialC: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialC: compileProg :: MonadFreshNames m => Text -> Prog SeqMem -> m (Warnings, CParts)
- Futhark.CodeGen.Backends.SequentialC: data CParts
- Futhark.CodeGen.Backends.SequentialC.Boilerplate: generateBoilerplate :: CompilerM op s ()
- Futhark.CodeGen.Backends.SequentialPython: compileProg :: MonadFreshNames m => CompilerMode -> String -> Prog SeqMem -> m (Warnings, Text)
- Futhark.CodeGen.Backends.SequentialWASM: CParts :: Text -> Text -> Text -> Text -> Text -> Text -> CParts
- Futhark.CodeGen.Backends.SequentialWASM: [cCLI] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialWASM: [cHeader] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialWASM: [cJsonManifest] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialWASM: [cLib] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialWASM: [cServer] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialWASM: [cUtils] :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialWASM: asExecutable :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialWASM: asLibrary :: CParts -> (Text, Text, Text)
- Futhark.CodeGen.Backends.SequentialWASM: asServer :: CParts -> Text
- Futhark.CodeGen.Backends.SequentialWASM: compileProg :: MonadFreshNames m => Text -> Prog SeqMem -> m (Warnings, (CParts, Text, [String]))
- Futhark.CodeGen.Backends.SequentialWASM: data CParts
- Futhark.CodeGen.Backends.SequentialWASM: libraryExports :: Text
- Futhark.CodeGen.Backends.SequentialWASM: runServer :: Text
- Futhark.CodeGen.Backends.SimpleRep: allEqual :: [Exp] -> Exp
- Futhark.CodeGen.Backends.SimpleRep: allTrue :: [Exp] -> Exp
- Futhark.CodeGen.Backends.SimpleRep: arrayName :: PrimType -> Signedness -> Int -> Text
- Futhark.CodeGen.Backends.SimpleRep: cScalarDefs :: Text
- Futhark.CodeGen.Backends.SimpleRep: cproduct :: [Exp] -> Exp
- Futhark.CodeGen.Backends.SimpleRep: csum :: [Exp] -> Exp
- Futhark.CodeGen.Backends.SimpleRep: defaultMemBlockType :: Type
- Futhark.CodeGen.Backends.SimpleRep: escapeName :: Text -> Text
- Futhark.CodeGen.Backends.SimpleRep: fromStorage :: PrimType -> Exp -> Exp
- Futhark.CodeGen.Backends.SimpleRep: funName :: Name -> Text
- Futhark.CodeGen.Backends.SimpleRep: instance Language.C.Quote.Base.ToExp Futhark.IR.Syntax.Core.SubExp
- Futhark.CodeGen.Backends.SimpleRep: instance Language.C.Quote.Base.ToExp Language.Futhark.Core.VName
- Futhark.CodeGen.Backends.SimpleRep: instance Language.C.Quote.Base.ToExp Language.Futhark.Primitive.FloatValue
- Futhark.CodeGen.Backends.SimpleRep: instance Language.C.Quote.Base.ToExp Language.Futhark.Primitive.IntValue
- Futhark.CodeGen.Backends.SimpleRep: instance Language.C.Quote.Base.ToExp Language.Futhark.Primitive.PrimValue
- Futhark.CodeGen.Backends.SimpleRep: instance Language.C.Quote.Base.ToIdent Data.Text.Internal.Text
- Futhark.CodeGen.Backends.SimpleRep: instance Language.C.Quote.Base.ToIdent Language.Futhark.Core.Name
- Futhark.CodeGen.Backends.SimpleRep: instance Language.C.Quote.Base.ToIdent Language.Futhark.Core.VName
- Futhark.CodeGen.Backends.SimpleRep: intTypeToCType :: IntType -> Type
- Futhark.CodeGen.Backends.SimpleRep: isValidCName :: Text -> Bool
- Futhark.CodeGen.Backends.SimpleRep: loadValueHeader :: Signedness -> PrimType -> Int -> Exp -> Exp -> [Stm]
- Futhark.CodeGen.Backends.SimpleRep: opaqueName :: Name -> Text
- Futhark.CodeGen.Backends.SimpleRep: primAPIType :: Signedness -> PrimType -> Type
- Futhark.CodeGen.Backends.SimpleRep: primStorageType :: PrimType -> Type
- Futhark.CodeGen.Backends.SimpleRep: primTypeToCType :: PrimType -> Type
- Futhark.CodeGen.Backends.SimpleRep: scalarToPrim :: Text -> (Signedness, PrimType)
- Futhark.CodeGen.Backends.SimpleRep: storageSize :: PrimType -> Int -> Exp -> Exp
- Futhark.CodeGen.Backends.SimpleRep: storeValueHeader :: Signedness -> PrimType -> Int -> Exp -> Exp -> [Stm]
- Futhark.CodeGen.Backends.SimpleRep: toStorage :: PrimType -> Exp -> Exp
- Futhark.CodeGen.Backends.SimpleRep: tupleField :: Int -> String
- Futhark.CodeGen.ImpCode: (:>>:) :: Code a -> Code a -> Code a
- Futhark.CodeGen.ImpCode: Allocate :: VName -> Count Bytes (TExp Int64) -> Space -> Code a
- Futhark.CodeGen.ImpCode: ArrayValue :: VName -> Space -> PrimType -> Signedness -> [DimSize] -> ValueDesc
- Futhark.CodeGen.ImpCode: ArrayValues :: [PrimValue] -> ArrayContents
- Futhark.CodeGen.ImpCode: ArrayZeros :: Int -> ArrayContents
- Futhark.CodeGen.ImpCode: Assert :: Exp -> ErrorMsg Exp -> (SrcLoc, [SrcLoc]) -> Code a
- Futhark.CodeGen.ImpCode: BoolValue :: !Bool -> PrimValue
- Futhark.CodeGen.ImpCode: Call :: [VName] -> Name -> [Arg] -> Code a
- Futhark.CodeGen.ImpCode: Comment :: Text -> Code a -> Code a
- Futhark.CodeGen.ImpCode: Constant :: PrimValue -> SubExp
- Futhark.CodeGen.ImpCode: Constants :: [Param] -> Code a -> Constants a
- Futhark.CodeGen.ImpCode: Copy :: PrimType -> [Count Elements (TExp Int64)] -> (VName, Space) -> (Count Elements (TExp Int64), [Count Elements (TExp Int64)]) -> (VName, Space) -> (Count Elements (TExp Int64), [Count Elements (TExp Int64)]) -> Code a
- Futhark.CodeGen.ImpCode: Count :: e -> Count (u :: k) e
- Futhark.CodeGen.ImpCode: DebugPrint :: String -> Maybe Exp -> Code a
- Futhark.CodeGen.ImpCode: DeclareArray :: VName -> PrimType -> ArrayContents -> Code a
- Futhark.CodeGen.ImpCode: DeclareMem :: VName -> Space -> Code a
- Futhark.CodeGen.ImpCode: DeclareScalar :: VName -> Volatility -> PrimType -> Code a
- Futhark.CodeGen.ImpCode: DefaultSpace :: Space
- Futhark.CodeGen.ImpCode: Definitions :: OpaqueTypes -> Constants a -> Functions a -> Definitions a
- Futhark.CodeGen.ImpCode: EntryPoint :: Name -> [(Uniqueness, ExternalValue)] -> [((Name, Uniqueness), ExternalValue)] -> EntryPoint
- Futhark.CodeGen.ImpCode: ErrorMsg :: [ErrorMsgPart a] -> ErrorMsg a
- Futhark.CodeGen.ImpCode: ErrorString :: Text -> ErrorMsgPart a
- Futhark.CodeGen.ImpCode: ErrorVal :: PrimType -> a -> ErrorMsgPart a
- Futhark.CodeGen.ImpCode: ExpArg :: Exp -> Arg
- Futhark.CodeGen.ImpCode: FloatValue :: !FloatValue -> PrimValue
- Futhark.CodeGen.ImpCode: For :: VName -> Exp -> Code a -> Code a
- Futhark.CodeGen.ImpCode: Free :: VName -> Space -> Code a
- Futhark.CodeGen.ImpCode: Function :: Maybe EntryPoint -> [Param] -> [Param] -> Code a -> FunctionT a
- Futhark.CodeGen.ImpCode: Functions :: [(Name, Function a)] -> Functions a
- Futhark.CodeGen.ImpCode: If :: TExp Bool -> Code a -> Code a -> Code a
- Futhark.CodeGen.ImpCode: IntValue :: !IntValue -> PrimValue
- Futhark.CodeGen.ImpCode: MemArg :: VName -> Arg
- Futhark.CodeGen.ImpCode: MemParam :: VName -> Space -> Param
- Futhark.CodeGen.ImpCode: Nonvolatile :: Volatility
- Futhark.CodeGen.ImpCode: Op :: a -> Code a
- Futhark.CodeGen.ImpCode: OpaqueArray :: Int -> Name -> [ValueType] -> OpaqueType
- Futhark.CodeGen.ImpCode: OpaqueRecord :: [(Name, EntryPointType)] -> OpaqueType
- Futhark.CodeGen.ImpCode: OpaqueRecordArray :: Int -> Name -> [(Name, EntryPointType)] -> OpaqueType
- Futhark.CodeGen.ImpCode: OpaqueSum :: [ValueType] -> [(Name, [(EntryPointType, [Int])])] -> OpaqueType
- Futhark.CodeGen.ImpCode: OpaqueType :: [ValueType] -> OpaqueType
- Futhark.CodeGen.ImpCode: OpaqueTypes :: [(Name, OpaqueType)] -> OpaqueTypes
- Futhark.CodeGen.ImpCode: OpaqueValue :: Name -> [ValueDesc] -> ExternalValue
- Futhark.CodeGen.ImpCode: Rank :: Int -> Rank
- Futhark.CodeGen.ImpCode: Read :: VName -> VName -> Count Elements (TExp Int64) -> PrimType -> Space -> Volatility -> Code a
- Futhark.CodeGen.ImpCode: ScalarParam :: VName -> PrimType -> Param
- Futhark.CodeGen.ImpCode: ScalarSpace :: [SubExp] -> PrimType -> Space
- Futhark.CodeGen.ImpCode: ScalarValue :: PrimType -> Signedness -> VName -> ValueDesc
- Futhark.CodeGen.ImpCode: SetMem :: VName -> VName -> Space -> Code a
- Futhark.CodeGen.ImpCode: SetScalar :: VName -> Exp -> Code a
- Futhark.CodeGen.ImpCode: Signed :: Signedness
- Futhark.CodeGen.ImpCode: SizeBespoke :: Name -> Int64 -> SizeClass
- Futhark.CodeGen.ImpCode: SizeCache :: SizeClass
- Futhark.CodeGen.ImpCode: SizeGrid :: SizeClass
- Futhark.CodeGen.ImpCode: SizeRegTile :: SizeClass
- Futhark.CodeGen.ImpCode: SizeRegisters :: SizeClass
- Futhark.CodeGen.ImpCode: SizeSharedMemory :: SizeClass
- Futhark.CodeGen.ImpCode: SizeThreadBlock :: SizeClass
- Futhark.CodeGen.ImpCode: SizeThreshold :: KernelPath -> Maybe Int64 -> SizeClass
- Futhark.CodeGen.ImpCode: SizeTile :: SizeClass
- Futhark.CodeGen.ImpCode: Skip :: Code a
- Futhark.CodeGen.ImpCode: Space :: SpaceId -> Space
- Futhark.CodeGen.ImpCode: TracePrint :: ErrorMsg Exp -> Code a
- Futhark.CodeGen.ImpCode: TransparentValue :: ValueDesc -> ExternalValue
- Futhark.CodeGen.ImpCode: TypeOpaque :: Name -> EntryPointType
- Futhark.CodeGen.ImpCode: TypeTransparent :: ValueType -> EntryPointType
- Futhark.CodeGen.ImpCode: UnitValue :: PrimValue
- Futhark.CodeGen.ImpCode: Unsigned :: Signedness
- Futhark.CodeGen.ImpCode: ValueType :: Signedness -> Rank -> PrimType -> ValueType
- Futhark.CodeGen.ImpCode: Var :: VName -> SubExp
- Futhark.CodeGen.ImpCode: Volatile :: Volatility
- Futhark.CodeGen.ImpCode: While :: TExp Bool -> Code a -> Code a
- Futhark.CodeGen.ImpCode: Write :: VName -> Count Elements (TExp Int64) -> PrimType -> Space -> Volatility -> Exp -> Code a
- Futhark.CodeGen.ImpCode: [constsDecl] :: Constants a -> [Param]
- Futhark.CodeGen.ImpCode: [constsInit] :: Constants a -> Code a
- Futhark.CodeGen.ImpCode: [defConsts] :: Definitions a -> Constants a
- Futhark.CodeGen.ImpCode: [defFuns] :: Definitions a -> Functions a
- Futhark.CodeGen.ImpCode: [defTypes] :: Definitions a -> OpaqueTypes
- Futhark.CodeGen.ImpCode: [entryPointArgs] :: EntryPoint -> [((Name, Uniqueness), ExternalValue)]
- Futhark.CodeGen.ImpCode: [entryPointName] :: EntryPoint -> Name
- Futhark.CodeGen.ImpCode: [entryPointResults] :: EntryPoint -> [(Uniqueness, ExternalValue)]
- Futhark.CodeGen.ImpCode: [functionBody] :: FunctionT a -> Code a
- Futhark.CodeGen.ImpCode: [functionEntry] :: FunctionT a -> Maybe EntryPoint
- Futhark.CodeGen.ImpCode: [functionInput] :: FunctionT a -> [Param]
- Futhark.CodeGen.ImpCode: [functionOutput] :: FunctionT a -> [Param]
- Futhark.CodeGen.ImpCode: [unCount] :: Count (u :: k) e -> e
- Futhark.CodeGen.ImpCode: [unFunctions] :: Functions a -> [(Name, Function a)]
- Futhark.CodeGen.ImpCode: bytes :: a -> Count Bytes a
- Futhark.CodeGen.ImpCode: callGraph :: (a -> Set Name) -> Functions a -> Map Name (Set Name)
- Futhark.CodeGen.ImpCode: calledFuncs :: (a -> Set Name) -> Code a -> Set Name
- Futhark.CodeGen.ImpCode: data Arg
- Futhark.CodeGen.ImpCode: data ArrayContents
- Futhark.CodeGen.ImpCode: data Bytes
- Futhark.CodeGen.ImpCode: data Code a
- Futhark.CodeGen.ImpCode: data Constants a
- Futhark.CodeGen.ImpCode: data Definitions a
- Futhark.CodeGen.ImpCode: data Elements
- Futhark.CodeGen.ImpCode: data EntryPoint
- Futhark.CodeGen.ImpCode: data EntryPointType
- Futhark.CodeGen.ImpCode: data ErrorMsgPart a
- Futhark.CodeGen.ImpCode: data ExternalValue
- Futhark.CodeGen.ImpCode: data FunctionT a
- Futhark.CodeGen.ImpCode: data OpaqueType
- Futhark.CodeGen.ImpCode: data Param
- Futhark.CodeGen.ImpCode: data PrimValue
- Futhark.CodeGen.ImpCode: data Signedness
- Futhark.CodeGen.ImpCode: data SizeClass
- Futhark.CodeGen.ImpCode: data Space
- Futhark.CodeGen.ImpCode: data SubExp
- Futhark.CodeGen.ImpCode: data ValueDesc
- Futhark.CodeGen.ImpCode: data ValueType
- Futhark.CodeGen.ImpCode: data Volatility
- Futhark.CodeGen.ImpCode: declaredIn :: Code a -> Names
- Futhark.CodeGen.ImpCode: declsFirst :: Code a -> Code a
- Futhark.CodeGen.ImpCode: elements :: a -> Count Elements a
- Futhark.CodeGen.ImpCode: errorMsgArgTypes :: ErrorMsg a -> [PrimType]
- Futhark.CodeGen.ImpCode: instance Data.Foldable.Foldable Futhark.CodeGen.ImpCode.Code
- Futhark.CodeGen.ImpCode: instance Data.Foldable.Foldable Futhark.CodeGen.ImpCode.FunctionT
- Futhark.CodeGen.ImpCode: instance Data.Foldable.Foldable Futhark.CodeGen.ImpCode.Functions
- Futhark.CodeGen.ImpCode: instance Data.Traversable.Traversable Futhark.CodeGen.ImpCode.Code
- Futhark.CodeGen.ImpCode: instance Data.Traversable.Traversable Futhark.CodeGen.ImpCode.FunctionT
- Futhark.CodeGen.ImpCode: instance Data.Traversable.Traversable Futhark.CodeGen.ImpCode.Functions
- Futhark.CodeGen.ImpCode: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.Arg
- Futhark.CodeGen.ImpCode: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.EntryPoint
- Futhark.CodeGen.ImpCode: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.ExternalValue
- Futhark.CodeGen.ImpCode: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.ValueDesc
- Futhark.CodeGen.ImpCode: instance Futhark.IR.Prop.Names.FreeIn a => Futhark.IR.Prop.Names.FreeIn (Futhark.CodeGen.ImpCode.Code a)
- Futhark.CodeGen.ImpCode: instance Futhark.IR.Prop.Names.FreeIn a => Futhark.IR.Prop.Names.FreeIn (Futhark.CodeGen.ImpCode.Functions a)
- Futhark.CodeGen.ImpCode: instance GHC.Base.Functor Futhark.CodeGen.ImpCode.Code
- Futhark.CodeGen.ImpCode: instance GHC.Base.Functor Futhark.CodeGen.ImpCode.Constants
- Futhark.CodeGen.ImpCode: instance GHC.Base.Functor Futhark.CodeGen.ImpCode.Definitions
- Futhark.CodeGen.ImpCode: instance GHC.Base.Functor Futhark.CodeGen.ImpCode.FunctionT
- Futhark.CodeGen.ImpCode: instance GHC.Base.Functor Futhark.CodeGen.ImpCode.Functions
- Futhark.CodeGen.ImpCode: instance GHC.Base.Monoid (Futhark.CodeGen.ImpCode.Code a)
- Futhark.CodeGen.ImpCode: instance GHC.Base.Monoid (Futhark.CodeGen.ImpCode.Constants a)
- Futhark.CodeGen.ImpCode: instance GHC.Base.Monoid (Futhark.CodeGen.ImpCode.Functions a)
- Futhark.CodeGen.ImpCode: instance GHC.Base.Semigroup (Futhark.CodeGen.ImpCode.Code a)
- Futhark.CodeGen.ImpCode: instance GHC.Base.Semigroup (Futhark.CodeGen.ImpCode.Constants a)
- Futhark.CodeGen.ImpCode: instance GHC.Base.Semigroup (Futhark.CodeGen.ImpCode.Functions a)
- Futhark.CodeGen.ImpCode: instance GHC.Classes.Eq Futhark.CodeGen.ImpCode.Param
- Futhark.CodeGen.ImpCode: instance GHC.Classes.Eq Futhark.CodeGen.ImpCode.ValueDesc
- Futhark.CodeGen.ImpCode: instance GHC.Classes.Eq Futhark.CodeGen.ImpCode.Volatility
- Futhark.CodeGen.ImpCode: instance GHC.Classes.Ord Futhark.CodeGen.ImpCode.Volatility
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show Futhark.CodeGen.ImpCode.Arg
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show Futhark.CodeGen.ImpCode.ArrayContents
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show Futhark.CodeGen.ImpCode.EntryPoint
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show Futhark.CodeGen.ImpCode.ExternalValue
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show Futhark.CodeGen.ImpCode.Param
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show Futhark.CodeGen.ImpCode.ValueDesc
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show Futhark.CodeGen.ImpCode.Volatility
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show a => GHC.Show.Show (Futhark.CodeGen.ImpCode.Code a)
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show a => GHC.Show.Show (Futhark.CodeGen.ImpCode.Constants a)
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show a => GHC.Show.Show (Futhark.CodeGen.ImpCode.Definitions a)
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show a => GHC.Show.Show (Futhark.CodeGen.ImpCode.FunctionT a)
- Futhark.CodeGen.ImpCode: instance GHC.Show.Show a => GHC.Show.Show (Futhark.CodeGen.ImpCode.Functions a)
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.Arg
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.ArrayContents
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.EntryPoint
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.ExternalValue
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.Param
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.ValueDesc
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty op => Prettyprinter.Internal.Pretty (Futhark.CodeGen.ImpCode.Code op)
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty op => Prettyprinter.Internal.Pretty (Futhark.CodeGen.ImpCode.Constants op)
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty op => Prettyprinter.Internal.Pretty (Futhark.CodeGen.ImpCode.Definitions op)
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty op => Prettyprinter.Internal.Pretty (Futhark.CodeGen.ImpCode.FunctionT op)
- Futhark.CodeGen.ImpCode: instance Prettyprinter.Internal.Pretty op => Prettyprinter.Internal.Pretty (Futhark.CodeGen.ImpCode.Functions op)
- Futhark.CodeGen.ImpCode: lexicalMemoryUsage :: Function a -> Map VName Space
- Futhark.CodeGen.ImpCode: newtype Count (u :: k) e
- Futhark.CodeGen.ImpCode: newtype ErrorMsg a
- Futhark.CodeGen.ImpCode: newtype Functions a
- Futhark.CodeGen.ImpCode: newtype OpaqueTypes
- Futhark.CodeGen.ImpCode: newtype Rank
- Futhark.CodeGen.ImpCode: paramName :: Param -> VName
- Futhark.CodeGen.ImpCode: prettyString :: Pretty a => a -> String
- Futhark.CodeGen.ImpCode: prettyText :: Pretty a => a -> Text
- Futhark.CodeGen.ImpCode: type DimSize = SubExp
- Futhark.CodeGen.ImpCode: type Exp = PrimExp VName
- Futhark.CodeGen.ImpCode: type Function = FunctionT
- Futhark.CodeGen.ImpCode: type MemSize = SubExp
- Futhark.CodeGen.ImpCode: type ParamMap = Map Name (SizeClass, Set Name)
- Futhark.CodeGen.ImpCode: type SpaceId = String
- Futhark.CodeGen.ImpCode: type TExp (t :: k) = TPrimExp t VName
- Futhark.CodeGen.ImpCode: var :: VName -> PrimType -> Exp
- Futhark.CodeGen.ImpCode: withElemType :: Count Elements (TExp Int64) -> PrimType -> Count Bytes (TExp Int64)
- Futhark.CodeGen.ImpCode.GPU: Atomic :: Space -> AtomicOp -> KernelOp
- Futhark.CodeGen.ImpCode.GPU: AtomicAdd :: IntType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicAnd :: IntType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicCmpXchg :: PrimType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicFAdd :: FloatType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicOr :: IntType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicSMax :: IntType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicSMin :: IntType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicUMax :: IntType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicUMin :: IntType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicWrite :: PrimType -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicXchg :: PrimType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: AtomicXor :: IntType -> VName -> VName -> Count Elements (TExp Int64) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.GPU: Barrier :: Fence -> KernelOp
- Futhark.CodeGen.ImpCode.GPU: CallKernel :: Kernel -> HostOp
- Futhark.CodeGen.ImpCode.GPU: CmpSizeLe :: VName -> Name -> SizeClass -> Exp -> HostOp
- Futhark.CodeGen.ImpCode.GPU: ConstUse :: VName -> KernelConstExp -> KernelUse
- Futhark.CodeGen.ImpCode.GPU: ErrorSync :: Fence -> KernelOp
- Futhark.CodeGen.ImpCode.GPU: FenceGlobal :: Fence
- Futhark.CodeGen.ImpCode.GPU: FenceLocal :: Fence
- Futhark.CodeGen.ImpCode.GPU: GetBlockId :: VName -> Int -> KernelOp
- Futhark.CodeGen.ImpCode.GPU: GetLocalId :: VName -> Int -> KernelOp
- Futhark.CodeGen.ImpCode.GPU: GetLocalSize :: VName -> Int -> KernelOp
- Futhark.CodeGen.ImpCode.GPU: GetLockstepWidth :: VName -> KernelOp
- Futhark.CodeGen.ImpCode.GPU: GetSize :: VName -> Name -> SizeClass -> HostOp
- Futhark.CodeGen.ImpCode.GPU: GetSizeMax :: VName -> SizeClass -> HostOp
- Futhark.CodeGen.ImpCode.GPU: Kernel :: Code KernelOp -> [KernelUse] -> [Exp] -> [BlockDim] -> Name -> Bool -> Bool -> Kernel
- Futhark.CodeGen.ImpCode.GPU: MemFence :: Fence -> KernelOp
- Futhark.CodeGen.ImpCode.GPU: MemoryUse :: VName -> KernelUse
- Futhark.CodeGen.ImpCode.GPU: ScalarUse :: VName -> PrimType -> KernelUse
- Futhark.CodeGen.ImpCode.GPU: SharedAlloc :: VName -> Count Bytes (TExp Int64) -> KernelOp
- Futhark.CodeGen.ImpCode.GPU: SizeConst :: Name -> SizeClass -> KernelConst
- Futhark.CodeGen.ImpCode.GPU: SizeMaxConst :: SizeClass -> KernelConst
- Futhark.CodeGen.ImpCode.GPU: [kernelBlockSize] :: Kernel -> [BlockDim]
- Futhark.CodeGen.ImpCode.GPU: [kernelBody] :: Kernel -> Code KernelOp
- Futhark.CodeGen.ImpCode.GPU: [kernelCheckSharedMemory] :: Kernel -> Bool
- Futhark.CodeGen.ImpCode.GPU: [kernelFailureTolerant] :: Kernel -> Bool
- Futhark.CodeGen.ImpCode.GPU: [kernelName] :: Kernel -> Name
- Futhark.CodeGen.ImpCode.GPU: [kernelNumBlocks] :: Kernel -> [Exp]
- Futhark.CodeGen.ImpCode.GPU: [kernelUses] :: Kernel -> [KernelUse]
- Futhark.CodeGen.ImpCode.GPU: data AtomicOp
- Futhark.CodeGen.ImpCode.GPU: data Fence
- Futhark.CodeGen.ImpCode.GPU: data HostOp
- Futhark.CodeGen.ImpCode.GPU: data Kernel
- Futhark.CodeGen.ImpCode.GPU: data KernelConst
- Futhark.CodeGen.ImpCode.GPU: data KernelOp
- Futhark.CodeGen.ImpCode.GPU: data KernelUse
- Futhark.CodeGen.ImpCode.GPU: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.GPU.AtomicOp
- Futhark.CodeGen.ImpCode.GPU: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.GPU.HostOp
- Futhark.CodeGen.ImpCode.GPU: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.GPU.Kernel
- Futhark.CodeGen.ImpCode.GPU: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.GPU.KernelConst
- Futhark.CodeGen.ImpCode.GPU: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.GPU.KernelOp
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Classes.Eq Futhark.CodeGen.ImpCode.GPU.Fence
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Classes.Eq Futhark.CodeGen.ImpCode.GPU.KernelConst
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Classes.Eq Futhark.CodeGen.ImpCode.GPU.KernelUse
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Classes.Ord Futhark.CodeGen.ImpCode.GPU.Fence
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Classes.Ord Futhark.CodeGen.ImpCode.GPU.KernelConst
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Classes.Ord Futhark.CodeGen.ImpCode.GPU.KernelUse
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Show.Show Futhark.CodeGen.ImpCode.GPU.AtomicOp
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Show.Show Futhark.CodeGen.ImpCode.GPU.Fence
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Show.Show Futhark.CodeGen.ImpCode.GPU.HostOp
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Show.Show Futhark.CodeGen.ImpCode.GPU.Kernel
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Show.Show Futhark.CodeGen.ImpCode.GPU.KernelConst
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Show.Show Futhark.CodeGen.ImpCode.GPU.KernelOp
- Futhark.CodeGen.ImpCode.GPU: instance GHC.Show.Show Futhark.CodeGen.ImpCode.GPU.KernelUse
- Futhark.CodeGen.ImpCode.GPU: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.GPU.HostOp
- Futhark.CodeGen.ImpCode.GPU: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.GPU.Kernel
- Futhark.CodeGen.ImpCode.GPU: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.GPU.KernelConst
- Futhark.CodeGen.ImpCode.GPU: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.GPU.KernelOp
- Futhark.CodeGen.ImpCode.GPU: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.GPU.KernelUse
- Futhark.CodeGen.ImpCode.GPU: type BlockDim = Either Exp KernelConstExp
- Futhark.CodeGen.ImpCode.GPU: type HostCode = Code HostOp
- Futhark.CodeGen.ImpCode.GPU: type KernelCode = Code KernelOp
- Futhark.CodeGen.ImpCode.GPU: type KernelConstExp = PrimExp KernelConst
- Futhark.CodeGen.ImpCode.GPU: type Program = Definitions HostOp
- Futhark.CodeGen.ImpCode.Multicore: Atomic :: AtomicOp -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: AtomicAdd :: IntType -> VName -> VName -> Count Elements (TExp Int32) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: AtomicAnd :: IntType -> VName -> VName -> Count Elements (TExp Int32) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: AtomicCmpXchg :: PrimType -> VName -> VName -> Count Elements (TExp Int32) -> VName -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: AtomicOr :: IntType -> VName -> VName -> Count Elements (TExp Int32) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: AtomicSub :: IntType -> VName -> VName -> Count Elements (TExp Int32) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: AtomicXchg :: PrimType -> VName -> VName -> Count Elements (TExp Int32) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: AtomicXor :: IntType -> VName -> VName -> Count Elements (TExp Int32) -> Exp -> AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: Dynamic :: Scheduling
- Futhark.CodeGen.ImpCode.Multicore: ExtractLane :: VName -> Exp -> Exp -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: ForEach :: VName -> Exp -> Exp -> MCCode -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: ForEachActive :: VName -> MCCode -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: GetLoopBounds :: VName -> VName -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: GetNumTasks :: VName -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: GetTaskId :: VName -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: ISPCKernel :: MCCode -> [Param] -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: OpaqueKernels :: KernelHandling
- Futhark.CodeGen.ImpCode.Multicore: ParLoop :: String -> MCCode -> [Param] -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: ParallelTask :: MCCode -> ParallelTask
- Futhark.CodeGen.ImpCode.Multicore: SchedulerInfo :: Exp -> Scheduling -> SchedulerInfo
- Futhark.CodeGen.ImpCode.Multicore: SegOp :: String -> [Param] -> ParallelTask -> Maybe ParallelTask -> [Param] -> SchedulerInfo -> Multicore
- Futhark.CodeGen.ImpCode.Multicore: Static :: Scheduling
- Futhark.CodeGen.ImpCode.Multicore: TraverseKernels :: KernelHandling
- Futhark.CodeGen.ImpCode.Multicore: [iterations] :: SchedulerInfo -> Exp
- Futhark.CodeGen.ImpCode.Multicore: [scheduling] :: SchedulerInfo -> Scheduling
- Futhark.CodeGen.ImpCode.Multicore: data AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: data KernelHandling
- Futhark.CodeGen.ImpCode.Multicore: data Multicore
- Futhark.CodeGen.ImpCode.Multicore: data SchedulerInfo
- Futhark.CodeGen.ImpCode.Multicore: data Scheduling
- Futhark.CodeGen.ImpCode.Multicore: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.Multicore.AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.Multicore.Multicore
- Futhark.CodeGen.ImpCode.Multicore: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.Multicore.ParallelTask
- Futhark.CodeGen.ImpCode.Multicore: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.Multicore.SchedulerInfo
- Futhark.CodeGen.ImpCode.Multicore: instance GHC.Show.Show Futhark.CodeGen.ImpCode.Multicore.AtomicOp
- Futhark.CodeGen.ImpCode.Multicore: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.Multicore.Multicore
- Futhark.CodeGen.ImpCode.Multicore: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.Multicore.ParallelTask
- Futhark.CodeGen.ImpCode.Multicore: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.Multicore.SchedulerInfo
- Futhark.CodeGen.ImpCode.Multicore: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.Multicore.Scheduling
- Futhark.CodeGen.ImpCode.Multicore: lexicalMemoryUsageMC :: KernelHandling -> Function Multicore -> Map VName Space
- Futhark.CodeGen.ImpCode.Multicore: newtype ParallelTask
- Futhark.CodeGen.ImpCode.Multicore: type MCCode = Code Multicore
- Futhark.CodeGen.ImpCode.Multicore: type Program = Functions Multicore
- Futhark.CodeGen.ImpCode.OpenCL: CmpSizeLe :: VName -> Name -> Exp -> OpenCL
- Futhark.CodeGen.ImpCode.OpenCL: FailureMsg :: ErrorMsg Exp -> String -> FailureMsg
- Futhark.CodeGen.ImpCode.OpenCL: GetSize :: VName -> Name -> OpenCL
- Futhark.CodeGen.ImpCode.OpenCL: GetSizeMax :: VName -> SizeClass -> OpenCL
- Futhark.CodeGen.ImpCode.OpenCL: LaunchKernel :: KernelSafety -> KernelName -> Count Bytes (TExp Int64) -> [KernelArg] -> [Exp] -> [BlockDim] -> OpenCL
- Futhark.CodeGen.ImpCode.OpenCL: MemKArg :: VName -> KernelArg
- Futhark.CodeGen.ImpCode.OpenCL: Program :: Text -> Text -> [(Name, KernelConstExp)] -> Map KernelName KernelSafety -> [PrimType] -> ParamMap -> [FailureMsg] -> Definitions OpenCL -> Program
- Futhark.CodeGen.ImpCode.OpenCL: SafetyCheap :: KernelSafety
- Futhark.CodeGen.ImpCode.OpenCL: SafetyFull :: KernelSafety
- Futhark.CodeGen.ImpCode.OpenCL: SafetyNone :: KernelSafety
- Futhark.CodeGen.ImpCode.OpenCL: SizeConst :: Name -> SizeClass -> KernelConst
- Futhark.CodeGen.ImpCode.OpenCL: SizeMaxConst :: SizeClass -> KernelConst
- Futhark.CodeGen.ImpCode.OpenCL: TargetCUDA :: KernelTarget
- Futhark.CodeGen.ImpCode.OpenCL: TargetHIP :: KernelTarget
- Futhark.CodeGen.ImpCode.OpenCL: TargetOpenCL :: KernelTarget
- Futhark.CodeGen.ImpCode.OpenCL: ValueKArg :: Exp -> PrimType -> KernelArg
- Futhark.CodeGen.ImpCode.OpenCL: [failureBacktrace] :: FailureMsg -> String
- Futhark.CodeGen.ImpCode.OpenCL: [failureError] :: FailureMsg -> ErrorMsg Exp
- Futhark.CodeGen.ImpCode.OpenCL: [hostDefinitions] :: Program -> Definitions OpenCL
- Futhark.CodeGen.ImpCode.OpenCL: [openClFailures] :: Program -> [FailureMsg]
- Futhark.CodeGen.ImpCode.OpenCL: [openClKernelNames] :: Program -> Map KernelName KernelSafety
- Futhark.CodeGen.ImpCode.OpenCL: [openClMacroDefs] :: Program -> [(Name, KernelConstExp)]
- Futhark.CodeGen.ImpCode.OpenCL: [openClParams] :: Program -> ParamMap
- Futhark.CodeGen.ImpCode.OpenCL: [openClPrelude] :: Program -> Text
- Futhark.CodeGen.ImpCode.OpenCL: [openClProgram] :: Program -> Text
- Futhark.CodeGen.ImpCode.OpenCL: [openClUsedTypes] :: Program -> [PrimType]
- Futhark.CodeGen.ImpCode.OpenCL: data FailureMsg
- Futhark.CodeGen.ImpCode.OpenCL: data KernelArg
- Futhark.CodeGen.ImpCode.OpenCL: data KernelConst
- Futhark.CodeGen.ImpCode.OpenCL: data KernelSafety
- Futhark.CodeGen.ImpCode.OpenCL: data KernelTarget
- Futhark.CodeGen.ImpCode.OpenCL: data OpenCL
- Futhark.CodeGen.ImpCode.OpenCL: data Program
- Futhark.CodeGen.ImpCode.OpenCL: instance GHC.Classes.Eq Futhark.CodeGen.ImpCode.OpenCL.KernelSafety
- Futhark.CodeGen.ImpCode.OpenCL: instance GHC.Classes.Eq Futhark.CodeGen.ImpCode.OpenCL.KernelTarget
- Futhark.CodeGen.ImpCode.OpenCL: instance GHC.Classes.Ord Futhark.CodeGen.ImpCode.OpenCL.KernelSafety
- Futhark.CodeGen.ImpCode.OpenCL: instance GHC.Show.Show Futhark.CodeGen.ImpCode.OpenCL.KernelArg
- Futhark.CodeGen.ImpCode.OpenCL: instance GHC.Show.Show Futhark.CodeGen.ImpCode.OpenCL.KernelSafety
- Futhark.CodeGen.ImpCode.OpenCL: instance GHC.Show.Show Futhark.CodeGen.ImpCode.OpenCL.MayFail
- Futhark.CodeGen.ImpCode.OpenCL: instance GHC.Show.Show Futhark.CodeGen.ImpCode.OpenCL.OpenCL
- Futhark.CodeGen.ImpCode.OpenCL: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.OpenCL.OpenCL
- Futhark.CodeGen.ImpCode.OpenCL: numFailureParams :: KernelSafety -> Int
- Futhark.CodeGen.ImpCode.OpenCL: type BlockDim = Either Exp KernelConstExp
- Futhark.CodeGen.ImpCode.OpenCL: type CLCode = Code OpenCL
- Futhark.CodeGen.ImpCode.OpenCL: type KernelConstExp = PrimExp KernelConst
- Futhark.CodeGen.ImpCode.OpenCL: type KernelName = Name
- Futhark.CodeGen.ImpCode.Sequential: data Sequential
- Futhark.CodeGen.ImpCode.Sequential: instance Futhark.IR.Prop.Names.FreeIn Futhark.CodeGen.ImpCode.Sequential.Sequential
- Futhark.CodeGen.ImpCode.Sequential: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.ImpCode.Sequential.Sequential
- Futhark.CodeGen.ImpCode.Sequential: type Program = Definitions Sequential
- Futhark.CodeGen.ImpGen: (<--) :: forall {k} (t :: k) rep r op. TV t -> TExp t -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: (<~~) :: VName -> Exp -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: AccVar :: Maybe (Exp rep) -> (VName, Shape, [Type]) -> VarEntry rep
- Futhark.CodeGen.ImpGen: ArrayEntry :: MemLoc -> PrimType -> ArrayEntry
- Futhark.CodeGen.ImpGen: ArrayVar :: Maybe (Exp rep) -> ArrayEntry -> VarEntry rep
- Futhark.CodeGen.ImpGen: MemEntry :: Space -> MemEntry
- Futhark.CodeGen.ImpGen: MemLoc :: VName -> [DimSize] -> LMAD (TExp Int64) -> MemLoc
- Futhark.CodeGen.ImpGen: MemVar :: Maybe (Exp rep) -> MemEntry -> VarEntry rep
- Futhark.CodeGen.ImpGen: Operations :: ExpCompiler rep r op -> OpCompiler rep r op -> StmsCompiler rep r op -> CopyCompiler rep r op -> Map Space (AllocCompiler rep r op) -> Operations rep r op
- Futhark.CodeGen.ImpGen: ScalarEntry :: PrimType -> ScalarEntry
- Futhark.CodeGen.ImpGen: ScalarVar :: Maybe (Exp rep) -> ScalarEntry -> VarEntry rep
- Futhark.CodeGen.ImpGen: [entryArrayElemType] :: ArrayEntry -> PrimType
- Futhark.CodeGen.ImpGen: [entryArrayLoc] :: ArrayEntry -> MemLoc
- Futhark.CodeGen.ImpGen: [entryMemSpace] :: MemEntry -> Space
- Futhark.CodeGen.ImpGen: [entryScalarType] :: ScalarEntry -> PrimType
- Futhark.CodeGen.ImpGen: [memLocLMAD] :: MemLoc -> LMAD (TExp Int64)
- Futhark.CodeGen.ImpGen: [memLocName] :: MemLoc -> VName
- Futhark.CodeGen.ImpGen: [memLocShape] :: MemLoc -> [DimSize]
- Futhark.CodeGen.ImpGen: [opsAllocCompilers] :: Operations rep r op -> Map Space (AllocCompiler rep r op)
- Futhark.CodeGen.ImpGen: [opsCopyCompiler] :: Operations rep r op -> CopyCompiler rep r op
- Futhark.CodeGen.ImpGen: [opsExpCompiler] :: Operations rep r op -> ExpCompiler rep r op
- Futhark.CodeGen.ImpGen: [opsOpCompiler] :: Operations rep r op -> OpCompiler rep r op
- Futhark.CodeGen.ImpGen: [opsStmsCompiler] :: Operations rep r op -> StmsCompiler rep r op
- Futhark.CodeGen.ImpGen: addLoopVar :: VName -> IntType -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: askAttrs :: ImpM rep r op Attrs
- Futhark.CodeGen.ImpGen: askEnv :: ImpM rep r op r
- Futhark.CodeGen.ImpGen: askFunction :: ImpM rep r op (Maybe Name)
- Futhark.CodeGen.ImpGen: caseMatch :: [SubExp] -> [Maybe PrimValue] -> TExp Bool
- Futhark.CodeGen.ImpGen: class MkTV (t :: k)
- Futhark.CodeGen.ImpGen: class ToExp a
- Futhark.CodeGen.ImpGen: collect :: ImpM rep r op () -> ImpM rep r op (Code op)
- Futhark.CodeGen.ImpGen: collect' :: ImpM rep r op a -> ImpM rep r op (a, Code op)
- Futhark.CodeGen.ImpGen: compileAlloc :: forall rep (inner :: Type -> Type) r op. Mem rep inner => Pat (LetDec rep) -> SubExp -> Space -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: compileBody :: Pat (LetDec rep) -> Body rep -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: compileBody' :: [Param dec] -> Body rep -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: compileExp :: Pat (LetDec rep) -> Exp rep -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: compileLoopBody :: Typed dec => [Param dec] -> Body rep -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: compileProg :: forall rep (inner :: Type -> Type) op m r. (Mem rep inner, FreeIn op, MonadFreshNames m) => r -> Operations rep r op -> Space -> Prog rep -> m (Warnings, Definitions op)
- Futhark.CodeGen.ImpGen: compileStms :: Names -> Stms rep -> ImpM rep r op () -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: copy :: CopyCompiler rep r op
- Futhark.CodeGen.ImpGen: copyDWIM :: VName -> [DimIndex (TExp Int64)] -> SubExp -> [DimIndex (TExp Int64)] -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: copyDWIMFix :: VName -> [TExp Int64] -> SubExp -> [TExp Int64] -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: dArray :: VName -> PrimType -> ShapeBase SubExp -> VName -> LMAD -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: dFParams :: forall rep (inner :: Type -> Type) r op. Mem rep inner => [FParam rep] -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: dIndexSpace :: [(VName, TExp Int64)] -> TExp Int64 -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: dIndexSpace' :: String -> [TExp Int64] -> TExp Int64 -> ImpM rep r op [TExp Int64]
- Futhark.CodeGen.ImpGen: dLParams :: forall rep (inner :: Type -> Type) r op. Mem rep inner => [LParam rep] -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: dPrim :: forall {k} (t :: k) rep r op. MkTV t => String -> ImpM rep r op (TV t)
- Futhark.CodeGen.ImpGen: dPrimS :: String -> PrimType -> ImpM rep r op VName
- Futhark.CodeGen.ImpGen: dPrimSV :: forall {k} rep r op (t :: k). String -> PrimType -> ImpM rep r op (TV t)
- Futhark.CodeGen.ImpGen: dPrimV :: forall {k} (t :: k) rep r op. String -> TExp t -> ImpM rep r op (TV t)
- Futhark.CodeGen.ImpGen: dPrimVE :: forall {k} (t :: k) rep r op. String -> TExp t -> ImpM rep r op (TExp t)
- Futhark.CodeGen.ImpGen: dPrimV_ :: forall {k} (t :: k) rep r op. VName -> TExp t -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: dPrimVol :: forall {k} (t :: k) rep r op. String -> PrimType -> TExp t -> ImpM rep r op (TV t)
- Futhark.CodeGen.ImpGen: dPrim_ :: VName -> PrimType -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: dScope :: forall rep (inner :: Type -> Type) r op. Mem rep inner => Maybe (Exp rep) -> Scope rep -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: data ArrayEntry
- Futhark.CodeGen.ImpGen: data ImpM rep r op a
- Futhark.CodeGen.ImpGen: data MemLoc
- Futhark.CodeGen.ImpGen: data Operations rep r op
- Futhark.CodeGen.ImpGen: data TV (t :: k)
- Futhark.CodeGen.ImpGen: data VarEntry rep
- Futhark.CodeGen.ImpGen: defCompileExp :: forall rep (inner :: Type -> Type) r op. Mem rep inner => Pat (LetDec rep) -> Exp rep -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: defCompileStms :: forall rep (inner :: Type -> Type) op r. (Mem rep inner, FreeIn op) => Names -> Stms rep -> ImpM rep r op () -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: defaultOperations :: forall rep (inner :: Type -> Type) op r. (Mem rep inner, FreeIn op) => OpCompiler rep r op -> Operations rep r op
- Futhark.CodeGen.ImpGen: emit :: Code op -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: emitFunction :: Name -> Function op -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: everythingVolatile :: ImpM rep r op a -> ImpM rep r op a
- Futhark.CodeGen.ImpGen: fullyIndexArray :: VName -> [TExp Int64] -> ImpM rep r op (VName, Space, Count Elements (TExp Int64))
- Futhark.CodeGen.ImpGen: fullyIndexArray' :: MemLoc -> [TExp Int64] -> ImpM rep r op (VName, Space, Count Elements (TExp Int64))
- Futhark.CodeGen.ImpGen: function :: Name -> [Param] -> [Param] -> ImpM rep r op () -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: genConstants :: ImpM rep r op (Names, a) -> ImpM rep r op a
- Futhark.CodeGen.ImpGen: getVTable :: ImpM rep r op (VTable rep)
- Futhark.CodeGen.ImpGen: hasFunction :: Name -> ImpM rep r op Bool
- Futhark.CodeGen.ImpGen: inBounds :: Slice (TExp Int64) -> [TExp Int64] -> TExp Bool
- Futhark.CodeGen.ImpGen: infixl 3 <~~
- Futhark.CodeGen.ImpGen: instance Control.Monad.Reader.Class.MonadReader (Futhark.CodeGen.ImpGen.Env rep r op) (Futhark.CodeGen.ImpGen.ImpM rep r op)
- Futhark.CodeGen.ImpGen: instance Control.Monad.State.Class.MonadState (Futhark.CodeGen.ImpGen.ImpState rep r op) (Futhark.CodeGen.ImpGen.ImpM rep r op)
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.MkTV GHC.Int.Int16
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.MkTV GHC.Int.Int32
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.MkTV GHC.Int.Int64
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.MkTV GHC.Int.Int8
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.MkTV GHC.Types.Bool
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.MkTV GHC.Types.Double
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.MkTV GHC.Types.Float
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.MkTV Numeric.Half.Internal.Half
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.ToExp (Futhark.Analysis.PrimExp.PrimExp Language.Futhark.Core.VName)
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.ToExp Futhark.IR.Syntax.Core.SubExp
- Futhark.CodeGen.ImpGen: instance Futhark.CodeGen.ImpGen.ToExp Language.Futhark.Core.VName
- Futhark.CodeGen.ImpGen: instance Futhark.IR.Prop.Scope.HasScope Futhark.IR.SOACS.SOACS (Futhark.CodeGen.ImpGen.ImpM rep r op)
- Futhark.CodeGen.ImpGen: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.CodeGen.ImpGen.VarEntry rep)
- Futhark.CodeGen.ImpGen: instance Futhark.MonadFreshNames.MonadFreshNames (Futhark.CodeGen.ImpGen.ImpM rep r op)
- Futhark.CodeGen.ImpGen: instance GHC.Base.Applicative (Futhark.CodeGen.ImpGen.ImpM rep r op)
- Futhark.CodeGen.ImpGen: instance GHC.Base.Functor (Futhark.CodeGen.ImpGen.ImpM rep r op)
- Futhark.CodeGen.ImpGen: instance GHC.Base.Monad (Futhark.CodeGen.ImpGen.ImpM rep r op)
- Futhark.CodeGen.ImpGen: instance GHC.Classes.Eq Futhark.CodeGen.ImpGen.MemLoc
- Futhark.CodeGen.ImpGen: instance GHC.Show.Show Futhark.CodeGen.ImpGen.ArrayEntry
- Futhark.CodeGen.ImpGen: instance GHC.Show.Show Futhark.CodeGen.ImpGen.MemEntry
- Futhark.CodeGen.ImpGen: instance GHC.Show.Show Futhark.CodeGen.ImpGen.MemLoc
- Futhark.CodeGen.ImpGen: instance GHC.Show.Show Futhark.CodeGen.ImpGen.ScalarEntry
- Futhark.CodeGen.ImpGen: instance GHC.Show.Show Futhark.CodeGen.ImpGen.ValueDestination
- Futhark.CodeGen.ImpGen: lmadCopy :: CopyCompiler rep r op
- Futhark.CodeGen.ImpGen: localDefaultSpace :: Space -> ImpM rep r op a -> ImpM rep r op a
- Futhark.CodeGen.ImpGen: localEnv :: (r -> r) -> ImpM rep r op a -> ImpM rep r op a
- Futhark.CodeGen.ImpGen: localOps :: Operations rep r op -> ImpM rep r op a -> ImpM rep r op a
- Futhark.CodeGen.ImpGen: localVTable :: (VTable rep -> VTable rep) -> ImpM rep r op a -> ImpM rep r op a
- Futhark.CodeGen.ImpGen: lookupAcc :: VName -> [TExp Int64] -> ImpM rep r op (VName, Space, [VName], [TExp Int64], Maybe (Lambda rep))
- Futhark.CodeGen.ImpGen: lookupArray :: VName -> ImpM rep r op ArrayEntry
- Futhark.CodeGen.ImpGen: lookupArraySpace :: VName -> ImpM rep r op Space
- Futhark.CodeGen.ImpGen: lookupMemory :: VName -> ImpM rep r op MemEntry
- Futhark.CodeGen.ImpGen: lookupVar :: VName -> ImpM rep r op (VarEntry rep)
- Futhark.CodeGen.ImpGen: mkTV :: MkTV t => VName -> TV t
- Futhark.CodeGen.ImpGen: nameForFun :: String -> ImpM rep r op Name
- Futhark.CodeGen.ImpGen: newVName :: MonadFreshNames m => String -> m VName
- Futhark.CodeGen.ImpGen: newVNameForFun :: String -> ImpM rep r op VName
- Futhark.CodeGen.ImpGen: newtype MemEntry
- Futhark.CodeGen.ImpGen: newtype ScalarEntry
- Futhark.CodeGen.ImpGen: sAlloc :: String -> Count Bytes (TExp Int64) -> Space -> ImpM rep r op VName
- Futhark.CodeGen.ImpGen: sAllocArray :: String -> PrimType -> ShapeBase SubExp -> Space -> ImpM rep r op VName
- Futhark.CodeGen.ImpGen: sAllocArrayPerm :: String -> PrimType -> ShapeBase SubExp -> Space -> [Int] -> ImpM rep r op VName
- Futhark.CodeGen.ImpGen: sAlloc_ :: VName -> Count Bytes (TExp Int64) -> Space -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sArray :: String -> PrimType -> ShapeBase SubExp -> VName -> LMAD -> ImpM rep r op VName
- Futhark.CodeGen.ImpGen: sArrayInMem :: String -> PrimType -> ShapeBase SubExp -> VName -> ImpM rep r op VName
- Futhark.CodeGen.ImpGen: sComment :: Text -> ImpM rep r op () -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sDeclareMem :: String -> Space -> ImpM rep r op VName
- Futhark.CodeGen.ImpGen: sFor :: forall {k} (t :: k) rep r op. String -> TExp t -> (TExp t -> ImpM rep r op ()) -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sIf :: TExp Bool -> ImpM rep r op () -> ImpM rep r op () -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sLoopNest :: Shape -> ([TExp Int64] -> ImpM rep r op ()) -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sLoopSpace :: forall {k} (t :: k) rep r op. [TExp t] -> ([TExp t] -> ImpM rep r op ()) -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sOp :: op -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sStaticArray :: String -> PrimType -> ArrayContents -> ImpM rep r op VName
- Futhark.CodeGen.ImpGen: sUnless :: TExp Bool -> ImpM rep r op () -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sUpdate :: VName -> Slice (TExp Int64) -> SubExp -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sWhen :: TExp Bool -> ImpM rep r op () -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sWhile :: TExp Bool -> ImpM rep r op () -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sWrite :: VName -> [TExp Int64] -> Exp -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: sliceMemLoc :: MemLoc -> Slice (TExp Int64) -> MemLoc
- Futhark.CodeGen.ImpGen: subImpM :: r' -> Operations rep r' op' -> ImpM rep r' op' a -> ImpM rep r op (a, Code op')
- Futhark.CodeGen.ImpGen: subImpM_ :: r' -> Operations rep r' op' -> ImpM rep r' op' a -> ImpM rep r op (Code op')
- Futhark.CodeGen.ImpGen: toExp :: ToExp a => a -> ImpM rep r op Exp
- Futhark.CodeGen.ImpGen: toExp' :: ToExp a => PrimType -> a -> Exp
- Futhark.CodeGen.ImpGen: tvExp :: forall {k} (t :: k). TV t -> TExp t
- Futhark.CodeGen.ImpGen: tvSize :: forall {k} (t :: k). TV t -> DimSize
- Futhark.CodeGen.ImpGen: tvType :: MkTV t => TV t -> PrimType
- Futhark.CodeGen.ImpGen: tvVar :: forall {k} (t :: k). TV t -> VName
- Futhark.CodeGen.ImpGen: type AllocCompiler rep r op = VName -> Count Bytes TExp Int64 -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: type CopyCompiler rep r op = PrimType -> MemLoc -> MemLoc -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: type ExpCompiler rep r op = Pat LetDec rep -> Exp rep -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: type OpCompiler rep r op = Pat LetDec rep -> Op rep -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: type StmsCompiler rep r op = Names -> Stms rep -> ImpM rep r op () -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen: type VTable rep = Map VName VarEntry rep
- Futhark.CodeGen.ImpGen: typeSize :: Type -> Count Bytes (TExp Int64)
- Futhark.CodeGen.ImpGen: warn :: Located loc => loc -> [loc] -> Text -> ImpM rep r op ()
- Futhark.CodeGen.ImpGen.CUDA: compileProg :: MonadFreshNames m => Prog GPUMem -> m (Warnings, Program)
- Futhark.CodeGen.ImpGen.CUDA: data Warnings
- Futhark.CodeGen.ImpGen.GPU: compileProgCUDA :: MonadFreshNames m => Prog GPUMem -> m (Warnings, Program)
- Futhark.CodeGen.ImpGen.GPU: compileProgHIP :: MonadFreshNames m => Prog GPUMem -> m (Warnings, Program)
- Futhark.CodeGen.ImpGen.GPU: compileProgOpenCL :: MonadFreshNames m => Prog GPUMem -> m (Warnings, Program)
- Futhark.CodeGen.ImpGen.GPU: data Warnings
- Futhark.CodeGen.ImpGen.GPU.Base: AtomicCAS :: DoAtomicUpdate rep r -> AtomicUpdate rep r
- Futhark.CodeGen.ImpGen.GPU.Base: AtomicLocking :: (Locking -> DoAtomicUpdate rep r) -> AtomicUpdate rep r
- Futhark.CodeGen.ImpGen.GPU.Base: AtomicPrim :: DoAtomicUpdate rep r -> AtomicUpdate rep r
- Futhark.CodeGen.ImpGen.GPU.Base: CUDA :: Target
- Futhark.CodeGen.ImpGen.GPU.Base: HIP :: Target
- Futhark.CodeGen.ImpGen.GPU.Base: HostEnv :: AtomicBinOp -> Target -> Map VName Locks -> HostEnv
- Futhark.CodeGen.ImpGen.GPU.Base: KernelAttrs :: Bool -> Bool -> Count NumBlocks SubExp -> Count BlockSize SubExp -> Map VName KernelConstExp -> KernelAttrs
- Futhark.CodeGen.ImpGen.GPU.Base: KernelConstants :: TV Int32 -> TV Int32 -> TV Int32 -> Count NumBlocks SubExp -> Count BlockSize SubExp -> TExp Int64 -> TExp Int64 -> TExp Int32 -> TExp Int32 -> Map [SubExp] [TExp Int32] -> Map [SubExp] (TExp Int32) -> KernelConstants
- Futhark.CodeGen.ImpGen.GPU.Base: KernelEnv :: AtomicBinOp -> KernelConstants -> Map VName Locks -> KernelEnv
- Futhark.CodeGen.ImpGen.GPU.Base: Locking :: VName -> TExp Int32 -> TExp Int32 -> TExp Int32 -> ([TExp Int64] -> [TExp Int64]) -> Locking
- Futhark.CodeGen.ImpGen.GPU.Base: Locks :: VName -> Int -> Locks
- Futhark.CodeGen.ImpGen.GPU.Base: OpenCL :: Target
- Futhark.CodeGen.ImpGen.GPU.Base: [hostAtomics] :: HostEnv -> AtomicBinOp
- Futhark.CodeGen.ImpGen.GPU.Base: [hostLocks] :: HostEnv -> Map VName Locks
- Futhark.CodeGen.ImpGen.GPU.Base: [hostTarget] :: HostEnv -> Target
- Futhark.CodeGen.ImpGen.GPU.Base: [kAttrBlockSize] :: KernelAttrs -> Count BlockSize SubExp
- Futhark.CodeGen.ImpGen.GPU.Base: [kAttrCheckSharedMemory] :: KernelAttrs -> Bool
- Futhark.CodeGen.ImpGen.GPU.Base: [kAttrConstExps] :: KernelAttrs -> Map VName KernelConstExp
- Futhark.CodeGen.ImpGen.GPU.Base: [kAttrFailureTolerant] :: KernelAttrs -> Bool
- Futhark.CodeGen.ImpGen.GPU.Base: [kAttrNumBlocks] :: KernelAttrs -> Count NumBlocks SubExp
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelAtomics] :: KernelEnv -> AtomicBinOp
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelBlockIdVar] :: KernelConstants -> TV Int32
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelBlockSizeCount] :: KernelConstants -> Count BlockSize SubExp
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelBlockSize] :: KernelConstants -> TExp Int64
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelChunkItersMap] :: KernelConstants -> Map [SubExp] (TExp Int32)
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelConstants] :: KernelEnv -> KernelConstants
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelGlobalThreadIdVar] :: KernelConstants -> TV Int32
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelLocalIdMap] :: KernelConstants -> Map [SubExp] [TExp Int32]
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelLocalThreadIdVar] :: KernelConstants -> TV Int32
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelLocks] :: KernelEnv -> Map VName Locks
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelNumBlocksCount] :: KernelConstants -> Count NumBlocks SubExp
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelNumBlocks] :: KernelConstants -> TExp Int64
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelNumThreads] :: KernelConstants -> TExp Int32
- Futhark.CodeGen.ImpGen.GPU.Base: [kernelWaveSize] :: KernelConstants -> TExp Int32
- Futhark.CodeGen.ImpGen.GPU.Base: [lockingArray] :: Locking -> VName
- Futhark.CodeGen.ImpGen.GPU.Base: [lockingIsUnlocked] :: Locking -> TExp Int32
- Futhark.CodeGen.ImpGen.GPU.Base: [lockingMapping] :: Locking -> [TExp Int64] -> [TExp Int64]
- Futhark.CodeGen.ImpGen.GPU.Base: [lockingToLock] :: Locking -> TExp Int32
- Futhark.CodeGen.ImpGen.GPU.Base: [lockingToUnlock] :: Locking -> TExp Int32
- Futhark.CodeGen.ImpGen.GPU.Base: [locksArray] :: Locks -> VName
- Futhark.CodeGen.ImpGen.GPU.Base: [locksCount] :: Locks -> Int
- Futhark.CodeGen.ImpGen.GPU.Base: allocLocal :: AllocCompiler GPUMem r KernelOp
- Futhark.CodeGen.ImpGen.GPU.Base: atomicUpdateLocking :: AtomicBinOp -> Lambda GPUMem -> AtomicUpdate GPUMem KernelEnv
- Futhark.CodeGen.ImpGen.GPU.Base: blockCoverSpace :: forall {k} (t :: k). IntExp t => [TExp t] -> ([TExp t] -> InKernelGen ()) -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: blockLoop :: forall {k} (t :: k). IntExp t => TExp t -> (TExp t -> InKernelGen ()) -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: blockReduce :: TExp Int32 -> Lambda GPUMem -> [VName] -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: blockScan :: Maybe (TExp Int32 -> TExp Int32 -> TExp Bool) -> TExp Int64 -> TExp Int64 -> Lambda GPUMem -> [VName] -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: compileThreadResult :: SegSpace -> PatElem LetDecMem -> KernelResult -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: data AtomicUpdate rep r
- Futhark.CodeGen.ImpGen.GPU.Base: data HostEnv
- Futhark.CodeGen.ImpGen.GPU.Base: data KernelAttrs
- Futhark.CodeGen.ImpGen.GPU.Base: data KernelConstants
- Futhark.CodeGen.ImpGen.GPU.Base: data KernelEnv
- Futhark.CodeGen.ImpGen.GPU.Base: data Locking
- Futhark.CodeGen.ImpGen.GPU.Base: data Locks
- Futhark.CodeGen.ImpGen.GPU.Base: data Target
- Futhark.CodeGen.ImpGen.GPU.Base: defKernelAttrs :: Count NumBlocks SubExp -> Count BlockSize SubExp -> KernelAttrs
- Futhark.CodeGen.ImpGen.GPU.Base: fenceForArrays :: [VName] -> InKernelGen Fence
- Futhark.CodeGen.ImpGen.GPU.Base: genZeroes :: String -> Int -> CallKernelGen VName
- Futhark.CodeGen.ImpGen.GPU.Base: getChunkSize :: [Type] -> KernelConstExp
- Futhark.CodeGen.ImpGen.GPU.Base: getSize :: String -> SizeClass -> CallKernelGen (TV Int64)
- Futhark.CodeGen.ImpGen.GPU.Base: isActive :: [(VName, SubExp)] -> TExp Bool
- Futhark.CodeGen.ImpGen.GPU.Base: isPrimParam :: Typed p => Param p -> Bool
- Futhark.CodeGen.ImpGen.GPU.Base: kernelBlockId :: KernelConstants -> TExp Int32
- Futhark.CodeGen.ImpGen.GPU.Base: kernelConstToExp :: KernelConstExp -> CallKernelGen Exp
- Futhark.CodeGen.ImpGen.GPU.Base: kernelGlobalThreadId :: KernelConstants -> TExp Int32
- Futhark.CodeGen.ImpGen.GPU.Base: kernelLocalThreadId :: KernelConstants -> TExp Int32
- Futhark.CodeGen.ImpGen.GPU.Base: kernelLoop :: forall {k} (t :: k). IntExp t => TExp t -> TExp t -> TExp t -> (TExp t -> InKernelGen ()) -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: keyWithEntryPoint :: Maybe Name -> Name -> Name
- Futhark.CodeGen.ImpGen.GPU.Base: lvlKernelAttrs :: SegLevel -> CallKernelGen KernelAttrs
- Futhark.CodeGen.ImpGen.GPU.Base: sIota :: VName -> TExp Int64 -> Exp -> Exp -> IntType -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: sKernel :: Operations GPUMem KernelEnv KernelOp -> (KernelConstants -> TExp Int64) -> String -> VName -> KernelAttrs -> InKernelGen () -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: sKernelThread :: String -> VName -> KernelAttrs -> InKernelGen () -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: sReplicate :: VName -> SubExp -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: threadOperations :: Operations GPUMem KernelEnv KernelOp
- Futhark.CodeGen.ImpGen.GPU.Base: type AtomicBinOp = BinOp -> Maybe VName -> VName -> Count Elements TExp Int64 -> Exp -> AtomicOp
- Futhark.CodeGen.ImpGen.GPU.Base: type CallKernelGen = ImpM GPUMem HostEnv HostOp
- Futhark.CodeGen.ImpGen.GPU.Base: type DoAtomicUpdate rep r = Space -> [VName] -> [TExp Int64] -> ImpM rep r KernelOp ()
- Futhark.CodeGen.ImpGen.GPU.Base: type InKernelGen = ImpM GPUMem KernelEnv KernelOp
- Futhark.CodeGen.ImpGen.GPU.Base: updateAcc :: Safety -> VName -> [SubExp] -> [SubExp] -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: virtualiseBlocks :: SegVirt -> TExp Int32 -> (TExp Int32 -> InKernelGen ()) -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Base: writeAtomic :: VName -> [TExp Int64] -> SubExp -> [TExp Int64] -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Block: atomicUpdateLocking :: AtomicBinOp -> Lambda GPUMem -> AtomicUpdate GPUMem KernelEnv
- Futhark.CodeGen.ImpGen.GPU.Block: blockOperations :: Operations GPUMem KernelEnv KernelOp
- Futhark.CodeGen.ImpGen.GPU.Block: compileBlockResult :: SegSpace -> PatElem LetDecMem -> KernelResult -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.Block: data Precomputed
- Futhark.CodeGen.ImpGen.GPU.Block: precomputeConstants :: Count BlockSize (TExp Int64) -> Stms GPUMem -> CallKernelGen Precomputed
- Futhark.CodeGen.ImpGen.GPU.Block: precomputedConstants :: Precomputed -> InKernelGen a -> InKernelGen a
- Futhark.CodeGen.ImpGen.GPU.Block: sKernelBlock :: String -> VName -> KernelAttrs -> InKernelGen () -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.SegHist: compileSegHist :: Pat LetDecMem -> SegLevel -> SegSpace -> [HistOp GPUMem] -> KernelBody GPUMem -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.SegHist: instance GHC.Classes.Eq Futhark.CodeGen.ImpGen.GPU.SegHist.Passage
- Futhark.CodeGen.ImpGen.GPU.SegHist: instance GHC.Classes.Ord Futhark.CodeGen.ImpGen.GPU.SegHist.Passage
- Futhark.CodeGen.ImpGen.GPU.SegMap: compileSegMap :: Pat LetDecMem -> SegLevel -> SegSpace -> KernelBody GPUMem -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.SegRed: compileSegRed :: Pat LetDecMem -> SegLevel -> SegSpace -> [SegBinOp GPUMem] -> KernelBody GPUMem -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.SegRed: compileSegRed' :: Pat LetDecMem -> KernelGrid -> SegSpace -> [SegBinOp GPUMem] -> DoSegBody -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.SegRed: type DoSegBody = [(SubExp, [TExp Int64])] -> InKernelGen () -> InKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.SegScan: compileSegScan :: Pat LetDecMem -> SegLevel -> SegSpace -> [SegBinOp GPUMem] -> KernelBody GPUMem -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.SegScan.SinglePass: compileSegScan :: Pat LetDecMem -> SegLevel -> SegSpace -> SegBinOp GPUMem -> KernelBody GPUMem -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.SegScan.TwoPass: compileSegScan :: Pat LetDecMem -> SegLevel -> SegSpace -> [SegBinOp GPUMem] -> KernelBody GPUMem -> CallKernelGen ()
- Futhark.CodeGen.ImpGen.GPU.ToOpenCL: instance GHC.Classes.Eq Futhark.CodeGen.ImpGen.GPU.ToOpenCL.OpsMode
- Futhark.CodeGen.ImpGen.GPU.ToOpenCL: kernelsToCUDA :: Program -> Program
- Futhark.CodeGen.ImpGen.GPU.ToOpenCL: kernelsToHIP :: Program -> Program
- Futhark.CodeGen.ImpGen.GPU.ToOpenCL: kernelsToOpenCL :: Program -> Program
- Futhark.CodeGen.ImpGen.HIP: compileProg :: MonadFreshNames m => Prog GPUMem -> m (Warnings, Program)
- Futhark.CodeGen.ImpGen.HIP: data Warnings
- Futhark.CodeGen.ImpGen.Multicore: compileProg :: MonadFreshNames m => Prog MCMem -> m (Warnings, Definitions Multicore)
- Futhark.CodeGen.ImpGen.Multicore: data Warnings
- Futhark.CodeGen.ImpGen.Multicore.Base: AtomicCAS :: DoAtomicUpdate rep r -> AtomicUpdate (rep :: k) (r :: k1)
- Futhark.CodeGen.ImpGen.Multicore.Base: AtomicLocking :: (Locking -> DoAtomicUpdate rep r) -> AtomicUpdate (rep :: k) (r :: k1)
- Futhark.CodeGen.ImpGen.Multicore.Base: AtomicPrim :: DoAtomicUpdate rep r -> AtomicUpdate (rep :: k) (r :: k1)
- Futhark.CodeGen.ImpGen.Multicore.Base: HostEnv :: AtomicBinOp -> Map VName Locks -> HostEnv
- Futhark.CodeGen.ImpGen.Multicore.Base: Locking :: VName -> TExp Int32 -> TExp Int32 -> TExp Int32 -> ([TExp Int64] -> [TExp Int64]) -> Locking
- Futhark.CodeGen.ImpGen.Multicore.Base: Locks :: VName -> Int -> Locks
- Futhark.CodeGen.ImpGen.Multicore.Base: Scalar :: ChunkLoopVectorization
- Futhark.CodeGen.ImpGen.Multicore.Base: Vectorized :: ChunkLoopVectorization
- Futhark.CodeGen.ImpGen.Multicore.Base: [hostAtomics] :: HostEnv -> AtomicBinOp
- Futhark.CodeGen.ImpGen.Multicore.Base: [hostLocks] :: HostEnv -> Map VName Locks
- Futhark.CodeGen.ImpGen.Multicore.Base: [lockingArray] :: Locking -> VName
- Futhark.CodeGen.ImpGen.Multicore.Base: [lockingIsUnlocked] :: Locking -> TExp Int32
- Futhark.CodeGen.ImpGen.Multicore.Base: [lockingMapping] :: Locking -> [TExp Int64] -> [TExp Int64]
- Futhark.CodeGen.ImpGen.Multicore.Base: [lockingToLock] :: Locking -> TExp Int32
- Futhark.CodeGen.ImpGen.Multicore.Base: [lockingToUnlock] :: Locking -> TExp Int32
- Futhark.CodeGen.ImpGen.Multicore.Base: [locksArray] :: Locks -> VName
- Futhark.CodeGen.ImpGen.Multicore.Base: [locksCount] :: Locks -> Int
- Futhark.CodeGen.ImpGen.Multicore.Base: atomicUpdateLocking :: AtomicBinOp -> Lambda MCMem -> AtomicUpdate MCMem ()
- Futhark.CodeGen.ImpGen.Multicore.Base: compileThreadResult :: SegSpace -> PatElem LetDecMem -> KernelResult -> MulticoreGen ()
- Futhark.CodeGen.ImpGen.Multicore.Base: data AtomicUpdate (rep :: k) (r :: k1)
- Futhark.CodeGen.ImpGen.Multicore.Base: data ChunkLoopVectorization
- Futhark.CodeGen.ImpGen.Multicore.Base: data HostEnv
- Futhark.CodeGen.ImpGen.Multicore.Base: data Locking
- Futhark.CodeGen.ImpGen.Multicore.Base: data Locks
- Futhark.CodeGen.ImpGen.Multicore.Base: decideScheduling :: MCCode -> Scheduling
- Futhark.CodeGen.ImpGen.Multicore.Base: decideScheduling' :: SegOp () rep -> MCCode -> Scheduling
- Futhark.CodeGen.ImpGen.Multicore.Base: extractAllocations :: MCCode -> (MCCode, MCCode)
- Futhark.CodeGen.ImpGen.Multicore.Base: extractVectorLane :: TExp Int64 -> MulticoreGen MCCode -> MulticoreGen ()
- Futhark.CodeGen.ImpGen.Multicore.Base: freeParams :: FreeIn a => a -> MulticoreGen [Param]
- Futhark.CodeGen.ImpGen.Multicore.Base: generateChunkLoop :: String -> ChunkLoopVectorization -> (TExp Int64 -> MulticoreGen ()) -> MulticoreGen ()
- Futhark.CodeGen.ImpGen.Multicore.Base: generateUniformizeLoop :: (TExp Int64 -> MulticoreGen ()) -> MulticoreGen ()
- Futhark.CodeGen.ImpGen.Multicore.Base: getIterationDomain :: SegOp () MCMem -> SegSpace -> MulticoreGen (TExp Int64)
- Futhark.CodeGen.ImpGen.Multicore.Base: getLoopBounds :: MulticoreGen (TExp Int64, TExp Int64)
- Futhark.CodeGen.ImpGen.Multicore.Base: getReturnParams :: Pat LetDecMem -> SegOp () MCMem -> MulticoreGen [Param]
- Futhark.CodeGen.ImpGen.Multicore.Base: getSpace :: SegOp () MCMem -> SegSpace
- Futhark.CodeGen.ImpGen.Multicore.Base: inISPC :: MulticoreGen () -> MulticoreGen ()
- Futhark.CodeGen.ImpGen.Multicore.Base: renameHistOpLambda :: [HistOp MCMem] -> MulticoreGen [HistOp MCMem]
- Futhark.CodeGen.ImpGen.Multicore.Base: renameSegBinOp :: [SegBinOp MCMem] -> MulticoreGen [SegBinOp MCMem]
- Futhark.CodeGen.ImpGen.Multicore.Base: sLoopNestVectorized :: Shape -> ([TExp Int64] -> MulticoreGen ()) -> MulticoreGen ()
- Futhark.CodeGen.ImpGen.Multicore.Base: segOpString :: SegOp () MCMem -> MulticoreGen String
- Futhark.CodeGen.ImpGen.Multicore.Base: toParam :: VName -> TypeBase shape u -> MulticoreGen [Param]
- Futhark.CodeGen.ImpGen.Multicore.Base: type AtomicBinOp = BinOp -> Maybe VName -> VName -> Count Elements TExp Int32 -> Exp -> AtomicOp
- Futhark.CodeGen.ImpGen.Multicore.Base: type DoAtomicUpdate (rep :: k) (r :: k1) = [VName] -> [TExp Int64] -> MulticoreGen ()
- Futhark.CodeGen.ImpGen.Multicore.Base: type MulticoreGen = ImpM MCMem HostEnv Multicore
- Futhark.CodeGen.ImpGen.Multicore.SegHist: compileSegHist :: Pat LetDecMem -> SegSpace -> [HistOp MCMem] -> KernelBody MCMem -> TV Int32 -> MulticoreGen MCCode
- Futhark.CodeGen.ImpGen.Multicore.SegMap: compileSegMap :: Pat LetDecMem -> SegSpace -> KernelBody MCMem -> MulticoreGen MCCode
- Futhark.CodeGen.ImpGen.Multicore.SegRed: compileSegRed :: Pat LetDecMem -> SegSpace -> [SegBinOp MCMem] -> KernelBody MCMem -> TV Int32 -> MulticoreGen MCCode
- Futhark.CodeGen.ImpGen.Multicore.SegRed: compileSegRed' :: Pat LetDecMem -> SegSpace -> [SegBinOp MCMem] -> TV Int32 -> DoSegBody -> MulticoreGen MCCode
- Futhark.CodeGen.ImpGen.Multicore.SegRed: type DoSegBody = [[(SubExp, [TExp Int64])]] -> MulticoreGen () -> MulticoreGen ()
- Futhark.CodeGen.ImpGen.Multicore.SegScan: compileSegScan :: Pat LetDecMem -> SegSpace -> [SegBinOp MCMem] -> KernelBody MCMem -> TV Int32 -> MulticoreGen MCCode
- Futhark.CodeGen.ImpGen.OpenCL: compileProg :: MonadFreshNames m => Prog GPUMem -> m (Warnings, Program)
- Futhark.CodeGen.ImpGen.OpenCL: data Warnings
- Futhark.CodeGen.ImpGen.Sequential: compileProg :: MonadFreshNames m => Prog SeqMem -> m (Warnings, Program)
- Futhark.CodeGen.ImpGen.Sequential: data Warnings
- Futhark.CodeGen.OpenCL.Heuristics: BlockSize :: WhichSize
- Futhark.CodeGen.OpenCL.Heuristics: DeviceCPU :: DeviceType
- Futhark.CodeGen.OpenCL.Heuristics: DeviceGPU :: DeviceType
- Futhark.CodeGen.OpenCL.Heuristics: DeviceInfo :: String -> DeviceInfo
- Futhark.CodeGen.OpenCL.Heuristics: LockstepWidth :: WhichSize
- Futhark.CodeGen.OpenCL.Heuristics: NumBlocks :: WhichSize
- Futhark.CodeGen.OpenCL.Heuristics: RegTileSize :: WhichSize
- Futhark.CodeGen.OpenCL.Heuristics: SizeHeuristic :: String -> DeviceType -> WhichSize -> TPrimExp Int32 DeviceInfo -> SizeHeuristic
- Futhark.CodeGen.OpenCL.Heuristics: Threshold :: WhichSize
- Futhark.CodeGen.OpenCL.Heuristics: TileSize :: WhichSize
- Futhark.CodeGen.OpenCL.Heuristics: [deviceType] :: SizeHeuristic -> DeviceType
- Futhark.CodeGen.OpenCL.Heuristics: [heuristicSize] :: SizeHeuristic -> WhichSize
- Futhark.CodeGen.OpenCL.Heuristics: [heuristicValue] :: SizeHeuristic -> TPrimExp Int32 DeviceInfo
- Futhark.CodeGen.OpenCL.Heuristics: [platformName] :: SizeHeuristic -> String
- Futhark.CodeGen.OpenCL.Heuristics: data DeviceType
- Futhark.CodeGen.OpenCL.Heuristics: data SizeHeuristic
- Futhark.CodeGen.OpenCL.Heuristics: data WhichSize
- Futhark.CodeGen.OpenCL.Heuristics: instance Prettyprinter.Internal.Pretty Futhark.CodeGen.OpenCL.Heuristics.DeviceInfo
- Futhark.CodeGen.OpenCL.Heuristics: newtype DeviceInfo
- Futhark.CodeGen.OpenCL.Heuristics: sizeHeuristicsTable :: [SizeHeuristic]
- Futhark.CodeGen.RTS.C: atomicsH :: Text
- Futhark.CodeGen.RTS.C: backendsCH :: Text
- Futhark.CodeGen.RTS.C: backendsCudaH :: Text
- Futhark.CodeGen.RTS.C: backendsHipH :: Text
- Futhark.CodeGen.RTS.C: backendsMulticoreH :: Text
- Futhark.CodeGen.RTS.C: backendsOpenclH :: Text
- Futhark.CodeGen.RTS.C: cacheH :: Text
- Futhark.CodeGen.RTS.C: contextH :: Text
- Futhark.CodeGen.RTS.C: contextPrototypesH :: Text
- Futhark.CodeGen.RTS.C: copyH :: Text
- Futhark.CodeGen.RTS.C: errorsH :: Text
- Futhark.CodeGen.RTS.C: eventListH :: Text
- Futhark.CodeGen.RTS.C: freeListH :: Text
- Futhark.CodeGen.RTS.C: gpuH :: Text
- Futhark.CodeGen.RTS.C: gpuPrototypesH :: Text
- Futhark.CodeGen.RTS.C: halfH :: Text
- Futhark.CodeGen.RTS.C: ispcUtilH :: Text
- Futhark.CodeGen.RTS.C: lockH :: Text
- Futhark.CodeGen.RTS.C: scalarF16H :: Text
- Futhark.CodeGen.RTS.C: scalarH :: Text
- Futhark.CodeGen.RTS.C: schedulerH :: Text
- Futhark.CodeGen.RTS.C: serverH :: Text
- Futhark.CodeGen.RTS.C: timingH :: Text
- Futhark.CodeGen.RTS.C: tuningH :: Text
- Futhark.CodeGen.RTS.C: uniformH :: Text
- Futhark.CodeGen.RTS.C: utilH :: Text
- Futhark.CodeGen.RTS.C: valuesH :: Text
- Futhark.CodeGen.RTS.CUDA: preludeCU :: Text
- Futhark.CodeGen.RTS.JavaScript: serverJs :: Text
- Futhark.CodeGen.RTS.JavaScript: valuesJs :: Text
- Futhark.CodeGen.RTS.JavaScript: wrapperclassesJs :: Text
- Futhark.CodeGen.RTS.OpenCL: copyCL :: Text
- Futhark.CodeGen.RTS.OpenCL: preludeCL :: Text
- Futhark.CodeGen.RTS.OpenCL: transposeCL :: Text
- Futhark.CodeGen.RTS.Python: memoryPy :: Text
- Futhark.CodeGen.RTS.Python: openclPy :: Text
- Futhark.CodeGen.RTS.Python: panicPy :: Text
- Futhark.CodeGen.RTS.Python: scalarPy :: Text
- Futhark.CodeGen.RTS.Python: serverPy :: Text
- Futhark.CodeGen.RTS.Python: tuningPy :: Text
- Futhark.CodeGen.RTS.Python: valuesPy :: Text
- Futhark.Compiler: dumpError :: FutharkConfig -> CompilerError -> IO ()
- Futhark.Compiler: handleWarnings :: FutharkConfig -> FutharkM (Warnings, a) -> FutharkM a
- Futhark.Compiler: prettyProgErrors :: NonEmpty ProgError -> Doc AnsiStyle
- Futhark.Compiler: readProgramFile :: (MonadError CompilerError m, MonadIO m) => [Name] -> FilePath -> m (Warnings, Imports, VNameSource)
- Futhark.Compiler: readProgramFiles :: (MonadError CompilerError m, MonadIO m) => [Name] -> [FilePath] -> m (Warnings, Imports, VNameSource)
- Futhark.Compiler: readProgramOrDie :: MonadIO m => FilePath -> m (Warnings, Imports, VNameSource)
- Futhark.Compiler: readUntypedProgram :: (MonadError CompilerError m, MonadIO m) => FilePath -> m [(String, UncheckedProg)]
- Futhark.Compiler: readUntypedProgramOrDie :: MonadIO m => FilePath -> m [(String, UncheckedProg)]
- Futhark.Compiler: runCompilerOnProgram :: FutharkConfig -> Pipeline SOACS rep -> Action rep -> FilePath -> IO ()
- Futhark.Compiler: runPipelineOnProgram :: FutharkConfig -> Pipeline SOACS torep -> FilePath -> FutharkM (Prog torep)
- Futhark.Compiler.CLI: ToExecutable :: CompilerMode
- Futhark.Compiler.CLI: ToLibrary :: CompilerMode
- Futhark.Compiler.CLI: ToServer :: CompilerMode
- Futhark.Compiler.CLI: compilerMain :: cfg -> [CompilerOption cfg] -> String -> String -> Pipeline SOACS rep -> (FutharkConfig -> cfg -> CompilerMode -> FilePath -> Prog rep -> FutharkM ()) -> String -> [String] -> IO ()
- Futhark.Compiler.CLI: data CompilerMode
- Futhark.Compiler.CLI: type CompilerOption cfg = OptDescr Either IO () cfg -> cfg
- Futhark.Compiler.Config: FutharkConfig :: (Verbosity, Maybe FilePath) -> Bool -> Bool -> Bool -> [Name] -> Bool -> FutharkConfig
- Futhark.Compiler.Config: NotVerbose :: Verbosity
- Futhark.Compiler.Config: ToExecutable :: CompilerMode
- Futhark.Compiler.Config: ToLibrary :: CompilerMode
- Futhark.Compiler.Config: ToServer :: CompilerMode
- Futhark.Compiler.Config: Verbose :: Verbosity
- Futhark.Compiler.Config: VeryVerbose :: Verbosity
- Futhark.Compiler.Config: [futharkEntryPoints] :: FutharkConfig -> [Name]
- Futhark.Compiler.Config: [futharkSafe] :: FutharkConfig -> Bool
- Futhark.Compiler.Config: [futharkTypeCheck] :: FutharkConfig -> Bool
- Futhark.Compiler.Config: [futharkVerbose] :: FutharkConfig -> (Verbosity, Maybe FilePath)
- Futhark.Compiler.Config: [futharkWarn] :: FutharkConfig -> Bool
- Futhark.Compiler.Config: [futharkWerror] :: FutharkConfig -> Bool
- Futhark.Compiler.Config: data CompilerMode
- Futhark.Compiler.Config: data FutharkConfig
- Futhark.Compiler.Config: data Verbosity
- Futhark.Compiler.Config: instance GHC.Classes.Eq Futhark.Compiler.Config.CompilerMode
- Futhark.Compiler.Config: instance GHC.Classes.Eq Futhark.Compiler.Config.Verbosity
- Futhark.Compiler.Config: instance GHC.Classes.Ord Futhark.Compiler.Config.CompilerMode
- Futhark.Compiler.Config: instance GHC.Classes.Ord Futhark.Compiler.Config.Verbosity
- Futhark.Compiler.Config: instance GHC.Show.Show Futhark.Compiler.Config.CompilerMode
- Futhark.Compiler.Config: newFutharkConfig :: FutharkConfig
- Futhark.Compiler.Program: FileModule :: TySet -> Env -> Prog -> Env -> FileModule
- Futhark.Compiler.Program: ProgError :: Loc -> Doc () -> ProgError
- Futhark.Compiler.Program: ProgWarning :: Loc -> Doc () -> ProgError
- Futhark.Compiler.Program: [fileAbs] :: FileModule -> TySet
- Futhark.Compiler.Program: [fileEnv] :: FileModule -> Env
- Futhark.Compiler.Program: [fileProg] :: FileModule -> Prog
- Futhark.Compiler.Program: [fileScope] :: FileModule -> Env
- Futhark.Compiler.Program: data FileModule
- Futhark.Compiler.Program: data LoadedProg
- Futhark.Compiler.Program: data ProgError
- Futhark.Compiler.Program: data Warnings
- Futhark.Compiler.Program: extendProg :: LoadedProg -> [FilePath] -> VFS -> IO (Either (NonEmpty ProgError) LoadedProg)
- Futhark.Compiler.Program: instance Data.Loc.Located Futhark.Compiler.Program.ProgError
- Futhark.Compiler.Program: instance GHC.Classes.Eq fm => GHC.Classes.Eq (Futhark.Compiler.Program.LoadedFile fm)
- Futhark.Compiler.Program: instance GHC.Classes.Ord fm => GHC.Classes.Ord (Futhark.Compiler.Program.LoadedFile fm)
- Futhark.Compiler.Program: instance GHC.Show.Show fm => GHC.Show.Show (Futhark.Compiler.Program.LoadedFile fm)
- Futhark.Compiler.Program: lpFilePaths :: LoadedProg -> [FilePath]
- Futhark.Compiler.Program: lpImports :: LoadedProg -> Imports
- Futhark.Compiler.Program: lpWarnings :: LoadedProg -> Warnings
- Futhark.Compiler.Program: noLoadedProg :: LoadedProg
- Futhark.Compiler.Program: prettyWarnings :: Warnings -> Doc AnsiStyle
- Futhark.Compiler.Program: readLibrary :: [Name] -> [FilePath] -> IO (Either (NonEmpty ProgError) (Warnings, Imports, VNameSource))
- Futhark.Compiler.Program: readUntypedLibrary :: [FilePath] -> IO (Either (NonEmpty ProgError) [(ImportName, UncheckedProg)])
- Futhark.Compiler.Program: reloadProg :: LoadedProg -> [FilePath] -> VFS -> IO (Either (NonEmpty ProgError) LoadedProg)
- Futhark.Compiler.Program: type Imports = [(ImportName, FileModule)]
- Futhark.Compiler.Program: type VFS = Map FilePath Text
- Futhark.Construct: asIntS :: MonadBuilder m => IntType -> SubExp -> m SubExp
- Futhark.Construct: asIntZ :: MonadBuilder m => IntType -> SubExp -> m SubExp
- Futhark.Construct: binOpLambda :: (MonadBuilder m, Buildable (Rep m)) => BinOp -> PrimType -> m (Lambda (Rep m))
- Futhark.Construct: buildBody :: MonadBuilder m => m (Result, a) -> m (Body (Rep m), a)
- Futhark.Construct: buildBody_ :: MonadBuilder m => m Result -> m (Body (Rep m))
- Futhark.Construct: class ToExp a
- Futhark.Construct: cmpOpLambda :: (MonadBuilder m, Buildable (Rep m)) => CmpOp -> m (Lambda (Rep m))
- Futhark.Construct: eAll :: MonadBuilder m => [SubExp] -> m (Exp (Rep m))
- Futhark.Construct: eAny :: MonadBuilder m => [SubExp] -> m (Exp (Rep m))
- Futhark.Construct: eBinOp :: MonadBuilder m => BinOp -> m (Exp (Rep m)) -> m (Exp (Rep m)) -> m (Exp (Rep m))
- Futhark.Construct: eBlank :: MonadBuilder m => Type -> m (Exp (Rep m))
- Futhark.Construct: eBody :: MonadBuilder m => [m (Exp (Rep m))] -> m (Body (Rep m))
- Futhark.Construct: eCmpOp :: MonadBuilder m => CmpOp -> m (Exp (Rep m)) -> m (Exp (Rep m)) -> m (Exp (Rep m))
- Futhark.Construct: eConvOp :: MonadBuilder m => ConvOp -> m (Exp (Rep m)) -> m (Exp (Rep m))
- Futhark.Construct: eCopy :: MonadBuilder m => m (Exp (Rep m)) -> m (Exp (Rep m))
- Futhark.Construct: eDimInBounds :: MonadBuilder m => m (Exp (Rep m)) -> m (Exp (Rep m)) -> m (Exp (Rep m))
- Futhark.Construct: eIf :: (MonadBuilder m, BranchType (Rep m) ~ ExtType) => m (Exp (Rep m)) -> m (Body (Rep m)) -> m (Body (Rep m)) -> m (Exp (Rep m))
- Futhark.Construct: eIf' :: (MonadBuilder m, BranchType (Rep m) ~ ExtType) => m (Exp (Rep m)) -> m (Body (Rep m)) -> m (Body (Rep m)) -> MatchSort -> m (Exp (Rep m))
- Futhark.Construct: eIndex :: MonadBuilder m => VName -> [m (Exp (Rep m))] -> m (Exp (Rep m))
- Futhark.Construct: eLambda :: MonadBuilder m => Lambda (Rep m) -> [m (Exp (Rep m))] -> m [SubExpRes]
- Futhark.Construct: eLast :: MonadBuilder m => VName -> m (Exp (Rep m))
- Futhark.Construct: eMatch :: (MonadBuilder m, BranchType (Rep m) ~ ExtType) => [SubExp] -> [Case (m (Body (Rep m)))] -> m (Body (Rep m)) -> m (Exp (Rep m))
- Futhark.Construct: eMatch' :: (MonadBuilder m, BranchType (Rep m) ~ ExtType) => [SubExp] -> [Case (m (Body (Rep m)))] -> m (Body (Rep m)) -> MatchSort -> m (Exp (Rep m))
- Futhark.Construct: eOutOfBounds :: MonadBuilder m => VName -> [m (Exp (Rep m))] -> m (Exp (Rep m))
- Futhark.Construct: eParam :: MonadBuilder m => Param t -> m (Exp (Rep m))
- Futhark.Construct: eSignum :: MonadBuilder m => m (Exp (Rep m)) -> m (Exp (Rep m))
- Futhark.Construct: eSubExp :: MonadBuilder m => SubExp -> m (Exp (Rep m))
- Futhark.Construct: eUnOp :: MonadBuilder m => UnOp -> m (Exp (Rep m)) -> m (Exp (Rep m))
- Futhark.Construct: foldBinOp :: MonadBuilder m => BinOp -> SubExp -> [SubExp] -> m (Exp (Rep m))
- Futhark.Construct: fullSlice :: Type -> [DimIndex SubExp] -> Slice SubExp
- Futhark.Construct: fullSliceNum :: Num d => [d] -> [DimIndex d] -> Slice d
- Futhark.Construct: insertStmsM :: MonadBuilder m => m (Body (Rep m)) -> m (Body (Rep m))
- Futhark.Construct: instance Futhark.Construct.ToExp Futhark.IR.Syntax.Core.SubExp
- Futhark.Construct: instance Futhark.Construct.ToExp Language.Futhark.Core.VName
- Futhark.Construct: instantiateShapes :: Monad m => (Int -> m SubExp) -> [TypeBase ExtShape u] -> m [TypeBase Shape u]
- Futhark.Construct: instantiateShapes' :: [VName] -> [TypeBase ExtShape u] -> [TypeBase Shape u]
- Futhark.Construct: isFullSlice :: Shape -> Slice SubExp -> Bool
- Futhark.Construct: letExp :: MonadBuilder m => String -> Exp (Rep m) -> m VName
- Futhark.Construct: letInPlace :: MonadBuilder m => String -> VName -> Slice SubExp -> Exp (Rep m) -> m VName
- Futhark.Construct: letSubExp :: MonadBuilder m => String -> Exp (Rep m) -> m SubExp
- Futhark.Construct: letTupExp :: MonadBuilder m => String -> Exp (Rep m) -> m [VName]
- Futhark.Construct: letTupExp' :: MonadBuilder m => String -> Exp (Rep m) -> m [SubExp]
- Futhark.Construct: mapResult :: Buildable rep => (Result -> Body rep) -> Body rep -> Body rep
- Futhark.Construct: mkLambda :: MonadBuilder m => [LParam (Rep m)] -> m Result -> m (Lambda (Rep m))
- Futhark.Construct: removeExistentials :: ExtType -> Type -> Type
- Futhark.Construct: resultBody :: Buildable rep => [SubExp] -> Body rep
- Futhark.Construct: resultBodyM :: MonadBuilder m => [SubExp] -> m (Body (Rep m))
- Futhark.Construct: simpleMkLetNames :: (ExpDec rep ~ (), LetDec rep ~ Type, MonadFreshNames m, TypedOp (OpC rep), HasScope rep m) => [VName] -> Exp rep -> m (Stm rep)
- Futhark.Construct: sliceAt :: Type -> Int -> [DimIndex SubExp] -> Slice SubExp
- Futhark.Construct: sliceDim :: SubExp -> DimIndex SubExp
- Futhark.Construct: toExp :: (ToExp a, MonadBuilder m) => a -> m (Exp (Rep m))
- Futhark.Construct: toSubExp :: (MonadBuilder m, ToExp a) => String -> a -> m SubExp
- Futhark.Doc.Generator: renderFiles :: [ImportName] -> Imports -> ([(FilePath, Html)], Warnings)
- Futhark.Error: CompilerBug :: ErrorClass
- Futhark.Error: CompilerLimitation :: ErrorClass
- Futhark.Error: Error :: ErrorClass -> Text -> InternalError
- Futhark.Error: ExternalError :: Doc AnsiStyle -> CompilerError
- Futhark.Error: InternalError :: Text -> Text -> ErrorClass -> CompilerError
- Futhark.Error: compilerBug :: Text -> a
- Futhark.Error: compilerBugS :: String -> a
- Futhark.Error: compilerLimitation :: Text -> a
- Futhark.Error: compilerLimitationS :: String -> a
- Futhark.Error: data CompilerError
- Futhark.Error: data ErrorClass
- Futhark.Error: data InternalError
- Futhark.Error: externalError :: MonadError CompilerError m => Doc AnsiStyle -> m a
- Futhark.Error: externalErrorS :: MonadError CompilerError m => String -> m a
- Futhark.Error: instance GHC.Classes.Eq Futhark.Error.ErrorClass
- Futhark.Error: instance GHC.Classes.Ord Futhark.Error.ErrorClass
- Futhark.Error: instance GHC.Exception.Type.Exception Futhark.Error.InternalError
- Futhark.Error: instance GHC.Show.Show Futhark.Error.ErrorClass
- Futhark.Error: instance GHC.Show.Show Futhark.Error.InternalError
- Futhark.Error: internalErrorS :: MonadError CompilerError m => String -> Doc AnsiStyle -> m a
- Futhark.Error: prettyCompilerError :: CompilerError -> Doc AnsiStyle
- Futhark.Fmt.Monad: (<+>) :: Fmt -> Fmt -> Fmt
- Futhark.Fmt.Monad: (</>) :: Fmt -> Fmt -> Fmt
- Futhark.Fmt.Monad: (<:/>) :: Fmt -> Fmt -> Fmt
- Futhark.Fmt.Monad: (<|>) :: Fmt -> Fmt -> Fmt
- Futhark.Fmt.Monad: addComments :: Located a => a -> Fmt -> Fmt
- Futhark.Fmt.Monad: align :: Fmt -> Fmt
- Futhark.Fmt.Monad: bindingStyle :: AnsiStyle
- Futhark.Fmt.Monad: braces :: Fmt -> Fmt
- Futhark.Fmt.Monad: brackets :: Fmt -> Fmt
- Futhark.Fmt.Monad: comment :: Text -> Fmt
- Futhark.Fmt.Monad: commentStyle :: AnsiStyle
- Futhark.Fmt.Monad: constantStyle :: AnsiStyle
- Futhark.Fmt.Monad: fmtByLayout :: Located a => a -> Fmt -> Fmt -> Fmt
- Futhark.Fmt.Monad: fmtCopyLoc :: Located a => AnsiStyle -> a -> Fmt
- Futhark.Fmt.Monad: hardIndent :: Int -> Fmt -> Fmt
- Futhark.Fmt.Monad: hardStdIndent :: Fmt -> Fmt
- Futhark.Fmt.Monad: hardline :: Fmt
- Futhark.Fmt.Monad: indent :: Int -> Fmt -> Fmt
- Futhark.Fmt.Monad: infixStyle :: AnsiStyle
- Futhark.Fmt.Monad: infixr 4 <|>
- Futhark.Fmt.Monad: infixr 6 <:/>
- Futhark.Fmt.Monad: instance Data.String.IsString Futhark.Fmt.Monad.Fmt
- Futhark.Fmt.Monad: instance GHC.Base.Monoid Futhark.Fmt.Monad.Fmt
- Futhark.Fmt.Monad: instance GHC.Base.Semigroup Futhark.Fmt.Monad.Fmt
- Futhark.Fmt.Monad: instance GHC.Classes.Eq Futhark.Fmt.Monad.FmtState
- Futhark.Fmt.Monad: instance GHC.Classes.Eq Futhark.Fmt.Monad.LastOutput
- Futhark.Fmt.Monad: instance GHC.Classes.Eq Futhark.Fmt.Monad.Layout
- Futhark.Fmt.Monad: instance GHC.Classes.Ord Futhark.Fmt.Monad.FmtState
- Futhark.Fmt.Monad: instance GHC.Classes.Ord Futhark.Fmt.Monad.LastOutput
- Futhark.Fmt.Monad: instance GHC.Show.Show Futhark.Fmt.Monad.FmtState
- Futhark.Fmt.Monad: instance GHC.Show.Show Futhark.Fmt.Monad.LastOutput
- Futhark.Fmt.Monad: instance GHC.Show.Show Futhark.Fmt.Monad.Layout
- Futhark.Fmt.Monad: keywordStyle :: AnsiStyle
- Futhark.Fmt.Monad: line :: Fmt
- Futhark.Fmt.Monad: localLayout :: Located a => a -> FmtM b -> FmtM b
- Futhark.Fmt.Monad: localLayoutList :: Located a => [a] -> FmtM b -> FmtM b
- Futhark.Fmt.Monad: nest :: Int -> Fmt -> Fmt
- Futhark.Fmt.Monad: nil :: Fmt
- Futhark.Fmt.Monad: parens :: Fmt -> Fmt
- Futhark.Fmt.Monad: popComments :: Fmt
- Futhark.Fmt.Monad: runFormat :: FmtM a -> [Comment] -> Text -> a
- Futhark.Fmt.Monad: sep :: Fmt -> [Fmt] -> Fmt
- Futhark.Fmt.Monad: sepArgs :: Located a => (a -> Fmt) -> NonEmpty a -> Fmt
- Futhark.Fmt.Monad: sepComments :: (a -> Loc) -> (a -> Fmt) -> Fmt -> [a] -> Fmt
- Futhark.Fmt.Monad: sepDecs :: Located a => (a -> Fmt) -> [a] -> Fmt
- Futhark.Fmt.Monad: sepLine :: Fmt -> [Fmt] -> Fmt
- Futhark.Fmt.Monad: sepLineComments :: (a -> Loc) -> (a -> Fmt) -> Fmt -> [a] -> Fmt
- Futhark.Fmt.Monad: space :: Fmt
- Futhark.Fmt.Monad: stdIndent :: Fmt -> Fmt
- Futhark.Fmt.Monad: stdNest :: Fmt -> Fmt
- Futhark.Fmt.Monad: text :: AnsiStyle -> Text -> Fmt
- Futhark.Fmt.Monad: type Fmt = FmtM Doc AnsiStyle
- Futhark.Fmt.Monad: type FmtM a = ReaderT Layout State FmtState a
- Futhark.Fmt.Printer: fmtToDoc :: String -> Text -> Either SyntaxError (Doc AnsiStyle)
- Futhark.Fmt.Printer: fmtToText :: String -> Text -> Either SyntaxError Text
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format (GHC.Maybe.Maybe Language.Futhark.Syntax.DocComment)
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format (Language.Futhark.Prop.UncheckedPat t)
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.AppExpBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.FieldBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.LoopFormBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.ModParamBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.SizeBinder Language.Futhark.Core.Name)
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.SizeExp Language.Futhark.Prop.UncheckedExp)
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.TypeArgExp Language.Futhark.Prop.UncheckedExp Language.Futhark.Core.Name)
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Core.Name
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedCase
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedDec
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedDimIndex
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedExp
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedModBind
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedModExp
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedModTypeBind
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedModTypeExp
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedProg
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedSpec
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedTypeBind
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedTypeExp
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedTypeParam
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Prop.UncheckedValBind
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Syntax.DocComment
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Syntax.Liftedness
- Futhark.Fmt.Printer: instance Futhark.Fmt.Printer.Format Language.Futhark.Syntax.PrimValue
- Futhark.Fmt.Printer: instance forall k (a :: k). Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.AttrAtom a)
- Futhark.Fmt.Printer: instance forall k (a :: k). Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.AttrInfo a)
- Futhark.Fmt.Printer: instance forall k (t :: k). Futhark.Fmt.Printer.Format (Language.Futhark.Syntax.IdentBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name t)
- Futhark.Format: parseFormatString :: Text -> Either Text [Either Text Text]
- Futhark.FreshNames: blankNameSource :: VNameSource
- Futhark.FreshNames: data VNameSource
- Futhark.FreshNames: instance GHC.Base.Monoid Futhark.FreshNames.VNameSource
- Futhark.FreshNames: instance GHC.Base.Semigroup Futhark.FreshNames.VNameSource
- Futhark.FreshNames: instance GHC.Classes.Eq Futhark.FreshNames.VNameSource
- Futhark.FreshNames: instance GHC.Classes.Ord Futhark.FreshNames.VNameSource
- Futhark.FreshNames: instance Language.Haskell.TH.Syntax.Lift Futhark.FreshNames.VNameSource
- Futhark.FreshNames: newName :: VNameSource -> VName -> (VName, VNameSource)
- Futhark.FreshNames: newNameSource :: Int -> VNameSource
- Futhark.IR.Aliases: AliasDec :: Names -> AliasDec
- Futhark.IR.Aliases: [unAliases] :: AliasDec -> Names
- Futhark.IR.Aliases: addOpAliases :: (CanBeAliased op, AliasableRep rep) => AliasTable -> op rep -> op (Aliases rep)
- Futhark.IR.Aliases: class CanBeAliased (op :: Type -> Type)
- Futhark.IR.Aliases: consumedInStms :: Aliased rep => Stms rep -> Names
- Futhark.IR.Aliases: data Aliases rep
- Futhark.IR.Aliases: instance (Futhark.Builder.Class.Buildable rep, Futhark.IR.Prop.Aliases.AliasedOp (Futhark.IR.Rep.OpC rep), Futhark.IR.Prop.ASTConstraints (Futhark.IR.Rep.OpC rep (Futhark.IR.Aliases.Aliases rep))) => Futhark.Builder.Class.Buildable (Futhark.IR.Aliases.Aliases rep)
- Futhark.IR.Aliases: instance (Futhark.IR.Prop.ASTRep rep, Futhark.IR.Prop.Aliases.AliasedOp (Futhark.IR.Rep.OpC rep), Futhark.Builder.Class.Buildable (Futhark.IR.Aliases.Aliases rep)) => Futhark.Builder.BuilderOps (Futhark.IR.Aliases.Aliases rep)
- Futhark.IR.Aliases: instance (Futhark.IR.Prop.ASTRep rep, Futhark.IR.Prop.Aliases.AliasedOp (Futhark.IR.Rep.OpC rep), Futhark.IR.Prop.ASTConstraints (Futhark.IR.Rep.OpC rep (Futhark.IR.Aliases.Aliases rep))) => Futhark.IR.Pretty.PrettyRep (Futhark.IR.Aliases.Aliases rep)
- Futhark.IR.Aliases: instance (Futhark.IR.Prop.ASTRep rep, Futhark.IR.Prop.Aliases.AliasedOp (Futhark.IR.Rep.OpC rep), Futhark.IR.Prop.ASTConstraints (Futhark.IR.Rep.OpC rep (Futhark.IR.Aliases.Aliases rep))) => Futhark.IR.Prop.ASTRep (Futhark.IR.Aliases.Aliases rep)
- Futhark.IR.Aliases: instance (Futhark.IR.Prop.ASTRep rep, Futhark.IR.Prop.Aliases.AliasedOp (Futhark.IR.Rep.OpC rep), Futhark.IR.Prop.ASTConstraints (Futhark.IR.Rep.OpC rep (Futhark.IR.Aliases.Aliases rep))) => Futhark.IR.Prop.Aliases.Aliased (Futhark.IR.Aliases.Aliases rep)
- Futhark.IR.Aliases: instance (Futhark.IR.Rep.RepTypes rep, Futhark.IR.Prop.ASTConstraints (Futhark.IR.Rep.OpC rep (Futhark.IR.Aliases.Aliases rep))) => Futhark.IR.Rep.RepTypes (Futhark.IR.Aliases.Aliases rep)
- Futhark.IR.Aliases: instance Futhark.IR.Aliases.CanBeAliased Futhark.IR.Rep.NoOp
- Futhark.IR.Aliases: instance Futhark.IR.Prop.Aliases.AliasesOf (Futhark.IR.Aliases.VarAliases, dec)
- Futhark.IR.Aliases: instance Futhark.IR.Prop.Names.FreeDec Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: instance Futhark.Transform.Rename.Rename Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: instance GHC.Base.Monoid Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: instance GHC.Base.Semigroup Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: instance GHC.Classes.Eq Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: instance GHC.Classes.Ord Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: instance GHC.Show.Show Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: instance Prettyprinter.Internal.Pretty Futhark.IR.Aliases.AliasDec
- Futhark.IR.Aliases: mkAliasedBody :: (ASTRep rep, AliasedOp (OpC rep), ASTConstraints (OpC rep (Aliases rep))) => BodyDec rep -> Stms (Aliases rep) -> Result -> Body (Aliases rep)
- Futhark.IR.Aliases: mkAliasedPat :: (Aliased rep, Typed dec) => Pat dec -> Exp rep -> Pat (VarAliases, dec)
- Futhark.IR.Aliases: mkBodyAliasing :: Aliased rep => Stms rep -> Result -> BodyAliasing
- Futhark.IR.Aliases: mkStmsAliases :: Aliased rep => Stms rep -> Result -> ([Names], Names)
- Futhark.IR.Aliases: newtype AliasDec
- Futhark.IR.Aliases: removeBodyAliases :: RephraseOp (OpC rep) => Body (Aliases rep) -> Body rep
- Futhark.IR.Aliases: removeExpAliases :: RephraseOp (OpC rep) => Exp (Aliases rep) -> Exp rep
- Futhark.IR.Aliases: removeFunDefAliases :: RephraseOp (OpC rep) => FunDef (Aliases rep) -> FunDef rep
- Futhark.IR.Aliases: removeLambdaAliases :: RephraseOp (OpC rep) => Lambda (Aliases rep) -> Lambda rep
- Futhark.IR.Aliases: removePatAliases :: Pat (AliasDec, a) -> Pat a
- Futhark.IR.Aliases: removeProgAliases :: RephraseOp (OpC rep) => Prog (Aliases rep) -> Prog rep
- Futhark.IR.Aliases: removeScopeAliases :: Scope (Aliases rep) -> Scope rep
- Futhark.IR.Aliases: removeStmAliases :: RephraseOp (OpC rep) => Stm (Aliases rep) -> Stm rep
- Futhark.IR.Aliases: trackAliases :: Aliased rep => AliasesAndConsumed -> Stm rep -> AliasesAndConsumed
- Futhark.IR.Aliases: type AliasableRep rep = (ASTRep rep, RephraseOp OpC rep, CanBeAliased OpC rep, AliasedOp OpC rep, ASTConstraints OpC rep Aliases rep)
- Futhark.IR.Aliases: type AliasesAndConsumed = (Map VName Names, Names)
- Futhark.IR.Aliases: type BodyAliasing = ([VarAliases], ConsumedInExp)
- Futhark.IR.Aliases: type ConsumedInExp = AliasDec
- Futhark.IR.Aliases: type VarAliases = AliasDec
- Futhark.IR.GPU: Hist :: SubExp -> [VName] -> [HistOp rep] -> Lambda rep -> SOAC rep
- Futhark.IR.GPU: JVP :: [SubExp] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.IR.GPU: Reduce :: Commutativity -> Lambda rep -> [SubExp] -> Reduce rep
- Futhark.IR.GPU: SOACMapper :: (SubExp -> m SubExp) -> (Lambda frep -> m (Lambda trep)) -> (VName -> m VName) -> SOACMapper frep trep (m :: Type -> Type)
- Futhark.IR.GPU: Scan :: Lambda rep -> [SubExp] -> Scan rep
- Futhark.IR.GPU: Scatter :: SubExp -> [VName] -> ScatterSpec VName -> Lambda rep -> SOAC rep
- Futhark.IR.GPU: Screma :: SubExp -> [VName] -> ScremaForm rep -> SOAC rep
- Futhark.IR.GPU: ScremaForm :: Lambda rep -> [Scan rep] -> [Reduce rep] -> ScremaForm rep
- Futhark.IR.GPU: Stream :: SubExp -> [VName] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.IR.GPU: VJP :: [SubExp] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.IR.GPU: [mapOnSOACLambda] :: SOACMapper frep trep (m :: Type -> Type) -> Lambda frep -> m (Lambda trep)
- Futhark.IR.GPU: [mapOnSOACSubExp] :: SOACMapper frep trep (m :: Type -> Type) -> SubExp -> m SubExp
- Futhark.IR.GPU: [mapOnSOACVName] :: SOACMapper frep trep (m :: Type -> Type) -> VName -> m VName
- Futhark.IR.GPU: [redComm] :: Reduce rep -> Commutativity
- Futhark.IR.GPU: [redLambda] :: Reduce rep -> Lambda rep
- Futhark.IR.GPU: [redNeutral] :: Reduce rep -> [SubExp]
- Futhark.IR.GPU: [scanLambda] :: Scan rep -> Lambda rep
- Futhark.IR.GPU: [scanNeutral] :: Scan rep -> [SubExp]
- Futhark.IR.GPU: [scremaLambda] :: ScremaForm rep -> Lambda rep
- Futhark.IR.GPU: [scremaReduces] :: ScremaForm rep -> [Reduce rep]
- Futhark.IR.GPU: [scremaScans] :: ScremaForm rep -> [Scan rep]
- Futhark.IR.GPU: data GPU
- Futhark.IR.GPU: data Reduce rep
- Futhark.IR.GPU: data SOAC rep
- Futhark.IR.GPU: data SOACMapper frep trep (m :: Type -> Type)
- Futhark.IR.GPU: data Scan rep
- Futhark.IR.GPU: data ScremaForm rep
- Futhark.IR.GPU: groupScatterResults :: ScatterSpec array -> [a] -> [(Shape, array, [([a], a)])]
- Futhark.IR.GPU: groupScatterResults' :: [(Shape, Int, array)] -> [a] -> [([a], a)]
- Futhark.IR.GPU: identitySOACMapper :: forall rep (m :: Type -> Type). Monad m => SOACMapper rep rep m
- Futhark.IR.GPU: instance Futhark.Builder.BuilderOps Futhark.IR.GPU.GPU
- Futhark.IR.GPU: instance Futhark.Builder.Class.Buildable Futhark.IR.GPU.GPU
- Futhark.IR.GPU: instance Futhark.IR.Pretty.PrettyRep Futhark.IR.GPU.GPU
- Futhark.IR.GPU: instance Futhark.IR.Prop.ASTRep Futhark.IR.GPU.GPU
- Futhark.IR.GPU: instance Futhark.IR.Rep.RepTypes Futhark.IR.GPU.GPU
- Futhark.IR.GPU: instance Futhark.IR.SegOp.HasSegOp Futhark.IR.GPU.GPU
- Futhark.IR.GPU: instance Futhark.IR.TypeCheck.Checkable Futhark.IR.GPU.GPU
- Futhark.IR.GPU: isIdentityLambda :: Lambda rep -> Bool
- Futhark.IR.GPU: isMapSOAC :: ScremaForm rep -> Maybe (Lambda rep)
- Futhark.IR.GPU: isRedomapSOAC :: ScremaForm rep -> Maybe ([Reduce rep], Lambda rep)
- Futhark.IR.GPU: isReduceSOAC :: ScremaForm rep -> Maybe [Reduce rep]
- Futhark.IR.GPU: isScanSOAC :: ScremaForm rep -> Maybe [Scan rep]
- Futhark.IR.GPU: isScanomapSOAC :: ScremaForm rep -> Maybe ([Scan rep], Lambda rep)
- Futhark.IR.GPU: mapSOAC :: Lambda rep -> ScremaForm rep
- Futhark.IR.GPU: mapSOACM :: Monad m => SOACMapper frep trep m -> SOAC frep -> m (SOAC trep)
- Futhark.IR.GPU: mkIdentityLambda :: (Buildable rep, MonadFreshNames m) => [Type] -> m (Lambda rep)
- Futhark.IR.GPU: nilFn :: Buildable rep => Lambda rep
- Futhark.IR.GPU: ppHist :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> [HistOp rep] -> Lambda rep -> Doc ann
- Futhark.IR.GPU: ppScatter :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> [(Shape, Int, VName)] -> Lambda rep -> Doc ann
- Futhark.IR.GPU: ppScrema :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> ScremaForm rep -> Doc ann
- Futhark.IR.GPU: ppStream :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> [SubExp] -> Lambda rep -> Doc ann
- Futhark.IR.GPU: redResults :: [Reduce rep] -> Int
- Futhark.IR.GPU: redomapSOAC :: [Reduce rep] -> Lambda rep -> ScremaForm rep
- Futhark.IR.GPU: reduceSOAC :: (Buildable rep, MonadFreshNames m) => [Reduce rep] -> m (ScremaForm rep)
- Futhark.IR.GPU: scanResults :: [Scan rep] -> Int
- Futhark.IR.GPU: scanSOAC :: (Buildable rep, MonadFreshNames m) => [Scan rep] -> m (ScremaForm rep)
- Futhark.IR.GPU: scanomapSOAC :: [Scan rep] -> Lambda rep -> ScremaForm rep
- Futhark.IR.GPU: scremaType :: SubExp -> ScremaForm rep -> [Type]
- Futhark.IR.GPU: singleReduce :: Buildable rep => [Reduce rep] -> Reduce rep
- Futhark.IR.GPU: singleScan :: Buildable rep => [Scan rep] -> Scan rep
- Futhark.IR.GPU: soacType :: Typed (LParamInfo rep) => SOAC rep -> [Type]
- Futhark.IR.GPU: splitScatterResults :: [(Shape, Int, array)] -> [a] -> ([a], [a])
- Futhark.IR.GPU: traverseSOACStms :: Monad m => OpStmsTraverser m (SOAC rep) rep
- Futhark.IR.GPU: type ScatterSpec v = [(Shape, Int, v)]
- Futhark.IR.GPU: typeCheckSOAC :: Checkable rep => SOAC (Aliases rep) -> TypeM rep ()
- Futhark.IR.GPU.Op: CalcNumBlocks :: SubExp -> Name -> SubExp -> SizeOp
- Futhark.IR.GPU.Op: CmpSizeLe :: Name -> SizeClass -> SubExp -> SizeOp
- Futhark.IR.GPU.Op: GPUBody :: [Type] -> Body rep -> HostOp (op :: Type -> Type) rep
- Futhark.IR.GPU.Op: GetSize :: Name -> SizeClass -> SizeOp
- Futhark.IR.GPU.Op: GetSizeMax :: SizeClass -> SizeOp
- Futhark.IR.GPU.Op: KernelGrid :: Count NumBlocks SubExp -> Count BlockSize SubExp -> KernelGrid
- Futhark.IR.GPU.Op: OtherOp :: op rep -> HostOp (op :: Type -> Type) rep
- Futhark.IR.GPU.Op: SegBlock :: SegVirt -> Maybe KernelGrid -> SegLevel
- Futhark.IR.GPU.Op: SegNoVirt :: SegVirt
- Futhark.IR.GPU.Op: SegNoVirtFull :: SegSeqDims -> SegVirt
- Futhark.IR.GPU.Op: SegOp :: SegOp SegLevel rep -> HostOp (op :: Type -> Type) rep
- Futhark.IR.GPU.Op: SegSeqDims :: [Int] -> SegSeqDims
- Futhark.IR.GPU.Op: SegThread :: SegVirt -> Maybe KernelGrid -> SegLevel
- Futhark.IR.GPU.Op: SegThreadInBlock :: SegVirt -> SegLevel
- Futhark.IR.GPU.Op: SegVirt :: SegVirt
- Futhark.IR.GPU.Op: SizeOp :: SizeOp -> HostOp (op :: Type -> Type) rep
- Futhark.IR.GPU.Op: [gridBlockSize] :: KernelGrid -> Count BlockSize SubExp
- Futhark.IR.GPU.Op: [gridNumBlocks] :: KernelGrid -> Count NumBlocks SubExp
- Futhark.IR.GPU.Op: [segSeqDims] :: SegSeqDims -> [Int]
- Futhark.IR.GPU.Op: data HostOp (op :: Type -> Type) rep
- Futhark.IR.GPU.Op: data KernelGrid
- Futhark.IR.GPU.Op: data SegLevel
- Futhark.IR.GPU.Op: data SegVirt
- Futhark.IR.GPU.Op: data SizeOp
- Futhark.IR.GPU.Op: instance (Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.Rep.Op rep), Futhark.Analysis.Metrics.OpMetrics (op rep)) => Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.IR.GPU.Op: instance (Futhark.IR.Pretty.PrettyRep rep, Prettyprinter.Internal.Pretty (op rep)) => Prettyprinter.Internal.Pretty (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.IR.GPU.Op: instance (Futhark.IR.Prop.ASTRep rep, Futhark.Analysis.SymbolTable.IndexOp (op rep)) => Futhark.Analysis.SymbolTable.IndexOp (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.IR.GPU.Op: instance (Futhark.IR.Prop.ASTRep rep, Futhark.IR.Prop.Names.FreeIn (op rep)) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.IR.GPU.Op: instance (Futhark.IR.Prop.ASTRep rep, Futhark.Transform.Rename.Rename (op rep)) => Futhark.Transform.Rename.Rename (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.IR.GPU.Op: instance (Futhark.IR.Prop.ASTRep rep, Futhark.Transform.Substitute.Substitute (op rep)) => Futhark.Transform.Substitute.Substitute (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.IR.GPU.Op: instance (Futhark.IR.Rep.RepTypes rep, GHC.Classes.Eq (op rep)) => GHC.Classes.Eq (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.IR.GPU.Op: instance (Futhark.IR.Rep.RepTypes rep, GHC.Classes.Ord (op rep)) => GHC.Classes.Ord (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.IR.GPU.Op: instance (Futhark.IR.Rep.RepTypes rep, GHC.Show.Show (op rep)) => GHC.Show.Show (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.IR.GPU.Op: instance Futhark.Analysis.Metrics.OpMetrics Futhark.IR.GPU.Op.SizeOp
- Futhark.IR.GPU.Op: instance Futhark.IR.Aliases.CanBeAliased op => Futhark.IR.Aliases.CanBeAliased (Futhark.IR.GPU.Op.HostOp op)
- Futhark.IR.GPU.Op: instance Futhark.IR.Mem.OpReturns (Futhark.IR.GPU.Op.HostOp Futhark.IR.Rep.NoOp)
- Futhark.IR.GPU.Op: instance Futhark.IR.Prop.Aliases.AliasedOp op => Futhark.IR.Prop.Aliases.AliasedOp (Futhark.IR.GPU.Op.HostOp op)
- Futhark.IR.GPU.Op: instance Futhark.IR.Prop.IsOp op => Futhark.IR.Prop.IsOp (Futhark.IR.GPU.Op.HostOp op)
- Futhark.IR.GPU.Op: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.GPU.Op.KernelGrid
- Futhark.IR.GPU.Op: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.GPU.Op.SegLevel
- Futhark.IR.GPU.Op: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.GPU.Op.SizeOp
- Futhark.IR.GPU.Op: instance Futhark.IR.Prop.TypeOf.TypedOp op => Futhark.IR.Prop.TypeOf.TypedOp (Futhark.IR.GPU.Op.HostOp op)
- Futhark.IR.GPU.Op: instance Futhark.IR.Rephrase.RephraseOp op => Futhark.IR.Rephrase.RephraseOp (Futhark.IR.GPU.Op.HostOp op)
- Futhark.IR.GPU.Op: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.GPU.Op.KernelGrid
- Futhark.IR.GPU.Op: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.GPU.Op.SegLevel
- Futhark.IR.GPU.Op: instance Futhark.Optimise.Simplify.Rep.CanBeWise op => Futhark.Optimise.Simplify.Rep.CanBeWise (Futhark.IR.GPU.Op.HostOp op)
- Futhark.IR.GPU.Op: instance Futhark.Transform.Rename.Rename Futhark.IR.GPU.Op.SegLevel
- Futhark.IR.GPU.Op: instance Futhark.Transform.Rename.Rename Futhark.IR.GPU.Op.SizeOp
- Futhark.IR.GPU.Op: instance Futhark.Transform.Substitute.Substitute Futhark.IR.GPU.Op.KernelGrid
- Futhark.IR.GPU.Op: instance Futhark.Transform.Substitute.Substitute Futhark.IR.GPU.Op.SegLevel
- Futhark.IR.GPU.Op: instance Futhark.Transform.Substitute.Substitute Futhark.IR.GPU.Op.SizeOp
- Futhark.IR.GPU.Op: instance GHC.Classes.Eq Futhark.IR.GPU.Op.KernelGrid
- Futhark.IR.GPU.Op: instance GHC.Classes.Eq Futhark.IR.GPU.Op.SegLevel
- Futhark.IR.GPU.Op: instance GHC.Classes.Eq Futhark.IR.GPU.Op.SegSeqDims
- Futhark.IR.GPU.Op: instance GHC.Classes.Eq Futhark.IR.GPU.Op.SegVirt
- Futhark.IR.GPU.Op: instance GHC.Classes.Eq Futhark.IR.GPU.Op.SizeOp
- Futhark.IR.GPU.Op: instance GHC.Classes.Ord Futhark.IR.GPU.Op.KernelGrid
- Futhark.IR.GPU.Op: instance GHC.Classes.Ord Futhark.IR.GPU.Op.SegLevel
- Futhark.IR.GPU.Op: instance GHC.Classes.Ord Futhark.IR.GPU.Op.SegSeqDims
- Futhark.IR.GPU.Op: instance GHC.Classes.Ord Futhark.IR.GPU.Op.SegVirt
- Futhark.IR.GPU.Op: instance GHC.Classes.Ord Futhark.IR.GPU.Op.SizeOp
- Futhark.IR.GPU.Op: instance GHC.Show.Show Futhark.IR.GPU.Op.KernelGrid
- Futhark.IR.GPU.Op: instance GHC.Show.Show Futhark.IR.GPU.Op.SegLevel
- Futhark.IR.GPU.Op: instance GHC.Show.Show Futhark.IR.GPU.Op.SegSeqDims
- Futhark.IR.GPU.Op: instance GHC.Show.Show Futhark.IR.GPU.Op.SegVirt
- Futhark.IR.GPU.Op: instance GHC.Show.Show Futhark.IR.GPU.Op.SizeOp
- Futhark.IR.GPU.Op: instance Prettyprinter.Internal.Pretty Futhark.IR.GPU.Op.KernelGrid
- Futhark.IR.GPU.Op: instance Prettyprinter.Internal.Pretty Futhark.IR.GPU.Op.SegLevel
- Futhark.IR.GPU.Op: instance Prettyprinter.Internal.Pretty Futhark.IR.GPU.Op.SegVirt
- Futhark.IR.GPU.Op: instance Prettyprinter.Internal.Pretty Futhark.IR.GPU.Op.SizeOp
- Futhark.IR.GPU.Op: newtype SegSeqDims
- Futhark.IR.GPU.Op: segVirt :: SegLevel -> SegVirt
- Futhark.IR.GPU.Op: traverseHostOpStms :: Monad m => OpStmsTraverser m (op rep) rep -> OpStmsTraverser m (HostOp op rep) rep
- Futhark.IR.GPU.Op: typeCheckHostOp :: Checkable rep => (SegLevel -> Op (Aliases rep) -> TypeM rep ()) -> Maybe SegLevel -> (op (Aliases rep) -> TypeM rep ()) -> HostOp op (Aliases rep) -> TypeM rep ()
- Futhark.IR.GPU.Simplify: data GPU
- Futhark.IR.GPU.Simplify: instance Futhark.Builder.BuilderOps (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.GPU.GPU)
- Futhark.IR.GPU.Simplify: instance Futhark.IR.SOACS.Simplify.HasSOAC (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.GPU.GPU)
- Futhark.IR.GPU.Simplify: instance Futhark.IR.SegOp.HasSegOp (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.GPU.GPU)
- Futhark.IR.GPU.Simplify: instance Futhark.IR.Traversals.TraverseOpStms (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.GPU.GPU)
- Futhark.IR.GPU.Simplify: simplifyGPU :: Prog GPU -> PassM (Prog GPU)
- Futhark.IR.GPU.Simplify: simplifyKernelOp :: (SimplifiableRep rep, BodyDec rep ~ ()) => SimplifyOp rep (op (Wise rep)) -> HostOp op (Wise rep) -> SimpleM rep (HostOp op (Wise rep), Stms (Wise rep))
- Futhark.IR.GPU.Simplify: simplifyLambda :: (HasScope GPU m, MonadFreshNames m) => Lambda GPU -> m (Lambda GPU)
- Futhark.IR.GPU.Sizes: Count :: e -> Count (u :: k) e
- Futhark.IR.GPU.Sizes: SizeBespoke :: Name -> Int64 -> SizeClass
- Futhark.IR.GPU.Sizes: SizeCache :: SizeClass
- Futhark.IR.GPU.Sizes: SizeGrid :: SizeClass
- Futhark.IR.GPU.Sizes: SizeRegTile :: SizeClass
- Futhark.IR.GPU.Sizes: SizeRegisters :: SizeClass
- Futhark.IR.GPU.Sizes: SizeSharedMemory :: SizeClass
- Futhark.IR.GPU.Sizes: SizeThreadBlock :: SizeClass
- Futhark.IR.GPU.Sizes: SizeThreshold :: KernelPath -> Maybe Int64 -> SizeClass
- Futhark.IR.GPU.Sizes: SizeTile :: SizeClass
- Futhark.IR.GPU.Sizes: [unCount] :: Count (u :: k) e -> e
- Futhark.IR.GPU.Sizes: data BlockSize
- Futhark.IR.GPU.Sizes: data NumBlocks
- Futhark.IR.GPU.Sizes: data NumThreads
- Futhark.IR.GPU.Sizes: data SizeClass
- Futhark.IR.GPU.Sizes: instance GHC.Classes.Eq Futhark.IR.GPU.Sizes.SizeClass
- Futhark.IR.GPU.Sizes: instance GHC.Classes.Ord Futhark.IR.GPU.Sizes.SizeClass
- Futhark.IR.GPU.Sizes: instance GHC.Show.Show Futhark.IR.GPU.Sizes.SizeClass
- Futhark.IR.GPU.Sizes: instance Prettyprinter.Internal.Pretty Futhark.IR.GPU.Sizes.SizeClass
- Futhark.IR.GPU.Sizes: instance forall k (u :: k) e. Futhark.IR.Prop.Names.FreeIn e => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.GPU.Sizes.Count u e)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k) e. Futhark.Transform.Substitute.Substitute e => Futhark.Transform.Substitute.Substitute (Futhark.IR.GPU.Sizes.Count u e)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k) e. Futhark.Util.IntegralExp.IntegralExp e => Futhark.Util.IntegralExp.IntegralExp (Futhark.IR.GPU.Sizes.Count u e)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k) e. GHC.Classes.Eq e => GHC.Classes.Eq (Futhark.IR.GPU.Sizes.Count u e)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k) e. GHC.Classes.Ord e => GHC.Classes.Ord (Futhark.IR.GPU.Sizes.Count u e)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k) e. GHC.Num.Num e => GHC.Num.Num (Futhark.IR.GPU.Sizes.Count u e)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k) e. GHC.Show.Show e => GHC.Show.Show (Futhark.IR.GPU.Sizes.Count u e)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k) e. Prettyprinter.Internal.Pretty e => Prettyprinter.Internal.Pretty (Futhark.IR.GPU.Sizes.Count u e)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k). Data.Foldable.Foldable (Futhark.IR.GPU.Sizes.Count u)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k). Data.Traversable.Traversable (Futhark.IR.GPU.Sizes.Count u)
- Futhark.IR.GPU.Sizes: instance forall k (u :: k). GHC.Base.Functor (Futhark.IR.GPU.Sizes.Count u)
- Futhark.IR.GPU.Sizes: newtype Count (u :: k) e
- Futhark.IR.GPU.Sizes: sizeDefault :: SizeClass -> Maybe Int64
- Futhark.IR.GPU.Sizes: type KernelPath = [(Name, Bool)]
- Futhark.IR.GPUMem: data GPUMem
- Futhark.IR.GPUMem: instance Futhark.Builder.BuilderOps (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.GPUMem.GPUMem)
- Futhark.IR.GPUMem: instance Futhark.Builder.BuilderOps Futhark.IR.GPUMem.GPUMem
- Futhark.IR.GPUMem: instance Futhark.IR.Pretty.PrettyRep Futhark.IR.GPUMem.GPUMem
- Futhark.IR.GPUMem: instance Futhark.IR.Prop.ASTRep Futhark.IR.GPUMem.GPUMem
- Futhark.IR.GPUMem: instance Futhark.IR.Rep.RepTypes Futhark.IR.GPUMem.GPUMem
- Futhark.IR.GPUMem: instance Futhark.IR.Traversals.TraverseOpStms (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.GPUMem.GPUMem)
- Futhark.IR.GPUMem: instance Futhark.IR.TypeCheck.Checkable Futhark.IR.GPUMem.GPUMem
- Futhark.IR.GPUMem: simpleGPUMem :: SimpleOps GPUMem
- Futhark.IR.GPUMem: simplifyProg :: Prog GPUMem -> PassM (Prog GPUMem)
- Futhark.IR.GPUMem: simplifyStms :: (HasScope GPUMem m, MonadFreshNames m) => Stms GPUMem -> m (Stms GPUMem)
- Futhark.IR.MC: Hist :: SubExp -> [VName] -> [HistOp rep] -> Lambda rep -> SOAC rep
- Futhark.IR.MC: JVP :: [SubExp] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.IR.MC: Reduce :: Commutativity -> Lambda rep -> [SubExp] -> Reduce rep
- Futhark.IR.MC: SOACMapper :: (SubExp -> m SubExp) -> (Lambda frep -> m (Lambda trep)) -> (VName -> m VName) -> SOACMapper frep trep (m :: Type -> Type)
- Futhark.IR.MC: Scan :: Lambda rep -> [SubExp] -> Scan rep
- Futhark.IR.MC: Scatter :: SubExp -> [VName] -> ScatterSpec VName -> Lambda rep -> SOAC rep
- Futhark.IR.MC: Screma :: SubExp -> [VName] -> ScremaForm rep -> SOAC rep
- Futhark.IR.MC: ScremaForm :: Lambda rep -> [Scan rep] -> [Reduce rep] -> ScremaForm rep
- Futhark.IR.MC: Stream :: SubExp -> [VName] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.IR.MC: VJP :: [SubExp] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.IR.MC: [mapOnSOACLambda] :: SOACMapper frep trep (m :: Type -> Type) -> Lambda frep -> m (Lambda trep)
- Futhark.IR.MC: [mapOnSOACSubExp] :: SOACMapper frep trep (m :: Type -> Type) -> SubExp -> m SubExp
- Futhark.IR.MC: [mapOnSOACVName] :: SOACMapper frep trep (m :: Type -> Type) -> VName -> m VName
- Futhark.IR.MC: [redComm] :: Reduce rep -> Commutativity
- Futhark.IR.MC: [redLambda] :: Reduce rep -> Lambda rep
- Futhark.IR.MC: [redNeutral] :: Reduce rep -> [SubExp]
- Futhark.IR.MC: [scanLambda] :: Scan rep -> Lambda rep
- Futhark.IR.MC: [scanNeutral] :: Scan rep -> [SubExp]
- Futhark.IR.MC: [scremaLambda] :: ScremaForm rep -> Lambda rep
- Futhark.IR.MC: [scremaReduces] :: ScremaForm rep -> [Reduce rep]
- Futhark.IR.MC: [scremaScans] :: ScremaForm rep -> [Scan rep]
- Futhark.IR.MC: data MC
- Futhark.IR.MC: data Reduce rep
- Futhark.IR.MC: data SOAC rep
- Futhark.IR.MC: data SOACMapper frep trep (m :: Type -> Type)
- Futhark.IR.MC: data Scan rep
- Futhark.IR.MC: data ScremaForm rep
- Futhark.IR.MC: groupScatterResults :: ScatterSpec array -> [a] -> [(Shape, array, [([a], a)])]
- Futhark.IR.MC: groupScatterResults' :: [(Shape, Int, array)] -> [a] -> [([a], a)]
- Futhark.IR.MC: identitySOACMapper :: forall rep (m :: Type -> Type). Monad m => SOACMapper rep rep m
- Futhark.IR.MC: instance Futhark.Builder.BuilderOps (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.MC.MC)
- Futhark.IR.MC: instance Futhark.Builder.BuilderOps Futhark.IR.MC.MC
- Futhark.IR.MC: instance Futhark.Builder.Class.Buildable Futhark.IR.MC.MC
- Futhark.IR.MC: instance Futhark.IR.Pretty.PrettyRep Futhark.IR.MC.MC
- Futhark.IR.MC: instance Futhark.IR.Prop.ASTRep Futhark.IR.MC.MC
- Futhark.IR.MC: instance Futhark.IR.Rep.RepTypes Futhark.IR.MC.MC
- Futhark.IR.MC: instance Futhark.IR.SegOp.HasSegOp (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.MC.MC)
- Futhark.IR.MC: instance Futhark.IR.SegOp.HasSegOp Futhark.IR.MC.MC
- Futhark.IR.MC: instance Futhark.IR.Traversals.TraverseOpStms (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.MC.MC)
- Futhark.IR.MC: instance Futhark.IR.TypeCheck.Checkable Futhark.IR.MC.MC
- Futhark.IR.MC: isIdentityLambda :: Lambda rep -> Bool
- Futhark.IR.MC: isMapSOAC :: ScremaForm rep -> Maybe (Lambda rep)
- Futhark.IR.MC: isRedomapSOAC :: ScremaForm rep -> Maybe ([Reduce rep], Lambda rep)
- Futhark.IR.MC: isReduceSOAC :: ScremaForm rep -> Maybe [Reduce rep]
- Futhark.IR.MC: isScanSOAC :: ScremaForm rep -> Maybe [Scan rep]
- Futhark.IR.MC: isScanomapSOAC :: ScremaForm rep -> Maybe ([Scan rep], Lambda rep)
- Futhark.IR.MC: mapSOAC :: Lambda rep -> ScremaForm rep
- Futhark.IR.MC: mapSOACM :: Monad m => SOACMapper frep trep m -> SOAC frep -> m (SOAC trep)
- Futhark.IR.MC: mkIdentityLambda :: (Buildable rep, MonadFreshNames m) => [Type] -> m (Lambda rep)
- Futhark.IR.MC: nilFn :: Buildable rep => Lambda rep
- Futhark.IR.MC: ppHist :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> [HistOp rep] -> Lambda rep -> Doc ann
- Futhark.IR.MC: ppScatter :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> [(Shape, Int, VName)] -> Lambda rep -> Doc ann
- Futhark.IR.MC: ppScrema :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> ScremaForm rep -> Doc ann
- Futhark.IR.MC: ppStream :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> [SubExp] -> Lambda rep -> Doc ann
- Futhark.IR.MC: redResults :: [Reduce rep] -> Int
- Futhark.IR.MC: redomapSOAC :: [Reduce rep] -> Lambda rep -> ScremaForm rep
- Futhark.IR.MC: reduceSOAC :: (Buildable rep, MonadFreshNames m) => [Reduce rep] -> m (ScremaForm rep)
- Futhark.IR.MC: scanResults :: [Scan rep] -> Int
- Futhark.IR.MC: scanSOAC :: (Buildable rep, MonadFreshNames m) => [Scan rep] -> m (ScremaForm rep)
- Futhark.IR.MC: scanomapSOAC :: [Scan rep] -> Lambda rep -> ScremaForm rep
- Futhark.IR.MC: scremaType :: SubExp -> ScremaForm rep -> [Type]
- Futhark.IR.MC: simplifyProg :: Prog MC -> PassM (Prog MC)
- Futhark.IR.MC: singleReduce :: Buildable rep => [Reduce rep] -> Reduce rep
- Futhark.IR.MC: singleScan :: Buildable rep => [Scan rep] -> Scan rep
- Futhark.IR.MC: soacType :: Typed (LParamInfo rep) => SOAC rep -> [Type]
- Futhark.IR.MC: splitScatterResults :: [(Shape, Int, array)] -> [a] -> ([a], [a])
- Futhark.IR.MC: traverseSOACStms :: Monad m => OpStmsTraverser m (SOAC rep) rep
- Futhark.IR.MC: type ScatterSpec v = [(Shape, Int, v)]
- Futhark.IR.MC: typeCheckSOAC :: Checkable rep => SOAC (Aliases rep) -> TypeM rep ()
- Futhark.IR.MC.Op: OtherOp :: op rep -> MCOp (op :: Type -> Type) rep
- Futhark.IR.MC.Op: ParOp :: Maybe (SegOp () rep) -> SegOp () rep -> MCOp (op :: Type -> Type) rep
- Futhark.IR.MC.Op: data MCOp (op :: Type -> Type) rep
- Futhark.IR.MC.Op: instance (Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.Rep.Op rep), Futhark.Analysis.Metrics.OpMetrics (op rep)) => Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.IR.MC.Op: instance (Futhark.IR.Pretty.PrettyRep rep, Prettyprinter.Internal.Pretty (op rep)) => Prettyprinter.Internal.Pretty (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.IR.MC.Op: instance (Futhark.IR.Prop.ASTRep rep, Futhark.Analysis.SymbolTable.IndexOp (op rep)) => Futhark.Analysis.SymbolTable.IndexOp (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.IR.MC.Op: instance (Futhark.IR.Prop.ASTRep rep, Futhark.IR.Prop.Names.FreeIn (op rep)) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.IR.MC.Op: instance (Futhark.IR.Prop.ASTRep rep, Futhark.Transform.Rename.Rename (op rep)) => Futhark.Transform.Rename.Rename (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.IR.MC.Op: instance (Futhark.IR.Prop.ASTRep rep, Futhark.Transform.Substitute.Substitute (op rep)) => Futhark.Transform.Substitute.Substitute (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.IR.MC.Op: instance (Futhark.IR.Rep.RepTypes rep, GHC.Classes.Eq (op rep)) => GHC.Classes.Eq (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.IR.MC.Op: instance (Futhark.IR.Rep.RepTypes rep, GHC.Classes.Ord (op rep)) => GHC.Classes.Ord (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.IR.MC.Op: instance (Futhark.IR.Rep.RepTypes rep, GHC.Show.Show (op rep)) => GHC.Show.Show (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.IR.MC.Op: instance Futhark.IR.Aliases.CanBeAliased op => Futhark.IR.Aliases.CanBeAliased (Futhark.IR.MC.Op.MCOp op)
- Futhark.IR.MC.Op: instance Futhark.IR.Mem.OpReturns (Futhark.IR.MC.Op.MCOp Futhark.IR.Rep.NoOp)
- Futhark.IR.MC.Op: instance Futhark.IR.Prop.Aliases.AliasedOp op => Futhark.IR.Prop.Aliases.AliasedOp (Futhark.IR.MC.Op.MCOp op)
- Futhark.IR.MC.Op: instance Futhark.IR.Prop.IsOp op => Futhark.IR.Prop.IsOp (Futhark.IR.MC.Op.MCOp op)
- Futhark.IR.MC.Op: instance Futhark.IR.Prop.TypeOf.TypedOp op => Futhark.IR.Prop.TypeOf.TypedOp (Futhark.IR.MC.Op.MCOp op)
- Futhark.IR.MC.Op: instance Futhark.IR.Rephrase.RephraseOp op => Futhark.IR.Rephrase.RephraseOp (Futhark.IR.MC.Op.MCOp op)
- Futhark.IR.MC.Op: instance Futhark.Optimise.Simplify.Rep.CanBeWise op => Futhark.Optimise.Simplify.Rep.CanBeWise (Futhark.IR.MC.Op.MCOp op)
- Futhark.IR.MC.Op: simplifyMCOp :: (SimplifiableRep rep, BodyDec rep ~ ()) => SimplifyOp rep (op (Wise rep)) -> MCOp op (Wise rep) -> SimpleM rep (MCOp op (Wise rep), Stms (Wise rep))
- Futhark.IR.MC.Op: traverseMCOpStms :: Monad m => OpStmsTraverser m (op rep) rep -> OpStmsTraverser m (MCOp op rep) rep
- Futhark.IR.MC.Op: typeCheckMCOp :: Checkable rep => (op (Aliases rep) -> TypeM rep ()) -> MCOp op (Aliases rep) -> TypeM rep ()
- Futhark.IR.MCMem: data MCMem
- Futhark.IR.MCMem: instance Futhark.Builder.BuilderOps (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.MCMem.MCMem)
- Futhark.IR.MCMem: instance Futhark.Builder.BuilderOps Futhark.IR.MCMem.MCMem
- Futhark.IR.MCMem: instance Futhark.IR.Pretty.PrettyRep Futhark.IR.MCMem.MCMem
- Futhark.IR.MCMem: instance Futhark.IR.Prop.ASTRep Futhark.IR.MCMem.MCMem
- Futhark.IR.MCMem: instance Futhark.IR.Rep.RepTypes Futhark.IR.MCMem.MCMem
- Futhark.IR.MCMem: instance Futhark.IR.Traversals.TraverseOpStms (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.MCMem.MCMem)
- Futhark.IR.MCMem: instance Futhark.IR.TypeCheck.Checkable Futhark.IR.MCMem.MCMem
- Futhark.IR.MCMem: simplifyProg :: Prog MCMem -> PassM (Prog MCMem)
- Futhark.IR.Mem: Alloc :: SubExp -> Space -> MemOp (inner :: Type -> Type) rep
- Futhark.IR.Mem: ArrayIn :: VName -> LMAD -> MemBind
- Futhark.IR.Mem: Inner :: inner rep -> MemOp (inner :: Type -> Type) rep
- Futhark.IR.Mem: MemAcc :: VName -> Shape -> [Type] -> u -> MemInfo d u ret
- Futhark.IR.Mem: MemArray :: PrimType -> ShapeBase d -> u -> ret -> MemInfo d u ret
- Futhark.IR.Mem: MemMem :: Space -> MemInfo d u ret
- Futhark.IR.Mem: MemPrim :: PrimType -> MemInfo d u ret
- Futhark.IR.Mem: ReturnsInBlock :: VName -> ExtLMAD -> MemReturn
- Futhark.IR.Mem: ReturnsNewBlock :: Space -> Int -> ExtLMAD -> MemReturn
- Futhark.IR.Mem: bodyReturnsFromPat :: Pat (MemBound NoUniqueness) -> [(VName, BodyReturns)]
- Futhark.IR.Mem: bodyReturnsToExpReturns :: BodyReturns -> ExpReturns
- Futhark.IR.Mem: checkMemInfo :: Checkable rep => VName -> MemInfo SubExp u MemBind -> TypeM rep ()
- Futhark.IR.Mem: class HasLetDecMem t
- Futhark.IR.Mem: class IsOp op => OpReturns (op :: Type -> Type)
- Futhark.IR.Mem: data MemBind
- Futhark.IR.Mem: data MemInfo d u ret
- Futhark.IR.Mem: data MemOp (inner :: Type -> Type) rep
- Futhark.IR.Mem: data MemReturn
- Futhark.IR.Mem: existentialiseLMAD :: [VName] -> LMAD -> ExtLMAD
- Futhark.IR.Mem: expReturns :: forall rep m (inner :: Type -> Type). (LocalScope rep m, Mem rep inner) => Exp rep -> m (Maybe [ExpReturns])
- Futhark.IR.Mem: extReturns :: [ExtType] -> [ExpReturns]
- Futhark.IR.Mem: instance (Futhark.IR.Prop.Names.FreeIn d, Futhark.IR.Prop.Names.FreeIn ret) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Mem.MemInfo d u ret)
- Futhark.IR.Mem: instance (Futhark.Optimise.Simplify.Engine.Simplifiable d, Futhark.Optimise.Simplify.Engine.Simplifiable ret) => Futhark.Optimise.Simplify.Engine.Simplifiable (Futhark.IR.Mem.MemInfo d u ret)
- Futhark.IR.Mem: instance (Futhark.Transform.Substitute.Substitute d, Futhark.Transform.Substitute.Substitute ret) => Futhark.Transform.Rename.Rename (Futhark.IR.Mem.MemInfo d u ret)
- Futhark.IR.Mem: instance (Futhark.Transform.Substitute.Substitute d, Futhark.Transform.Substitute.Substitute ret) => Futhark.Transform.Substitute.Substitute (Futhark.IR.Mem.MemInfo d u ret)
- Futhark.IR.Mem: instance (GHC.Classes.Eq d, GHC.Classes.Eq ret, GHC.Classes.Eq u) => GHC.Classes.Eq (Futhark.IR.Mem.MemInfo d u ret)
- Futhark.IR.Mem: instance (GHC.Classes.Ord d, GHC.Classes.Ord ret, GHC.Classes.Ord u) => GHC.Classes.Ord (Futhark.IR.Mem.MemInfo d u ret)
- Futhark.IR.Mem: instance (GHC.Show.Show d, GHC.Show.Show ret, GHC.Show.Show u) => GHC.Show.Show (Futhark.IR.Mem.MemInfo d u ret)
- Futhark.IR.Mem: instance (Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.ShapeBase d), Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.TypeBase (Futhark.IR.Syntax.Core.ShapeBase d) u), Prettyprinter.Internal.Pretty d, Prettyprinter.Internal.Pretty u, Prettyprinter.Internal.Pretty ret) => Prettyprinter.Internal.Pretty (Futhark.IR.Mem.MemInfo d u ret)
- Futhark.IR.Mem: instance Futhark.Analysis.Metrics.OpMetrics (inner rep) => Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.Mem.MemOp inner rep)
- Futhark.IR.Mem: instance Futhark.Analysis.SymbolTable.IndexOp (inner rep) => Futhark.Analysis.SymbolTable.IndexOp (Futhark.IR.Mem.MemOp inner rep)
- Futhark.IR.Mem: instance Futhark.IR.Aliases.CanBeAliased inner => Futhark.IR.Aliases.CanBeAliased (Futhark.IR.Mem.MemOp inner)
- Futhark.IR.Mem: instance Futhark.IR.Mem.HasLetDecMem Futhark.IR.Mem.LetDecMem
- Futhark.IR.Mem: instance Futhark.IR.Mem.HasLetDecMem b => Futhark.IR.Mem.HasLetDecMem (a, b)
- Futhark.IR.Mem: instance Futhark.IR.Mem.OpReturns Futhark.IR.Rep.NoOp
- Futhark.IR.Mem: instance Futhark.IR.Mem.OpReturns inner => Futhark.IR.Mem.OpReturns (Futhark.IR.Mem.MemOp inner)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Aliases.AliasedOp inner => Futhark.IR.Prop.Aliases.AliasedOp (Futhark.IR.Mem.MemOp inner)
- Futhark.IR.Mem: instance Futhark.IR.Prop.IsOp inner => Futhark.IR.Prop.IsOp (Futhark.IR.Mem.MemOp inner)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Names.FreeIn (inner rep) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Mem.MemOp inner rep)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Mem.MemBind
- Futhark.IR.Mem: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Mem.MemReturn
- Futhark.IR.Mem: instance Futhark.IR.Prop.TypeOf.TypedOp inner => Futhark.IR.Prop.TypeOf.TypedOp (Futhark.IR.Mem.MemOp inner)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Types.DeclTyped (Futhark.IR.Mem.MemInfo Futhark.IR.Syntax.Core.SubExp Language.Futhark.Core.Uniqueness ret)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Types.FixExt Futhark.IR.Mem.MemReturn
- Futhark.IR.Mem: instance Futhark.IR.Prop.Types.FixExt ret => Futhark.IR.Prop.Types.DeclExtTyped (Futhark.IR.Mem.MemInfo Futhark.IR.Syntax.Core.ExtSize Language.Futhark.Core.Uniqueness ret)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Types.FixExt ret => Futhark.IR.Prop.Types.ExtTyped (Futhark.IR.Mem.MemInfo Futhark.IR.Syntax.Core.ExtSize Language.Futhark.Core.NoUniqueness ret)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Types.FixExt ret => Futhark.IR.Prop.Types.ExtTyped (Futhark.IR.Mem.MemInfo Futhark.IR.Syntax.Core.ExtSize Language.Futhark.Core.Uniqueness ret)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Types.FixExt ret => Futhark.IR.Prop.Types.FixExt (Futhark.IR.Mem.MemInfo Futhark.IR.Syntax.Core.ExtSize u ret)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Types.Typed (Futhark.IR.Mem.MemInfo Futhark.IR.Syntax.Core.SubExp Language.Futhark.Core.NoUniqueness ret)
- Futhark.IR.Mem: instance Futhark.IR.Prop.Types.Typed (Futhark.IR.Mem.MemInfo Futhark.IR.Syntax.Core.SubExp Language.Futhark.Core.Uniqueness ret)
- Futhark.IR.Mem: instance Futhark.IR.Rephrase.RephraseOp inner => Futhark.IR.Rephrase.RephraseOp (Futhark.IR.Mem.MemOp inner)
- Futhark.IR.Mem: instance Futhark.IR.RetType.IsBodyType Futhark.IR.Mem.BodyReturns
- Futhark.IR.Mem: instance Futhark.IR.RetType.IsRetType Futhark.IR.Mem.FunReturns
- Futhark.IR.Mem: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.Mem.MemBind
- Futhark.IR.Mem: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.Mem.MemReturn
- Futhark.IR.Mem: instance Futhark.Optimise.Simplify.Engine.Simplifiable [Futhark.IR.Mem.FunReturns]
- Futhark.IR.Mem: instance Futhark.Optimise.Simplify.Rep.CanBeWise inner => Futhark.Optimise.Simplify.Rep.CanBeWise (Futhark.IR.Mem.MemOp inner)
- Futhark.IR.Mem: instance Futhark.Transform.Rename.Rename (inner rep) => Futhark.Transform.Rename.Rename (Futhark.IR.Mem.MemOp inner rep)
- Futhark.IR.Mem: instance Futhark.Transform.Rename.Rename Futhark.IR.Mem.MemBind
- Futhark.IR.Mem: instance Futhark.Transform.Rename.Rename Futhark.IR.Mem.MemReturn
- Futhark.IR.Mem: instance Futhark.Transform.Substitute.Substitute (inner rep) => Futhark.Transform.Substitute.Substitute (Futhark.IR.Mem.MemOp inner rep)
- Futhark.IR.Mem: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Mem.MemBind
- Futhark.IR.Mem: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Mem.MemReturn
- Futhark.IR.Mem: instance GHC.Classes.Eq (inner rep) => GHC.Classes.Eq (Futhark.IR.Mem.MemOp inner rep)
- Futhark.IR.Mem: instance GHC.Classes.Eq Futhark.IR.Mem.MemBind
- Futhark.IR.Mem: instance GHC.Classes.Eq Futhark.IR.Mem.MemReturn
- Futhark.IR.Mem: instance GHC.Classes.Ord (inner rep) => GHC.Classes.Ord (Futhark.IR.Mem.MemOp inner rep)
- Futhark.IR.Mem: instance GHC.Classes.Ord Futhark.IR.Mem.MemBind
- Futhark.IR.Mem: instance GHC.Classes.Ord Futhark.IR.Mem.MemReturn
- Futhark.IR.Mem: instance GHC.Show.Show (inner rep) => GHC.Show.Show (Futhark.IR.Mem.MemOp inner rep)
- Futhark.IR.Mem: instance GHC.Show.Show Futhark.IR.Mem.MemBind
- Futhark.IR.Mem: instance GHC.Show.Show Futhark.IR.Mem.MemReturn
- Futhark.IR.Mem: instance Prettyprinter.Internal.Pretty (inner rep) => Prettyprinter.Internal.Pretty (Futhark.IR.Mem.MemOp inner rep)
- Futhark.IR.Mem: instance Prettyprinter.Internal.Pretty Futhark.IR.Mem.MemBind
- Futhark.IR.Mem: instance Prettyprinter.Internal.Pretty Futhark.IR.Mem.MemReturn
- Futhark.IR.Mem: isStaticLMAD :: ExtLMAD -> Maybe LMAD
- Futhark.IR.Mem: letDecMem :: HasLetDecMem t => t -> LetDecMem
- Futhark.IR.Mem: lookupArraySummary :: forall rep (inner :: Type -> Type) m. (Mem rep inner, HasScope rep m, Monad m) => VName -> m (VName, LMAD (TPrimExp Int64 VName))
- Futhark.IR.Mem: lookupMemInfo :: forall rep m (inner :: Type -> Type). (HasScope rep m, Mem rep inner) => VName -> m (MemInfo SubExp NoUniqueness MemBind)
- Futhark.IR.Mem: lookupMemSpace :: forall rep (inner :: Type -> Type) m. (Mem rep inner, HasScope rep m, Monad m) => VName -> m Space
- Futhark.IR.Mem: matchBranchReturnType :: forall rep (inner :: Type -> Type). (Mem rep inner, Checkable rep) => [BodyReturns] -> Body (Aliases rep) -> TypeM rep ()
- Futhark.IR.Mem: matchFunctionReturnType :: forall rep (inner :: Type -> Type). (Mem rep inner, Checkable rep) => [FunReturns] -> Result -> TypeM rep ()
- Futhark.IR.Mem: matchLoopResultMem :: forall rep (inner :: Type -> Type). (Mem rep inner, Checkable rep) => [FParam (Aliases rep)] -> Result -> TypeM rep ()
- Futhark.IR.Mem: matchPatToExp :: forall rep (inner :: Type -> Type). (Mem rep inner, LetDec rep ~ LetDecMem, Checkable rep) => Pat (LetDec (Aliases rep)) -> Exp (Aliases rep) -> TypeM rep ()
- Futhark.IR.Mem: nameInfoToMemInfo :: forall rep (inner :: Type -> Type). Mem rep inner => NameInfo rep -> MemBound NoUniqueness
- Futhark.IR.Mem: noUniquenessReturns :: MemInfo d u r -> MemInfo d NoUniqueness r
- Futhark.IR.Mem: opReturns :: forall rep (inner :: Type -> Type) m. (OpReturns op, Mem rep inner, Monad m, HasScope rep m) => op rep -> m [ExpReturns]
- Futhark.IR.Mem: subExpMemInfo :: forall rep m (inner :: Type -> Type). (HasScope rep m, Mem rep inner) => SubExp -> m (MemInfo SubExp NoUniqueness MemBind)
- Futhark.IR.Mem: traverseMemOpStms :: Monad m => OpStmsTraverser m (inner rep) rep -> OpStmsTraverser m (MemOp inner rep) rep
- Futhark.IR.Mem: type BodyReturns = MemInfo ExtSize NoUniqueness MemReturn
- Futhark.IR.Mem: type BranchTypeMem = BodyReturns
- Futhark.IR.Mem: type ExpReturns = MemInfo ExtSize NoUniqueness Maybe MemReturn
- Futhark.IR.Mem: type ExtLMAD = LMAD TPrimExp Int64 Ext VName
- Futhark.IR.Mem: type FParamMem = MemInfo SubExp Uniqueness MemBind
- Futhark.IR.Mem: type FunReturns = MemInfo ExtSize Uniqueness MemReturn
- Futhark.IR.Mem: type LMAD = LMAD TPrimExp Int64 VName
- Futhark.IR.Mem: type LParamMem = MemInfo SubExp NoUniqueness MemBind
- Futhark.IR.Mem: type LetDecMem = MemInfo SubExp NoUniqueness MemBind
- Futhark.IR.Mem: type Mem rep (inner :: Type -> Type) = (FParamInfo rep ~ FParamMem, LParamInfo rep ~ LParamMem, HasLetDecMem LetDec rep, RetType rep ~ RetTypeMem, BranchType rep ~ BranchTypeMem, ASTRep rep, OpReturns inner, RephraseOp inner, ASTConstraints inner rep, FreeIn inner rep, OpC rep ~ MemOp inner)
- Futhark.IR.Mem: type MemBound u = MemInfo SubExp u MemBind
- Futhark.IR.Mem: type RetTypeMem = FunReturns
- Futhark.IR.Mem: varReturns :: forall rep m (inner :: Type -> Type). (HasScope rep m, Monad m, Mem rep inner) => VName -> m ExpReturns
- Futhark.IR.Mem.Interval: Interval :: TPrimExp Int64 VName -> TPrimExp Int64 VName -> TPrimExp Int64 VName -> Interval
- Futhark.IR.Mem.Interval: [lowerBound] :: Interval -> TPrimExp Int64 VName
- Futhark.IR.Mem.Interval: [numElements] :: Interval -> TPrimExp Int64 VName
- Futhark.IR.Mem.Interval: [stride] :: Interval -> TPrimExp Int64 VName
- Futhark.IR.Mem.Interval: data Interval
- Futhark.IR.Mem.Interval: distributeOffset :: MonadFail m => SofP -> [Interval] -> m [Interval]
- Futhark.IR.Mem.Interval: expandOffset :: SofP -> [Interval] -> Maybe SofP
- Futhark.IR.Mem.Interval: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Mem.Interval.Interval
- Futhark.IR.Mem.Interval: instance GHC.Classes.Eq Futhark.IR.Mem.Interval.Interval
- Futhark.IR.Mem.Interval: instance GHC.Show.Show Futhark.IR.Mem.Interval.Interval
- Futhark.IR.Mem.Interval: intervalOverlap :: [(VName, PrimExp VName)] -> Names -> Interval -> Interval -> Bool
- Futhark.IR.Mem.Interval: intervalPairs :: [Interval] -> [Interval] -> [(Interval, Interval)]
- Futhark.IR.Mem.Interval: justLeafExp :: PrimExp VName -> Maybe VName
- Futhark.IR.Mem.Interval: primBool :: TPrimExp Bool VName -> Maybe Bool
- Futhark.IR.Mem.Interval: selfOverlap :: scope -> asserts -> [(VName, PrimExp VName)] -> [PrimExp VName] -> [Interval] -> Maybe Interval
- Futhark.IR.Mem.LMAD: LMAD :: num -> [LMADDim num] -> LMAD num
- Futhark.IR.Mem.LMAD: LMADDim :: num -> num -> LMADDim num
- Futhark.IR.Mem.LMAD: [dims] :: LMAD num -> [LMADDim num]
- Futhark.IR.Mem.LMAD: [ldShape] :: LMADDim num -> num
- Futhark.IR.Mem.LMAD: [ldStride] :: LMADDim num -> num
- Futhark.IR.Mem.LMAD: [offset] :: LMAD num -> num
- Futhark.IR.Mem.LMAD: closeEnough :: LMAD num -> LMAD num -> Bool
- Futhark.IR.Mem.LMAD: coerce :: LMAD num -> Shape num -> LMAD num
- Futhark.IR.Mem.LMAD: data LMAD num
- Futhark.IR.Mem.LMAD: data LMADDim num
- Futhark.IR.Mem.LMAD: disjoint :: [(VName, PrimExp VName)] -> Names -> LMAD (TPrimExp Int64 VName) -> LMAD (TPrimExp Int64 VName) -> Bool
- Futhark.IR.Mem.LMAD: disjoint2 :: scope -> asserts -> [(VName, PrimExp VName)] -> Names -> LMAD (TPrimExp Int64 VName) -> LMAD (TPrimExp Int64 VName) -> Bool
- Futhark.IR.Mem.LMAD: disjoint3 :: Map VName Type -> [PrimExp VName] -> [(VName, PrimExp VName)] -> [PrimExp VName] -> LMAD (TPrimExp Int64 VName) -> LMAD (TPrimExp Int64 VName) -> Bool
- Futhark.IR.Mem.LMAD: dynamicEqualsLMAD :: forall {k} num (t :: k). Eq num => LMAD (TPrimExp t num) -> LMAD (TPrimExp t num) -> TPrimExp Bool num
- Futhark.IR.Mem.LMAD: equivalent :: Eq num => LMAD num -> LMAD num -> Bool
- Futhark.IR.Mem.LMAD: existentialize :: Int -> LMAD (TPrimExp Int64 a) -> LMAD (TPrimExp Int64 (Ext a))
- Futhark.IR.Mem.LMAD: existentialized :: LMAD a -> [a]
- Futhark.IR.Mem.LMAD: expand :: IntegralExp num => num -> num -> LMAD num -> LMAD num
- Futhark.IR.Mem.LMAD: flatSlice :: IntegralExp num => LMAD num -> FlatSlice num -> LMAD num
- Futhark.IR.Mem.LMAD: index :: (IntegralExp num, Eq num) => LMAD num -> Indices num -> num
- Futhark.IR.Mem.LMAD: instance Data.Foldable.Foldable Futhark.IR.Mem.LMAD.LMAD
- Futhark.IR.Mem.LMAD: instance Data.Traversable.Traversable Futhark.IR.Mem.LMAD.LMAD
- Futhark.IR.Mem.LMAD: instance Futhark.IR.Prop.Names.FreeIn num => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Mem.LMAD.LMAD num)
- Futhark.IR.Mem.LMAD: instance Futhark.IR.Prop.Names.FreeIn num => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Mem.LMAD.LMADDim num)
- Futhark.IR.Mem.LMAD: instance Futhark.Transform.Substitute.Substitute num => Futhark.Transform.Rename.Rename (Futhark.IR.Mem.LMAD.LMAD num)
- Futhark.IR.Mem.LMAD: instance Futhark.Transform.Substitute.Substitute num => Futhark.Transform.Substitute.Substitute (Futhark.IR.Mem.LMAD.LMAD num)
- Futhark.IR.Mem.LMAD: instance GHC.Base.Functor Futhark.IR.Mem.LMAD.LMAD
- Futhark.IR.Mem.LMAD: instance GHC.Classes.Eq num => GHC.Classes.Eq (Futhark.IR.Mem.LMAD.LMAD num)
- Futhark.IR.Mem.LMAD: instance GHC.Classes.Eq num => GHC.Classes.Eq (Futhark.IR.Mem.LMAD.LMADDim num)
- Futhark.IR.Mem.LMAD: instance GHC.Classes.Ord num => GHC.Classes.Ord (Futhark.IR.Mem.LMAD.LMAD num)
- Futhark.IR.Mem.LMAD: instance GHC.Classes.Ord num => GHC.Classes.Ord (Futhark.IR.Mem.LMAD.LMADDim num)
- Futhark.IR.Mem.LMAD: instance GHC.Show.Show num => GHC.Show.Show (Futhark.IR.Mem.LMAD.LMAD num)
- Futhark.IR.Mem.LMAD: instance GHC.Show.Show num => GHC.Show.Show (Futhark.IR.Mem.LMAD.LMADDim num)
- Futhark.IR.Mem.LMAD: instance Prettyprinter.Internal.Pretty num => Prettyprinter.Internal.Pretty (Futhark.IR.Mem.LMAD.LMAD num)
- Futhark.IR.Mem.LMAD: iota :: IntegralExp num => num -> [num] -> LMAD num
- Futhark.IR.Mem.LMAD: isDirect :: (Eq num, IntegralExp num) => LMAD num -> Bool
- Futhark.IR.Mem.LMAD: mkExistential :: Shape (Ext a) -> Int -> LMAD (Ext a)
- Futhark.IR.Mem.LMAD: permute :: LMAD num -> Permutation -> LMAD num
- Futhark.IR.Mem.LMAD: range :: Pretty num => LMAD (TPrimExp Int64 num) -> TPrimExp Int64 num
- Futhark.IR.Mem.LMAD: reshape :: (Eq num, IntegralExp num) => LMAD num -> Shape num -> Maybe (LMAD num)
- Futhark.IR.Mem.LMAD: shape :: LMAD num -> Shape num
- Futhark.IR.Mem.LMAD: slice :: (Eq num, IntegralExp num) => LMAD num -> Slice num -> LMAD num
- Futhark.IR.Mem.LMAD: substitute :: forall {k} a (t :: k). Ord a => Map a (TPrimExp t a) -> LMAD (TPrimExp t a) -> LMAD (TPrimExp t a)
- Futhark.IR.Mem.LMAD: type Indices num = [num]
- Futhark.IR.Mem.LMAD: type Permutation = [Int]
- Futhark.IR.Mem.LMAD: type Shape num = [num]
- Futhark.IR.Mem.Simplify: memRuleBook :: forall rep (inner :: Type -> Type). SimplifyMemory rep inner => RuleBook (Wise rep)
- Futhark.IR.Mem.Simplify: simpleGeneric :: SimplifyMemory rep inner => (inner (Wise rep) -> UsageTable) -> SimplifyOp rep (inner (Wise rep)) -> SimpleOps rep
- Futhark.IR.Mem.Simplify: simplifyProgGeneric :: forall rep (inner :: Type -> Type). SimplifyMemory rep inner => RuleBook (Wise rep) -> SimpleOps rep -> Prog rep -> PassM (Prog rep)
- Futhark.IR.Mem.Simplify: simplifyStmsGeneric :: forall rep m (inner :: Type -> Type). (HasScope rep m, MonadFreshNames m, SimplifyMemory rep inner) => RuleBook (Wise rep) -> SimpleOps rep -> Stms rep -> m (Stms rep)
- Futhark.IR.Mem.Simplify: type SimplifyMemory rep (inner :: Type -> Type) = (SimplifiableRep rep, LetDec rep ~ LetDecMem, ExpDec rep ~ (), BodyDec rep ~ (), CanBeWise OpC rep, BuilderOps Wise rep, OpReturns inner, IndexOp inner Wise rep, AliasedOp inner, Mem rep inner, CanBeWise inner, RephraseOp inner, ASTConstraints inner Wise rep)
- Futhark.IR.Parse: parseBodyGPU :: FilePath -> Text -> Either Text (Body GPU)
- Futhark.IR.Parse: parseBodyMC :: FilePath -> Text -> Either Text (Body MC)
- Futhark.IR.Parse: parseDeclExtType :: FilePath -> Text -> Either Text DeclExtType
- Futhark.IR.Parse: parseDeclType :: FilePath -> Text -> Either Text DeclType
- Futhark.IR.Parse: parseGPU :: FilePath -> Text -> Either Text (Prog GPU)
- Futhark.IR.Parse: parseGPUMem :: FilePath -> Text -> Either Text (Prog GPUMem)
- Futhark.IR.Parse: parseMC :: FilePath -> Text -> Either Text (Prog MC)
- Futhark.IR.Parse: parseMCMem :: FilePath -> Text -> Either Text (Prog MCMem)
- Futhark.IR.Parse: parseSOACS :: FilePath -> Text -> Either Text (Prog SOACS)
- Futhark.IR.Parse: parseSeq :: FilePath -> Text -> Either Text (Prog Seq)
- Futhark.IR.Parse: parseSeqMem :: FilePath -> Text -> Either Text (Prog SeqMem)
- Futhark.IR.Parse: parseStmGPU :: FilePath -> Text -> Either Text (Stm GPU)
- Futhark.IR.Parse: parseStmMC :: FilePath -> Text -> Either Text (Stm MC)
- Futhark.IR.Parse: parseSubExp :: FilePath -> Text -> Either Text SubExp
- Futhark.IR.Parse: parseSubExpRes :: FilePath -> Text -> Either Text SubExpRes
- Futhark.IR.Parse: parseType :: FilePath -> Text -> Either Text Type
- Futhark.IR.Parse: parseVName :: FilePath -> Text -> Either Text VName
- Futhark.IR.Pretty: class (RepTypes rep, Pretty RetType rep, Pretty BranchType rep, Pretty FParamInfo rep, Pretty LParamInfo rep, Pretty LetDec rep, Pretty Op rep) => PrettyRep rep
- Futhark.IR.Pretty: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Body rep)
- Futhark.IR.Pretty: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Case (Futhark.IR.Syntax.Body rep))
- Futhark.IR.Pretty: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Exp rep)
- Futhark.IR.Pretty: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.FunDef rep)
- Futhark.IR.Pretty: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Lambda rep)
- Futhark.IR.Pretty: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Prog rep)
- Futhark.IR.Pretty: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Stm rep)
- Futhark.IR.Pretty: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Stms rep)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.BasicOp
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.Attr
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.Attrs
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.Certs
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.Commutativity
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.EntryPointType
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.Ident
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.OpaqueType
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.OpaqueTypes
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.Rank
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.Signedness
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.Space
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.SubExp
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.Core.ValueType
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.EntryParam
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.EntryResult
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Futhark.IR.Syntax.SubExpRes
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty Language.Futhark.Core.VName
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty a => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.ErrorMsg a)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty a => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.Ext a)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty a => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.FlatSlice a)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty a => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.Slice a)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty d => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.DimIndex d)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty d => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.FlatDimIndex d)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty d => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty d => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.DimSplice d)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty d => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.NewShape d)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty dec => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.StmAux dec)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty t => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.Param t)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty t => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.PatElem t)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty t => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Pat t)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty u => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.TypeBase Futhark.IR.Syntax.Core.ExtShape u)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty u => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.TypeBase Futhark.IR.Syntax.Core.Rank u)
- Futhark.IR.Pretty: instance Prettyprinter.Internal.Pretty u => Prettyprinter.Internal.Pretty (Futhark.IR.Syntax.Core.TypeBase Futhark.IR.Syntax.Core.Shape u)
- Futhark.IR.Pretty: instance forall k (rep :: k). Prettyprinter.Internal.Pretty (Futhark.IR.Rep.NoOp rep)
- Futhark.IR.Pretty: ppExpDec :: PrettyRep rep => ExpDec rep -> Exp rep -> Maybe (Doc a)
- Futhark.IR.Pretty: prettyString :: Pretty a => a -> String
- Futhark.IR.Pretty: prettyTuple :: Pretty a => [a] -> Text
- Futhark.IR.Pretty: prettyTupleLines :: Pretty a => [a] -> Text
- Futhark.IR.Prop: asBasicOp :: Exp rep -> Maybe BasicOp
- Futhark.IR.Prop: attrsForAssert :: Attrs -> Attrs
- Futhark.IR.Prop: builtInFunctions :: Map Name (PrimType, [PrimType])
- Futhark.IR.Prop: certify :: Certs -> Stm rep -> Stm rep
- Futhark.IR.Prop: cheapOp :: (IsOp op, ASTRep rep) => op rep -> Bool
- Futhark.IR.Prop: class (RepTypes rep, PrettyRep rep, Renameable rep, Substitutable rep, FreeDec ExpDec rep, FreeIn LetDec rep, FreeDec BodyDec rep, FreeIn FParamInfo rep, FreeIn LParamInfo rep, FreeIn RetType rep, FreeIn BranchType rep, ASTConstraints OpC rep rep, IsOp OpC rep, RephraseOp OpC rep) => ASTRep rep
- Futhark.IR.Prop: class TypedOp op => IsOp (op :: Type -> Type)
- Futhark.IR.Prop: commutativeLambda :: Lambda rep -> Bool
- Futhark.IR.Prop: defAux :: dec -> StmAux dec
- Futhark.IR.Prop: expExtTypesFromPat :: Typed dec => Pat dec -> [ExtType]
- Futhark.IR.Prop: expTypesFromPat :: (ASTRep rep, HasScope rep m, Monad m) => Pat (LetDec rep) -> m [BranchType rep]
- Futhark.IR.Prop: instance Futhark.IR.Prop.IsOp Futhark.IR.Rep.NoOp
- Futhark.IR.Prop: isBuiltInFunction :: Name -> Bool
- Futhark.IR.Prop: lamIsBinOp :: ASTRep rep => Lambda rep -> Maybe [(BinOp, PrimType, VName, VName)]
- Futhark.IR.Prop: opDependencies :: (IsOp op, ASTRep rep) => op rep -> [Names]
- Futhark.IR.Prop: safeExp :: ASTRep rep => Exp rep -> Bool
- Futhark.IR.Prop: safeOp :: (IsOp op, ASTRep rep) => op rep -> Bool
- Futhark.IR.Prop: stmCerts :: Stm rep -> Certs
- Futhark.IR.Prop: subExpVar :: SubExp -> Maybe VName
- Futhark.IR.Prop: subExpVars :: [SubExp] -> [VName]
- Futhark.IR.Prop: type ASTConstraints a = (Eq a, Ord a, Show a, Rename a, Substitute a, FreeIn a, Pretty a)
- Futhark.IR.Prop.Aliases: aliasesOf :: AliasesOf a => a -> Names
- Futhark.IR.Prop.Aliases: bodyAliases :: Aliased rep => Body rep -> [Names]
- Futhark.IR.Prop.Aliases: class (ASTRep rep, AliasedOp OpC rep, AliasesOf LetDec rep) => Aliased rep
- Futhark.IR.Prop.Aliases: class IsOp op => AliasedOp (op :: Type -> Type)
- Futhark.IR.Prop.Aliases: class AliasesOf a
- Futhark.IR.Prop.Aliases: consumedByLambda :: Aliased rep => Lambda rep -> Names
- Futhark.IR.Prop.Aliases: consumedInBody :: Aliased rep => Body rep -> Names
- Futhark.IR.Prop.Aliases: consumedInExp :: Aliased rep => Exp rep -> Names
- Futhark.IR.Prop.Aliases: consumedInOp :: (AliasedOp op, Aliased rep) => op rep -> Names
- Futhark.IR.Prop.Aliases: consumedInStm :: Aliased rep => Stm rep -> Names
- Futhark.IR.Prop.Aliases: expAliases :: Aliased rep => [PatElem dec] -> Exp rep -> [Names]
- Futhark.IR.Prop.Aliases: instance Futhark.IR.Prop.Aliases.AliasedOp Futhark.IR.Rep.NoOp
- Futhark.IR.Prop.Aliases: instance Futhark.IR.Prop.Aliases.AliasesOf Futhark.IR.Prop.Names.Names
- Futhark.IR.Prop.Aliases: instance Futhark.IR.Prop.Aliases.AliasesOf dec => Futhark.IR.Prop.Aliases.AliasesOf (Futhark.IR.Syntax.Core.PatElem dec)
- Futhark.IR.Prop.Aliases: lookupAliases :: AliasesOf (LetDec rep) => VName -> Scope rep -> Names
- Futhark.IR.Prop.Aliases: opAliases :: (AliasedOp op, Aliased rep) => op rep -> [Names]
- Futhark.IR.Prop.Aliases: patAliases :: AliasesOf dec => Pat dec -> [Names]
- Futhark.IR.Prop.Aliases: subExpAliases :: SubExp -> Names
- Futhark.IR.Prop.Aliases: type AliasTable = Map VName Names
- Futhark.IR.Prop.Constants: class IsValue a
- Futhark.IR.Prop.Constants: constant :: IsValue v => v -> SubExp
- Futhark.IR.Prop.Constants: floatConst :: FloatType -> Double -> SubExp
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Int.Int16
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Int.Int32
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Int.Int64
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Int.Int8
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Types.Bool
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Types.Double
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Types.Float
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Word.Word16
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Word.Word32
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Word.Word64
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue GHC.Word.Word8
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue Language.Futhark.Primitive.FloatValue
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue Language.Futhark.Primitive.IntValue
- Futhark.IR.Prop.Constants: instance Futhark.IR.Prop.Constants.IsValue Language.Futhark.Primitive.PrimValue
- Futhark.IR.Prop.Constants: intConst :: IntType -> Integer -> SubExp
- Futhark.IR.Prop.Constants: value :: IsValue a => a -> PrimValue
- Futhark.IR.Prop.Names: boundByLambda :: Lambda rep -> [VName]
- Futhark.IR.Prop.Names: boundByStm :: Stm rep -> Names
- Futhark.IR.Prop.Names: boundByStms :: Stms rep -> Names
- Futhark.IR.Prop.Names: boundInBody :: Body rep -> Names
- Futhark.IR.Prop.Names: class FreeIn dec => FreeDec dec
- Futhark.IR.Prop.Names: class FreeIn a
- Futhark.IR.Prop.Names: data FV
- Futhark.IR.Prop.Names: data Names
- Futhark.IR.Prop.Names: freeIn :: FreeIn a => a -> Names
- Futhark.IR.Prop.Names: freeIn' :: FreeIn a => a -> FV
- Futhark.IR.Prop.Names: freeInStmsAndRes :: (FreeIn (Op rep), FreeIn (LetDec rep), FreeIn (LParamInfo rep), FreeIn (FParamInfo rep), FreeDec (BodyDec rep), FreeIn (RetType rep), FreeIn (BranchType rep), FreeDec (ExpDec rep)) => Stms rep -> Result -> FV
- Futhark.IR.Prop.Names: fvBind :: Names -> FV -> FV
- Futhark.IR.Prop.Names: fvName :: VName -> FV
- Futhark.IR.Prop.Names: fvNames :: Names -> FV
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.ExpDec rep), Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.BodyDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.FParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LetDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.RetType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.BranchType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.Op rep)) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Body rep)
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.ExpDec rep), Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.BodyDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.FParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LetDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.RetType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.BranchType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.Op rep)) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Exp rep)
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.ExpDec rep), Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.BodyDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.FParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LetDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.RetType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.BranchType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.Op rep)) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.FunDef rep)
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.ExpDec rep), Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.BodyDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.FParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LetDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.RetType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.BranchType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.Op rep)) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Lambda rep)
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.ExpDec rep), Futhark.IR.Prop.Names.FreeDec (Futhark.IR.Rep.BodyDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.FParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LParamInfo rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.LetDec rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.RetType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.BranchType rep), Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.Op rep)) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Stm rep)
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeDec a, Futhark.IR.Prop.Names.FreeIn b) => Futhark.IR.Prop.Names.FreeDec (a, b)
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeIn a, Futhark.IR.Prop.Names.FreeIn b) => Futhark.IR.Prop.Names.FreeIn (Data.Either.Either a b)
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeIn a, Futhark.IR.Prop.Names.FreeIn b) => Futhark.IR.Prop.Names.FreeIn (a, b)
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeIn a, Futhark.IR.Prop.Names.FreeIn b, Futhark.IR.Prop.Names.FreeIn c) => Futhark.IR.Prop.Names.FreeIn (a, b, c)
- Futhark.IR.Prop.Names: instance (Futhark.IR.Prop.Names.FreeIn a, Futhark.IR.Prop.Names.FreeIn b, Futhark.IR.Prop.Names.FreeIn c, Futhark.IR.Prop.Names.FreeIn d) => Futhark.IR.Prop.Names.FreeIn (a, b, c, d)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeDec ()
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeDec Futhark.IR.Prop.Names.Names
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeDec a => Futhark.IR.Prop.Names.FreeDec (GHC.Maybe.Maybe a)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeDec a => Futhark.IR.Prop.Names.FreeDec [a]
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn ()
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Stm rep) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Stms rep)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Prop.Names.FV
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Prop.Names.Names
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Syntax.Core.Attrs
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Syntax.Core.Certs
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Syntax.Core.Ident
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Syntax.Core.Space
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Syntax.Core.SubExp
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Syntax.LoopForm
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.Syntax.SubExpRes
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn GHC.Types.Bool
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn GHC.Types.Int
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Language.Futhark.Core.VName
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn Language.Futhark.Primitive.PrimType
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn a => Futhark.IR.Prop.Names.FreeIn (Data.Set.Internal.Set a)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn a => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.MatchDec a)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn a => Futhark.IR.Prop.Names.FreeIn (GHC.Maybe.Maybe a)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn a => Futhark.IR.Prop.Names.FreeIn [a]
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn body => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Case body)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn d => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Core.DimIndex d)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn d => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Core.Ext d)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn d => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Core.FlatDimIndex d)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn d => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Core.FlatSlice d)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn d => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn d => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Core.Slice d)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn d => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.NewShape d)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn dec => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Core.Param dec)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn dec => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Core.PatElem dec)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn dec => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Pat dec)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn dec => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.StmAux dec)
- Futhark.IR.Prop.Names: instance Futhark.IR.Prop.Names.FreeIn shape => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Syntax.Core.TypeBase shape u)
- Futhark.IR.Prop.Names: instance GHC.Base.Monoid Futhark.IR.Prop.Names.FV
- Futhark.IR.Prop.Names: instance GHC.Base.Monoid Futhark.IR.Prop.Names.Names
- Futhark.IR.Prop.Names: instance GHC.Base.Semigroup Futhark.IR.Prop.Names.FV
- Futhark.IR.Prop.Names: instance GHC.Base.Semigroup Futhark.IR.Prop.Names.Names
- Futhark.IR.Prop.Names: instance GHC.Classes.Eq Futhark.IR.Prop.Names.Names
- Futhark.IR.Prop.Names: instance GHC.Classes.Ord Futhark.IR.Prop.Names.Names
- Futhark.IR.Prop.Names: instance GHC.Show.Show Futhark.IR.Prop.Names.Names
- Futhark.IR.Prop.Names: instance Prettyprinter.Internal.Pretty Futhark.IR.Prop.Names.Names
- Futhark.IR.Prop.Names: instance forall k (rep :: k). Futhark.IR.Prop.Names.FreeIn (Futhark.IR.Rep.NoOp rep)
- Futhark.IR.Prop.Names: mapNames :: (VName -> VName) -> Names -> Names
- Futhark.IR.Prop.Names: nameIn :: VName -> Names -> Bool
- Futhark.IR.Prop.Names: namesFromList :: [VName] -> Names
- Futhark.IR.Prop.Names: namesIntMap :: Names -> IntMap VName
- Futhark.IR.Prop.Names: namesIntSet :: Names -> IntSet
- Futhark.IR.Prop.Names: namesIntersect :: Names -> Names -> Bool
- Futhark.IR.Prop.Names: namesIntersection :: Names -> Names -> Names
- Futhark.IR.Prop.Names: namesSubtract :: Names -> Names -> Names
- Futhark.IR.Prop.Names: namesToList :: Names -> [VName]
- Futhark.IR.Prop.Names: notNameIn :: VName -> Names -> Bool
- Futhark.IR.Prop.Names: oneName :: VName -> Names
- Futhark.IR.Prop.Names: precomputed :: FreeDec dec => dec -> FV -> FV
- Futhark.IR.Prop.Pat: basicPat :: [Ident] -> Pat Type
- Futhark.IR.Prop.Pat: paramDeclType :: DeclTyped dec => Param dec -> DeclType
- Futhark.IR.Prop.Pat: paramIdent :: Typed dec => Param dec -> Ident
- Futhark.IR.Prop.Pat: paramType :: Typed dec => Param dec -> Type
- Futhark.IR.Prop.Pat: patElemIdent :: Typed dec => PatElem dec -> Ident
- Futhark.IR.Prop.Pat: patElemType :: Typed dec => PatElem dec -> Type
- Futhark.IR.Prop.Pat: patIdents :: Typed dec => Pat dec -> [Ident]
- Futhark.IR.Prop.Pat: patNames :: Pat dec -> [VName]
- Futhark.IR.Prop.Pat: patSize :: Pat dec -> Int
- Futhark.IR.Prop.Pat: patTypes :: Typed dec => Pat dec -> [Type]
- Futhark.IR.Prop.Pat: setPatElemDec :: PatElem oldattr -> newattr -> PatElem newattr
- Futhark.IR.Prop.Rearrange: isIdentityPerm :: [Int] -> Bool
- Futhark.IR.Prop.Rearrange: isMapTranspose :: [Int] -> Maybe (Int, Int, Int)
- Futhark.IR.Prop.Rearrange: isPermutationOf :: Eq a => [a] -> [a] -> Maybe [Int]
- Futhark.IR.Prop.Rearrange: rearrangeCompose :: [Int] -> [Int] -> [Int]
- Futhark.IR.Prop.Rearrange: rearrangeInverse :: [Int] -> [Int]
- Futhark.IR.Prop.Rearrange: rearrangeReach :: [Int] -> Int
- Futhark.IR.Prop.Rearrange: rearrangeShape :: [Int] -> [a] -> [a]
- Futhark.IR.Prop.Rearrange: transposeIndex :: Int -> Int -> [a] -> [a]
- Futhark.IR.Prop.Reshape: ReshapeArbitrary :: ReshapeKind
- Futhark.IR.Prop.Reshape: ReshapeCoerce :: ReshapeKind
- Futhark.IR.Prop.Reshape: applySplice :: ShapeBase d -> DimSplice d -> ShapeBase d
- Futhark.IR.Prop.Reshape: data ReshapeKind
- Futhark.IR.Prop.Reshape: flattenIndex :: IntegralExp num => [num] -> [num] -> num
- Futhark.IR.Prop.Reshape: flipRearrangeReshape :: [Int] -> NewShape d -> Maybe (NewShape d, [Int])
- Futhark.IR.Prop.Reshape: flipReshapeRearrange :: Eq d => [d] -> [d] -> [Int] -> Maybe [Int]
- Futhark.IR.Prop.Reshape: instance GHC.Classes.Eq Futhark.IR.Prop.Reshape.ReshapeKind
- Futhark.IR.Prop.Reshape: instance GHC.Classes.Ord Futhark.IR.Prop.Reshape.ReshapeKind
- Futhark.IR.Prop.Reshape: instance GHC.Show.Show Futhark.IR.Prop.Reshape.ReshapeKind
- Futhark.IR.Prop.Reshape: newShape :: NewShape d -> ShapeBase d
- Futhark.IR.Prop.Reshape: newshapeInner :: Shape -> NewShape SubExp -> NewShape SubExp
- Futhark.IR.Prop.Reshape: reshapeAll :: ArrayShape old => old -> ShapeBase new -> NewShape new
- Futhark.IR.Prop.Reshape: reshapeCoerce :: ShapeBase new -> NewShape new
- Futhark.IR.Prop.Reshape: reshapeIndex :: IntegralExp num => [num] -> [num] -> [num] -> [num]
- Futhark.IR.Prop.Reshape: reshapeInner :: Shape -> Int -> Shape -> Shape
- Futhark.IR.Prop.Reshape: reshapeKind :: NewShape SubExp -> ReshapeKind
- Futhark.IR.Prop.Reshape: reshapeOuter :: Shape -> Int -> Shape -> Shape
- Futhark.IR.Prop.Reshape: shapeCoerce :: [SubExp] -> VName -> Exp rep
- Futhark.IR.Prop.Reshape: simplifyNewShape :: Eq d => ShapeBase d -> NewShape d -> Maybe (NewShape d)
- Futhark.IR.Prop.Reshape: sliceSizes :: IntegralExp num => [num] -> [num]
- Futhark.IR.Prop.Reshape: unflattenIndex :: IntegralExp num => [num] -> num -> [num]
- Futhark.IR.Prop.Scope: FParamName :: FParamInfo rep -> NameInfo rep
- Futhark.IR.Prop.Scope: IndexName :: IntType -> NameInfo rep
- Futhark.IR.Prop.Scope: LParamName :: LParamInfo rep -> NameInfo rep
- Futhark.IR.Prop.Scope: LetName :: LetDec rep -> NameInfo rep
- Futhark.IR.Prop.Scope: askScope :: HasScope rep m => m (Scope rep)
- Futhark.IR.Prop.Scope: asksScope :: HasScope rep m => (Scope rep -> a) -> m a
- Futhark.IR.Prop.Scope: castScope :: SameScope fromrep torep => Scope fromrep -> Scope torep
- Futhark.IR.Prop.Scope: class (Applicative m, RepTypes rep) => HasScope rep (m :: Type -> Type) | m -> rep
- Futhark.IR.Prop.Scope: class (HasScope rep m, Monad m) => LocalScope rep (m :: Type -> Type)
- Futhark.IR.Prop.Scope: class Scoped rep a | a -> rep
- Futhark.IR.Prop.Scope: data ExtendedScope rep (m :: Type -> Type) a
- Futhark.IR.Prop.Scope: data NameInfo rep
- Futhark.IR.Prop.Scope: extendedScope :: ExtendedScope rep m a -> Scope rep -> m a
- Futhark.IR.Prop.Scope: inScopeOf :: (Scoped rep a, LocalScope rep m) => a -> m b -> m b
- Futhark.IR.Prop.Scope: instance (Futhark.IR.Prop.Scope.HasScope rep m, GHC.Base.Monad m) => Futhark.IR.Prop.Scope.HasScope rep (Futhark.IR.Prop.Scope.ExtendedScope rep m)
- Futhark.IR.Prop.Scope: instance (GHC.Base.Monad m, Futhark.IR.Prop.Scope.HasScope rep m) => Futhark.IR.Prop.Scope.HasScope rep (Control.Monad.Trans.Except.ExceptT e m)
- Futhark.IR.Prop.Scope: instance (GHC.Base.Monad m, Futhark.IR.Rep.RepTypes rep) => Futhark.IR.Prop.Scope.HasScope rep (Control.Monad.Trans.Reader.ReaderT (Futhark.IR.Prop.Scope.Scope rep) m)
- Futhark.IR.Prop.Scope: instance (GHC.Base.Monad m, Futhark.IR.Rep.RepTypes rep) => Futhark.IR.Prop.Scope.LocalScope rep (Control.Monad.Trans.Reader.ReaderT (Futhark.IR.Prop.Scope.Scope rep) m)
- Futhark.IR.Prop.Scope: instance (GHC.Base.Monad m, GHC.Base.Monoid w, Futhark.IR.Rep.RepTypes rep) => Futhark.IR.Prop.Scope.HasScope rep (Control.Monad.Trans.RWS.Lazy.RWST (Futhark.IR.Prop.Scope.Scope rep) w s m)
- Futhark.IR.Prop.Scope: instance (GHC.Base.Monad m, GHC.Base.Monoid w, Futhark.IR.Rep.RepTypes rep) => Futhark.IR.Prop.Scope.HasScope rep (Control.Monad.Trans.RWS.Strict.RWST (Futhark.IR.Prop.Scope.Scope rep) w s m)
- Futhark.IR.Prop.Scope: instance (GHC.Base.Monad m, GHC.Base.Monoid w, Futhark.IR.Rep.RepTypes rep) => Futhark.IR.Prop.Scope.LocalScope rep (Control.Monad.Trans.RWS.Lazy.RWST (Futhark.IR.Prop.Scope.Scope rep) w s m)
- Futhark.IR.Prop.Scope: instance (GHC.Base.Monad m, GHC.Base.Monoid w, Futhark.IR.Rep.RepTypes rep) => Futhark.IR.Prop.Scope.LocalScope rep (Control.Monad.Trans.RWS.Strict.RWST (Futhark.IR.Prop.Scope.Scope rep) w s m)
- Futhark.IR.Prop.Scope: instance Futhark.IR.Prop.Scope.LocalScope rep m => Futhark.IR.Prop.Scope.LocalScope rep (Control.Monad.Trans.Except.ExceptT e m)
- Futhark.IR.Prop.Scope: instance Futhark.IR.Prop.Scope.Scoped rep (Futhark.IR.Syntax.FunDef rep)
- Futhark.IR.Prop.Scope: instance Futhark.IR.Prop.Scope.Scoped rep (Futhark.IR.Syntax.Lambda rep)
- Futhark.IR.Prop.Scope: instance Futhark.IR.Prop.Scope.Scoped rep (Futhark.IR.Syntax.Stm rep)
- Futhark.IR.Prop.Scope: instance Futhark.IR.Prop.Scope.Scoped rep (Futhark.IR.Syntax.Stms rep)
- Futhark.IR.Prop.Scope: instance Futhark.IR.Prop.Scope.Scoped rep (Language.Futhark.Core.VName, Futhark.IR.Prop.Scope.NameInfo rep)
- Futhark.IR.Prop.Scope: instance Futhark.IR.Prop.Scope.Scoped rep a => Futhark.IR.Prop.Scope.Scoped rep [a]
- Futhark.IR.Prop.Scope: instance Futhark.IR.Rep.RepTypes rep => Futhark.IR.Prop.Types.Typed (Futhark.IR.Prop.Scope.NameInfo rep)
- Futhark.IR.Prop.Scope: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.Prop.Scope.NameInfo rep)
- Futhark.IR.Prop.Scope: instance GHC.Base.Applicative m => GHC.Base.Applicative (Futhark.IR.Prop.Scope.ExtendedScope rep m)
- Futhark.IR.Prop.Scope: instance GHC.Base.Functor m => GHC.Base.Functor (Futhark.IR.Prop.Scope.ExtendedScope rep m)
- Futhark.IR.Prop.Scope: instance GHC.Base.Monad m => Control.Monad.Reader.Class.MonadReader (Futhark.IR.Prop.Scope.Scope rep) (Futhark.IR.Prop.Scope.ExtendedScope rep m)
- Futhark.IR.Prop.Scope: instance GHC.Base.Monad m => GHC.Base.Monad (Futhark.IR.Prop.Scope.ExtendedScope rep m)
- Futhark.IR.Prop.Scope: localScope :: LocalScope rep m => Scope rep -> m a -> m a
- Futhark.IR.Prop.Scope: lookupInfo :: HasScope rep m => VName -> m (NameInfo rep)
- Futhark.IR.Prop.Scope: lookupType :: HasScope rep m => VName -> m Type
- Futhark.IR.Prop.Scope: scopeOf :: Scoped rep a => a -> Scope rep
- Futhark.IR.Prop.Scope: scopeOfFParams :: FParamInfo rep ~ dec => [Param dec] -> Scope rep
- Futhark.IR.Prop.Scope: scopeOfLParams :: LParamInfo rep ~ dec => [Param dec] -> Scope rep
- Futhark.IR.Prop.Scope: scopeOfLoopForm :: LoopForm -> Scope rep
- Futhark.IR.Prop.Scope: scopeOfPat :: LetDec rep ~ dec => Pat dec -> Scope rep
- Futhark.IR.Prop.Scope: scopeOfPatElem :: LetDec rep ~ dec => PatElem dec -> Scope rep
- Futhark.IR.Prop.Scope: type SameScope rep1 rep2 = (LetDec rep1 ~ LetDec rep2, FParamInfo rep1 ~ FParamInfo rep2, LParamInfo rep1 ~ LParamInfo rep2)
- Futhark.IR.Prop.Scope: type Scope rep = Map VName NameInfo rep
- Futhark.IR.Prop.TypeOf: basicOpType :: HasScope rep m => BasicOp -> m [Type]
- Futhark.IR.Prop.TypeOf: class TypedOp (op :: Type -> Type)
- Futhark.IR.Prop.TypeOf: expExtType :: (HasScope rep m, TypedOp (OpC rep)) => Exp rep -> m [ExtType]
- Futhark.IR.Prop.TypeOf: instance Futhark.IR.Prop.TypeOf.TypedOp Futhark.IR.Rep.NoOp
- Futhark.IR.Prop.TypeOf: mapType :: SubExp -> Lambda rep -> [Type]
- Futhark.IR.Prop.TypeOf: opType :: (TypedOp op, HasScope rep m) => op rep -> m [ExtType]
- Futhark.IR.Prop.TypeOf: subExpResType :: HasScope t m => SubExpRes -> m Type
- Futhark.IR.Prop.TypeOf: subExpType :: HasScope t m => SubExp -> m Type
- Futhark.IR.Prop.Types: arrayDims :: TypeBase Shape u -> [SubExp]
- Futhark.IR.Prop.Types: arrayExtDims :: TypeBase ExtShape u -> [ExtSize]
- Futhark.IR.Prop.Types: arrayOf :: ArrayShape shape => TypeBase shape u_unused -> shape -> u -> TypeBase shape u
- Futhark.IR.Prop.Types: arrayOfRow :: ArrayShape (ShapeBase d) => TypeBase (ShapeBase d) NoUniqueness -> d -> TypeBase (ShapeBase d) NoUniqueness
- Futhark.IR.Prop.Types: arrayOfShape :: Type -> Shape -> Type
- Futhark.IR.Prop.Types: arrayRank :: ArrayShape shape => TypeBase shape u -> Int
- Futhark.IR.Prop.Types: arrayShape :: ArrayShape shape => TypeBase shape u -> shape
- Futhark.IR.Prop.Types: arraySize :: Int -> TypeBase Shape u -> SubExp
- Futhark.IR.Prop.Types: arraysSize :: Int -> [TypeBase Shape u] -> SubExp
- Futhark.IR.Prop.Types: class FixExt t => DeclExtTyped t
- Futhark.IR.Prop.Types: class DeclTyped t
- Futhark.IR.Prop.Types: class FixExt t => ExtTyped t
- Futhark.IR.Prop.Types: class FixExt t
- Futhark.IR.Prop.Types: class Typed t
- Futhark.IR.Prop.Types: declExtTypeOf :: DeclExtTyped t => t -> DeclExtType
- Futhark.IR.Prop.Types: declTypeOf :: DeclTyped t => t -> DeclType
- Futhark.IR.Prop.Types: diet :: TypeBase shape Uniqueness -> Diet
- Futhark.IR.Prop.Types: elemType :: TypeBase shape u -> PrimType
- Futhark.IR.Prop.Types: existential :: ExtType -> Bool
- Futhark.IR.Prop.Types: existentialiseExtTypes :: [VName] -> [ExtType] -> [ExtType]
- Futhark.IR.Prop.Types: extTypeOf :: ExtTyped t => t -> ExtType
- Futhark.IR.Prop.Types: extractShapeContext :: [TypeBase ExtShape u] -> [[a]] -> [a]
- Futhark.IR.Prop.Types: fixExt :: FixExt t => Int -> SubExp -> t -> t
- Futhark.IR.Prop.Types: float32 :: PrimType
- Futhark.IR.Prop.Types: float64 :: PrimType
- Futhark.IR.Prop.Types: fromDecl :: TypeBase shape Uniqueness -> TypeBase shape NoUniqueness
- Futhark.IR.Prop.Types: generaliseExtTypes :: [TypeBase ExtShape u] -> [TypeBase ExtShape u] -> [TypeBase ExtShape u]
- Futhark.IR.Prop.Types: hasStaticShape :: TypeBase ExtShape u -> Maybe (TypeBase Shape u)
- Futhark.IR.Prop.Types: instance (Futhark.IR.Prop.Types.FixExt shape, Futhark.IR.Syntax.Core.ArrayShape shape) => Futhark.IR.Prop.Types.FixExt (Futhark.IR.Syntax.Core.TypeBase shape u)
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.DeclExtTyped Futhark.IR.Syntax.Core.DeclExtType
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.DeclTyped Futhark.IR.Syntax.Core.DeclType
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.DeclTyped dec => Futhark.IR.Prop.Types.DeclTyped (Futhark.IR.Syntax.Core.Param dec)
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.ExtTyped Futhark.IR.Syntax.Core.DeclExtType
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.ExtTyped Futhark.IR.Syntax.Core.ExtType
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.FixExt ()
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.FixExt Futhark.IR.Syntax.Core.ExtSize
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.FixExt a => Futhark.IR.Prop.Types.FixExt [a]
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.FixExt d => Futhark.IR.Prop.Types.FixExt (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.Typed Futhark.IR.Syntax.Core.DeclType
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.Typed Futhark.IR.Syntax.Core.Ident
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.Typed Futhark.IR.Syntax.Core.Type
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.Typed b => Futhark.IR.Prop.Types.Typed (a, b)
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.Typed dec => Futhark.IR.Prop.Types.Typed (Futhark.IR.Syntax.Core.Param dec)
- Futhark.IR.Prop.Types: instance Futhark.IR.Prop.Types.Typed dec => Futhark.IR.Prop.Types.Typed (Futhark.IR.Syntax.Core.PatElem dec)
- Futhark.IR.Prop.Types: int16 :: PrimType
- Futhark.IR.Prop.Types: int32 :: PrimType
- Futhark.IR.Prop.Types: int64 :: PrimType
- Futhark.IR.Prop.Types: int8 :: PrimType
- Futhark.IR.Prop.Types: isAcc :: TypeBase shape u -> Bool
- Futhark.IR.Prop.Types: isEmptyArray :: Type -> Maybe (PrimType, Shape)
- Futhark.IR.Prop.Types: isExt :: Ext a -> Maybe Int
- Futhark.IR.Prop.Types: isFree :: Ext a -> Maybe a
- Futhark.IR.Prop.Types: mapExt :: FixExt t => (Int -> Int) -> t -> t
- Futhark.IR.Prop.Types: mapOnExtType :: Monad m => (SubExp -> m SubExp) -> TypeBase ExtShape u -> m (TypeBase ExtShape u)
- Futhark.IR.Prop.Types: mapOnType :: Monad m => (SubExp -> m SubExp) -> TypeBase Shape u -> m (TypeBase Shape u)
- Futhark.IR.Prop.Types: peelArray :: Int -> TypeBase Shape u -> Maybe (TypeBase Shape u)
- Futhark.IR.Prop.Types: primType :: TypeBase shape u -> Bool
- Futhark.IR.Prop.Types: rankShaped :: ArrayShape shape => TypeBase shape u -> TypeBase Rank u
- Futhark.IR.Prop.Types: rearrangeType :: [Int] -> Type -> Type
- Futhark.IR.Prop.Types: rowType :: TypeBase Shape u -> TypeBase Shape u
- Futhark.IR.Prop.Types: setArrayDims :: TypeBase oldshape u -> [SubExp] -> TypeBase Shape u
- Futhark.IR.Prop.Types: setArrayShape :: ArrayShape newshape => TypeBase oldshape u -> newshape -> TypeBase newshape u
- Futhark.IR.Prop.Types: setDim :: Int -> ShapeBase d -> d -> ShapeBase d
- Futhark.IR.Prop.Types: setDimSize :: ArrayShape (ShapeBase d) => Int -> TypeBase (ShapeBase d) u -> d -> TypeBase (ShapeBase d) u
- Futhark.IR.Prop.Types: setOuterDim :: ShapeBase d -> d -> ShapeBase d
- Futhark.IR.Prop.Types: setOuterDims :: ShapeBase d -> Int -> ShapeBase d -> ShapeBase d
- Futhark.IR.Prop.Types: setOuterSize :: ArrayShape (ShapeBase d) => TypeBase (ShapeBase d) u -> d -> TypeBase (ShapeBase d) u
- Futhark.IR.Prop.Types: shapeContext :: [TypeBase ExtShape u] -> Set Int
- Futhark.IR.Prop.Types: shapeExtMapping :: [TypeBase ExtShape u] -> [TypeBase Shape u1] -> Map Int SubExp
- Futhark.IR.Prop.Types: shapeSize :: Int -> Shape -> SubExp
- Futhark.IR.Prop.Types: staticShapes :: [TypeBase Shape u] -> [TypeBase ExtShape u]
- Futhark.IR.Prop.Types: staticShapes1 :: TypeBase Shape u -> TypeBase ExtShape u
- Futhark.IR.Prop.Types: stripArray :: Int -> TypeBase Shape u -> TypeBase Shape u
- Futhark.IR.Prop.Types: subtypeOf :: (Ord u, ArrayShape shape) => TypeBase shape u -> TypeBase shape u -> Bool
- Futhark.IR.Prop.Types: subtypesOf :: (Ord u, ArrayShape shape) => [TypeBase shape u] -> [TypeBase shape u] -> Bool
- Futhark.IR.Prop.Types: toDecl :: TypeBase shape NoUniqueness -> Uniqueness -> TypeBase shape Uniqueness
- Futhark.IR.Prop.Types: transposeType :: Type -> Type
- Futhark.IR.Prop.Types: typeOf :: Typed t => t -> Type
- Futhark.IR.Prop.Types: unique :: TypeBase shape Uniqueness -> Bool
- Futhark.IR.Prop.Types: uniqueness :: TypeBase shape Uniqueness -> Uniqueness
- Futhark.IR.Rep: -- definition is to ensure that we can change the "inner" representation
- Futhark.IR.Rep: -- in a generic way (e.g. add aliasing information) In most code, you
- Futhark.IR.Rep: -- will use the <a>Op</a> alias instead.
- Futhark.IR.Rep: -- | Type constructor for the extensible operation. The somewhat funky
- Futhark.IR.Rep: NoOp :: NoOp (rep :: k)
- Futhark.IR.Rep: class (Show LetDec l, Show ExpDec l, Show BodyDec l, Show FParamInfo l, Show LParamInfo l, Show RetType l, Show BranchType l, Show Op l, Eq LetDec l, Eq ExpDec l, Eq BodyDec l, Eq FParamInfo l, Eq LParamInfo l, Eq RetType l, Eq BranchType l, Eq Op l, Ord LetDec l, Ord ExpDec l, Ord BodyDec l, Ord FParamInfo l, Ord LParamInfo l, Ord RetType l, Ord BranchType l, Ord Op l, IsRetType RetType l, IsBodyType BranchType l, Typed FParamInfo l, Typed LParamInfo l, Typed LetDec l, DeclTyped FParamInfo l) => RepTypes l where {
- Futhark.IR.Rep: data NoOp (rep :: k)
- Futhark.IR.Rep: instance forall k (rep :: k). GHC.Classes.Eq (Futhark.IR.Rep.NoOp rep)
- Futhark.IR.Rep: instance forall k (rep :: k). GHC.Classes.Ord (Futhark.IR.Rep.NoOp rep)
- Futhark.IR.Rep: instance forall k (rep :: k). GHC.Show.Show (Futhark.IR.Rep.NoOp rep)
- Futhark.IR.Rep: type BodyDec l = ();
- Futhark.IR.Rep: type BranchType l = ExtType;
- Futhark.IR.Rep: type ExpDec l = ();
- Futhark.IR.Rep: type FParamInfo l = DeclType;
- Futhark.IR.Rep: type LParamInfo l = Type;
- Futhark.IR.Rep: type LetDec l = Type;
- Futhark.IR.Rep: type Op l = OpC l l
- Futhark.IR.Rep: type OpC l = NoOp :: Type -> Type;
- Futhark.IR.Rep: type RetType l = DeclExtType;
- Futhark.IR.Rep: }
- Futhark.IR.Rephrase: Rephraser :: (ExpDec from -> m (ExpDec to)) -> (LetDec from -> m (LetDec to)) -> (FParamInfo from -> m (FParamInfo to)) -> (LParamInfo from -> m (LParamInfo to)) -> (BodyDec from -> m (BodyDec to)) -> (RetType from -> m (RetType to)) -> (BranchType from -> m (BranchType to)) -> (Op from -> m (Op to)) -> Rephraser (m :: Type -> Type) from to
- Futhark.IR.Rephrase: [rephraseBodyDec] :: Rephraser (m :: Type -> Type) from to -> BodyDec from -> m (BodyDec to)
- Futhark.IR.Rephrase: [rephraseBranchType] :: Rephraser (m :: Type -> Type) from to -> BranchType from -> m (BranchType to)
- Futhark.IR.Rephrase: [rephraseExpDec] :: Rephraser (m :: Type -> Type) from to -> ExpDec from -> m (ExpDec to)
- Futhark.IR.Rephrase: [rephraseFParamDec] :: Rephraser (m :: Type -> Type) from to -> FParamInfo from -> m (FParamInfo to)
- Futhark.IR.Rephrase: [rephraseLParamDec] :: Rephraser (m :: Type -> Type) from to -> LParamInfo from -> m (LParamInfo to)
- Futhark.IR.Rephrase: [rephraseLetBoundDec] :: Rephraser (m :: Type -> Type) from to -> LetDec from -> m (LetDec to)
- Futhark.IR.Rephrase: [rephraseOp] :: Rephraser (m :: Type -> Type) from to -> Op from -> m (Op to)
- Futhark.IR.Rephrase: [rephraseRetType] :: Rephraser (m :: Type -> Type) from to -> RetType from -> m (RetType to)
- Futhark.IR.Rephrase: class RephraseOp (op :: Type -> Type)
- Futhark.IR.Rephrase: data Rephraser (m :: Type -> Type) from to
- Futhark.IR.Rephrase: instance Futhark.IR.Rephrase.RephraseOp Futhark.IR.Rep.NoOp
- Futhark.IR.Rephrase: rephraseBody :: Monad m => Rephraser m from to -> Body from -> m (Body to)
- Futhark.IR.Rephrase: rephraseExp :: Monad m => Rephraser m from to -> Exp from -> m (Exp to)
- Futhark.IR.Rephrase: rephraseFunDef :: Monad m => Rephraser m from to -> FunDef from -> m (FunDef to)
- Futhark.IR.Rephrase: rephraseInOp :: (RephraseOp op, Monad m) => Rephraser m from to -> op from -> m (op to)
- Futhark.IR.Rephrase: rephraseLambda :: Monad m => Rephraser m from to -> Lambda from -> m (Lambda to)
- Futhark.IR.Rephrase: rephrasePat :: Monad m => (from -> m to) -> Pat from -> m (Pat to)
- Futhark.IR.Rephrase: rephrasePatElem :: Monad m => (from -> m to) -> PatElem from -> m (PatElem to)
- Futhark.IR.Rephrase: rephraseProg :: Monad m => Rephraser m from to -> Prog from -> m (Prog to)
- Futhark.IR.Rephrase: rephraseStm :: Monad m => Rephraser m from to -> Stm from -> m (Stm to)
- Futhark.IR.RetType: applyRetType :: (IsRetType rt, Typed dec) => [rt] -> [Param dec] -> [(SubExp, Type)] -> Maybe [rt]
- Futhark.IR.RetType: class (Show rt, Eq rt, Ord rt, ExtTyped rt) => IsBodyType rt
- Futhark.IR.RetType: class (Show rt, Eq rt, Ord rt, ExtTyped rt, DeclExtTyped rt) => IsRetType rt
- Futhark.IR.RetType: expectedTypes :: Typed t => [VName] -> [t] -> [SubExp] -> [Type]
- Futhark.IR.RetType: instance Futhark.IR.RetType.IsBodyType Futhark.IR.Syntax.Core.ExtType
- Futhark.IR.RetType: instance Futhark.IR.RetType.IsRetType Futhark.IR.Syntax.Core.DeclExtType
- Futhark.IR.RetType: primBodyType :: IsBodyType rt => PrimType -> rt
- Futhark.IR.RetType: primRetType :: IsRetType rt => PrimType -> rt
- Futhark.IR.SOACS: data SOACS
- Futhark.IR.SOACS: instance Futhark.Builder.BuilderOps Futhark.IR.SOACS.SOACS
- Futhark.IR.SOACS: instance Futhark.Builder.Class.Buildable Futhark.IR.SOACS.SOACS
- Futhark.IR.SOACS: instance Futhark.IR.Pretty.PrettyRep Futhark.IR.SOACS.SOACS
- Futhark.IR.SOACS: instance Futhark.IR.Prop.ASTRep Futhark.IR.SOACS.SOACS
- Futhark.IR.SOACS: instance Futhark.IR.Rep.RepTypes Futhark.IR.SOACS.SOACS
- Futhark.IR.SOACS: instance Futhark.IR.TypeCheck.Checkable Futhark.IR.SOACS.SOACS
- Futhark.IR.SOACS: usesAD :: Prog SOACS -> Bool
- Futhark.IR.SOACS.SOAC: Hist :: SubExp -> [VName] -> [HistOp rep] -> Lambda rep -> SOAC rep
- Futhark.IR.SOACS.SOAC: HistOp :: Shape -> SubExp -> [VName] -> [SubExp] -> Lambda rep -> HistOp rep
- Futhark.IR.SOACS.SOAC: JVP :: [SubExp] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.IR.SOACS.SOAC: Reduce :: Commutativity -> Lambda rep -> [SubExp] -> Reduce rep
- Futhark.IR.SOACS.SOAC: SOACMapper :: (SubExp -> m SubExp) -> (Lambda frep -> m (Lambda trep)) -> (VName -> m VName) -> SOACMapper frep trep (m :: Type -> Type)
- Futhark.IR.SOACS.SOAC: Scan :: Lambda rep -> [SubExp] -> Scan rep
- Futhark.IR.SOACS.SOAC: Scatter :: SubExp -> [VName] -> ScatterSpec VName -> Lambda rep -> SOAC rep
- Futhark.IR.SOACS.SOAC: Screma :: SubExp -> [VName] -> ScremaForm rep -> SOAC rep
- Futhark.IR.SOACS.SOAC: ScremaForm :: Lambda rep -> [Scan rep] -> [Reduce rep] -> ScremaForm rep
- Futhark.IR.SOACS.SOAC: Stream :: SubExp -> [VName] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.IR.SOACS.SOAC: VJP :: [SubExp] -> [SubExp] -> Lambda rep -> SOAC rep
- Futhark.IR.SOACS.SOAC: [histDest] :: HistOp rep -> [VName]
- Futhark.IR.SOACS.SOAC: [histNeutral] :: HistOp rep -> [SubExp]
- Futhark.IR.SOACS.SOAC: [histOp] :: HistOp rep -> Lambda rep
- Futhark.IR.SOACS.SOAC: [histRaceFactor] :: HistOp rep -> SubExp
- Futhark.IR.SOACS.SOAC: [histShape] :: HistOp rep -> Shape
- Futhark.IR.SOACS.SOAC: [mapOnSOACLambda] :: SOACMapper frep trep (m :: Type -> Type) -> Lambda frep -> m (Lambda trep)
- Futhark.IR.SOACS.SOAC: [mapOnSOACSubExp] :: SOACMapper frep trep (m :: Type -> Type) -> SubExp -> m SubExp
- Futhark.IR.SOACS.SOAC: [mapOnSOACVName] :: SOACMapper frep trep (m :: Type -> Type) -> VName -> m VName
- Futhark.IR.SOACS.SOAC: [redComm] :: Reduce rep -> Commutativity
- Futhark.IR.SOACS.SOAC: [redLambda] :: Reduce rep -> Lambda rep
- Futhark.IR.SOACS.SOAC: [redNeutral] :: Reduce rep -> [SubExp]
- Futhark.IR.SOACS.SOAC: [scanLambda] :: Scan rep -> Lambda rep
- Futhark.IR.SOACS.SOAC: [scanNeutral] :: Scan rep -> [SubExp]
- Futhark.IR.SOACS.SOAC: [scremaLambda] :: ScremaForm rep -> Lambda rep
- Futhark.IR.SOACS.SOAC: [scremaReduces] :: ScremaForm rep -> [Reduce rep]
- Futhark.IR.SOACS.SOAC: [scremaScans] :: ScremaForm rep -> [Scan rep]
- Futhark.IR.SOACS.SOAC: data HistOp rep
- Futhark.IR.SOACS.SOAC: data Reduce rep
- Futhark.IR.SOACS.SOAC: data SOAC rep
- Futhark.IR.SOACS.SOAC: data SOACMapper frep trep (m :: Type -> Type)
- Futhark.IR.SOACS.SOAC: data Scan rep
- Futhark.IR.SOACS.SOAC: data ScremaForm rep
- Futhark.IR.SOACS.SOAC: groupScatterResults :: ScatterSpec array -> [a] -> [(Shape, array, [([a], a)])]
- Futhark.IR.SOACS.SOAC: groupScatterResults' :: [(Shape, Int, array)] -> [a] -> [([a], a)]
- Futhark.IR.SOACS.SOAC: identitySOACMapper :: forall rep (m :: Type -> Type). Monad m => SOACMapper rep rep m
- Futhark.IR.SOACS.SOAC: instance Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.Rep.Op rep) => Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.SOACS.SOAC.SOAC rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Aliases.CanBeAliased Futhark.IR.SOACS.SOAC.SOAC
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.SOACS.SOAC.Reduce rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.SOACS.SOAC.SOAC rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.SOACS.SOAC.Scan rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.SOACS.SOAC.HistOp rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.SOACS.SOAC.Reduce rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.SOACS.SOAC.SOAC rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.SOACS.SOAC.Scan rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.SOACS.SOAC.ScremaForm rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.ASTRep rep => Futhark.Transform.Rename.Rename (Futhark.IR.SOACS.SOAC.SOAC rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.ASTRep rep => Futhark.Transform.Substitute.Substitute (Futhark.IR.SOACS.SOAC.SOAC rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.Aliases.AliasedOp Futhark.IR.SOACS.SOAC.SOAC
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.IsOp Futhark.IR.SOACS.SOAC.SOAC
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Prop.TypeOf.TypedOp Futhark.IR.SOACS.SOAC.SOAC
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => Futhark.Analysis.SymbolTable.IndexOp (Futhark.IR.SOACS.SOAC.SOAC rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.SOACS.SOAC.HistOp rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.SOACS.SOAC.Reduce rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.SOACS.SOAC.SOAC rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.SOACS.SOAC.Scan rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.SOACS.SOAC.ScremaForm rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.SOACS.SOAC.HistOp rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.SOACS.SOAC.Reduce rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.SOACS.SOAC.SOAC rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.SOACS.SOAC.Scan rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.SOACS.SOAC.ScremaForm rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.SOACS.SOAC.HistOp rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.SOACS.SOAC.Reduce rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.SOACS.SOAC.SOAC rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.SOACS.SOAC.Scan rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.SOACS.SOAC.ScremaForm rep)
- Futhark.IR.SOACS.SOAC: instance Futhark.IR.Rephrase.RephraseOp Futhark.IR.SOACS.SOAC.SOAC
- Futhark.IR.SOACS.SOAC: instance Futhark.Optimise.Simplify.Rep.CanBeWise Futhark.IR.SOACS.SOAC.SOAC
- Futhark.IR.SOACS.SOAC: isIdentityLambda :: Lambda rep -> Bool
- Futhark.IR.SOACS.SOAC: isMapSOAC :: ScremaForm rep -> Maybe (Lambda rep)
- Futhark.IR.SOACS.SOAC: isRedomapSOAC :: ScremaForm rep -> Maybe ([Reduce rep], Lambda rep)
- Futhark.IR.SOACS.SOAC: isReduceSOAC :: ScremaForm rep -> Maybe [Reduce rep]
- Futhark.IR.SOACS.SOAC: isScanSOAC :: ScremaForm rep -> Maybe [Scan rep]
- Futhark.IR.SOACS.SOAC: isScanomapSOAC :: ScremaForm rep -> Maybe ([Scan rep], Lambda rep)
- Futhark.IR.SOACS.SOAC: mapSOAC :: Lambda rep -> ScremaForm rep
- Futhark.IR.SOACS.SOAC: mapSOACM :: Monad m => SOACMapper frep trep m -> SOAC frep -> m (SOAC trep)
- Futhark.IR.SOACS.SOAC: mkIdentityLambda :: (Buildable rep, MonadFreshNames m) => [Type] -> m (Lambda rep)
- Futhark.IR.SOACS.SOAC: nilFn :: Buildable rep => Lambda rep
- Futhark.IR.SOACS.SOAC: ppHist :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> [HistOp rep] -> Lambda rep -> Doc ann
- Futhark.IR.SOACS.SOAC: ppScatter :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> [(Shape, Int, VName)] -> Lambda rep -> Doc ann
- Futhark.IR.SOACS.SOAC: ppScrema :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> ScremaForm rep -> Doc ann
- Futhark.IR.SOACS.SOAC: ppStream :: (PrettyRep rep, Pretty inp) => SubExp -> [inp] -> [SubExp] -> Lambda rep -> Doc ann
- Futhark.IR.SOACS.SOAC: redResults :: [Reduce rep] -> Int
- Futhark.IR.SOACS.SOAC: redomapSOAC :: [Reduce rep] -> Lambda rep -> ScremaForm rep
- Futhark.IR.SOACS.SOAC: reduceSOAC :: (Buildable rep, MonadFreshNames m) => [Reduce rep] -> m (ScremaForm rep)
- Futhark.IR.SOACS.SOAC: scanResults :: [Scan rep] -> Int
- Futhark.IR.SOACS.SOAC: scanSOAC :: (Buildable rep, MonadFreshNames m) => [Scan rep] -> m (ScremaForm rep)
- Futhark.IR.SOACS.SOAC: scanomapSOAC :: [Scan rep] -> Lambda rep -> ScremaForm rep
- Futhark.IR.SOACS.SOAC: scremaType :: SubExp -> ScremaForm rep -> [Type]
- Futhark.IR.SOACS.SOAC: singleReduce :: Buildable rep => [Reduce rep] -> Reduce rep
- Futhark.IR.SOACS.SOAC: singleScan :: Buildable rep => [Scan rep] -> Scan rep
- Futhark.IR.SOACS.SOAC: soacType :: Typed (LParamInfo rep) => SOAC rep -> [Type]
- Futhark.IR.SOACS.SOAC: splitScatterResults :: [(Shape, Int, array)] -> [a] -> ([a], [a])
- Futhark.IR.SOACS.SOAC: traverseSOACStms :: Monad m => OpStmsTraverser m (SOAC rep) rep
- Futhark.IR.SOACS.SOAC: type ScatterSpec v = [(Shape, Int, v)]
- Futhark.IR.SOACS.SOAC: typeCheckSOAC :: Checkable rep => SOAC (Aliases rep) -> TypeM rep ()
- Futhark.IR.SOACS.Simplify: asSOAC :: HasSOAC rep => Op rep -> Maybe (SOAC rep)
- Futhark.IR.SOACS.Simplify: class HasSOAC rep
- Futhark.IR.SOACS.Simplify: data SOACS
- Futhark.IR.SOACS.Simplify: instance Futhark.Builder.BuilderOps (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.SOACS.SOACS)
- Futhark.IR.SOACS.Simplify: instance Futhark.IR.SOACS.Simplify.HasSOAC (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.SOACS.SOACS)
- Futhark.IR.SOACS.Simplify: instance Futhark.IR.Traversals.TraverseOpStms (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.SOACS.SOACS)
- Futhark.IR.SOACS.Simplify: instance GHC.Classes.Eq Futhark.IR.SOACS.Simplify.ArrayOp
- Futhark.IR.SOACS.Simplify: instance GHC.Classes.Ord Futhark.IR.SOACS.Simplify.ArrayOp
- Futhark.IR.SOACS.Simplify: instance GHC.Show.Show Futhark.IR.SOACS.Simplify.ArrayOp
- Futhark.IR.SOACS.Simplify: liftIdentityMapping :: (Buildable rep, BuilderOps rep, HasSOAC rep) => TopDownRuleOp rep
- Futhark.IR.SOACS.Simplify: removeReplicateMapping :: (Aliased rep, BuilderOps rep, HasSOAC rep) => TopDownRuleOp rep
- Futhark.IR.SOACS.Simplify: removeUnusedSOACInput :: (Aliased rep, Buildable rep, BuilderOps rep, HasSOAC rep) => TopDownRuleOp rep
- Futhark.IR.SOACS.Simplify: simpleSOACS :: SimpleOps SOACS
- Futhark.IR.SOACS.Simplify: simplifyConsts :: MonadFreshNames m => Stms SOACS -> m (Stms SOACS)
- Futhark.IR.SOACS.Simplify: simplifyFun :: MonadFreshNames m => SymbolTable (Wise SOACS) -> FunDef SOACS -> m (FunDef SOACS)
- Futhark.IR.SOACS.Simplify: simplifyKnownIterationSOAC :: (Buildable rep, BuilderOps rep, HasSOAC rep) => TopDownRuleOp rep
- Futhark.IR.SOACS.Simplify: simplifyLambda :: (HasScope SOACS m, MonadFreshNames m) => Lambda SOACS -> m (Lambda SOACS)
- Futhark.IR.SOACS.Simplify: simplifyMapIota :: (Buildable rep, BuilderOps rep, HasSOAC rep) => TopDownRuleOp rep
- Futhark.IR.SOACS.Simplify: simplifySOAC :: SimplifiableRep rep => SimplifyOp rep (SOAC (Wise rep))
- Futhark.IR.SOACS.Simplify: simplifySOACS :: Prog SOACS -> PassM (Prog SOACS)
- Futhark.IR.SOACS.Simplify: simplifyStms :: (HasScope SOACS m, MonadFreshNames m) => Stms SOACS -> m (Stms SOACS)
- Futhark.IR.SOACS.Simplify: soacOp :: HasSOAC rep => SOAC rep -> Op rep
- Futhark.IR.SOACS.Simplify: soacRules :: RuleBook (Wise SOACS)
- Futhark.IR.SegOp: HistOp :: Shape -> SubExp -> [VName] -> [SubExp] -> Shape -> Lambda rep -> HistOp rep
- Futhark.IR.SegOp: KernelBody :: BodyDec rep -> Stms rep -> [KernelResult] -> KernelBody rep
- Futhark.IR.SegOp: RegTileReturns :: Certs -> [(SubExp, SubExp, SubExp)] -> VName -> KernelResult
- Futhark.IR.SegOp: ResultMaySimplify :: ResultManifest
- Futhark.IR.SegOp: ResultNoSimplify :: ResultManifest
- Futhark.IR.SegOp: ResultPrivate :: ResultManifest
- Futhark.IR.SegOp: Returns :: ResultManifest -> Certs -> SubExp -> KernelResult
- Futhark.IR.SegOp: SegBinOp :: Commutativity -> Lambda rep -> [SubExp] -> Shape -> SegBinOp rep
- Futhark.IR.SegOp: SegHist :: lvl -> SegSpace -> [Type] -> KernelBody rep -> [HistOp rep] -> SegOp lvl rep
- Futhark.IR.SegOp: SegMap :: lvl -> SegSpace -> [Type] -> KernelBody rep -> SegOp lvl rep
- Futhark.IR.SegOp: SegOpMapper :: (SubExp -> m SubExp) -> (Lambda frep -> m (Lambda trep)) -> (KernelBody frep -> m (KernelBody trep)) -> (VName -> m VName) -> (lvl -> m lvl) -> SegOpMapper lvl frep trep (m :: Type -> Type)
- Futhark.IR.SegOp: SegRed :: lvl -> SegSpace -> [Type] -> KernelBody rep -> [SegBinOp rep] -> SegOp lvl rep
- Futhark.IR.SegOp: SegScan :: lvl -> SegSpace -> [Type] -> KernelBody rep -> [SegBinOp rep] -> SegOp lvl rep
- Futhark.IR.SegOp: SegSpace :: VName -> [(VName, SubExp)] -> SegSpace
- Futhark.IR.SegOp: TileReturns :: Certs -> [(SubExp, SubExp)] -> VName -> KernelResult
- Futhark.IR.SegOp: WriteReturns :: Certs -> VName -> [(Slice SubExp, SubExp)] -> KernelResult
- Futhark.IR.SegOp: [histDest] :: HistOp rep -> [VName]
- Futhark.IR.SegOp: [histNeutral] :: HistOp rep -> [SubExp]
- Futhark.IR.SegOp: [histOpShape] :: HistOp rep -> Shape
- Futhark.IR.SegOp: [histOp] :: HistOp rep -> Lambda rep
- Futhark.IR.SegOp: [histRaceFactor] :: HistOp rep -> SubExp
- Futhark.IR.SegOp: [histShape] :: HistOp rep -> Shape
- Futhark.IR.SegOp: [kernelBodyDec] :: KernelBody rep -> BodyDec rep
- Futhark.IR.SegOp: [kernelBodyResult] :: KernelBody rep -> [KernelResult]
- Futhark.IR.SegOp: [kernelBodyStms] :: KernelBody rep -> Stms rep
- Futhark.IR.SegOp: [mapOnSegOpBody] :: SegOpMapper lvl frep trep (m :: Type -> Type) -> KernelBody frep -> m (KernelBody trep)
- Futhark.IR.SegOp: [mapOnSegOpLambda] :: SegOpMapper lvl frep trep (m :: Type -> Type) -> Lambda frep -> m (Lambda trep)
- Futhark.IR.SegOp: [mapOnSegOpLevel] :: SegOpMapper lvl frep trep (m :: Type -> Type) -> lvl -> m lvl
- Futhark.IR.SegOp: [mapOnSegOpSubExp] :: SegOpMapper lvl frep trep (m :: Type -> Type) -> SubExp -> m SubExp
- Futhark.IR.SegOp: [mapOnSegOpVName] :: SegOpMapper lvl frep trep (m :: Type -> Type) -> VName -> m VName
- Futhark.IR.SegOp: [segBinOpComm] :: SegBinOp rep -> Commutativity
- Futhark.IR.SegOp: [segBinOpLambda] :: SegBinOp rep -> Lambda rep
- Futhark.IR.SegOp: [segBinOpNeutral] :: SegBinOp rep -> [SubExp]
- Futhark.IR.SegOp: [segBinOpShape] :: SegBinOp rep -> Shape
- Futhark.IR.SegOp: [segFlat] :: SegSpace -> VName
- Futhark.IR.SegOp: [unSegSpace] :: SegSpace -> [(VName, SubExp)]
- Futhark.IR.SegOp: aliasAnalyseKernelBody :: AliasableRep rep => AliasTable -> KernelBody rep -> KernelBody (Aliases rep)
- Futhark.IR.SegOp: asSegOp :: HasSegOp rep => Op rep -> Maybe (SegOp (SegOpLevel rep) rep)
- Futhark.IR.SegOp: class HasSegOp rep where {
- Futhark.IR.SegOp: consumedInKernelBody :: Aliased rep => KernelBody rep -> Names
- Futhark.IR.SegOp: data HistOp rep
- Futhark.IR.SegOp: data KernelBody rep
- Futhark.IR.SegOp: data KernelResult
- Futhark.IR.SegOp: data ResultManifest
- Futhark.IR.SegOp: data SegBinOp rep
- Futhark.IR.SegOp: data SegOp lvl rep
- Futhark.IR.SegOp: data SegOpMapper lvl frep trep (m :: Type -> Type)
- Futhark.IR.SegOp: data SegSpace
- Futhark.IR.SegOp: histType :: HistOp rep -> [Type]
- Futhark.IR.SegOp: identitySegOpMapper :: forall (m :: Type -> Type) lvl rep. Monad m => SegOpMapper lvl rep rep m
- Futhark.IR.SegOp: instance (Futhark.IR.Pretty.PrettyRep rep, Prettyprinter.Internal.Pretty lvl) => Prettyprinter.Internal.Pretty (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.IR.SegOp: instance (Futhark.IR.Prop.ASTRep rep, Futhark.IR.Prop.ASTConstraints lvl) => Futhark.Transform.Rename.Rename (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.IR.SegOp: instance (Futhark.IR.Prop.ASTRep rep, Futhark.IR.Prop.Names.FreeIn lvl) => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.IR.SegOp: instance (Futhark.IR.Prop.ASTRep rep, Futhark.Transform.Substitute.Substitute lvl) => Futhark.Transform.Substitute.Substitute (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.IR.SegOp: instance (Futhark.IR.Rep.RepTypes rep, GHC.Classes.Eq lvl) => GHC.Classes.Eq (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.IR.SegOp: instance (Futhark.IR.Rep.RepTypes rep, GHC.Classes.Ord lvl) => GHC.Classes.Ord (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.IR.SegOp: instance (Futhark.IR.Rep.RepTypes rep, GHC.Show.Show lvl) => GHC.Show.Show (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.IR.SegOp: instance Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.Rep.Op rep) => Futhark.Analysis.Metrics.OpMetrics (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.IR.SegOp: instance Futhark.IR.Aliases.CanBeAliased (Futhark.IR.SegOp.SegOp lvl)
- Futhark.IR.SegOp: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.SegOp.KernelBody rep)
- Futhark.IR.SegOp: instance Futhark.IR.Pretty.PrettyRep rep => Prettyprinter.Internal.Pretty (Futhark.IR.SegOp.SegBinOp rep)
- Futhark.IR.SegOp: instance Futhark.IR.Prop.ASTConstraints lvl => Futhark.IR.Prop.Aliases.AliasedOp (Futhark.IR.SegOp.SegOp lvl)
- Futhark.IR.SegOp: instance Futhark.IR.Prop.ASTConstraints lvl => Futhark.IR.Prop.IsOp (Futhark.IR.SegOp.SegOp lvl)
- Futhark.IR.SegOp: instance Futhark.IR.Prop.ASTRep rep => Futhark.Analysis.SymbolTable.IndexOp (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.IR.SegOp: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Names.FreeIn (Futhark.IR.SegOp.KernelBody rep)
- Futhark.IR.SegOp: instance Futhark.IR.Prop.ASTRep rep => Futhark.Transform.Rename.Rename (Futhark.IR.SegOp.KernelBody rep)
- Futhark.IR.SegOp: instance Futhark.IR.Prop.ASTRep rep => Futhark.Transform.Substitute.Substitute (Futhark.IR.SegOp.KernelBody rep)
- Futhark.IR.SegOp: instance Futhark.IR.Prop.Names.FreeIn Futhark.IR.SegOp.KernelResult
- Futhark.IR.SegOp: instance Futhark.IR.Prop.TypeOf.TypedOp (Futhark.IR.SegOp.SegOp lvl)
- Futhark.IR.SegOp: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.SegOp.HistOp rep)
- Futhark.IR.SegOp: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.SegOp.KernelBody rep)
- Futhark.IR.SegOp: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.SegOp.SegBinOp rep)
- Futhark.IR.SegOp: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.SegOp.HistOp rep)
- Futhark.IR.SegOp: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.SegOp.KernelBody rep)
- Futhark.IR.SegOp: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.SegOp.SegBinOp rep)
- Futhark.IR.SegOp: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.SegOp.HistOp rep)
- Futhark.IR.SegOp: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.SegOp.KernelBody rep)
- Futhark.IR.SegOp: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.SegOp.SegBinOp rep)
- Futhark.IR.SegOp: instance Futhark.IR.Rephrase.RephraseOp (Futhark.IR.SegOp.SegOp lvl)
- Futhark.IR.SegOp: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.SegOp.KernelResult
- Futhark.IR.SegOp: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.SegOp.SegSpace
- Futhark.IR.SegOp: instance Futhark.Optimise.Simplify.Rep.CanBeWise (Futhark.IR.SegOp.SegOp lvl)
- Futhark.IR.SegOp: instance Futhark.Transform.Rename.Rename Futhark.IR.SegOp.KernelResult
- Futhark.IR.SegOp: instance Futhark.Transform.Substitute.Substitute Futhark.IR.SegOp.KernelResult
- Futhark.IR.SegOp: instance GHC.Classes.Eq Futhark.IR.SegOp.KernelResult
- Futhark.IR.SegOp: instance GHC.Classes.Eq Futhark.IR.SegOp.ResultManifest
- Futhark.IR.SegOp: instance GHC.Classes.Eq Futhark.IR.SegOp.SegSpace
- Futhark.IR.SegOp: instance GHC.Classes.Ord Futhark.IR.SegOp.KernelResult
- Futhark.IR.SegOp: instance GHC.Classes.Ord Futhark.IR.SegOp.ResultManifest
- Futhark.IR.SegOp: instance GHC.Classes.Ord Futhark.IR.SegOp.SegSpace
- Futhark.IR.SegOp: instance GHC.Show.Show Futhark.IR.SegOp.KernelResult
- Futhark.IR.SegOp: instance GHC.Show.Show Futhark.IR.SegOp.ResultManifest
- Futhark.IR.SegOp: instance GHC.Show.Show Futhark.IR.SegOp.SegSpace
- Futhark.IR.SegOp: instance Prettyprinter.Internal.Pretty Futhark.IR.SegOp.KernelResult
- Futhark.IR.SegOp: instance Prettyprinter.Internal.Pretty Futhark.IR.SegOp.SegSpace
- Futhark.IR.SegOp: kernelResultCerts :: KernelResult -> Certs
- Futhark.IR.SegOp: kernelResultSubExp :: KernelResult -> SubExp
- Futhark.IR.SegOp: mapSegOpM :: Monad m => SegOpMapper lvl frep trep m -> SegOp lvl frep -> m (SegOp lvl trep)
- Futhark.IR.SegOp: scopeOfSegSpace :: SegSpace -> Scope rep
- Futhark.IR.SegOp: segBinOpChunks :: [SegBinOp rep] -> [a] -> [[a]]
- Futhark.IR.SegOp: segBinOpResults :: [SegBinOp rep] -> Int
- Futhark.IR.SegOp: segBody :: SegOp lvl rep -> KernelBody rep
- Futhark.IR.SegOp: segLevel :: SegOp lvl rep -> lvl
- Futhark.IR.SegOp: segOp :: HasSegOp rep => SegOp (SegOpLevel rep) rep -> Op rep
- Futhark.IR.SegOp: segOpReturns :: forall rep (inner :: Type -> Type) m lvl. (Mem rep inner, Monad m, HasScope rep m) => SegOp lvl rep -> m [ExpReturns]
- Futhark.IR.SegOp: segOpRules :: (HasSegOp rep, BuilderOps rep, Buildable rep, Aliased rep) => RuleBook rep
- Futhark.IR.SegOp: segSpace :: SegOp lvl rep -> SegSpace
- Futhark.IR.SegOp: segSpaceDims :: SegSpace -> [SubExp]
- Futhark.IR.SegOp: simplifySegOp :: (SimplifiableRep rep, BodyDec rep ~ (), Simplifiable lvl) => SegOp lvl (Wise rep) -> SimpleM rep (SegOp lvl (Wise rep), Stms (Wise rep))
- Futhark.IR.SegOp: splitHistResults :: [HistOp rep] -> [SubExp] -> [([SubExp], [SubExp])]
- Futhark.IR.SegOp: traverseSegOpStms :: Monad m => OpStmsTraverser m (SegOp lvl rep) rep
- Futhark.IR.SegOp: type SegOpLevel rep;
- Futhark.IR.SegOp: typeCheckSegOp :: Checkable rep => (lvl -> TypeM rep ()) -> SegOp lvl (Aliases rep) -> TypeM rep ()
- Futhark.IR.SegOp: }
- Futhark.IR.Seq: data Seq
- Futhark.IR.Seq: instance Futhark.Builder.BuilderOps (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.Seq.Seq)
- Futhark.IR.Seq: instance Futhark.Builder.BuilderOps Futhark.IR.Seq.Seq
- Futhark.IR.Seq: instance Futhark.Builder.Class.Buildable Futhark.IR.Seq.Seq
- Futhark.IR.Seq: instance Futhark.IR.Pretty.PrettyRep Futhark.IR.Seq.Seq
- Futhark.IR.Seq: instance Futhark.IR.Prop.ASTRep Futhark.IR.Seq.Seq
- Futhark.IR.Seq: instance Futhark.IR.Rep.RepTypes Futhark.IR.Seq.Seq
- Futhark.IR.Seq: instance Futhark.IR.Traversals.TraverseOpStms (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.Seq.Seq)
- Futhark.IR.Seq: instance Futhark.IR.Traversals.TraverseOpStms Futhark.IR.Seq.Seq
- Futhark.IR.Seq: instance Futhark.IR.TypeCheck.Checkable Futhark.IR.Seq.Seq
- Futhark.IR.Seq: simplifyProg :: Prog Seq -> PassM (Prog Seq)
- Futhark.IR.SeqMem: data SeqMem
- Futhark.IR.SeqMem: instance Futhark.Builder.BuilderOps (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.SeqMem.SeqMem)
- Futhark.IR.SeqMem: instance Futhark.Builder.BuilderOps Futhark.IR.SeqMem.SeqMem
- Futhark.IR.SeqMem: instance Futhark.IR.Pretty.PrettyRep Futhark.IR.SeqMem.SeqMem
- Futhark.IR.SeqMem: instance Futhark.IR.Prop.ASTRep Futhark.IR.SeqMem.SeqMem
- Futhark.IR.SeqMem: instance Futhark.IR.Rep.RepTypes Futhark.IR.SeqMem.SeqMem
- Futhark.IR.SeqMem: instance Futhark.IR.Traversals.TraverseOpStms (Futhark.Optimise.Simplify.Rep.Wise Futhark.IR.SeqMem.SeqMem)
- Futhark.IR.SeqMem: instance Futhark.IR.Traversals.TraverseOpStms Futhark.IR.SeqMem.SeqMem
- Futhark.IR.SeqMem: instance Futhark.IR.TypeCheck.Checkable Futhark.IR.SeqMem.SeqMem
- Futhark.IR.SeqMem: simpleSeqMem :: SimpleOps SeqMem
- Futhark.IR.SeqMem: simplifyProg :: Prog SeqMem -> PassM (Prog SeqMem)
- Futhark.IR.Syntax: AShr :: IntType -> BinOp
- Futhark.IR.Syntax: Abs :: IntType -> UnOp
- Futhark.IR.Syntax: Acc :: VName -> Shape -> [Type] -> u -> TypeBase shape u
- Futhark.IR.Syntax: Add :: IntType -> Overflow -> BinOp
- Futhark.IR.Syntax: And :: IntType -> BinOp
- Futhark.IR.Syntax: Apply :: Name -> [(SubExp, Diet)] -> [(RetType rep, RetAls)] -> (Safety, SrcLoc, [SrcLoc]) -> Exp rep
- Futhark.IR.Syntax: Array :: PrimType -> shape -> u -> TypeBase shape u
- Futhark.IR.Syntax: ArrayLit :: [SubExp] -> Type -> BasicOp
- Futhark.IR.Syntax: ArrayVal :: [PrimValue] -> PrimType -> BasicOp
- Futhark.IR.Syntax: Assert :: SubExp -> ErrorMsg SubExp -> (SrcLoc, [SrcLoc]) -> BasicOp
- Futhark.IR.Syntax: BToF :: FloatType -> ConvOp
- Futhark.IR.Syntax: BToI :: IntType -> ConvOp
- Futhark.IR.Syntax: BasicOp :: BasicOp -> Exp rep
- Futhark.IR.Syntax: BinOp :: BinOp -> SubExp -> SubExp -> BasicOp
- Futhark.IR.Syntax: Body :: BodyDec rep -> Stms rep -> Result -> Body rep
- Futhark.IR.Syntax: Case :: [Maybe PrimValue] -> body -> Case body
- Futhark.IR.Syntax: CmpEq :: PrimType -> CmpOp
- Futhark.IR.Syntax: CmpLle :: CmpOp
- Futhark.IR.Syntax: CmpLlt :: CmpOp
- Futhark.IR.Syntax: CmpOp :: CmpOp -> SubExp -> SubExp -> BasicOp
- Futhark.IR.Syntax: CmpSle :: IntType -> CmpOp
- Futhark.IR.Syntax: CmpSlt :: IntType -> CmpOp
- Futhark.IR.Syntax: CmpUle :: IntType -> CmpOp
- Futhark.IR.Syntax: CmpUlt :: IntType -> CmpOp
- Futhark.IR.Syntax: Complement :: IntType -> UnOp
- Futhark.IR.Syntax: Concat :: Int -> NonEmpty VName -> SubExp -> BasicOp
- Futhark.IR.Syntax: Constant :: PrimValue -> SubExp
- Futhark.IR.Syntax: Consume :: Diet
- Futhark.IR.Syntax: ConvOp :: ConvOp -> SubExp -> BasicOp
- Futhark.IR.Syntax: DefaultSpace :: Space
- Futhark.IR.Syntax: DimSplice :: Int -> Int -> ShapeBase d -> DimSplice d
- Futhark.IR.Syntax: EntryParam :: Name -> Uniqueness -> EntryPointType -> EntryParam
- Futhark.IR.Syntax: EntryResult :: Uniqueness -> EntryPointType -> EntryResult
- Futhark.IR.Syntax: FAbs :: FloatType -> UnOp
- Futhark.IR.Syntax: FAdd :: FloatType -> BinOp
- Futhark.IR.Syntax: FCmpLe :: FloatType -> CmpOp
- Futhark.IR.Syntax: FCmpLt :: FloatType -> CmpOp
- Futhark.IR.Syntax: FDiv :: FloatType -> BinOp
- Futhark.IR.Syntax: FMax :: FloatType -> BinOp
- Futhark.IR.Syntax: FMin :: FloatType -> BinOp
- Futhark.IR.Syntax: FMod :: FloatType -> BinOp
- Futhark.IR.Syntax: FMul :: FloatType -> BinOp
- Futhark.IR.Syntax: FPConv :: FloatType -> FloatType -> ConvOp
- Futhark.IR.Syntax: FPToSI :: FloatType -> IntType -> ConvOp
- Futhark.IR.Syntax: FPToUI :: FloatType -> IntType -> ConvOp
- Futhark.IR.Syntax: FPow :: FloatType -> BinOp
- Futhark.IR.Syntax: FSignum :: FloatType -> UnOp
- Futhark.IR.Syntax: FSub :: FloatType -> BinOp
- Futhark.IR.Syntax: FToB :: FloatType -> ConvOp
- Futhark.IR.Syntax: FlatIndex :: VName -> FlatSlice SubExp -> BasicOp
- Futhark.IR.Syntax: FlatUpdate :: VName -> FlatSlice SubExp -> VName -> BasicOp
- Futhark.IR.Syntax: ForLoop :: VName -> IntType -> SubExp -> LoopForm
- Futhark.IR.Syntax: FunDef :: Maybe EntryPoint -> Attrs -> Name -> [(RetType rep, RetAls)] -> [FParam rep] -> Body rep -> FunDef rep
- Futhark.IR.Syntax: IToB :: IntType -> ConvOp
- Futhark.IR.Syntax: Ident :: VName -> Type -> Ident
- Futhark.IR.Syntax: Index :: VName -> Slice SubExp -> BasicOp
- Futhark.IR.Syntax: Iota :: SubExp -> SubExp -> SubExp -> IntType -> BasicOp
- Futhark.IR.Syntax: LShr :: IntType -> BinOp
- Futhark.IR.Syntax: Lambda :: [LParam rep] -> [Type] -> Body rep -> Lambda rep
- Futhark.IR.Syntax: Let :: Pat (LetDec rep) -> StmAux (ExpDec rep) -> Exp rep -> Stm rep
- Futhark.IR.Syntax: LogAnd :: BinOp
- Futhark.IR.Syntax: LogOr :: BinOp
- Futhark.IR.Syntax: Loop :: [(FParam rep, SubExp)] -> LoopForm -> Body rep -> Exp rep
- Futhark.IR.Syntax: Manifest :: VName -> [Int] -> BasicOp
- Futhark.IR.Syntax: Match :: [SubExp] -> [Case (Body rep)] -> Body rep -> MatchDec (BranchType rep) -> Exp rep
- Futhark.IR.Syntax: MatchDec :: [rt] -> MatchSort -> MatchDec rt
- Futhark.IR.Syntax: MatchEquiv :: MatchSort
- Futhark.IR.Syntax: MatchFallback :: MatchSort
- Futhark.IR.Syntax: MatchNormal :: MatchSort
- Futhark.IR.Syntax: Mem :: Space -> TypeBase shape u
- Futhark.IR.Syntax: Mul :: IntType -> Overflow -> BinOp
- Futhark.IR.Syntax: Neg :: PrimType -> UnOp
- Futhark.IR.Syntax: NewShape :: [DimSplice d] -> ShapeBase d -> NewShape d
- Futhark.IR.Syntax: NoUniqueness :: NoUniqueness
- Futhark.IR.Syntax: Nonunique :: Uniqueness
- Futhark.IR.Syntax: Observe :: Diet
- Futhark.IR.Syntax: ObservePrim :: Diet
- Futhark.IR.Syntax: Op :: Op rep -> Exp rep
- Futhark.IR.Syntax: Opaque :: OpaqueOp -> SubExp -> BasicOp
- Futhark.IR.Syntax: OpaqueNil :: OpaqueOp
- Futhark.IR.Syntax: OpaqueTrace :: Text -> OpaqueOp
- Futhark.IR.Syntax: Or :: IntType -> BinOp
- Futhark.IR.Syntax: Param :: Attrs -> VName -> dec -> Param dec
- Futhark.IR.Syntax: Pat :: [PatElem dec] -> Pat dec
- Futhark.IR.Syntax: PatElem :: VName -> dec -> PatElem dec
- Futhark.IR.Syntax: Pow :: IntType -> BinOp
- Futhark.IR.Syntax: Prim :: PrimType -> TypeBase shape u
- Futhark.IR.Syntax: Prog :: OpaqueTypes -> Stms rep -> [FunDef rep] -> Prog rep
- Futhark.IR.Syntax: Rank :: Int -> Rank
- Futhark.IR.Syntax: Rearrange :: VName -> [Int] -> BasicOp
- Futhark.IR.Syntax: Replicate :: Shape -> SubExp -> BasicOp
- Futhark.IR.Syntax: Reshape :: VName -> NewShape SubExp -> BasicOp
- Futhark.IR.Syntax: RetAls :: [Int] -> [Int] -> RetAls
- Futhark.IR.Syntax: SDiv :: IntType -> Safety -> BinOp
- Futhark.IR.Syntax: SDivUp :: IntType -> Safety -> BinOp
- Futhark.IR.Syntax: SExt :: IntType -> IntType -> ConvOp
- Futhark.IR.Syntax: SIToFP :: IntType -> FloatType -> ConvOp
- Futhark.IR.Syntax: SMax :: IntType -> BinOp
- Futhark.IR.Syntax: SMin :: IntType -> BinOp
- Futhark.IR.Syntax: SMod :: IntType -> Safety -> BinOp
- Futhark.IR.Syntax: SQuot :: IntType -> Safety -> BinOp
- Futhark.IR.Syntax: SRem :: IntType -> Safety -> BinOp
- Futhark.IR.Syntax: SSignum :: IntType -> UnOp
- Futhark.IR.Syntax: Safe :: Safety
- Futhark.IR.Syntax: ScalarSpace :: [SubExp] -> PrimType -> Space
- Futhark.IR.Syntax: Scratch :: PrimType -> [SubExp] -> BasicOp
- Futhark.IR.Syntax: Shl :: IntType -> BinOp
- Futhark.IR.Syntax: Space :: SpaceId -> Space
- Futhark.IR.Syntax: StmAux :: !Certs -> Attrs -> dec -> StmAux dec
- Futhark.IR.Syntax: Sub :: IntType -> Overflow -> BinOp
- Futhark.IR.Syntax: SubExp :: SubExp -> BasicOp
- Futhark.IR.Syntax: SubExpRes :: Certs -> SubExp -> SubExpRes
- Futhark.IR.Syntax: UDiv :: IntType -> Safety -> BinOp
- Futhark.IR.Syntax: UDivUp :: IntType -> Safety -> BinOp
- Futhark.IR.Syntax: UIToFP :: IntType -> FloatType -> ConvOp
- Futhark.IR.Syntax: UMax :: IntType -> BinOp
- Futhark.IR.Syntax: UMin :: IntType -> BinOp
- Futhark.IR.Syntax: UMod :: IntType -> Safety -> BinOp
- Futhark.IR.Syntax: USignum :: IntType -> UnOp
- Futhark.IR.Syntax: UnOp :: UnOp -> SubExp -> BasicOp
- Futhark.IR.Syntax: Unique :: Uniqueness
- Futhark.IR.Syntax: Unsafe :: Safety
- Futhark.IR.Syntax: Update :: Safety -> VName -> Slice SubExp -> SubExp -> BasicOp
- Futhark.IR.Syntax: UpdateAcc :: Safety -> VName -> [SubExp] -> [SubExp] -> BasicOp
- Futhark.IR.Syntax: Var :: VName -> SubExp
- Futhark.IR.Syntax: WhileLoop :: VName -> LoopForm
- Futhark.IR.Syntax: WithAcc :: [WithAccInput rep] -> Lambda rep -> Exp rep
- Futhark.IR.Syntax: Xor :: IntType -> BinOp
- Futhark.IR.Syntax: ZExt :: IntType -> IntType -> ConvOp
- Futhark.IR.Syntax: [bodyDec] :: Body rep -> BodyDec rep
- Futhark.IR.Syntax: [bodyResult] :: Body rep -> Result
- Futhark.IR.Syntax: [bodyStms] :: Body rep -> Stms rep
- Futhark.IR.Syntax: [caseBody] :: Case body -> body
- Futhark.IR.Syntax: [casePat] :: Case body -> [Maybe PrimValue]
- Futhark.IR.Syntax: [dimSplices] :: NewShape d -> [DimSplice d]
- Futhark.IR.Syntax: [entryParamName] :: EntryParam -> Name
- Futhark.IR.Syntax: [entryParamType] :: EntryParam -> EntryPointType
- Futhark.IR.Syntax: [entryParamUniqueness] :: EntryParam -> Uniqueness
- Futhark.IR.Syntax: [entryResultType] :: EntryResult -> EntryPointType
- Futhark.IR.Syntax: [entryResultUniqueness] :: EntryResult -> Uniqueness
- Futhark.IR.Syntax: [funDefAttrs] :: FunDef rep -> Attrs
- Futhark.IR.Syntax: [funDefBody] :: FunDef rep -> Body rep
- Futhark.IR.Syntax: [funDefEntryPoint] :: FunDef rep -> Maybe EntryPoint
- Futhark.IR.Syntax: [funDefName] :: FunDef rep -> Name
- Futhark.IR.Syntax: [funDefParams] :: FunDef rep -> [FParam rep]
- Futhark.IR.Syntax: [funDefRetType] :: FunDef rep -> [(RetType rep, RetAls)]
- Futhark.IR.Syntax: [identName] :: Ident -> VName
- Futhark.IR.Syntax: [identType] :: Ident -> Type
- Futhark.IR.Syntax: [lambdaBody] :: Lambda rep -> Body rep
- Futhark.IR.Syntax: [lambdaParams] :: Lambda rep -> [LParam rep]
- Futhark.IR.Syntax: [lambdaReturnType] :: Lambda rep -> [Type]
- Futhark.IR.Syntax: [matchReturns] :: MatchDec rt -> [rt]
- Futhark.IR.Syntax: [matchSort] :: MatchDec rt -> MatchSort
- Futhark.IR.Syntax: [newShape] :: NewShape d -> ShapeBase d
- Futhark.IR.Syntax: [otherAls] :: RetAls -> [Int]
- Futhark.IR.Syntax: [paramAls] :: RetAls -> [Int]
- Futhark.IR.Syntax: [paramAttrs] :: Param dec -> Attrs
- Futhark.IR.Syntax: [paramDec] :: Param dec -> dec
- Futhark.IR.Syntax: [paramName] :: Param dec -> VName
- Futhark.IR.Syntax: [patElemDec] :: PatElem dec -> dec
- Futhark.IR.Syntax: [patElemName] :: PatElem dec -> VName
- Futhark.IR.Syntax: [patElems] :: Pat dec -> [PatElem dec]
- Futhark.IR.Syntax: [progConsts] :: Prog rep -> Stms rep
- Futhark.IR.Syntax: [progFuns] :: Prog rep -> [FunDef rep]
- Futhark.IR.Syntax: [progTypes] :: Prog rep -> OpaqueTypes
- Futhark.IR.Syntax: [resCerts] :: SubExpRes -> Certs
- Futhark.IR.Syntax: [resSubExp] :: SubExpRes -> SubExp
- Futhark.IR.Syntax: [stmAuxAttrs] :: StmAux dec -> Attrs
- Futhark.IR.Syntax: [stmAuxCerts] :: StmAux dec -> !Certs
- Futhark.IR.Syntax: [stmAuxDec] :: StmAux dec -> dec
- Futhark.IR.Syntax: [stmAux] :: Stm rep -> StmAux (ExpDec rep)
- Futhark.IR.Syntax: [stmExp] :: Stm rep -> Exp rep
- Futhark.IR.Syntax: [stmPat] :: Stm rep -> Pat (LetDec rep)
- Futhark.IR.Syntax: class (Monoid a, Eq a, Ord a) => ArrayShape a
- Futhark.IR.Syntax: class Pretty a
- Futhark.IR.Syntax: data BasicOp
- Futhark.IR.Syntax: data BinOp
- Futhark.IR.Syntax: data Body rep
- Futhark.IR.Syntax: data Case body
- Futhark.IR.Syntax: data CmpOp
- Futhark.IR.Syntax: data ConvOp
- Futhark.IR.Syntax: data Diet
- Futhark.IR.Syntax: data DimSplice d
- Futhark.IR.Syntax: data EntryParam
- Futhark.IR.Syntax: data EntryResult
- Futhark.IR.Syntax: data Exp rep
- Futhark.IR.Syntax: data FunDef rep
- Futhark.IR.Syntax: data Ident
- Futhark.IR.Syntax: data Lambda rep
- Futhark.IR.Syntax: data LoopForm
- Futhark.IR.Syntax: data MatchDec rt
- Futhark.IR.Syntax: data MatchSort
- Futhark.IR.Syntax: data NewShape d
- Futhark.IR.Syntax: data NoUniqueness
- Futhark.IR.Syntax: data OpaqueOp
- Futhark.IR.Syntax: data Param dec
- Futhark.IR.Syntax: data PatElem dec
- Futhark.IR.Syntax: data Prog rep
- Futhark.IR.Syntax: data RetAls
- Futhark.IR.Syntax: data Safety
- Futhark.IR.Syntax: data Space
- Futhark.IR.Syntax: data Stm rep
- Futhark.IR.Syntax: data StmAux dec
- Futhark.IR.Syntax: data SubExp
- Futhark.IR.Syntax: data SubExpRes
- Futhark.IR.Syntax: data TypeBase shape u
- Futhark.IR.Syntax: data UnOp
- Futhark.IR.Syntax: data Uniqueness
- Futhark.IR.Syntax: instance Data.Foldable.Foldable Futhark.IR.Syntax.Case
- Futhark.IR.Syntax: instance Data.Foldable.Foldable Futhark.IR.Syntax.DimSplice
- Futhark.IR.Syntax: instance Data.Foldable.Foldable Futhark.IR.Syntax.NewShape
- Futhark.IR.Syntax: instance Data.Foldable.Foldable Futhark.IR.Syntax.Pat
- Futhark.IR.Syntax: instance Data.Traversable.Traversable Futhark.IR.Syntax.Case
- Futhark.IR.Syntax: instance Data.Traversable.Traversable Futhark.IR.Syntax.DimSplice
- Futhark.IR.Syntax: instance Data.Traversable.Traversable Futhark.IR.Syntax.NewShape
- Futhark.IR.Syntax: instance Data.Traversable.Traversable Futhark.IR.Syntax.Pat
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.Syntax.Body rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.Syntax.Exp rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.Syntax.FunDef rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.Syntax.Lambda rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.Syntax.Prog rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Eq (Futhark.IR.Syntax.Stm rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.Syntax.Body rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.Syntax.Exp rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.Syntax.FunDef rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.Syntax.Lambda rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.Syntax.Prog rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Classes.Ord (Futhark.IR.Syntax.Stm rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.Syntax.Body rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.Syntax.Exp rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.Syntax.FunDef rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.Syntax.Lambda rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.Syntax.Prog rep)
- Futhark.IR.Syntax: instance Futhark.IR.Rep.RepTypes rep => GHC.Show.Show (Futhark.IR.Syntax.Stm rep)
- Futhark.IR.Syntax: instance GHC.Base.Functor Futhark.IR.Syntax.Case
- Futhark.IR.Syntax: instance GHC.Base.Functor Futhark.IR.Syntax.DimSplice
- Futhark.IR.Syntax: instance GHC.Base.Functor Futhark.IR.Syntax.NewShape
- Futhark.IR.Syntax: instance GHC.Base.Functor Futhark.IR.Syntax.Pat
- Futhark.IR.Syntax: instance GHC.Base.Monoid (Futhark.IR.Syntax.Pat dec)
- Futhark.IR.Syntax: instance GHC.Base.Monoid Futhark.IR.Syntax.RetAls
- Futhark.IR.Syntax: instance GHC.Base.Monoid dec => GHC.Base.Monoid (Futhark.IR.Syntax.StmAux dec)
- Futhark.IR.Syntax: instance GHC.Base.Semigroup (Futhark.IR.Syntax.NewShape d)
- Futhark.IR.Syntax: instance GHC.Base.Semigroup (Futhark.IR.Syntax.Pat dec)
- Futhark.IR.Syntax: instance GHC.Base.Semigroup Futhark.IR.Syntax.RetAls
- Futhark.IR.Syntax: instance GHC.Base.Semigroup dec => GHC.Base.Semigroup (Futhark.IR.Syntax.StmAux dec)
- Futhark.IR.Syntax: instance GHC.Classes.Eq Futhark.IR.Syntax.BasicOp
- Futhark.IR.Syntax: instance GHC.Classes.Eq Futhark.IR.Syntax.EntryParam
- Futhark.IR.Syntax: instance GHC.Classes.Eq Futhark.IR.Syntax.EntryResult
- Futhark.IR.Syntax: instance GHC.Classes.Eq Futhark.IR.Syntax.LoopForm
- Futhark.IR.Syntax: instance GHC.Classes.Eq Futhark.IR.Syntax.MatchSort
- Futhark.IR.Syntax: instance GHC.Classes.Eq Futhark.IR.Syntax.OpaqueOp
- Futhark.IR.Syntax: instance GHC.Classes.Eq Futhark.IR.Syntax.RetAls
- Futhark.IR.Syntax: instance GHC.Classes.Eq Futhark.IR.Syntax.SubExpRes
- Futhark.IR.Syntax: instance GHC.Classes.Eq body => GHC.Classes.Eq (Futhark.IR.Syntax.Case body)
- Futhark.IR.Syntax: instance GHC.Classes.Eq d => GHC.Classes.Eq (Futhark.IR.Syntax.DimSplice d)
- Futhark.IR.Syntax: instance GHC.Classes.Eq d => GHC.Classes.Eq (Futhark.IR.Syntax.NewShape d)
- Futhark.IR.Syntax: instance GHC.Classes.Eq dec => GHC.Classes.Eq (Futhark.IR.Syntax.Pat dec)
- Futhark.IR.Syntax: instance GHC.Classes.Eq dec => GHC.Classes.Eq (Futhark.IR.Syntax.StmAux dec)
- Futhark.IR.Syntax: instance GHC.Classes.Eq rt => GHC.Classes.Eq (Futhark.IR.Syntax.MatchDec rt)
- Futhark.IR.Syntax: instance GHC.Classes.Ord Futhark.IR.Syntax.BasicOp
- Futhark.IR.Syntax: instance GHC.Classes.Ord Futhark.IR.Syntax.EntryParam
- Futhark.IR.Syntax: instance GHC.Classes.Ord Futhark.IR.Syntax.EntryResult
- Futhark.IR.Syntax: instance GHC.Classes.Ord Futhark.IR.Syntax.LoopForm
- Futhark.IR.Syntax: instance GHC.Classes.Ord Futhark.IR.Syntax.MatchSort
- Futhark.IR.Syntax: instance GHC.Classes.Ord Futhark.IR.Syntax.OpaqueOp
- Futhark.IR.Syntax: instance GHC.Classes.Ord Futhark.IR.Syntax.RetAls
- Futhark.IR.Syntax: instance GHC.Classes.Ord Futhark.IR.Syntax.SubExpRes
- Futhark.IR.Syntax: instance GHC.Classes.Ord body => GHC.Classes.Ord (Futhark.IR.Syntax.Case body)
- Futhark.IR.Syntax: instance GHC.Classes.Ord d => GHC.Classes.Ord (Futhark.IR.Syntax.DimSplice d)
- Futhark.IR.Syntax: instance GHC.Classes.Ord d => GHC.Classes.Ord (Futhark.IR.Syntax.NewShape d)
- Futhark.IR.Syntax: instance GHC.Classes.Ord dec => GHC.Classes.Ord (Futhark.IR.Syntax.Pat dec)
- Futhark.IR.Syntax: instance GHC.Classes.Ord dec => GHC.Classes.Ord (Futhark.IR.Syntax.StmAux dec)
- Futhark.IR.Syntax: instance GHC.Classes.Ord rt => GHC.Classes.Ord (Futhark.IR.Syntax.MatchDec rt)
- Futhark.IR.Syntax: instance GHC.Show.Show Futhark.IR.Syntax.BasicOp
- Futhark.IR.Syntax: instance GHC.Show.Show Futhark.IR.Syntax.EntryParam
- Futhark.IR.Syntax: instance GHC.Show.Show Futhark.IR.Syntax.EntryResult
- Futhark.IR.Syntax: instance GHC.Show.Show Futhark.IR.Syntax.LoopForm
- Futhark.IR.Syntax: instance GHC.Show.Show Futhark.IR.Syntax.MatchSort
- Futhark.IR.Syntax: instance GHC.Show.Show Futhark.IR.Syntax.OpaqueOp
- Futhark.IR.Syntax: instance GHC.Show.Show Futhark.IR.Syntax.RetAls
- Futhark.IR.Syntax: instance GHC.Show.Show Futhark.IR.Syntax.SubExpRes
- Futhark.IR.Syntax: instance GHC.Show.Show body => GHC.Show.Show (Futhark.IR.Syntax.Case body)
- Futhark.IR.Syntax: instance GHC.Show.Show d => GHC.Show.Show (Futhark.IR.Syntax.DimSplice d)
- Futhark.IR.Syntax: instance GHC.Show.Show d => GHC.Show.Show (Futhark.IR.Syntax.NewShape d)
- Futhark.IR.Syntax: instance GHC.Show.Show dec => GHC.Show.Show (Futhark.IR.Syntax.Pat dec)
- Futhark.IR.Syntax: instance GHC.Show.Show dec => GHC.Show.Show (Futhark.IR.Syntax.StmAux dec)
- Futhark.IR.Syntax: instance GHC.Show.Show rt => GHC.Show.Show (Futhark.IR.Syntax.MatchDec rt)
- Futhark.IR.Syntax: newtype Pat dec
- Futhark.IR.Syntax: newtype Rank
- Futhark.IR.Syntax: oneStm :: Stm rep -> Stms rep
- Futhark.IR.Syntax: prettyString :: Pretty a => a -> String
- Futhark.IR.Syntax: prettyStringOneLine :: Pretty a => a -> String
- Futhark.IR.Syntax: prettyText :: Pretty a => a -> Text
- Futhark.IR.Syntax: prettyTextOneLine :: Pretty a => a -> Text
- Futhark.IR.Syntax: shapeRank :: ArrayShape a => a -> Int
- Futhark.IR.Syntax: stmsFromList :: [Stm rep] -> Stms rep
- Futhark.IR.Syntax: stmsHead :: Stms rep -> Maybe (Stm rep, Stms rep)
- Futhark.IR.Syntax: stmsLast :: Stms lore -> Maybe (Stms lore, Stm lore)
- Futhark.IR.Syntax: stmsToList :: Stms rep -> [Stm rep]
- Futhark.IR.Syntax: subExpRes :: SubExp -> SubExpRes
- Futhark.IR.Syntax: subExpResVName :: SubExpRes -> Maybe VName
- Futhark.IR.Syntax: subExpsRes :: [SubExp] -> Result
- Futhark.IR.Syntax: subShapeOf :: ArrayShape a => a -> a -> Bool
- Futhark.IR.Syntax: type EntryPoint = (Name, [EntryParam], [EntryResult])
- Futhark.IR.Syntax: type FParam rep = Param FParamInfo rep
- Futhark.IR.Syntax: type LParam rep = Param LParamInfo rep
- Futhark.IR.Syntax: type Result = [SubExpRes]
- Futhark.IR.Syntax: type Stms rep = Seq Stm rep
- Futhark.IR.Syntax: type WithAccInput rep = (Shape, [VName], Maybe (Lambda rep, [SubExp]))
- Futhark.IR.Syntax: varRes :: VName -> SubExpRes
- Futhark.IR.Syntax: varsRes :: [VName] -> Result
- Futhark.IR.Syntax.Core: Acc :: VName -> Shape -> [Type] -> u -> TypeBase shape u
- Futhark.IR.Syntax.Core: Array :: PrimType -> shape -> u -> TypeBase shape u
- Futhark.IR.Syntax.Core: AttrComp :: Name -> [Attr] -> Attr
- Futhark.IR.Syntax.Core: AttrInt :: Integer -> Attr
- Futhark.IR.Syntax.Core: AttrName :: Name -> Attr
- Futhark.IR.Syntax.Core: Attrs :: Set Attr -> Attrs
- Futhark.IR.Syntax.Core: BoolValue :: !Bool -> PrimValue
- Futhark.IR.Syntax.Core: Certs :: [VName] -> Certs
- Futhark.IR.Syntax.Core: Commutative :: Commutativity
- Futhark.IR.Syntax.Core: Constant :: PrimValue -> SubExp
- Futhark.IR.Syntax.Core: Consume :: Diet
- Futhark.IR.Syntax.Core: DefaultSpace :: Space
- Futhark.IR.Syntax.Core: DimFix :: d -> DimIndex d
- Futhark.IR.Syntax.Core: DimSlice :: d -> d -> d -> DimIndex d
- Futhark.IR.Syntax.Core: ErrorMsg :: [ErrorMsgPart a] -> ErrorMsg a
- Futhark.IR.Syntax.Core: ErrorString :: Text -> ErrorMsgPart a
- Futhark.IR.Syntax.Core: ErrorVal :: PrimType -> a -> ErrorMsgPart a
- Futhark.IR.Syntax.Core: Ext :: Int -> Ext a
- Futhark.IR.Syntax.Core: FlatDimIndex :: d -> d -> FlatDimIndex d
- Futhark.IR.Syntax.Core: FlatSlice :: d -> [FlatDimIndex d] -> FlatSlice d
- Futhark.IR.Syntax.Core: FloatValue :: !FloatValue -> PrimValue
- Futhark.IR.Syntax.Core: Free :: a -> Ext a
- Futhark.IR.Syntax.Core: Ident :: VName -> Type -> Ident
- Futhark.IR.Syntax.Core: IntValue :: !IntValue -> PrimValue
- Futhark.IR.Syntax.Core: Mem :: Space -> TypeBase shape u
- Futhark.IR.Syntax.Core: Noncommutative :: Commutativity
- Futhark.IR.Syntax.Core: Nonunique :: Uniqueness
- Futhark.IR.Syntax.Core: Observe :: Diet
- Futhark.IR.Syntax.Core: ObservePrim :: Diet
- Futhark.IR.Syntax.Core: OpaqueArray :: Int -> Name -> [ValueType] -> OpaqueType
- Futhark.IR.Syntax.Core: OpaqueRecord :: [(Name, EntryPointType)] -> OpaqueType
- Futhark.IR.Syntax.Core: OpaqueRecordArray :: Int -> Name -> [(Name, EntryPointType)] -> OpaqueType
- Futhark.IR.Syntax.Core: OpaqueSum :: [ValueType] -> [(Name, [(EntryPointType, [Int])])] -> OpaqueType
- Futhark.IR.Syntax.Core: OpaqueType :: [ValueType] -> OpaqueType
- Futhark.IR.Syntax.Core: OpaqueTypes :: [(Name, OpaqueType)] -> OpaqueTypes
- Futhark.IR.Syntax.Core: Param :: Attrs -> VName -> dec -> Param dec
- Futhark.IR.Syntax.Core: PatElem :: VName -> dec -> PatElem dec
- Futhark.IR.Syntax.Core: Prim :: PrimType -> TypeBase shape u
- Futhark.IR.Syntax.Core: Rank :: Int -> Rank
- Futhark.IR.Syntax.Core: ScalarSpace :: [SubExp] -> PrimType -> Space
- Futhark.IR.Syntax.Core: Shape :: [d] -> ShapeBase d
- Futhark.IR.Syntax.Core: Signed :: Signedness
- Futhark.IR.Syntax.Core: Slice :: [DimIndex d] -> Slice d
- Futhark.IR.Syntax.Core: Space :: SpaceId -> Space
- Futhark.IR.Syntax.Core: TypeOpaque :: Name -> EntryPointType
- Futhark.IR.Syntax.Core: TypeTransparent :: ValueType -> EntryPointType
- Futhark.IR.Syntax.Core: Unique :: Uniqueness
- Futhark.IR.Syntax.Core: UnitValue :: PrimValue
- Futhark.IR.Syntax.Core: Unsigned :: Signedness
- Futhark.IR.Syntax.Core: ValueType :: Signedness -> Rank -> PrimType -> ValueType
- Futhark.IR.Syntax.Core: Var :: VName -> SubExp
- Futhark.IR.Syntax.Core: [identName] :: Ident -> VName
- Futhark.IR.Syntax.Core: [identType] :: Ident -> Type
- Futhark.IR.Syntax.Core: [paramAttrs] :: Param dec -> Attrs
- Futhark.IR.Syntax.Core: [paramDec] :: Param dec -> dec
- Futhark.IR.Syntax.Core: [paramName] :: Param dec -> VName
- Futhark.IR.Syntax.Core: [patElemDec] :: PatElem dec -> dec
- Futhark.IR.Syntax.Core: [patElemName] :: PatElem dec -> VName
- Futhark.IR.Syntax.Core: [shapeDims] :: ShapeBase d -> [d]
- Futhark.IR.Syntax.Core: [unAttrs] :: Attrs -> Set Attr
- Futhark.IR.Syntax.Core: [unCerts] :: Certs -> [VName]
- Futhark.IR.Syntax.Core: [unSlice] :: Slice d -> [DimIndex d]
- Futhark.IR.Syntax.Core: class (Monoid a, Eq a, Ord a) => ArrayShape a
- Futhark.IR.Syntax.Core: data Attr
- Futhark.IR.Syntax.Core: data Commutativity
- Futhark.IR.Syntax.Core: data Diet
- Futhark.IR.Syntax.Core: data DimIndex d
- Futhark.IR.Syntax.Core: data EntryPointType
- Futhark.IR.Syntax.Core: data ErrorMsgPart a
- Futhark.IR.Syntax.Core: data Ext a
- Futhark.IR.Syntax.Core: data FlatDimIndex d
- Futhark.IR.Syntax.Core: data FlatSlice d
- Futhark.IR.Syntax.Core: data Ident
- Futhark.IR.Syntax.Core: data OpaqueType
- Futhark.IR.Syntax.Core: data Param dec
- Futhark.IR.Syntax.Core: data PatElem dec
- Futhark.IR.Syntax.Core: data PrimValue
- Futhark.IR.Syntax.Core: data Signedness
- Futhark.IR.Syntax.Core: data Space
- Futhark.IR.Syntax.Core: data SubExp
- Futhark.IR.Syntax.Core: data TypeBase shape u
- Futhark.IR.Syntax.Core: data Uniqueness
- Futhark.IR.Syntax.Core: data ValueType
- Futhark.IR.Syntax.Core: dimFix :: DimIndex d -> Maybe d
- Futhark.IR.Syntax.Core: dropDims :: Int -> ShapeBase d -> ShapeBase d
- Futhark.IR.Syntax.Core: errorMsgArgTypes :: ErrorMsg a -> [PrimType]
- Futhark.IR.Syntax.Core: fixSlice :: Num d => Slice d -> [d] -> [d]
- Futhark.IR.Syntax.Core: flatSliceDims :: FlatSlice d -> [d]
- Futhark.IR.Syntax.Core: flatSliceStrides :: FlatSlice d -> [d]
- Futhark.IR.Syntax.Core: inAttrs :: Attr -> Attrs -> Bool
- Futhark.IR.Syntax.Core: instance (GHC.Classes.Eq shape, GHC.Classes.Eq u) => GHC.Classes.Eq (Futhark.IR.Syntax.Core.TypeBase shape u)
- Futhark.IR.Syntax.Core: instance (GHC.Classes.Ord shape, GHC.Classes.Ord u) => GHC.Classes.Ord (Futhark.IR.Syntax.Core.TypeBase shape u)
- Futhark.IR.Syntax.Core: instance (GHC.Show.Show shape, GHC.Show.Show u) => GHC.Show.Show (Futhark.IR.Syntax.Core.TypeBase shape u)
- Futhark.IR.Syntax.Core: instance Data.Bifoldable.Bifoldable Futhark.IR.Syntax.Core.TypeBase
- Futhark.IR.Syntax.Core: instance Data.Bifunctor.Bifunctor Futhark.IR.Syntax.Core.TypeBase
- Futhark.IR.Syntax.Core: instance Data.Bitraversable.Bitraversable Futhark.IR.Syntax.Core.TypeBase
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable (Futhark.IR.Syntax.Core.TypeBase shape)
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.DimIndex
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.ErrorMsg
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.ErrorMsgPart
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.Ext
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.FlatDimIndex
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.FlatSlice
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.Param
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.PatElem
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.ShapeBase
- Futhark.IR.Syntax.Core: instance Data.Foldable.Foldable Futhark.IR.Syntax.Core.Slice
- Futhark.IR.Syntax.Core: instance Data.String.IsString (Futhark.IR.Syntax.Core.ErrorMsg a)
- Futhark.IR.Syntax.Core: instance Data.String.IsString (Futhark.IR.Syntax.Core.ErrorMsgPart a)
- Futhark.IR.Syntax.Core: instance Data.String.IsString Futhark.IR.Syntax.Core.Attr
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable (Futhark.IR.Syntax.Core.TypeBase shape)
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.DimIndex
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.ErrorMsg
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.ErrorMsgPart
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.Ext
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.FlatDimIndex
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.FlatSlice
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.Param
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.PatElem
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.ShapeBase
- Futhark.IR.Syntax.Core: instance Data.Traversable.Traversable Futhark.IR.Syntax.Core.Slice
- Futhark.IR.Syntax.Core: instance Futhark.IR.Syntax.Core.ArrayShape (Futhark.IR.Syntax.Core.ShapeBase Futhark.IR.Syntax.Core.ExtSize)
- Futhark.IR.Syntax.Core: instance Futhark.IR.Syntax.Core.ArrayShape (Futhark.IR.Syntax.Core.ShapeBase Futhark.IR.Syntax.Core.SubExp)
- Futhark.IR.Syntax.Core: instance Futhark.IR.Syntax.Core.ArrayShape Futhark.IR.Syntax.Core.Rank
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor (Futhark.IR.Syntax.Core.TypeBase shape)
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.DimIndex
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.ErrorMsg
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.ErrorMsgPart
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.Ext
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.FlatDimIndex
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.FlatSlice
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.Param
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.PatElem
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.ShapeBase
- Futhark.IR.Syntax.Core: instance GHC.Base.Functor Futhark.IR.Syntax.Core.Slice
- Futhark.IR.Syntax.Core: instance GHC.Base.Monoid (Futhark.IR.Syntax.Core.ErrorMsg a)
- Futhark.IR.Syntax.Core: instance GHC.Base.Monoid (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.IR.Syntax.Core: instance GHC.Base.Monoid Futhark.IR.Syntax.Core.Attrs
- Futhark.IR.Syntax.Core: instance GHC.Base.Monoid Futhark.IR.Syntax.Core.Certs
- Futhark.IR.Syntax.Core: instance GHC.Base.Monoid Futhark.IR.Syntax.Core.Commutativity
- Futhark.IR.Syntax.Core: instance GHC.Base.Monoid Futhark.IR.Syntax.Core.OpaqueTypes
- Futhark.IR.Syntax.Core: instance GHC.Base.Monoid Futhark.IR.Syntax.Core.Rank
- Futhark.IR.Syntax.Core: instance GHC.Base.Semigroup (Futhark.IR.Syntax.Core.ErrorMsg a)
- Futhark.IR.Syntax.Core: instance GHC.Base.Semigroup (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.IR.Syntax.Core: instance GHC.Base.Semigroup Futhark.IR.Syntax.Core.Attrs
- Futhark.IR.Syntax.Core: instance GHC.Base.Semigroup Futhark.IR.Syntax.Core.Certs
- Futhark.IR.Syntax.Core: instance GHC.Base.Semigroup Futhark.IR.Syntax.Core.Commutativity
- Futhark.IR.Syntax.Core: instance GHC.Base.Semigroup Futhark.IR.Syntax.Core.OpaqueTypes
- Futhark.IR.Syntax.Core: instance GHC.Base.Semigroup Futhark.IR.Syntax.Core.Rank
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.Attr
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.Attrs
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.Certs
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.Commutativity
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.Diet
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.EntryPointType
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.Ident
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.OpaqueType
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.OpaqueTypes
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.Rank
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.Signedness
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.Space
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.SubExp
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq Futhark.IR.Syntax.Core.ValueType
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq a => GHC.Classes.Eq (Futhark.IR.Syntax.Core.ErrorMsg a)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq a => GHC.Classes.Eq (Futhark.IR.Syntax.Core.ErrorMsgPart a)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq a => GHC.Classes.Eq (Futhark.IR.Syntax.Core.Ext a)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq d => GHC.Classes.Eq (Futhark.IR.Syntax.Core.DimIndex d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq d => GHC.Classes.Eq (Futhark.IR.Syntax.Core.FlatDimIndex d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq d => GHC.Classes.Eq (Futhark.IR.Syntax.Core.FlatSlice d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq d => GHC.Classes.Eq (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq d => GHC.Classes.Eq (Futhark.IR.Syntax.Core.Slice d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq dec => GHC.Classes.Eq (Futhark.IR.Syntax.Core.Param dec)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Eq dec => GHC.Classes.Eq (Futhark.IR.Syntax.Core.PatElem dec)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.Attr
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.Attrs
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.Certs
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.Commutativity
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.Diet
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.EntryPointType
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.Ident
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.OpaqueType
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.OpaqueTypes
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.Rank
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.Signedness
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.Space
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.SubExp
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord Futhark.IR.Syntax.Core.ValueType
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord a => GHC.Classes.Ord (Futhark.IR.Syntax.Core.ErrorMsg a)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord a => GHC.Classes.Ord (Futhark.IR.Syntax.Core.ErrorMsgPart a)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord a => GHC.Classes.Ord (Futhark.IR.Syntax.Core.Ext a)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord d => GHC.Classes.Ord (Futhark.IR.Syntax.Core.DimIndex d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord d => GHC.Classes.Ord (Futhark.IR.Syntax.Core.FlatDimIndex d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord d => GHC.Classes.Ord (Futhark.IR.Syntax.Core.FlatSlice d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord d => GHC.Classes.Ord (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord d => GHC.Classes.Ord (Futhark.IR.Syntax.Core.Slice d)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord dec => GHC.Classes.Ord (Futhark.IR.Syntax.Core.Param dec)
- Futhark.IR.Syntax.Core: instance GHC.Classes.Ord dec => GHC.Classes.Ord (Futhark.IR.Syntax.Core.PatElem dec)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.Attr
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.Attrs
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.Certs
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.Commutativity
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.Diet
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.EntryPointType
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.Ident
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.OpaqueType
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.OpaqueTypes
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.Rank
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.Signedness
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.Space
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.SubExp
- Futhark.IR.Syntax.Core: instance GHC.Show.Show Futhark.IR.Syntax.Core.ValueType
- Futhark.IR.Syntax.Core: instance GHC.Show.Show a => GHC.Show.Show (Futhark.IR.Syntax.Core.ErrorMsg a)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show a => GHC.Show.Show (Futhark.IR.Syntax.Core.ErrorMsgPart a)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show a => GHC.Show.Show (Futhark.IR.Syntax.Core.Ext a)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show d => GHC.Show.Show (Futhark.IR.Syntax.Core.DimIndex d)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show d => GHC.Show.Show (Futhark.IR.Syntax.Core.FlatDimIndex d)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show d => GHC.Show.Show (Futhark.IR.Syntax.Core.FlatSlice d)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show d => GHC.Show.Show (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show d => GHC.Show.Show (Futhark.IR.Syntax.Core.Slice d)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show dec => GHC.Show.Show (Futhark.IR.Syntax.Core.Param dec)
- Futhark.IR.Syntax.Core: instance GHC.Show.Show dec => GHC.Show.Show (Futhark.IR.Syntax.Core.PatElem dec)
- Futhark.IR.Syntax.Core: mapAttrs :: (Attr -> a) -> Attrs -> [a]
- Futhark.IR.Syntax.Core: newtype Attrs
- Futhark.IR.Syntax.Core: newtype Certs
- Futhark.IR.Syntax.Core: newtype ErrorMsg a
- Futhark.IR.Syntax.Core: newtype OpaqueTypes
- Futhark.IR.Syntax.Core: newtype Rank
- Futhark.IR.Syntax.Core: newtype ShapeBase d
- Futhark.IR.Syntax.Core: newtype Slice d
- Futhark.IR.Syntax.Core: oneAttr :: Attr -> Attrs
- Futhark.IR.Syntax.Core: shapeRank :: ArrayShape a => a -> Int
- Futhark.IR.Syntax.Core: sliceDims :: Slice d -> [d]
- Futhark.IR.Syntax.Core: sliceIndices :: Slice d -> Maybe [d]
- Futhark.IR.Syntax.Core: sliceShape :: Slice d -> ShapeBase d
- Futhark.IR.Syntax.Core: sliceSlice :: Num d => Slice d -> Slice d -> Slice d
- Futhark.IR.Syntax.Core: stripDims :: Int -> ShapeBase d -> ShapeBase d
- Futhark.IR.Syntax.Core: subShapeOf :: ArrayShape a => a -> a -> Bool
- Futhark.IR.Syntax.Core: takeDims :: Int -> ShapeBase d -> ShapeBase d
- Futhark.IR.Syntax.Core: type DeclExtType = TypeBase ExtShape Uniqueness
- Futhark.IR.Syntax.Core: type DeclType = TypeBase Shape Uniqueness
- Futhark.IR.Syntax.Core: type ExtShape = ShapeBase ExtSize
- Futhark.IR.Syntax.Core: type ExtSize = Ext SubExp
- Futhark.IR.Syntax.Core: type ExtType = TypeBase ExtShape NoUniqueness
- Futhark.IR.Syntax.Core: type Shape = ShapeBase SubExp
- Futhark.IR.Syntax.Core: type SpaceId = String
- Futhark.IR.Syntax.Core: type Type = TypeBase Shape NoUniqueness
- Futhark.IR.Syntax.Core: unitSlice :: Num d => d -> d -> DimIndex d
- Futhark.IR.Syntax.Core: withoutAttrs :: Attrs -> Attrs -> Attrs
- Futhark.IR.Traversals: Mapper :: (SubExp -> m SubExp) -> (Scope trep -> Body frep -> m (Body trep)) -> (VName -> m VName) -> (RetType frep -> m (RetType trep)) -> (BranchType frep -> m (BranchType trep)) -> (FParam frep -> m (FParam trep)) -> (LParam frep -> m (LParam trep)) -> (Op frep -> m (Op trep)) -> Mapper frep trep (m :: Type -> Type)
- Futhark.IR.Traversals: Walker :: (SubExp -> m ()) -> (Scope rep -> Body rep -> m ()) -> (VName -> m ()) -> (RetType rep -> m ()) -> (BranchType rep -> m ()) -> (FParam rep -> m ()) -> (LParam rep -> m ()) -> (Op rep -> m ()) -> Walker rep (m :: Type -> Type)
- Futhark.IR.Traversals: [mapOnBody] :: Mapper frep trep (m :: Type -> Type) -> Scope trep -> Body frep -> m (Body trep)
- Futhark.IR.Traversals: [mapOnBranchType] :: Mapper frep trep (m :: Type -> Type) -> BranchType frep -> m (BranchType trep)
- Futhark.IR.Traversals: [mapOnFParam] :: Mapper frep trep (m :: Type -> Type) -> FParam frep -> m (FParam trep)
- Futhark.IR.Traversals: [mapOnLParam] :: Mapper frep trep (m :: Type -> Type) -> LParam frep -> m (LParam trep)
- Futhark.IR.Traversals: [mapOnOp] :: Mapper frep trep (m :: Type -> Type) -> Op frep -> m (Op trep)
- Futhark.IR.Traversals: [mapOnRetType] :: Mapper frep trep (m :: Type -> Type) -> RetType frep -> m (RetType trep)
- Futhark.IR.Traversals: [mapOnSubExp] :: Mapper frep trep (m :: Type -> Type) -> SubExp -> m SubExp
- Futhark.IR.Traversals: [mapOnVName] :: Mapper frep trep (m :: Type -> Type) -> VName -> m VName
- Futhark.IR.Traversals: [walkOnBody] :: Walker rep (m :: Type -> Type) -> Scope rep -> Body rep -> m ()
- Futhark.IR.Traversals: [walkOnBranchType] :: Walker rep (m :: Type -> Type) -> BranchType rep -> m ()
- Futhark.IR.Traversals: [walkOnFParam] :: Walker rep (m :: Type -> Type) -> FParam rep -> m ()
- Futhark.IR.Traversals: [walkOnLParam] :: Walker rep (m :: Type -> Type) -> LParam rep -> m ()
- Futhark.IR.Traversals: [walkOnOp] :: Walker rep (m :: Type -> Type) -> Op rep -> m ()
- Futhark.IR.Traversals: [walkOnRetType] :: Walker rep (m :: Type -> Type) -> RetType rep -> m ()
- Futhark.IR.Traversals: [walkOnSubExp] :: Walker rep (m :: Type -> Type) -> SubExp -> m ()
- Futhark.IR.Traversals: [walkOnVName] :: Walker rep (m :: Type -> Type) -> VName -> m ()
- Futhark.IR.Traversals: class TraverseOpStms rep
- Futhark.IR.Traversals: data Mapper frep trep (m :: Type -> Type)
- Futhark.IR.Traversals: data Walker rep (m :: Type -> Type)
- Futhark.IR.Traversals: identityMapper :: forall rep (m :: Type -> Type). Monad m => Mapper rep rep m
- Futhark.IR.Traversals: identityWalker :: forall rep (m :: Type -> Type). Monad m => Walker rep m
- Futhark.IR.Traversals: mapExp :: Mapper frep trep Identity -> Exp frep -> Exp trep
- Futhark.IR.Traversals: mapExpM :: Monad m => Mapper frep trep m -> Exp frep -> m (Exp trep)
- Futhark.IR.Traversals: traverseLambdaStms :: Monad m => OpStmsTraverser m (Lambda rep) rep
- Futhark.IR.Traversals: traverseOpStms :: (TraverseOpStms rep, Monad m) => OpStmsTraverser m (Op rep) rep
- Futhark.IR.Traversals: type OpStmsTraverser (m :: Type -> Type) op rep = Scope rep -> Stms rep -> m Stms rep -> op -> m op
- Futhark.IR.Traversals: walkExpM :: Monad m => Walker rep m -> Exp rep -> m ()
- Futhark.IR.TypeCheck: ($dmcheckBodyDec) :: (Checkable rep, BodyDec rep ~ ()) => BodyDec rep -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmcheckExpDec) :: (Checkable rep, ExpDec rep ~ ()) => ExpDec rep -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmcheckFParamDec) :: (Checkable rep, FParamInfo rep ~ DeclType) => VName -> FParamInfo rep -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmcheckLParamDec) :: (Checkable rep, LParamInfo rep ~ Type) => VName -> LParamInfo rep -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmcheckLetBoundDec) :: (Checkable rep, LetDec rep ~ Type) => VName -> LetDec rep -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmcheckRetType) :: (Checkable rep, RetType rep ~ DeclExtType) => [RetType rep] -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmmatchBranchType) :: (Checkable rep, BranchType rep ~ ExtType) => [BranchType rep] -> Body (Aliases rep) -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmmatchLoopResult) :: (Checkable rep, FParamInfo rep ~ DeclType) => [FParam (Aliases rep)] -> Result -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmmatchPat) :: Checkable rep => Pat (LetDec (Aliases rep)) -> Exp (Aliases rep) -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmmatchReturnType) :: (Checkable rep, RetType rep ~ DeclExtType) => [RetType rep] -> Result -> TypeM rep ()
- Futhark.IR.TypeCheck: ($dmprimFParam) :: (Checkable rep, FParamInfo rep ~ DeclType) => VName -> PrimType -> TypeM rep (FParam (Aliases rep))
- Futhark.IR.TypeCheck: BadAnnotation :: String -> Type -> Type -> ErrorCase rep
- Futhark.IR.TypeCheck: DupDefinitionError :: Name -> ErrorCase rep
- Futhark.IR.TypeCheck: DupParamError :: Name -> VName -> ErrorCase rep
- Futhark.IR.TypeCheck: DupPatError :: VName -> ErrorCase rep
- Futhark.IR.TypeCheck: Error :: [Text] -> ErrorCase rep -> TypeError rep
- Futhark.IR.TypeCheck: InvalidPatError :: Pat (LetDec (Aliases rep)) -> [ExtType] -> Maybe String -> ErrorCase rep
- Futhark.IR.TypeCheck: NotAnArray :: VName -> Type -> ErrorCase rep
- Futhark.IR.TypeCheck: ParameterMismatch :: Maybe Name -> [Type] -> [Type] -> ErrorCase rep
- Futhark.IR.TypeCheck: PermutationError :: [Int] -> Int -> Maybe VName -> ErrorCase rep
- Futhark.IR.TypeCheck: ReturnAliased :: Name -> VName -> ErrorCase rep
- Futhark.IR.TypeCheck: ReturnTypeError :: Name -> [ExtType] -> [ExtType] -> ErrorCase rep
- Futhark.IR.TypeCheck: SlicingError :: Shape -> Int -> ErrorCase rep
- Futhark.IR.TypeCheck: TypeError :: Text -> ErrorCase rep
- Futhark.IR.TypeCheck: UnexpectedType :: Exp rep -> Type -> [Type] -> ErrorCase rep
- Futhark.IR.TypeCheck: UniqueReturnAliased :: Name -> ErrorCase rep
- Futhark.IR.TypeCheck: UnknownFunctionError :: Name -> ErrorCase rep
- Futhark.IR.TypeCheck: UnknownVariableError :: VName -> ErrorCase rep
- Futhark.IR.TypeCheck: alternative :: TypeM rep a -> TypeM rep b -> TypeM rep (a, b)
- Futhark.IR.TypeCheck: argType :: Arg -> Type
- Futhark.IR.TypeCheck: bad :: ErrorCase rep -> TypeM rep a
- Futhark.IR.TypeCheck: binding :: Checkable rep => Scope (Aliases rep) -> TypeM rep a -> TypeM rep a
- Futhark.IR.TypeCheck: checkArg :: Checkable rep => SubExp -> TypeM rep Arg
- Futhark.IR.TypeCheck: checkBody :: Checkable rep => Body (Aliases rep) -> TypeM rep [Names]
- Futhark.IR.TypeCheck: checkBodyDec :: Checkable rep => BodyDec rep -> TypeM rep ()
- Futhark.IR.TypeCheck: checkCerts :: Checkable rep => Certs -> TypeM rep ()
- Futhark.IR.TypeCheck: checkExp :: Checkable rep => Exp (Aliases rep) -> TypeM rep ()
- Futhark.IR.TypeCheck: checkExpDec :: Checkable rep => ExpDec rep -> TypeM rep ()
- Futhark.IR.TypeCheck: checkExtType :: Checkable rep => TypeBase ExtShape u -> TypeM rep ()
- Futhark.IR.TypeCheck: checkFParamDec :: Checkable rep => VName -> FParamInfo rep -> TypeM rep ()
- Futhark.IR.TypeCheck: checkLParamDec :: Checkable rep => VName -> LParamInfo rep -> TypeM rep ()
- Futhark.IR.TypeCheck: checkLambda :: Checkable rep => Lambda (Aliases rep) -> [Arg] -> TypeM rep ()
- Futhark.IR.TypeCheck: checkLetBoundDec :: Checkable rep => VName -> LetDec rep -> TypeM rep ()
- Futhark.IR.TypeCheck: checkOp :: Checkable rep => Op (Aliases rep) -> TypeM rep ()
- Futhark.IR.TypeCheck: checkOpWith :: (Op (Aliases rep) -> TypeM rep ()) -> TypeM rep a -> TypeM rep a
- Futhark.IR.TypeCheck: checkProg :: Checkable rep => Prog (Aliases rep) -> Either (TypeError rep) ()
- Futhark.IR.TypeCheck: checkRetType :: Checkable rep => [RetType rep] -> TypeM rep ()
- Futhark.IR.TypeCheck: checkSOACArrayArgs :: Checkable rep => SubExp -> [VName] -> TypeM rep [Arg]
- Futhark.IR.TypeCheck: checkSlice :: Checkable rep => Type -> Slice SubExp -> TypeM rep ()
- Futhark.IR.TypeCheck: checkStm :: Checkable rep => Stm (Aliases rep) -> TypeM rep a -> TypeM rep a
- Futhark.IR.TypeCheck: checkStms :: Checkable rep => Stms (Aliases rep) -> TypeM rep a -> TypeM rep a
- Futhark.IR.TypeCheck: checkSubExp :: Checkable rep => SubExp -> TypeM rep Type
- Futhark.IR.TypeCheck: checkType :: Checkable rep => TypeBase Shape u -> TypeM rep ()
- Futhark.IR.TypeCheck: class (AliasableRep rep, TypedOp OpC rep) => Checkable rep
- Futhark.IR.TypeCheck: consume :: Checkable rep => Names -> TypeM rep ()
- Futhark.IR.TypeCheck: context :: Text -> TypeM rep a -> TypeM rep a
- Futhark.IR.TypeCheck: data ErrorCase rep
- Futhark.IR.TypeCheck: data TypeError rep
- Futhark.IR.TypeCheck: data TypeM rep a
- Futhark.IR.TypeCheck: instance Control.Monad.Reader.Class.MonadReader (Futhark.IR.TypeCheck.Env rep) (Futhark.IR.TypeCheck.TypeM rep)
- Futhark.IR.TypeCheck: instance Control.Monad.State.Class.MonadState Futhark.IR.TypeCheck.TState (Futhark.IR.TypeCheck.TypeM rep)
- Futhark.IR.TypeCheck: instance Futhark.IR.TypeCheck.Checkable rep => Futhark.IR.Prop.Scope.HasScope (Futhark.IR.Aliases.Aliases rep) (Futhark.IR.TypeCheck.TypeM rep)
- Futhark.IR.TypeCheck: instance Futhark.IR.TypeCheck.Checkable rep => GHC.Show.Show (Futhark.IR.TypeCheck.ErrorCase rep)
- Futhark.IR.TypeCheck: instance Futhark.IR.TypeCheck.Checkable rep => GHC.Show.Show (Futhark.IR.TypeCheck.TypeError rep)
- Futhark.IR.TypeCheck: instance GHC.Base.Applicative (Futhark.IR.TypeCheck.TypeM rep)
- Futhark.IR.TypeCheck: instance GHC.Base.Functor (Futhark.IR.TypeCheck.TypeM rep)
- Futhark.IR.TypeCheck: instance GHC.Base.Monad (Futhark.IR.TypeCheck.TypeM rep)
- Futhark.IR.TypeCheck: instance GHC.Base.Monoid Futhark.IR.TypeCheck.Consumption
- Futhark.IR.TypeCheck: instance GHC.Base.Semigroup Futhark.IR.TypeCheck.Consumption
- Futhark.IR.TypeCheck: instance GHC.Classes.Eq Futhark.IR.TypeCheck.Occurence
- Futhark.IR.TypeCheck: instance GHC.Classes.Eq Futhark.IR.TypeCheck.Usage
- Futhark.IR.TypeCheck: instance GHC.Classes.Ord Futhark.IR.TypeCheck.Usage
- Futhark.IR.TypeCheck: instance GHC.Show.Show Futhark.IR.TypeCheck.Consumption
- Futhark.IR.TypeCheck: instance GHC.Show.Show Futhark.IR.TypeCheck.Occurence
- Futhark.IR.TypeCheck: instance GHC.Show.Show Futhark.IR.TypeCheck.Usage
- Futhark.IR.TypeCheck: lookupAliases :: Checkable rep => VName -> TypeM rep Names
- Futhark.IR.TypeCheck: lookupVar :: VName -> TypeM rep (NameInfo (Aliases rep))
- Futhark.IR.TypeCheck: matchBranchType :: Checkable rep => [BranchType rep] -> Body (Aliases rep) -> TypeM rep ()
- Futhark.IR.TypeCheck: matchExtBranchType :: Checkable rep => [ExtType] -> Body (Aliases rep) -> TypeM rep ()
- Futhark.IR.TypeCheck: matchExtPat :: Checkable rep => Pat (LetDec (Aliases rep)) -> [ExtType] -> TypeM rep ()
- Futhark.IR.TypeCheck: matchLoopResult :: Checkable rep => [FParam (Aliases rep)] -> Result -> TypeM rep ()
- Futhark.IR.TypeCheck: matchPat :: Checkable rep => Pat (LetDec (Aliases rep)) -> Exp (Aliases rep) -> TypeM rep ()
- Futhark.IR.TypeCheck: matchReturnType :: Checkable rep => [RetType rep] -> Result -> TypeM rep ()
- Futhark.IR.TypeCheck: noArgAliases :: Arg -> Arg
- Futhark.IR.TypeCheck: primFParam :: Checkable rep => VName -> PrimType -> TypeM rep (FParam (Aliases rep))
- Futhark.IR.TypeCheck: require :: Checkable rep => [Type] -> SubExp -> TypeM rep ()
- Futhark.IR.TypeCheck: requireI :: Checkable rep => [Type] -> VName -> TypeM rep ()
- Futhark.IR.TypeCheck: requirePrimExp :: Checkable rep => PrimType -> PrimExp VName -> TypeM rep ()
- Futhark.Internalise: internaliseProg :: (MonadFreshNames m, MonadLogger m) => FutharkConfig -> Imports -> m (Prog SOACS)
- Futhark.Internalise.AccurateSizes: argShapes :: [VName] -> [FParam SOACS] -> [Type] -> InternaliseM [SubExp]
- Futhark.Internalise.AccurateSizes: ensureArgShapes :: Typed (TypeBase Shape u) => ErrorMsg SubExp -> SrcLoc -> [VName] -> [TypeBase Shape u] -> [SubExp] -> InternaliseM [SubExp]
- Futhark.Internalise.AccurateSizes: ensureExtShape :: ErrorMsg SubExp -> SrcLoc -> ExtType -> String -> SubExp -> InternaliseM SubExp
- Futhark.Internalise.AccurateSizes: ensureResultExtShape :: ErrorMsg SubExp -> SrcLoc -> [ExtType] -> Result -> InternaliseM Result
- Futhark.Internalise.AccurateSizes: ensureResultShape :: ErrorMsg SubExp -> SrcLoc -> [Type] -> Result -> InternaliseM Result
- Futhark.Internalise.AccurateSizes: ensureShape :: ErrorMsg SubExp -> SrcLoc -> Type -> String -> SubExp -> InternaliseM SubExp
- Futhark.Internalise.ApplyTypeAbbrs: transformProg :: Monad m => [Dec] -> m [ValBind]
- Futhark.Internalise.Bindings: bindingFParams :: [TypeParam] -> [Pat ParamType] -> ([FParam SOACS] -> [[Tree (FParam SOACS)]] -> InternaliseM a) -> InternaliseM a
- Futhark.Internalise.Bindings: bindingLambdaParams :: [Pat ParamType] -> [Type] -> ([LParam SOACS] -> InternaliseM a) -> InternaliseM a
- Futhark.Internalise.Bindings: bindingLoopParams :: [TypeParam] -> Pat ParamType -> [Type] -> ([FParam SOACS] -> [FParam SOACS] -> InternaliseM a) -> InternaliseM a
- Futhark.Internalise.Bindings: internaliseAttr :: AttrInfo VName -> InternaliseM Attr
- Futhark.Internalise.Bindings: internaliseAttrs :: [AttrInfo VName] -> InternaliseM Attrs
- Futhark.Internalise.Bindings: stmPat :: Pat ParamType -> [Type] -> ([VName] -> InternaliseM a) -> InternaliseM a
- Futhark.Internalise.Defunctionalise: instance Control.Monad.Reader.Class.MonadReader (Data.Set.Internal.Set Language.Futhark.Core.VName, Futhark.Internalise.Defunctionalise.Env) Futhark.Internalise.Defunctionalise.DefM
- Futhark.Internalise.Defunctionalise: instance Control.Monad.State.Class.MonadState ([Language.Futhark.Prop.ValBind], Futhark.FreshNames.VNameSource) Futhark.Internalise.Defunctionalise.DefM
- Futhark.Internalise.Defunctionalise: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Internalise.Defunctionalise.DefM
- Futhark.Internalise.Defunctionalise: instance GHC.Base.Applicative Futhark.Internalise.Defunctionalise.DefM
- Futhark.Internalise.Defunctionalise: instance GHC.Base.Functor Futhark.Internalise.Defunctionalise.DefM
- Futhark.Internalise.Defunctionalise: instance GHC.Base.Monad Futhark.Internalise.Defunctionalise.DefM
- Futhark.Internalise.Defunctionalise: instance GHC.Classes.Eq Futhark.Internalise.Defunctionalise.SizeSubst
- Futhark.Internalise.Defunctionalise: instance GHC.Classes.Ord Futhark.Internalise.Defunctionalise.SizeSubst
- Futhark.Internalise.Defunctionalise: instance GHC.Show.Show Futhark.Internalise.Defunctionalise.Binding
- Futhark.Internalise.Defunctionalise: instance GHC.Show.Show Futhark.Internalise.Defunctionalise.SizeSubst
- Futhark.Internalise.Defunctionalise: instance GHC.Show.Show Futhark.Internalise.Defunctionalise.StaticVal
- Futhark.Internalise.Defunctionalise: transformProg :: MonadFreshNames m => [ValBind] -> m [ValBind]
- Futhark.Internalise.Defunctorise: instance Control.Monad.Reader.Class.MonadReader Futhark.Internalise.Defunctorise.Env Futhark.Internalise.Defunctorise.TransformM
- Futhark.Internalise.Defunctorise: instance Control.Monad.Writer.Class.MonadWriter (Data.DList.Internal.DList Language.Futhark.Prop.Dec) Futhark.Internalise.Defunctorise.TransformM
- Futhark.Internalise.Defunctorise: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Internalise.Defunctorise.TransformM
- Futhark.Internalise.Defunctorise: instance GHC.Base.Applicative Futhark.Internalise.Defunctorise.TransformM
- Futhark.Internalise.Defunctorise: instance GHC.Base.Functor Futhark.Internalise.Defunctorise.TransformM
- Futhark.Internalise.Defunctorise: instance GHC.Base.Monad Futhark.Internalise.Defunctorise.TransformM
- Futhark.Internalise.Defunctorise: instance GHC.Base.Monoid Futhark.Internalise.Defunctorise.Scope
- Futhark.Internalise.Defunctorise: instance GHC.Base.Semigroup Futhark.Internalise.Defunctorise.Scope
- Futhark.Internalise.Defunctorise: instance GHC.Show.Show Futhark.Internalise.Defunctorise.Mod
- Futhark.Internalise.Defunctorise: instance GHC.Show.Show Futhark.Internalise.Defunctorise.Scope
- Futhark.Internalise.Defunctorise: transformProg :: MonadFreshNames m => Imports -> m [Dec]
- Futhark.Internalise.Entry: data VisibleTypes
- Futhark.Internalise.Entry: entryPoint :: VisibleTypes -> Name -> [(EntryParam, [Param DeclType])] -> (EntryType, [[TypeBase Rank Uniqueness]]) -> (EntryPoint, OpaqueTypes)
- Futhark.Internalise.Entry: visibleTypes :: Imports -> VisibleTypes
- Futhark.Internalise.Exps: instance GHC.Show.Show Futhark.Internalise.Exps.Function
- Futhark.Internalise.Exps: transformProg :: MonadFreshNames m => Bool -> VisibleTypes -> [ValBind] -> m (Prog SOACS)
- Futhark.Internalise.FullNormalise: instance Control.Monad.Reader.Class.MonadReader GHC.Base.String Futhark.Internalise.FullNormalise.OrderingM
- Futhark.Internalise.FullNormalise: instance Control.Monad.State.Class.MonadState Futhark.Internalise.FullNormalise.NormState Futhark.Internalise.FullNormalise.OrderingM
- Futhark.Internalise.FullNormalise: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Internalise.FullNormalise.OrderingM
- Futhark.Internalise.FullNormalise: instance GHC.Base.Applicative Futhark.Internalise.FullNormalise.OrderingM
- Futhark.Internalise.FullNormalise: instance GHC.Base.Functor Futhark.Internalise.FullNormalise.OrderingM
- Futhark.Internalise.FullNormalise: instance GHC.Base.Monad Futhark.Internalise.FullNormalise.OrderingM
- Futhark.Internalise.FullNormalise: transformProg :: MonadFreshNames m => [ValBind] -> m [ValBind]
- Futhark.Internalise.Lambdas: internaliseFoldLambda :: InternaliseLambda -> Exp -> [Type] -> [Type] -> InternaliseM (Lambda SOACS)
- Futhark.Internalise.Lambdas: internalisePartitionLambda :: InternaliseLambda -> Int -> Exp -> [SubExp] -> InternaliseM (Lambda SOACS)
- Futhark.Internalise.Lambdas: type InternaliseLambda = Exp -> [Type] -> InternaliseM ([LParam SOACS], Body SOACS, [Type])
- Futhark.Internalise.LiftLambdas: instance Control.Monad.Reader.Class.MonadReader Futhark.Internalise.LiftLambdas.Env Futhark.Internalise.LiftLambdas.LiftM
- Futhark.Internalise.LiftLambdas: instance Control.Monad.State.Class.MonadState Futhark.Internalise.LiftLambdas.LiftState Futhark.Internalise.LiftLambdas.LiftM
- Futhark.Internalise.LiftLambdas: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Internalise.LiftLambdas.LiftM
- Futhark.Internalise.LiftLambdas: instance GHC.Base.Applicative Futhark.Internalise.LiftLambdas.LiftM
- Futhark.Internalise.LiftLambdas: instance GHC.Base.Functor Futhark.Internalise.LiftLambdas.LiftM
- Futhark.Internalise.LiftLambdas: instance GHC.Base.Monad Futhark.Internalise.LiftLambdas.LiftM
- Futhark.Internalise.LiftLambdas: transformProg :: MonadFreshNames m => [ValBind] -> m [ValBind]
- Futhark.Internalise.Monad: InternaliseEnv :: VarSubsts -> Bool -> Bool -> Attrs -> InternaliseEnv
- Futhark.Internalise.Monad: [envAttrs] :: InternaliseEnv -> Attrs
- Futhark.Internalise.Monad: [envDoBoundsChecks] :: InternaliseEnv -> Bool
- Futhark.Internalise.Monad: [envSafe] :: InternaliseEnv -> Bool
- Futhark.Internalise.Monad: [envSubsts] :: InternaliseEnv -> VarSubsts
- Futhark.Internalise.Monad: addFunDef :: FunDef SOACS -> InternaliseM ()
- Futhark.Internalise.Monad: addOpaques :: OpaqueTypes -> InternaliseM ()
- Futhark.Internalise.Monad: assert :: String -> SubExp -> ErrorMsg SubExp -> SrcLoc -> InternaliseM Certs
- Futhark.Internalise.Monad: bindConstant :: VName -> FunDef SOACS -> InternaliseM ()
- Futhark.Internalise.Monad: bindFunction :: VName -> FunDef SOACS -> FunInfo -> InternaliseM ()
- Futhark.Internalise.Monad: data InternaliseEnv
- Futhark.Internalise.Monad: data InternaliseM a
- Futhark.Internalise.Monad: instance Control.Monad.Reader.Class.MonadReader Futhark.Internalise.Monad.InternaliseEnv Futhark.Internalise.Monad.InternaliseM
- Futhark.Internalise.Monad: instance Control.Monad.State.Class.MonadState Futhark.Internalise.Monad.InternaliseState Futhark.Internalise.Monad.InternaliseM
- Futhark.Internalise.Monad: instance Futhark.Builder.Class.MonadBuilder Futhark.Internalise.Monad.InternaliseM
- Futhark.Internalise.Monad: instance Futhark.IR.Prop.Scope.HasScope Futhark.IR.SOACS.SOACS Futhark.Internalise.Monad.InternaliseM
- Futhark.Internalise.Monad: instance Futhark.IR.Prop.Scope.LocalScope Futhark.IR.SOACS.SOACS Futhark.Internalise.Monad.InternaliseM
- Futhark.Internalise.Monad: instance Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.State.Lazy.State Futhark.Internalise.Monad.InternaliseState)
- Futhark.Internalise.Monad: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Internalise.Monad.InternaliseM
- Futhark.Internalise.Monad: instance GHC.Base.Applicative Futhark.Internalise.Monad.InternaliseM
- Futhark.Internalise.Monad: instance GHC.Base.Functor Futhark.Internalise.Monad.InternaliseM
- Futhark.Internalise.Monad: instance GHC.Base.Monad Futhark.Internalise.Monad.InternaliseM
- Futhark.Internalise.Monad: lookupConst :: VName -> InternaliseM (Maybe [SubExp])
- Futhark.Internalise.Monad: lookupFunction :: VName -> InternaliseM FunInfo
- Futhark.Internalise.Monad: lookupSubst :: VName -> InternaliseM (Maybe [SubExp])
- Futhark.Internalise.Monad: runInternaliseM :: MonadFreshNames m => Bool -> InternaliseM () -> m (OpaqueTypes, Stms SOACS, [FunDef SOACS])
- Futhark.Internalise.Monad: substitutingVars :: VarSubsts -> InternaliseM a -> InternaliseM a
- Futhark.Internalise.Monad: throwError :: MonadError e m => e -> m a
- Futhark.Internalise.Monad: type FunInfo = ([VName], [DeclType], [FParam SOACS], [(SubExp, Type)] -> Maybe [(DeclExtType, RetAls)])
- Futhark.Internalise.Monad: type VarSubsts = Map VName [SubExp]
- Futhark.Internalise.Monomorphise: instance Control.Monad.Reader.Class.MonadReader Futhark.Internalise.Monomorphise.Env Futhark.Internalise.Monomorphise.MonoM
- Futhark.Internalise.Monomorphise: instance Control.Monad.State.Class.MonadState Futhark.Internalise.Monomorphise.ExpReplacements Futhark.Internalise.Monomorphise.MonoM
- Futhark.Internalise.Monomorphise: instance Control.Monad.Writer.Class.MonadWriter (Data.Sequence.Internal.Seq (Language.Futhark.Core.VName, Language.Futhark.Prop.ValBind)) Futhark.Internalise.Monomorphise.MonoM
- Futhark.Internalise.Monomorphise: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Internalise.Monomorphise.MonoM
- Futhark.Internalise.Monomorphise: instance GHC.Base.Applicative Futhark.Internalise.Monomorphise.MonoM
- Futhark.Internalise.Monomorphise: instance GHC.Base.Functor Futhark.Internalise.Monomorphise.MonoM
- Futhark.Internalise.Monomorphise: instance GHC.Base.Monad Futhark.Internalise.Monomorphise.MonoM
- Futhark.Internalise.Monomorphise: instance GHC.Base.Monoid Futhark.Internalise.Monomorphise.Env
- Futhark.Internalise.Monomorphise: instance GHC.Base.Semigroup Futhark.Internalise.Monomorphise.Env
- Futhark.Internalise.Monomorphise: instance GHC.Classes.Eq Futhark.Internalise.Monomorphise.MonoSize
- Futhark.Internalise.Monomorphise: instance GHC.Classes.Eq Futhark.Internalise.Monomorphise.ReplacedExp
- Futhark.Internalise.Monomorphise: instance GHC.Show.Show Futhark.Internalise.Monomorphise.MonoSize
- Futhark.Internalise.Monomorphise: instance GHC.Show.Show Futhark.Internalise.Monomorphise.ReplacedExp
- Futhark.Internalise.Monomorphise: instance Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.Shape Futhark.Internalise.Monomorphise.MonoSize)
- Futhark.Internalise.Monomorphise: instance Prettyprinter.Internal.Pretty Futhark.Internalise.Monomorphise.MonoSize
- Futhark.Internalise.Monomorphise: instance Prettyprinter.Internal.Pretty Futhark.Internalise.Monomorphise.ReplacedExp
- Futhark.Internalise.Monomorphise: transformProg :: MonadFreshNames m => [ValBind] -> m [ValBind]
- Futhark.Internalise.ReplaceRecords: instance Control.Monad.Reader.Class.MonadReader Futhark.Internalise.ReplaceRecords.Env Futhark.Internalise.ReplaceRecords.RecordM
- Futhark.Internalise.ReplaceRecords: instance Control.Monad.State.Class.MonadState Futhark.Internalise.ReplaceRecords.S Futhark.Internalise.ReplaceRecords.RecordM
- Futhark.Internalise.ReplaceRecords: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Internalise.ReplaceRecords.RecordM
- Futhark.Internalise.ReplaceRecords: instance GHC.Base.Applicative Futhark.Internalise.ReplaceRecords.RecordM
- Futhark.Internalise.ReplaceRecords: instance GHC.Base.Functor Futhark.Internalise.ReplaceRecords.RecordM
- Futhark.Internalise.ReplaceRecords: instance GHC.Base.Monad Futhark.Internalise.ReplaceRecords.RecordM
- Futhark.Internalise.ReplaceRecords: transformProg :: MonadFreshNames m => [ValBind] -> m [ValBind]
- Futhark.Internalise.TypesValues: inferAliases :: [Tree (TypeBase Shape Uniqueness)] -> [Tree (TypeBase ExtShape Uniqueness)] -> [[(TypeBase ExtShape Uniqueness, RetAls)]]
- Futhark.Internalise.TypesValues: instance Control.Monad.State.Class.MonadState Futhark.Internalise.TypesValues.TypeState Futhark.Internalise.TypesValues.InternaliseTypeM
- Futhark.Internalise.TypesValues: instance GHC.Base.Applicative Futhark.Internalise.TypesValues.InternaliseTypeM
- Futhark.Internalise.TypesValues: instance GHC.Base.Functor Futhark.Internalise.TypesValues.InternaliseTypeM
- Futhark.Internalise.TypesValues: instance GHC.Base.Monad Futhark.Internalise.TypesValues.InternaliseTypeM
- Futhark.Internalise.TypesValues: internaliseCoerceType :: StructType -> [TypeBase shape u] -> [TypeBase ExtShape Uniqueness]
- Futhark.Internalise.TypesValues: internaliseConstructors :: Map Name [Tree (TypeBase ExtShape Uniqueness)] -> ([Tree (TypeBase ExtShape Uniqueness)], [(Name, [Int])])
- Futhark.Internalise.TypesValues: internaliseEntryReturnType :: [Tree (TypeBase Shape Uniqueness)] -> ResRetType -> [[(TypeBase ExtShape Uniqueness, RetAls)]]
- Futhark.Internalise.TypesValues: internaliseLambdaReturnType :: ResType -> [TypeBase shape u] -> InternaliseM [TypeBase Shape NoUniqueness]
- Futhark.Internalise.TypesValues: internaliseLoopParamType :: ParamType -> [TypeBase shape u] -> InternaliseM [TypeBase Shape Uniqueness]
- Futhark.Internalise.TypesValues: internaliseParamTypes :: [ParamType] -> InternaliseM [[Tree (TypeBase Shape Uniqueness)]]
- Futhark.Internalise.TypesValues: internalisePrimType :: PrimType -> PrimType
- Futhark.Internalise.TypesValues: internalisePrimValue :: PrimValue -> PrimValue
- Futhark.Internalise.TypesValues: internaliseReturnType :: [Tree (TypeBase Shape Uniqueness)] -> ResRetType -> [TypeBase shape u] -> [(TypeBase ExtShape Uniqueness, RetAls)]
- Futhark.Internalise.TypesValues: internaliseSumType :: Map Name [StructType] -> InternaliseM ([TypeBase ExtShape Uniqueness], [(Name, [Int])])
- Futhark.Internalise.TypesValues: internaliseSumTypeRep :: Map Name [StructType] -> ([TypeBase ExtShape Uniqueness], [(Name, [Int])])
- Futhark.Internalise.TypesValues: internaliseType :: TypeBase Size NoUniqueness -> [Tree (TypeBase ExtShape Uniqueness)]
- Futhark.Internalise.TypesValues: internalisedTypeSize :: TypeBase Size als -> Int
- Futhark.Internalise.TypesValues: type Tree = Free []
- Futhark.LSP.Compile: tryReCompile :: IORef State -> Maybe FilePath -> LspT () IO ()
- Futhark.LSP.Compile: tryTakeStateFromIORef :: IORef State -> Maybe FilePath -> LspT () IO State
- Futhark.LSP.Diagnostic: diagnosticSource :: Maybe Text
- Futhark.LSP.Diagnostic: maxDiagnostic :: Int
- Futhark.LSP.Diagnostic: publishErrorDiagnostics :: NonEmpty ProgError -> LspT () IO ()
- Futhark.LSP.Diagnostic: publishWarningDiagnostics :: [(Loc, Doc a)] -> LspT () IO ()
- Futhark.LSP.Handlers: handlers :: IORef State -> ClientCapabilities -> Handlers (LspM ())
- Futhark.LSP.PositionMapping: StaleFile :: VirtualFile -> Maybe PositionMapping -> StaleFile
- Futhark.LSP.PositionMapping: [staleContent] :: StaleFile -> VirtualFile
- Futhark.LSP.PositionMapping: [staleMapping] :: StaleFile -> Maybe PositionMapping
- Futhark.LSP.PositionMapping: data PositionMapping
- Futhark.LSP.PositionMapping: data StaleFile
- Futhark.LSP.PositionMapping: instance GHC.Show.Show Futhark.LSP.PositionMapping.PositionMapping
- Futhark.LSP.PositionMapping: instance GHC.Show.Show Futhark.LSP.PositionMapping.StaleFile
- Futhark.LSP.PositionMapping: mappingFromDiff :: [Text] -> [Text] -> PositionMapping
- Futhark.LSP.PositionMapping: toCurrentLoc :: Maybe PositionMapping -> Loc -> Maybe Loc
- Futhark.LSP.PositionMapping: toStalePos :: Maybe PositionMapping -> Pos -> Maybe Pos
- Futhark.LSP.State: State :: Maybe LoadedProg -> Map FilePath StaleFile -> State
- Futhark.LSP.State: [staleData] :: State -> Map FilePath StaleFile
- Futhark.LSP.State: [stateProgram] :: State -> Maybe LoadedProg
- Futhark.LSP.State: data State
- Futhark.LSP.State: emptyState :: State
- Futhark.LSP.State: getStaleContent :: State -> FilePath -> Maybe VirtualFile
- Futhark.LSP.State: getStaleMapping :: State -> FilePath -> Maybe PositionMapping
- Futhark.LSP.State: updateStaleContent :: FilePath -> VirtualFile -> LoadedProg -> State -> State
- Futhark.LSP.State: updateStaleMapping :: Maybe FilePath -> Maybe PositionMapping -> State -> State
- Futhark.LSP.Tool: computeMapping :: State -> Maybe FilePath -> LspM () (Maybe PositionMapping)
- Futhark.LSP.Tool: findDefinitionRange :: State -> Maybe FilePath -> Int -> Int -> Maybe Location
- Futhark.LSP.Tool: getHoverInfoFromState :: State -> Maybe FilePath -> Int -> Int -> Maybe Hover
- Futhark.LSP.Tool: posToUri :: Pos -> Uri
- Futhark.LSP.Tool: rangeFromLoc :: Loc -> Range
- Futhark.MonadFreshNames: blankNameSource :: VNameSource
- Futhark.MonadFreshNames: class Monad m => MonadFreshNames (m :: Type -> Type)
- Futhark.MonadFreshNames: data VNameSource
- Futhark.MonadFreshNames: getNameSource :: MonadFreshNames m => m VNameSource
- Futhark.MonadFreshNames: instance (Futhark.MonadFreshNames.MonadFreshNames m, GHC.Base.Monoid s) => Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.Writer.Lazy.WriterT s m)
- Futhark.MonadFreshNames: instance (Futhark.MonadFreshNames.MonadFreshNames m, GHC.Base.Monoid s) => Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.Writer.Strict.WriterT s m)
- Futhark.MonadFreshNames: instance (GHC.Base.Monad im, GHC.Base.Monoid w) => Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.RWS.Lazy.RWST r w Futhark.FreshNames.VNameSource im)
- Futhark.MonadFreshNames: instance (GHC.Base.Monad im, GHC.Base.Monoid w) => Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.RWS.Strict.RWST r w Futhark.FreshNames.VNameSource im)
- Futhark.MonadFreshNames: instance Futhark.MonadFreshNames.MonadFreshNames m => Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.Except.ExceptT e m)
- Futhark.MonadFreshNames: instance Futhark.MonadFreshNames.MonadFreshNames m => Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.Maybe.MaybeT m)
- Futhark.MonadFreshNames: instance Futhark.MonadFreshNames.MonadFreshNames m => Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.Reader.ReaderT s m)
- Futhark.MonadFreshNames: instance GHC.Base.Monad im => Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.State.Lazy.StateT Futhark.FreshNames.VNameSource im)
- Futhark.MonadFreshNames: instance GHC.Base.Monad im => Futhark.MonadFreshNames.MonadFreshNames (Control.Monad.Trans.State.Strict.StateT Futhark.FreshNames.VNameSource im)
- Futhark.MonadFreshNames: modifyNameSource :: MonadFreshNames m => (VNameSource -> (a, VNameSource)) -> m a
- Futhark.MonadFreshNames: newIdent :: MonadFreshNames m => String -> Type -> m Ident
- Futhark.MonadFreshNames: newIdent' :: MonadFreshNames m => (String -> String) -> Ident -> m Ident
- Futhark.MonadFreshNames: newName :: MonadFreshNames m => VName -> m VName
- Futhark.MonadFreshNames: newNameFromString :: MonadFreshNames m => String -> m VName
- Futhark.MonadFreshNames: newNameSource :: Int -> VNameSource
- Futhark.MonadFreshNames: newParam :: MonadFreshNames m => String -> dec -> m (Param dec)
- Futhark.MonadFreshNames: newVName :: MonadFreshNames m => String -> m VName
- Futhark.MonadFreshNames: putNameSource :: MonadFreshNames m => VNameSource -> m ()
- Futhark.Optimise.ArrayLayout: optimiseArrayLayoutGPU :: Pass GPU GPU
- Futhark.Optimise.ArrayLayout: optimiseArrayLayoutMC :: Pass MC MC
- Futhark.Optimise.ArrayLayout.Layout: class Layout (rep :: k)
- Futhark.Optimise.ArrayLayout.Layout: commonPermutationEliminators :: [Int] -> [BodyType] -> Bool
- Futhark.Optimise.ArrayLayout.Layout: instance Futhark.Optimise.ArrayLayout.Layout.Layout Futhark.IR.GPU.GPU
- Futhark.Optimise.ArrayLayout.Layout: instance Futhark.Optimise.ArrayLayout.Layout.Layout Futhark.IR.MC.MC
- Futhark.Optimise.ArrayLayout.Layout: layoutTableFromIndexTable :: forall {k} (rep :: k). Layout rep => PrimExpTable -> IndexTable rep -> LayoutTable
- Futhark.Optimise.ArrayLayout.Layout: type LayoutTable = Map SegOpName Map ArrayName Map IndexExprName Permutation
- Futhark.Optimise.ArrayLayout.Layout: type Permutation = [Int]
- Futhark.Optimise.ArrayLayout.Transform: class (Layout rep, PrimExpAnalysis rep) => Transform rep
- Futhark.Optimise.ArrayLayout.Transform: instance Futhark.Optimise.ArrayLayout.Transform.Transform Futhark.IR.GPU.GPU
- Futhark.Optimise.ArrayLayout.Transform: instance Futhark.Optimise.ArrayLayout.Transform.Transform Futhark.IR.MC.MC
- Futhark.Optimise.ArrayLayout.Transform: transformStms :: (Transform rep, BuilderOps rep) => LayoutTable -> ExpMap rep -> Stms rep -> TransformM rep (Stms rep)
- Futhark.Optimise.ArrayShortCircuiting: optimiseGPUMem :: Pass GPUMem GPUMem
- Futhark.Optimise.ArrayShortCircuiting: optimiseMCMem :: Pass MCMem MCMem
- Futhark.Optimise.ArrayShortCircuiting: optimiseSeqMem :: Pass SeqMem SeqMem
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: instance Control.Monad.Reader.Class.MonadReader (Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing.ShortCircuitReader rep) (Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing.ShortCircuitM rep)
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: instance Control.Monad.State.Class.MonadState Futhark.FreshNames.VNameSource (Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing.ShortCircuitM rep)
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: instance Futhark.MonadFreshNames.MonadFreshNames (Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing.ShortCircuitM rep)
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: instance GHC.Base.Applicative (Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing.ShortCircuitM rep)
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: instance GHC.Base.Functor (Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing.ShortCircuitM rep)
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: instance GHC.Base.Monad (Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing.ShortCircuitM rep)
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: mkCoalsTab :: MonadFreshNames m => Prog (Aliases SeqMem) -> m (Map Name CoalsTab)
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: mkCoalsTabGPU :: MonadFreshNames m => Prog (Aliases GPUMem) -> m (Map Name CoalsTab)
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: mkCoalsTabMC :: MonadFreshNames m => Prog (Aliases MCMem) -> m (Map Name CoalsTab)
- Futhark.Optimise.ArrayShortCircuiting.ArrayCoalescing: type CoalsTab = Map VName CoalsEntry
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: BotUpEnv :: ScalarTab -> CoalsTab -> CoalsTab -> InhibitTab -> BotUpEnv
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: Coalesced :: CoalescedKind -> ArrayMemBound -> FreeVarSubsts -> Coalesced
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: CoalsEntry :: VName -> LMAD -> Names -> Map VName Coalesced -> Map VName VName -> MemRefs -> Certs -> CoalsEntry
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: ConcatCoal :: CoalescedKind
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: CopyCoal :: CoalescedKind
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: InPlaceCoal :: CoalescedKind
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: MapCoal :: CoalescedKind
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: MemBlock :: PrimType -> Shape -> VName -> LMAD -> ArrayMemBound
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: MemRefs :: AccessSummary -> AccessSummary -> MemRefs
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: Set :: Set LmadRef -> AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: TransitiveCoal :: CoalescedKind
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: Undeterminable :: AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [activeCoals] :: BotUpEnv -> CoalsTab
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [alsmem] :: CoalsEntry -> Names
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [certs] :: CoalsEntry -> Certs
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [dstind] :: CoalsEntry -> LMAD
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [dstmem] :: CoalsEntry -> VName
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [dstrefs] :: MemRefs -> AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [inhibit] :: BotUpEnv -> InhibitTab
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [ixfun] :: ArrayMemBound -> LMAD
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [memName] :: ArrayMemBound -> VName
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [memrefs] :: CoalsEntry -> MemRefs
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [optdeps] :: CoalsEntry -> Map VName VName
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [primType] :: ArrayMemBound -> PrimType
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [scals] :: BotUpEnv -> ScalarTab
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [shape] :: ArrayMemBound -> Shape
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [srcwrts] :: MemRefs -> AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [successCoals] :: BotUpEnv -> CoalsTab
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: [vartab] :: CoalsEntry -> Map VName Coalesced
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: accessSubtract :: AccessSummary -> AccessSummary -> AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: class HasMemBlock rep
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: createsNewArrOK :: Exp rep -> Bool
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: data AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: data ArrayMemBound
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: data BotUpEnv
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: data Coalesced
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: data CoalescedKind
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: data CoalsEntry
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: data MemRefs
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: getArrMemAssoc :: Pat (aliases, LetDecMem) -> [(VName, ArrayMemBound)]
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: getArrMemAssocFParam :: [Param FParamMem] -> [(VName, Uniqueness, ArrayMemBound)]
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: getScopeMemInfo :: HasMemBlock rep => VName -> Scope rep -> Maybe ArrayMemBound
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: getUniqueMemFParam :: [Param FParamMem] -> Map VName Space
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Futhark.IR.Prop.Names.FreeIn Futhark.Optimise.ArrayShortCircuiting.DataStructs.AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Futhark.Optimise.ArrayShortCircuiting.DataStructs.HasMemBlock (Futhark.IR.Aliases.Aliases Futhark.IR.GPUMem.GPUMem)
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Futhark.Optimise.ArrayShortCircuiting.DataStructs.HasMemBlock (Futhark.IR.Aliases.Aliases Futhark.IR.MCMem.MCMem)
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Futhark.Optimise.ArrayShortCircuiting.DataStructs.HasMemBlock (Futhark.IR.Aliases.Aliases Futhark.IR.SeqMem.SeqMem)
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance GHC.Base.Monoid Futhark.Optimise.ArrayShortCircuiting.DataStructs.AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance GHC.Base.Monoid Futhark.Optimise.ArrayShortCircuiting.DataStructs.MemRefs
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance GHC.Base.Semigroup Futhark.Optimise.ArrayShortCircuiting.DataStructs.AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance GHC.Base.Semigroup Futhark.Optimise.ArrayShortCircuiting.DataStructs.MemRefs
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Prettyprinter.Internal.Pretty Futhark.Optimise.ArrayShortCircuiting.DataStructs.AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Prettyprinter.Internal.Pretty Futhark.Optimise.ArrayShortCircuiting.DataStructs.ArrayMemBound
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Prettyprinter.Internal.Pretty Futhark.Optimise.ArrayShortCircuiting.DataStructs.Coalesced
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Prettyprinter.Internal.Pretty Futhark.Optimise.ArrayShortCircuiting.DataStructs.CoalescedKind
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Prettyprinter.Internal.Pretty Futhark.Optimise.ArrayShortCircuiting.DataStructs.CoalsEntry
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Prettyprinter.Internal.Pretty Futhark.Optimise.ArrayShortCircuiting.DataStructs.CoalsTab
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: instance Prettyprinter.Internal.Pretty Futhark.Optimise.ArrayShortCircuiting.DataStructs.MemRefs
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: markFailedCoal :: (CoalsTab, InhibitTab) -> VName -> (CoalsTab, InhibitTab)
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: markSuccessCoal :: (CoalsTab, CoalsTab) -> VName -> CoalsEntry -> (CoalsTab, CoalsTab)
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: type AllocTab = Map VName Space
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: type CoalsTab = Map VName CoalsEntry
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: type FreeVarSubsts = Map VName TPrimExp Int64 VName
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: type InhibitTab = Map VName Names
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: type LmadRef = LMAD TPrimExp Int64 VName
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: type ScalarTab = Map VName PrimExp VName
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: type ScopeTab rep = Scope Aliases rep
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: unionCoalsEntry :: CoalsEntry -> CoalsEntry -> CoalsEntry
- Futhark.Optimise.ArrayShortCircuiting.DataStructs: vnameToPrimExp :: AliasableRep rep => ScopeTab rep -> ScalarTab -> VName -> Maybe (PrimExp VName)
- Futhark.Optimise.ArrayShortCircuiting.MemRefAggreg: aggSummaryLoopPartial :: MonadFreshNames m => ScalarTab -> Maybe (VName, (TPrimExp Int64 VName, TPrimExp Int64 VName)) -> AccessSummary -> m AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.MemRefAggreg: aggSummaryLoopTotal :: MonadFreshNames m => ScopeTab rep -> ScopeTab rep -> ScalarTab -> Maybe (VName, (TPrimExp Int64 VName, TPrimExp Int64 VName)) -> AccessSummary -> m AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.MemRefAggreg: aggSummaryMapPartial :: MonadFreshNames m => ScalarTab -> [(VName, SubExp)] -> LmadRef -> m AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.MemRefAggreg: aggSummaryMapTotal :: MonadFreshNames m => ScalarTab -> [(VName, SubExp)] -> AccessSummary -> m AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.MemRefAggreg: freeVarSubstitutions :: FreeIn a => ScopeTab rep -> ScalarTab -> a -> Maybe FreeVarSubsts
- Futhark.Optimise.ArrayShortCircuiting.MemRefAggreg: noMemOverlap :: AliasableRep rep => TopdownEnv rep -> AccessSummary -> AccessSummary -> Bool
- Futhark.Optimise.ArrayShortCircuiting.MemRefAggreg: recordMemRefUses :: forall rep (inner :: Type -> Type). (AliasableRep rep, Op rep ~ MemOp inner rep, HasMemBlock (Aliases rep)) => TopdownEnv rep -> BotUpEnv -> Stm (Aliases rep) -> (CoalsTab, InhibitTab)
- Futhark.Optimise.ArrayShortCircuiting.MemRefAggreg: translateAccessSummary :: ScopeTab rep -> ScalarTab -> AccessSummary -> AccessSummary
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: TopdownEnv :: AllocTab -> ScopeTab rep -> InhibitTab -> VarAliasTab -> MemAliasTab -> Names -> Map VName (PrimExp VName) -> [(VName, PrimExp VName)] -> [SubExp] -> TopdownEnv rep
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: [alloc] :: TopdownEnv rep -> AllocTab
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: [inhibited] :: TopdownEnv rep -> InhibitTab
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: [knownLessThan] :: TopdownEnv rep -> [(VName, PrimExp VName)]
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: [m_alias] :: TopdownEnv rep -> MemAliasTab
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: [nonNegatives] :: TopdownEnv rep -> Names
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: [scalarTable] :: TopdownEnv rep -> Map VName (PrimExp VName)
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: [scope] :: TopdownEnv rep -> ScopeTab rep
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: [td_asserts] :: TopdownEnv rep -> [SubExp]
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: [v_alias] :: TopdownEnv rep -> VarAliasTab
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: addInvAliasesVarTab :: HasMemBlock (Aliases rep) => TopdownEnv rep -> Map VName Coalesced -> VName -> Maybe (Map VName Coalesced)
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: areAnyAliased :: TopdownEnv rep -> VName -> [VName] -> Bool
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: class TopDownHelper inner
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: data TopdownEnv rep
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: getDirAliasedIxfn :: HasMemBlock (Aliases rep) => TopdownEnv rep -> CoalsTab -> VName -> Maybe (VName, VName, LMAD)
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: getDirAliasedIxfn' :: HasMemBlock (Aliases rep) => TopdownEnv rep -> CoalsTab -> VName -> Maybe (VName, VName, LMAD)
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: instance Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis.TopDownHelper (Futhark.IR.GPU.Op.HostOp Futhark.IR.Rep.NoOp (Futhark.IR.Aliases.Aliases Futhark.IR.GPUMem.GPUMem))
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: instance Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis.TopDownHelper (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: instance Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis.TopDownHelper (inner (Futhark.IR.Aliases.Aliases Futhark.IR.MCMem.MCMem)) => Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis.TopDownHelper (Futhark.IR.MC.Op.MCOp inner (Futhark.IR.Aliases.Aliases Futhark.IR.MCMem.MCMem))
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: instance forall k (rep :: k). Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis.TopDownHelper (Futhark.IR.Rep.NoOp rep)
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: isInScope :: TopdownEnv rep -> VName -> Bool
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: nonNegativesInPat :: Typed rep => Pat rep -> Names
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: type InhibitTab = Map VName Names
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: type ScopeTab rep = Scope Aliases rep
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: updateTopdownEnv :: forall rep (inner :: Type -> Type). (ASTRep rep, Op rep ~ MemOp inner rep, TopDownHelper (inner (Aliases rep))) => TopdownEnv rep -> Stm (Aliases rep) -> TopdownEnv rep
- Futhark.Optimise.ArrayShortCircuiting.TopdownAnalysis: updateTopdownEnvLoop :: TopdownEnv rep -> [(FParam rep, SubExp)] -> LoopForm -> TopdownEnv rep
- Futhark.Optimise.BlkRegTiling: doRegTiling3D :: Stm GPU -> TileM (Maybe (Stms GPU, Stm GPU))
- Futhark.Optimise.BlkRegTiling: mmBlkRegTiling :: Env -> Stm GPU -> TileM (Maybe (Stms GPU, Stm GPU))
- Futhark.Optimise.CSE: class CSEInOp op
- Futhark.Optimise.CSE: instance (Futhark.IR.Aliases.AliasableRep rep, Futhark.Optimise.CSE.CSEInOp (Futhark.IR.Rep.Op (Futhark.IR.Aliases.Aliases rep))) => Futhark.Optimise.CSE.CSEInOp (Futhark.IR.SOACS.SOAC.SOAC (Futhark.IR.Aliases.Aliases rep))
- Futhark.Optimise.CSE: instance (Futhark.IR.Prop.Aliases.Aliased rep, Futhark.Optimise.CSE.CSEInOp (Futhark.IR.Rep.Op rep)) => Futhark.Optimise.CSE.CSEInOp (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.Optimise.CSE: instance (Futhark.IR.Prop.Aliases.Aliased rep, Futhark.Optimise.CSE.CSEInOp (Futhark.IR.Rep.Op rep), Futhark.Optimise.CSE.CSEInOp (op rep)) => Futhark.Optimise.CSE.CSEInOp (Futhark.IR.GPU.Op.HostOp op rep)
- Futhark.Optimise.CSE: instance (Futhark.IR.Prop.Aliases.Aliased rep, Futhark.Optimise.CSE.CSEInOp (Futhark.IR.Rep.Op rep), Futhark.Optimise.CSE.CSEInOp (op rep)) => Futhark.Optimise.CSE.CSEInOp (Futhark.IR.MC.Op.MCOp op rep)
- Futhark.Optimise.CSE: instance Futhark.Optimise.CSE.CSEInOp (op rep) => Futhark.Optimise.CSE.CSEInOp (Futhark.IR.Mem.MemOp op rep)
- Futhark.Optimise.CSE: instance forall k (rep :: k). Futhark.Optimise.CSE.CSEInOp (Futhark.IR.Rep.NoOp rep)
- Futhark.Optimise.CSE: performCSE :: (AliasableRep rep, CSEInOp (Op (Aliases rep))) => Bool -> Pass rep rep
- Futhark.Optimise.CSE: performCSEOnFunDef :: (AliasableRep rep, CSEInOp (Op (Aliases rep))) => Bool -> FunDef rep -> FunDef rep
- Futhark.Optimise.CSE: performCSEOnStms :: (AliasableRep rep, CSEInOp (Op (Aliases rep))) => Stms rep -> Stms rep
- Futhark.Optimise.DoubleBuffer: doubleBufferGPU :: Pass GPUMem GPUMem
- Futhark.Optimise.DoubleBuffer: doubleBufferMC :: Pass MCMem MCMem
- Futhark.Optimise.DoubleBuffer: instance Control.Monad.Reader.Class.MonadReader (Futhark.Optimise.DoubleBuffer.Env rep) (Futhark.Optimise.DoubleBuffer.DoubleBufferM rep)
- Futhark.Optimise.DoubleBuffer: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Scope.HasScope rep (Futhark.Optimise.DoubleBuffer.DoubleBufferM rep)
- Futhark.Optimise.DoubleBuffer: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Scope.LocalScope rep (Futhark.Optimise.DoubleBuffer.DoubleBufferM rep)
- Futhark.Optimise.DoubleBuffer: instance Futhark.MonadFreshNames.MonadFreshNames (Futhark.Optimise.DoubleBuffer.DoubleBufferM rep)
- Futhark.Optimise.DoubleBuffer: instance GHC.Base.Applicative (Futhark.Optimise.DoubleBuffer.DoubleBufferM rep)
- Futhark.Optimise.DoubleBuffer: instance GHC.Base.Functor (Futhark.Optimise.DoubleBuffer.DoubleBufferM rep)
- Futhark.Optimise.DoubleBuffer: instance GHC.Base.Monad (Futhark.Optimise.DoubleBuffer.DoubleBufferM rep)
- Futhark.Optimise.EntryPointMem: entryPointMemGPU :: Pass GPUMem GPUMem
- Futhark.Optimise.EntryPointMem: entryPointMemMC :: Pass MCMem MCMem
- Futhark.Optimise.EntryPointMem: entryPointMemSeq :: Pass SeqMem SeqMem
- Futhark.Optimise.Fusion: fuseSOACs :: Pass SOACS SOACS
- Futhark.Optimise.Fusion: instance Control.Monad.State.Class.MonadState Futhark.Optimise.Fusion.FusionEnv Futhark.Optimise.Fusion.FusionM
- Futhark.Optimise.Fusion: instance Futhark.IR.Prop.Scope.HasScope Futhark.IR.SOACS.SOACS Futhark.Optimise.Fusion.FusionM
- Futhark.Optimise.Fusion: instance Futhark.IR.Prop.Scope.LocalScope Futhark.IR.SOACS.SOACS Futhark.Optimise.Fusion.FusionM
- Futhark.Optimise.Fusion: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Optimise.Fusion.FusionM
- Futhark.Optimise.Fusion: instance GHC.Base.Applicative Futhark.Optimise.Fusion.FusionM
- Futhark.Optimise.Fusion: instance GHC.Base.Functor Futhark.Optimise.Fusion.FusionM
- Futhark.Optimise.Fusion: instance GHC.Base.Monad Futhark.Optimise.Fusion.FusionM
- Futhark.Optimise.Fusion.Composing: fuseMaps :: Buildable rep => Names -> Lambda rep -> [Input] -> [(VName, Ident)] -> Lambda rep -> [Input] -> (Lambda rep, [Input])
- Futhark.Optimise.Fusion.Composing: fuseRedomap :: Buildable rep => Names -> [VName] -> Lambda rep -> [SubExp] -> [SubExp] -> [Input] -> [(VName, Ident)] -> Lambda rep -> [SubExp] -> [SubExp] -> [Input] -> (Lambda rep, [Input])
- Futhark.Optimise.Fusion.GraphRep: Alias :: VName -> EdgeT
- Futhark.Optimise.Fusion.GraphRep: Cons :: VName -> EdgeT
- Futhark.Optimise.Fusion.GraphRep: Dep :: VName -> EdgeT
- Futhark.Optimise.Fusion.GraphRep: DepGraph :: Gr NodeT EdgeT -> ProducerMapping -> AliasTable -> DepGraph
- Futhark.Optimise.Fusion.GraphRep: DoNode :: Stm SOACS -> [(NodeT, [EdgeT])] -> NodeT
- Futhark.Optimise.Fusion.GraphRep: Fake :: VName -> EdgeT
- Futhark.Optimise.Fusion.GraphRep: FreeNode :: VName -> NodeT
- Futhark.Optimise.Fusion.GraphRep: InfDep :: VName -> EdgeT
- Futhark.Optimise.Fusion.GraphRep: MatchNode :: Stm SOACS -> [(NodeT, [EdgeT])] -> NodeT
- Futhark.Optimise.Fusion.GraphRep: Res :: VName -> EdgeT
- Futhark.Optimise.Fusion.GraphRep: ResNode :: VName -> NodeT
- Futhark.Optimise.Fusion.GraphRep: SoacNode :: ArrayTransforms -> Pat Type -> SOAC SOACS -> StmAux (ExpDec SOACS) -> NodeT
- Futhark.Optimise.Fusion.GraphRep: StmNode :: Stm SOACS -> NodeT
- Futhark.Optimise.Fusion.GraphRep: TransNode :: VName -> ArrayTransform -> VName -> NodeT
- Futhark.Optimise.Fusion.GraphRep: [dgAliasTable] :: DepGraph -> AliasTable
- Futhark.Optimise.Fusion.GraphRep: [dgGraph] :: DepGraph -> Gr NodeT EdgeT
- Futhark.Optimise.Fusion.GraphRep: [dgProducerMapping] :: DepGraph -> ProducerMapping
- Futhark.Optimise.Fusion.GraphRep: applyAugs :: Monad m => [DepGraphAug m] -> DepGraphAug m
- Futhark.Optimise.Fusion.GraphRep: contractEdge :: Monad m => Node -> DepContext -> DepGraphAug m
- Futhark.Optimise.Fusion.GraphRep: data DepGraph
- Futhark.Optimise.Fusion.GraphRep: data EdgeT
- Futhark.Optimise.Fusion.GraphRep: data NodeT
- Futhark.Optimise.Fusion.GraphRep: depsFromEdge :: DepEdge -> VName
- Futhark.Optimise.Fusion.GraphRep: edgesBetween :: DepGraph -> Node -> Node -> [DepEdge]
- Futhark.Optimise.Fusion.GraphRep: getName :: EdgeT -> VName
- Futhark.Optimise.Fusion.GraphRep: hFusionFeasability :: DepGraph -> Node -> Node -> Bool
- Futhark.Optimise.Fusion.GraphRep: instance GHC.Classes.Eq Futhark.Optimise.Fusion.GraphRep.Classification
- Futhark.Optimise.Fusion.GraphRep: instance GHC.Classes.Eq Futhark.Optimise.Fusion.GraphRep.EdgeT
- Futhark.Optimise.Fusion.GraphRep: instance GHC.Classes.Eq Futhark.Optimise.Fusion.GraphRep.NodeT
- Futhark.Optimise.Fusion.GraphRep: instance GHC.Classes.Ord Futhark.Optimise.Fusion.GraphRep.Classification
- Futhark.Optimise.Fusion.GraphRep: instance GHC.Classes.Ord Futhark.Optimise.Fusion.GraphRep.EdgeT
- Futhark.Optimise.Fusion.GraphRep: instance GHC.Show.Show Futhark.Optimise.Fusion.GraphRep.Classification
- Futhark.Optimise.Fusion.GraphRep: instance GHC.Show.Show Futhark.Optimise.Fusion.GraphRep.EdgeT
- Futhark.Optimise.Fusion.GraphRep: instance GHC.Show.Show Futhark.Optimise.Fusion.GraphRep.NodeT
- Futhark.Optimise.Fusion.GraphRep: isCons :: EdgeT -> Bool
- Futhark.Optimise.Fusion.GraphRep: isDep :: EdgeT -> Bool
- Futhark.Optimise.Fusion.GraphRep: isInf :: (Node, Node, EdgeT) -> Bool
- Futhark.Optimise.Fusion.GraphRep: isRealNode :: NodeT -> Bool
- Futhark.Optimise.Fusion.GraphRep: isWithAccNodeId :: Node -> DepGraph -> Bool
- Futhark.Optimise.Fusion.GraphRep: isWithAccNodeT :: NodeT -> Bool
- Futhark.Optimise.Fusion.GraphRep: mapAcross :: Monad m => (DepContext -> m DepContext) -> DepGraphAug m
- Futhark.Optimise.Fusion.GraphRep: mergedContext :: Ord b => a -> Context a b -> Context a b -> Context a b
- Futhark.Optimise.Fusion.GraphRep: mkDepGraph :: (HasScope SOACS m, Monad m) => Body SOACS -> m DepGraph
- Futhark.Optimise.Fusion.GraphRep: mkDepGraphForFun :: FunDef SOACS -> DepGraph
- Futhark.Optimise.Fusion.GraphRep: nodeFromLNode :: DepNode -> Node
- Futhark.Optimise.Fusion.GraphRep: pprg :: DepGraph -> String
- Futhark.Optimise.Fusion.GraphRep: reachable :: DepGraph -> Node -> Node -> Bool
- Futhark.Optimise.Fusion.GraphRep: type DepContext = Context NodeT EdgeT
- Futhark.Optimise.Fusion.GraphRep: type DepGraphAug (m :: Type -> Type) = DepGraph -> m DepGraph
- Futhark.Optimise.Fusion.GraphRep: type DepNode = LNode NodeT
- Futhark.Optimise.Fusion.GraphRep: vFusionFeasability :: DepGraph -> Node -> Node -> Bool
- Futhark.Optimise.Fusion.RulesWithAccs: ruleMFScat :: (HasScope SOACS m, MonadFreshNames m) => DepNode -> DepGraph -> m (Maybe DepGraph)
- Futhark.Optimise.Fusion.RulesWithAccs: tryFuseWithAccs :: (HasScope SOACS m, MonadFreshNames m) => [VName] -> Stm SOACS -> Stm SOACS -> Maybe (m (Stm SOACS))
- Futhark.Optimise.Fusion.TryFusion: FusedSOAC :: SOAC -> ArrayTransforms -> [VName] -> FusedSOAC
- Futhark.Optimise.Fusion.TryFusion: Horizontal :: Mode
- Futhark.Optimise.Fusion.TryFusion: Vertical :: Mode
- Futhark.Optimise.Fusion.TryFusion: [fsOutNames] :: FusedSOAC -> [VName]
- Futhark.Optimise.Fusion.TryFusion: [fsOutputTransform] :: FusedSOAC -> ArrayTransforms
- Futhark.Optimise.Fusion.TryFusion: [fsSOAC] :: FusedSOAC -> SOAC
- Futhark.Optimise.Fusion.TryFusion: attemptFusion :: (HasScope SOACS m, MonadFreshNames m) => Mode -> Names -> [VName] -> SOAC -> FusedSOAC -> m (Maybe FusedSOAC)
- Futhark.Optimise.Fusion.TryFusion: data FusedSOAC
- Futhark.Optimise.Fusion.TryFusion: data Mode
- Futhark.Optimise.Fusion.TryFusion: instance Control.Monad.Fail.MonadFail Futhark.Optimise.Fusion.TryFusion.TryFusion
- Futhark.Optimise.Fusion.TryFusion: instance Futhark.IR.Prop.Scope.HasScope Futhark.IR.SOACS.SOACS Futhark.Optimise.Fusion.TryFusion.TryFusion
- Futhark.Optimise.Fusion.TryFusion: instance Futhark.IR.Prop.Scope.LocalScope Futhark.IR.SOACS.SOACS Futhark.Optimise.Fusion.TryFusion.TryFusion
- Futhark.Optimise.Fusion.TryFusion: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Optimise.Fusion.TryFusion.TryFusion
- Futhark.Optimise.Fusion.TryFusion: instance GHC.Base.Alternative Futhark.Optimise.Fusion.TryFusion.TryFusion
- Futhark.Optimise.Fusion.TryFusion: instance GHC.Base.Applicative Futhark.Optimise.Fusion.TryFusion.TryFusion
- Futhark.Optimise.Fusion.TryFusion: instance GHC.Base.Functor Futhark.Optimise.Fusion.TryFusion.TryFusion
- Futhark.Optimise.Fusion.TryFusion: instance GHC.Base.Monad Futhark.Optimise.Fusion.TryFusion.TryFusion
- Futhark.Optimise.Fusion.TryFusion: instance GHC.Show.Show Futhark.Optimise.Fusion.TryFusion.FusedSOAC
- Futhark.Optimise.GenRedOpt: instance GHC.Classes.Eq Futhark.Optimise.GenRedOpt.Cost
- Futhark.Optimise.GenRedOpt: optimiseGenRed :: Pass GPU GPU
- Futhark.Optimise.HistAccs: histAccsGPU :: Pass GPU GPU
- Futhark.Optimise.InliningDeadFun: inlineAggressively :: Pass SOACS SOACS
- Futhark.Optimise.InliningDeadFun: inlineConservatively :: Pass SOACS SOACS
- Futhark.Optimise.InliningDeadFun: instance GHC.Classes.Eq Futhark.Optimise.InliningDeadFun.Used
- Futhark.Optimise.InliningDeadFun: instance GHC.Classes.Ord Futhark.Optimise.InliningDeadFun.Used
- Futhark.Optimise.InliningDeadFun: instance GHC.Show.Show Futhark.Optimise.InliningDeadFun.Used
- Futhark.Optimise.InliningDeadFun: removeDeadFunctions :: Pass SOACS SOACS
- Futhark.Optimise.MemoryBlockMerging: optimise :: Pass GPUMem GPUMem
- Futhark.Optimise.MemoryBlockMerging.GreedyColoring: colorGraph :: (Ord a, Ord space) => Map a space -> Graph a -> (Map Int space, Coloring a)
- Futhark.Optimise.MemoryBlockMerging.GreedyColoring: type Coloring a = Map a Int
- Futhark.Optimise.MergeGPUBodies: instance GHC.Base.Monoid Futhark.Optimise.MergeGPUBodies.Group
- Futhark.Optimise.MergeGPUBodies: instance GHC.Base.Monoid Futhark.Optimise.MergeGPUBodies.Usage
- Futhark.Optimise.MergeGPUBodies: instance GHC.Base.Semigroup Futhark.Optimise.MergeGPUBodies.Group
- Futhark.Optimise.MergeGPUBodies: instance GHC.Base.Semigroup Futhark.Optimise.MergeGPUBodies.Usage
- Futhark.Optimise.MergeGPUBodies: mergeGPUBodies :: Pass GPU GPU
- Futhark.Optimise.ReduceDeviceSyncs: instance Control.Monad.Reader.Class.MonadReader Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.MigrationTable Futhark.Optimise.ReduceDeviceSyncs.ReduceM
- Futhark.Optimise.ReduceDeviceSyncs: instance Control.Monad.State.Class.MonadState Futhark.Optimise.ReduceDeviceSyncs.State Futhark.Optimise.ReduceDeviceSyncs.ReduceM
- Futhark.Optimise.ReduceDeviceSyncs: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Optimise.ReduceDeviceSyncs.ReduceM
- Futhark.Optimise.ReduceDeviceSyncs: instance GHC.Base.Applicative Futhark.Optimise.ReduceDeviceSyncs.ReduceM
- Futhark.Optimise.ReduceDeviceSyncs: instance GHC.Base.Functor Futhark.Optimise.ReduceDeviceSyncs.ReduceM
- Futhark.Optimise.ReduceDeviceSyncs: instance GHC.Base.Monad Futhark.Optimise.ReduceDeviceSyncs.ReduceM
- Futhark.Optimise.ReduceDeviceSyncs: reduceDeviceSyncs :: Pass GPU GPU
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: MoveToDevice :: MigrationStatus
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: StayOnHost :: MigrationStatus
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: UsedOnHost :: MigrationStatus
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: analyseConsts :: HostOnlyFuns -> [FunDef GPU] -> Stms GPU -> MigrationTable
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: analyseFunDef :: HostOnlyFuns -> FunDef GPU -> MigrationTable
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: data MigrationStatus
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: data MigrationTable
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: hostOnlyFunDefs :: [FunDef GPU] -> HostOnlyFuns
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: instance GHC.Base.Monoid Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.BodyStats
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: instance GHC.Base.Semigroup Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.BodyStats
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: instance GHC.Base.Semigroup Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.MigrationTable
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: instance GHC.Classes.Eq Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.MigrationStatus
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: instance GHC.Classes.Ord Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.MigrationStatus
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: instance GHC.Show.Show Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.MigrationStatus
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: shouldMove :: VName -> MigrationTable -> Bool
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: shouldMoveStm :: Stm GPU -> MigrationTable -> Bool
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: statusOf :: VName -> MigrationTable -> MigrationStatus
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable: usedOnHost :: VName -> MigrationTable -> Bool
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: Exhausted :: Exhaustion
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: FoundSink :: Result a
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: FromNode :: Id -> Exhaustion -> Routing
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: FromSource :: Routing
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: NoRoute :: Routing
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: Normal :: EdgeType
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: NotExhausted :: Exhaustion
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: Produced :: a -> Result a
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: Reversed :: EdgeType
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: ToNodes :: IdSet -> Maybe IdSet -> Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: ToSink :: Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: Vertex :: Id -> m -> Routing -> Edges -> Vertex m
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: [vertexEdges] :: Vertex m -> Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: [vertexId] :: Vertex m -> Id
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: [vertexMeta] :: Vertex m -> m
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: [vertexRouting] :: Vertex m -> Routing
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: addEdges :: Edges -> Id -> Graph m -> Graph m
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: adjust :: (Vertex m -> Vertex m) -> Id -> Graph m -> Graph m
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: connectToSink :: Id -> Graph m -> Graph m
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: data EdgeType
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: data Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: data Exhaustion
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: data Graph m
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: data Result a
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: data Routing
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: data Vertex m
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: data Visited a
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: declareEdges :: [Id] -> Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: empty :: Graph m
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: fold :: Graph m -> (a -> EdgeType -> Vertex m -> a) -> (a, Visited ()) -> EdgeType -> Id -> (a, Visited ())
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: insert :: Vertex m -> Graph m -> Graph m
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Base.Monoid (Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.RoutingResult a)
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Base.Monoid Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Base.Semigroup (Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.RoutingResult a)
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Base.Semigroup Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Base.Semigroup a => GHC.Base.Semigroup (Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Result a)
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Classes.Eq Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.EdgeType
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Classes.Eq Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Classes.Eq Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Exhaustion
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Classes.Eq Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Routing
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Classes.Eq a => GHC.Classes.Eq (Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Result a)
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Classes.Ord Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.EdgeType
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Classes.Ord Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Classes.Ord Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Exhaustion
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Classes.Ord Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Routing
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Show.Show Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Show.Show Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Exhaustion
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: instance GHC.Show.Show Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph.Routing
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: isSinkConnected :: Id -> Graph m -> Bool
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: lookup :: Id -> Graph m -> Maybe (Vertex m)
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: member :: Id -> Graph m -> Bool
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: none :: Visited a
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: oneEdge :: Id -> Edges
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: reduce :: Monoid a => Graph m -> (a -> EdgeType -> Vertex m -> a) -> Visited (Result a) -> EdgeType -> Id -> (Result a, Visited (Result a))
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: route :: Id -> Graph m -> (Maybe Id, Graph m)
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: routeMany :: [Id] -> Graph m -> ([Id], Graph m)
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: type Id = Int
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: type IdSet = IntSet
- Futhark.Optimise.ReduceDeviceSyncs.MigrationTable.Graph: vertex :: Id -> m -> Vertex m
- Futhark.Optimise.Simplify: SimpleOps :: (SymbolTable (Wise rep) -> Pat (LetDec (Wise rep)) -> Exp (Wise rep) -> SimpleM rep (ExpDec (Wise rep))) -> (SymbolTable (Wise rep) -> Stms (Wise rep) -> Result -> SimpleM rep (Body (Wise rep))) -> Protect (Builder (Wise rep)) -> (Op (Wise rep) -> UsageTable) -> SimplifyOp rep (Op (Wise rep)) -> SimpleOps (rep :: k)
- Futhark.Optimise.Simplify: [mkBodyS] :: SimpleOps (rep :: k) -> SymbolTable (Wise rep) -> Stms (Wise rep) -> Result -> SimpleM rep (Body (Wise rep))
- Futhark.Optimise.Simplify: [mkExpDecS] :: SimpleOps (rep :: k) -> SymbolTable (Wise rep) -> Pat (LetDec (Wise rep)) -> Exp (Wise rep) -> SimpleM rep (ExpDec (Wise rep))
- Futhark.Optimise.Simplify: [opUsageS] :: SimpleOps (rep :: k) -> Op (Wise rep) -> UsageTable
- Futhark.Optimise.Simplify: [protectHoistedOpS] :: SimpleOps (rep :: k) -> Protect (Builder (Wise rep))
- Futhark.Optimise.Simplify: [simplifyOpS] :: SimpleOps (rep :: k) -> SimplifyOp rep (Op (Wise rep))
- Futhark.Optimise.Simplify: bindableSimpleOps :: (SimplifiableRep rep, Buildable rep) => SimplifyOp rep (Op (Wise rep)) -> SimpleOps rep
- Futhark.Optimise.Simplify: data HoistBlockers (rep :: k)
- Futhark.Optimise.Simplify: data RuleBook rep
- Futhark.Optimise.Simplify: data SimpleM (rep :: k) a
- Futhark.Optimise.Simplify: data SimpleOps (rep :: k)
- Futhark.Optimise.Simplify: neverHoist :: forall {k} (rep :: k). HoistBlockers rep
- Futhark.Optimise.Simplify: noExtraHoistBlockers :: forall {k} (rep :: k). HoistBlockers rep
- Futhark.Optimise.Simplify: simplifyFun :: (MonadFreshNames m, SimplifiableRep rep) => SimpleOps rep -> RuleBook (Wise rep) -> HoistBlockers rep -> SymbolTable (Wise rep) -> FunDef rep -> m (FunDef rep)
- Futhark.Optimise.Simplify: simplifyLambda :: (MonadFreshNames m, HasScope rep m, SimplifiableRep rep) => SimpleOps rep -> RuleBook (Wise rep) -> HoistBlockers rep -> Lambda rep -> m (Lambda rep)
- Futhark.Optimise.Simplify: simplifyProg :: SimplifiableRep rep => SimpleOps rep -> RuleBook (Wise rep) -> HoistBlockers rep -> Prog rep -> PassM (Prog rep)
- Futhark.Optimise.Simplify: simplifySomething :: (MonadFreshNames m, SimplifiableRep rep) => (a -> SimpleM rep b) -> (b -> a) -> SimpleOps rep -> RuleBook (Wise rep) -> HoistBlockers rep -> SymbolTable (Wise rep) -> a -> m a
- Futhark.Optimise.Simplify: simplifyStms :: (MonadFreshNames m, SimplifiableRep rep) => SimpleOps rep -> RuleBook (Wise rep) -> HoistBlockers rep -> Scope rep -> Stms rep -> m (Stms rep)
- Futhark.Optimise.Simplify: type SimplifiableRep rep = (ASTRep rep, Simplifiable LetDec rep, Simplifiable FParamInfo rep, Simplifiable LParamInfo rep, Simplifiable RetType rep, Simplifiable BranchType rep, TraverseOpStms Wise rep, CanBeWise OpC rep, IndexOp Op Wise rep, IsOp OpC rep, ASTConstraints OpC rep Wise rep, AliasedOp OpC Wise rep, RephraseOp OpC rep, BuilderOps Wise rep, IsOp OpC rep)
- Futhark.Optimise.Simplify: type SimplifyOp (rep :: k) op = op -> SimpleM rep (op, Stms Wise rep)
- Futhark.Optimise.Simplify.Engine: HoistBlockers :: BlockPred (Wise rep) -> BlockPred (Wise rep) -> BlockPred (Wise rep) -> (Stm (Wise rep) -> Bool) -> HoistBlockers (rep :: k)
- Futhark.Optimise.Simplify.Engine: SimpleOps :: (SymbolTable (Wise rep) -> Pat (LetDec (Wise rep)) -> Exp (Wise rep) -> SimpleM rep (ExpDec (Wise rep))) -> (SymbolTable (Wise rep) -> Stms (Wise rep) -> Result -> SimpleM rep (Body (Wise rep))) -> Protect (Builder (Wise rep)) -> (Op (Wise rep) -> UsageTable) -> SimplifyOp rep (Op (Wise rep)) -> SimpleOps (rep :: k)
- Futhark.Optimise.Simplify.Engine: [blockHoistBranch] :: HoistBlockers (rep :: k) -> BlockPred (Wise rep)
- Futhark.Optimise.Simplify.Engine: [blockHoistPar] :: HoistBlockers (rep :: k) -> BlockPred (Wise rep)
- Futhark.Optimise.Simplify.Engine: [blockHoistSeq] :: HoistBlockers (rep :: k) -> BlockPred (Wise rep)
- Futhark.Optimise.Simplify.Engine: [isAllocation] :: HoistBlockers (rep :: k) -> Stm (Wise rep) -> Bool
- Futhark.Optimise.Simplify.Engine: [mkBodyS] :: SimpleOps (rep :: k) -> SymbolTable (Wise rep) -> Stms (Wise rep) -> Result -> SimpleM rep (Body (Wise rep))
- Futhark.Optimise.Simplify.Engine: [mkExpDecS] :: SimpleOps (rep :: k) -> SymbolTable (Wise rep) -> Pat (LetDec (Wise rep)) -> Exp (Wise rep) -> SimpleM rep (ExpDec (Wise rep))
- Futhark.Optimise.Simplify.Engine: [opUsageS] :: SimpleOps (rep :: k) -> Op (Wise rep) -> UsageTable
- Futhark.Optimise.Simplify.Engine: [protectHoistedOpS] :: SimpleOps (rep :: k) -> Protect (Builder (Wise rep))
- Futhark.Optimise.Simplify.Engine: [simplifyOpS] :: SimpleOps (rep :: k) -> SimplifyOp rep (Op (Wise rep))
- Futhark.Optimise.Simplify.Engine: askVtable :: forall {k} (rep :: k). SimpleM rep (SymbolTable (Wise rep))
- Futhark.Optimise.Simplify.Engine: asksEngineEnv :: forall {k} (rep :: k) a. (Env rep -> a) -> SimpleM rep a
- Futhark.Optimise.Simplify.Engine: bindLParams :: SimplifiableRep rep => [LParam (Wise rep)] -> SimpleM rep a -> SimpleM rep a
- Futhark.Optimise.Simplify.Engine: bindableSimpleOps :: (SimplifiableRep rep, Buildable rep) => SimplifyOp rep (Op (Wise rep)) -> SimpleOps rep
- Futhark.Optimise.Simplify.Engine: blockIf :: SimplifiableRep rep => BlockPred (Wise rep) -> Stms (Wise rep) -> SimpleM rep (a, UsageTable) -> SimpleM rep (a, Stms (Wise rep), Stms (Wise rep))
- Futhark.Optimise.Simplify.Engine: blockMigrated :: SimplifiableRep rep => SimpleM rep (Lambda (Wise rep), Stms (Wise rep)) -> SimpleM rep (Lambda (Wise rep), Stms (Wise rep))
- Futhark.Optimise.Simplify.Engine: class Simplifiable e
- Futhark.Optimise.Simplify.Engine: constructBody :: SimplifiableRep rep => Stms (Wise rep) -> Result -> SimpleM rep (Body (Wise rep))
- Futhark.Optimise.Simplify.Engine: data Env (rep :: k)
- Futhark.Optimise.Simplify.Engine: data HoistBlockers (rep :: k)
- Futhark.Optimise.Simplify.Engine: data SimpleM (rep :: k) a
- Futhark.Optimise.Simplify.Engine: data SimpleOps (rep :: k)
- Futhark.Optimise.Simplify.Engine: data SymbolTable rep
- Futhark.Optimise.Simplify.Engine: emptyEnv :: forall {k} (rep :: k). RuleBook (Wise rep) -> HoistBlockers rep -> Env rep
- Futhark.Optimise.Simplify.Engine: enterLoop :: forall {k} (rep :: k) a. SimpleM rep a -> SimpleM rep a
- Futhark.Optimise.Simplify.Engine: hasFree :: ASTRep rep => Names -> BlockPred rep
- Futhark.Optimise.Simplify.Engine: hoistStms :: SimplifiableRep rep => RuleBook (Wise rep) -> BlockPred (Wise rep) -> Stms (Wise rep) -> SimpleM rep (a, UsageTable) -> SimpleM rep (a, Stms (Wise rep), Stms (Wise rep))
- Futhark.Optimise.Simplify.Engine: instance (Futhark.Optimise.Simplify.Engine.Simplifiable a, Futhark.Optimise.Simplify.Engine.Simplifiable b) => Futhark.Optimise.Simplify.Engine.Simplifiable (a, b)
- Futhark.Optimise.Simplify.Engine: instance (Futhark.Optimise.Simplify.Engine.Simplifiable a, Futhark.Optimise.Simplify.Engine.Simplifiable b, Futhark.Optimise.Simplify.Engine.Simplifiable c) => Futhark.Optimise.Simplify.Engine.Simplifiable (a, b, c)
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable ()
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.Syntax.Core.Certs
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.Syntax.Core.ExtSize
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.Syntax.Core.Space
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.Syntax.Core.SubExp
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable Futhark.IR.Syntax.SubExpRes
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable GHC.Types.Int
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable Language.Futhark.Core.VName
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable Language.Futhark.Primitive.PrimType
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable a => Futhark.Optimise.Simplify.Engine.Simplifiable (GHC.Maybe.Maybe a)
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable a => Futhark.Optimise.Simplify.Engine.Simplifiable [a]
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable d => Futhark.Optimise.Simplify.Engine.Simplifiable (Futhark.IR.Syntax.Core.DimIndex d)
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable d => Futhark.Optimise.Simplify.Engine.Simplifiable (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable d => Futhark.Optimise.Simplify.Engine.Simplifiable (Futhark.IR.Syntax.Core.Slice d)
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.Simplifiable shape => Futhark.Optimise.Simplify.Engine.Simplifiable (Futhark.IR.Syntax.Core.TypeBase shape u)
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.SimplifiableRep rep => Futhark.IR.Prop.Scope.HasScope (Futhark.Optimise.Simplify.Rep.Wise rep) (Futhark.Optimise.Simplify.Engine.SimpleM rep)
- Futhark.Optimise.Simplify.Engine: instance Futhark.Optimise.Simplify.Engine.SimplifiableRep rep => Futhark.IR.Prop.Scope.LocalScope (Futhark.Optimise.Simplify.Rep.Wise rep) (Futhark.Optimise.Simplify.Engine.SimpleM rep)
- Futhark.Optimise.Simplify.Engine: instance forall k (rep :: k). Control.Monad.Reader.Class.MonadReader (Futhark.Optimise.Simplify.Engine.SimpleOps rep, Futhark.Optimise.Simplify.Engine.Env rep) (Futhark.Optimise.Simplify.Engine.SimpleM rep)
- Futhark.Optimise.Simplify.Engine: instance forall k (rep :: k). Control.Monad.State.Class.MonadState (Futhark.FreshNames.VNameSource, GHC.Types.Bool, Futhark.IR.Syntax.Core.Certs) (Futhark.Optimise.Simplify.Engine.SimpleM rep)
- Futhark.Optimise.Simplify.Engine: instance forall k (rep :: k). Futhark.MonadFreshNames.MonadFreshNames (Futhark.Optimise.Simplify.Engine.SimpleM rep)
- Futhark.Optimise.Simplify.Engine: instance forall k (rep :: k). GHC.Base.Applicative (Futhark.Optimise.Simplify.Engine.SimpleM rep)
- Futhark.Optimise.Simplify.Engine: instance forall k (rep :: k). GHC.Base.Functor (Futhark.Optimise.Simplify.Engine.SimpleM rep)
- Futhark.Optimise.Simplify.Engine: instance forall k (rep :: k). GHC.Base.Monad (Futhark.Optimise.Simplify.Engine.SimpleM rep)
- Futhark.Optimise.Simplify.Engine: isConsumed :: BlockPred rep
- Futhark.Optimise.Simplify.Engine: isConsuming :: Aliased rep => BlockPred rep
- Futhark.Optimise.Simplify.Engine: isDeviceMigrated :: SimplifiableRep rep => BlockPred (Wise rep)
- Futhark.Optimise.Simplify.Engine: isFalse :: Bool -> BlockPred rep
- Futhark.Optimise.Simplify.Engine: isNotSafe :: ASTRep rep => BlockPred rep
- Futhark.Optimise.Simplify.Engine: isOp :: BlockPred rep
- Futhark.Optimise.Simplify.Engine: localVtable :: forall {k} (rep :: k) a. (SymbolTable (Wise rep) -> SymbolTable (Wise rep)) -> SimpleM rep a -> SimpleM rep a
- Futhark.Optimise.Simplify.Engine: neverBlocks :: BlockPred rep
- Futhark.Optimise.Simplify.Engine: neverHoist :: forall {k} (rep :: k). HoistBlockers rep
- Futhark.Optimise.Simplify.Engine: noExtraHoistBlockers :: forall {k} (rep :: k). HoistBlockers rep
- Futhark.Optimise.Simplify.Engine: orIf :: BlockPred rep -> BlockPred rep -> BlockPred rep
- Futhark.Optimise.Simplify.Engine: runSimpleM :: forall {k} (rep :: k) a. SimpleM rep a -> SimpleOps rep -> Env rep -> VNameSource -> ((a, Bool), VNameSource)
- Futhark.Optimise.Simplify.Engine: simplify :: (Simplifiable e, SimplifiableRep rep) => e -> SimpleM rep e
- Futhark.Optimise.Simplify.Engine: simplifyBody :: SimplifiableRep rep => BlockPred (Wise rep) -> UsageTable -> [Usages] -> Body (Wise rep) -> SimpleM rep (Stms (Wise rep), Body (Wise rep))
- Futhark.Optimise.Simplify.Engine: simplifyFun :: SimplifiableRep rep => FunDef (Wise rep) -> SimpleM rep (FunDef (Wise rep))
- Futhark.Optimise.Simplify.Engine: simplifyLambda :: SimplifiableRep rep => Names -> Lambda (Wise rep) -> SimpleM rep (Lambda (Wise rep), Stms (Wise rep))
- Futhark.Optimise.Simplify.Engine: simplifyLambdaNoHoisting :: SimplifiableRep rep => Lambda (Wise rep) -> SimpleM rep (Lambda (Wise rep))
- Futhark.Optimise.Simplify.Engine: simplifyStms :: SimplifiableRep rep => Stms (Wise rep) -> SimpleM rep (Stms (Wise rep))
- Futhark.Optimise.Simplify.Engine: simplifyStmsWithUsage :: SimplifiableRep rep => UsageTable -> Stms (Wise rep) -> SimpleM rep (Stms (Wise rep))
- Futhark.Optimise.Simplify.Engine: type BlockPred rep = SymbolTable rep -> UsageTable -> Stm rep -> Bool
- Futhark.Optimise.Simplify.Engine: type SimplifiableRep rep = (ASTRep rep, Simplifiable LetDec rep, Simplifiable FParamInfo rep, Simplifiable LParamInfo rep, Simplifiable RetType rep, Simplifiable BranchType rep, TraverseOpStms Wise rep, CanBeWise OpC rep, IndexOp Op Wise rep, IsOp OpC rep, ASTConstraints OpC rep Wise rep, AliasedOp OpC Wise rep, RephraseOp OpC rep, BuilderOps Wise rep, IsOp OpC rep)
- Futhark.Optimise.Simplify.Engine: type SimplifyOp (rep :: k) op = op -> SimpleM rep (op, Stms Wise rep)
- Futhark.Optimise.Simplify.Rep: VarWisdom :: VarAliases -> VarWisdom
- Futhark.Optimise.Simplify.Rep: [varWisdomAliases] :: VarWisdom -> VarAliases
- Futhark.Optimise.Simplify.Rep: addOpWisdom :: (CanBeWise op, Informing rep) => op rep -> op (Wise rep)
- Futhark.Optimise.Simplify.Rep: addScopeWisdom :: Scope rep -> Scope (Wise rep)
- Futhark.Optimise.Simplify.Rep: addWisdomToPat :: Informing rep => Pat (LetDec rep) -> Exp (Wise rep) -> Pat (LetDec (Wise rep))
- Futhark.Optimise.Simplify.Rep: class CanBeWise (op :: Type -> Type)
- Futhark.Optimise.Simplify.Rep: data ExpWisdom
- Futhark.Optimise.Simplify.Rep: data Wise (rep :: k)
- Futhark.Optimise.Simplify.Rep: informBody :: Informing rep => Body rep -> Body (Wise rep)
- Futhark.Optimise.Simplify.Rep: informFunDef :: Informing rep => FunDef rep -> FunDef (Wise rep)
- Futhark.Optimise.Simplify.Rep: informLambda :: Informing rep => Lambda rep -> Lambda (Wise rep)
- Futhark.Optimise.Simplify.Rep: informStms :: Informing rep => Stms rep -> Stms (Wise rep)
- Futhark.Optimise.Simplify.Rep: instance (Futhark.Builder.Class.Buildable rep, Futhark.Optimise.Simplify.Rep.Informing rep) => Futhark.Builder.Class.Buildable (Futhark.Optimise.Simplify.Rep.Wise rep)
- Futhark.Optimise.Simplify.Rep: instance (Futhark.Optimise.Simplify.Rep.Informing rep, Futhark.IR.Prop.IsOp (Futhark.IR.Rep.OpC rep)) => Futhark.IR.Prop.ASTRep (Futhark.Optimise.Simplify.Rep.Wise rep)
- Futhark.Optimise.Simplify.Rep: instance (Futhark.Optimise.Simplify.Rep.Informing rep, GHC.Classes.Ord (Futhark.IR.Rep.OpC rep (Futhark.Optimise.Simplify.Rep.Wise rep)), GHC.Classes.Eq (Futhark.IR.Rep.OpC rep (Futhark.Optimise.Simplify.Rep.Wise rep)), GHC.Show.Show (Futhark.IR.Rep.OpC rep (Futhark.Optimise.Simplify.Rep.Wise rep)), Futhark.IR.Prop.IsOp (Futhark.IR.Rep.OpC rep), Prettyprinter.Internal.Pretty (Futhark.IR.Rep.OpC rep (Futhark.Optimise.Simplify.Rep.Wise rep))) => Futhark.IR.Rep.RepTypes (Futhark.Optimise.Simplify.Rep.Wise rep)
- Futhark.Optimise.Simplify.Rep: instance (Futhark.Optimise.Simplify.Rep.Informing rep, Prettyprinter.Internal.Pretty (Futhark.IR.Rep.OpC rep (Futhark.Optimise.Simplify.Rep.Wise rep))) => Futhark.IR.Pretty.PrettyRep (Futhark.Optimise.Simplify.Rep.Wise rep)
- Futhark.Optimise.Simplify.Rep: instance Futhark.IR.Prop.Aliases.AliasesOf (Futhark.Optimise.Simplify.Rep.VarWisdom, dec)
- Futhark.Optimise.Simplify.Rep: instance Futhark.IR.Prop.Names.FreeDec Futhark.Optimise.Simplify.Rep.BodyWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.IR.Prop.Names.FreeDec Futhark.Optimise.Simplify.Rep.ExpWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.IR.Prop.Names.FreeIn Futhark.Optimise.Simplify.Rep.BodyWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.IR.Prop.Names.FreeIn Futhark.Optimise.Simplify.Rep.ExpWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.IR.Prop.Names.FreeIn Futhark.Optimise.Simplify.Rep.VarWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.Optimise.Simplify.Rep.CanBeWise Futhark.IR.Rep.NoOp
- Futhark.Optimise.Simplify.Rep: instance Futhark.Optimise.Simplify.Rep.Informing rep => Futhark.IR.Prop.Aliases.Aliased (Futhark.Optimise.Simplify.Rep.Wise rep)
- Futhark.Optimise.Simplify.Rep: instance Futhark.Transform.Rename.Rename Futhark.Optimise.Simplify.Rep.BodyWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.Transform.Rename.Rename Futhark.Optimise.Simplify.Rep.ExpWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.Transform.Rename.Rename Futhark.Optimise.Simplify.Rep.VarWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.Transform.Substitute.Substitute Futhark.Optimise.Simplify.Rep.BodyWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.Transform.Substitute.Substitute Futhark.Optimise.Simplify.Rep.ExpWisdom
- Futhark.Optimise.Simplify.Rep: instance Futhark.Transform.Substitute.Substitute Futhark.Optimise.Simplify.Rep.VarWisdom
- Futhark.Optimise.Simplify.Rep: instance GHC.Classes.Eq Futhark.Optimise.Simplify.Rep.BodyWisdom
- Futhark.Optimise.Simplify.Rep: instance GHC.Classes.Eq Futhark.Optimise.Simplify.Rep.ExpWisdom
- Futhark.Optimise.Simplify.Rep: instance GHC.Classes.Eq Futhark.Optimise.Simplify.Rep.VarWisdom
- Futhark.Optimise.Simplify.Rep: instance GHC.Classes.Ord Futhark.Optimise.Simplify.Rep.BodyWisdom
- Futhark.Optimise.Simplify.Rep: instance GHC.Classes.Ord Futhark.Optimise.Simplify.Rep.ExpWisdom
- Futhark.Optimise.Simplify.Rep: instance GHC.Classes.Ord Futhark.Optimise.Simplify.Rep.VarWisdom
- Futhark.Optimise.Simplify.Rep: instance GHC.Show.Show Futhark.Optimise.Simplify.Rep.BodyWisdom
- Futhark.Optimise.Simplify.Rep: instance GHC.Show.Show Futhark.Optimise.Simplify.Rep.ExpWisdom
- Futhark.Optimise.Simplify.Rep: instance GHC.Show.Show Futhark.Optimise.Simplify.Rep.VarWisdom
- Futhark.Optimise.Simplify.Rep: instance Prettyprinter.Internal.Pretty Futhark.Optimise.Simplify.Rep.VarWisdom
- Futhark.Optimise.Simplify.Rep: mkWiseBody :: Informing rep => BodyDec rep -> Stms (Wise rep) -> Result -> Body (Wise rep)
- Futhark.Optimise.Simplify.Rep: mkWiseExpDec :: Informing rep => Pat (LetDec (Wise rep)) -> ExpDec rep -> Exp (Wise rep) -> ExpDec (Wise rep)
- Futhark.Optimise.Simplify.Rep: mkWiseStm :: Informing rep => Pat (LetDec rep) -> StmAux (ExpDec rep) -> Exp (Wise rep) -> Stm (Wise rep)
- Futhark.Optimise.Simplify.Rep: newtype VarWisdom
- Futhark.Optimise.Simplify.Rep: removeBodyWisdom :: RephraseOp (OpC rep) => Body (Wise rep) -> Body rep
- Futhark.Optimise.Simplify.Rep: removeExpWisdom :: RephraseOp (OpC rep) => Exp (Wise rep) -> Exp rep
- Futhark.Optimise.Simplify.Rep: removeFunDefWisdom :: RephraseOp (OpC rep) => FunDef (Wise rep) -> FunDef rep
- Futhark.Optimise.Simplify.Rep: removeLambdaWisdom :: RephraseOp (OpC rep) => Lambda (Wise rep) -> Lambda rep
- Futhark.Optimise.Simplify.Rep: removePatWisdom :: Pat (VarWisdom, a) -> Pat a
- Futhark.Optimise.Simplify.Rep: removeScopeWisdom :: Scope (Wise rep) -> Scope rep
- Futhark.Optimise.Simplify.Rep: removeStmWisdom :: RephraseOp (OpC rep) => Stm (Wise rep) -> Stm rep
- Futhark.Optimise.Simplify.Rep: type Informing rep = (ASTRep rep, AliasedOp OpC rep, RephraseOp OpC rep, CanBeWise OpC rep, FreeIn OpC rep Wise rep, ASTConstraints OpC rep Wise rep)
- Futhark.Optimise.Simplify.Rule: RuleBasicOp :: RuleBasicOp rep a -> SimplificationRule rep a
- Futhark.Optimise.Simplify.Rule: RuleGeneric :: RuleGeneric rep a -> SimplificationRule rep a
- Futhark.Optimise.Simplify.Rule: RuleLoop :: RuleLoop rep a -> SimplificationRule rep a
- Futhark.Optimise.Simplify.Rule: RuleMatch :: RuleMatch rep a -> SimplificationRule rep a
- Futhark.Optimise.Simplify.Rule: RuleOp :: RuleOp rep a -> SimplificationRule rep a
- Futhark.Optimise.Simplify.Rule: Simplify :: RuleM rep () -> Rule rep
- Futhark.Optimise.Simplify.Rule: Skip :: Rule rep
- Futhark.Optimise.Simplify.Rule: bottomUpSimplifyStm :: (MonadFreshNames m, HasScope rep m, PrettyRep rep) => RuleBook rep -> (SymbolTable rep, UsageTable) -> Stm rep -> m (Maybe (Stms rep))
- Futhark.Optimise.Simplify.Rule: cannotSimplify :: RuleM rep a
- Futhark.Optimise.Simplify.Rule: data Rule rep
- Futhark.Optimise.Simplify.Rule: data RuleBook rep
- Futhark.Optimise.Simplify.Rule: data RuleM rep a
- Futhark.Optimise.Simplify.Rule: data SimplificationRule rep a
- Futhark.Optimise.Simplify.Rule: instance Futhark.Builder.BuilderOps rep => Futhark.Builder.Class.MonadBuilder (Futhark.Optimise.Simplify.Rule.RuleM rep)
- Futhark.Optimise.Simplify.Rule: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Scope.HasScope rep (Futhark.Optimise.Simplify.Rule.RuleM rep)
- Futhark.Optimise.Simplify.Rule: instance Futhark.IR.Prop.ASTRep rep => Futhark.IR.Prop.Scope.LocalScope rep (Futhark.Optimise.Simplify.Rule.RuleM rep)
- Futhark.Optimise.Simplify.Rule: instance Futhark.MonadFreshNames.MonadFreshNames (Futhark.Optimise.Simplify.Rule.RuleM rep)
- Futhark.Optimise.Simplify.Rule: instance GHC.Base.Applicative (Futhark.Optimise.Simplify.Rule.RuleM rep)
- Futhark.Optimise.Simplify.Rule: instance GHC.Base.Functor (Futhark.Optimise.Simplify.Rule.RuleM rep)
- Futhark.Optimise.Simplify.Rule: instance GHC.Base.Monad (Futhark.Optimise.Simplify.Rule.RuleM rep)
- Futhark.Optimise.Simplify.Rule: instance GHC.Base.Monoid (Futhark.Optimise.Simplify.Rule.RuleBook rep)
- Futhark.Optimise.Simplify.Rule: instance GHC.Base.Monoid (Futhark.Optimise.Simplify.Rule.Rules rep a)
- Futhark.Optimise.Simplify.Rule: instance GHC.Base.Semigroup (Futhark.Optimise.Simplify.Rule.RuleBook rep)
- Futhark.Optimise.Simplify.Rule: instance GHC.Base.Semigroup (Futhark.Optimise.Simplify.Rule.Rules rep a)
- Futhark.Optimise.Simplify.Rule: liftMaybe :: Maybe a -> RuleM rep a
- Futhark.Optimise.Simplify.Rule: ruleBook :: [TopDownRule m] -> [BottomUpRule m] -> RuleBook m
- Futhark.Optimise.Simplify.Rule: topDownSimplifyStm :: (MonadFreshNames m, HasScope rep m, PrettyRep rep) => RuleBook rep -> SymbolTable rep -> Stm rep -> m (Maybe (Stms rep))
- Futhark.Optimise.Simplify.Rule: type BottomUp rep = (SymbolTable rep, UsageTable)
- Futhark.Optimise.Simplify.Rule: type BottomUpRule rep = SimplificationRule rep BottomUp rep
- Futhark.Optimise.Simplify.Rule: type BottomUpRuleBasicOp rep = RuleBasicOp rep BottomUp rep
- Futhark.Optimise.Simplify.Rule: type BottomUpRuleGeneric rep = RuleGeneric rep BottomUp rep
- Futhark.Optimise.Simplify.Rule: type BottomUpRuleLoop rep = RuleLoop rep BottomUp rep
- Futhark.Optimise.Simplify.Rule: type BottomUpRuleMatch rep = RuleMatch rep BottomUp rep
- Futhark.Optimise.Simplify.Rule: type BottomUpRuleOp rep = RuleOp rep BottomUp rep
- Futhark.Optimise.Simplify.Rule: type RuleBasicOp rep a = a -> Pat LetDec rep -> StmAux ExpDec rep -> BasicOp -> Rule rep
- Futhark.Optimise.Simplify.Rule: type RuleGeneric rep a = a -> Stm rep -> Rule rep
- Futhark.Optimise.Simplify.Rule: type RuleLoop rep a = a -> Pat LetDec rep -> StmAux ExpDec rep -> ([(FParam rep, SubExp)], LoopForm, Body rep) -> Rule rep
- Futhark.Optimise.Simplify.Rule: type RuleMatch rep a = a -> Pat LetDec rep -> StmAux ExpDec rep -> ([SubExp], [Case Body rep], Body rep, MatchDec BranchType rep) -> Rule rep
- Futhark.Optimise.Simplify.Rule: type TopDown rep = SymbolTable rep
- Futhark.Optimise.Simplify.Rule: type TopDownRule rep = SimplificationRule rep TopDown rep
- Futhark.Optimise.Simplify.Rule: type TopDownRuleBasicOp rep = RuleBasicOp rep TopDown rep
- Futhark.Optimise.Simplify.Rule: type TopDownRuleGeneric rep = RuleGeneric rep TopDown rep
- Futhark.Optimise.Simplify.Rule: type TopDownRuleLoop rep = RuleLoop rep TopDown rep
- Futhark.Optimise.Simplify.Rule: type TopDownRuleMatch rep = RuleMatch rep TopDown rep
- Futhark.Optimise.Simplify.Rule: type TopDownRuleOp rep = RuleOp rep TopDown rep
- Futhark.Optimise.Simplify.Rules: removeUnnecessaryCopy :: BuilderOps rep => BottomUpRuleBasicOp rep
- Futhark.Optimise.Simplify.Rules: standardRules :: (BuilderOps rep, TraverseOpStms rep) => RuleBook rep
- Futhark.Optimise.Simplify.Rules.BasicOp: basicOpRules :: BuilderOps rep => RuleBook rep
- Futhark.Optimise.Simplify.Rules.ClosedForm: foldClosedForm :: BuilderOps rep => VarLookup rep -> Pat (LetDec rep) -> Lambda rep -> [SubExp] -> [VName] -> RuleM rep ()
- Futhark.Optimise.Simplify.Rules.ClosedForm: loopClosedForm :: BuilderOps rep => Pat (LetDec rep) -> [(FParam rep, SubExp)] -> Names -> IntType -> SubExp -> Body rep -> RuleM rep ()
- Futhark.Optimise.Simplify.Rules.Index: IndexResult :: Certs -> VName -> Slice SubExp -> IndexResult
- Futhark.Optimise.Simplify.Rules.Index: SubExpResult :: Certs -> SubExp -> IndexResult
- Futhark.Optimise.Simplify.Rules.Index: data IndexResult
- Futhark.Optimise.Simplify.Rules.Index: simplifyIndexing :: MonadBuilder m => SymbolTable (Rep m) -> TypeLookup -> VName -> Slice SubExp -> Bool -> (VName -> Bool) -> Maybe (m IndexResult)
- Futhark.Optimise.Simplify.Rules.Loop: loopRules :: BuilderOps rep => RuleBook rep
- Futhark.Optimise.Simplify.Rules.Match: matchRules :: BuilderOps rep => RuleBook rep
- Futhark.Optimise.Simplify.Rules.Simple: applySimpleRules :: VarLookup rep -> TypeLookup -> BasicOp -> Maybe (BasicOp, Certs)
- Futhark.Optimise.Simplify.Rules.Simple: type TypeLookup = SubExp -> Maybe Type
- Futhark.Optimise.Simplify.Rules.Simple: type VarLookup rep = VName -> Maybe (Exp rep, Certs)
- Futhark.Optimise.Sink: sinkGPU :: Pass GPU GPU
- Futhark.Optimise.Sink: sinkMC :: Pass MC MC
- Futhark.Optimise.TileLoops: instance GHC.Base.Monoid Futhark.Optimise.TileLoops.PrivStms
- Futhark.Optimise.TileLoops: instance GHC.Base.Semigroup Futhark.Optimise.TileLoops.PrivStms
- Futhark.Optimise.TileLoops: tileLoops :: Pass GPU GPU
- Futhark.Optimise.TileLoops.Shared: TileFull :: TileKind
- Futhark.Optimise.TileLoops.Shared: TilePartial :: TileKind
- Futhark.Optimise.TileLoops.Shared: changeEnv :: Env -> VName -> Exp GPU -> TileM Env
- Futhark.Optimise.TileLoops.Shared: data TileKind
- Futhark.Optimise.TileLoops.Shared: forLoop :: SubExp -> [VName] -> (VName -> [VName] -> Builder GPU (Body GPU)) -> Builder GPU VName
- Futhark.Optimise.TileLoops.Shared: forLoop' :: SubExp -> [VName] -> (VName -> [VName] -> Builder GPU (Body GPU)) -> Builder GPU [VName]
- Futhark.Optimise.TileLoops.Shared: index :: MonadBuilder m => String -> VName -> [VName] -> m VName
- Futhark.Optimise.TileLoops.Shared: initialIxFnEnv :: Scope GPU -> IxFnEnv
- Futhark.Optimise.TileLoops.Shared: isTileableRedomap :: Stm GPU -> Maybe (SubExp, [VName], (Commutativity, Lambda GPU, [SubExp], Lambda GPU))
- Futhark.Optimise.TileLoops.Shared: segMap1D :: String -> SegLevel -> ResultManifest -> SubExp -> (VName -> Builder GPU Result) -> Builder GPU [VName]
- Futhark.Optimise.TileLoops.Shared: segMap2D :: String -> SegLevel -> ResultManifest -> (SubExp, SubExp) -> ((VName, VName) -> Builder GPU Result) -> Builder GPU [VName]
- Futhark.Optimise.TileLoops.Shared: segMap3D :: String -> SegLevel -> ResultManifest -> (SubExp, SubExp, SubExp) -> ((VName, VName, VName) -> Builder GPU Result) -> Builder GPU [VName]
- Futhark.Optimise.TileLoops.Shared: segScatter2D :: String -> VName -> [SubExp] -> (SubExp, SubExp) -> ([VName] -> (VName, VName) -> Builder GPU (SubExp, SubExp)) -> Builder GPU VName
- Futhark.Optimise.TileLoops.Shared: type Env = (WithEnv, IxFnEnv)
- Futhark.Optimise.TileLoops.Shared: type TileM = ReaderT Scope GPU State VNameSource
- Futhark.Optimise.TileLoops.Shared: type VarianceTable = Map VName Names
- Futhark.Optimise.TileLoops.Shared: update :: MonadBuilder m => String -> VName -> [VName] -> SubExp -> m VName
- Futhark.Optimise.TileLoops.Shared: varianceInStms :: VarianceTable -> Stms GPU -> VarianceTable
- Futhark.Optimise.Unstream: unstreamGPU :: Pass GPU GPU
- Futhark.Optimise.Unstream: unstreamMC :: Pass MC MC
- Futhark.Pass: Pass :: String -> String -> (Prog fromrep -> PassM (Prog torep)) -> Pass fromrep torep
- Futhark.Pass: [passDescription] :: Pass fromrep torep -> String
- Futhark.Pass: [passFunction] :: Pass fromrep torep -> Prog fromrep -> PassM (Prog torep)
- Futhark.Pass: [passName] :: Pass fromrep torep -> String
- Futhark.Pass: data Pass fromrep torep
- Futhark.Pass: data PassM a
- Futhark.Pass: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Pass.PassM
- Futhark.Pass: instance Futhark.Util.Log.MonadLogger Futhark.Pass.PassM
- Futhark.Pass: instance GHC.Base.Applicative Futhark.Pass.PassM
- Futhark.Pass: instance GHC.Base.Functor Futhark.Pass.PassM
- Futhark.Pass: instance GHC.Base.Monad Futhark.Pass.PassM
- Futhark.Pass: intraproceduralTransformation :: (Scope rep -> Stms rep -> PassM (Stms rep)) -> Prog rep -> PassM (Prog rep)
- Futhark.Pass: intraproceduralTransformationWithConsts :: (Stms fromrep -> PassM (Stms torep)) -> (Stms torep -> FunDef fromrep -> PassM (FunDef torep)) -> Prog fromrep -> PassM (Prog torep)
- Futhark.Pass: parPass :: (a -> PassM b) -> [a] -> PassM [b]
- Futhark.Pass: passLongOption :: Pass fromrep torep -> String
- Futhark.Pass: runPassM :: MonadFreshNames m => PassM a -> m (a, Log)
- Futhark.Pass.AD: applyAD :: Pass SOACS SOACS
- Futhark.Pass.AD: applyADInnermost :: Pass SOACS SOACS
- Futhark.Pass.AD: instance GHC.Classes.Eq Futhark.Pass.AD.Mode
- Futhark.Pass.ExpandAllocations: expandAllocations :: Pass GPUMem GPUMem
- Futhark.Pass.ExpandAllocations: instance Control.Monad.Error.Class.MonadError GHC.Base.String Futhark.Pass.ExpandAllocations.OffsetM
- Futhark.Pass.ExpandAllocations: instance Futhark.Builder.Class.MonadBuilder Futhark.Pass.ExpandAllocations.OffsetM
- Futhark.Pass.ExpandAllocations: instance Futhark.IR.Prop.Scope.HasScope Futhark.IR.GPUMem.GPUMem Futhark.Pass.ExpandAllocations.OffsetM
- Futhark.Pass.ExpandAllocations: instance Futhark.IR.Prop.Scope.LocalScope Futhark.IR.GPUMem.GPUMem Futhark.Pass.ExpandAllocations.OffsetM
- Futhark.Pass.ExpandAllocations: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Pass.ExpandAllocations.OffsetM
- Futhark.Pass.ExpandAllocations: instance GHC.Base.Applicative Futhark.Pass.ExpandAllocations.OffsetM
- Futhark.Pass.ExpandAllocations: instance GHC.Base.Functor Futhark.Pass.ExpandAllocations.OffsetM
- Futhark.Pass.ExpandAllocations: instance GHC.Base.Monad Futhark.Pass.ExpandAllocations.OffsetM
- Futhark.Pass.ExplicitAllocations: AllocEnv :: Space -> Set VName -> (Op fromrep -> AllocM fromrep torep (Op torep)) -> (Exp torep -> AllocM fromrep torep [ExpHint]) -> AllocEnv fromrep torep
- Futhark.Pass.ExplicitAllocations: Hint :: LMAD -> Space -> ExpHint
- Futhark.Pass.ExplicitAllocations: NoHint :: ExpHint
- Futhark.Pass.ExplicitAllocations: [allocInOp] :: AllocEnv fromrep torep -> Op fromrep -> AllocM fromrep torep (Op torep)
- Futhark.Pass.ExplicitAllocations: [allocSpace] :: AllocEnv fromrep torep -> Space
- Futhark.Pass.ExplicitAllocations: [envConsts] :: AllocEnv fromrep torep -> Set VName
- Futhark.Pass.ExplicitAllocations: [envExpHints] :: AllocEnv fromrep torep -> Exp torep -> AllocM fromrep torep [ExpHint]
- Futhark.Pass.ExplicitAllocations: allocForArray :: forall fromrep torep (inner :: Type -> Type). Allocable fromrep torep inner => Type -> Space -> AllocM fromrep torep VName
- Futhark.Pass.ExplicitAllocations: allocInStms :: forall fromrep torep (inner :: Type -> Type) a. Allocable fromrep torep inner => Stms fromrep -> AllocM fromrep torep a -> AllocM fromrep torep a
- Futhark.Pass.ExplicitAllocations: askDefaultSpace :: AllocM fromrep torep Space
- Futhark.Pass.ExplicitAllocations: class SizeSubst op
- Futhark.Pass.ExplicitAllocations: data AllocEnv fromrep torep
- Futhark.Pass.ExplicitAllocations: data AllocM fromrep torep a
- Futhark.Pass.ExplicitAllocations: data ExpHint
- Futhark.Pass.ExplicitAllocations: defaultExpHints :: (ASTRep rep, HasScope rep m) => Exp rep -> m [ExpHint]
- Futhark.Pass.ExplicitAllocations: explicitAllocationsGeneric :: forall fromrep torep (inner :: Type -> Type). Allocable fromrep torep inner => Space -> (Op fromrep -> AllocM fromrep torep (Op torep)) -> (Exp torep -> AllocM fromrep torep [ExpHint]) -> Pass fromrep torep
- Futhark.Pass.ExplicitAllocations: explicitAllocationsInStmsGeneric :: forall m torep fromrep (inner :: Type -> Type). (MonadFreshNames m, HasScope torep m, Allocable fromrep torep inner) => Space -> (Op fromrep -> AllocM fromrep torep (Op torep)) -> (Exp torep -> AllocM fromrep torep [ExpHint]) -> Stms fromrep -> m (Stms torep)
- Futhark.Pass.ExplicitAllocations: instance Control.Monad.Reader.Class.MonadReader (Futhark.Pass.ExplicitAllocations.AllocEnv fromrep torep) (Futhark.Pass.ExplicitAllocations.AllocM fromrep torep)
- Futhark.Pass.ExplicitAllocations: instance Futhark.IR.Prop.ASTRep torep => Futhark.IR.Prop.Scope.HasScope torep (Futhark.Pass.ExplicitAllocations.AllocM fromrep torep)
- Futhark.Pass.ExplicitAllocations: instance Futhark.IR.Prop.ASTRep torep => Futhark.IR.Prop.Scope.LocalScope torep (Futhark.Pass.ExplicitAllocations.AllocM fromrep torep)
- Futhark.Pass.ExplicitAllocations: instance Futhark.MonadFreshNames.MonadFreshNames (Futhark.Pass.ExplicitAllocations.AllocM fromrep torep)
- Futhark.Pass.ExplicitAllocations: instance Futhark.Pass.ExplicitAllocations.Allocable fromrep torep inner => Futhark.Builder.Class.MonadBuilder (Futhark.Pass.ExplicitAllocations.AllocM fromrep torep)
- Futhark.Pass.ExplicitAllocations: instance Futhark.Pass.ExplicitAllocations.SizeSubst (op rep) => Futhark.Pass.ExplicitAllocations.SizeSubst (Futhark.IR.Mem.MemOp op rep)
- Futhark.Pass.ExplicitAllocations: instance GHC.Base.Applicative (Futhark.Pass.ExplicitAllocations.AllocM fromrep torep)
- Futhark.Pass.ExplicitAllocations: instance GHC.Base.Functor (Futhark.Pass.ExplicitAllocations.AllocM fromrep torep)
- Futhark.Pass.ExplicitAllocations: instance GHC.Base.Monad (Futhark.Pass.ExplicitAllocations.AllocM fromrep torep)
- Futhark.Pass.ExplicitAllocations: instance GHC.Classes.Eq Futhark.Pass.ExplicitAllocations.MemReq
- Futhark.Pass.ExplicitAllocations: instance GHC.Show.Show Futhark.Pass.ExplicitAllocations.MemReq
- Futhark.Pass.ExplicitAllocations: instance forall k (rep :: k). Futhark.Pass.ExplicitAllocations.SizeSubst (Futhark.IR.Rep.NoOp rep)
- Futhark.Pass.ExplicitAllocations: mkLetNamesB' :: forall m (inner :: Type -> Type). (LetDec (Rep m) ~ LetDecMem, Mem (Rep m) inner, MonadBuilder m, ExpDec (Rep m) ~ ()) => Space -> ExpDec (Rep m) -> [VName] -> Exp (Rep m) -> m (Stm (Rep m))
- Futhark.Pass.ExplicitAllocations: mkLetNamesB'' :: forall rep (inner :: Type -> Type) m. (Mem rep inner, LetDec rep ~ LetDecMem, OpReturns inner, ExpDec rep ~ (), Rep m ~ Wise rep, HasScope (Wise rep) m, MonadBuilder m, AliasedOp inner, RephraseOp (MemOp inner), CanBeWise inner, ASTConstraints (inner (Wise rep))) => Space -> [VName] -> Exp (Wise rep) -> m (Stm (Wise rep))
- Futhark.Pass.ExplicitAllocations: opIsConst :: SizeSubst op => op -> Bool
- Futhark.Pass.ExplicitAllocations: simplifiable :: (SimplifiableRep rep, LetDec rep ~ LetDecMem, ExpDec rep ~ (), BodyDec rep ~ (), Mem (Wise rep) inner, CanBeWise inner, RephraseOp inner, IsOp inner, OpReturns inner, AliasedOp inner, IndexOp (inner (Wise rep))) => (inner (Wise rep) -> UsageTable) -> (inner (Wise rep) -> SimpleM rep (inner (Wise rep), Stms (Wise rep))) -> SimpleOps rep
- Futhark.Pass.ExplicitAllocations: type Allocable fromrep torep (inner :: Type -> Type) = (PrettyRep fromrep, PrettyRep torep, Mem torep inner, LetDec torep ~ LetDecMem, FParamInfo fromrep ~ DeclType, LParamInfo fromrep ~ Type, BranchType fromrep ~ ExtType, RetType fromrep ~ DeclExtType, BodyDec fromrep ~ (), BodyDec torep ~ (), ExpDec torep ~ (), SizeSubst inner torep, BuilderOps torep)
- Futhark.Pass.ExplicitAllocations.GPU: explicitAllocations :: Pass GPU GPUMem
- Futhark.Pass.ExplicitAllocations.GPU: explicitAllocationsInStms :: (MonadFreshNames m, HasScope GPUMem m) => Stms GPU -> m (Stms GPUMem)
- Futhark.Pass.ExplicitAllocations.GPU: instance Futhark.Pass.ExplicitAllocations.SizeSubst (Futhark.IR.GPU.Op.HostOp rep op)
- Futhark.Pass.ExplicitAllocations.MC: explicitAllocations :: Pass MC MCMem
- Futhark.Pass.ExplicitAllocations.MC: instance Futhark.Pass.ExplicitAllocations.SizeSubst (Futhark.IR.MC.Op.MCOp rep op)
- Futhark.Pass.ExplicitAllocations.SegOp: allocInBinOpLambda :: forall fromrep torep (inner :: Type -> Type). Allocable fromrep torep inner => SubExp -> SegSpace -> Lambda fromrep -> AllocM fromrep torep (Lambda torep)
- Futhark.Pass.ExplicitAllocations.SegOp: allocInKernelBody :: forall fromrep torep (inner :: Type -> Type). Allocable fromrep torep inner => KernelBody fromrep -> AllocM fromrep torep (KernelBody torep)
- Futhark.Pass.ExplicitAllocations.SegOp: instance Futhark.Pass.ExplicitAllocations.SizeSubst (Futhark.IR.SegOp.SegOp lvl rep)
- Futhark.Pass.ExplicitAllocations.Seq: explicitAllocations :: Pass Seq SeqMem
- Futhark.Pass.ExplicitAllocations.Seq: simplifiable :: (SimplifiableRep rep, LetDec rep ~ LetDecMem, ExpDec rep ~ (), BodyDec rep ~ (), Mem (Wise rep) inner, CanBeWise inner, RephraseOp inner, IsOp inner, OpReturns inner, AliasedOp inner, IndexOp (inner (Wise rep))) => (inner (Wise rep) -> UsageTable) -> (inner (Wise rep) -> SimpleM rep (inner (Wise rep), Stms (Wise rep))) -> SimpleOps rep
- Futhark.Pass.ExtractKernels: extractKernels :: Pass SOACS GPU
- Futhark.Pass.ExtractKernels: instance Control.Monad.State.Class.MonadState Futhark.Pass.ExtractKernels.State Futhark.Pass.ExtractKernels.DistribM
- Futhark.Pass.ExtractKernels: instance Futhark.IR.Prop.Scope.HasScope Futhark.IR.GPU.GPU Futhark.Pass.ExtractKernels.DistribM
- Futhark.Pass.ExtractKernels: instance Futhark.IR.Prop.Scope.LocalScope Futhark.IR.GPU.GPU Futhark.Pass.ExtractKernels.DistribM
- Futhark.Pass.ExtractKernels: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Pass.ExtractKernels.DistribM
- Futhark.Pass.ExtractKernels: instance Futhark.Util.Log.MonadLogger Futhark.Pass.ExtractKernels.DistribM
- Futhark.Pass.ExtractKernels: instance GHC.Base.Applicative Futhark.Pass.ExtractKernels.DistribM
- Futhark.Pass.ExtractKernels: instance GHC.Base.Functor Futhark.Pass.ExtractKernels.DistribM
- Futhark.Pass.ExtractKernels: instance GHC.Base.Monad Futhark.Pass.ExtractKernels.DistribM
- Futhark.Pass.ExtractKernels.BlockedKernel: KernelInput :: VName -> Type -> VName -> [SubExp] -> KernelInput
- Futhark.Pass.ExtractKernels.BlockedKernel: ManyThreads :: ThreadRecommendation
- Futhark.Pass.ExtractKernels.BlockedKernel: NoRecommendation :: SegVirt -> ThreadRecommendation
- Futhark.Pass.ExtractKernels.BlockedKernel: [kernelInputArray] :: KernelInput -> VName
- Futhark.Pass.ExtractKernels.BlockedKernel: [kernelInputIndices] :: KernelInput -> [SubExp]
- Futhark.Pass.ExtractKernels.BlockedKernel: [kernelInputName] :: KernelInput -> VName
- Futhark.Pass.ExtractKernels.BlockedKernel: [kernelInputType] :: KernelInput -> Type
- Futhark.Pass.ExtractKernels.BlockedKernel: data KernelInput
- Futhark.Pass.ExtractKernels.BlockedKernel: data ThreadRecommendation
- Futhark.Pass.ExtractKernels.BlockedKernel: dummyDim :: MonadBuilder m => Pat Type -> m (Pat Type, [(VName, SubExp)], m ())
- Futhark.Pass.ExtractKernels.BlockedKernel: instance GHC.Show.Show Futhark.Pass.ExtractKernels.BlockedKernel.KernelInput
- Futhark.Pass.ExtractKernels.BlockedKernel: mapKernel :: (DistRep rep, HasScope rep m, MonadFreshNames m) => MkSegLevel rep m -> [(VName, SubExp)] -> [KernelInput] -> [Type] -> KernelBody rep -> m (SegOp (SegOpLevel rep) rep, Stms rep)
- Futhark.Pass.ExtractKernels.BlockedKernel: mkSegSpace :: MonadFreshNames m => [(VName, SubExp)] -> m SegSpace
- Futhark.Pass.ExtractKernels.BlockedKernel: nonSegRed :: (MonadFreshNames m, DistRep rep, HasScope rep m) => SegOpLevel rep -> Pat Type -> SubExp -> [SegBinOp rep] -> Lambda rep -> [VName] -> m (Stms rep)
- Futhark.Pass.ExtractKernels.BlockedKernel: readKernelInput :: (DistRep (Rep m), MonadBuilder m) => KernelInput -> m ()
- Futhark.Pass.ExtractKernels.BlockedKernel: segHist :: (DistRep rep, MonadFreshNames m, HasScope rep m) => SegOpLevel rep -> Pat Type -> SubExp -> [(VName, SubExp)] -> [KernelInput] -> [HistOp rep] -> Lambda rep -> [VName] -> m (Stms rep)
- Futhark.Pass.ExtractKernels.BlockedKernel: segMap :: (MonadFreshNames m, DistRep rep, HasScope rep m) => SegOpLevel rep -> Pat (LetDec rep) -> SubExp -> Lambda rep -> [VName] -> [(VName, SubExp)] -> [KernelInput] -> m (Stms rep)
- Futhark.Pass.ExtractKernels.BlockedKernel: segRed :: (MonadFreshNames m, DistRep rep, HasScope rep m) => SegOpLevel rep -> Pat (LetDec rep) -> Certs -> SubExp -> [SegBinOp rep] -> Lambda rep -> [VName] -> [(VName, SubExp)] -> [KernelInput] -> m (Stms rep)
- Futhark.Pass.ExtractKernels.BlockedKernel: segScan :: (MonadFreshNames m, DistRep rep, HasScope rep m) => SegOpLevel rep -> Pat (LetDec rep) -> Certs -> SubExp -> [SegBinOp rep] -> Lambda rep -> [VName] -> [(VName, SubExp)] -> [KernelInput] -> m (Stms rep)
- Futhark.Pass.ExtractKernels.BlockedKernel: type DistRep rep = (Buildable rep, HasSegOp rep, BuilderOps rep, LetDec rep ~ Type, ExpDec rep ~ (), BodyDec rep ~ (), AliasableRep rep)
- Futhark.Pass.ExtractKernels.BlockedKernel: type MkSegLevel rep (m :: Type -> Type) = [SubExp] -> String -> ThreadRecommendation -> BuilderT rep m SegOpLevel rep
- Futhark.Pass.ExtractKernels.DistributeNests: DistAcc :: Targets -> Stms rep -> DistAcc rep
- Futhark.Pass.ExtractKernels.DistributeNests: DistEnv :: Nestings -> Scope rep -> (Stms SOACS -> DistNestT rep m (Stms rep)) -> (MapLoop -> DistAcc rep -> DistNestT rep m (DistAcc rep)) -> (Stm SOACS -> Builder rep (Stms rep)) -> (Lambda SOACS -> Builder rep (Lambda rep)) -> MkSegLevel rep m -> DistEnv rep (m :: Type -> Type)
- Futhark.Pass.ExtractKernels.DistributeNests: MapLoop :: Pat Type -> StmAux () -> SubExp -> Lambda SOACS -> [VName] -> MapLoop
- Futhark.Pass.ExtractKernels.DistributeNests: [distNest] :: DistEnv rep (m :: Type -> Type) -> Nestings
- Futhark.Pass.ExtractKernels.DistributeNests: [distOnInnerMap] :: DistEnv rep (m :: Type -> Type) -> MapLoop -> DistAcc rep -> DistNestT rep m (DistAcc rep)
- Futhark.Pass.ExtractKernels.DistributeNests: [distOnSOACSLambda] :: DistEnv rep (m :: Type -> Type) -> Lambda SOACS -> Builder rep (Lambda rep)
- Futhark.Pass.ExtractKernels.DistributeNests: [distOnSOACSStms] :: DistEnv rep (m :: Type -> Type) -> Stm SOACS -> Builder rep (Stms rep)
- Futhark.Pass.ExtractKernels.DistributeNests: [distOnTopLevelStms] :: DistEnv rep (m :: Type -> Type) -> Stms SOACS -> DistNestT rep m (Stms rep)
- Futhark.Pass.ExtractKernels.DistributeNests: [distScope] :: DistEnv rep (m :: Type -> Type) -> Scope rep
- Futhark.Pass.ExtractKernels.DistributeNests: [distSegLevel] :: DistEnv rep (m :: Type -> Type) -> MkSegLevel rep m
- Futhark.Pass.ExtractKernels.DistributeNests: [distStms] :: DistAcc rep -> Stms rep
- Futhark.Pass.ExtractKernels.DistributeNests: [distTargets] :: DistAcc rep -> Targets
- Futhark.Pass.ExtractKernels.DistributeNests: addPostStms :: forall (m :: Type -> Type) rep. Monad m => PostStms rep -> DistNestT rep m ()
- Futhark.Pass.ExtractKernels.DistributeNests: addStmToAcc :: forall (m :: Type -> Type) rep. (MonadFreshNames m, DistRep rep) => Stm SOACS -> DistAcc rep -> DistNestT rep m (DistAcc rep)
- Futhark.Pass.ExtractKernels.DistributeNests: addStmsToAcc :: Stms rep -> DistAcc rep -> DistAcc rep
- Futhark.Pass.ExtractKernels.DistributeNests: bodyContainsParallelism :: Body SOACS -> Bool
- Futhark.Pass.ExtractKernels.DistributeNests: data DistAcc rep
- Futhark.Pass.ExtractKernels.DistributeNests: data DistEnv rep (m :: Type -> Type)
- Futhark.Pass.ExtractKernels.DistributeNests: data DistNestT rep (m :: Type -> Type) a
- Futhark.Pass.ExtractKernels.DistributeNests: data MapLoop
- Futhark.Pass.ExtractKernels.DistributeNests: determineReduceOp :: MonadBuilder m => Lambda SOACS -> [SubExp] -> m (Lambda SOACS, [SubExp], Shape)
- Futhark.Pass.ExtractKernels.DistributeNests: distribute :: forall (m :: Type -> Type) rep. (MonadFreshNames m, LocalScope rep m, DistRep rep) => DistAcc rep -> DistNestT rep m (DistAcc rep)
- Futhark.Pass.ExtractKernels.DistributeNests: distributeMap :: forall (m :: Type -> Type) rep. (MonadFreshNames m, LocalScope rep m, DistRep rep) => MapLoop -> DistAcc rep -> DistNestT rep m (DistAcc rep)
- Futhark.Pass.ExtractKernels.DistributeNests: distributeMapBodyStms :: forall (m :: Type -> Type) rep. (MonadFreshNames m, LocalScope rep m, DistRep rep) => DistAcc rep -> Stms SOACS -> DistNestT rep m (DistAcc rep)
- Futhark.Pass.ExtractKernels.DistributeNests: distributeSingleStm :: forall (m :: Type -> Type) rep. (MonadFreshNames m, LocalScope rep m, DistRep rep) => DistAcc rep -> Stm SOACS -> DistNestT rep m (Maybe (PostStms rep, Result, KernelNest, DistAcc rep))
- Futhark.Pass.ExtractKernels.DistributeNests: histKernel :: (MonadBuilder m, DistRep (Rep m)) => (Lambda SOACS -> m (Lambda (Rep m))) -> SegOpLevel (Rep m) -> Pat Type -> [(VName, SubExp)] -> [KernelInput] -> Certs -> SubExp -> [HistOp SOACS] -> Lambda (Rep m) -> [VName] -> m (Stms (Rep m))
- Futhark.Pass.ExtractKernels.DistributeNests: inNesting :: forall (m :: Type -> Type) rep a. (Monad m, DistRep rep) => KernelNest -> DistNestT rep m a -> DistNestT rep m a
- Futhark.Pass.ExtractKernels.DistributeNests: instance (GHC.Base.Monad m, Futhark.IR.Prop.ASTRep rep) => Futhark.IR.Prop.Scope.HasScope rep (Futhark.Pass.ExtractKernels.DistributeNests.DistNestT rep m)
- Futhark.Pass.ExtractKernels.DistributeNests: instance (GHC.Base.Monad m, Futhark.IR.Prop.ASTRep rep) => Futhark.IR.Prop.Scope.LocalScope rep (Futhark.Pass.ExtractKernels.DistributeNests.DistNestT rep m)
- Futhark.Pass.ExtractKernels.DistributeNests: instance Futhark.MonadFreshNames.MonadFreshNames m => Futhark.MonadFreshNames.MonadFreshNames (Futhark.Pass.ExtractKernels.DistributeNests.DistNestT rep m)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Applicative m => GHC.Base.Applicative (Futhark.Pass.ExtractKernels.DistributeNests.DistNestT rep m)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Functor m => GHC.Base.Functor (Futhark.Pass.ExtractKernels.DistributeNests.DistNestT rep m)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Monad m => Control.Monad.Reader.Class.MonadReader (Futhark.Pass.ExtractKernels.DistributeNests.DistEnv rep m) (Futhark.Pass.ExtractKernels.DistributeNests.DistNestT rep m)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Monad m => Control.Monad.Writer.Class.MonadWriter (Futhark.Pass.ExtractKernels.DistributeNests.DistRes rep) (Futhark.Pass.ExtractKernels.DistributeNests.DistNestT rep m)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Monad m => Futhark.Util.Log.MonadLogger (Futhark.Pass.ExtractKernels.DistributeNests.DistNestT rep m)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Monad m => GHC.Base.Monad (Futhark.Pass.ExtractKernels.DistributeNests.DistNestT rep m)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Monoid (Futhark.Pass.ExtractKernels.DistributeNests.DistRes rep)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Monoid (Futhark.Pass.ExtractKernels.DistributeNests.PostStms rep)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Semigroup (Futhark.Pass.ExtractKernels.DistributeNests.DistRes rep)
- Futhark.Pass.ExtractKernels.DistributeNests: instance GHC.Base.Semigroup (Futhark.Pass.ExtractKernels.DistributeNests.PostStms rep)
- Futhark.Pass.ExtractKernels.DistributeNests: lambdaContainsParallelism :: Lambda SOACS -> Bool
- Futhark.Pass.ExtractKernels.DistributeNests: liftInner :: (LocalScope rep m, DistRep rep) => m a -> DistNestT rep m a
- Futhark.Pass.ExtractKernels.DistributeNests: mapLoopStm :: MapLoop -> Stm SOACS
- Futhark.Pass.ExtractKernels.DistributeNests: permutationAndMissing :: Pat Type -> Result -> Maybe ([Int], [PatElem Type])
- Futhark.Pass.ExtractKernels.DistributeNests: postStm :: forall (m :: Type -> Type) rep. Monad m => Stms rep -> DistNestT rep m ()
- Futhark.Pass.ExtractKernels.DistributeNests: runDistNestT :: (MonadLogger m, DistRep rep) => DistEnv rep m -> DistNestT rep m (DistAcc rep) -> m (Stms rep)
- Futhark.Pass.ExtractKernels.Distribution: MapNesting :: Pat Type -> StmAux () -> SubExp -> [(Param Type, VName)] -> LoopNesting
- Futhark.Pass.ExtractKernels.Distribution: Nesting :: Names -> LoopNesting -> Nesting
- Futhark.Pass.ExtractKernels.Distribution: [loopNestingAux] :: LoopNesting -> StmAux ()
- Futhark.Pass.ExtractKernels.Distribution: [loopNestingParamsAndArrs] :: LoopNesting -> [(Param Type, VName)]
- Futhark.Pass.ExtractKernels.Distribution: [loopNestingPat] :: LoopNesting -> Pat Type
- Futhark.Pass.ExtractKernels.Distribution: [loopNestingWidth] :: LoopNesting -> SubExp
- Futhark.Pass.ExtractKernels.Distribution: [nestingLetBound] :: Nesting -> Names
- Futhark.Pass.ExtractKernels.Distribution: [nestingLoop] :: Nesting -> LoopNesting
- Futhark.Pass.ExtractKernels.Distribution: boundInKernelNest :: KernelNest -> Names
- Futhark.Pass.ExtractKernels.Distribution: boundInKernelNests :: KernelNest -> [Names]
- Futhark.Pass.ExtractKernels.Distribution: constructKernel :: (DistRep rep, MonadFreshNames m, LocalScope rep m) => MkSegLevel rep m -> KernelNest -> Body rep -> m (Stm rep, Stms rep)
- Futhark.Pass.ExtractKernels.Distribution: data LoopNesting
- Futhark.Pass.ExtractKernels.Distribution: data Nesting
- Futhark.Pass.ExtractKernels.Distribution: data Targets
- Futhark.Pass.ExtractKernels.Distribution: flatKernel :: MonadFreshNames m => KernelNest -> m ([(VName, SubExp)], [KernelInput])
- Futhark.Pass.ExtractKernels.Distribution: innerTarget :: Targets -> Target
- Futhark.Pass.ExtractKernels.Distribution: innermostKernelNesting :: KernelNest -> LoopNesting
- Futhark.Pass.ExtractKernels.Distribution: instance Futhark.IR.Prop.Names.FreeIn Futhark.Pass.ExtractKernels.Distribution.LoopNesting
- Futhark.Pass.ExtractKernels.Distribution: instance GHC.Show.Show Futhark.Pass.ExtractKernels.Distribution.LoopNesting
- Futhark.Pass.ExtractKernels.Distribution: instance GHC.Show.Show Futhark.Pass.ExtractKernels.Distribution.Nesting
- Futhark.Pass.ExtractKernels.Distribution: kernelNestLoops :: KernelNest -> [LoopNesting]
- Futhark.Pass.ExtractKernels.Distribution: kernelNestWidths :: KernelNest -> [SubExp]
- Futhark.Pass.ExtractKernels.Distribution: letBindInInnerNesting :: Names -> Nestings -> Nestings
- Futhark.Pass.ExtractKernels.Distribution: newKernel :: LoopNesting -> KernelNest
- Futhark.Pass.ExtractKernels.Distribution: outerTarget :: Targets -> Target
- Futhark.Pass.ExtractKernels.Distribution: popInnerTarget :: Targets -> Maybe (Target, Targets)
- Futhark.Pass.ExtractKernels.Distribution: ppKernelNest :: KernelNest -> String
- Futhark.Pass.ExtractKernels.Distribution: ppLoopNesting :: LoopNesting -> String
- Futhark.Pass.ExtractKernels.Distribution: ppNestings :: Nestings -> String
- Futhark.Pass.ExtractKernels.Distribution: ppTargets :: Targets -> String
- Futhark.Pass.ExtractKernels.Distribution: pushInnerKernelNesting :: Target -> LoopNesting -> KernelNest -> KernelNest
- Futhark.Pass.ExtractKernels.Distribution: pushInnerNesting :: Nesting -> Nestings -> Nestings
- Futhark.Pass.ExtractKernels.Distribution: pushInnerTarget :: Target -> Targets -> Targets
- Futhark.Pass.ExtractKernels.Distribution: pushKernelNesting :: Target -> LoopNesting -> KernelNest -> KernelNest
- Futhark.Pass.ExtractKernels.Distribution: scopeOfKernelNest :: LParamInfo rep ~ Type => KernelNest -> Scope rep
- Futhark.Pass.ExtractKernels.Distribution: scopeOfLoopNesting :: LParamInfo rep ~ Type => LoopNesting -> Scope rep
- Futhark.Pass.ExtractKernels.Distribution: singleNesting :: Nesting -> Nestings
- Futhark.Pass.ExtractKernels.Distribution: singleTarget :: Target -> Targets
- Futhark.Pass.ExtractKernels.Distribution: targetsScope :: DistRep rep => Targets -> Scope rep
- Futhark.Pass.ExtractKernels.Distribution: tryDistribute :: (DistRep rep, MonadFreshNames m, LocalScope rep m, MonadLogger m) => MkSegLevel rep m -> Nestings -> Targets -> Stms rep -> m (Maybe (Targets, Stms rep))
- Futhark.Pass.ExtractKernels.Distribution: tryDistributeStm :: (MonadFreshNames m, HasScope t m, ASTRep rep) => Nestings -> Targets -> Stm rep -> m (Maybe (Result, Targets, KernelNest))
- Futhark.Pass.ExtractKernels.Distribution: type KernelNest = (LoopNesting, [LoopNesting])
- Futhark.Pass.ExtractKernels.Distribution: type Nestings = (Nesting, [Nesting])
- Futhark.Pass.ExtractKernels.Distribution: type Target = (Pat Type, Result)
- Futhark.Pass.ExtractKernels.ISRWIM: irwim :: (MonadBuilder m, Rep m ~ SOACS) => Pat Type -> SubExp -> Commutativity -> Lambda SOACS -> [(SubExp, VName)] -> Maybe (m ())
- Futhark.Pass.ExtractKernels.ISRWIM: iswim :: (MonadBuilder m, Rep m ~ SOACS) => Pat Type -> SubExp -> Lambda SOACS -> [(SubExp, VName)] -> Maybe (m ())
- Futhark.Pass.ExtractKernels.ISRWIM: rwimPossible :: Lambda SOACS -> Maybe (Pat Type, StmAux (), SubExp, Lambda SOACS)
- Futhark.Pass.ExtractKernels.Interchange: Branch :: [Int] -> Pat Type -> [SubExp] -> [Case (Body SOACS)] -> Body SOACS -> MatchDec (BranchType SOACS) -> Branch
- Futhark.Pass.ExtractKernels.Interchange: SeqLoop :: [Int] -> Pat Type -> [(FParam SOACS, SubExp)] -> LoopForm -> Body SOACS -> SeqLoop
- Futhark.Pass.ExtractKernels.Interchange: WithAccStm :: [Int] -> Pat Type -> [(Shape, [VName], Maybe (Lambda SOACS, [SubExp]))] -> Lambda SOACS -> WithAccStm
- Futhark.Pass.ExtractKernels.Interchange: data Branch
- Futhark.Pass.ExtractKernels.Interchange: data SeqLoop
- Futhark.Pass.ExtractKernels.Interchange: data WithAccStm
- Futhark.Pass.ExtractKernels.Interchange: interchangeBranch :: (MonadFreshNames m, HasScope SOACS m) => KernelNest -> Branch -> m (Stm SOACS)
- Futhark.Pass.ExtractKernels.Interchange: interchangeLoops :: (MonadFreshNames m, HasScope SOACS m) => KernelNest -> SeqLoop -> m (Stms SOACS)
- Futhark.Pass.ExtractKernels.Interchange: interchangeWithAcc :: (MonadFreshNames m, LocalScope SOACS m) => KernelNest -> WithAccStm -> m (Stm SOACS)
- Futhark.Pass.ExtractKernels.Intrablock: instance Futhark.Util.Log.MonadLogger Futhark.Pass.ExtractKernels.Intrablock.IntrablockM
- Futhark.Pass.ExtractKernels.Intrablock: instance GHC.Base.Monoid Futhark.Pass.ExtractKernels.Intrablock.IntraAcc
- Futhark.Pass.ExtractKernels.Intrablock: instance GHC.Base.Semigroup Futhark.Pass.ExtractKernels.Intrablock.IntraAcc
- Futhark.Pass.ExtractKernels.Intrablock: intrablockParallelise :: (MonadFreshNames m, LocalScope GPU m) => KernelNest -> Lambda SOACS -> m (Maybe ((SubExp, SubExp), SubExp, Log, Stms GPU, Stms GPU))
- Futhark.Pass.ExtractKernels.StreamKernel: instance GHC.Classes.Eq Futhark.Pass.ExtractKernels.StreamKernel.KernelSize
- Futhark.Pass.ExtractKernels.StreamKernel: instance GHC.Classes.Ord Futhark.Pass.ExtractKernels.StreamKernel.KernelSize
- Futhark.Pass.ExtractKernels.StreamKernel: instance GHC.Show.Show Futhark.Pass.ExtractKernels.StreamKernel.KernelSize
- Futhark.Pass.ExtractKernels.StreamKernel: segThreadCapped :: forall (m :: Type -> Type). MonadFreshNames m => MkSegLevel GPU m
- Futhark.Pass.ExtractKernels.ToGPU: getSize :: forall m (inner :: Type -> Type). (MonadBuilder m, Op (Rep m) ~ HostOp inner (Rep m)) => String -> SizeClass -> m SubExp
- Futhark.Pass.ExtractKernels.ToGPU: injectSOACS :: forall (m :: Type -> Type) from to. (Monad m, SameScope from to, ExpDec from ~ ExpDec to, BodyDec from ~ BodyDec to, RetType from ~ RetType to, BranchType from ~ BranchType to, Op from ~ SOAC from) => (SOAC to -> Op to) -> Rephraser m from to
- Futhark.Pass.ExtractKernels.ToGPU: scopeForGPU :: Scope SOACS -> Scope GPU
- Futhark.Pass.ExtractKernels.ToGPU: scopeForSOACs :: Scope GPU -> Scope SOACS
- Futhark.Pass.ExtractKernels.ToGPU: segThread :: forall m (inner :: Type -> Type). (MonadBuilder m, Op (Rep m) ~ HostOp inner (Rep m)) => String -> m SegLevel
- Futhark.Pass.ExtractKernels.ToGPU: soacsLambdaToGPU :: Lambda SOACS -> Lambda GPU
- Futhark.Pass.ExtractKernels.ToGPU: soacsStmToGPU :: Stm SOACS -> Stm GPU
- Futhark.Pass.ExtractMulticore: extractMulticore :: Pass SOACS MC
- Futhark.Pass.ExtractMulticore: instance Futhark.IR.Prop.Scope.HasScope Futhark.IR.MC.MC Futhark.Pass.ExtractMulticore.ExtractM
- Futhark.Pass.ExtractMulticore: instance Futhark.IR.Prop.Scope.LocalScope Futhark.IR.MC.MC Futhark.Pass.ExtractMulticore.ExtractM
- Futhark.Pass.ExtractMulticore: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Pass.ExtractMulticore.ExtractM
- Futhark.Pass.ExtractMulticore: instance Futhark.Util.Log.MonadLogger Futhark.Pass.ExtractMulticore.ExtractM
- Futhark.Pass.ExtractMulticore: instance GHC.Base.Applicative Futhark.Pass.ExtractMulticore.ExtractM
- Futhark.Pass.ExtractMulticore: instance GHC.Base.Functor Futhark.Pass.ExtractMulticore.ExtractM
- Futhark.Pass.ExtractMulticore: instance GHC.Base.Monad Futhark.Pass.ExtractMulticore.ExtractM
- Futhark.Pass.FirstOrderTransform: firstOrderTransform :: FirstOrderRep rep => Pass SOACS rep
- Futhark.Pass.LiftAllocations: liftAllocationsGPUMem :: Pass GPUMem GPUMem
- Futhark.Pass.LiftAllocations: liftAllocationsMCMem :: Pass MCMem MCMem
- Futhark.Pass.LiftAllocations: liftAllocationsSeqMem :: Pass SeqMem SeqMem
- Futhark.Pass.LowerAllocations: lowerAllocationsGPUMem :: Pass GPUMem GPUMem
- Futhark.Pass.LowerAllocations: lowerAllocationsMCMem :: Pass MCMem MCMem
- Futhark.Pass.LowerAllocations: lowerAllocationsSeqMem :: Pass SeqMem SeqMem
- Futhark.Pass.Simplify: simplify :: (Prog rep -> PassM (Prog rep)) -> Pass rep rep
- Futhark.Pass.Simplify: simplifyGPU :: Pass GPU GPU
- Futhark.Pass.Simplify: simplifyGPUMem :: Pass GPUMem GPUMem
- Futhark.Pass.Simplify: simplifyMC :: Pass MC MC
- Futhark.Pass.Simplify: simplifyMCMem :: Pass MCMem MCMem
- Futhark.Pass.Simplify: simplifySOACS :: Pass SOACS SOACS
- Futhark.Pass.Simplify: simplifySeq :: Pass Seq Seq
- Futhark.Pass.Simplify: simplifySeqMem :: Pass SeqMem SeqMem
- Futhark.Passes: gpuPipeline :: Pipeline SOACS GPU
- Futhark.Passes: gpumemPipeline :: Pipeline SOACS GPUMem
- Futhark.Passes: mcPipeline :: Pipeline SOACS MC
- Futhark.Passes: mcmemPipeline :: Pipeline SOACS MCMem
- Futhark.Passes: seqPipeline :: Pipeline SOACS Seq
- Futhark.Passes: seqmemPipeline :: Pipeline SOACS SeqMem
- Futhark.Passes: standardPipeline :: Pipeline SOACS SOACS
- Futhark.Pipeline: Action :: String -> String -> (Prog rep -> FutharkM ()) -> Action rep
- Futhark.Pipeline: NotVerbose :: Verbosity
- Futhark.Pipeline: PipelineConfig :: Bool -> Bool -> PipelineConfig
- Futhark.Pipeline: Verbose :: Verbosity
- Futhark.Pipeline: VeryVerbose :: Verbosity
- Futhark.Pipeline: [actionDescription] :: Action rep -> String
- Futhark.Pipeline: [actionName] :: Action rep -> String
- Futhark.Pipeline: [actionProcedure] :: Action rep -> Prog rep -> FutharkM ()
- Futhark.Pipeline: [pipelineValidate] :: PipelineConfig -> Bool
- Futhark.Pipeline: [pipelineVerbose] :: PipelineConfig -> Bool
- Futhark.Pipeline: condPipeline :: (Prog rep -> Bool) -> Pipeline rep rep -> Pipeline rep rep
- Futhark.Pipeline: data Action rep
- Futhark.Pipeline: data FutharkM a
- Futhark.Pipeline: data Pipeline fromrep torep
- Futhark.Pipeline: data PipelineConfig
- Futhark.Pipeline: data Verbosity
- Futhark.Pipeline: instance Control.Category.Category Futhark.Pipeline.Pipeline
- Futhark.Pipeline: instance Control.Monad.Error.Class.MonadError Futhark.Error.CompilerError Futhark.Pipeline.FutharkM
- Futhark.Pipeline: instance Control.Monad.IO.Class.MonadIO Futhark.Pipeline.FutharkM
- Futhark.Pipeline: instance Control.Monad.Reader.Class.MonadReader Futhark.Pipeline.FutharkEnv Futhark.Pipeline.FutharkM
- Futhark.Pipeline: instance Control.Monad.State.Class.MonadState Futhark.Pipeline.FutharkState Futhark.Pipeline.FutharkM
- Futhark.Pipeline: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Pipeline.FutharkM
- Futhark.Pipeline: instance Futhark.Util.Log.MonadLogger Futhark.Pipeline.FutharkM
- Futhark.Pipeline: instance GHC.Base.Applicative Futhark.Pipeline.FutharkM
- Futhark.Pipeline: instance GHC.Base.Functor Futhark.Pipeline.FutharkM
- Futhark.Pipeline: instance GHC.Base.Monad Futhark.Pipeline.FutharkM
- Futhark.Pipeline: onePass :: Checkable torep => Pass fromrep torep -> Pipeline fromrep torep
- Futhark.Pipeline: passes :: Checkable rep => [Pass rep rep] -> Pipeline rep rep
- Futhark.Pipeline: runFutharkM :: FutharkM a -> Verbosity -> IO (Either CompilerError a)
- Futhark.Pipeline: runPipeline :: Pipeline fromrep torep -> PipelineConfig -> Prog fromrep -> FutharkM (Prog torep)
- Futhark.Pkg.Info: CacheDir :: FilePath -> CacheDir
- Futhark.Pkg.Info: PkgInfo :: Map SemVer (PkgRevInfo m) -> (Maybe Text -> m (PkgRevInfo m)) -> PkgInfo (m :: Type -> Type)
- Futhark.Pkg.Info: PkgRevInfo :: GetFiles m -> Text -> GetManifest m -> UTCTime -> PkgRevInfo (m :: Type -> Type)
- Futhark.Pkg.Info: [pkgGetFiles] :: PkgRevInfo (m :: Type -> Type) -> GetFiles m
- Futhark.Pkg.Info: [pkgLookupCommit] :: PkgInfo (m :: Type -> Type) -> Maybe Text -> m (PkgRevInfo m)
- Futhark.Pkg.Info: [pkgRevCommit] :: PkgRevInfo (m :: Type -> Type) -> Text
- Futhark.Pkg.Info: [pkgRevGetManifest] :: PkgRevInfo (m :: Type -> Type) -> GetManifest m
- Futhark.Pkg.Info: [pkgRevTime] :: PkgRevInfo (m :: Type -> Type) -> UTCTime
- Futhark.Pkg.Info: [pkgVersions] :: PkgInfo (m :: Type -> Type) -> Map SemVer (PkgRevInfo m)
- Futhark.Pkg.Info: class (MonadIO m, MonadLogger m, MonadFail m) => MonadPkgRegistry (m :: Type -> Type)
- Futhark.Pkg.Info: data GetFiles (m :: Type -> Type)
- Futhark.Pkg.Info: data GetManifest (m :: Type -> Type)
- Futhark.Pkg.Info: data PkgInfo (m :: Type -> Type)
- Futhark.Pkg.Info: data PkgRegistry (m :: Type -> Type)
- Futhark.Pkg.Info: data PkgRevInfo (m :: Type -> Type)
- Futhark.Pkg.Info: getPkgRegistry :: MonadPkgRegistry m => m (PkgRegistry m)
- Futhark.Pkg.Info: instance GHC.Base.Monoid (Futhark.Pkg.Info.PkgRegistry m)
- Futhark.Pkg.Info: instance GHC.Base.Semigroup (Futhark.Pkg.Info.PkgRegistry m)
- Futhark.Pkg.Info: instance GHC.Classes.Eq (Futhark.Pkg.Info.GetFiles m)
- Futhark.Pkg.Info: instance GHC.Classes.Eq (Futhark.Pkg.Info.GetManifest m)
- Futhark.Pkg.Info: instance GHC.Classes.Eq (Futhark.Pkg.Info.PkgRevInfo m)
- Futhark.Pkg.Info: instance GHC.Show.Show (Futhark.Pkg.Info.GetFiles m)
- Futhark.Pkg.Info: instance GHC.Show.Show (Futhark.Pkg.Info.GetManifest m)
- Futhark.Pkg.Info: instance GHC.Show.Show (Futhark.Pkg.Info.PkgRevInfo m)
- Futhark.Pkg.Info: lookupNewestRev :: MonadPkgRegistry m => CacheDir -> PkgPath -> m SemVer
- Futhark.Pkg.Info: lookupPackage :: MonadPkgRegistry m => CacheDir -> PkgPath -> m (PkgInfo m)
- Futhark.Pkg.Info: lookupPackageRev :: MonadPkgRegistry m => CacheDir -> PkgPath -> SemVer -> m (PkgRevInfo m)
- Futhark.Pkg.Info: lookupPkgRev :: forall (m :: Type -> Type). SemVer -> PkgInfo m -> Maybe (PkgRevInfo m)
- Futhark.Pkg.Info: modifyPkgRegistry :: MonadPkgRegistry m => (PkgRegistry m -> PkgRegistry m) -> m ()
- Futhark.Pkg.Info: newtype CacheDir
- Futhark.Pkg.Info: pkgInfo :: (MonadIO m, MonadLogger m, MonadFail m) => CacheDir -> PkgPath -> m (PkgInfo m)
- Futhark.Pkg.Info: putPkgRegistry :: MonadPkgRegistry m => PkgRegistry m -> m ()
- Futhark.Pkg.Solve: instance GHC.Base.Functor Futhark.Pkg.Solve.PkgOp
- Futhark.Pkg.Solve: instance GHC.Show.Show Futhark.Pkg.Solve.RoughBuildList
- Futhark.Pkg.Solve: solveDeps :: MonadPkgRegistry m => CacheDir -> PkgRevDeps -> m BuildList
- Futhark.Pkg.Solve: solveDepsPure :: PkgRevDepInfo -> PkgRevDeps -> Either Text BuildList
- Futhark.Pkg.Solve: type PkgRevDepInfo = Map (PkgPath, SemVer) PkgRevDeps
- Futhark.Pkg.Types: Alphanum :: !Text -> Chunk
- Futhark.Pkg.Types: BuildList :: Map PkgPath SemVer -> BuildList
- Futhark.Pkg.Types: Commented :: [Comment] -> a -> Commented a
- Futhark.Pkg.Types: PkgManifest :: Commented (Maybe PkgPath) -> Commented [Either Comment Required] -> [Comment] -> PkgManifest
- Futhark.Pkg.Types: PkgRevDeps :: Map PkgPath (SemVer, Maybe Text) -> PkgRevDeps
- Futhark.Pkg.Types: Release :: NonEmpty Chunk -> Release
- Futhark.Pkg.Types: Required :: PkgPath -> SemVer -> Maybe Text -> Required
- Futhark.Pkg.Types: SemVer :: !Word -> !Word -> !Word -> !Maybe Release -> !Maybe Text -> SemVer
- Futhark.Pkg.Types: [_svMajor] :: SemVer -> !Word
- Futhark.Pkg.Types: [_svMeta] :: SemVer -> !Maybe Text
- Futhark.Pkg.Types: [_svMinor] :: SemVer -> !Word
- Futhark.Pkg.Types: [_svPatch] :: SemVer -> !Word
- Futhark.Pkg.Types: [_svPreRel] :: SemVer -> !Maybe Release
- Futhark.Pkg.Types: [commented] :: Commented a -> a
- Futhark.Pkg.Types: [comments] :: Commented a -> [Comment]
- Futhark.Pkg.Types: [manifestEndComments] :: PkgManifest -> [Comment]
- Futhark.Pkg.Types: [manifestPkgPath] :: PkgManifest -> Commented (Maybe PkgPath)
- Futhark.Pkg.Types: [manifestRequire] :: PkgManifest -> Commented [Either Comment Required]
- Futhark.Pkg.Types: [requiredHash] :: Required -> Maybe Text
- Futhark.Pkg.Types: [requiredPkgRev] :: Required -> SemVer
- Futhark.Pkg.Types: [requiredPkg] :: Required -> PkgPath
- Futhark.Pkg.Types: [unBuildList] :: BuildList -> Map PkgPath SemVer
- Futhark.Pkg.Types: addRequiredToManifest :: Required -> PkgManifest -> (PkgManifest, Maybe Required)
- Futhark.Pkg.Types: commitVersion :: Text -> Text -> SemVer
- Futhark.Pkg.Types: data Chunk
- Futhark.Pkg.Types: data Commented a
- Futhark.Pkg.Types: data PkgManifest
- Futhark.Pkg.Types: data Required
- Futhark.Pkg.Types: data SemVer
- Futhark.Pkg.Types: errorBundlePretty :: (VisualStream s, TraversableStream s, ShowErrorComponent e) => ParseErrorBundle s e -> String
- Futhark.Pkg.Types: futharkPkg :: FilePath
- Futhark.Pkg.Types: instance Data.Foldable.Foldable Futhark.Pkg.Types.Commented
- Futhark.Pkg.Types: instance Data.Traversable.Traversable Futhark.Pkg.Types.Commented
- Futhark.Pkg.Types: instance GHC.Base.Functor Futhark.Pkg.Types.Commented
- Futhark.Pkg.Types: instance GHC.Base.Monoid Futhark.Pkg.Types.PkgRevDeps
- Futhark.Pkg.Types: instance GHC.Base.Semigroup Futhark.Pkg.Types.PkgRevDeps
- Futhark.Pkg.Types: instance GHC.Classes.Eq Futhark.Pkg.Types.BuildList
- Futhark.Pkg.Types: instance GHC.Classes.Eq Futhark.Pkg.Types.PkgManifest
- Futhark.Pkg.Types: instance GHC.Classes.Eq Futhark.Pkg.Types.Required
- Futhark.Pkg.Types: instance GHC.Classes.Eq a => GHC.Classes.Eq (Futhark.Pkg.Types.Commented a)
- Futhark.Pkg.Types: instance GHC.Show.Show Futhark.Pkg.Types.BuildList
- Futhark.Pkg.Types: instance GHC.Show.Show Futhark.Pkg.Types.PkgManifest
- Futhark.Pkg.Types: instance GHC.Show.Show Futhark.Pkg.Types.PkgRevDeps
- Futhark.Pkg.Types: instance GHC.Show.Show Futhark.Pkg.Types.Required
- Futhark.Pkg.Types: instance GHC.Show.Show a => GHC.Show.Show (Futhark.Pkg.Types.Commented a)
- Futhark.Pkg.Types: isCommitVersion :: SemVer -> Maybe Text
- Futhark.Pkg.Types: newPkgManifest :: Maybe PkgPath -> PkgManifest
- Futhark.Pkg.Types: newtype BuildList
- Futhark.Pkg.Types: newtype PkgRevDeps
- Futhark.Pkg.Types: newtype Release
- Futhark.Pkg.Types: parsePkgManifest :: FilePath -> Text -> Either (ParseErrorBundle Text Void) PkgManifest
- Futhark.Pkg.Types: parsePkgManifestFromFile :: FilePath -> IO PkgManifest
- Futhark.Pkg.Types: parseVersion :: Text -> Either (ParseErrorBundle Text Void) SemVer
- Futhark.Pkg.Types: pkgDir :: PkgManifest -> Maybe FilePath
- Futhark.Pkg.Types: pkgPathFilePath :: PkgPath -> FilePath
- Futhark.Pkg.Types: pkgRevDeps :: PkgManifest -> PkgRevDeps
- Futhark.Pkg.Types: prettyBuildList :: BuildList -> Text
- Futhark.Pkg.Types: prettyPkgManifest :: PkgManifest -> Text
- Futhark.Pkg.Types: prettySemVer :: SemVer -> Text
- Futhark.Pkg.Types: removeRequiredFromManifest :: PkgPath -> PkgManifest -> Maybe (PkgManifest, Required)
- Futhark.Pkg.Types: type Comment = Text
- Futhark.Pkg.Types: type PkgPath = Text
- Futhark.Profile: ProfilingEvent :: Text -> Double -> Text -> ProfilingEvent
- Futhark.Profile: ProfilingReport :: [ProfilingEvent] -> Map Text Integer -> ProfilingReport
- Futhark.Profile: [eventDescription] :: ProfilingEvent -> Text
- Futhark.Profile: [eventDuration] :: ProfilingEvent -> Double
- Futhark.Profile: [eventName] :: ProfilingEvent -> Text
- Futhark.Profile: [profilingEvents] :: ProfilingReport -> [ProfilingEvent]
- Futhark.Profile: [profilingMemory] :: ProfilingReport -> Map Text Integer
- Futhark.Profile: data ProfilingEvent
- Futhark.Profile: data ProfilingReport
- Futhark.Profile: decodeProfilingReport :: ByteString -> Maybe ProfilingReport
- Futhark.Profile: instance Data.Aeson.Types.FromJSON.FromJSON Futhark.Profile.ProfilingEvent
- Futhark.Profile: instance Data.Aeson.Types.FromJSON.FromJSON Futhark.Profile.ProfilingReport
- Futhark.Profile: instance Data.Aeson.Types.ToJSON.ToJSON Futhark.Profile.ProfilingEvent
- Futhark.Profile: instance Data.Aeson.Types.ToJSON.ToJSON Futhark.Profile.ProfilingReport
- Futhark.Profile: instance GHC.Classes.Eq Futhark.Profile.ProfilingEvent
- Futhark.Profile: instance GHC.Classes.Eq Futhark.Profile.ProfilingReport
- Futhark.Profile: instance GHC.Classes.Ord Futhark.Profile.ProfilingEvent
- Futhark.Profile: instance GHC.Classes.Ord Futhark.Profile.ProfilingReport
- Futhark.Profile: instance GHC.Show.Show Futhark.Profile.ProfilingEvent
- Futhark.Profile: instance GHC.Show.Show Futhark.Profile.ProfilingReport
- Futhark.Profile: profilingReportFromText :: Text -> Maybe ProfilingReport
- Futhark.Script: Call :: Func -> [Exp] -> Exp
- Futhark.Script: Const :: Value -> Exp
- Futhark.Script: FuncBuiltin :: Text -> Func
- Futhark.Script: FuncFut :: EntryName -> Func
- Futhark.Script: Let :: [VarName] -> Exp -> Exp -> Exp
- Futhark.Script: Record :: [(Text, Exp)] -> Exp
- Futhark.Script: SFun :: EntryName -> [TypeName] -> [TypeName] -> [ScriptValue v] -> ScriptValue v
- Futhark.Script: STFun :: [TypeName] -> [TypeName] -> ScriptValueType
- Futhark.Script: STValue :: TypeName -> ScriptValueType
- Futhark.Script: SValue :: TypeName -> v -> ScriptValue v
- Futhark.Script: ServerVar :: TypeName -> VarName -> Exp
- Futhark.Script: StringLit :: Text -> Exp
- Futhark.Script: Tuple :: [Exp] -> Exp
- Futhark.Script: VVal :: Value -> ValOrVar
- Futhark.Script: VVar :: VarName -> ValOrVar
- Futhark.Script: data Exp
- Futhark.Script: data Func
- Futhark.Script: data ScriptServer
- Futhark.Script: data ScriptValue v
- Futhark.Script: data ScriptValueType
- Futhark.Script: data ValOrVar
- Futhark.Script: evalExp :: (MonadError Text m, MonadIO m) => EvalBuiltin m -> ScriptServer -> Exp -> m ExpValue
- Futhark.Script: evalExpToGround :: (MonadError Text m, MonadIO m) => EvalBuiltin m -> ScriptServer -> Exp -> m (Either (Compound ScriptValueType) CompoundValue)
- Futhark.Script: freeValue :: (MonadError Text m, MonadIO m) => ScriptServer -> ExpValue -> m ()
- Futhark.Script: getExpValue :: (MonadError Text m, MonadIO m) => ScriptServer -> ExpValue -> m CompoundValue
- Futhark.Script: instance Data.Foldable.Foldable Futhark.Script.ScriptValue
- Futhark.Script: instance Data.Traversable.Traversable Futhark.Script.ScriptValue
- Futhark.Script: instance GHC.Base.Functor Futhark.Script.ScriptValue
- Futhark.Script: instance GHC.Classes.Eq Futhark.Script.ScriptValueType
- Futhark.Script: instance GHC.Show.Show Futhark.Script.Exp
- Futhark.Script: instance GHC.Show.Show Futhark.Script.Func
- Futhark.Script: instance GHC.Show.Show Futhark.Script.ScriptValueType
- Futhark.Script: instance GHC.Show.Show Futhark.Script.ValOrVar
- Futhark.Script: instance GHC.Show.Show v => GHC.Show.Show (Futhark.Script.ScriptValue v)
- Futhark.Script: instance Prettyprinter.Internal.Pretty Futhark.Script.Exp
- Futhark.Script: instance Prettyprinter.Internal.Pretty Futhark.Script.Func
- Futhark.Script: instance Prettyprinter.Internal.Pretty Futhark.Script.ScriptValueType
- Futhark.Script: parseExp :: Parsec Void Text () -> Parsec Void Text Exp
- Futhark.Script: parseExpFromText :: FilePath -> Text -> Either Text Exp
- Futhark.Script: scriptBuiltin :: (MonadIO m, MonadError Text m) => FilePath -> EvalBuiltin m
- Futhark.Script: scriptValueType :: ScriptValue v -> ScriptValueType
- Futhark.Script: serverVarsInValue :: ExpValue -> Set VarName
- Futhark.Script: type EvalBuiltin (m :: Type -> Type) = Text -> [CompoundValue] -> m CompoundValue
- Futhark.Script: type ExpValue = Compound ScriptValue ValOrVar
- Futhark.Script: valueToExp :: ExpValue -> Exp
- Futhark.Script: varsInExp :: Exp -> Set EntryName
- Futhark.Script: withScriptServer :: ServerCfg -> (ScriptServer -> IO a) -> IO a
- Futhark.Script: withScriptServer' :: MonadIO m => Server -> (ScriptServer -> m a) -> m a
- Futhark.Test: FutharkExe :: FilePath -> FutharkExe
- Futhark.Test: binaryName :: FilePath -> FilePath
- Futhark.Test: checkResult :: (MonadError Text m, MonadIO m) => FilePath -> [Value] -> [Value] -> m ()
- Futhark.Test: compareValues :: Tolerance -> Value -> Value -> [Mismatch]
- Futhark.Test: compileProgram :: (MonadIO m, MonadError Text m) => [String] -> FutharkExe -> String -> FilePath -> m (ByteString, ByteString)
- Futhark.Test: data Mismatch
- Futhark.Test: data Value
- Futhark.Test: determineCache :: Maybe FilePath -> FilePath -> [String]
- Futhark.Test: determineTuning :: MonadIO m => Maybe FilePath -> FilePath -> m ([String], String)
- Futhark.Test: ensureReferenceOutput :: (MonadIO m, MonadError Text m) => Maybe Int -> FutharkExe -> String -> FilePath -> [InputOutputs] -> m ()
- Futhark.Test: futharkServerCfg :: FilePath -> [String] -> ServerCfg
- Futhark.Test: getExpectedResult :: (MonadFail m, MonadIO m) => FutharkExe -> FilePath -> Text -> TestRun -> m (ExpectedResult [Value])
- Futhark.Test: getValues :: (MonadFail m, MonadIO m) => FutharkExe -> FilePath -> Values -> m [Value]
- Futhark.Test: getValuesBS :: (MonadFail m, MonadIO m) => FutharkExe -> FilePath -> Values -> m ByteString
- Futhark.Test: instance GHC.Classes.Eq Futhark.Test.FutharkExe
- Futhark.Test: instance GHC.Classes.Ord Futhark.Test.FutharkExe
- Futhark.Test: instance GHC.Show.Show Futhark.Test.FutharkExe
- Futhark.Test: newtype FutharkExe
- Futhark.Test: readResults :: (MonadIO m, MonadError Text m) => Server -> [VarName] -> m [Value]
- Futhark.Test: testRunReferenceOutput :: FilePath -> Text -> TestRun -> FilePath
- Futhark.Test: valueText :: Value -> Text
- Futhark.Test: valuesAsVars :: (MonadError Text m, MonadIO m) => Server -> [(VarName, TypeName)] -> FutharkExe -> FilePath -> Values -> m ()
- Futhark.Test: valuesFromByteString :: String -> ByteString -> Either String [Value]
- Futhark.Test.Spec: AnyError :: ExpectedError
- Futhark.Test.Spec: CompileTimeFailure :: ExpectedError -> TestAction
- Futhark.Test.Spec: ExpectedWarning :: Text -> Regex -> WarningTest
- Futhark.Test.Spec: GenPrim :: Value -> GenValue
- Futhark.Test.Spec: GenValue :: ValueType -> GenValue
- Futhark.Test.Spec: GenValues :: [GenValue] -> Values
- Futhark.Test.Spec: GpuMemPipeline :: StructurePipeline
- Futhark.Test.Spec: GpuPipeline :: StructurePipeline
- Futhark.Test.Spec: InFile :: FilePath -> Values
- Futhark.Test.Spec: InputOutputs :: Text -> [TestRun] -> InputOutputs
- Futhark.Test.Spec: MCMemPipeline :: StructurePipeline
- Futhark.Test.Spec: MCPipeline :: StructurePipeline
- Futhark.Test.Spec: NoPipeline :: StructurePipeline
- Futhark.Test.Spec: ProgramTest :: Text -> [Text] -> TestAction -> ProgramTest
- Futhark.Test.Spec: RunCases :: [InputOutputs] -> [StructureTest] -> [WarningTest] -> TestAction
- Futhark.Test.Spec: RunTimeFailure :: ExpectedError -> ExpectedResult values
- Futhark.Test.Spec: SOACSPipeline :: StructurePipeline
- Futhark.Test.Spec: ScriptFile :: FilePath -> Values
- Futhark.Test.Spec: ScriptValues :: Exp -> Values
- Futhark.Test.Spec: SeqMemPipeline :: StructurePipeline
- Futhark.Test.Spec: StructureTest :: StructurePipeline -> AstMetrics -> StructureTest
- Futhark.Test.Spec: Succeeds :: Maybe values -> ExpectedResult values
- Futhark.Test.Spec: SuccessGenerateValues :: Success
- Futhark.Test.Spec: SuccessValues :: Values -> Success
- Futhark.Test.Spec: TestRun :: [Text] -> Values -> ExpectedResult Success -> Int -> Text -> TestRun
- Futhark.Test.Spec: ThisError :: Text -> Regex -> ExpectedError
- Futhark.Test.Spec: Values :: [Value] -> Values
- Futhark.Test.Spec: [iosEntryPoint] :: InputOutputs -> Text
- Futhark.Test.Spec: [iosTestRuns] :: InputOutputs -> [TestRun]
- Futhark.Test.Spec: [runDescription] :: TestRun -> Text
- Futhark.Test.Spec: [runExpectedResult] :: TestRun -> ExpectedResult Success
- Futhark.Test.Spec: [runIndex] :: TestRun -> Int
- Futhark.Test.Spec: [runInput] :: TestRun -> Values
- Futhark.Test.Spec: [runTags] :: TestRun -> [Text]
- Futhark.Test.Spec: [testAction] :: ProgramTest -> TestAction
- Futhark.Test.Spec: [testDescription] :: ProgramTest -> Text
- Futhark.Test.Spec: [testTags] :: ProgramTest -> [Text]
- Futhark.Test.Spec: data ExpectedError
- Futhark.Test.Spec: data ExpectedResult values
- Futhark.Test.Spec: data GenValue
- Futhark.Test.Spec: data InputOutputs
- Futhark.Test.Spec: data ProgramTest
- Futhark.Test.Spec: data StructurePipeline
- Futhark.Test.Spec: data StructureTest
- Futhark.Test.Spec: data Success
- Futhark.Test.Spec: data TestAction
- Futhark.Test.Spec: data TestRun
- Futhark.Test.Spec: data Values
- Futhark.Test.Spec: data WarningTest
- Futhark.Test.Spec: genValueType :: GenValue -> Text
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.ExpectedError
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.GenValue
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.InputOutputs
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.ProgramTest
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.StructurePipeline
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.StructureTest
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.Success
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.TestAction
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.TestRun
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.Values
- Futhark.Test.Spec: instance GHC.Show.Show Futhark.Test.Spec.WarningTest
- Futhark.Test.Spec: instance GHC.Show.Show values => GHC.Show.Show (Futhark.Test.Spec.ExpectedResult values)
- Futhark.Test.Spec: testSpecFromFile :: FilePath -> IO (Either String ProgramTest)
- Futhark.Test.Spec: testSpecFromFileOrDie :: FilePath -> IO ProgramTest
- Futhark.Test.Spec: testSpecFromProgram :: FilePath -> IO (Either String ProgramTest)
- Futhark.Test.Spec: testSpecFromProgramOrDie :: FilePath -> IO ProgramTest
- Futhark.Test.Spec: testSpecsFromPaths :: [FilePath] -> IO (Either String [(FilePath, ProgramTest)])
- Futhark.Test.Spec: testSpecsFromPathsOrDie :: [FilePath] -> IO [(FilePath, ProgramTest)]
- Futhark.Test.Values: ValueAtom :: v -> Compound v
- Futhark.Test.Values: ValueRecord :: Map Text (Compound v) -> Compound v
- Futhark.Test.Values: ValueTuple :: [Compound v] -> Compound v
- Futhark.Test.Values: data Compound v
- Futhark.Test.Values: instance Data.Foldable.Foldable Futhark.Test.Values.Compound
- Futhark.Test.Values: instance Data.Traversable.Traversable Futhark.Test.Values.Compound
- Futhark.Test.Values: instance GHC.Base.Functor Futhark.Test.Values.Compound
- Futhark.Test.Values: instance GHC.Classes.Eq v => GHC.Classes.Eq (Futhark.Test.Values.Compound v)
- Futhark.Test.Values: instance GHC.Classes.Ord v => GHC.Classes.Ord (Futhark.Test.Values.Compound v)
- Futhark.Test.Values: instance GHC.Show.Show v => GHC.Show.Show (Futhark.Test.Values.Compound v)
- Futhark.Test.Values: instance Prettyprinter.Internal.Pretty Futhark.Data.Value
- Futhark.Test.Values: instance Prettyprinter.Internal.Pretty Futhark.Data.ValueType
- Futhark.Test.Values: instance Prettyprinter.Internal.Pretty v => Prettyprinter.Internal.Pretty (Futhark.Test.Values.Compound v)
- Futhark.Test.Values: mkCompound :: [Compound v] -> Compound v
- Futhark.Test.Values: type CompoundValue = Compound Value
- Futhark.Test.Values: unCompound :: Compound v -> [Compound v]
- Futhark.Tools: dissectScrema :: (MonadBuilder m, Op (Rep m) ~ SOAC (Rep m), Buildable (Rep m)) => Pat (LetDec (Rep m)) -> SubExp -> ScremaForm (Rep m) -> [VName] -> m ()
- Futhark.Tools: partitionChunkedFoldParameters :: Int -> [Param dec] -> (Param dec, [Param dec], [Param dec])
- Futhark.Tools: redomapToMapAndReduce :: (MonadFreshNames m, Buildable rep, ExpDec rep ~ (), Op rep ~ SOAC rep) => Pat (LetDec rep) -> (SubExp, [Reduce rep], Lambda rep, [VName]) -> m (Stm rep, Stm rep)
- Futhark.Tools: scanomapToMapAndScan :: (MonadFreshNames m, Buildable rep, ExpDec rep ~ (), Op rep ~ SOAC rep) => Pat (LetDec rep) -> (SubExp, [Scan rep], Lambda rep, [VName]) -> m (Stm rep, Stm rep)
- Futhark.Tools: sequentialStreamWholeArray :: (MonadBuilder m, Buildable (Rep m)) => Pat (LetDec (Rep m)) -> SubExp -> [SubExp] -> Lambda (Rep m) -> [VName] -> m ()
- Futhark.Transform.CopyPropagate: copyPropagateInFun :: (MonadFreshNames m, SimplifiableRep rep) => SimpleOps rep -> SymbolTable (Wise rep) -> FunDef rep -> m (FunDef rep)
- Futhark.Transform.CopyPropagate: copyPropagateInProg :: SimplifiableRep rep => SimpleOps rep -> Prog rep -> PassM (Prog rep)
- Futhark.Transform.CopyPropagate: copyPropagateInStms :: (MonadFreshNames m, SimplifiableRep rep) => SimpleOps rep -> Scope rep -> Stms rep -> m (Stms rep)
- Futhark.Transform.FirstOrderTransform: transformConsts :: (MonadFreshNames m, FirstOrderRep torep) => Stms SOACS -> m (Stms torep)
- Futhark.Transform.FirstOrderTransform: transformFunDef :: (MonadFreshNames m, FirstOrderRep torep) => Scope torep -> FunDef SOACS -> m (FunDef torep)
- Futhark.Transform.FirstOrderTransform: transformLambda :: (MonadFreshNames m, Buildable rep, BuilderOps rep, LocalScope somerep m, SameScope somerep rep, LetDec rep ~ LetDec SOACS, AliasableRep rep) => Lambda SOACS -> m (Lambda rep)
- Futhark.Transform.FirstOrderTransform: transformSOAC :: Transformer m => Pat (LetDec (Rep m)) -> SOAC (Rep m) -> m ()
- Futhark.Transform.FirstOrderTransform: transformStmRecursively :: (Transformer m, LetDec (Rep m) ~ LetDec SOACS) => Stm SOACS -> m ()
- Futhark.Transform.FirstOrderTransform: type FirstOrderRep rep = (Buildable rep, BuilderOps rep, LetDec SOACS ~ LetDec rep, LParamInfo SOACS ~ LParamInfo rep, AliasableRep rep)
- Futhark.Transform.FirstOrderTransform: type Transformer (m :: Type -> Type) = (MonadBuilder m, LocalScope Rep m m, Buildable Rep m, BuilderOps Rep m, LParamInfo SOACS ~ LParamInfo Rep m, AliasableRep Rep m)
- Futhark.Transform.Rename: class Rename a
- Futhark.Transform.Rename: data RenameM a
- Futhark.Transform.Rename: instance (Futhark.Transform.Rename.Rename a, Futhark.Transform.Rename.Rename b) => Futhark.Transform.Rename.Rename (a, b)
- Futhark.Transform.Rename: instance (Futhark.Transform.Rename.Rename a, Futhark.Transform.Rename.Rename b, Futhark.Transform.Rename.Rename c) => Futhark.Transform.Rename.Rename (a, b, c)
- Futhark.Transform.Rename: instance Control.Monad.Reader.Class.MonadReader Futhark.Transform.Rename.RenameEnv Futhark.Transform.Rename.RenameM
- Futhark.Transform.Rename: instance Futhark.MonadFreshNames.MonadFreshNames Futhark.Transform.Rename.RenameM
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename ()
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Futhark.IR.Prop.Names.Names
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Futhark.IR.Syntax.Core.Attrs
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Futhark.IR.Syntax.Core.Certs
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Futhark.IR.Syntax.Core.ExtSize
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Futhark.IR.Syntax.Core.Ident
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Futhark.IR.Syntax.Core.Rank
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Futhark.IR.Syntax.Core.SubExp
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Futhark.IR.Syntax.SubExpRes
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename GHC.Types.Bool
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Language.Futhark.Core.VName
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename Language.Futhark.Primitive.PrimType
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename a => Futhark.Transform.Rename.Rename (GHC.Maybe.Maybe a)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename a => Futhark.Transform.Rename.Rename [a]
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename d => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Core.DimIndex d)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename d => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename dec => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Core.Param dec)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename dec => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Core.PatElem dec)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename dec => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Pat dec)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename dec => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.StmAux dec)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Rename shape => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Core.TypeBase shape u)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Renameable rep => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Body rep)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Renameable rep => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Exp rep)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Renameable rep => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.FunDef rep)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Renameable rep => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Lambda rep)
- Futhark.Transform.Rename: instance Futhark.Transform.Rename.Renameable rep => Futhark.Transform.Rename.Rename (Futhark.IR.Syntax.Stm rep)
- Futhark.Transform.Rename: instance GHC.Base.Applicative Futhark.Transform.Rename.RenameM
- Futhark.Transform.Rename: instance GHC.Base.Functor Futhark.Transform.Rename.RenameM
- Futhark.Transform.Rename: instance GHC.Base.Monad Futhark.Transform.Rename.RenameM
- Futhark.Transform.Rename: instance forall k (rep :: k). Futhark.Transform.Rename.Rename (Futhark.IR.Rep.NoOp rep)
- Futhark.Transform.Rename: rename :: Rename a => a -> RenameM a
- Futhark.Transform.Rename: renameBody :: (Renameable rep, MonadFreshNames m) => Body rep -> m (Body rep)
- Futhark.Transform.Rename: renameBound :: [VName] -> RenameM a -> RenameM a
- Futhark.Transform.Rename: renameExp :: (Renameable rep, MonadFreshNames m) => Exp rep -> m (Exp rep)
- Futhark.Transform.Rename: renameLambda :: (Renameable rep, MonadFreshNames m) => Lambda rep -> m (Lambda rep)
- Futhark.Transform.Rename: renamePat :: (Rename dec, MonadFreshNames m) => Pat dec -> m (Pat dec)
- Futhark.Transform.Rename: renameProg :: (Renameable rep, MonadFreshNames m) => Prog rep -> m (Prog rep)
- Futhark.Transform.Rename: renameSomething :: (Rename a, MonadFreshNames m) => a -> m a
- Futhark.Transform.Rename: renameStm :: (Renameable rep, MonadFreshNames m) => Stm rep -> m (Stm rep)
- Futhark.Transform.Rename: renameStmsWith :: (MonadFreshNames m, Renameable rep, Rename a) => Stms rep -> a -> m (Stms rep, a)
- Futhark.Transform.Rename: renamingStms :: Renameable rep => Stms rep -> (Stms rep -> RenameM a) -> RenameM a
- Futhark.Transform.Rename: substituteRename :: Substitute a => a -> RenameM a
- Futhark.Transform.Rename: type Renameable rep = (Rename LetDec rep, Rename ExpDec rep, Rename BodyDec rep, Rename FParamInfo rep, Rename LParamInfo rep, Rename RetType rep, Rename BranchType rep, Rename Op rep)
- Futhark.Transform.Substitute: class Substitute a
- Futhark.Transform.Substitute: instance (Futhark.Transform.Substitute.Substitute a, Futhark.Transform.Substitute.Substitute b) => Futhark.Transform.Substitute.Substitute (a, b)
- Futhark.Transform.Substitute: instance (Futhark.Transform.Substitute.Substitute a, Futhark.Transform.Substitute.Substitute b, Futhark.Transform.Substitute.Substitute c) => Futhark.Transform.Substitute.Substitute (a, b, c)
- Futhark.Transform.Substitute: instance (Futhark.Transform.Substitute.Substitute a, Futhark.Transform.Substitute.Substitute b, Futhark.Transform.Substitute.Substitute c, Futhark.Transform.Substitute.Substitute d) => Futhark.Transform.Substitute.Substitute (a, b, c, d)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitutable rep => Futhark.Transform.Substitute.Substitute (Futhark.IR.Prop.Scope.NameInfo rep)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitutable rep => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Body rep)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitutable rep => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Exp rep)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitutable rep => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Lambda rep)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitutable rep => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Stm rep)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute ()
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Stm rep) => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Stms rep)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Prop.Names.FV
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Prop.Names.Names
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Syntax.Core.Attrs
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Syntax.Core.Certs
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Syntax.Core.Ident
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Syntax.Core.Rank
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Syntax.Core.SubExp
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Futhark.IR.Syntax.SubExpRes
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute GHC.Types.Bool
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Language.Futhark.Core.VName
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute Language.Futhark.Primitive.PrimType
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute a => Futhark.Transform.Substitute.Substitute (GHC.Maybe.Maybe a)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute a => Futhark.Transform.Substitute.Substitute [a]
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute d => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Core.DimIndex d)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute d => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Core.Ext d)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute d => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Core.FlatDimIndex d)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute d => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Core.FlatSlice d)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute d => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Core.ShapeBase d)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute d => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Core.Slice d)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute d => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.NewShape d)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute dec => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Core.Param dec)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute dec => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Core.PatElem dec)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute dec => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Pat dec)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute dec => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.StmAux dec)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute shape => Futhark.Transform.Substitute.Substitute (Futhark.IR.Syntax.Core.TypeBase shape u)
- Futhark.Transform.Substitute: instance Futhark.Transform.Substitute.Substitute v => Futhark.Transform.Substitute.Substitute (Futhark.Analysis.PrimExp.PrimExp v)
- Futhark.Transform.Substitute: instance forall k (rep :: k). Futhark.Transform.Substitute.Substitute (Futhark.IR.Rep.NoOp rep)
- Futhark.Transform.Substitute: instance forall k v (t :: k). Futhark.Transform.Substitute.Substitute v => Futhark.Transform.Substitute.Substitute (Futhark.Analysis.PrimExp.TPrimExp t v)
- Futhark.Transform.Substitute: substituteNames :: Substitute a => Map VName VName -> a -> a
- Futhark.Transform.Substitute: type Substitutable rep = (RepTypes rep, Substitute ExpDec rep, Substitute BodyDec rep, Substitute LetDec rep, Substitute FParamInfo rep, Substitute LParamInfo rep, Substitute RetType rep, Substitute BranchType rep, Substitute Op rep)
- Futhark.Transform.Substitute: type Substitutions = Map VName VName
- Futhark.Util: atMostChars :: Int -> Text -> Text
- Futhark.Util: cartesian :: (Monoid m, Foldable t) => (a -> a -> m) -> t a -> t a -> m
- Futhark.Util: chunk :: Int -> [a] -> [[a]]
- Futhark.Util: chunkLike :: [[a]] -> [b] -> [[b]]
- Futhark.Util: chunks :: [Int] -> [a] -> [[a]]
- Futhark.Util: concatMapM :: (Monad m, Monoid b) => (a -> m b) -> [a] -> m b
- Futhark.Util: convFloat :: (RealFloat from, RealFloat to) => from -> to
- Futhark.Util: debugTraceM :: Monad m => Int -> String -> m ()
- Futhark.Util: directoryContents :: FilePath -> IO [FilePath]
- Futhark.Util: dropAt :: Int -> Int -> [a] -> [a]
- Futhark.Util: dropLast :: Int -> [a] -> [a]
- Futhark.Util: fancyTerminal :: Bool
- Futhark.Util: fixPoint :: Eq a => (a -> a) -> a -> a
- Futhark.Util: focusMaybe :: (a -> Maybe b) -> [a] -> Maybe ([a], b, [a])
- Futhark.Util: focusNth :: Integral int => int -> [a] -> Maybe ([a], a, [a])
- Futhark.Util: fromPOSIX :: FilePath -> FilePath
- Futhark.Util: hFancyTerminal :: Handle -> IO Bool
- Futhark.Util: hashText :: Text -> Text
- Futhark.Util: interactWithFileSafely :: IO a -> IO (Maybe (Either String a))
- Futhark.Util: invertMap :: (Ord v, Ord k) => Map k v -> Map v (Set k)
- Futhark.Util: isEnvVarAtLeast :: String -> Int -> Bool
- Futhark.Util: lookupWithIndex :: Eq a => a -> [(a, b)] -> Maybe (Int, b)
- Futhark.Util: mapAccumLM :: (Monad m, Traversable t) => (acc -> x -> m (acc, y)) -> acc -> t x -> m (acc, t y)
- Futhark.Util: mapEither :: (a -> Either b c) -> [a] -> ([b], [c])
- Futhark.Util: maxinum :: (Num a, Ord a, Foldable f) => f a -> a
- Futhark.Util: maybeHead :: [a] -> Maybe a
- Futhark.Util: maybeNth :: Integral int => int -> [a] -> Maybe a
- Futhark.Util: mininum :: (Num a, Ord a, Foldable f) => f a -> a
- Futhark.Util: nubByOrd :: (a -> a -> Ordering) -> [a] -> [a]
- Futhark.Util: nubOrd :: Ord a => [a] -> [a]
- Futhark.Util: partitionMaybe :: (a -> Maybe b) -> [a] -> ([b], [a])
- Futhark.Util: pmapIO :: Maybe Int -> (a -> IO b) -> [a] -> IO [b]
- Futhark.Util: runProgramWithExitCode :: FilePath -> [String] -> ByteString -> IO (Either IOException (ExitCode, String, String))
- Futhark.Util: showText :: Show a => a -> Text
- Futhark.Util: splitAt3 :: Int -> Int -> [a] -> ([a], [a], [a])
- Futhark.Util: splitFromEnd :: Int -> [a] -> ([a], [a])
- Futhark.Util: startupTime :: UTCTime
- Futhark.Util: takeLast :: Int -> [a] -> [a]
- Futhark.Util: toPOSIX :: FilePath -> FilePath
- Futhark.Util: topologicalSort :: (a -> a -> Bool) -> [a] -> [a]
- Futhark.Util: traverseFold :: (Monoid m, Traversable t, Applicative f) => (a -> f m) -> t a -> f m
- Futhark.Util: trim :: String -> String
- Futhark.Util: type EncodedText = Text
- Futhark.Util: type UserText = Text
- Futhark.Util: unixEnvironment :: [(String, String)]
- Futhark.Util: zEncodeText :: UserText -> EncodedText
- Futhark.Util.CMath: cbrt :: Double -> Double
- Futhark.Util.CMath: cbrtf :: Float -> Float
- Futhark.Util.CMath: ceilDouble :: Double -> Double
- Futhark.Util.CMath: ceilFloat :: Float -> Float
- Futhark.Util.CMath: copysign :: Double -> Double -> Double
- Futhark.Util.CMath: copysignf :: Float -> Float -> Float
- Futhark.Util.CMath: erf :: Double -> Double
- Futhark.Util.CMath: erfc :: Double -> Double
- Futhark.Util.CMath: erfcf :: Float -> Float
- Futhark.Util.CMath: erff :: Float -> Float
- Futhark.Util.CMath: floorDouble :: Double -> Double
- Futhark.Util.CMath: floorFloat :: Float -> Float
- Futhark.Util.CMath: hypot :: Double -> Double -> Double
- Futhark.Util.CMath: hypotf :: Float -> Float -> Float
- Futhark.Util.CMath: ldexp :: Double -> CInt -> Double
- Futhark.Util.CMath: ldexpf :: Float -> CInt -> Float
- Futhark.Util.CMath: lgamma :: Double -> Double
- Futhark.Util.CMath: lgammaf :: Float -> Float
- Futhark.Util.CMath: nextafter :: Double -> Double -> Double
- Futhark.Util.CMath: nextafterf :: Float -> Float -> Float
- Futhark.Util.CMath: roundDouble :: Double -> Double
- Futhark.Util.CMath: roundFloat :: Float -> Float
- Futhark.Util.CMath: tgamma :: Double -> Double
- Futhark.Util.CMath: tgammaf :: Float -> Float
- Futhark.Util.IntegralExp: Wrapped :: a -> Wrapped a
- Futhark.Util.IntegralExp: [wrappedValue] :: Wrapped a -> a
- Futhark.Util.IntegralExp: class Num e => IntegralExp e
- Futhark.Util.IntegralExp: div :: IntegralExp e => e -> e -> e
- Futhark.Util.IntegralExp: divUp :: IntegralExp e => e -> e -> e
- Futhark.Util.IntegralExp: instance GHC.Classes.Eq a => GHC.Classes.Eq (Futhark.Util.IntegralExp.Wrapped a)
- Futhark.Util.IntegralExp: instance GHC.Classes.Ord a => GHC.Classes.Ord (Futhark.Util.IntegralExp.Wrapped a)
- Futhark.Util.IntegralExp: instance GHC.Enum.Enum a => GHC.Enum.Enum (Futhark.Util.IntegralExp.Wrapped a)
- Futhark.Util.IntegralExp: instance GHC.Num.Num a => GHC.Num.Num (Futhark.Util.IntegralExp.Wrapped a)
- Futhark.Util.IntegralExp: instance GHC.Real.Integral a => Futhark.Util.IntegralExp.IntegralExp (Futhark.Util.IntegralExp.Wrapped a)
- Futhark.Util.IntegralExp: instance GHC.Show.Show a => GHC.Show.Show (Futhark.Util.IntegralExp.Wrapped a)
- Futhark.Util.IntegralExp: mod :: IntegralExp e => e -> e -> e
- Futhark.Util.IntegralExp: newtype Wrapped a
- Futhark.Util.IntegralExp: nextMul :: IntegralExp e => e -> e -> e
- Futhark.Util.IntegralExp: pow :: IntegralExp e => e -> e -> e
- Futhark.Util.IntegralExp: quot :: IntegralExp e => e -> e -> e
- Futhark.Util.IntegralExp: rem :: IntegralExp e => e -> e -> e
- Futhark.Util.IntegralExp: sgn :: IntegralExp e => e -> Maybe Int
- Futhark.Util.Log: addLog :: MonadLogger m => Log -> m ()
- Futhark.Util.Log: class (Applicative m, Monad m) => MonadLogger (m :: Type -> Type)
- Futhark.Util.Log: class ToLog a
- Futhark.Util.Log: data Log
- Futhark.Util.Log: instance Futhark.Util.Log.MonadLogger GHC.Types.IO
- Futhark.Util.Log: instance Futhark.Util.Log.ToLog Data.Text.Internal.Text
- Futhark.Util.Log: instance Futhark.Util.Log.ToLog GHC.Base.String
- Futhark.Util.Log: instance GHC.Base.Monad m => Futhark.Util.Log.MonadLogger (Control.Monad.Trans.RWS.Lazy.RWST r Futhark.Util.Log.Log s m)
- Futhark.Util.Log: instance GHC.Base.Monad m => Futhark.Util.Log.MonadLogger (Control.Monad.Trans.RWS.Strict.RWST r Futhark.Util.Log.Log s m)
- Futhark.Util.Log: instance GHC.Base.Monad m => Futhark.Util.Log.MonadLogger (Control.Monad.Trans.Writer.Lazy.WriterT Futhark.Util.Log.Log m)
- Futhark.Util.Log: instance GHC.Base.Monoid Futhark.Util.Log.Log
- Futhark.Util.Log: instance GHC.Base.Semigroup Futhark.Util.Log.Log
- Futhark.Util.Log: logMsg :: (MonadLogger m, ToLog a) => a -> m ()
- Futhark.Util.Log: toLog :: ToLog a => a -> Log
- Futhark.Util.Log: toText :: Log -> Text
- Futhark.Util.Options: commonOptions :: String -> String -> [FunOptDescr cfg] -> [FunOptDescr cfg]
- Futhark.Util.Options: mainWithOptions :: cfg -> [FunOptDescr cfg] -> String -> ([String] -> cfg -> Maybe (IO ())) -> String -> [String] -> IO ()
- Futhark.Util.Options: optionsError :: String -> IO ()
- Futhark.Util.Options: type FunOptDescr cfg = OptDescr Either IO () cfg -> cfg
- Futhark.Util.Pretty: (</>) :: Doc a -> Doc a -> Doc a
- Futhark.Util.Pretty: Black :: Color
- Futhark.Util.Pretty: Blue :: Color
- Futhark.Util.Pretty: Cyan :: Color
- Futhark.Util.Pretty: Green :: Color
- Futhark.Util.Pretty: Magenta :: Color
- Futhark.Util.Pretty: Red :: Color
- Futhark.Util.Pretty: White :: Color
- Futhark.Util.Pretty: Yellow :: Color
- Futhark.Util.Pretty: annot :: [Doc a] -> Doc a -> Doc a
- Futhark.Util.Pretty: apply :: [Doc a] -> Doc a
- Futhark.Util.Pretty: bgColor :: Color -> AnsiStyle
- Futhark.Util.Pretty: bgColorDull :: Color -> AnsiStyle
- Futhark.Util.Pretty: bold :: AnsiStyle
- Futhark.Util.Pretty: color :: Color -> AnsiStyle
- Futhark.Util.Pretty: colorDull :: Color -> AnsiStyle
- Futhark.Util.Pretty: commasep :: [Doc a] -> Doc a
- Futhark.Util.Pretty: commastack :: [Doc a] -> Doc a
- Futhark.Util.Pretty: data AnsiStyle
- Futhark.Util.Pretty: data Color
- Futhark.Util.Pretty: docString :: Doc a -> String
- Futhark.Util.Pretty: docText :: Doc a -> Text
- Futhark.Util.Pretty: docTextForHandle :: Handle -> Doc AnsiStyle -> IO Text
- Futhark.Util.Pretty: hPutDoc :: Handle -> Doc AnsiStyle -> IO ()
- Futhark.Util.Pretty: hPutDocLn :: Handle -> Doc AnsiStyle -> IO ()
- Futhark.Util.Pretty: instance Prettyprinter.Internal.Pretty Numeric.Half.Internal.Half
- Futhark.Util.Pretty: italicized :: AnsiStyle
- Futhark.Util.Pretty: nestedBlock :: Doc a -> Doc a -> Doc a -> Doc a
- Futhark.Util.Pretty: oneLine :: Doc a -> Doc a
- Futhark.Util.Pretty: parensIf :: Bool -> Doc a -> Doc a
- Futhark.Util.Pretty: ppTuple' :: [Doc a] -> Doc a
- Futhark.Util.Pretty: ppTupleLines' :: [Doc a] -> Doc a
- Futhark.Util.Pretty: prettyString :: Pretty a => a -> String
- Futhark.Util.Pretty: prettyStringOneLine :: Pretty a => a -> String
- Futhark.Util.Pretty: prettyText :: Pretty a => a -> Text
- Futhark.Util.Pretty: prettyTextOneLine :: Pretty a => a -> Text
- Futhark.Util.Pretty: prettyTuple :: Pretty a => [a] -> Text
- Futhark.Util.Pretty: prettyTupleLines :: Pretty a => [a] -> Text
- Futhark.Util.Pretty: putDoc :: Doc AnsiStyle -> IO ()
- Futhark.Util.Pretty: putDocLn :: Doc AnsiStyle -> IO ()
- Futhark.Util.Pretty: semistack :: [Doc a] -> Doc a
- Futhark.Util.Pretty: shorten :: Doc a -> Doc b
- Futhark.Util.Pretty: stack :: [Doc a] -> Doc a
- Futhark.Util.Pretty: textwrap :: Text -> Doc a
- Futhark.Util.Pretty: underlined :: AnsiStyle
- Futhark.Util.ProgressBar: ProgressBar :: Int -> Double -> Double -> ProgressBar
- Futhark.Util.ProgressBar: [progressBarBound] :: ProgressBar -> Double
- Futhark.Util.ProgressBar: [progressBarElapsed] :: ProgressBar -> Double
- Futhark.Util.ProgressBar: [progressBarSteps] :: ProgressBar -> Int
- Futhark.Util.ProgressBar: data ProgressBar
- Futhark.Util.ProgressBar: progressBar :: ProgressBar -> Text
- Futhark.Util.ProgressBar: progressSpinner :: Int -> Text
- Futhark.Util.Table: Black :: Color
- Futhark.Util.Table: Blue :: Color
- Futhark.Util.Table: Cyan :: Color
- Futhark.Util.Table: Green :: Color
- Futhark.Util.Table: Magenta :: Color
- Futhark.Util.Table: Red :: Color
- Futhark.Util.Table: White :: Color
- Futhark.Util.Table: Yellow :: Color
- Futhark.Util.Table: color :: Color -> AnsiStyle
- Futhark.Util.Table: data AnsiStyle
- Futhark.Util.Table: data Color
- Futhark.Util.Table: data Entry
- Futhark.Util.Table: hPutTable :: Handle -> [[Entry]] -> Int -> IO ()
- Futhark.Util.Table: instance GHC.Show.Show Futhark.Util.Table.RowTemplate
- Futhark.Util.Table: mkEntry :: String -> AnsiStyle -> Entry
- Futhark.Version: version :: Version
- Futhark.Version: versionString :: Text
- Language.Futhark.Core: L :: Loc -> a -> L a
- Language.Futhark.Core: NoUniqueness :: NoUniqueness
- Language.Futhark.Core: Nonunique :: Uniqueness
- Language.Futhark.Core: Unique :: Uniqueness
- Language.Futhark.Core: VName :: !Name -> !Int -> VName
- Language.Futhark.Core: baseName :: VName -> Name
- Language.Futhark.Core: baseString :: VName -> String
- Language.Futhark.Core: baseTag :: VName -> Int
- Language.Futhark.Core: baseText :: VName -> Text
- Language.Futhark.Core: class Located a
- Language.Futhark.Core: data Half
- Language.Futhark.Core: data Int16
- Language.Futhark.Core: data Int32
- Language.Futhark.Core: data Int64
- Language.Futhark.Core: data Int8
- Language.Futhark.Core: data L a
- Language.Futhark.Core: data Loc
- Language.Futhark.Core: data Name
- Language.Futhark.Core: data NoUniqueness
- Language.Futhark.Core: data SrcLoc
- Language.Futhark.Core: data Uniqueness
- Language.Futhark.Core: data VName
- Language.Futhark.Core: data Word16
- Language.Futhark.Core: data Word32
- Language.Futhark.Core: data Word64
- Language.Futhark.Core: data Word8
- Language.Futhark.Core: instance Data.String.IsString Language.Futhark.Core.Name
- Language.Futhark.Core: instance GHC.Base.Monoid Language.Futhark.Core.NoUniqueness
- Language.Futhark.Core: instance GHC.Base.Monoid Language.Futhark.Core.Uniqueness
- Language.Futhark.Core: instance GHC.Base.Semigroup Language.Futhark.Core.Name
- Language.Futhark.Core: instance GHC.Base.Semigroup Language.Futhark.Core.NoUniqueness
- Language.Futhark.Core: instance GHC.Base.Semigroup Language.Futhark.Core.Uniqueness
- Language.Futhark.Core: instance GHC.Classes.Eq Language.Futhark.Core.Name
- Language.Futhark.Core: instance GHC.Classes.Eq Language.Futhark.Core.NoUniqueness
- Language.Futhark.Core: instance GHC.Classes.Eq Language.Futhark.Core.Uniqueness
- Language.Futhark.Core: instance GHC.Classes.Eq Language.Futhark.Core.VName
- Language.Futhark.Core: instance GHC.Classes.Ord Language.Futhark.Core.Name
- Language.Futhark.Core: instance GHC.Classes.Ord Language.Futhark.Core.NoUniqueness
- Language.Futhark.Core: instance GHC.Classes.Ord Language.Futhark.Core.Uniqueness
- Language.Futhark.Core: instance GHC.Classes.Ord Language.Futhark.Core.VName
- Language.Futhark.Core: instance GHC.Show.Show Language.Futhark.Core.Name
- Language.Futhark.Core: instance GHC.Show.Show Language.Futhark.Core.NoUniqueness
- Language.Futhark.Core: instance GHC.Show.Show Language.Futhark.Core.Uniqueness
- Language.Futhark.Core: instance GHC.Show.Show Language.Futhark.Core.VName
- Language.Futhark.Core: instance Prettyprinter.Internal.Pretty Language.Futhark.Core.Name
- Language.Futhark.Core: instance Prettyprinter.Internal.Pretty Language.Futhark.Core.NoUniqueness
- Language.Futhark.Core: instance Prettyprinter.Internal.Pretty Language.Futhark.Core.Uniqueness
- Language.Futhark.Core: locOf :: Located a => a -> Loc
- Language.Futhark.Core: locOfList :: Located a => [a] -> Loc
- Language.Futhark.Core: locStr :: Located a => a -> String
- Language.Futhark.Core: locStrRel :: (Located a, Located b) => a -> b -> String
- Language.Futhark.Core: locText :: Located a => a -> Text
- Language.Futhark.Core: locTextRel :: (Located a, Located b) => a -> b -> Text
- Language.Futhark.Core: nameFromString :: String -> Name
- Language.Futhark.Core: nameFromText :: Text -> Name
- Language.Futhark.Core: nameToString :: Name -> String
- Language.Futhark.Core: nameToText :: Name -> Text
- Language.Futhark.Core: noLoc :: IsLocation a => a
- Language.Futhark.Core: prettyStacktrace :: Int -> [Text] -> Text
- Language.Futhark.Core: quote :: Text -> Text
- Language.Futhark.Core: srclocOf :: Located a => a -> SrcLoc
- Language.Futhark.Core: unLoc :: L a -> a
- Language.Futhark.FreeVars: data FV
- Language.Futhark.FreeVars: freeInExp :: ExpBase Info VName -> FV
- Language.Futhark.FreeVars: freeInPat :: Pat (TypeBase Size u) -> FV
- Language.Futhark.FreeVars: freeInType :: TypeBase Size u -> FV
- Language.Futhark.FreeVars: freeWithout :: FV -> Set VName -> FV
- Language.Futhark.FreeVars: fvVars :: FV -> Set VName
- Language.Futhark.FreeVars: instance GHC.Base.Monoid Language.Futhark.FreeVars.FV
- Language.Futhark.FreeVars: instance GHC.Base.Semigroup Language.Futhark.FreeVars.FV
- Language.Futhark.FreeVars: instance GHC.Show.Show Language.Futhark.FreeVars.FV
- Language.Futhark.Interpreter: BreakNaN :: BreakReason
- Language.Futhark.Interpreter: BreakPoint :: BreakReason
- Language.Futhark.Interpreter: Ctx :: Env -> Map ImportName Env -> Ctx
- Language.Futhark.Interpreter: ExtOpBreak :: Loc -> BreakReason -> NonEmpty StackFrame -> a -> ExtOp a
- Language.Futhark.Interpreter: ExtOpError :: InterpreterError -> ExtOp a
- Language.Futhark.Interpreter: ExtOpTrace :: Text -> Doc () -> a -> ExtOp a
- Language.Futhark.Interpreter: StackFrame :: Loc -> Ctx -> StackFrame
- Language.Futhark.Interpreter: [ctxEnv] :: Ctx -> Env
- Language.Futhark.Interpreter: [ctxImports] :: Ctx -> Map ImportName Env
- Language.Futhark.Interpreter: [stackFrameCtx] :: StackFrame -> Ctx
- Language.Futhark.Interpreter: [stackFrameLoc] :: StackFrame -> Loc
- Language.Futhark.Interpreter: ctxWithImports :: [Env] -> Ctx -> Ctx
- Language.Futhark.Interpreter: data BreakReason
- Language.Futhark.Interpreter: data Ctx
- Language.Futhark.Interpreter: data Env
- Language.Futhark.Interpreter: data ExtOp a
- Language.Futhark.Interpreter: data InterpreterError
- Language.Futhark.Interpreter: data StackFrame
- Language.Futhark.Interpreter: fromTuple :: forall (m :: Type -> Type). Value m -> Maybe [Value m]
- Language.Futhark.Interpreter: initialCtx :: Ctx
- Language.Futhark.Interpreter: instance Control.Monad.Free.Class.MonadFree Language.Futhark.Interpreter.ExtOp Language.Futhark.Interpreter.EvalM
- Language.Futhark.Interpreter: instance Control.Monad.Reader.Class.MonadReader (Language.Futhark.Interpreter.Stack, Data.Map.Internal.Map Language.Futhark.Syntax.ImportName Language.Futhark.Interpreter.Env) Language.Futhark.Interpreter.EvalM
- Language.Futhark.Interpreter: instance Control.Monad.State.Class.MonadState (Language.Futhark.Interpreter.Exts, Language.Futhark.Interpreter.AD.Counter) Language.Futhark.Interpreter.EvalM
- Language.Futhark.Interpreter: instance Data.Loc.Located Language.Futhark.Interpreter.StackFrame
- Language.Futhark.Interpreter: instance GHC.Base.Applicative Language.Futhark.Interpreter.EvalM
- Language.Futhark.Interpreter: instance GHC.Base.Functor Language.Futhark.Interpreter.EvalM
- Language.Futhark.Interpreter: instance GHC.Base.Functor Language.Futhark.Interpreter.ExtOp
- Language.Futhark.Interpreter: instance GHC.Base.Monad Language.Futhark.Interpreter.EvalM
- Language.Futhark.Interpreter: instance GHC.Base.Monoid Language.Futhark.Interpreter.Env
- Language.Futhark.Interpreter: instance GHC.Base.Semigroup Language.Futhark.Interpreter.Env
- Language.Futhark.Interpreter: instance GHC.Show.Show Language.Futhark.Interpreter.Env
- Language.Futhark.Interpreter: instance GHC.Show.Show Language.Futhark.Interpreter.InterpreterError
- Language.Futhark.Interpreter: instance GHC.Show.Show Language.Futhark.Interpreter.Module
- Language.Futhark.Interpreter: instance GHC.Show.Show Language.Futhark.Interpreter.SizeClosure
- Language.Futhark.Interpreter: instance GHC.Show.Show Language.Futhark.Interpreter.TermBinding
- Language.Futhark.Interpreter: instance GHC.Show.Show Language.Futhark.Interpreter.TypeBinding
- Language.Futhark.Interpreter: instance Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.Shape Language.Futhark.Interpreter.SizeClosure)
- Language.Futhark.Interpreter: instance Prettyprinter.Internal.Pretty Language.Futhark.Interpreter.Indexing
- Language.Futhark.Interpreter: instance Prettyprinter.Internal.Pretty Language.Futhark.Interpreter.SizeClosure
- Language.Futhark.Interpreter: interpretDec :: Ctx -> Dec -> F ExtOp Ctx
- Language.Futhark.Interpreter: interpretExp :: Ctx -> Exp -> F ExtOp Value
- Language.Futhark.Interpreter: interpretFunction :: Ctx -> VName -> [Value] -> Either Text (F ExtOp Value)
- Language.Futhark.Interpreter: interpretImport :: Ctx -> (ImportName, Prog) -> F ExtOp Ctx
- Language.Futhark.Interpreter: isEmptyArray :: forall (m :: Type -> Type). Value m -> Bool
- Language.Futhark.Interpreter: prettyEmptyArray :: forall (m :: Type -> Type). TypeBase () () -> Value m -> Text
- Language.Futhark.Interpreter: prettyInterpreterError :: InterpreterError -> Doc AnsiStyle
- Language.Futhark.Interpreter: prettyValue :: forall (m :: Type -> Type) a. Value m -> Doc a
- Language.Futhark.Interpreter: type Value = Value EvalM
- Language.Futhark.Interpreter: typeCheckerEnv :: Env -> Env
- Language.Futhark.Interpreter: valueText :: forall (m :: Type -> Type). Value m -> Text
- Language.Futhark.Interpreter.AD: Constant :: PrimValue -> ADValue
- Language.Futhark.Interpreter.AD: Counter :: Int -> Counter
- Language.Futhark.Interpreter.AD: Depth :: Int -> Depth
- Language.Futhark.Interpreter.AD: JVP :: JVPValue -> ADVariable
- Language.Futhark.Interpreter.AD: JVPValue :: ADValue -> ADValue -> JVPValue
- Language.Futhark.Interpreter.AD: OpBin :: BinOp -> Op
- Language.Futhark.Interpreter.AD: OpCmp :: CmpOp -> Op
- Language.Futhark.Interpreter.AD: OpConv :: ConvOp -> Op
- Language.Futhark.Interpreter.AD: OpFn :: Text -> Op
- Language.Futhark.Interpreter.AD: OpUn :: UnOp -> Op
- Language.Futhark.Interpreter.AD: TapeConst :: ADValue -> Tape
- Language.Futhark.Interpreter.AD: TapeID :: Counter -> ADValue -> Tape
- Language.Futhark.Interpreter.AD: TapeOp :: Op -> [Tape] -> Counter -> ADValue -> Tape
- Language.Futhark.Interpreter.AD: VJP :: VJPValue -> ADVariable
- Language.Futhark.Interpreter.AD: VJPValue :: Tape -> VJPValue
- Language.Futhark.Interpreter.AD: Variable :: Depth -> ADVariable -> ADValue
- Language.Futhark.Interpreter.AD: addFor :: PrimType -> BinOp
- Language.Futhark.Interpreter.AD: data ADValue
- Language.Futhark.Interpreter.AD: data ADVariable
- Language.Futhark.Interpreter.AD: data JVPValue
- Language.Futhark.Interpreter.AD: data Op
- Language.Futhark.Interpreter.AD: data Tape
- Language.Futhark.Interpreter.AD: deriveTape :: Tape -> ADValue -> Counter -> Either String (Map Counter ADValue, Counter)
- Language.Futhark.Interpreter.AD: doOp :: Op -> [ADValue] -> Counter -> Either String (ADValue, Counter)
- Language.Futhark.Interpreter.AD: instance GHC.Classes.Eq Language.Futhark.Interpreter.AD.Counter
- Language.Futhark.Interpreter.AD: instance GHC.Classes.Eq Language.Futhark.Interpreter.AD.Depth
- Language.Futhark.Interpreter.AD: instance GHC.Classes.Ord Language.Futhark.Interpreter.AD.Counter
- Language.Futhark.Interpreter.AD: instance GHC.Classes.Ord Language.Futhark.Interpreter.AD.Depth
- Language.Futhark.Interpreter.AD: instance GHC.Num.Num Language.Futhark.Interpreter.AD.Counter
- Language.Futhark.Interpreter.AD: instance GHC.Show.Show Language.Futhark.Interpreter.AD.ADValue
- Language.Futhark.Interpreter.AD: instance GHC.Show.Show Language.Futhark.Interpreter.AD.ADVariable
- Language.Futhark.Interpreter.AD: instance GHC.Show.Show Language.Futhark.Interpreter.AD.Counter
- Language.Futhark.Interpreter.AD: instance GHC.Show.Show Language.Futhark.Interpreter.AD.Depth
- Language.Futhark.Interpreter.AD: instance GHC.Show.Show Language.Futhark.Interpreter.AD.JVPValue
- Language.Futhark.Interpreter.AD: instance GHC.Show.Show Language.Futhark.Interpreter.AD.Op
- Language.Futhark.Interpreter.AD: instance GHC.Show.Show Language.Futhark.Interpreter.AD.Tape
- Language.Futhark.Interpreter.AD: instance GHC.Show.Show Language.Futhark.Interpreter.AD.VJPValue
- Language.Futhark.Interpreter.AD: newtype Counter
- Language.Futhark.Interpreter.AD: newtype Depth
- Language.Futhark.Interpreter.AD: newtype VJPValue
- Language.Futhark.Interpreter.AD: primitive :: ADValue -> PrimValue
- Language.Futhark.Interpreter.AD: tapePrimal :: Tape -> ADValue
- Language.Futhark.Interpreter.AD: unionWithM :: (Monad m, Ord k) => (a -> a -> m a) -> Map k a -> Map k a -> m (Map k a)
- Language.Futhark.Interpreter.AD: unionsWithM :: (Foldable f, Monad m, Ord k) => (a -> a -> m a) -> f (Map k a) -> m (Map k a)
- Language.Futhark.Interpreter.AD: varPrimal :: ADVariable -> PrimValue
- Language.Futhark.Interpreter.Values: ShapeDim :: d -> Shape d -> Shape d
- Language.Futhark.Interpreter.Values: ShapeLeaf :: Shape d
- Language.Futhark.Interpreter.Values: ShapeRecord :: Map Name (Shape d) -> Shape d
- Language.Futhark.Interpreter.Values: ShapeSum :: Map Name [Shape d] -> Shape d
- Language.Futhark.Interpreter.Values: ValueAD :: Depth -> ADVariable -> Value (m :: Type -> Type)
- Language.Futhark.Interpreter.Values: ValueAcc :: ValueShape -> (Value m -> Value m -> m (Value m)) -> !Array Int (Value m) -> Value (m :: Type -> Type)
- Language.Futhark.Interpreter.Values: ValueArray :: ValueShape -> !Array Int (Value m) -> Value (m :: Type -> Type)
- Language.Futhark.Interpreter.Values: ValueFun :: (Value m -> m (Value m)) -> Value (m :: Type -> Type)
- Language.Futhark.Interpreter.Values: ValuePrim :: !PrimValue -> Value (m :: Type -> Type)
- Language.Futhark.Interpreter.Values: ValueRecord :: Map Name (Value m) -> Value (m :: Type -> Type)
- Language.Futhark.Interpreter.Values: ValueSum :: ValueShape -> Name -> [Value m] -> Value (m :: Type -> Type)
- Language.Futhark.Interpreter.Values: arrayLength :: forall int (m :: Type -> Type). Integral int => Array Int (Value m) -> int
- Language.Futhark.Interpreter.Values: arrayValueShape :: forall (m :: Type -> Type). Value m -> ValueShape
- Language.Futhark.Interpreter.Values: data Shape d
- Language.Futhark.Interpreter.Values: data Value (m :: Type -> Type)
- Language.Futhark.Interpreter.Values: fromDataValue :: forall (m :: Type -> Type). Value -> Value m
- Language.Futhark.Interpreter.Values: fromTuple :: forall (m :: Type -> Type). Value m -> Maybe [Value m]
- Language.Futhark.Interpreter.Values: instance Data.Foldable.Foldable Language.Futhark.Interpreter.Values.Shape
- Language.Futhark.Interpreter.Values: instance Data.Traversable.Traversable Language.Futhark.Interpreter.Values.Shape
- Language.Futhark.Interpreter.Values: instance GHC.Base.Functor Language.Futhark.Interpreter.Values.Shape
- Language.Futhark.Interpreter.Values: instance GHC.Classes.Eq (Language.Futhark.Interpreter.Values.Value m)
- Language.Futhark.Interpreter.Values: instance GHC.Classes.Eq d => GHC.Classes.Eq (Language.Futhark.Interpreter.Values.Shape d)
- Language.Futhark.Interpreter.Values: instance GHC.Show.Show (Language.Futhark.Interpreter.Values.Value m)
- Language.Futhark.Interpreter.Values: instance GHC.Show.Show d => GHC.Show.Show (Language.Futhark.Interpreter.Values.Shape d)
- Language.Futhark.Interpreter.Values: instance Prettyprinter.Internal.Pretty d => Prettyprinter.Internal.Pretty (Language.Futhark.Interpreter.Values.Shape d)
- Language.Futhark.Interpreter.Values: isEmptyArray :: forall (m :: Type -> Type). Value m -> Bool
- Language.Futhark.Interpreter.Values: prettyEmptyArray :: forall (m :: Type -> Type). TypeBase () () -> Value m -> Text
- Language.Futhark.Interpreter.Values: prettyValue :: forall (m :: Type -> Type) a. Value m -> Doc a
- Language.Futhark.Interpreter.Values: structTypeShape :: StructType -> Shape (Maybe Int64)
- Language.Futhark.Interpreter.Values: toArray :: forall (m :: Type -> Type). ValueShape -> [Value m] -> Value m
- Language.Futhark.Interpreter.Values: toArray' :: forall (m :: Type -> Type). ValueShape -> [Value m] -> Value m
- Language.Futhark.Interpreter.Values: toTuple :: forall (m :: Type -> Type). [Value m] -> Value m
- Language.Futhark.Interpreter.Values: type ValueShape = Shape Int64
- Language.Futhark.Interpreter.Values: typeShape :: TypeBase d u -> Shape d
- Language.Futhark.Interpreter.Values: valueAccum :: forall a (m :: Type -> Type). (a -> Value m -> (a, Value m)) -> a -> Value m -> (a, Value m)
- Language.Futhark.Interpreter.Values: valueAccumLM :: forall f a (m :: Type -> Type). Monad f => (a -> Value m -> f (a, Value m)) -> a -> Value m -> f (a, Value m)
- Language.Futhark.Interpreter.Values: valueShape :: forall (m :: Type -> Type). Value m -> ValueShape
- Language.Futhark.Interpreter.Values: valueText :: forall (m :: Type -> Type). Value m -> Text
- Language.Futhark.Parser: Comment :: Loc -> Text -> Comment
- Language.Futhark.Parser: SyntaxError :: Loc -> Text -> SyntaxError
- Language.Futhark.Parser: [commentLoc] :: Comment -> Loc
- Language.Futhark.Parser: [commentText] :: Comment -> Text
- Language.Futhark.Parser: [syntaxErrorLoc] :: SyntaxError -> Loc
- Language.Futhark.Parser: [syntaxErrorMsg] :: SyntaxError -> Text
- Language.Futhark.Parser: data Comment
- Language.Futhark.Parser: data SyntaxError
- Language.Futhark.Parser: parseDecOrExp :: FilePath -> Text -> Either SyntaxError (Either UncheckedDec UncheckedExp)
- Language.Futhark.Parser: parseExp :: FilePath -> Text -> Either SyntaxError UncheckedExp
- Language.Futhark.Parser: parseFuthark :: FilePath -> Text -> Either SyntaxError UncheckedProg
- Language.Futhark.Parser: parseFutharkWithComments :: FilePath -> Text -> Either SyntaxError (UncheckedProg, [Comment])
- Language.Futhark.Parser: parseModExp :: FilePath -> Text -> Either SyntaxError (ModExpBase (NoInfo :: Type -> Type) Name)
- Language.Futhark.Parser: parseType :: FilePath -> Text -> Either SyntaxError UncheckedTypeExp
- Language.Futhark.Parser.Lexer.Tokens: APOSTROPHE :: Token
- Language.Futhark.Parser.Lexer.Tokens: APOSTROPHE_THEN_HAT :: Token
- Language.Futhark.Parser.Lexer.Tokens: APOSTROPHE_THEN_TILDE :: Token
- Language.Futhark.Parser.Lexer.Tokens: ASSERT :: Token
- Language.Futhark.Parser.Lexer.Tokens: ASTERISK :: Token
- Language.Futhark.Parser.Lexer.Tokens: BACKSLASH :: Token
- Language.Futhark.Parser.Lexer.Tokens: BACKTICK :: Token
- Language.Futhark.Parser.Lexer.Tokens: BANG :: Token
- Language.Futhark.Parser.Lexer.Tokens: CASE :: Token
- Language.Futhark.Parser.Lexer.Tokens: CHARLIT :: Char -> Token
- Language.Futhark.Parser.Lexer.Tokens: COLON :: Token
- Language.Futhark.Parser.Lexer.Tokens: COLON_GT :: Token
- Language.Futhark.Parser.Lexer.Tokens: COMMA :: Token
- Language.Futhark.Parser.Lexer.Tokens: COMMENT :: Text -> Token
- Language.Futhark.Parser.Lexer.Tokens: CONSTRUCTOR :: Name -> Token
- Language.Futhark.Parser.Lexer.Tokens: DEF :: Token
- Language.Futhark.Parser.Lexer.Tokens: DO :: Token
- Language.Futhark.Parser.Lexer.Tokens: DOC :: Text -> Token
- Language.Futhark.Parser.Lexer.Tokens: DOLLAR :: Token
- Language.Futhark.Parser.Lexer.Tokens: DOT :: Token
- Language.Futhark.Parser.Lexer.Tokens: ELSE :: Token
- Language.Futhark.Parser.Lexer.Tokens: ENTRY :: Token
- Language.Futhark.Parser.Lexer.Tokens: EOF :: Token
- Language.Futhark.Parser.Lexer.Tokens: EQU :: Token
- Language.Futhark.Parser.Lexer.Tokens: ERROR :: Text -> Token
- Language.Futhark.Parser.Lexer.Tokens: F16LIT :: Half -> Token
- Language.Futhark.Parser.Lexer.Tokens: F32LIT :: Float -> Token
- Language.Futhark.Parser.Lexer.Tokens: F64LIT :: Double -> Token
- Language.Futhark.Parser.Lexer.Tokens: FALSE :: Token
- Language.Futhark.Parser.Lexer.Tokens: FLOATLIT :: Double -> Token
- Language.Futhark.Parser.Lexer.Tokens: FOR :: Token
- Language.Futhark.Parser.Lexer.Tokens: HASH_LBRACKET :: Token
- Language.Futhark.Parser.Lexer.Tokens: HAT :: Token
- Language.Futhark.Parser.Lexer.Tokens: HOLE :: Token
- Language.Futhark.Parser.Lexer.Tokens: I16LIT :: Int16 -> Token
- Language.Futhark.Parser.Lexer.Tokens: I32LIT :: Int32 -> Token
- Language.Futhark.Parser.Lexer.Tokens: I64LIT :: Int64 -> Token
- Language.Futhark.Parser.Lexer.Tokens: I8LIT :: Int8 -> Token
- Language.Futhark.Parser.Lexer.Tokens: ID :: Name -> Token
- Language.Futhark.Parser.Lexer.Tokens: IF :: Token
- Language.Futhark.Parser.Lexer.Tokens: IMPORT :: Token
- Language.Futhark.Parser.Lexer.Tokens: IN :: Token
- Language.Futhark.Parser.Lexer.Tokens: INCLUDE :: Token
- Language.Futhark.Parser.Lexer.Tokens: INDEXING :: Token
- Language.Futhark.Parser.Lexer.Tokens: INTLIT :: Integer -> Token
- Language.Futhark.Parser.Lexer.Tokens: LBRACKET :: Token
- Language.Futhark.Parser.Lexer.Tokens: LCURLY :: Token
- Language.Futhark.Parser.Lexer.Tokens: LET :: Token
- Language.Futhark.Parser.Lexer.Tokens: LOCAL :: Token
- Language.Futhark.Parser.Lexer.Tokens: LOOP :: Token
- Language.Futhark.Parser.Lexer.Tokens: LPAR :: Token
- Language.Futhark.Parser.Lexer.Tokens: LTH :: Token
- Language.Futhark.Parser.Lexer.Tokens: MATCH :: Token
- Language.Futhark.Parser.Lexer.Tokens: MODULE :: Token
- Language.Futhark.Parser.Lexer.Tokens: NATLIT :: Name -> Integer -> Token
- Language.Futhark.Parser.Lexer.Tokens: NEGATE :: Token
- Language.Futhark.Parser.Lexer.Tokens: OPEN :: Token
- Language.Futhark.Parser.Lexer.Tokens: PIPE :: Token
- Language.Futhark.Parser.Lexer.Tokens: QUESTION_MARK :: Token
- Language.Futhark.Parser.Lexer.Tokens: RBRACKET :: Token
- Language.Futhark.Parser.Lexer.Tokens: RCURLY :: Token
- Language.Futhark.Parser.Lexer.Tokens: RIGHT_ARROW :: Token
- Language.Futhark.Parser.Lexer.Tokens: RPAR :: Token
- Language.Futhark.Parser.Lexer.Tokens: STRINGLIT :: Text -> Token
- Language.Futhark.Parser.Lexer.Tokens: SYMBOL :: BinOp -> [Name] -> Name -> Token
- Language.Futhark.Parser.Lexer.Tokens: THEN :: Token
- Language.Futhark.Parser.Lexer.Tokens: THREE_DOTS :: Token
- Language.Futhark.Parser.Lexer.Tokens: TILDE :: Token
- Language.Futhark.Parser.Lexer.Tokens: TRUE :: Token
- Language.Futhark.Parser.Lexer.Tokens: TWO_DOTS :: Token
- Language.Futhark.Parser.Lexer.Tokens: TWO_DOTS_GT :: Token
- Language.Futhark.Parser.Lexer.Tokens: TWO_DOTS_LT :: Token
- Language.Futhark.Parser.Lexer.Tokens: TYPE :: Token
- Language.Futhark.Parser.Lexer.Tokens: U16LIT :: Word16 -> Token
- Language.Futhark.Parser.Lexer.Tokens: U32LIT :: Word32 -> Token
- Language.Futhark.Parser.Lexer.Tokens: U64LIT :: Word64 -> Token
- Language.Futhark.Parser.Lexer.Tokens: U8LIT :: Word8 -> Token
- Language.Futhark.Parser.Lexer.Tokens: UNDERSCORE :: Token
- Language.Futhark.Parser.Lexer.Tokens: VAL :: Token
- Language.Futhark.Parser.Lexer.Tokens: WHILE :: Token
- Language.Futhark.Parser.Lexer.Tokens: WITH :: Token
- Language.Futhark.Parser.Lexer.Tokens: binToken :: Integral a => (a -> Token) -> ByteString -> Token
- Language.Futhark.Parser.Lexer.Tokens: data Token
- Language.Futhark.Parser.Lexer.Tokens: decToken :: Integral a => (a -> Token) -> ByteString -> Token
- Language.Futhark.Parser.Lexer.Tokens: fromRoman :: Integral a => Text -> a
- Language.Futhark.Parser.Lexer.Tokens: hexToken :: Integral a => (a -> Token) -> ByteString -> Token
- Language.Futhark.Parser.Lexer.Tokens: instance GHC.Classes.Eq Language.Futhark.Parser.Lexer.Tokens.Token
- Language.Futhark.Parser.Lexer.Tokens: instance GHC.Classes.Ord Language.Futhark.Parser.Lexer.Tokens.Token
- Language.Futhark.Parser.Lexer.Tokens: instance GHC.Show.Show Language.Futhark.Parser.Lexer.Tokens.Token
- Language.Futhark.Parser.Lexer.Tokens: mkQualId :: Text -> ([Name], Name)
- Language.Futhark.Parser.Lexer.Tokens: readHexRealLit :: RealFloat a => Text -> a
- Language.Futhark.Parser.Lexer.Tokens: romToken :: Integral a => (a -> Token) -> ByteString -> Token
- Language.Futhark.Parser.Lexer.Tokens: suffZero :: Text -> Text
- Language.Futhark.Parser.Lexer.Tokens: symbol :: [Name] -> Name -> Token
- Language.Futhark.Parser.Lexer.Tokens: tokenC :: a -> ByteString -> a
- Language.Futhark.Parser.Lexer.Tokens: tokenS :: (Text -> a) -> ByteString -> a
- Language.Futhark.Parser.Lexer.Tokens: tryRead :: Read a => String -> Text -> a
- Language.Futhark.Parser.Lexer.Wrapper: LexerError :: Loc -> Text -> LexerError
- Language.Futhark.Parser.Lexer.Wrapper: alexGetByte :: AlexInput -> Maybe (Byte, AlexInput)
- Language.Futhark.Parser.Lexer.Wrapper: alexGetPos :: AlexInput -> Pos
- Language.Futhark.Parser.Lexer.Wrapper: alexInputPrevChar :: AlexInput -> Char
- Language.Futhark.Parser.Lexer.Wrapper: data LexerError
- Language.Futhark.Parser.Lexer.Wrapper: initialLexerState :: Pos -> ByteString -> AlexInput
- Language.Futhark.Parser.Lexer.Wrapper: instance GHC.Show.Show Language.Futhark.Parser.Lexer.Wrapper.LexerError
- Language.Futhark.Parser.Lexer.Wrapper: type AlexInput = (Pos, Char, ByteString, Int64)
- Language.Futhark.Parser.Monad: Comment :: Loc -> Text -> Comment
- Language.Futhark.Parser.Monad: SyntaxError :: Loc -> Text -> SyntaxError
- Language.Futhark.Parser.Monad: [commentLoc] :: Comment -> Loc
- Language.Futhark.Parser.Monad: [commentText] :: Comment -> Text
- Language.Futhark.Parser.Monad: [syntaxErrorLoc] :: SyntaxError -> Loc
- Language.Futhark.Parser.Monad: [syntaxErrorMsg] :: SyntaxError -> Text
- Language.Futhark.Parser.Monad: addAttr :: AttrInfo Name -> UncheckedDec -> UncheckedDec
- Language.Futhark.Parser.Monad: addAttrSpec :: AttrInfo Name -> UncheckedSpec -> UncheckedSpec
- Language.Futhark.Parser.Monad: addDoc :: DocComment -> UncheckedDec -> UncheckedDec
- Language.Futhark.Parser.Monad: addDocSpec :: DocComment -> SpecBase (NoInfo :: Type -> Type) Name -> SpecBase (NoInfo :: Type -> Type) Name
- Language.Futhark.Parser.Monad: applyExp :: NonEmpty UncheckedExp -> ParserMonad UncheckedExp
- Language.Futhark.Parser.Monad: arrayFromList :: [a] -> Array Int a
- Language.Futhark.Parser.Monad: arrayLitExp :: [UncheckedExp] -> SrcLoc -> UncheckedExp
- Language.Futhark.Parser.Monad: backOneCol :: Loc -> Loc
- Language.Futhark.Parser.Monad: binOp :: UncheckedExp -> L Token -> UncheckedExp -> UncheckedExp
- Language.Futhark.Parser.Monad: binOpName :: L Token -> (QualName Name, Loc)
- Language.Futhark.Parser.Monad: data Comment
- Language.Futhark.Parser.Monad: data L a
- Language.Futhark.Parser.Monad: data ParserState
- Language.Futhark.Parser.Monad: data SyntaxError
- Language.Futhark.Parser.Monad: data Token
- Language.Futhark.Parser.Monad: emptyArrayError :: Loc -> ParserMonad a
- Language.Futhark.Parser.Monad: instance Data.Loc.Located Language.Futhark.Parser.Monad.Comment
- Language.Futhark.Parser.Monad: instance GHC.Classes.Eq Language.Futhark.Parser.Monad.Comment
- Language.Futhark.Parser.Monad: instance GHC.Classes.Ord Language.Futhark.Parser.Monad.Comment
- Language.Futhark.Parser.Monad: instance GHC.Show.Show Language.Futhark.Parser.Monad.Comment
- Language.Futhark.Parser.Monad: lexer :: (L Token -> ParserMonad a) -> ParserMonad a
- Language.Futhark.Parser.Monad: mustBe :: L Token -> Text -> ParserMonad ()
- Language.Futhark.Parser.Monad: mustBeEmpty :: Located loc => loc -> ValueType -> ParserMonad ()
- Language.Futhark.Parser.Monad: parse :: ParserMonad a -> FilePath -> Text -> Either SyntaxError a
- Language.Futhark.Parser.Monad: parseError :: (L Token, [String]) -> ParserMonad a
- Language.Futhark.Parser.Monad: parseErrorAt :: Located loc => loc -> Maybe Text -> ParserMonad a
- Language.Futhark.Parser.Monad: parseWithComments :: ParserMonad a -> FilePath -> Text -> Either SyntaxError (a, [Comment])
- Language.Futhark.Parser.Monad: primNegate :: PrimValue -> PrimValue
- Language.Futhark.Parser.Monad: twoDotsRange :: Loc -> ParserMonad a
- Language.Futhark.Parser.Monad: type ParserMonad = ExceptT SyntaxError State ParserState
- Language.Futhark.Prelude: prelude :: [(FilePath, Text)]
- Language.Futhark.Pretty: class Annot (f :: Type -> Type)
- Language.Futhark.Pretty: class Eq v => IsName v
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.AppExpBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.CaseBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.DecBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.DimIndexBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.ExpBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.FieldBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.LoopFormBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.LoopInitBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.ModBindBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.ModExpBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.ModParamBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.ModTypeBindBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.ModTypeExpBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.ProgBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.SpecBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.TypeBindBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.ValBindBase f vn)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Language.Futhark.Pretty.Annot f, Prettyprinter.Internal.Pretty t) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.PatBase f vn t)
- Language.Futhark.Pretty: instance (Language.Futhark.Pretty.IsName vn, Prettyprinter.Internal.Pretty d) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.TypeExp d vn)
- Language.Futhark.Pretty: instance (Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.Shape dim), Prettyprinter.Internal.Pretty u) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.RetTypeBase dim u)
- Language.Futhark.Pretty: instance (Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.Shape dim), Prettyprinter.Internal.Pretty u) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.ScalarTypeBase dim u)
- Language.Futhark.Pretty: instance (Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.Shape dim), Prettyprinter.Internal.Pretty u) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.TypeBase dim u)
- Language.Futhark.Pretty: instance (Prettyprinter.Internal.Pretty d, Language.Futhark.Pretty.IsName vn) => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.TypeArgExp d vn)
- Language.Futhark.Pretty: instance Language.Futhark.Pretty.Annot Language.Futhark.Syntax.Info
- Language.Futhark.Pretty: instance Language.Futhark.Pretty.Annot Language.Futhark.Syntax.NoInfo
- Language.Futhark.Pretty: instance Language.Futhark.Pretty.IsName Language.Futhark.Core.Name
- Language.Futhark.Pretty: instance Language.Futhark.Pretty.IsName Language.Futhark.Core.VName
- Language.Futhark.Pretty: instance Language.Futhark.Pretty.IsName vn => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.AttrAtom vn)
- Language.Futhark.Pretty: instance Language.Futhark.Pretty.IsName vn => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.AttrInfo vn)
- Language.Futhark.Pretty: instance Language.Futhark.Pretty.IsName vn => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.QualName vn)
- Language.Futhark.Pretty: instance Language.Futhark.Pretty.IsName vn => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.SizeBinder vn)
- Language.Futhark.Pretty: instance Language.Futhark.Pretty.IsName vn => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.TypeParamBase vn)
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.Shape ())
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.Shape GHC.Int.Int64)
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.Shape GHC.Types.Bool)
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.Shape Language.Futhark.Syntax.Size)
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.TypeArg Language.Futhark.Syntax.Size)
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty Language.Futhark.Syntax.Diet
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty Language.Futhark.Syntax.Liftedness
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty Language.Futhark.Syntax.PatLit
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty Language.Futhark.Syntax.PrimValue
- Language.Futhark.Pretty: instance Prettyprinter.Internal.Pretty d => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.SizeExp d)
- Language.Futhark.Pretty: instance forall k vn (f :: k -> *) (t :: k). Language.Futhark.Pretty.IsName vn => Prettyprinter.Internal.Pretty (Language.Futhark.Syntax.IdentBase f vn t)
- Language.Futhark.Pretty: leadingOperator :: Name -> BinOp
- Language.Futhark.Pretty: prettyName :: IsName v => v -> Doc a
- Language.Futhark.Pretty: prettyNameString :: IsName v => v -> String
- Language.Futhark.Pretty: prettyString :: Pretty a => a -> String
- Language.Futhark.Pretty: prettyTuple :: Pretty a => [a] -> Text
- Language.Futhark.Pretty: symbolName :: Name -> Bool
- Language.Futhark.Pretty: toName :: IsName v => v -> Name
- Language.Futhark.Pretty: unAnnot :: Annot f => f a -> Maybe a
- Language.Futhark.Primitive: AShr :: IntType -> BinOp
- Language.Futhark.Primitive: Abs :: IntType -> UnOp
- Language.Futhark.Primitive: Add :: IntType -> Overflow -> BinOp
- Language.Futhark.Primitive: And :: IntType -> BinOp
- Language.Futhark.Primitive: BToF :: FloatType -> ConvOp
- Language.Futhark.Primitive: BToI :: IntType -> ConvOp
- Language.Futhark.Primitive: Bool :: PrimType
- Language.Futhark.Primitive: BoolValue :: !Bool -> PrimValue
- Language.Futhark.Primitive: CmpEq :: PrimType -> CmpOp
- Language.Futhark.Primitive: CmpLle :: CmpOp
- Language.Futhark.Primitive: CmpLlt :: CmpOp
- Language.Futhark.Primitive: CmpSle :: IntType -> CmpOp
- Language.Futhark.Primitive: CmpSlt :: IntType -> CmpOp
- Language.Futhark.Primitive: CmpUle :: IntType -> CmpOp
- Language.Futhark.Primitive: CmpUlt :: IntType -> CmpOp
- Language.Futhark.Primitive: Complement :: IntType -> UnOp
- Language.Futhark.Primitive: FAbs :: FloatType -> UnOp
- Language.Futhark.Primitive: FAdd :: FloatType -> BinOp
- Language.Futhark.Primitive: FCmpLe :: FloatType -> CmpOp
- Language.Futhark.Primitive: FCmpLt :: FloatType -> CmpOp
- Language.Futhark.Primitive: FDiv :: FloatType -> BinOp
- Language.Futhark.Primitive: FMax :: FloatType -> BinOp
- Language.Futhark.Primitive: FMin :: FloatType -> BinOp
- Language.Futhark.Primitive: FMod :: FloatType -> BinOp
- Language.Futhark.Primitive: FMul :: FloatType -> BinOp
- Language.Futhark.Primitive: FPConv :: FloatType -> FloatType -> ConvOp
- Language.Futhark.Primitive: FPToSI :: FloatType -> IntType -> ConvOp
- Language.Futhark.Primitive: FPToUI :: FloatType -> IntType -> ConvOp
- Language.Futhark.Primitive: FPow :: FloatType -> BinOp
- Language.Futhark.Primitive: FSignum :: FloatType -> UnOp
- Language.Futhark.Primitive: FSub :: FloatType -> BinOp
- Language.Futhark.Primitive: FToB :: FloatType -> ConvOp
- Language.Futhark.Primitive: Float16 :: FloatType
- Language.Futhark.Primitive: Float16Value :: !Half -> FloatValue
- Language.Futhark.Primitive: Float32 :: FloatType
- Language.Futhark.Primitive: Float32Value :: !Float -> FloatValue
- Language.Futhark.Primitive: Float64 :: FloatType
- Language.Futhark.Primitive: Float64Value :: !Double -> FloatValue
- Language.Futhark.Primitive: FloatType :: FloatType -> PrimType
- Language.Futhark.Primitive: FloatValue :: !FloatValue -> PrimValue
- Language.Futhark.Primitive: IToB :: IntType -> ConvOp
- Language.Futhark.Primitive: Int16 :: IntType
- Language.Futhark.Primitive: Int16Value :: !Int16 -> IntValue
- Language.Futhark.Primitive: Int32 :: IntType
- Language.Futhark.Primitive: Int32Value :: !Int32 -> IntValue
- Language.Futhark.Primitive: Int64 :: IntType
- Language.Futhark.Primitive: Int64Value :: !Int64 -> IntValue
- Language.Futhark.Primitive: Int8 :: IntType
- Language.Futhark.Primitive: Int8Value :: !Int8 -> IntValue
- Language.Futhark.Primitive: IntType :: IntType -> PrimType
- Language.Futhark.Primitive: IntValue :: !IntValue -> PrimValue
- Language.Futhark.Primitive: LShr :: IntType -> BinOp
- Language.Futhark.Primitive: LogAnd :: BinOp
- Language.Futhark.Primitive: LogOr :: BinOp
- Language.Futhark.Primitive: Mul :: IntType -> Overflow -> BinOp
- Language.Futhark.Primitive: Neg :: PrimType -> UnOp
- Language.Futhark.Primitive: Or :: IntType -> BinOp
- Language.Futhark.Primitive: OverflowUndef :: Overflow
- Language.Futhark.Primitive: OverflowWrap :: Overflow
- Language.Futhark.Primitive: Pow :: IntType -> BinOp
- Language.Futhark.Primitive: SDiv :: IntType -> Safety -> BinOp
- Language.Futhark.Primitive: SDivUp :: IntType -> Safety -> BinOp
- Language.Futhark.Primitive: SExt :: IntType -> IntType -> ConvOp
- Language.Futhark.Primitive: SIToFP :: IntType -> FloatType -> ConvOp
- Language.Futhark.Primitive: SMax :: IntType -> BinOp
- Language.Futhark.Primitive: SMin :: IntType -> BinOp
- Language.Futhark.Primitive: SMod :: IntType -> Safety -> BinOp
- Language.Futhark.Primitive: SQuot :: IntType -> Safety -> BinOp
- Language.Futhark.Primitive: SRem :: IntType -> Safety -> BinOp
- Language.Futhark.Primitive: SSignum :: IntType -> UnOp
- Language.Futhark.Primitive: Safe :: Safety
- Language.Futhark.Primitive: Shl :: IntType -> BinOp
- Language.Futhark.Primitive: Sub :: IntType -> Overflow -> BinOp
- Language.Futhark.Primitive: UDiv :: IntType -> Safety -> BinOp
- Language.Futhark.Primitive: UDivUp :: IntType -> Safety -> BinOp
- Language.Futhark.Primitive: UIToFP :: IntType -> FloatType -> ConvOp
- Language.Futhark.Primitive: UMax :: IntType -> BinOp
- Language.Futhark.Primitive: UMin :: IntType -> BinOp
- Language.Futhark.Primitive: UMod :: IntType -> Safety -> BinOp
- Language.Futhark.Primitive: USignum :: IntType -> UnOp
- Language.Futhark.Primitive: Unit :: PrimType
- Language.Futhark.Primitive: UnitValue :: PrimValue
- Language.Futhark.Primitive: Unsafe :: Safety
- Language.Futhark.Primitive: Xor :: IntType -> BinOp
- Language.Futhark.Primitive: ZExt :: IntType -> IntType -> ConvOp
- Language.Futhark.Primitive: allBinOps :: [BinOp]
- Language.Futhark.Primitive: allCmpOps :: [CmpOp]
- Language.Futhark.Primitive: allConvOps :: [ConvOp]
- Language.Futhark.Primitive: allFloatTypes :: [FloatType]
- Language.Futhark.Primitive: allIntTypes :: [IntType]
- Language.Futhark.Primitive: allPrimTypes :: [PrimType]
- Language.Futhark.Primitive: allUnOps :: [UnOp]
- Language.Futhark.Primitive: associativeBinOp :: BinOp -> Bool
- Language.Futhark.Primitive: binOpType :: BinOp -> PrimType
- Language.Futhark.Primitive: blankPrimValue :: PrimType -> PrimValue
- Language.Futhark.Primitive: cmpOpType :: CmpOp -> PrimType
- Language.Futhark.Primitive: commutativeBinOp :: BinOp -> Bool
- Language.Futhark.Primitive: condFun :: PrimType -> Text
- Language.Futhark.Primitive: convOpFun :: ConvOp -> String
- Language.Futhark.Primitive: convOpType :: ConvOp -> (PrimType, PrimType)
- Language.Futhark.Primitive: data BinOp
- Language.Futhark.Primitive: data CmpOp
- Language.Futhark.Primitive: data ConvOp
- Language.Futhark.Primitive: data FloatType
- Language.Futhark.Primitive: data FloatValue
- Language.Futhark.Primitive: data Half
- Language.Futhark.Primitive: data Int16
- Language.Futhark.Primitive: data Int32
- Language.Futhark.Primitive: data Int64
- Language.Futhark.Primitive: data Int8
- Language.Futhark.Primitive: data IntType
- Language.Futhark.Primitive: data IntValue
- Language.Futhark.Primitive: data Overflow
- Language.Futhark.Primitive: data PrimType
- Language.Futhark.Primitive: data PrimValue
- Language.Futhark.Primitive: data Safety
- Language.Futhark.Primitive: data UnOp
- Language.Futhark.Primitive: data Word16
- Language.Futhark.Primitive: data Word32
- Language.Futhark.Primitive: data Word64
- Language.Futhark.Primitive: data Word8
- Language.Futhark.Primitive: doAbs :: IntValue -> IntValue
- Language.Futhark.Primitive: doAdd :: IntValue -> IntValue -> IntValue
- Language.Futhark.Primitive: doBinOp :: BinOp -> PrimValue -> PrimValue -> Maybe PrimValue
- Language.Futhark.Primitive: doCmpEq :: PrimValue -> PrimValue -> Bool
- Language.Futhark.Primitive: doCmpOp :: CmpOp -> PrimValue -> PrimValue -> Maybe Bool
- Language.Futhark.Primitive: doCmpSle :: IntValue -> IntValue -> Bool
- Language.Futhark.Primitive: doCmpSlt :: IntValue -> IntValue -> Bool
- Language.Futhark.Primitive: doCmpUle :: IntValue -> IntValue -> Bool
- Language.Futhark.Primitive: doCmpUlt :: IntValue -> IntValue -> Bool
- Language.Futhark.Primitive: doComplement :: IntValue -> IntValue
- Language.Futhark.Primitive: doConvOp :: ConvOp -> PrimValue -> Maybe PrimValue
- Language.Futhark.Primitive: doFAbs :: FloatValue -> FloatValue
- Language.Futhark.Primitive: doFCmpLe :: FloatValue -> FloatValue -> Bool
- Language.Futhark.Primitive: doFCmpLt :: FloatValue -> FloatValue -> Bool
- Language.Futhark.Primitive: doFPConv :: FloatValue -> FloatType -> FloatValue
- Language.Futhark.Primitive: doFPToSI :: FloatValue -> IntType -> IntValue
- Language.Futhark.Primitive: doFPToUI :: FloatValue -> IntType -> IntValue
- Language.Futhark.Primitive: doMul :: IntValue -> IntValue -> IntValue
- Language.Futhark.Primitive: doPow :: IntValue -> IntValue -> Maybe IntValue
- Language.Futhark.Primitive: doSDiv :: IntValue -> IntValue -> Maybe IntValue
- Language.Futhark.Primitive: doSExt :: IntValue -> IntType -> IntValue
- Language.Futhark.Primitive: doSIToFP :: IntValue -> FloatType -> FloatValue
- Language.Futhark.Primitive: doSMod :: IntValue -> IntValue -> Maybe IntValue
- Language.Futhark.Primitive: doSSignum :: IntValue -> IntValue
- Language.Futhark.Primitive: doUIToFP :: IntValue -> FloatType -> FloatValue
- Language.Futhark.Primitive: doUSignum :: IntValue -> IntValue
- Language.Futhark.Primitive: doUnOp :: UnOp -> PrimValue -> Maybe PrimValue
- Language.Futhark.Primitive: doZExt :: IntValue -> IntType -> IntValue
- Language.Futhark.Primitive: flipConvOp :: ConvOp -> ConvOp
- Language.Futhark.Primitive: floatByteSize :: Num a => FloatType -> a
- Language.Futhark.Primitive: floatValue :: Real num => FloatType -> num -> FloatValue
- Language.Futhark.Primitive: floatValueType :: FloatValue -> FloatType
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.BinOp
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.CmpOp
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.ConvOp
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.FloatType
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.FloatValue
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.IntType
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.IntValue
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.Overflow
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.PrimType
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.PrimValue
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.Safety
- Language.Futhark.Primitive: instance GHC.Classes.Eq Language.Futhark.Primitive.UnOp
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.BinOp
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.CmpOp
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.ConvOp
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.FloatType
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.FloatValue
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.IntType
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.IntValue
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.Overflow
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.PrimType
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.PrimValue
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.Safety
- Language.Futhark.Primitive: instance GHC.Classes.Ord Language.Futhark.Primitive.UnOp
- Language.Futhark.Primitive: instance GHC.Enum.Bounded Language.Futhark.Primitive.FloatType
- Language.Futhark.Primitive: instance GHC.Enum.Bounded Language.Futhark.Primitive.IntType
- Language.Futhark.Primitive: instance GHC.Enum.Bounded Language.Futhark.Primitive.PrimType
- Language.Futhark.Primitive: instance GHC.Enum.Enum Language.Futhark.Primitive.FloatType
- Language.Futhark.Primitive: instance GHC.Enum.Enum Language.Futhark.Primitive.IntType
- Language.Futhark.Primitive: instance GHC.Enum.Enum Language.Futhark.Primitive.PrimType
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.BinOp
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.CmpOp
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.ConvOp
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.FloatType
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.FloatValue
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.IntType
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.IntValue
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.Overflow
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.PrimType
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.PrimValue
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.Safety
- Language.Futhark.Primitive: instance GHC.Show.Show Language.Futhark.Primitive.UnOp
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.BinOp
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.CmpOp
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.ConvOp
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.FloatType
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.FloatValue
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.IntType
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.IntValue
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.PrimType
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.PrimValue
- Language.Futhark.Primitive: instance Prettyprinter.Internal.Pretty Language.Futhark.Primitive.UnOp
- Language.Futhark.Primitive: intByteSize :: Num a => IntType -> a
- Language.Futhark.Primitive: intToInt64 :: IntValue -> Int64
- Language.Futhark.Primitive: intToWord64 :: IntValue -> Word64
- Language.Futhark.Primitive: intValue :: Integral int => IntType -> int -> IntValue
- Language.Futhark.Primitive: intValueType :: IntValue -> IntType
- Language.Futhark.Primitive: isCondFun :: Text -> Maybe PrimType
- Language.Futhark.Primitive: negativeIsh :: PrimValue -> Bool
- Language.Futhark.Primitive: oneIsh :: PrimValue -> Bool
- Language.Futhark.Primitive: oneIshInt :: IntValue -> Bool
- Language.Futhark.Primitive: onePrimValue :: PrimType -> PrimValue
- Language.Futhark.Primitive: prettySigned :: Bool -> PrimType -> Text
- Language.Futhark.Primitive: primBitSize :: PrimType -> Int
- Language.Futhark.Primitive: primByteSize :: Num a => PrimType -> a
- Language.Futhark.Primitive: primFuns :: Map Text ([PrimType], PrimType, [PrimValue] -> Maybe PrimValue)
- Language.Futhark.Primitive: primValueType :: PrimValue -> PrimType
- Language.Futhark.Primitive: unOpType :: UnOp -> PrimType
- Language.Futhark.Primitive: valueIntegral :: Integral int => IntValue -> int
- Language.Futhark.Primitive: zeroIsh :: PrimValue -> Bool
- Language.Futhark.Primitive: zeroIshInt :: IntValue -> Bool
- Language.Futhark.Primitive.Parse: constituent :: Char -> Bool
- Language.Futhark.Primitive.Parse: keyword :: Text -> Parsec Void Text ()
- Language.Futhark.Primitive.Parse: lexeme :: Parsec Void Text a -> Parsec Void Text a
- Language.Futhark.Primitive.Parse: pFloatType :: Parsec Void Text FloatType
- Language.Futhark.Primitive.Parse: pIntType :: Parsec Void Text IntType
- Language.Futhark.Primitive.Parse: pPrimType :: Parsec Void Text PrimType
- Language.Futhark.Primitive.Parse: pPrimValue :: Parsec Void Text PrimValue
- Language.Futhark.Primitive.Parse: whitespace :: Parsec Void Text ()
- Language.Futhark.Prop: IntrinsicEquality :: Intrinsic
- Language.Futhark.Prop: IntrinsicMonoFun :: [PrimType] -> PrimType -> Intrinsic
- Language.Futhark.Prop: IntrinsicOverloadedFun :: [PrimType] -> [Maybe PrimType] -> Maybe PrimType -> Intrinsic
- Language.Futhark.Prop: IntrinsicPolyFun :: [TypeParamBase VName] -> [ParamType] -> RetTypeBase Size Uniqueness -> Intrinsic
- Language.Futhark.Prop: IntrinsicType :: Liftedness -> [TypeParamBase VName] -> StructType -> Intrinsic
- Language.Futhark.Prop: PosImmediate :: DimPos
- Language.Futhark.Prop: PosParam :: DimPos
- Language.Futhark.Prop: PosReturn :: DimPos
- Language.Futhark.Prop: anySize :: Size
- Language.Futhark.Prop: areTupleFields :: Map Name a -> Maybe [a]
- Language.Futhark.Prop: arrayOf :: Shape dim -> TypeBase dim NoUniqueness -> TypeBase dim NoUniqueness
- Language.Futhark.Prop: arrayOfWithAliases :: u -> Shape dim -> TypeBase dim u' -> TypeBase dim u
- Language.Futhark.Prop: arrayRank :: TypeBase d u -> Int
- Language.Futhark.Prop: arrayShape :: TypeBase dim as -> Shape dim
- Language.Futhark.Prop: data DimPos
- Language.Futhark.Prop: data Intrinsic
- Language.Futhark.Prop: decImports :: forall (f :: Type -> Type) vn. DecBase f vn -> [(String, Loc)]
- Language.Futhark.Prop: defaultEntryPoint :: Name
- Language.Futhark.Prop: diet :: TypeBase shape Diet -> Diet
- Language.Futhark.Prop: foldFunType :: [ParamType] -> ResRetType -> StructType
- Language.Futhark.Prop: funType :: [Pat ParamType] -> ResRetType -> StructType
- Language.Futhark.Prop: identifierReference :: String -> Maybe ((String, String, Maybe FilePath), String)
- Language.Futhark.Prop: instance GHC.Classes.Eq Language.Futhark.Prop.DimPos
- Language.Futhark.Prop: instance GHC.Classes.Ord Language.Futhark.Prop.DimPos
- Language.Futhark.Prop: instance GHC.Show.Show Language.Futhark.Prop.DimPos
- Language.Futhark.Prop: intrinsicVar :: Name -> VName
- Language.Futhark.Prop: intrinsics :: Map VName Intrinsic
- Language.Futhark.Prop: isAccType :: TypeBase d u -> Maybe (TypeBase d NoUniqueness)
- Language.Futhark.Prop: isBuiltin :: FilePath -> Bool
- Language.Futhark.Prop: isBuiltinLoc :: Located a => a -> Bool
- Language.Futhark.Prop: isSizeParam :: TypeParamBase vn -> Bool
- Language.Futhark.Prop: isTupleRecord :: TypeBase dim as -> Maybe [TypeBase dim as]
- Language.Futhark.Prop: isTypeParam :: TypeParamBase vn -> Bool
- Language.Futhark.Prop: leadingOperator :: Name -> BinOp
- Language.Futhark.Prop: matchDims :: (Monoid as, Monad m) => ([VName] -> d1 -> d2 -> m d1) -> TypeBase d1 as -> TypeBase d2 as -> m (TypeBase d1 as)
- Language.Futhark.Prop: maxIntrinsicTag :: Int
- Language.Futhark.Prop: namesToPrimTypes :: Map Name PrimType
- Language.Futhark.Prop: noSizes :: TypeBase Size as -> TypeBase () as
- Language.Futhark.Prop: orderZero :: TypeBase dim as -> Bool
- Language.Futhark.Prop: paramName :: PName -> Maybe VName
- Language.Futhark.Prop: paramToRes :: ParamType -> ResType
- Language.Futhark.Prop: patIdents :: forall (f :: Type -> Type) vn t. PatBase f vn t -> [IdentBase f vn t]
- Language.Futhark.Prop: patNames :: Pat t -> [VName]
- Language.Futhark.Prop: patternMap :: Pat t -> [(VName, t)]
- Language.Futhark.Prop: patternOrderZero :: Pat (TypeBase d u) -> Bool
- Language.Futhark.Prop: patternParam :: Pat ParamType -> (PName, Diet, StructType)
- Language.Futhark.Prop: patternStructType :: Pat (TypeBase Size u) -> StructType
- Language.Futhark.Prop: patternType :: Pat (TypeBase d u) -> TypeBase d u
- Language.Futhark.Prop: peelArray :: Int -> TypeBase dim u -> Maybe (TypeBase dim u)
- Language.Futhark.Prop: prettyStacktrace :: Int -> [Text] -> Text
- Language.Futhark.Prop: primValueType :: PrimValue -> PrimType
- Language.Futhark.Prop: progHoles :: ProgBase Info VName -> [(Loc, StructType)]
- Language.Futhark.Prop: progImports :: forall (f :: Type -> Type) vn. ProgBase f vn -> [(String, Loc)]
- Language.Futhark.Prop: progModuleTypes :: ProgBase Info VName -> Set VName
- Language.Futhark.Prop: qualName :: v -> QualName v
- Language.Futhark.Prop: qualify :: v -> QualName v -> QualName v
- Language.Futhark.Prop: resToParam :: ResType -> ParamType
- Language.Futhark.Prop: sameExp :: Exp -> Exp -> Bool
- Language.Futhark.Prop: setUniqueness :: TypeBase dim u1 -> u2 -> TypeBase dim u2
- Language.Futhark.Prop: similarExps :: Exp -> Exp -> Maybe [(Exp, Exp)]
- Language.Futhark.Prop: sortConstrs :: Map Name a -> [(Name, a)]
- Language.Futhark.Prop: sortFields :: Map Name a -> [(Name, a)]
- Language.Futhark.Prop: stripArray :: Int -> TypeBase dim as -> TypeBase dim as
- Language.Futhark.Prop: stripExp :: Exp -> Maybe Exp
- Language.Futhark.Prop: subExps :: Exp -> [Exp]
- Language.Futhark.Prop: toParam :: Diet -> TypeBase Size u -> ParamType
- Language.Futhark.Prop: toRes :: Uniqueness -> TypeBase Size u -> ResType
- Language.Futhark.Prop: toResRet :: Uniqueness -> RetTypeBase Size u -> ResRetType
- Language.Futhark.Prop: toStruct :: TypeBase dim u -> TypeBase dim NoUniqueness
- Language.Futhark.Prop: toStructural :: TypeBase dim as -> TypeBase () ()
- Language.Futhark.Prop: traverseDims :: Applicative f => (Set VName -> DimPos -> fdim -> f tdim) -> TypeBase fdim als -> f (TypeBase tdim als)
- Language.Futhark.Prop: tupleFieldNames :: [Name]
- Language.Futhark.Prop: tupleFields :: [a] -> Map Name a
- Language.Futhark.Prop: tupleRecord :: [TypeBase dim as] -> ScalarTypeBase dim as
- Language.Futhark.Prop: type AppExp = AppExpBase Info VName
- Language.Futhark.Prop: type Case = CaseBase Info VName
- Language.Futhark.Prop: type Dec = DecBase Info VName
- Language.Futhark.Prop: type DimIndex = DimIndexBase Info VName
- Language.Futhark.Prop: type Exp = ExpBase Info VName
- Language.Futhark.Prop: type Ident = IdentBase Info VName
- Language.Futhark.Prop: type ModBind = ModBindBase Info VName
- Language.Futhark.Prop: type ModExp = ModExpBase Info VName
- Language.Futhark.Prop: type ModParam = ModParamBase Info VName
- Language.Futhark.Prop: type ModTypeBind = ModTypeBindBase Info VName
- Language.Futhark.Prop: type ModTypeExp = ModTypeExpBase Info VName
- Language.Futhark.Prop: type Pat = PatBase Info VName
- Language.Futhark.Prop: type Prog = ProgBase Info VName
- Language.Futhark.Prop: type ScalarType = ScalarTypeBase ()
- Language.Futhark.Prop: type Slice = SliceBase Info VName
- Language.Futhark.Prop: type Spec = SpecBase Info VName
- Language.Futhark.Prop: type StructTypeArg = TypeArg Size
- Language.Futhark.Prop: type TypeBind = TypeBindBase Info VName
- Language.Futhark.Prop: type TypeParam = TypeParamBase VName
- Language.Futhark.Prop: type UncheckedCase = CaseBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedDec = DecBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedDimIndex = DimIndexBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedExp = ExpBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedIdent = IdentBase NoInfo :: k -> Type Name
- Language.Futhark.Prop: type UncheckedModBind = ModBindBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedModExp = ModExpBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedModTypeBind = ModTypeBindBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedModTypeExp = ModTypeExpBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedPat = PatBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedProg = ProgBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedSlice = SliceBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedSpec = SpecBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedType = TypeBase Shape Name ()
- Language.Futhark.Prop: type UncheckedTypeBind = TypeBindBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type UncheckedTypeExp = TypeExp UncheckedExp Name
- Language.Futhark.Prop: type UncheckedTypeParam = TypeParamBase Name
- Language.Futhark.Prop: type UncheckedValBind = ValBindBase NoInfo :: Type -> Type Name
- Language.Futhark.Prop: type ValBind = ValBindBase Info VName
- Language.Futhark.Prop: typeOf :: ExpBase Info VName -> StructType
- Language.Futhark.Prop: typeVars :: TypeBase dim as -> Set VName
- Language.Futhark.Prop: unfoldFunType :: TypeBase dim as -> ([TypeBase dim Diet], TypeBase dim NoUniqueness)
- Language.Futhark.Prop: unique :: TypeBase shape Uniqueness -> Bool
- Language.Futhark.Prop: uniqueness :: TypeBase shape Uniqueness -> Uniqueness
- Language.Futhark.Prop: valBindBound :: ValBindBase Info VName -> [VName]
- Language.Futhark.Prop: valBindTypeScheme :: ValBindBase Info VName -> ([TypeParamBase VName], StructType)
- Language.Futhark.Query: AtName :: QualName VName -> Maybe BoundTo -> Loc -> AtPos
- Language.Futhark.Query: BoundModule :: Loc -> BoundTo
- Language.Futhark.Query: BoundModuleType :: Loc -> BoundTo
- Language.Futhark.Query: BoundTerm :: StructType -> Loc -> BoundTo
- Language.Futhark.Query: BoundType :: Loc -> BoundTo
- Language.Futhark.Query: Pos :: !FilePath -> {-# UNPACK #-} !Int -> {-# UNPACK #-} !Int -> {-# UNPACK #-} !Int -> Pos
- Language.Futhark.Query: atPos :: Imports -> Pos -> Maybe AtPos
- Language.Futhark.Query: boundLoc :: BoundTo -> Loc
- Language.Futhark.Query: data AtPos
- Language.Futhark.Query: data BoundTo
- Language.Futhark.Query: data Pos
- Language.Futhark.Query: instance GHC.Classes.Eq Language.Futhark.Query.AtPos
- Language.Futhark.Query: instance GHC.Classes.Eq Language.Futhark.Query.BoundTo
- Language.Futhark.Query: instance GHC.Classes.Eq Language.Futhark.Query.Def
- Language.Futhark.Query: instance GHC.Show.Show Language.Futhark.Query.AtPos
- Language.Futhark.Query: instance GHC.Show.Show Language.Futhark.Query.BoundTo
- Language.Futhark.Query: instance GHC.Show.Show Language.Futhark.Query.Def
- Language.Futhark.Semantic: BoundV :: [TypeParam] -> StructType -> BoundV
- Language.Futhark.Semantic: Env :: Map VName BoundV -> Map VName TypeBinding -> Map VName MTy -> Map VName Mod -> NameMap -> Env
- Language.Futhark.Semantic: FileModule :: TySet -> Env -> Prog -> Env -> FileModule
- Language.Futhark.Semantic: FunModType :: TySet -> Mod -> MTy -> FunModType
- Language.Futhark.Semantic: MTy :: TySet -> Mod -> MTy
- Language.Futhark.Semantic: ModEnv :: Env -> Mod
- Language.Futhark.Semantic: ModFun :: FunModType -> Mod
- Language.Futhark.Semantic: Signature :: Namespace
- Language.Futhark.Semantic: Term :: Namespace
- Language.Futhark.Semantic: Type :: Namespace
- Language.Futhark.Semantic: TypeAbbr :: Liftedness -> [TypeParam] -> StructRetType -> TypeBinding
- Language.Futhark.Semantic: [boundValTParams] :: BoundV -> [TypeParam]
- Language.Futhark.Semantic: [boundValType] :: BoundV -> StructType
- Language.Futhark.Semantic: [envModTable] :: Env -> Map VName Mod
- Language.Futhark.Semantic: [envModTypeTable] :: Env -> Map VName MTy
- Language.Futhark.Semantic: [envNameMap] :: Env -> NameMap
- Language.Futhark.Semantic: [envTypeTable] :: Env -> Map VName TypeBinding
- Language.Futhark.Semantic: [envVtable] :: Env -> Map VName BoundV
- Language.Futhark.Semantic: [fileAbs] :: FileModule -> TySet
- Language.Futhark.Semantic: [fileEnv] :: FileModule -> Env
- Language.Futhark.Semantic: [fileProg] :: FileModule -> Prog
- Language.Futhark.Semantic: [fileScope] :: FileModule -> Env
- Language.Futhark.Semantic: [funModTypeAbs] :: FunModType -> TySet
- Language.Futhark.Semantic: [funModTypeMod] :: FunModType -> Mod
- Language.Futhark.Semantic: [funModTypeMty] :: FunModType -> MTy
- Language.Futhark.Semantic: [mtyAbs] :: MTy -> TySet
- Language.Futhark.Semantic: [mtyMod] :: MTy -> Mod
- Language.Futhark.Semantic: data BoundV
- Language.Futhark.Semantic: data Env
- Language.Futhark.Semantic: data FileModule
- Language.Futhark.Semantic: data FunModType
- Language.Futhark.Semantic: data ImportName
- Language.Futhark.Semantic: data MTy
- Language.Futhark.Semantic: data Mod
- Language.Futhark.Semantic: data Namespace
- Language.Futhark.Semantic: data TypeBinding
- Language.Futhark.Semantic: includeToFilePath :: ImportName -> FilePath
- Language.Futhark.Semantic: includeToString :: ImportName -> String
- Language.Futhark.Semantic: includeToText :: ImportName -> Text
- Language.Futhark.Semantic: instance GHC.Base.Monoid Language.Futhark.Semantic.Env
- Language.Futhark.Semantic: instance GHC.Base.Semigroup Language.Futhark.Semantic.Env
- Language.Futhark.Semantic: instance GHC.Classes.Eq Language.Futhark.Semantic.Namespace
- Language.Futhark.Semantic: instance GHC.Classes.Eq Language.Futhark.Semantic.TypeBinding
- Language.Futhark.Semantic: instance GHC.Classes.Ord Language.Futhark.Semantic.Namespace
- Language.Futhark.Semantic: instance GHC.Enum.Enum Language.Futhark.Semantic.Namespace
- Language.Futhark.Semantic: instance GHC.Show.Show Language.Futhark.Semantic.BoundV
- Language.Futhark.Semantic: instance GHC.Show.Show Language.Futhark.Semantic.Env
- Language.Futhark.Semantic: instance GHC.Show.Show Language.Futhark.Semantic.FunModType
- Language.Futhark.Semantic: instance GHC.Show.Show Language.Futhark.Semantic.MTy
- Language.Futhark.Semantic: instance GHC.Show.Show Language.Futhark.Semantic.Mod
- Language.Futhark.Semantic: instance GHC.Show.Show Language.Futhark.Semantic.Namespace
- Language.Futhark.Semantic: instance GHC.Show.Show Language.Futhark.Semantic.TypeBinding
- Language.Futhark.Semantic: instance Prettyprinter.Internal.Pretty Language.Futhark.Semantic.Env
- Language.Futhark.Semantic: instance Prettyprinter.Internal.Pretty Language.Futhark.Semantic.MTy
- Language.Futhark.Semantic: instance Prettyprinter.Internal.Pretty Language.Futhark.Semantic.Mod
- Language.Futhark.Semantic: instance Prettyprinter.Internal.Pretty Language.Futhark.Semantic.Namespace
- Language.Futhark.Semantic: mkImportFrom :: ImportName -> String -> ImportName
- Language.Futhark.Semantic: mkInitialImport :: FilePath -> ImportName
- Language.Futhark.Semantic: type Imports = [(ImportName, FileModule)]
- Language.Futhark.Semantic: type NameMap = Map (Namespace, Name) QualName VName
- Language.Futhark.Semantic: type TySet = Map QualName VName Liftedness
- Language.Futhark.Syntax: AppExp :: AppExpBase f vn -> f AppRes -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: AppRes :: StructType -> [VName] -> AppRes
- Language.Futhark.Syntax: Apply :: ExpBase f vn -> NonEmpty (f (Maybe VName), ExpBase f vn) -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Array :: u -> Shape dim -> ScalarTypeBase dim NoUniqueness -> TypeBase dim u
- Language.Futhark.Syntax: ArrayLit :: [ExpBase f vn] -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ArrayVal :: [PrimValue] -> PrimType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Arrow :: u -> PName -> Diet -> TypeBase dim NoUniqueness -> RetTypeBase dim Uniqueness -> ScalarTypeBase dim u
- Language.Futhark.Syntax: Ascript :: ExpBase f vn -> TypeExp (ExpBase f vn) vn -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Assert :: ExpBase f vn -> ExpBase f vn -> f Text -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: AtomInt :: Integer -> AttrAtom (vn :: k)
- Language.Futhark.Syntax: AtomName :: Name -> AttrAtom (vn :: k)
- Language.Futhark.Syntax: Attr :: AttrInfo vn -> ExpBase f vn -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: AttrAtom :: AttrAtom vn -> SrcLoc -> AttrInfo (vn :: k)
- Language.Futhark.Syntax: AttrComp :: Name -> [AttrInfo vn] -> SrcLoc -> AttrInfo (vn :: k)
- Language.Futhark.Syntax: Backtick :: BinOp
- Language.Futhark.Syntax: Band :: BinOp
- Language.Futhark.Syntax: Bang :: BinOp
- Language.Futhark.Syntax: BinOp :: (QualName vn, SrcLoc) -> f StructType -> (ExpBase f vn, f (Maybe VName)) -> (ExpBase f vn, f (Maybe VName)) -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Bool :: PrimType
- Language.Futhark.Syntax: BoolValue :: !Bool -> PrimValue
- Language.Futhark.Syntax: Bor :: BinOp
- Language.Futhark.Syntax: CasePat :: PatBase f vn StructType -> ExpBase f vn -> SrcLoc -> CaseBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Coerce :: ExpBase f vn -> TypeExp (ExpBase f vn) vn -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Constr :: Name -> [ExpBase f vn] -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Consume :: Diet
- Language.Futhark.Syntax: DimFix :: ExpBase f vn -> DimIndexBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: DimSlice :: Maybe (ExpBase f vn) -> Maybe (ExpBase f vn) -> Maybe (ExpBase f vn) -> DimIndexBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Divide :: BinOp
- Language.Futhark.Syntax: DocComment :: Text -> SrcLoc -> DocComment
- Language.Futhark.Syntax: DownToExclusive :: a -> Inclusiveness a
- Language.Futhark.Syntax: EntryParam :: Name -> EntryType -> EntryParam
- Language.Futhark.Syntax: EntryPoint :: [EntryParam] -> EntryType -> EntryPoint
- Language.Futhark.Syntax: EntryType :: StructType -> Maybe (TypeExp (ExpBase Info VName) VName) -> EntryType
- Language.Futhark.Syntax: Equ :: BinOp
- Language.Futhark.Syntax: Equal :: BinOp
- Language.Futhark.Syntax: Float16 :: FloatType
- Language.Futhark.Syntax: Float16Value :: !Half -> FloatValue
- Language.Futhark.Syntax: Float32 :: FloatType
- Language.Futhark.Syntax: Float32Value :: !Float -> FloatValue
- Language.Futhark.Syntax: Float64 :: FloatType
- Language.Futhark.Syntax: Float64Value :: !Double -> FloatValue
- Language.Futhark.Syntax: FloatLit :: Double -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: FloatType :: FloatType -> PrimType
- Language.Futhark.Syntax: FloatValue :: !FloatValue -> PrimValue
- Language.Futhark.Syntax: For :: IdentBase f vn StructType -> ExpBase f vn -> LoopFormBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ForIn :: PatBase f vn StructType -> ExpBase f vn -> LoopFormBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Geq :: BinOp
- Language.Futhark.Syntax: Greater :: BinOp
- Language.Futhark.Syntax: Hole :: f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Id :: vn -> f t -> SrcLoc -> PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: Ident :: vn -> f t -> SrcLoc -> IdentBase (f :: k -> Type) vn (t :: k)
- Language.Futhark.Syntax: If :: ExpBase f vn -> ExpBase f vn -> ExpBase f vn -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ImportDec :: FilePath -> f ImportName -> SrcLoc -> DecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ImportName :: FilePath -> ImportName
- Language.Futhark.Syntax: IncludeSpec :: ModTypeExpBase f vn -> SrcLoc -> SpecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Index :: ExpBase f vn -> SliceBase f vn -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: IndexSection :: SliceBase f vn -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Info :: a -> Info a
- Language.Futhark.Syntax: Int16 :: IntType
- Language.Futhark.Syntax: Int16Value :: !Int16 -> IntValue
- Language.Futhark.Syntax: Int32 :: IntType
- Language.Futhark.Syntax: Int32Value :: !Int32 -> IntValue
- Language.Futhark.Syntax: Int64 :: IntType
- Language.Futhark.Syntax: Int64Value :: !Int64 -> IntValue
- Language.Futhark.Syntax: Int8 :: IntType
- Language.Futhark.Syntax: Int8Value :: !Int8 -> IntValue
- Language.Futhark.Syntax: IntLit :: Integer -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: L :: Loc -> a -> L a
- Language.Futhark.Syntax: Lambda :: [PatBase f vn ParamType] -> ExpBase f vn -> Maybe (TypeExp (ExpBase f vn) vn) -> f ResRetType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Leq :: BinOp
- Language.Futhark.Syntax: Less :: BinOp
- Language.Futhark.Syntax: LetFun :: vn -> ([TypeParamBase vn], [PatBase f vn ParamType], Maybe (TypeExp (ExpBase f vn) vn), f ResRetType, ExpBase f vn) -> ExpBase f vn -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: LetPat :: [SizeBinder vn] -> PatBase f vn StructType -> ExpBase f vn -> ExpBase f vn -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: LetWith :: IdentBase f vn StructType -> IdentBase f vn StructType -> SliceBase f vn -> ExpBase f vn -> ExpBase f vn -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Lifted :: Liftedness
- Language.Futhark.Syntax: Literal :: PrimValue -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: LocalDec :: DecBase f vn -> SrcLoc -> DecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: LogAnd :: BinOp
- Language.Futhark.Syntax: LogOr :: BinOp
- Language.Futhark.Syntax: Loop :: [VName] -> PatBase f vn ParamType -> LoopInitBase f vn -> LoopFormBase f vn -> ExpBase f vn -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: LoopInitExplicit :: ExpBase f vn -> LoopInitBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: LoopInitImplicit :: f (ExpBase f vn) -> LoopInitBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Match :: ExpBase f vn -> NonEmpty (CaseBase f vn) -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Minus :: BinOp
- Language.Futhark.Syntax: Mod :: BinOp
- Language.Futhark.Syntax: ModApply :: ModExpBase f vn -> ModExpBase f vn -> f (Map VName VName) -> f (Map VName VName) -> SrcLoc -> ModExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModAscript :: ModExpBase f vn -> ModTypeExpBase f vn -> f (Map VName VName) -> SrcLoc -> ModExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModBind :: vn -> [ModParamBase f vn] -> Maybe (ModTypeExpBase f vn, f (Map VName VName)) -> ModExpBase f vn -> Maybe DocComment -> SrcLoc -> ModBindBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModDec :: ModBindBase f vn -> DecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModDecs :: [DecBase f vn] -> SrcLoc -> ModExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModImport :: FilePath -> f ImportName -> SrcLoc -> ModExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModLambda :: ModParamBase f vn -> Maybe (ModTypeExpBase f vn, f (Map VName VName)) -> ModExpBase f vn -> SrcLoc -> ModExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModParam :: vn -> ModTypeExpBase f vn -> f [VName] -> SrcLoc -> ModParamBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModParens :: ModExpBase f vn -> SrcLoc -> ModExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModSpec :: vn -> ModTypeExpBase f vn -> Maybe DocComment -> SrcLoc -> SpecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModTypeArrow :: Maybe vn -> ModTypeExpBase f vn -> ModTypeExpBase f vn -> SrcLoc -> ModTypeExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModTypeBind :: vn -> ModTypeExpBase f vn -> Maybe DocComment -> SrcLoc -> ModTypeBindBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModTypeDec :: ModTypeBindBase f vn -> DecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModTypeParens :: ModTypeExpBase f vn -> SrcLoc -> ModTypeExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModTypeSpecs :: [SpecBase f vn] -> SrcLoc -> ModTypeExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModTypeVar :: QualName vn -> f (Map VName VName) -> SrcLoc -> ModTypeExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModTypeWith :: ModTypeExpBase f vn -> TypeRefBase f vn -> SrcLoc -> ModTypeExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ModVar :: QualName vn -> SrcLoc -> ModExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Named :: VName -> PName
- Language.Futhark.Syntax: Negate :: ExpBase f vn -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: NoInfo :: NoInfo (a :: k)
- Language.Futhark.Syntax: Nonunique :: Uniqueness
- Language.Futhark.Syntax: Not :: ExpBase f vn -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: NotEqual :: BinOp
- Language.Futhark.Syntax: Observe :: Diet
- Language.Futhark.Syntax: OpSection :: QualName vn -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: OpSectionLeft :: QualName vn -> f StructType -> ExpBase f vn -> (f (PName, ParamType, Maybe VName), f (PName, ParamType)) -> (f ResRetType, f [VName]) -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: OpSectionRight :: QualName vn -> f StructType -> ExpBase f vn -> (f (PName, ParamType), f (PName, ParamType, Maybe VName)) -> f ResRetType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: OpenDec :: ModExpBase f vn -> SrcLoc -> DecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Parens :: ExpBase f vn -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: PatAscription :: PatBase f vn t -> TypeExp (ExpBase f vn) vn -> SrcLoc -> PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: PatAttr :: AttrInfo vn -> PatBase f vn t -> SrcLoc -> PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: PatConstr :: Name -> f t -> [PatBase f vn t] -> SrcLoc -> PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: PatLit :: PatLit -> f t -> SrcLoc -> PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: PatLitFloat :: Double -> PatLit
- Language.Futhark.Syntax: PatLitInt :: Integer -> PatLit
- Language.Futhark.Syntax: PatLitPrim :: PrimValue -> PatLit
- Language.Futhark.Syntax: PatParens :: PatBase f vn t -> SrcLoc -> PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: PipeLeft :: BinOp
- Language.Futhark.Syntax: PipeRight :: BinOp
- Language.Futhark.Syntax: Plus :: BinOp
- Language.Futhark.Syntax: Pow :: BinOp
- Language.Futhark.Syntax: Prim :: PrimType -> ScalarTypeBase dim u
- Language.Futhark.Syntax: Prog :: Maybe DocComment -> [DecBase f vn] -> ProgBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Project :: Name -> ExpBase f vn -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ProjectSection :: [Name] -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: QualName :: ![vn] -> !vn -> QualName vn
- Language.Futhark.Syntax: QualParens :: (QualName vn, SrcLoc) -> ExpBase f vn -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Quot :: BinOp
- Language.Futhark.Syntax: Range :: ExpBase f vn -> Maybe (ExpBase f vn) -> Inclusiveness (ExpBase f vn) -> SrcLoc -> AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Record :: Map Name (TypeBase dim u) -> ScalarTypeBase dim u
- Language.Futhark.Syntax: RecordFieldExplicit :: L Name -> ExpBase f vn -> SrcLoc -> FieldBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: RecordFieldImplicit :: L vn -> f StructType -> SrcLoc -> FieldBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: RecordLit :: [FieldBase f vn] -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: RecordPat :: [(L Name, PatBase f vn t)] -> SrcLoc -> PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: RecordUpdate :: ExpBase f vn -> [Name] -> ExpBase f vn -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Rem :: BinOp
- Language.Futhark.Syntax: RetType :: [VName] -> TypeBase dim as -> RetTypeBase dim as
- Language.Futhark.Syntax: Scalar :: ScalarTypeBase dim u -> TypeBase dim u
- Language.Futhark.Syntax: Shape :: [dim] -> Shape dim
- Language.Futhark.Syntax: ShiftL :: BinOp
- Language.Futhark.Syntax: ShiftR :: BinOp
- Language.Futhark.Syntax: Signed :: IntType -> PrimType
- Language.Futhark.Syntax: SignedValue :: !IntValue -> PrimValue
- Language.Futhark.Syntax: SizeBinder :: !vn -> !SrcLoc -> SizeBinder vn
- Language.Futhark.Syntax: SizeExp :: d -> SrcLoc -> SizeExp d
- Language.Futhark.Syntax: SizeExpAny :: SrcLoc -> SizeExp d
- Language.Futhark.Syntax: SizeLifted :: Liftedness
- Language.Futhark.Syntax: StringLit :: [Word8] -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Sum :: Map Name [TypeBase dim u] -> ScalarTypeBase dim u
- Language.Futhark.Syntax: TEApply :: TypeExp d vn -> TypeArgExp d vn -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: TEArray :: SizeExp d -> TypeExp d vn -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: TEArrow :: Maybe vn -> TypeExp d vn -> TypeExp d vn -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: TEDim :: [vn] -> TypeExp d vn -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: TEParens :: TypeExp d vn -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: TERecord :: [(L Name, TypeExp d vn)] -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: TESum :: [(Name, [TypeExp d vn])] -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: TETuple :: [TypeExp d vn] -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: TEUnique :: TypeExp d vn -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: TEVar :: QualName vn -> SrcLoc -> TypeExp d vn
- Language.Futhark.Syntax: Times :: BinOp
- Language.Futhark.Syntax: ToInclusive :: a -> Inclusiveness a
- Language.Futhark.Syntax: TupLit :: [ExpBase f vn] -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: TuplePat :: [PatBase f vn t] -> SrcLoc -> PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: TypeAbbrSpec :: TypeBindBase f vn -> SpecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: TypeArgDim :: dim -> TypeArg dim
- Language.Futhark.Syntax: TypeArgExpSize :: SizeExp d -> TypeArgExp d vn
- Language.Futhark.Syntax: TypeArgExpType :: TypeExp d vn -> TypeArgExp d vn
- Language.Futhark.Syntax: TypeArgType :: TypeBase dim NoUniqueness -> TypeArg dim
- Language.Futhark.Syntax: TypeBind :: vn -> Liftedness -> [TypeParamBase vn] -> TypeExp (ExpBase f vn) vn -> f StructRetType -> Maybe DocComment -> SrcLoc -> TypeBindBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: TypeDec :: TypeBindBase f vn -> DecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: TypeParamDim :: vn -> SrcLoc -> TypeParamBase vn
- Language.Futhark.Syntax: TypeParamType :: Liftedness -> vn -> SrcLoc -> TypeParamBase vn
- Language.Futhark.Syntax: TypeRef :: QualName vn -> [TypeParamBase vn] -> TypeExp (ExpBase f vn) vn -> SrcLoc -> TypeRefBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: TypeSpec :: Liftedness -> vn -> [TypeParamBase vn] -> Maybe DocComment -> SrcLoc -> SpecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: TypeVar :: u -> QualName VName -> [TypeArg dim] -> ScalarTypeBase dim u
- Language.Futhark.Syntax: Unique :: Uniqueness
- Language.Futhark.Syntax: Unlifted :: Liftedness
- Language.Futhark.Syntax: Unnamed :: PName
- Language.Futhark.Syntax: Unsigned :: IntType -> PrimType
- Language.Futhark.Syntax: UnsignedValue :: !IntValue -> PrimValue
- Language.Futhark.Syntax: UpToExclusive :: a -> Inclusiveness a
- Language.Futhark.Syntax: Update :: ExpBase f vn -> SliceBase f vn -> ExpBase f vn -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ValBind :: Maybe (f EntryPoint) -> vn -> Maybe (TypeExp (ExpBase f vn) vn) -> f ResRetType -> [TypeParamBase vn] -> [PatBase f vn ParamType] -> ExpBase f vn -> Maybe DocComment -> [AttrInfo vn] -> SrcLoc -> ValBindBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ValDec :: ValBindBase f vn -> DecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: ValSpec :: vn -> [TypeParamBase vn] -> TypeExp (ExpBase f vn) vn -> f StructType -> Maybe DocComment -> SrcLoc -> SpecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Var :: QualName vn -> f StructType -> SrcLoc -> ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: While :: ExpBase f vn -> LoopFormBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: Wildcard :: f t -> SrcLoc -> PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: Xor :: BinOp
- Language.Futhark.Syntax: [appResExt] :: AppRes -> [VName]
- Language.Futhark.Syntax: [appResType] :: AppRes -> StructType
- Language.Futhark.Syntax: [entryAscribed] :: EntryType -> Maybe (TypeExp (ExpBase Info VName) VName)
- Language.Futhark.Syntax: [entryParamName] :: EntryParam -> Name
- Language.Futhark.Syntax: [entryParamType] :: EntryParam -> EntryType
- Language.Futhark.Syntax: [entryParams] :: EntryPoint -> [EntryParam]
- Language.Futhark.Syntax: [entryReturn] :: EntryPoint -> EntryType
- Language.Futhark.Syntax: [entryType] :: EntryType -> StructType
- Language.Futhark.Syntax: [identName] :: IdentBase (f :: k -> Type) vn (t :: k) -> vn
- Language.Futhark.Syntax: [identSrcLoc] :: IdentBase (f :: k -> Type) vn (t :: k) -> SrcLoc
- Language.Futhark.Syntax: [identType] :: IdentBase (f :: k -> Type) vn (t :: k) -> f t
- Language.Futhark.Syntax: [modDoc] :: ModBindBase (f :: Type -> Type) vn -> Maybe DocComment
- Language.Futhark.Syntax: [modExp] :: ModBindBase (f :: Type -> Type) vn -> ModExpBase f vn
- Language.Futhark.Syntax: [modLocation] :: ModBindBase (f :: Type -> Type) vn -> SrcLoc
- Language.Futhark.Syntax: [modName] :: ModBindBase (f :: Type -> Type) vn -> vn
- Language.Futhark.Syntax: [modParamAbs] :: ModParamBase (f :: Type -> Type) vn -> f [VName]
- Language.Futhark.Syntax: [modParamLocation] :: ModParamBase (f :: Type -> Type) vn -> SrcLoc
- Language.Futhark.Syntax: [modParamName] :: ModParamBase (f :: Type -> Type) vn -> vn
- Language.Futhark.Syntax: [modParamType] :: ModParamBase (f :: Type -> Type) vn -> ModTypeExpBase f vn
- Language.Futhark.Syntax: [modParams] :: ModBindBase (f :: Type -> Type) vn -> [ModParamBase f vn]
- Language.Futhark.Syntax: [modTypeDoc] :: ModTypeBindBase (f :: Type -> Type) vn -> Maybe DocComment
- Language.Futhark.Syntax: [modTypeExp] :: ModTypeBindBase (f :: Type -> Type) vn -> ModTypeExpBase f vn
- Language.Futhark.Syntax: [modTypeLoc] :: ModTypeBindBase (f :: Type -> Type) vn -> SrcLoc
- Language.Futhark.Syntax: [modTypeName] :: ModTypeBindBase (f :: Type -> Type) vn -> vn
- Language.Futhark.Syntax: [modType] :: ModBindBase (f :: Type -> Type) vn -> Maybe (ModTypeExpBase f vn, f (Map VName VName))
- Language.Futhark.Syntax: [progDecs] :: ProgBase (f :: Type -> Type) vn -> [DecBase f vn]
- Language.Futhark.Syntax: [progDoc] :: ProgBase (f :: Type -> Type) vn -> Maybe DocComment
- Language.Futhark.Syntax: [qualLeaf] :: QualName vn -> !vn
- Language.Futhark.Syntax: [qualQuals] :: QualName vn -> ![vn]
- Language.Futhark.Syntax: [retDims] :: RetTypeBase dim as -> [VName]
- Language.Futhark.Syntax: [retType] :: RetTypeBase dim as -> TypeBase dim as
- Language.Futhark.Syntax: [shapeDims] :: Shape dim -> [dim]
- Language.Futhark.Syntax: [sizeLoc] :: SizeBinder vn -> !SrcLoc
- Language.Futhark.Syntax: [sizeName] :: SizeBinder vn -> !vn
- Language.Futhark.Syntax: [specDoc] :: SpecBase (f :: Type -> Type) vn -> Maybe DocComment
- Language.Futhark.Syntax: [specLocation] :: SpecBase (f :: Type -> Type) vn -> SrcLoc
- Language.Futhark.Syntax: [specName] :: SpecBase (f :: Type -> Type) vn -> vn
- Language.Futhark.Syntax: [specTypeExp] :: SpecBase (f :: Type -> Type) vn -> TypeExp (ExpBase f vn) vn
- Language.Futhark.Syntax: [specTypeParams] :: SpecBase (f :: Type -> Type) vn -> [TypeParamBase vn]
- Language.Futhark.Syntax: [specType] :: SpecBase (f :: Type -> Type) vn -> f StructType
- Language.Futhark.Syntax: [typeAlias] :: TypeBindBase (f :: Type -> Type) vn -> vn
- Language.Futhark.Syntax: [typeBindLocation] :: TypeBindBase (f :: Type -> Type) vn -> SrcLoc
- Language.Futhark.Syntax: [typeDoc] :: TypeBindBase (f :: Type -> Type) vn -> Maybe DocComment
- Language.Futhark.Syntax: [typeElab] :: TypeBindBase (f :: Type -> Type) vn -> f StructRetType
- Language.Futhark.Syntax: [typeExp] :: TypeBindBase (f :: Type -> Type) vn -> TypeExp (ExpBase f vn) vn
- Language.Futhark.Syntax: [typeLiftedness] :: TypeBindBase (f :: Type -> Type) vn -> Liftedness
- Language.Futhark.Syntax: [typeParams] :: TypeBindBase (f :: Type -> Type) vn -> [TypeParamBase vn]
- Language.Futhark.Syntax: [unInfo] :: Info a -> a
- Language.Futhark.Syntax: [valBindAttrs] :: ValBindBase (f :: Type -> Type) vn -> [AttrInfo vn]
- Language.Futhark.Syntax: [valBindBody] :: ValBindBase (f :: Type -> Type) vn -> ExpBase f vn
- Language.Futhark.Syntax: [valBindDoc] :: ValBindBase (f :: Type -> Type) vn -> Maybe DocComment
- Language.Futhark.Syntax: [valBindEntryPoint] :: ValBindBase (f :: Type -> Type) vn -> Maybe (f EntryPoint)
- Language.Futhark.Syntax: [valBindLocation] :: ValBindBase (f :: Type -> Type) vn -> SrcLoc
- Language.Futhark.Syntax: [valBindName] :: ValBindBase (f :: Type -> Type) vn -> vn
- Language.Futhark.Syntax: [valBindParams] :: ValBindBase (f :: Type -> Type) vn -> [PatBase f vn ParamType]
- Language.Futhark.Syntax: [valBindRetDecl] :: ValBindBase (f :: Type -> Type) vn -> Maybe (TypeExp (ExpBase f vn) vn)
- Language.Futhark.Syntax: [valBindRetType] :: ValBindBase (f :: Type -> Type) vn -> f ResRetType
- Language.Futhark.Syntax: [valBindTypeParams] :: ValBindBase (f :: Type -> Type) vn -> [TypeParamBase vn]
- Language.Futhark.Syntax: class IsPrimValue v
- Language.Futhark.Syntax: data AppExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data AppRes
- Language.Futhark.Syntax: data AttrAtom (vn :: k)
- Language.Futhark.Syntax: data AttrInfo (vn :: k)
- Language.Futhark.Syntax: data BinOp
- Language.Futhark.Syntax: data CaseBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data DecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data Diet
- Language.Futhark.Syntax: data DimIndexBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data DocComment
- Language.Futhark.Syntax: data EntryParam
- Language.Futhark.Syntax: data EntryPoint
- Language.Futhark.Syntax: data EntryType
- Language.Futhark.Syntax: data ExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data FieldBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data FloatType
- Language.Futhark.Syntax: data FloatValue
- Language.Futhark.Syntax: data IdentBase (f :: k -> Type) vn (t :: k)
- Language.Futhark.Syntax: data Inclusiveness a
- Language.Futhark.Syntax: data IntType
- Language.Futhark.Syntax: data IntValue
- Language.Futhark.Syntax: data L a
- Language.Futhark.Syntax: data Liftedness
- Language.Futhark.Syntax: data LoopFormBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data LoopInitBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data ModBindBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data ModExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data ModParamBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data ModTypeBindBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data ModTypeExpBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data NoInfo (a :: k)
- Language.Futhark.Syntax: data PName
- Language.Futhark.Syntax: data PatBase (f :: Type -> Type) vn t
- Language.Futhark.Syntax: data PatLit
- Language.Futhark.Syntax: data PrimType
- Language.Futhark.Syntax: data PrimValue
- Language.Futhark.Syntax: data ProgBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data QualName vn
- Language.Futhark.Syntax: data RetTypeBase dim as
- Language.Futhark.Syntax: data ScalarTypeBase dim u
- Language.Futhark.Syntax: data SizeBinder vn
- Language.Futhark.Syntax: data SizeExp d
- Language.Futhark.Syntax: data SpecBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data TypeArg dim
- Language.Futhark.Syntax: data TypeArgExp d vn
- Language.Futhark.Syntax: data TypeBase dim u
- Language.Futhark.Syntax: data TypeBindBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data TypeExp d vn
- Language.Futhark.Syntax: data TypeParamBase vn
- Language.Futhark.Syntax: data TypeRefBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: data Uniqueness
- Language.Futhark.Syntax: data ValBindBase (f :: Type -> Type) vn
- Language.Futhark.Syntax: instance (GHC.Classes.Eq as, GHC.Classes.Eq dim) => GHC.Classes.Eq (Language.Futhark.Syntax.RetTypeBase dim as)
- Language.Futhark.Syntax: instance (GHC.Classes.Eq d, GHC.Classes.Eq vn) => GHC.Classes.Eq (Language.Futhark.Syntax.TypeArgExp d vn)
- Language.Futhark.Syntax: instance (GHC.Classes.Eq dim, GHC.Classes.Eq u) => GHC.Classes.Eq (Language.Futhark.Syntax.ScalarTypeBase dim u)
- Language.Futhark.Syntax: instance (GHC.Classes.Eq dim, GHC.Classes.Eq u) => GHC.Classes.Eq (Language.Futhark.Syntax.TypeBase dim u)
- Language.Futhark.Syntax: instance (GHC.Classes.Eq vn, GHC.Classes.Eq d) => GHC.Classes.Eq (Language.Futhark.Syntax.TypeExp d vn)
- Language.Futhark.Syntax: instance (GHC.Classes.Ord as, GHC.Classes.Ord dim) => GHC.Classes.Ord (Language.Futhark.Syntax.RetTypeBase dim as)
- Language.Futhark.Syntax: instance (GHC.Classes.Ord d, GHC.Classes.Ord vn) => GHC.Classes.Ord (Language.Futhark.Syntax.TypeArgExp d vn)
- Language.Futhark.Syntax: instance (GHC.Classes.Ord dim, GHC.Classes.Ord u) => GHC.Classes.Ord (Language.Futhark.Syntax.ScalarTypeBase dim u)
- Language.Futhark.Syntax: instance (GHC.Classes.Ord dim, GHC.Classes.Ord u) => GHC.Classes.Ord (Language.Futhark.Syntax.TypeBase dim u)
- Language.Futhark.Syntax: instance (GHC.Classes.Ord vn, GHC.Classes.Ord d) => GHC.Classes.Ord (Language.Futhark.Syntax.TypeExp d vn)
- Language.Futhark.Syntax: instance (GHC.Show.Show (Language.Futhark.Syntax.Info t), GHC.Show.Show vn) => GHC.Show.Show (Language.Futhark.Syntax.IdentBase Language.Futhark.Syntax.NoInfo vn t)
- Language.Futhark.Syntax: instance (GHC.Show.Show (Language.Futhark.Syntax.NoInfo t), GHC.Show.Show vn) => GHC.Show.Show (Language.Futhark.Syntax.PatBase Language.Futhark.Syntax.NoInfo vn t)
- Language.Futhark.Syntax: instance (GHC.Show.Show as, GHC.Show.Show dim) => GHC.Show.Show (Language.Futhark.Syntax.RetTypeBase dim as)
- Language.Futhark.Syntax: instance (GHC.Show.Show d, GHC.Show.Show vn) => GHC.Show.Show (Language.Futhark.Syntax.TypeArgExp d vn)
- Language.Futhark.Syntax: instance (GHC.Show.Show dim, GHC.Show.Show u) => GHC.Show.Show (Language.Futhark.Syntax.ScalarTypeBase dim u)
- Language.Futhark.Syntax: instance (GHC.Show.Show dim, GHC.Show.Show u) => GHC.Show.Show (Language.Futhark.Syntax.TypeBase dim u)
- Language.Futhark.Syntax: instance (GHC.Show.Show vn, GHC.Show.Show d) => GHC.Show.Show (Language.Futhark.Syntax.TypeExp d vn)
- Language.Futhark.Syntax: instance Data.Bifoldable.Bifoldable Language.Futhark.Syntax.RetTypeBase
- Language.Futhark.Syntax: instance Data.Bifoldable.Bifoldable Language.Futhark.Syntax.ScalarTypeBase
- Language.Futhark.Syntax: instance Data.Bifoldable.Bifoldable Language.Futhark.Syntax.TypeArgExp
- Language.Futhark.Syntax: instance Data.Bifoldable.Bifoldable Language.Futhark.Syntax.TypeBase
- Language.Futhark.Syntax: instance Data.Bifoldable.Bifoldable Language.Futhark.Syntax.TypeExp
- Language.Futhark.Syntax: instance Data.Bifunctor.Bifunctor Language.Futhark.Syntax.RetTypeBase
- Language.Futhark.Syntax: instance Data.Bifunctor.Bifunctor Language.Futhark.Syntax.ScalarTypeBase
- Language.Futhark.Syntax: instance Data.Bifunctor.Bifunctor Language.Futhark.Syntax.TypeArgExp
- Language.Futhark.Syntax: instance Data.Bifunctor.Bifunctor Language.Futhark.Syntax.TypeBase
- Language.Futhark.Syntax: instance Data.Bifunctor.Bifunctor Language.Futhark.Syntax.TypeExp
- Language.Futhark.Syntax: instance Data.Bitraversable.Bitraversable Language.Futhark.Syntax.RetTypeBase
- Language.Futhark.Syntax: instance Data.Bitraversable.Bitraversable Language.Futhark.Syntax.ScalarTypeBase
- Language.Futhark.Syntax: instance Data.Bitraversable.Bitraversable Language.Futhark.Syntax.TypeArgExp
- Language.Futhark.Syntax: instance Data.Bitraversable.Bitraversable Language.Futhark.Syntax.TypeBase
- Language.Futhark.Syntax: instance Data.Bitraversable.Bitraversable Language.Futhark.Syntax.TypeExp
- Language.Futhark.Syntax: instance Data.Foldable.Foldable (Language.Futhark.Syntax.RetTypeBase dim)
- Language.Futhark.Syntax: instance Data.Foldable.Foldable (Language.Futhark.Syntax.ScalarTypeBase dim)
- Language.Futhark.Syntax: instance Data.Foldable.Foldable (Language.Futhark.Syntax.TypeArgExp d)
- Language.Futhark.Syntax: instance Data.Foldable.Foldable (Language.Futhark.Syntax.TypeBase dim)
- Language.Futhark.Syntax: instance Data.Foldable.Foldable (Language.Futhark.Syntax.TypeExp dim)
- Language.Futhark.Syntax: instance Data.Foldable.Foldable Language.Futhark.Syntax.Inclusiveness
- Language.Futhark.Syntax: instance Data.Foldable.Foldable Language.Futhark.Syntax.Info
- Language.Futhark.Syntax: instance Data.Foldable.Foldable Language.Futhark.Syntax.NoInfo
- Language.Futhark.Syntax: instance Data.Foldable.Foldable Language.Futhark.Syntax.QualName
- Language.Futhark.Syntax: instance Data.Foldable.Foldable Language.Futhark.Syntax.Shape
- Language.Futhark.Syntax: instance Data.Foldable.Foldable Language.Futhark.Syntax.SizeExp
- Language.Futhark.Syntax: instance Data.Foldable.Foldable Language.Futhark.Syntax.TypeArg
- Language.Futhark.Syntax: instance Data.Foldable.Foldable Language.Futhark.Syntax.TypeParamBase
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.AppExpBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.CaseBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.DecBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.ExpBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.FieldBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.LoopInitBase Language.Futhark.Syntax.Info vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.ModBindBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.ModExpBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.ModParamBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.ModTypeBindBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.ModTypeExpBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.PatBase f vn t)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.SizeBinder vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.SizeExp d)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.SpecBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.TypeArgExp f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.TypeBindBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.TypeExp f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.TypeParamBase vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.TypeRefBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located (Language.Futhark.Syntax.ValBindBase f vn)
- Language.Futhark.Syntax: instance Data.Loc.Located Language.Futhark.Syntax.DocComment
- Language.Futhark.Syntax: instance Data.Loc.Located a => Data.Loc.Located (Language.Futhark.Syntax.Inclusiveness a)
- Language.Futhark.Syntax: instance Data.Traversable.Traversable (Language.Futhark.Syntax.RetTypeBase dim)
- Language.Futhark.Syntax: instance Data.Traversable.Traversable (Language.Futhark.Syntax.ScalarTypeBase dim)
- Language.Futhark.Syntax: instance Data.Traversable.Traversable (Language.Futhark.Syntax.TypeArgExp d)
- Language.Futhark.Syntax: instance Data.Traversable.Traversable (Language.Futhark.Syntax.TypeBase dim)
- Language.Futhark.Syntax: instance Data.Traversable.Traversable (Language.Futhark.Syntax.TypeExp dim)
- Language.Futhark.Syntax: instance Data.Traversable.Traversable Language.Futhark.Syntax.Inclusiveness
- Language.Futhark.Syntax: instance Data.Traversable.Traversable Language.Futhark.Syntax.Info
- Language.Futhark.Syntax: instance Data.Traversable.Traversable Language.Futhark.Syntax.NoInfo
- Language.Futhark.Syntax: instance Data.Traversable.Traversable Language.Futhark.Syntax.QualName
- Language.Futhark.Syntax: instance Data.Traversable.Traversable Language.Futhark.Syntax.Shape
- Language.Futhark.Syntax: instance Data.Traversable.Traversable Language.Futhark.Syntax.SizeExp
- Language.Futhark.Syntax: instance Data.Traversable.Traversable Language.Futhark.Syntax.TypeArg
- Language.Futhark.Syntax: instance Data.Traversable.Traversable Language.Futhark.Syntax.TypeParamBase
- Language.Futhark.Syntax: instance Data.Traversable.Traversable f => Data.Foldable.Foldable (Language.Futhark.Syntax.PatBase f vn)
- Language.Futhark.Syntax: instance Data.Traversable.Traversable f => Data.Traversable.Traversable (Language.Futhark.Syntax.PatBase f vn)
- Language.Futhark.Syntax: instance Data.Traversable.Traversable f => GHC.Base.Functor (Language.Futhark.Syntax.PatBase f vn)
- Language.Futhark.Syntax: instance GHC.Base.Functor (Language.Futhark.Syntax.RetTypeBase dim)
- Language.Futhark.Syntax: instance GHC.Base.Functor (Language.Futhark.Syntax.ScalarTypeBase dim)
- Language.Futhark.Syntax: instance GHC.Base.Functor (Language.Futhark.Syntax.TypeArgExp d)
- Language.Futhark.Syntax: instance GHC.Base.Functor (Language.Futhark.Syntax.TypeBase dim)
- Language.Futhark.Syntax: instance GHC.Base.Functor (Language.Futhark.Syntax.TypeExp d)
- Language.Futhark.Syntax: instance GHC.Base.Functor Language.Futhark.Syntax.Inclusiveness
- Language.Futhark.Syntax: instance GHC.Base.Functor Language.Futhark.Syntax.Info
- Language.Futhark.Syntax: instance GHC.Base.Functor Language.Futhark.Syntax.NoInfo
- Language.Futhark.Syntax: instance GHC.Base.Functor Language.Futhark.Syntax.QualName
- Language.Futhark.Syntax: instance GHC.Base.Functor Language.Futhark.Syntax.Shape
- Language.Futhark.Syntax: instance GHC.Base.Functor Language.Futhark.Syntax.SizeExp
- Language.Futhark.Syntax: instance GHC.Base.Functor Language.Futhark.Syntax.TypeArg
- Language.Futhark.Syntax: instance GHC.Base.Functor Language.Futhark.Syntax.TypeParamBase
- Language.Futhark.Syntax: instance GHC.Base.Monoid (Language.Futhark.Syntax.Shape dim)
- Language.Futhark.Syntax: instance GHC.Base.Monoid Language.Futhark.Syntax.Diet
- Language.Futhark.Syntax: instance GHC.Base.Semigroup (Language.Futhark.Syntax.Shape dim)
- Language.Futhark.Syntax: instance GHC.Base.Semigroup Language.Futhark.Syntax.Diet
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.AppExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.AppExpBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.CaseBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.CaseBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.DimIndexBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.DimIndexBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.FieldBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.FieldBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.Info t) => GHC.Classes.Eq (Language.Futhark.Syntax.PatBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName t)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.LoopFormBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.LoopFormBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.LoopInitBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.LoopInitBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Eq (Language.Futhark.Syntax.NoInfo t) => GHC.Classes.Eq (Language.Futhark.Syntax.PatBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName t)
- Language.Futhark.Syntax: instance GHC.Classes.Eq Language.Futhark.Syntax.AppRes
- Language.Futhark.Syntax: instance GHC.Classes.Eq Language.Futhark.Syntax.BinOp
- Language.Futhark.Syntax: instance GHC.Classes.Eq Language.Futhark.Syntax.Diet
- Language.Futhark.Syntax: instance GHC.Classes.Eq Language.Futhark.Syntax.ImportName
- Language.Futhark.Syntax: instance GHC.Classes.Eq Language.Futhark.Syntax.Liftedness
- Language.Futhark.Syntax: instance GHC.Classes.Eq Language.Futhark.Syntax.PName
- Language.Futhark.Syntax: instance GHC.Classes.Eq Language.Futhark.Syntax.PatLit
- Language.Futhark.Syntax: instance GHC.Classes.Eq Language.Futhark.Syntax.PrimType
- Language.Futhark.Syntax: instance GHC.Classes.Eq Language.Futhark.Syntax.PrimValue
- Language.Futhark.Syntax: instance GHC.Classes.Eq a => GHC.Classes.Eq (Language.Futhark.Syntax.Inclusiveness a)
- Language.Futhark.Syntax: instance GHC.Classes.Eq a => GHC.Classes.Eq (Language.Futhark.Syntax.Info a)
- Language.Futhark.Syntax: instance GHC.Classes.Eq d => GHC.Classes.Eq (Language.Futhark.Syntax.SizeExp d)
- Language.Futhark.Syntax: instance GHC.Classes.Eq dim => GHC.Classes.Eq (Language.Futhark.Syntax.Shape dim)
- Language.Futhark.Syntax: instance GHC.Classes.Eq dim => GHC.Classes.Eq (Language.Futhark.Syntax.TypeArg dim)
- Language.Futhark.Syntax: instance GHC.Classes.Eq v => GHC.Classes.Eq (Language.Futhark.Syntax.QualName v)
- Language.Futhark.Syntax: instance GHC.Classes.Eq vn => GHC.Classes.Eq (Language.Futhark.Syntax.SizeBinder vn)
- Language.Futhark.Syntax: instance GHC.Classes.Eq vn => GHC.Classes.Eq (Language.Futhark.Syntax.TypeParamBase vn)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.AppExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.AppExpBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.CaseBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.CaseBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.DimIndexBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.DimIndexBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.FieldBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.FieldBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.Info t) => GHC.Classes.Ord (Language.Futhark.Syntax.PatBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName t)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.LoopFormBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.LoopFormBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.LoopInitBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.LoopInitBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Classes.Ord (Language.Futhark.Syntax.NoInfo t) => GHC.Classes.Ord (Language.Futhark.Syntax.PatBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.VName t)
- Language.Futhark.Syntax: instance GHC.Classes.Ord Language.Futhark.Syntax.AppRes
- Language.Futhark.Syntax: instance GHC.Classes.Ord Language.Futhark.Syntax.BinOp
- Language.Futhark.Syntax: instance GHC.Classes.Ord Language.Futhark.Syntax.Diet
- Language.Futhark.Syntax: instance GHC.Classes.Ord Language.Futhark.Syntax.ImportName
- Language.Futhark.Syntax: instance GHC.Classes.Ord Language.Futhark.Syntax.Liftedness
- Language.Futhark.Syntax: instance GHC.Classes.Ord Language.Futhark.Syntax.PName
- Language.Futhark.Syntax: instance GHC.Classes.Ord Language.Futhark.Syntax.PatLit
- Language.Futhark.Syntax: instance GHC.Classes.Ord Language.Futhark.Syntax.PrimType
- Language.Futhark.Syntax: instance GHC.Classes.Ord Language.Futhark.Syntax.PrimValue
- Language.Futhark.Syntax: instance GHC.Classes.Ord a => GHC.Classes.Ord (Language.Futhark.Syntax.Inclusiveness a)
- Language.Futhark.Syntax: instance GHC.Classes.Ord a => GHC.Classes.Ord (Language.Futhark.Syntax.Info a)
- Language.Futhark.Syntax: instance GHC.Classes.Ord d => GHC.Classes.Ord (Language.Futhark.Syntax.SizeExp d)
- Language.Futhark.Syntax: instance GHC.Classes.Ord dim => GHC.Classes.Ord (Language.Futhark.Syntax.Shape dim)
- Language.Futhark.Syntax: instance GHC.Classes.Ord dim => GHC.Classes.Ord (Language.Futhark.Syntax.TypeArg dim)
- Language.Futhark.Syntax: instance GHC.Classes.Ord v => GHC.Classes.Ord (Language.Futhark.Syntax.QualName v)
- Language.Futhark.Syntax: instance GHC.Classes.Ord vn => GHC.Classes.Ord (Language.Futhark.Syntax.SizeBinder vn)
- Language.Futhark.Syntax: instance GHC.Classes.Ord vn => GHC.Classes.Ord (Language.Futhark.Syntax.TypeParamBase vn)
- Language.Futhark.Syntax: instance GHC.Enum.Bounded Language.Futhark.Syntax.BinOp
- Language.Futhark.Syntax: instance GHC.Enum.Enum Language.Futhark.Syntax.BinOp
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.AppExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.CaseBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.DecBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.DecBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.DimIndexBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.FieldBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.Info t) => GHC.Show.Show (Language.Futhark.Syntax.IdentBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName t)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.Info t) => GHC.Show.Show (Language.Futhark.Syntax.PatBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName t)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.LoopFormBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.LoopInitBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModBindBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModBindBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModExpBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModParamBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModParamBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModTypeBindBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModTypeBindBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModTypeExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ModTypeExpBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ProgBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ProgBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.SpecBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.SpecBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.TypeBindBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.TypeBindBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.TypeRefBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.TypeRefBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ValBindBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Syntax: instance GHC.Show.Show (Language.Futhark.Syntax.ValBindBase Language.Futhark.Syntax.NoInfo Language.Futhark.Core.Name)
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.AppRes
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.BinOp
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.Diet
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.DocComment
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.EntryParam
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.EntryPoint
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.EntryType
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.ImportName
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.Liftedness
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.PName
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.PatLit
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.PrimType
- Language.Futhark.Syntax: instance GHC.Show.Show Language.Futhark.Syntax.PrimValue
- Language.Futhark.Syntax: instance GHC.Show.Show a => GHC.Show.Show (Language.Futhark.Syntax.Inclusiveness a)
- Language.Futhark.Syntax: instance GHC.Show.Show a => GHC.Show.Show (Language.Futhark.Syntax.Info a)
- Language.Futhark.Syntax: instance GHC.Show.Show d => GHC.Show.Show (Language.Futhark.Syntax.SizeExp d)
- Language.Futhark.Syntax: instance GHC.Show.Show dim => GHC.Show.Show (Language.Futhark.Syntax.Shape dim)
- Language.Futhark.Syntax: instance GHC.Show.Show dim => GHC.Show.Show (Language.Futhark.Syntax.TypeArg dim)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.AppExpBase Language.Futhark.Syntax.NoInfo vn)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.CaseBase Language.Futhark.Syntax.NoInfo vn)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.DimIndexBase Language.Futhark.Syntax.NoInfo vn)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.NoInfo vn)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.FieldBase Language.Futhark.Syntax.NoInfo vn)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.LoopFormBase Language.Futhark.Syntax.NoInfo vn)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.LoopInitBase Language.Futhark.Syntax.NoInfo vn)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.QualName vn)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.SizeBinder vn)
- Language.Futhark.Syntax: instance GHC.Show.Show vn => GHC.Show.Show (Language.Futhark.Syntax.TypeParamBase vn)
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Int.Int16
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Int.Int32
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Int.Int64
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Int.Int8
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Types.Bool
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Types.Double
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Types.Float
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Types.Int
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Word.Word16
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Word.Word32
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Word.Word64
- Language.Futhark.Syntax: instance Language.Futhark.Syntax.IsPrimValue GHC.Word.Word8
- Language.Futhark.Syntax: instance Prettyprinter.Internal.Pretty Language.Futhark.Syntax.BinOp
- Language.Futhark.Syntax: instance Prettyprinter.Internal.Pretty Language.Futhark.Syntax.PrimType
- Language.Futhark.Syntax: instance forall k (a :: k). GHC.Classes.Eq (Language.Futhark.Syntax.NoInfo a)
- Language.Futhark.Syntax: instance forall k (a :: k). GHC.Classes.Ord (Language.Futhark.Syntax.NoInfo a)
- Language.Futhark.Syntax: instance forall k (a :: k). GHC.Show.Show (Language.Futhark.Syntax.NoInfo a)
- Language.Futhark.Syntax: instance forall k (ty :: k -> *) vn (t :: k). Data.Loc.Located (Language.Futhark.Syntax.IdentBase ty vn t)
- Language.Futhark.Syntax: instance forall k (vn :: k). GHC.Classes.Eq (Language.Futhark.Syntax.AttrAtom vn)
- Language.Futhark.Syntax: instance forall k (vn :: k). GHC.Classes.Eq (Language.Futhark.Syntax.AttrInfo vn)
- Language.Futhark.Syntax: instance forall k (vn :: k). GHC.Classes.Ord (Language.Futhark.Syntax.AttrAtom vn)
- Language.Futhark.Syntax: instance forall k (vn :: k). GHC.Classes.Ord (Language.Futhark.Syntax.AttrInfo vn)
- Language.Futhark.Syntax: instance forall k (vn :: k). GHC.Show.Show (Language.Futhark.Syntax.AttrAtom vn)
- Language.Futhark.Syntax: instance forall k (vn :: k). GHC.Show.Show (Language.Futhark.Syntax.AttrInfo vn)
- Language.Futhark.Syntax: instance forall k vn (ty :: k -> *) (t :: k). GHC.Classes.Eq vn => GHC.Classes.Eq (Language.Futhark.Syntax.IdentBase ty vn t)
- Language.Futhark.Syntax: instance forall k vn (ty :: k -> *) (t :: k). GHC.Classes.Ord vn => GHC.Classes.Ord (Language.Futhark.Syntax.IdentBase ty vn t)
- Language.Futhark.Syntax: loopInitExp :: LoopInitBase Info VName -> ExpBase Info VName
- Language.Futhark.Syntax: mkApply :: ExpBase Info vn -> [(Maybe VName, ExpBase Info vn)] -> AppRes -> ExpBase Info vn
- Language.Futhark.Syntax: mkApplyUT :: ExpBase (NoInfo :: Type -> Type) vn -> ExpBase (NoInfo :: Type -> Type) vn -> ExpBase (NoInfo :: Type -> Type) vn
- Language.Futhark.Syntax: newtype ImportName
- Language.Futhark.Syntax: newtype Info a
- Language.Futhark.Syntax: newtype Shape dim
- Language.Futhark.Syntax: prettyString :: Pretty a => a -> String
- Language.Futhark.Syntax: prettyText :: Pretty a => a -> Text
- Language.Futhark.Syntax: primValue :: IsPrimValue v => v -> PrimValue
- Language.Futhark.Syntax: shapeRank :: Shape dim -> Int
- Language.Futhark.Syntax: sizeFromInteger :: Integer -> SrcLoc -> Size
- Language.Futhark.Syntax: sizeFromName :: QualName VName -> SrcLoc -> Size
- Language.Futhark.Syntax: stripDims :: Int -> Shape dim -> Maybe (Shape dim)
- Language.Futhark.Syntax: type ParamType = TypeBase Size Diet
- Language.Futhark.Syntax: type ResRetType = RetTypeBase Size Uniqueness
- Language.Futhark.Syntax: type ResType = TypeBase Size Uniqueness
- Language.Futhark.Syntax: type Size = ExpBase Info VName
- Language.Futhark.Syntax: type SliceBase (f :: Type -> Type) vn = [DimIndexBase f vn]
- Language.Futhark.Syntax: type StructRetType = RetTypeBase Size NoUniqueness
- Language.Futhark.Syntax: type StructType = TypeBase Size NoUniqueness
- Language.Futhark.Syntax: type ValueType = TypeBase Int64 NoUniqueness
- Language.Futhark.Syntax: typeParamName :: TypeParamBase vn -> vn
- Language.Futhark.Traversals: ASTMapper :: (ExpBase Info VName -> m (ExpBase Info VName)) -> (QualName VName -> m (QualName VName)) -> (StructType -> m StructType) -> (ParamType -> m ParamType) -> (ResRetType -> m ResRetType) -> ASTMapper (m :: Type -> Type)
- Language.Futhark.Traversals: [mapOnExp] :: ASTMapper (m :: Type -> Type) -> ExpBase Info VName -> m (ExpBase Info VName)
- Language.Futhark.Traversals: [mapOnName] :: ASTMapper (m :: Type -> Type) -> QualName VName -> m (QualName VName)
- Language.Futhark.Traversals: [mapOnParamType] :: ASTMapper (m :: Type -> Type) -> ParamType -> m ParamType
- Language.Futhark.Traversals: [mapOnResRetType] :: ASTMapper (m :: Type -> Type) -> ResRetType -> m ResRetType
- Language.Futhark.Traversals: [mapOnStructType] :: ASTMapper (m :: Type -> Type) -> StructType -> m StructType
- Language.Futhark.Traversals: astMap :: (ASTMappable x, Monad m) => ASTMapper m -> x -> m x
- Language.Futhark.Traversals: bareExp :: ExpBase Info VName -> ExpBase (NoInfo :: Type -> Type) VName
- Language.Futhark.Traversals: class ASTMappable x
- Language.Futhark.Traversals: data ASTMapper (m :: Type -> Type)
- Language.Futhark.Traversals: identityMapper :: forall (m :: Type -> Type). Monad m => ASTMapper m
- Language.Futhark.Traversals: instance (Language.Futhark.Traversals.ASTMappable a, Language.Futhark.Traversals.ASTMappable b) => Language.Futhark.Traversals.ASTMappable (a, b)
- Language.Futhark.Traversals: instance (Language.Futhark.Traversals.ASTMappable a, Language.Futhark.Traversals.ASTMappable b, Language.Futhark.Traversals.ASTMappable c) => Language.Futhark.Traversals.ASTMappable (a, b, c)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.AppExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.CaseBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.DimIndexBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.FieldBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.IdentBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName Language.Futhark.Syntax.StructType)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.LoopFormBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.LoopInitBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.PatBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName Language.Futhark.Syntax.ParamType)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.PatBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName Language.Futhark.Syntax.StructType)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.SizeExp (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName))
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.TypeArgExp (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName) Language.Futhark.Core.VName)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.TypeBase Language.Futhark.Syntax.Size Language.Futhark.Core.Uniqueness)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.TypeExp (Language.Futhark.Syntax.ExpBase Language.Futhark.Syntax.Info Language.Futhark.Core.VName) Language.Futhark.Core.VName)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable Language.Futhark.Syntax.AppRes
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable Language.Futhark.Syntax.ParamType
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable Language.Futhark.Syntax.ResRetType
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable Language.Futhark.Syntax.StructType
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable a => Language.Futhark.Traversals.ASTMappable (GHC.Base.NonEmpty a)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable a => Language.Futhark.Traversals.ASTMappable (Language.Futhark.Syntax.Info a)
- Language.Futhark.Traversals: instance Language.Futhark.Traversals.ASTMappable a => Language.Futhark.Traversals.ASTMappable [a]
- Language.Futhark.Tuple: areTupleFields :: Map Name a -> Maybe [a]
- Language.Futhark.Tuple: sortFields :: Map Name a -> [(Name, a)]
- Language.Futhark.Tuple: tupleFieldNames :: [Name]
- Language.Futhark.Tuple: tupleFields :: [a] -> Map Name a
- Language.Futhark.TypeChecker: TypeError :: Loc -> Notes -> Doc () -> TypeError
- Language.Futhark.TypeChecker: checkDec :: Imports -> VNameSource -> Env -> ImportName -> UncheckedDec -> (Warnings, Either TypeError (Env, Dec, VNameSource))
- Language.Futhark.TypeChecker: checkExp :: Imports -> VNameSource -> Env -> UncheckedExp -> (Warnings, Either TypeError ([TypeParam], Exp))
- Language.Futhark.TypeChecker: checkModExp :: Imports -> VNameSource -> Env -> ModExpBase (NoInfo :: Type -> Type) Name -> (Warnings, Either TypeError (MTy, ModExpBase Info VName))
- Language.Futhark.TypeChecker: checkProg :: Imports -> VNameSource -> ImportName -> UncheckedProg -> (Warnings, Either TypeError (FileModule, VNameSource))
- Language.Futhark.TypeChecker: data Notes
- Language.Futhark.TypeChecker: data TypeError
- Language.Futhark.TypeChecker: data Warnings
- Language.Futhark.TypeChecker: envWithImports :: Imports -> Env -> Env
- Language.Futhark.TypeChecker: initialEnv :: Env
- Language.Futhark.TypeChecker: prettyTypeError :: TypeError -> Doc AnsiStyle
- Language.Futhark.TypeChecker: prettyTypeErrorNoLoc :: TypeError -> Doc AnsiStyle
- Language.Futhark.TypeChecker.Consumption: checkValDef :: (VName, [Pat ParamType], Exp, ResRetType, Maybe (TypeExp Exp VName), SrcLoc) -> ((Exp, ResRetType), [TypeError])
- Language.Futhark.TypeChecker.Consumption: instance Control.Monad.Reader.Class.MonadReader Language.Futhark.TypeChecker.Consumption.CheckEnv Language.Futhark.TypeChecker.Consumption.CheckM
- Language.Futhark.TypeChecker.Consumption: instance Control.Monad.State.Class.MonadState Language.Futhark.TypeChecker.Consumption.CheckState Language.Futhark.TypeChecker.Consumption.CheckM
- Language.Futhark.TypeChecker.Consumption: instance GHC.Base.Applicative Language.Futhark.TypeChecker.Consumption.CheckM
- Language.Futhark.TypeChecker.Consumption: instance GHC.Base.Functor Language.Futhark.TypeChecker.Consumption.CheckM
- Language.Futhark.TypeChecker.Consumption: instance GHC.Base.Functor Language.Futhark.TypeChecker.Consumption.Entry
- Language.Futhark.TypeChecker.Consumption: instance GHC.Base.Monad Language.Futhark.TypeChecker.Consumption.CheckM
- Language.Futhark.TypeChecker.Consumption: instance GHC.Classes.Eq Language.Futhark.TypeChecker.Consumption.Alias
- Language.Futhark.TypeChecker.Consumption: instance GHC.Classes.Eq a => GHC.Classes.Eq (Language.Futhark.TypeChecker.Consumption.Entry a)
- Language.Futhark.TypeChecker.Consumption: instance GHC.Classes.Ord Language.Futhark.TypeChecker.Consumption.Alias
- Language.Futhark.TypeChecker.Consumption: instance GHC.Classes.Ord a => GHC.Classes.Ord (Language.Futhark.TypeChecker.Consumption.Entry a)
- Language.Futhark.TypeChecker.Consumption: instance GHC.Show.Show Language.Futhark.TypeChecker.Consumption.Alias
- Language.Futhark.TypeChecker.Consumption: instance GHC.Show.Show a => GHC.Show.Show (Language.Futhark.TypeChecker.Consumption.Entry a)
- Language.Futhark.TypeChecker.Consumption: instance Prettyprinter.Internal.Pretty (Data.Set.Internal.Set Language.Futhark.TypeChecker.Consumption.Alias)
- Language.Futhark.TypeChecker.Consumption: instance Prettyprinter.Internal.Pretty Language.Futhark.TypeChecker.Consumption.Alias
- Language.Futhark.TypeChecker.Match: data Match t
- Language.Futhark.TypeChecker.Match: instance GHC.Classes.Eq Language.Futhark.TypeChecker.Match.Constr
- Language.Futhark.TypeChecker.Match: instance GHC.Classes.Eq t => GHC.Classes.Eq (Language.Futhark.TypeChecker.Match.Match t)
- Language.Futhark.TypeChecker.Match: instance GHC.Classes.Ord Language.Futhark.TypeChecker.Match.Constr
- Language.Futhark.TypeChecker.Match: instance GHC.Classes.Ord t => GHC.Classes.Ord (Language.Futhark.TypeChecker.Match.Match t)
- Language.Futhark.TypeChecker.Match: instance GHC.Show.Show Language.Futhark.TypeChecker.Match.Constr
- Language.Futhark.TypeChecker.Match: instance GHC.Show.Show t => GHC.Show.Show (Language.Futhark.TypeChecker.Match.Match t)
- Language.Futhark.TypeChecker.Match: instance Prettyprinter.Internal.Pretty (Language.Futhark.TypeChecker.Match.Match t)
- Language.Futhark.TypeChecker.Match: unmatched :: [Pat StructType] -> [Match ()]
- Language.Futhark.TypeChecker.Modules: applyFunctor :: Loc -> FunModType -> MTy -> TypeM (MTy, Map VName VName, Map VName VName)
- Language.Futhark.TypeChecker.Modules: matchMTys :: MTy -> MTy -> Loc -> Either TypeError (Map VName VName)
- Language.Futhark.TypeChecker.Modules: newNamesForMTy :: MTy -> TypeM (MTy, Map VName VName)
- Language.Futhark.TypeChecker.Modules: refineEnv :: SrcLoc -> TySet -> Env -> QualName Name -> [TypeParam] -> StructRetType -> TypeM (QualName VName, TySet, Env)
- Language.Futhark.TypeChecker.Monad: BoundV :: [TypeParam] -> StructType -> BoundV
- Language.Futhark.TypeChecker.Monad: Env :: Map VName BoundV -> Map VName TypeBinding -> Map VName MTy -> Map VName Mod -> NameMap -> Env
- Language.Futhark.TypeChecker.Monad: FunModType :: TySet -> Mod -> MTy -> FunModType
- Language.Futhark.TypeChecker.Monad: MTy :: TySet -> Mod -> MTy
- Language.Futhark.TypeChecker.Monad: ModEnv :: Env -> Mod
- Language.Futhark.TypeChecker.Monad: ModFun :: FunModType -> Mod
- Language.Futhark.TypeChecker.Monad: Signature :: Namespace
- Language.Futhark.TypeChecker.Monad: Term :: Namespace
- Language.Futhark.TypeChecker.Monad: Type :: Namespace
- Language.Futhark.TypeChecker.Monad: TypeAbbr :: Liftedness -> [TypeParam] -> StructRetType -> TypeBinding
- Language.Futhark.TypeChecker.Monad: TypeError :: Loc -> Notes -> Doc () -> TypeError
- Language.Futhark.TypeChecker.Monad: [boundValTParams] :: BoundV -> [TypeParam]
- Language.Futhark.TypeChecker.Monad: [boundValType] :: BoundV -> StructType
- Language.Futhark.TypeChecker.Monad: [envModTable] :: Env -> Map VName Mod
- Language.Futhark.TypeChecker.Monad: [envModTypeTable] :: Env -> Map VName MTy
- Language.Futhark.TypeChecker.Monad: [envNameMap] :: Env -> NameMap
- Language.Futhark.TypeChecker.Monad: [envTypeTable] :: Env -> Map VName TypeBinding
- Language.Futhark.TypeChecker.Monad: [envVtable] :: Env -> Map VName BoundV
- Language.Futhark.TypeChecker.Monad: [funModTypeAbs] :: FunModType -> TySet
- Language.Futhark.TypeChecker.Monad: [funModTypeMod] :: FunModType -> Mod
- Language.Futhark.TypeChecker.Monad: [funModTypeMty] :: FunModType -> MTy
- Language.Futhark.TypeChecker.Monad: [mtyAbs] :: MTy -> TySet
- Language.Futhark.TypeChecker.Monad: [mtyMod] :: MTy -> Mod
- Language.Futhark.TypeChecker.Monad: aNote :: Doc () -> Notes
- Language.Futhark.TypeChecker.Monad: anyFloatType :: [PrimType]
- Language.Futhark.TypeChecker.Monad: anyIntType :: [PrimType]
- Language.Futhark.TypeChecker.Monad: anyNumberType :: [PrimType]
- Language.Futhark.TypeChecker.Monad: anyPrimType :: [PrimType]
- Language.Futhark.TypeChecker.Monad: anySignedType :: [PrimType]
- Language.Futhark.TypeChecker.Monad: anyUnsignedType :: [PrimType]
- Language.Futhark.TypeChecker.Monad: askEnv :: TypeM Env
- Language.Futhark.TypeChecker.Monad: askImportName :: TypeM ImportName
- Language.Futhark.TypeChecker.Monad: atTopLevel :: TypeM Bool
- Language.Futhark.TypeChecker.Monad: badOnLeft :: Either TypeError a -> TypeM a
- Language.Futhark.TypeChecker.Monad: bindIdents :: forall {k} (t :: k) a. [IdentBase (NoInfo :: k -> Type) VName t] -> TypeM a -> TypeM a
- Language.Futhark.TypeChecker.Monad: bindSpaced :: [(Namespace, Name, SrcLoc)] -> ([VName] -> TypeM a) -> TypeM a
- Language.Futhark.TypeChecker.Monad: bindSpaced1 :: Namespace -> Name -> SrcLoc -> (VName -> TypeM a) -> TypeM a
- Language.Futhark.TypeChecker.Monad: bindVal :: MonadTypeChecker m => VName -> BoundV -> m a -> m a
- Language.Futhark.TypeChecker.Monad: checkAttr :: MonadTypeChecker m => AttrInfo VName -> m (AttrInfo VName)
- Language.Futhark.TypeChecker.Monad: checkName :: Namespace -> Name -> SrcLoc -> TypeM VName
- Language.Futhark.TypeChecker.Monad: checkQualName :: Namespace -> QualName Name -> SrcLoc -> TypeM (QualName VName)
- Language.Futhark.TypeChecker.Monad: checkValName :: QualName Name -> SrcLoc -> TypeM (QualName VName)
- Language.Futhark.TypeChecker.Monad: class Monad m => MonadTypeChecker (m :: Type -> Type)
- Language.Futhark.TypeChecker.Monad: data BoundV
- Language.Futhark.TypeChecker.Monad: data Env
- Language.Futhark.TypeChecker.Monad: data FunModType
- Language.Futhark.TypeChecker.Monad: data MTy
- Language.Futhark.TypeChecker.Monad: data Mod
- Language.Futhark.TypeChecker.Monad: data Namespace
- Language.Futhark.TypeChecker.Monad: data Notes
- Language.Futhark.TypeChecker.Monad: data TypeBinding
- Language.Futhark.TypeChecker.Monad: data TypeError
- Language.Futhark.TypeChecker.Monad: data TypeM a
- Language.Futhark.TypeChecker.Monad: data TypeState
- Language.Futhark.TypeChecker.Monad: enteringModule :: TypeM a -> TypeM a
- Language.Futhark.TypeChecker.Monad: instance Control.Monad.Error.Class.MonadError Language.Futhark.TypeChecker.Monad.TypeError Language.Futhark.TypeChecker.Monad.TypeM
- Language.Futhark.TypeChecker.Monad: instance Control.Monad.Reader.Class.MonadReader Language.Futhark.TypeChecker.Monad.Context Language.Futhark.TypeChecker.Monad.TypeM
- Language.Futhark.TypeChecker.Monad: instance Control.Monad.State.Class.MonadState Language.Futhark.TypeChecker.Monad.TypeState Language.Futhark.TypeChecker.Monad.TypeM
- Language.Futhark.TypeChecker.Monad: instance GHC.Base.Applicative Language.Futhark.TypeChecker.Monad.TypeM
- Language.Futhark.TypeChecker.Monad: instance GHC.Base.Functor Language.Futhark.TypeChecker.Monad.TypeM
- Language.Futhark.TypeChecker.Monad: instance GHC.Base.Monad Language.Futhark.TypeChecker.Monad.TypeM
- Language.Futhark.TypeChecker.Monad: instance GHC.Base.Monoid Language.Futhark.TypeChecker.Monad.Notes
- Language.Futhark.TypeChecker.Monad: instance GHC.Base.Semigroup Language.Futhark.TypeChecker.Monad.Notes
- Language.Futhark.TypeChecker.Monad: instance Language.Futhark.TypeChecker.Monad.MonadTypeChecker Language.Futhark.TypeChecker.Monad.TypeM
- Language.Futhark.TypeChecker.Monad: instance Prettyprinter.Internal.Pretty Language.Futhark.TypeChecker.Monad.Note
- Language.Futhark.TypeChecker.Monad: instance Prettyprinter.Internal.Pretty Language.Futhark.TypeChecker.Monad.Notes
- Language.Futhark.TypeChecker.Monad: intrinsicsNameMap :: NameMap
- Language.Futhark.TypeChecker.Monad: isKnownType :: QualName VName -> TypeM Bool
- Language.Futhark.TypeChecker.Monad: localEnv :: Env -> TypeM a -> TypeM a
- Language.Futhark.TypeChecker.Monad: lookupImport :: SrcLoc -> FilePath -> TypeM (ImportName, Env)
- Language.Futhark.TypeChecker.Monad: lookupMTy :: SrcLoc -> QualName Name -> TypeM (QualName VName, MTy)
- Language.Futhark.TypeChecker.Monad: lookupMod :: SrcLoc -> QualName Name -> TypeM (QualName VName, Mod)
- Language.Futhark.TypeChecker.Monad: lookupType :: MonadTypeChecker m => QualName VName -> m ([TypeParam], StructRetType, Liftedness)
- Language.Futhark.TypeChecker.Monad: mkTypeVarName :: Name -> Int -> Name
- Language.Futhark.TypeChecker.Monad: newID :: MonadTypeChecker m => Name -> m VName
- Language.Futhark.TypeChecker.Monad: newName :: MonadTypeChecker m => VName -> m VName
- Language.Futhark.TypeChecker.Monad: newTypeName :: MonadTypeChecker m => Name -> m VName
- Language.Futhark.TypeChecker.Monad: prettyTypeError :: TypeError -> Doc AnsiStyle
- Language.Futhark.TypeChecker.Monad: prettyTypeErrorNoLoc :: TypeError -> Doc AnsiStyle
- Language.Futhark.TypeChecker.Monad: qualifyTypeVars :: Env -> [VName] -> [VName] -> TypeBase Size as -> TypeBase Size as
- Language.Futhark.TypeChecker.Monad: runTypeM :: Env -> ImportTable -> ImportName -> VNameSource -> TypeM a -> (Warnings, Either TypeError (a, VNameSource))
- Language.Futhark.TypeChecker.Monad: topLevelNameMap :: NameMap
- Language.Futhark.TypeChecker.Monad: type ImportTable = Map ImportName Env
- Language.Futhark.TypeChecker.Monad: type NameMap = Map (Namespace, Name) QualName VName
- Language.Futhark.TypeChecker.Monad: type TySet = Map QualName VName Liftedness
- Language.Futhark.TypeChecker.Monad: typeError :: (MonadTypeChecker m, Located loc) => loc -> Notes -> Doc () -> m a
- Language.Futhark.TypeChecker.Monad: unappliedFunctor :: MonadTypeChecker m => SrcLoc -> m a
- Language.Futhark.TypeChecker.Monad: underscoreUse :: MonadTypeChecker m => SrcLoc -> QualName Name -> m a
- Language.Futhark.TypeChecker.Monad: unknownVariable :: MonadTypeChecker m => Namespace -> QualName Name -> SrcLoc -> m a
- Language.Futhark.TypeChecker.Monad: usedName :: VName -> TypeM ()
- Language.Futhark.TypeChecker.Monad: warn :: (MonadTypeChecker m, Located loc) => loc -> Doc () -> m ()
- Language.Futhark.TypeChecker.Monad: warnings :: MonadTypeChecker m => Warnings -> m ()
- Language.Futhark.TypeChecker.Monad: withIndexLink :: Doc a -> Doc a -> Doc a
- Language.Futhark.TypeChecker.Names: resolveExp :: ExpBase (NoInfo :: Type -> Type) Name -> TypeM (ExpBase (NoInfo :: Type -> Type) VName)
- Language.Futhark.TypeChecker.Names: resolveTypeExp :: TypeExp (ExpBase (NoInfo :: Type -> Type) Name) Name -> TypeM (TypeExp (ExpBase (NoInfo :: Type -> Type) VName) VName)
- Language.Futhark.TypeChecker.Names: resolveTypeParams :: [TypeParamBase Name] -> ([TypeParamBase VName] -> TypeM a) -> TypeM a
- Language.Futhark.TypeChecker.Names: resolveValBind :: ValBindBase (NoInfo :: Type -> Type) Name -> TypeM (ValBindBase (NoInfo :: Type -> Type) VName)
- Language.Futhark.TypeChecker.Terms: checkFunDef :: (VName, Maybe (TypeExp (ExpBase (NoInfo :: Type -> Type) VName) VName), [TypeParam], [PatBase (NoInfo :: Type -> Type) VName ParamType], ExpBase (NoInfo :: Type -> Type) VName, SrcLoc) -> TypeM ([TypeParam], [Pat ParamType], Maybe (TypeExp Exp VName), ResRetType, Exp)
- Language.Futhark.TypeChecker.Terms: checkOneExp :: ExpBase (NoInfo :: Type -> Type) VName -> TypeM ([TypeParam], Exp)
- Language.Futhark.TypeChecker.Terms: checkSizeExp :: ExpBase (NoInfo :: Type -> Type) VName -> TypeM Exp
- Language.Futhark.TypeChecker.Terms: instance GHC.Base.Functor Language.Futhark.TypeChecker.Terms.Unmatched
- Language.Futhark.TypeChecker.Terms: instance GHC.Show.Show p => GHC.Show.Show (Language.Futhark.TypeChecker.Terms.Unmatched p)
- Language.Futhark.TypeChecker.Terms: instance Prettyprinter.Internal.Pretty (Language.Futhark.TypeChecker.Terms.Unmatched (Language.Futhark.Prop.Pat Language.Futhark.Syntax.StructType))
- Language.Futhark.TypeChecker.Terms.Loop: checkLoop :: (ExpBase (NoInfo :: Type -> Type) VName -> TermTypeM Exp) -> UncheckedLoop -> SrcLoc -> TermTypeM (CheckedLoop, AppRes)
- Language.Futhark.TypeChecker.Terms.Loop: type CheckedLoop = ([VName], Pat ParamType, LoopInitBase Info VName, LoopFormBase Info VName, Exp)
- Language.Futhark.TypeChecker.Terms.Loop: type UncheckedLoop = (PatBase NoInfo :: Type -> Type VName ParamType, LoopInitBase NoInfo :: Type -> Type VName, LoopFormBase NoInfo :: Type -> Type VName, ExpBase NoInfo :: Type -> Type VName)
- Language.Futhark.TypeChecker.Terms.Monad: Ascribed :: t -> Inferred t
- Language.Futhark.TypeChecker.Terms.Monad: BoundV :: [TypeParam] -> StructType -> ValBinding
- Language.Futhark.TypeChecker.Terms.Monad: CheckingApply :: Maybe (QualName VName) -> Exp -> StructType -> StructType -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingAscription :: StructType -> StructType -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingBranches :: StructType -> StructType -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingLetGeneralise :: Name -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingLoopBody :: StructType -> StructType -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingLoopInitial :: StructType -> StructType -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingParams :: Maybe Name -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingPat :: PatBase (NoInfo :: Type -> Type) VName StructType -> Inferred StructType -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingRecordUpdate :: [Name] -> StructType -> StructType -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingRequired :: [StructType] -> StructType -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: CheckingReturn :: ResType -> StructType -> Checking
- Language.Futhark.TypeChecker.Terms.Monad: EqualityF :: ValBinding
- Language.Futhark.TypeChecker.Terms.Monad: NoneInferred :: Inferred t
- Language.Futhark.TypeChecker.Terms.Monad: OverloadedF :: [PrimType] -> [Maybe PrimType] -> Maybe PrimType -> ValBinding
- Language.Futhark.TypeChecker.Terms.Monad: SourceSlice :: Maybe Size -> Maybe (ExpBase (NoInfo :: Type -> Type) VName) -> Maybe (ExpBase (NoInfo :: Type -> Type) VName) -> Maybe (ExpBase (NoInfo :: Type -> Type) VName) -> SizeSource
- Language.Futhark.TypeChecker.Terms.Monad: TermEnv :: TermScope -> Maybe Checking -> Level -> (ExpBase (NoInfo :: Type -> Type) VName -> TermTypeM Exp) -> Env -> ImportName -> TermEnv
- Language.Futhark.TypeChecker.Terms.Monad: TermScope :: Map VName ValBinding -> Map VName TypeBinding -> Map VName Mod -> TermScope
- Language.Futhark.TypeChecker.Terms.Monad: TermTypeState :: Constraints -> !Int -> Warnings -> VNameSource -> TermTypeState
- Language.Futhark.TypeChecker.Terms.Monad: [scopeModTable] :: TermScope -> Map VName Mod
- Language.Futhark.TypeChecker.Terms.Monad: [scopeTypeTable] :: TermScope -> Map VName TypeBinding
- Language.Futhark.TypeChecker.Terms.Monad: [scopeVtable] :: TermScope -> Map VName ValBinding
- Language.Futhark.TypeChecker.Terms.Monad: [stateConstraints] :: TermTypeState -> Constraints
- Language.Futhark.TypeChecker.Terms.Monad: [stateCounter] :: TermTypeState -> !Int
- Language.Futhark.TypeChecker.Terms.Monad: [stateNameSource] :: TermTypeState -> VNameSource
- Language.Futhark.TypeChecker.Terms.Monad: [stateWarnings] :: TermTypeState -> Warnings
- Language.Futhark.TypeChecker.Terms.Monad: [termChecker] :: TermEnv -> ExpBase (NoInfo :: Type -> Type) VName -> TermTypeM Exp
- Language.Futhark.TypeChecker.Terms.Monad: [termChecking] :: TermEnv -> Maybe Checking
- Language.Futhark.TypeChecker.Terms.Monad: [termImportName] :: TermEnv -> ImportName
- Language.Futhark.TypeChecker.Terms.Monad: [termLevel] :: TermEnv -> Level
- Language.Futhark.TypeChecker.Terms.Monad: [termOuterEnv] :: TermEnv -> Env
- Language.Futhark.TypeChecker.Terms.Monad: [termScope] :: TermEnv -> TermScope
- Language.Futhark.TypeChecker.Terms.Monad: allDimsFreshInType :: Usage -> Rigidity -> Name -> TypeBase Size als -> TermTypeM (TypeBase Size als, Map VName Size)
- Language.Futhark.TypeChecker.Terms.Monad: checkTypeExpNonrigid :: TypeExp (ExpBase (NoInfo :: Type -> Type) VName) VName -> TermTypeM (TypeExp Exp VName, ResType, [VName])
- Language.Futhark.TypeChecker.Terms.Monad: constrain :: VName -> Constraint -> TermTypeM ()
- Language.Futhark.TypeChecker.Terms.Monad: data Checking
- Language.Futhark.TypeChecker.Terms.Monad: data Inferred t
- Language.Futhark.TypeChecker.Terms.Monad: data SizeSource
- Language.Futhark.TypeChecker.Terms.Monad: data TermEnv
- Language.Futhark.TypeChecker.Terms.Monad: data TermScope
- Language.Futhark.TypeChecker.Terms.Monad: data TermTypeM a
- Language.Futhark.TypeChecker.Terms.Monad: data TermTypeState
- Language.Futhark.TypeChecker.Terms.Monad: data ValBinding
- Language.Futhark.TypeChecker.Terms.Monad: expType :: Exp -> TermTypeM StructType
- Language.Futhark.TypeChecker.Terms.Monad: expTypeFully :: Exp -> TermTypeM StructType
- Language.Futhark.TypeChecker.Terms.Monad: extSize :: SrcLoc -> SizeSource -> TermTypeM (Size, Maybe VName)
- Language.Futhark.TypeChecker.Terms.Monad: incLevel :: TermTypeM a -> TermTypeM a
- Language.Futhark.TypeChecker.Terms.Monad: instance Control.Monad.Error.Class.MonadError Language.Futhark.TypeChecker.Monad.TypeError Language.Futhark.TypeChecker.Terms.Monad.TermTypeM
- Language.Futhark.TypeChecker.Terms.Monad: instance Control.Monad.Reader.Class.MonadReader Language.Futhark.TypeChecker.Terms.Monad.TermEnv Language.Futhark.TypeChecker.Terms.Monad.TermTypeM
- Language.Futhark.TypeChecker.Terms.Monad: instance Control.Monad.State.Class.MonadState Language.Futhark.TypeChecker.Terms.Monad.TermTypeState Language.Futhark.TypeChecker.Terms.Monad.TermTypeM
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Base.Applicative Language.Futhark.TypeChecker.Terms.Monad.TermTypeM
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Base.Functor Language.Futhark.TypeChecker.Terms.Monad.Inferred
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Base.Functor Language.Futhark.TypeChecker.Terms.Monad.TermTypeM
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Base.Monad Language.Futhark.TypeChecker.Terms.Monad.TermTypeM
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Base.Semigroup Language.Futhark.TypeChecker.Terms.Monad.TermScope
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Classes.Eq Language.Futhark.TypeChecker.Terms.Monad.FName
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Classes.Eq Language.Futhark.TypeChecker.Terms.Monad.SizeSource
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Classes.Ord Language.Futhark.TypeChecker.Terms.Monad.FName
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Classes.Ord Language.Futhark.TypeChecker.Terms.Monad.SizeSource
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Show.Show Language.Futhark.TypeChecker.Terms.Monad.FName
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Show.Show Language.Futhark.TypeChecker.Terms.Monad.SizeSource
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Show.Show Language.Futhark.TypeChecker.Terms.Monad.TermScope
- Language.Futhark.TypeChecker.Terms.Monad: instance GHC.Show.Show Language.Futhark.TypeChecker.Terms.Monad.ValBinding
- Language.Futhark.TypeChecker.Terms.Monad: instance Language.Futhark.TypeChecker.Monad.MonadTypeChecker Language.Futhark.TypeChecker.Terms.Monad.TermTypeM
- Language.Futhark.TypeChecker.Terms.Monad: instance Language.Futhark.TypeChecker.Unify.MonadUnify Language.Futhark.TypeChecker.Terms.Monad.TermTypeM
- Language.Futhark.TypeChecker.Terms.Monad: instance Prettyprinter.Internal.Pretty Language.Futhark.TypeChecker.Terms.Monad.Checking
- Language.Futhark.TypeChecker.Terms.Monad: isInt64 :: Exp -> Maybe Int64
- Language.Futhark.TypeChecker.Terms.Monad: localScope :: (TermScope -> TermScope) -> TermTypeM a -> TermTypeM a
- Language.Futhark.TypeChecker.Terms.Monad: lookupMod :: QualName VName -> TermTypeM Mod
- Language.Futhark.TypeChecker.Terms.Monad: lookupVar :: SrcLoc -> QualName VName -> TermTypeM StructType
- Language.Futhark.TypeChecker.Terms.Monad: newArrayType :: Usage -> Name -> Int -> TermTypeM (StructType, StructType)
- Language.Futhark.TypeChecker.Terms.Monad: onFailure :: Checking -> TermTypeM a -> TermTypeM a
- Language.Futhark.TypeChecker.Terms.Monad: require :: Text -> [PrimType] -> Exp -> TermTypeM Exp
- Language.Futhark.TypeChecker.Terms.Monad: runTermTypeM :: (ExpBase (NoInfo :: Type -> Type) VName -> TermTypeM Exp) -> TermTypeM a -> TypeM a
- Language.Futhark.TypeChecker.Terms.Monad: type Names = Set VName
- Language.Futhark.TypeChecker.Terms.Monad: unifies :: Text -> StructType -> Exp -> TermTypeM Exp
- Language.Futhark.TypeChecker.Terms.Monad: unusedSize :: MonadTypeChecker m => SizeBinder VName -> m a
- Language.Futhark.TypeChecker.Terms.Monad: updateTypes :: ASTMappable e => e -> TermTypeM e
- Language.Futhark.TypeChecker.Terms.Monad: withEnv :: TermEnv -> Env -> TermEnv
- Language.Futhark.TypeChecker.Terms.Pat: binding :: [Ident StructType] -> TermTypeM a -> TermTypeM a
- Language.Futhark.TypeChecker.Terms.Pat: bindingIdent :: IdentBase (NoInfo :: Type -> Type) VName StructType -> StructType -> (Ident StructType -> TermTypeM a) -> TermTypeM a
- Language.Futhark.TypeChecker.Terms.Pat: bindingParams :: [TypeParam] -> [PatBase (NoInfo :: Type -> Type) VName ParamType] -> ([Pat ParamType] -> TermTypeM a) -> TermTypeM a
- Language.Futhark.TypeChecker.Terms.Pat: bindingPat :: [SizeBinder VName] -> PatBase (NoInfo :: Type -> Type) VName (TypeBase Size u) -> StructType -> (Pat ParamType -> TermTypeM a) -> TermTypeM a
- Language.Futhark.TypeChecker.Terms.Pat: bindingSizes :: [SizeBinder VName] -> TermTypeM a -> TermTypeM a
- Language.Futhark.TypeChecker.Types: ExpSubst :: Exp -> Subst t
- Language.Futhark.TypeChecker.Types: Subst :: [TypeParam] -> t -> Subst t
- Language.Futhark.TypeChecker.Types: applySubst :: Substitutable a => TypeSubs -> a -> a
- Language.Futhark.TypeChecker.Types: checkTypeExp :: (MonadTypeChecker m, Pretty df) => (df -> m Exp) -> TypeExp df VName -> m (TypeExp Exp VName, [VName], ResRetType, Liftedness)
- Language.Futhark.TypeChecker.Types: class Substitutable a
- Language.Futhark.TypeChecker.Types: data Subst t
- Language.Futhark.TypeChecker.Types: determineSizeWitnesses :: StructType -> (Set VName, Set VName)
- Language.Futhark.TypeChecker.Types: instance GHC.Base.Functor Language.Futhark.TypeChecker.Types.Subst
- Language.Futhark.TypeChecker.Types: instance GHC.Show.Show t => GHC.Show.Show (Language.Futhark.TypeChecker.Types.Subst t)
- Language.Futhark.TypeChecker.Types: instance Language.Futhark.TypeChecker.Types.Substitutable (Language.Futhark.Prop.Pat Language.Futhark.Syntax.ParamType)
- Language.Futhark.TypeChecker.Types: instance Language.Futhark.TypeChecker.Types.Substitutable (Language.Futhark.Prop.Pat Language.Futhark.Syntax.StructType)
- Language.Futhark.TypeChecker.Types: instance Language.Futhark.TypeChecker.Types.Substitutable (Language.Futhark.Syntax.RetTypeBase Language.Futhark.Syntax.Size Language.Futhark.Core.NoUniqueness)
- Language.Futhark.TypeChecker.Types: instance Language.Futhark.TypeChecker.Types.Substitutable (Language.Futhark.Syntax.RetTypeBase Language.Futhark.Syntax.Size Language.Futhark.Core.Uniqueness)
- Language.Futhark.TypeChecker.Types: instance Language.Futhark.TypeChecker.Types.Substitutable (Language.Futhark.Syntax.TypeBase Language.Futhark.Syntax.Size Language.Futhark.Core.Uniqueness)
- Language.Futhark.TypeChecker.Types: instance Language.Futhark.TypeChecker.Types.Substitutable Language.Futhark.Prop.Exp
- Language.Futhark.TypeChecker.Types: instance Language.Futhark.TypeChecker.Types.Substitutable Language.Futhark.Syntax.ParamType
- Language.Futhark.TypeChecker.Types: instance Language.Futhark.TypeChecker.Types.Substitutable Language.Futhark.Syntax.StructType
- Language.Futhark.TypeChecker.Types: instance Language.Futhark.TypeChecker.Types.Substitutable d => Language.Futhark.TypeChecker.Types.Substitutable (Language.Futhark.Syntax.Shape d)
- Language.Futhark.TypeChecker.Types: instance Prettyprinter.Internal.Pretty t => Prettyprinter.Internal.Pretty (Language.Futhark.TypeChecker.Types.Subst t)
- Language.Futhark.TypeChecker.Types: mustBeExplicitInBinding :: StructType -> Set VName
- Language.Futhark.TypeChecker.Types: mustBeExplicitInType :: StructType -> Set VName
- Language.Futhark.TypeChecker.Types: renameRetType :: MonadTypeChecker m => ResRetType -> m ResRetType
- Language.Futhark.TypeChecker.Types: substFromAbbr :: TypeBinding -> Subst StructRetType
- Language.Futhark.TypeChecker.Types: substTypesAny :: Monoid u => (VName -> Maybe (Subst (RetTypeBase Size u))) -> TypeBase Size u -> TypeBase Size u
- Language.Futhark.TypeChecker.Types: type TypeSubs = VName -> Maybe Subst StructRetType
- Language.Futhark.TypeChecker.Types: typeParamToArg :: TypeParam -> StructTypeArg
- Language.Futhark.TypeChecker.Unify: Constraint :: StructRetType -> Usage -> Constraint
- Language.Futhark.TypeChecker.Unify: Equality :: Usage -> Constraint
- Language.Futhark.TypeChecker.Unify: HasConstrs :: Liftedness -> Map Name [StructType] -> Usage -> Constraint
- Language.Futhark.TypeChecker.Unify: HasFields :: Liftedness -> Map Name StructType -> Usage -> Constraint
- Language.Futhark.TypeChecker.Unify: NoConstraint :: Liftedness -> Usage -> Constraint
- Language.Futhark.TypeChecker.Unify: Nonrigid :: Rigidity
- Language.Futhark.TypeChecker.Unify: Overloaded :: [PrimType] -> Usage -> Constraint
- Language.Futhark.TypeChecker.Unify: ParamSize :: Loc -> Constraint
- Language.Futhark.TypeChecker.Unify: ParamType :: Liftedness -> Loc -> Constraint
- Language.Futhark.TypeChecker.Unify: Rigid :: RigidSource -> Rigidity
- Language.Futhark.TypeChecker.Unify: RigidArg :: Maybe (QualName VName) -> Text -> RigidSource
- Language.Futhark.TypeChecker.Unify: RigidCond :: StructType -> StructType -> RigidSource
- Language.Futhark.TypeChecker.Unify: RigidLoop :: RigidSource
- Language.Futhark.TypeChecker.Unify: RigidOutOfScope :: Loc -> VName -> RigidSource
- Language.Futhark.TypeChecker.Unify: RigidRange :: RigidSource
- Language.Futhark.TypeChecker.Unify: RigidRet :: Maybe (QualName VName) -> RigidSource
- Language.Futhark.TypeChecker.Unify: RigidSlice :: Maybe Size -> Text -> RigidSource
- Language.Futhark.TypeChecker.Unify: RigidUnify :: RigidSource
- Language.Futhark.TypeChecker.Unify: Size :: Maybe Exp -> Usage -> Constraint
- Language.Futhark.TypeChecker.Unify: UnknownSize :: Loc -> RigidSource -> Constraint
- Language.Futhark.TypeChecker.Unify: Usage :: Maybe Text -> Loc -> Usage
- Language.Futhark.TypeChecker.Unify: arrayElemType :: (MonadUnify m, Pretty (Shape dim), Pretty u) => Usage -> Text -> TypeBase dim u -> m ()
- Language.Futhark.TypeChecker.Unify: class Monad m => MonadUnify (m :: Type -> Type)
- Language.Futhark.TypeChecker.Unify: curLevel :: MonadUnify m => m Level
- Language.Futhark.TypeChecker.Unify: data BreadCrumbs
- Language.Futhark.TypeChecker.Unify: data Constraint
- Language.Futhark.TypeChecker.Unify: data RigidSource
- Language.Futhark.TypeChecker.Unify: data Rigidity
- Language.Futhark.TypeChecker.Unify: data Usage
- Language.Futhark.TypeChecker.Unify: dimNotes :: (Located a, MonadUnify m) => a -> Exp -> m Notes
- Language.Futhark.TypeChecker.Unify: doUnification :: Loc -> [TypeParam] -> [TypeParam] -> StructType -> StructType -> Either TypeError StructType
- Language.Futhark.TypeChecker.Unify: equalityType :: (MonadUnify m, Pretty (Shape dim), Pretty u) => Usage -> TypeBase dim u -> m ()
- Language.Futhark.TypeChecker.Unify: getConstraints :: MonadUnify m => m Constraints
- Language.Futhark.TypeChecker.Unify: hasNoBreadCrumbs :: BreadCrumbs -> Bool
- Language.Futhark.TypeChecker.Unify: instance Control.Monad.Error.Class.MonadError Language.Futhark.TypeChecker.Monad.TypeError Language.Futhark.TypeChecker.Unify.UnifyM
- Language.Futhark.TypeChecker.Unify: instance Control.Monad.State.Class.MonadState Language.Futhark.TypeChecker.Unify.UnifyMState Language.Futhark.TypeChecker.Unify.UnifyM
- Language.Futhark.TypeChecker.Unify: instance Data.Loc.Located Language.Futhark.TypeChecker.Unify.Constraint
- Language.Futhark.TypeChecker.Unify: instance Data.Loc.Located Language.Futhark.TypeChecker.Unify.Usage
- Language.Futhark.TypeChecker.Unify: instance GHC.Base.Applicative Language.Futhark.TypeChecker.Unify.UnifyM
- Language.Futhark.TypeChecker.Unify: instance GHC.Base.Functor Language.Futhark.TypeChecker.Unify.UnifyM
- Language.Futhark.TypeChecker.Unify: instance GHC.Base.Monad Language.Futhark.TypeChecker.Unify.UnifyM
- Language.Futhark.TypeChecker.Unify: instance GHC.Classes.Eq Language.Futhark.TypeChecker.Unify.RigidSource
- Language.Futhark.TypeChecker.Unify: instance GHC.Classes.Eq Language.Futhark.TypeChecker.Unify.Rigidity
- Language.Futhark.TypeChecker.Unify: instance GHC.Classes.Ord Language.Futhark.TypeChecker.Unify.RigidSource
- Language.Futhark.TypeChecker.Unify: instance GHC.Classes.Ord Language.Futhark.TypeChecker.Unify.Rigidity
- Language.Futhark.TypeChecker.Unify: instance GHC.Show.Show Language.Futhark.TypeChecker.Unify.Constraint
- Language.Futhark.TypeChecker.Unify: instance GHC.Show.Show Language.Futhark.TypeChecker.Unify.RigidSource
- Language.Futhark.TypeChecker.Unify: instance GHC.Show.Show Language.Futhark.TypeChecker.Unify.Rigidity
- Language.Futhark.TypeChecker.Unify: instance GHC.Show.Show Language.Futhark.TypeChecker.Unify.Usage
- Language.Futhark.TypeChecker.Unify: instance Language.Futhark.TypeChecker.Unify.MonadUnify Language.Futhark.TypeChecker.Unify.UnifyM
- Language.Futhark.TypeChecker.Unify: instance Prettyprinter.Internal.Pretty Language.Futhark.TypeChecker.Unify.BreadCrumb
- Language.Futhark.TypeChecker.Unify: instance Prettyprinter.Internal.Pretty Language.Futhark.TypeChecker.Unify.BreadCrumbs
- Language.Futhark.TypeChecker.Unify: instance Prettyprinter.Internal.Pretty Language.Futhark.TypeChecker.Unify.Usage
- Language.Futhark.TypeChecker.Unify: matchError :: (MonadUnify m, Located loc) => loc -> Notes -> BreadCrumbs -> StructType -> StructType -> m a
- Language.Futhark.TypeChecker.Unify: mkUsage :: Located a => a -> Text -> Usage
- Language.Futhark.TypeChecker.Unify: mkUsage' :: Located a => a -> Usage
- Language.Futhark.TypeChecker.Unify: modifyConstraints :: MonadUnify m => (Constraints -> Constraints) -> m ()
- Language.Futhark.TypeChecker.Unify: mustBeOneOf :: MonadUnify m => [PrimType] -> Usage -> StructType -> m ()
- Language.Futhark.TypeChecker.Unify: mustHaveConstr :: MonadUnify m => Usage -> Name -> StructType -> [StructType] -> m ()
- Language.Futhark.TypeChecker.Unify: mustHaveField :: MonadUnify m => Usage -> Name -> StructType -> m StructType
- Language.Futhark.TypeChecker.Unify: newDimVar :: MonadUnify m => Usage -> Rigidity -> Name -> m VName
- Language.Futhark.TypeChecker.Unify: newFlexibleDim :: MonadUnify m => Usage -> Name -> m VName
- Language.Futhark.TypeChecker.Unify: newRigidDim :: (MonadUnify m, Located a) => a -> RigidSource -> Name -> m VName
- Language.Futhark.TypeChecker.Unify: newTypeVar :: (MonadUnify m, Monoid als, Located a) => a -> Name -> m (TypeBase dim als)
- Language.Futhark.TypeChecker.Unify: noBreadCrumbs :: BreadCrumbs
- Language.Futhark.TypeChecker.Unify: normType :: MonadUnify m => StructType -> m StructType
- Language.Futhark.TypeChecker.Unify: normTypeFully :: (Substitutable a, MonadUnify m) => a -> m a
- Language.Futhark.TypeChecker.Unify: putConstraints :: MonadUnify m => Constraints -> m ()
- Language.Futhark.TypeChecker.Unify: sizeFree :: MonadUnify m => SrcLoc -> (Exp -> Maybe VName) -> TypeBase Size u -> m (TypeBase Size u, [VName])
- Language.Futhark.TypeChecker.Unify: type Constraints = Map VName (Level, Constraint)
- Language.Futhark.TypeChecker.Unify: type Level = Int
- Language.Futhark.TypeChecker.Unify: unify :: MonadUnify m => Usage -> StructType -> StructType -> m ()
- Language.Futhark.TypeChecker.Unify: unifyError :: (MonadUnify m, Located loc) => loc -> Notes -> BreadCrumbs -> Doc () -> m a
- Language.Futhark.TypeChecker.Unify: unifyMostCommon :: MonadUnify m => Usage -> StructType -> StructType -> m (StructType, [VName])
- Language.Futhark.TypeChecker.Unify: zeroOrderType :: MonadUnify m => Usage -> Text -> StructType -> m ()
- Language.Futhark.Warnings: anyWarnings :: Warnings -> Bool
- Language.Futhark.Warnings: data Warnings
- Language.Futhark.Warnings: instance GHC.Base.Monoid Language.Futhark.Warnings.Warnings
- Language.Futhark.Warnings: instance GHC.Base.Semigroup Language.Futhark.Warnings.Warnings
- Language.Futhark.Warnings: listWarnings :: Warnings -> [(Loc, Doc ())]
- Language.Futhark.Warnings: prettyWarnings :: Warnings -> Doc AnsiStyle
- Language.Futhark.Warnings: singleWarning :: Loc -> Doc () -> Warnings
- Language.Futhark.Warnings: singleWarning' :: Loc -> [Loc] -> Doc () -> Warnings
+ Futhark.AD.DerivativesTests: tests :: TestTree
+ Futhark.Analysis.AlgSimplifyTests: instance GHC.Show.Show Futhark.Analysis.AlgSimplifyTests.TestableExp
+ Futhark.Analysis.AlgSimplifyTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.Analysis.AlgSimplifyTests.TestableExp
+ Futhark.Analysis.AlgSimplifyTests: tests :: TestTree
+ Futhark.Analysis.PrimExp.TableTests: tests :: TestTree
+ Futhark.BenchTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.Bench.BenchResult
+ Futhark.BenchTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.Bench.DataResult
+ Futhark.BenchTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.Bench.RunResult
+ Futhark.BenchTests: tests :: TestTree
+ Futhark.IR.GPUTests: instance Data.String.IsString (Futhark.IR.Syntax.Body Futhark.IR.GPU.GPU)
+ Futhark.IR.GPUTests: instance Data.String.IsString (Futhark.IR.Syntax.Prog Futhark.IR.GPU.GPU)
+ Futhark.IR.GPUTests: instance Data.String.IsString (Futhark.IR.Syntax.Stm Futhark.IR.GPU.GPU)
+ Futhark.IR.MCTests: instance Data.String.IsString (Futhark.IR.Syntax.Body Futhark.IR.MC.MC)
+ Futhark.IR.MCTests: instance Data.String.IsString (Futhark.IR.Syntax.Prog Futhark.IR.MC.MC)
+ Futhark.IR.MCTests: instance Data.String.IsString (Futhark.IR.Syntax.Stm Futhark.IR.MC.MC)
+ Futhark.IR.Mem.IntervalTests: tests :: TestTree
+ Futhark.IR.Mem.IxFun.Alg: Coerce :: IxFun num -> Shape num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: Direct :: Shape num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: Expand :: num -> num -> IxFun num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: FlatIndex :: IxFun num -> FlatSlice num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: Index :: IxFun num -> Slice num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: OffsetIndex :: IxFun num -> num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: Permute :: IxFun num -> Permutation -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: Reshape :: IxFun num -> Shape num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: coerce :: IxFun num -> Shape num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: data IxFun num
+ Futhark.IR.Mem.IxFun.Alg: disjoint :: (IntegralExp num, Ord num, Enum num) => IxFun num -> IxFun num -> Bool
+ Futhark.IR.Mem.IxFun.Alg: expand :: num -> num -> IxFun num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: flatSlice :: IxFun num -> FlatSlice num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: index :: (Eq num, IntegralExp num) => IxFun num -> Indices num -> num
+ Futhark.IR.Mem.IxFun.Alg: instance GHC.Classes.Eq num => GHC.Classes.Eq (Futhark.IR.Mem.IxFun.Alg.IxFun num)
+ Futhark.IR.Mem.IxFun.Alg: instance GHC.Show.Show num => GHC.Show.Show (Futhark.IR.Mem.IxFun.Alg.IxFun num)
+ Futhark.IR.Mem.IxFun.Alg: instance Prettyprinter.Internal.Pretty num => Prettyprinter.Internal.Pretty (Futhark.IR.Mem.IxFun.Alg.IxFun num)
+ Futhark.IR.Mem.IxFun.Alg: iota :: Shape num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: offsetIndex :: IxFun num -> num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: permute :: IxFun num -> Permutation -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: reshape :: IxFun num -> Shape num -> IxFun num
+ Futhark.IR.Mem.IxFun.Alg: shape :: IntegralExp num => IxFun num -> Shape num
+ Futhark.IR.Mem.IxFun.Alg: slice :: IxFun num -> Slice num -> IxFun num
+ Futhark.IR.Mem.IxFunTests: instance Futhark.Util.IntegralExp.IntegralExp GHC.Types.Int
+ Futhark.IR.Mem.IxFunTests: tests :: TestTree
+ Futhark.IR.Mem.IxFunWrapper: coerce :: IxFun num -> Shape num -> IxFun num
+ Futhark.IR.Mem.IxFunWrapper: expand :: IntegralExp num => num -> num -> IxFun num -> IxFun num
+ Futhark.IR.Mem.IxFunWrapper: flatSlice :: IntegralExp num => IxFun num -> FlatSlice num -> IxFun num
+ Futhark.IR.Mem.IxFunWrapper: iota :: IntegralExp num => Shape num -> IxFun num
+ Futhark.IR.Mem.IxFunWrapper: permute :: IxFun num -> Permutation -> IxFun num
+ Futhark.IR.Mem.IxFunWrapper: reshape :: (Eq num, IntegralExp num) => IxFun num -> Shape num -> IxFun num
+ Futhark.IR.Mem.IxFunWrapper: slice :: (Eq num, IntegralExp num) => IxFun num -> Slice num -> IxFun num
+ Futhark.IR.Mem.IxFunWrapper: type IxFun num = (Maybe LMAD num, IxFun num)
+ Futhark.IR.Prop.RearrangeTests: instance GHC.Classes.Eq Futhark.IR.Prop.RearrangeTests.Permutation
+ Futhark.IR.Prop.RearrangeTests: instance GHC.Classes.Ord Futhark.IR.Prop.RearrangeTests.Permutation
+ Futhark.IR.Prop.RearrangeTests: instance GHC.Show.Show Futhark.IR.Prop.RearrangeTests.Permutation
+ Futhark.IR.Prop.RearrangeTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.IR.Prop.RearrangeTests.Permutation
+ Futhark.IR.Prop.RearrangeTests: tests :: TestTree
+ Futhark.IR.Prop.ReshapeTests: tests :: TestTree
+ Futhark.IR.PropTests: tests :: TestTree
+ Futhark.IR.Syntax.CoreTests: instance (Test.QuickCheck.Arbitrary.Arbitrary shape, Test.QuickCheck.Arbitrary.Arbitrary u) => Test.QuickCheck.Arbitrary.Arbitrary (Futhark.IR.Syntax.Core.TypeBase shape u)
+ Futhark.IR.Syntax.CoreTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.IR.Syntax.Core.Ident
+ Futhark.IR.Syntax.CoreTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.IR.Syntax.Core.Rank
+ Futhark.IR.Syntax.CoreTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.IR.Syntax.Core.Shape
+ Futhark.IR.Syntax.CoreTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Core.NoUniqueness
+ Futhark.IR.Syntax.CoreTests: tests :: TestTree
+ Futhark.IR.SyntaxTests: instance Data.String.IsString Futhark.IR.Syntax.Core.DeclExtType
+ Futhark.IR.SyntaxTests: instance Data.String.IsString Futhark.IR.Syntax.Core.DeclType
+ Futhark.IR.SyntaxTests: instance Data.String.IsString Futhark.IR.Syntax.Core.SubExp
+ Futhark.IR.SyntaxTests: instance Data.String.IsString Futhark.IR.Syntax.Core.Type
+ Futhark.IR.SyntaxTests: instance Data.String.IsString Futhark.IR.Syntax.SubExpRes
+ Futhark.IR.SyntaxTests: instance Data.String.IsString Language.Futhark.Core.VName
+ Futhark.IR.SyntaxTests: parseString :: String -> (FilePath -> Text -> Either Text a) -> String -> a
+ Futhark.Internalise.TypesValuesTests: tests :: TestTree
+ Futhark.Optimise.ArrayLayout.AnalyseTests: tests :: TestTree
+ Futhark.Optimise.ArrayLayout.LayoutTests: tests :: TestTree
+ Futhark.Optimise.ArrayLayoutTests: tests :: TestTree
+ Futhark.Optimise.MemoryBlockMerging.GreedyColoringTests: tests :: TestTree
+ Futhark.Pkg.SolveTests: instance GHC.Classes.Eq Futhark.Pkg.SolveTests.SolverRes
+ Futhark.Pkg.SolveTests: instance GHC.Show.Show Futhark.Pkg.SolveTests.SolverRes
+ Futhark.Pkg.SolveTests: tests :: TestTree
+ Futhark.ProfileTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.Profile.ProfilingEvent
+ Futhark.ProfileTests: instance Test.QuickCheck.Arbitrary.Arbitrary Futhark.Profile.ProfilingReport
+ Language.Futhark.CoreTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Core.Name
+ Language.Futhark.CoreTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Core.VName
+ Language.Futhark.ParserBenchmarks: benchmarks :: Benchmark
+ Language.Futhark.PrettyTests: tests :: TestTree
+ Language.Futhark.PrimitiveTests: arbitraryPrimValOfType :: PrimType -> Gen PrimValue
+ Language.Futhark.PrimitiveTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Primitive.FloatType
+ Language.Futhark.PrimitiveTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Primitive.FloatValue
+ Language.Futhark.PrimitiveTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Primitive.IntType
+ Language.Futhark.PrimitiveTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Primitive.IntValue
+ Language.Futhark.PrimitiveTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Primitive.PrimType
+ Language.Futhark.PrimitiveTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Primitive.PrimValue
+ Language.Futhark.PrimitiveTests: instance Test.QuickCheck.Arbitrary.Arbitrary Numeric.Half.Internal.Half
+ Language.Futhark.PrimitiveTests: tests :: TestTree
+ Language.Futhark.SemanticTests: tests :: TestTree
+ Language.Futhark.SyntaxTests: instance Data.String.IsString (Language.Futhark.Syntax.ScalarTypeBase Language.Futhark.Syntax.Size Language.Futhark.Core.NoUniqueness)
+ Language.Futhark.SyntaxTests: instance Data.String.IsString Language.Futhark.Core.VName
+ Language.Futhark.SyntaxTests: instance Data.String.IsString Language.Futhark.Prop.UncheckedExp
+ Language.Futhark.SyntaxTests: instance Data.String.IsString Language.Futhark.Prop.UncheckedTypeExp
+ Language.Futhark.SyntaxTests: instance Data.String.IsString Language.Futhark.Syntax.ResRetType
+ Language.Futhark.SyntaxTests: instance Data.String.IsString Language.Futhark.Syntax.StructRetType
+ Language.Futhark.SyntaxTests: instance Data.String.IsString Language.Futhark.Syntax.StructType
+ Language.Futhark.SyntaxTests: instance Data.String.IsString v => Data.String.IsString (Language.Futhark.Syntax.QualName v)
+ Language.Futhark.SyntaxTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Core.Uniqueness
+ Language.Futhark.SyntaxTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Syntax.BinOp
+ Language.Futhark.SyntaxTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Syntax.PrimType
+ Language.Futhark.SyntaxTests: instance Test.QuickCheck.Arbitrary.Arbitrary Language.Futhark.Syntax.PrimValue
+ Language.Futhark.SyntaxTests: tests :: TestTree
+ Language.Futhark.TypeChecker.TypesTests: tests :: TestTree
+ Language.Futhark.TypeCheckerTests: tests :: TestTree
Files
- CHANGELOG.md +41/−0
- docs/c-api.rst +7/−5
- docs/man/futhark-profile.rst +21/−19
- docs/man/futhark-test.rst +19/−6
- futhark.cabal +28/−8
- prelude/math.fut +12/−12
- rts/c/atomics16.h +6/−6
- rts/c/atomics64.h +4/−4
- rts/c/backends/cuda.h +36/−17
- rts/c/backends/hip.h +30/−16
- rts/c/backends/opencl.h +29/−17
- rts/c/context.h +10/−3
- rts/c/context_prototypes.h +6/−3
- rts/c/copy.h +4/−2
- rts/c/event_list.h +120/−6
- rts/c/gpu.h +41/−41
- rts/c/scalar.h +28/−19
- rts/c/scalar_f16.h +10/−10
- rts/c/uniform.h +2/−3
- rts/python/scalar.py +12/−18
- src-testing/Futhark/AD/DerivativesTests.hs +52/−0
- src-testing/Futhark/Analysis/AlgSimplifyTests.hs +90/−0
- src-testing/Futhark/Analysis/PrimExp/TableTests.hs +257/−0
- src-testing/Futhark/BenchTests.hs +48/−0
- src-testing/Futhark/IR/GPUTests.hs +20/−0
- src-testing/Futhark/IR/MCTests.hs +20/−0
- src-testing/Futhark/IR/Mem/IntervalTests.hs +68/−0
- src-testing/Futhark/IR/Mem/IxFun/Alg.hs +176/−0
- src-testing/Futhark/IR/Mem/IxFunTests.hs +571/−0
- src-testing/Futhark/IR/Mem/IxFunWrapper.hs +72/−0
- src-testing/Futhark/IR/Prop/RearrangeTests.hs +54/−0
- src-testing/Futhark/IR/Prop/ReshapeTests.hs +236/−0
- src-testing/Futhark/IR/PropTests.hs +18/−0
- src-testing/Futhark/IR/Syntax/CoreTests.hs +100/−0
- src-testing/Futhark/IR/SyntaxTests.hs +33/−0
- src-testing/Futhark/Internalise/TypesValuesTests.hs +170/−0
- src-testing/Futhark/Optimise/ArrayLayout/AnalyseTests.hs +241/−0
- src-testing/Futhark/Optimise/ArrayLayout/LayoutTests.hs +163/−0
- src-testing/Futhark/Optimise/ArrayLayoutTests.hs +15/−0
- src-testing/Futhark/Optimise/MemoryBlockMerging/GreedyColoringTests.hs +80/−0
- src-testing/Futhark/Pkg/SolveTests.hs +142/−0
- src-testing/Futhark/ProfileTests.hs +23/−0
- src-testing/Language/Futhark/CoreTests.hs +13/−0
- src-testing/Language/Futhark/ParserBenchmarks.hs +23/−0
- src-testing/Language/Futhark/PrettyTests.hs +35/−0
- src-testing/Language/Futhark/PrimitiveTests.hs +76/−0
- src-testing/Language/Futhark/SemanticTests.hs +24/−0
- src-testing/Language/Futhark/SyntaxTests.hs +211/−0
- src-testing/Language/Futhark/TypeChecker/TypesTests.hs +185/−0
- src-testing/Language/Futhark/TypeCheckerTests.hs +11/−0
- src-testing/futhark_benchmarks.hs +10/−0
- src-testing/futhark_tests.hs +44/−0
- src/Futhark/AD/Derivatives.hs +0/−12
- src/Futhark/AD/Rev.hs +8/−1
- src/Futhark/Analysis/AccessPattern.hs +2/−3
- src/Futhark/Analysis/Alias.hs +3/−3
- src/Futhark/Analysis/LastUse.hs +1/−1
- src/Futhark/Analysis/PrimExp/Convert.hs +1/−1
- src/Futhark/Builder/Class.hs +16/−9
- src/Futhark/CLI/Doc.hs +4/−1
- src/Futhark/CLI/Misc.hs +1/−1
- src/Futhark/CLI/Profile.hs +6/−3
- src/Futhark/CodeGen/Backends/GPU.hs +24/−11
- src/Futhark/CodeGen/Backends/GenericC/Code.hs +7/−7
- src/Futhark/CodeGen/Backends/GenericC/Monad.hs +34/−2
- src/Futhark/CodeGen/Backends/GenericPython.hs +6/−5
- src/Futhark/CodeGen/Backends/MulticoreC.hs +3/−1
- src/Futhark/CodeGen/Backends/MulticoreISPC.hs +2/−11
- src/Futhark/CodeGen/Backends/SimpleRep.hs +2/−2
- src/Futhark/CodeGen/ImpCode.hs +36/−16
- src/Futhark/CodeGen/ImpCode/Multicore.hs +0/−1
- src/Futhark/CodeGen/ImpGen.hs +52/−20
- src/Futhark/CodeGen/ImpGen/GPU/Base.hs +39/−34
- src/Futhark/CodeGen/ImpGen/GPU/Block.hs +4/−0
- src/Futhark/CodeGen/ImpGen/GPU/ToOpenCL.hs +3/−4
- src/Futhark/CodeGen/ImpGen/Multicore.hs +6/−3
- src/Futhark/CodeGen/ImpGen/Multicore/Base.hs +18/−15
- src/Futhark/CodeGen/ImpGen/Multicore/SegScan.hs +3/−1
- src/Futhark/Compiler/Program.hs +1/−1
- src/Futhark/IR/Aliases.hs +2/−2
- src/Futhark/IR/Mem/Simplify.hs +1/−1
- src/Futhark/IR/Parse.hs +41/−17
- src/Futhark/IR/Pretty.hs +18/−7
- src/Futhark/IR/Prop.hs +9/−3
- src/Futhark/IR/Prop/Names.hs +2/−2
- src/Futhark/IR/Prop/Types.hs +6/−0
- src/Futhark/IR/Rephrase.hs +2/−2
- src/Futhark/IR/Syntax.hs +41/−7
- src/Futhark/IR/Syntax/Core.hs +40/−0
- src/Futhark/IR/Traversals.hs +5/−5
- src/Futhark/IR/TypeCheck.hs +4/−2
- src/Futhark/Internalise/AccurateSizes.hs +13/−20
- src/Futhark/Internalise/Defunctionalise.hs +6/−6
- src/Futhark/Internalise/Exps.hs +147/−163
- src/Futhark/Internalise/FullNormalise.hs +2/−2
- src/Futhark/Internalise/Lambdas.hs +0/−1
- src/Futhark/Internalise/Monad.hs +19/−8
- src/Futhark/LSP/Tool.hs +1/−1
- src/Futhark/Optimise/ArrayLayout/Layout.hs +4/−4
- src/Futhark/Optimise/ArrayLayout/Transform.hs +25/−16
- src/Futhark/Optimise/ArrayShortCircuiting.hs +2/−2
- src/Futhark/Optimise/ArrayShortCircuiting/ArrayCoalescing.hs +2/−5
- src/Futhark/Optimise/ArrayShortCircuiting/TopdownAnalysis.hs +1/−1
- src/Futhark/Optimise/BlkRegTiling.hs +0/−1
- src/Futhark/Optimise/CSE.hs +8/−15
- src/Futhark/Optimise/Fusion.hs +17/−8
- src/Futhark/Optimise/Fusion/TryFusion.hs +4/−0
- src/Futhark/Optimise/InliningDeadFun.hs +33/−34
- src/Futhark/Optimise/MergeGPUBodies.hs +10/−12
- src/Futhark/Optimise/ReduceDeviceSyncs.hs +8/−9
- src/Futhark/Optimise/Simplify/Engine.hs +6/−6
- src/Futhark/Optimise/Simplify/Rep.hs +2/−2
- src/Futhark/Optimise/Simplify/Rules.hs +6/−11
- src/Futhark/Optimise/Simplify/Rules/BasicOp.hs +9/−11
- src/Futhark/Optimise/Simplify/Rules/Match.hs +2/−2
- src/Futhark/Optimise/Simplify/Rules/Simple.hs +1/−1
- src/Futhark/Pass/ExplicitAllocations.hs +12/−5
- src/Futhark/Pass/ExtractKernels.hs +12/−8
- src/Futhark/Pass/ExtractKernels/DistributeNests.hs +13/−13
- src/Futhark/Pkg/Types.hs +1/−1
- src/Futhark/Profile.hs +16/−7
- src/Futhark/Script.hs +12/−7
- src/Futhark/Transform/Rename.hs +2/−2
- src/Futhark/Transform/Substitute.hs +2/−1
- src/Language/Futhark/Core.hs +15/−0
- src/Language/Futhark/Interpreter.hs +24/−20
- src/Language/Futhark/Interpreter/AD.hs +0/−1
- src/Language/Futhark/Primitive.hs +30/−54
- src/Language/Futhark/Prop.hs +0/−16
- src/Language/Futhark/Syntax.hs +1/−0
- src/Language/Futhark/TypeChecker/Consumption.hs +18/−9
- unittests/Futhark/AD/DerivativesTests.hs +0/−52
- unittests/Futhark/Analysis/AlgSimplifyTests.hs +0/−90
- unittests/Futhark/Analysis/PrimExp/TableTests.hs +0/−257
- unittests/Futhark/BenchTests.hs +0/−48
- unittests/Futhark/IR/GPUTests.hs +0/−20
- unittests/Futhark/IR/MCTests.hs +0/−20
- unittests/Futhark/IR/Mem/IntervalTests.hs +0/−68
- unittests/Futhark/IR/Mem/IxFun/Alg.hs +0/−176
- unittests/Futhark/IR/Mem/IxFunTests.hs +0/−571
- unittests/Futhark/IR/Mem/IxFunWrapper.hs +0/−72
- unittests/Futhark/IR/Prop/RearrangeTests.hs +0/−54
- unittests/Futhark/IR/Prop/ReshapeTests.hs +0/−236
- unittests/Futhark/IR/PropTests.hs +0/−18
- unittests/Futhark/IR/Syntax/CoreTests.hs +0/−70
- unittests/Futhark/IR/SyntaxTests.hs +0/−33
- unittests/Futhark/Internalise/TypesValuesTests.hs +0/−170
- unittests/Futhark/Optimise/ArrayLayout/AnalyseTests.hs +0/−241
- unittests/Futhark/Optimise/ArrayLayout/LayoutTests.hs +0/−163
- unittests/Futhark/Optimise/ArrayLayoutTests.hs +0/−15
- unittests/Futhark/Optimise/MemoryBlockMerging/GreedyColoringTests.hs +0/−80
- unittests/Futhark/Pkg/SolveTests.hs +0/−142
- unittests/Futhark/ProfileTests.hs +0/−23
- unittests/Language/Futhark/CoreTests.hs +0/−13
- unittests/Language/Futhark/PrimitiveTests.hs +0/−76
- unittests/Language/Futhark/SemanticTests.hs +0/−24
- unittests/Language/Futhark/SyntaxTests.hs +0/−208
- unittests/Language/Futhark/TypeChecker/TypesTests.hs +0/−185
- unittests/Language/Futhark/TypeCheckerTests.hs +0/−11
- unittests/futhark_tests.hs +0/−42
CHANGELOG.md view
@@ -5,6 +5,47 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). +## [0.25.32]++### Added++* `futhark doc` now prints warnings about errors in doc comments (mostly+ references to unknown names).++* FutharkScript now permits chained `let` without `in`, just as in Futhark.++* `futhark pkg` now allows the `~` character in package paths.++* `cuda` backend: explicitly support CC 8.9, 9.0, 10.0, 10.1, and 12.0.++* Profiling now provides source locations for the profiled events. Some things+ are not yet accurately tracked, and only the static location is reported+ (i.e., no full call stack).++* The AD transformation is now more diligent about propagating attributes from+ SOACs in the primal code to SOACs in the differentiated code.++### Fixed++* `f64` atomics on NVIDIA GPUs with less than CC 6.0 (Maxwell and older).++* Infinite loop in fusion (#2276).++* Rare compiler crash during internalisation code that does size coercions on+ opaque size-lifted types.++* Missing fusion inside reduction and scan operators (#2283).++* Incorrect aliasing for memory blocks could cause some optimisations to be+ misapplied. (#2288)++* `to_bits`/`from_bits` not handled by AD (#2292).++* For GPU backends, incorrect code generation for accumulator updates (produced+ by AD) for thread-local arrays (#2294).++* Missing consumption check in the termination condition for `while` loops (#2300).+ ## [0.25.31] ### Added
docs/c-api.rst view
@@ -206,12 +206,14 @@ .. c:function:: char *futhark_context_report(struct futhark_context *ctx) Produce a C string encoding a JSON object with debug and profiling- information collected during program runtime. It is the caller's- responsibility to free the returned string. It is likely to only- contain interesting information if+ information collected during program runtime. It is the caller's+ responsibility to free the returned string. The format of the string is+ intentionally undocumented and is not a stable format, but can be passed to+ ``futhark profile`` to produce human-readable information. The report is+ likely to only contain interesting information if :c:func:`futhark_context_config_set_debugging` or- :c:func:`futhark_context_config_set_profiling` has been called- previously. Returns ``NULL`` on failure.+ :c:func:`futhark_context_config_set_profiling` has been called previously.+ Returns ``NULL`` on failure. .. c:function:: int futhark_context_clear_caches(struct futhark_context *ctx)
docs/man/futhark-profile.rst view
@@ -14,13 +14,13 @@ DESCRIPTION =========== -This tool produces human-readable profiling information based on-information collected with :ref:`futhark bench<futhark-bench(1)>`.-Futhark has only rudimentary support for profiling. While the system-can collect information about the run-time behaviour of the program,-there is currently no automatic way to connect the information to the-program source code. However, the collected information can still be-useful for estimating the source of inefficiencies.+This tool produces human-readable profiling information based on information+collected with :ref:`futhark bench<futhark-bench(1)>`. Futhark has basic support+for profiling. The system can collect information about the run-time behaviour+of the program, and connects it as best it is able to the program source code.+This works best for the GPU backends, and not at all for the sequential+backends. The collected information can then be used to estimate the source of+inefficiencies. USAGE =====@@ -49,17 +49,19 @@ Supposing a dataset ``foo``, ``futhark profile`` will produce the following files in the top level directory. -* ``foo.log``: the running log produced during execution. Contains- many details on dynamic behaviour, depending on the exact backend.+* ``foo.log``: the running log produced during execution. Contains many details+ on dynamic behaviour, depending on the exact backend. -* ``foo.summary``: a summary of memory usage and cost centres. For- the GPU backends, the cost centres are kernel executions and memory- copies.+* ``foo.summary``: a summary of memory usage and cost centres. For the GPU+ backends, the cost centres are kernel executions and memory copies. -* ``foo.timeline``: a list of all recorded profiling events, in the- order in which they occurred, along with their runtime and other- available information+* ``foo.timeline``: a list of all recorded profiling events, in the order in+ which they occurred, along with their runtime and other available information,+ most importantly the source locations. +The log file is often too verbose to be useful, but the summary and timeline+should be inspected, even if the latter is sometimes fairly large.+ Technicalities -------------- @@ -73,10 +75,10 @@ Raw reports ----------- -Alternatively, the JSON can also contain a raw profiling report as-produced by the C API function ``futhark_context_report()``. A-directory is still created, but it will only contain a single set of-files, and it will not contain a log.+Alternatively, the JSON file passed to ``futhark profile`` may also be a raw+profiling report as produced by the C API function ``futhark_context_report()``.+A directory is still created, but it will only contain a single set of files,+and it will not contain a log. EXAMPLES ========
docs/man/futhark-test.rst view
@@ -37,7 +37,8 @@ [tags { tags... }] [entry: names...]- ["name..."] [compiled|nobench|random|script] input ({ values... } | @ filename)+ ["name..."] [ tags... ]+ random input { types ... } | script input { ... } | input ({ values... } | @ filename) output { values... } | auto output | error: regex If a test case begins with a quoted string, that string is reported as@@ -95,11 +96,6 @@ This is used to test the type checker. -Tuple syntax is not supported when specifying input and output values.-Instead, you can write an N-tuple as its constituent N values. Beware-of syntax errors in the values - the errors reported by-``futhark test`` are very poor.- An optional tags specification is permitted in the first test block. This section can contain arbitrary tags that classify the benchmark:: @@ -122,6 +118,23 @@ For many usage examples, see the ``tests`` directory in the Futhark source directory. A simple example can be found in ``EXAMPLES`` below.++VALUES+------++The notation used for specifying values in ``input`` and ``output`` blocks is a+small subset of Futhark syntax.++Tuple syntax is not supported. Instead, you can write an *N*-tuple as its+constituent *N* values. Beware of syntax errors in the values - the errors+reported by ``futhark test`` are very poor. When comparing the output of an+entry point with the values in an ``output`` block, the tuple is implicitly+unpacked and compared to the expected values.++The element type of an array value is determined by the first primitive element+of the array. You therefore only need to provide a type suffix on the first+element. If no suffix is provided, integer arrays have element type ``i32`` and+decimal arrays have type ``f64``. OPTIONS =======
futhark.cabal view
@@ -1,6 +1,6 @@ cabal-version: 2.4 name: futhark-version: 0.25.31+version: 0.25.32 synopsis: An optimising compiler for a functional, array-oriented language. description: Futhark is a small programming language designed to be compiled to@@ -466,7 +466,7 @@ , file-embed >=0.0.14.0 , filepath >=1.4.1.1 , free >=5.1.10- , futhark-data >= 1.1.1.0+ , futhark-data >= 1.1.2.0 , futhark-server >= 1.2.3.0 , futhark-manifest >= 1.5.0.0 , githash >=0.1.6.1@@ -506,12 +506,10 @@ ghc-options: -threaded -rtsopts "-with-rtsopts=-maxN16 -qg1 -A16M" build-depends: base, futhark -test-suite unit+library futhark-testing import: common- type: exitcode-stdio-1.0- main-is: futhark_tests.hs- hs-source-dirs: unittests- other-modules:+ hs-source-dirs: src-testing+ exposed-modules: Futhark.AD.DerivativesTests Futhark.Analysis.AlgSimplifyTests Futhark.Analysis.PrimExp.TableTests@@ -535,6 +533,8 @@ Futhark.Pkg.SolveTests Futhark.ProfileTests Language.Futhark.CoreTests+ Language.Futhark.PrettyTests+ Language.Futhark.ParserBenchmarks Language.Futhark.PrimitiveTests Language.Futhark.SemanticTests Language.Futhark.SyntaxTests@@ -542,13 +542,33 @@ Language.Futhark.TypeCheckerTests build-depends: QuickCheck >=2.8- , mtl >=2.2.1+ , criterion+ , mtl >=2.2.1 , base , containers , free , futhark , megaparsec+ , srcloc , tasty , tasty-hunit , tasty-quickcheck , text++test-suite unit+ import: common+ type: exitcode-stdio-1.0+ main-is: src-testing/futhark_tests.hs+ build-depends:+ base+ , futhark-testing+ , tasty++benchmark benchmarks+ import: common+ type: exitcode-stdio-1.0+ main-is: src-testing/futhark_benchmarks.hs+ build-depends:+ base+ , criterion+ , futhark-testing
prelude/math.fut view
@@ -81,12 +81,12 @@ module type integral = { include numeric - -- | Like `/`@term, but rounds towards zero. This only matters when- -- one of the operands is negative. May be more efficient.+ -- | Like `/`, but rounds towards zero. This only matters when one of the+ -- operands is negative. May be more efficient. val (//) : t -> t -> t - -- | Like `%`@term, but rounds towards zero. This only matters when- -- one of the operands is negative. May be more efficient.+ -- | Like `%`, but rounds towards zero. This only matters when one of the+ -- operands is negative. May be more efficient. val (%%) : t -> t -> t -- | Bitwise and.@@ -204,7 +204,7 @@ -- | The true Gamma function. val gamma : t -> t - -- | The natural logarithm of the absolute value of `gamma`@term.+ -- | The natural logarithm of the absolute value of `gamma`. val lgamma : t -> t -- | The error function.@@ -245,7 +245,7 @@ -- | Computes `a*b+c`. Depending on the compiler backend, this may -- be fused into a single operation that is faster but less- -- accurate. Do not confuse it with `fma`@term.+ -- accurate. Do not confuse it with `fma`. val mad : (a: t) -> (b: t) -> (c: t) -> t -- | Computes `a*b+c`, with `a*b` being rounded with infinite@@ -1036,8 +1036,8 @@ def ldexp x y = intrinsics.ldexp64 (x, y) def copysign x y = intrinsics.copysign64 (x, y) - def to_bits (x: f64) : u64 = u64m.i64 (intrinsics.to_bits64 x)- def from_bits (x: u64) : f64 = intrinsics.from_bits64 (intrinsics.sign_i64 x)+ def to_bits (x: f64) : u64 = u64m.i64 (intrinsics.fptobits_f64_i64 x)+ def from_bits (x: u64) : f64 = intrinsics.bitstofp_i64_f64 (intrinsics.sign_i64 x) def num_bits = 64i32 def get_bit (bit: i32) (x: t) = u64m.get_bit bit (to_bits x)@@ -1161,8 +1161,8 @@ def ldexp x y = intrinsics.ldexp32 (x, y) def copysign x y = intrinsics.copysign32 (x, y) - def to_bits (x: f32) : u32 = u32m.i32 (intrinsics.to_bits32 x)- def from_bits (x: u32) : f32 = intrinsics.from_bits32 (intrinsics.sign_i32 x)+ def to_bits (x: f32) : u32 = u32m.i32 (intrinsics.fptobits_f32_i32 x)+ def from_bits (x: u32) : f32 = intrinsics.bitstofp_i32_f32 (intrinsics.sign_i32 x) def num_bits = 32i32 def get_bit (bit: i32) (x: t) = u32m.get_bit bit (to_bits x)@@ -1290,8 +1290,8 @@ def ldexp x y = intrinsics.ldexp16 (x, y) def copysign x y = intrinsics.copysign16 (x, y) - def to_bits (x: f16) : u16 = u16m.i16 (intrinsics.to_bits16 x)- def from_bits (x: u16) : f16 = intrinsics.from_bits16 (intrinsics.sign_i16 x)+ def to_bits (x: f16) : u16 = u16m.i16 (intrinsics.fptobits_f16_i16 x)+ def from_bits (x: u16) : f16 = intrinsics.bitstofp_i16_f16 (intrinsics.sign_i16 x) def num_bits = 16i32 def get_bit (bit: i32) (x: t) = u16m.get_bit bit (to_bits x)
rts/c/atomics16.h view
@@ -150,13 +150,13 @@ int shift = offset * 16; int32_t mask = 0xffff << shift; int32_t old = 0;- int32_t upd = mask & ((int32_t)futrts_to_bits16(val) << shift);+ int32_t upd = mask & ((int32_t)fptobits_f16_i16(val) << shift); int32_t saw; while ((saw=atomic_cmpxchg_i32_global(p32, old, upd)) != old) { old = saw;- upd = (old & ~mask) | (int32_t)futrts_to_bits16(futrts_from_bits16((uint32_t)old >> shift) + val) << shift;+ upd = (old & ~mask) | (int32_t)fptobits_f16_i16(bitstofp_i16_f16((uint32_t)old >> shift) + val) << shift; }- return futrts_from_bits16((uint32_t)old >> shift);+ return bitstofp_i16_f16((uint32_t)old >> shift); } SCALAR_FUN_ATTR f16 atomic_fadd_f16_shared(volatile __local uint16_t *p, f16 val) {@@ -165,13 +165,13 @@ int shift = offset * 16; int32_t mask = 0xffff << shift; int32_t old = 0;- int32_t upd = mask & ((int32_t)futrts_to_bits16(val) << shift);+ int32_t upd = mask & ((int32_t)fptobits_f16_i16(val) << shift); int32_t saw; while ((saw=atomic_cmpxchg_i32_shared(p32, old, upd)) != old) { old = saw;- upd = (old & ~mask) | (int32_t)futrts_to_bits16(futrts_from_bits16((uint32_t)old >> shift) + val) << shift;+ upd = (old & ~mask) | (int32_t)fptobits_f16_i16(bitstofp_i16_f16((uint32_t)old >> shift) + val) << shift; }- return futrts_from_bits16((uint32_t)old >> shift);+ return bitstofp_i16_f16((uint32_t)old >> shift); } // End of atomics16.h
rts/c/atomics64.h view
@@ -34,7 +34,7 @@ #if defined(FUTHARK_CUDA) || defined(FUTHARK_HIP) return atomicExch((unsigned long long*)p, x); #else- return atom_xor(p, x);+ return atom_xchg(p, x); #endif } @@ -42,7 +42,7 @@ #if defined(FUTHARK_CUDA) || defined(FUTHARK_HIP) return atomicExch((unsigned long long*)p, x); #else- return atom_xor(p, x);+ return atom_xchg(p, x); #endif } @@ -103,9 +103,9 @@ union {int64_t i; double f;} ret; old.f = x; while (1) {- ret.i = atom_xchg((volatile __global int64_t*)p, (int64_t)0);+ ret.i = atomic_xchg_i64_global((volatile __global int64_t*)p, (int64_t)0); ret.f += old.f;- old.i = atom_xchg((volatile __global int64_t*)p, ret.i);+ old.i = atomic_xchg_i64_global((volatile __global int64_t*)p, ret.i); if (old.i == 0) { break; }
rts/c/backends/cuda.h view
@@ -339,7 +339,12 @@ { 7, 5, "compute_75" }, { 8, 0, "compute_80" }, { 8, 6, "compute_80" },- { 8, 7, "compute_80" }+ { 8, 7, "compute_80" },+ { 8, 9, "compute_80" },+ { 9, 0, "compute_90" },+ { 10, 0, "compute_100" },+ { 10, 1, "compute_101" },+ { 12, 0, "compute_120" } }; int major = device_query(dev, COMPUTE_CAPABILITY_MAJOR);@@ -877,13 +882,15 @@ } static int gpu_scalar_to_device(struct futhark_context* ctx,+ const char *provenance, gpu_mem dst, size_t offset, size_t size, void *src) { struct cuda_event *event = cuda_event_new(ctx); if (event != NULL) { add_event(ctx, "copy_scalar_to_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)cuda_event_report); CUDA_SUCCEED_FATAL(cuEventRecord(event->start, ctx->stream));@@ -896,13 +903,15 @@ } static int gpu_scalar_from_device(struct futhark_context* ctx,+ const char *provenance, void *dst, gpu_mem src, size_t offset, size_t size) { struct cuda_event *event = cuda_event_new(ctx); if (event != NULL) { add_event(ctx, "copy_scalar_from_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)cuda_event_report); CUDA_SUCCEED_FATAL(cuEventRecord(event->start, ctx->stream));@@ -915,6 +924,7 @@ } static int gpu_memcpy(struct futhark_context* ctx,+ const char *provenance, gpu_mem dst, int64_t dst_offset, gpu_mem src, int64_t src_offset, int64_t nbytes) {@@ -922,7 +932,8 @@ if (event != NULL) { add_event(ctx, "copy_dev_to_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)cuda_event_report); CUDA_SUCCEED_FATAL(cuEventRecord(event->start, ctx->stream));@@ -934,7 +945,9 @@ return FUTHARK_SUCCESS; } -static int memcpy_host2gpu(struct futhark_context* ctx, bool sync,+static int memcpy_host2gpu(struct futhark_context* ctx,+ const char *provenance,+ bool sync, gpu_mem dst, int64_t dst_offset, const unsigned char* src, int64_t src_offset, int64_t nbytes) {@@ -943,7 +956,8 @@ if (event != NULL) { add_event(ctx, "copy_host_to_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)cuda_event_report); CUDA_SUCCEED_FATAL(cuEventRecord(event->start, ctx->stream));@@ -962,7 +976,9 @@ return FUTHARK_SUCCESS; } -static int memcpy_gpu2host(struct futhark_context* ctx, bool sync,+static int memcpy_gpu2host(struct futhark_context* ctx,+ const char *provenance,+ bool sync, unsigned char* dst, int64_t dst_offset, gpu_mem src, int64_t src_offset, int64_t nbytes) {@@ -971,7 +987,8 @@ if (event != NULL) { add_event(ctx, "copy_dev_to_host",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)cuda_event_report); CUDA_SUCCEED_FATAL(cuEventRecord(event->start, ctx->stream));@@ -996,7 +1013,8 @@ } static int gpu_launch_kernel(struct futhark_context* ctx,- gpu_kernel kernel, const char *name,+ gpu_kernel kernel,+ const char *name, const char *provenance, const int32_t grid[3], const int32_t block[3], unsigned int shared_mem_bytes,@@ -1020,16 +1038,17 @@ if (event != NULL) { CUDA_SUCCEED_FATAL(cuEventRecord(event->start, ctx->stream));++ struct kvs *kvs = kvs_new();+ kvs_printf(kvs, "kernel", "\"%s\"", name);+ kvs_printf(kvs, "grid", "[%d,%d,%d]", grid[0], grid[1], grid[2]);+ kvs_printf(kvs, "block", "[%d,%d,%d]", block[0], block[1], block[2]);+ kvs_printf(kvs, "shared memory", "%d", shared_mem_bytes);+ add_event(ctx, name,- msgprintf("Kernel %s with\n"- " grid=(%d,%d,%d)\n"- " block=(%d,%d,%d)\n"- " shared memory=%d",- name,- grid[0], grid[1], grid[2],- block[0], block[1], block[2],- shared_mem_bytes),+ provenance,+ kvs, event, (event_report_fn)cuda_event_report); }
rts/c/backends/hip.h view
@@ -720,13 +720,15 @@ } static int gpu_scalar_to_device(struct futhark_context* ctx,+ const char *provenance, gpu_mem dst, size_t offset, size_t size, void *src) { struct hip_event *event = hip_event_new(ctx); if (event != NULL) { add_event(ctx, "copy_scalar_to_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)hip_event_report); HIP_SUCCEED_FATAL(hipEventRecord(event->start, ctx->stream));@@ -739,13 +741,15 @@ } static int gpu_scalar_from_device(struct futhark_context* ctx,+ const char *provenance, void *dst, gpu_mem src, size_t offset, size_t size) { struct hip_event *event = hip_event_new(ctx); if (event != NULL) { add_event(ctx, "copy_scalar_from_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)hip_event_report); HIP_SUCCEED_FATAL(hipEventRecord(event->start, ctx->stream));@@ -758,6 +762,7 @@ } static int gpu_memcpy(struct futhark_context* ctx,+ const char *provenance, gpu_mem dst, int64_t dst_offset, gpu_mem src, int64_t src_offset, int64_t nbytes) {@@ -765,7 +770,8 @@ if (event != NULL) { add_event(ctx, "copy_dev_to_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)hip_event_report); HIP_SUCCEED_FATAL(hipEventRecord(event->start, ctx->stream));@@ -778,7 +784,9 @@ return FUTHARK_SUCCESS; } -static int memcpy_host2gpu(struct futhark_context* ctx, bool sync,+static int memcpy_host2gpu(struct futhark_context* ctx,+ const char *provenance,+ bool sync, gpu_mem dst, int64_t dst_offset, const unsigned char* src, int64_t src_offset, int64_t nbytes) {@@ -787,7 +795,8 @@ if (event != NULL) { add_event(ctx, "copy_host_to_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)hip_event_report); HIP_SUCCEED_FATAL(hipEventRecord(event->start, ctx->stream));@@ -809,7 +818,9 @@ return FUTHARK_SUCCESS; } -static int memcpy_gpu2host(struct futhark_context* ctx, bool sync,+static int memcpy_gpu2host(struct futhark_context* ctx,+ const char *provenance,+ bool sync, unsigned char* dst, int64_t dst_offset, gpu_mem src, int64_t src_offset, int64_t nbytes) {@@ -818,7 +829,8 @@ if (event != NULL) { add_event(ctx, "copy_dev_to_host",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)hip_event_report); HIP_SUCCEED_FATAL(hipEventRecord(event->start, ctx->stream));@@ -847,7 +859,8 @@ } static int gpu_launch_kernel(struct futhark_context* ctx,- gpu_kernel kernel, const char *name,+ gpu_kernel kernel,+ const char *name, const char *provenance, const int32_t grid[3], const int32_t block[3], unsigned int shared_mem_bytes,@@ -871,16 +884,17 @@ if (event != NULL) { HIP_SUCCEED_FATAL(hipEventRecord(event->start, ctx->stream));++ struct kvs *kvs = kvs_new();+ kvs_printf(kvs, "kernel", "\"%s\"", name);+ kvs_printf(kvs, "grid", "[%d,%d,%d]", grid[0], grid[1], grid[2]);+ kvs_printf(kvs, "block", "[%d,%d,%d]", block[0], block[1], block[2]);+ kvs_printf(kvs, "shared memory", "%d", shared_mem_bytes);+ add_event(ctx, name,- msgprintf("Kernel %s with\n"- " grid=(%d,%d,%d)\n"- " block=(%d,%d,%d)\n"- " shared memory=%d",- name,- grid[0], grid[1], grid[2],- block[0], block[1], block[2],- shared_mem_bytes),+ provenance,+ kvs, event, (event_report_fn)hip_event_report); }
rts/c/backends/opencl.h view
@@ -1157,13 +1157,15 @@ } static int gpu_scalar_to_device(struct futhark_context* ctx,+ const char *provenance, gpu_mem dst, size_t offset, size_t size, void *src) { cl_event* event = opencl_event_new(ctx); if (event != NULL) { add_event(ctx, "copy_scalar_to_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)opencl_event_report); }@@ -1175,13 +1177,15 @@ } static int gpu_scalar_from_device(struct futhark_context* ctx,+ const char *provenance, void *dst, gpu_mem src, size_t offset, size_t size) { cl_event* event = opencl_event_new(ctx); if (event != NULL) { add_event(ctx, "copy_scalar_from_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)opencl_event_report); }@@ -1192,7 +1196,7 @@ return 0; } -static int gpu_memcpy(struct futhark_context* ctx,+static int gpu_memcpy(struct futhark_context* ctx, const char *provenance, gpu_mem dst, int64_t dst_offset, gpu_mem src, int64_t src_offset, int64_t nbytes) {@@ -1201,7 +1205,8 @@ if (event != NULL) { add_event(ctx, "copy_dev_to_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)opencl_event_report); }@@ -1218,7 +1223,8 @@ return FUTHARK_SUCCESS; } -static int memcpy_host2gpu(struct futhark_context* ctx, bool sync,+static int memcpy_host2gpu(struct futhark_context* ctx, const char *provenance,+ bool sync, gpu_mem dst, int64_t dst_offset, const unsigned char* src, int64_t src_offset, int64_t nbytes) {@@ -1227,7 +1233,8 @@ if (event != NULL) { add_event(ctx, "copy_host_to_dev",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)opencl_event_report); }@@ -1245,7 +1252,8 @@ return FUTHARK_SUCCESS; } -static int memcpy_gpu2host(struct futhark_context* ctx, bool sync,+static int memcpy_gpu2host(struct futhark_context* ctx, const char *provenance,+ bool sync, unsigned char* dst, int64_t dst_offset, gpu_mem src, int64_t src_offset, int64_t nbytes) {@@ -1254,7 +1262,8 @@ if (event != NULL) { add_event(ctx, "copy_dev_to_host",- strdup(""),+ provenance,+ NULL, event, (event_report_fn)opencl_event_report); }@@ -1275,7 +1284,9 @@ } static int gpu_launch_kernel(struct futhark_context* ctx,- gpu_kernel kernel, const char *name,+ gpu_kernel kernel,+ const char *name,+ const char *provenance, const int32_t grid[3], const int32_t block[3], unsigned int shared_mem_bytes,@@ -1292,16 +1303,17 @@ cl_event* event = opencl_event_new(ctx); if (event != NULL) {++ struct kvs *kvs = kvs_new();+ kvs_printf(kvs, "kernel", "\"%s\"", name);+ kvs_printf(kvs, "grid", "[%d,%d,%d]", grid[0], grid[1], grid[2]);+ kvs_printf(kvs, "block", "[%d,%d,%d]", block[0], block[1], block[2]);+ kvs_printf(kvs, "shared memory", "%d", shared_mem_bytes);+ add_event(ctx, name,- msgprintf("Kernel %s with\n"- " grid=(%d,%d,%d)\n"- " block=(%d,%d,%d)\n"- " shared memory=%d",- name,- grid[0], grid[1], grid[2],- block[0], block[1], block[2],- shared_mem_bytes),+ provenance,+ kvs, event, (event_report_fn)opencl_event_report); }
rts/c/context.h view
@@ -70,13 +70,20 @@ static void add_event(struct futhark_context* ctx, const char* name,- char* description,+ const char* provenance,+ struct kvs *kvs, void* data, event_report_fn f) {+ if (provenance == NULL) {+ provenance = "unknown";+ } if (ctx->logging) {- fprintf(ctx->log, "Event: %s\n%s\n", name, description);+ fprintf(ctx->log, "Event: %s\n at: %s\n", name, provenance);+ if (kvs) {+ kvs_log(kvs, " ", ctx->log);+ } }- add_event_to_list(&ctx->event_list, name, description, data, f);+ add_event_to_list(&ctx->event_list, name, provenance, kvs, data, f); } char *futhark_context_get_error(struct futhark_context *ctx) {
rts/c/context_prototypes.h view
@@ -20,9 +20,11 @@ // Allocate memory allocated with host_alloc(). static void host_free(struct futhark_context* ctx, size_t size, const char* tag, void* mem); -// Log that a copy has occurred.+// Log that a copy has occurred. The provenance may be NULL, if we do not know+// where this came from. static void log_copy(struct futhark_context* ctx,- const char *kind, int r,+ const char *kind, const char *provenance,+ int r, int64_t dst_offset, int64_t dst_strides[r], int64_t src_offset, int64_t src_strides[r], int64_t shape[r]);@@ -43,7 +45,8 @@ static void add_event(struct futhark_context* ctx, const char* name,- char* description,+ const char* provenance,+ struct kvs *kvs, void* data, event_report_fn f);
rts/c/copy.h view
@@ -188,12 +188,14 @@ static void log_copy(struct futhark_context* ctx,- const char *kind, int r,+ const char *kind, const char *provenance,+ int r, int64_t dst_offset, int64_t dst_strides[r], int64_t src_offset, int64_t src_strides[r], int64_t shape[r]) { if (ctx->logging) { fprintf(ctx->log, "\n# Copy %s\n", kind);+ if (provenance) { fprintf(ctx->log, "At: %s\n", provenance); } fprintf(ctx->log, "Shape: "); for (int i = 0; i < r; i++) { fprintf(ctx->log, "[%ld]", (long int)shape[i]); } fprintf(ctx->log, "\n");@@ -225,7 +227,7 @@ ELEM_TYPE* dst, int64_t dst_offset, int64_t dst_strides[r], \ ELEM_TYPE *src, int64_t src_offset, int64_t src_strides[r], \ int64_t shape[r]) { \- log_copy(ctx, "CPU to CPU", r, dst_offset, dst_strides, \+ log_copy(ctx, "CPU to CPU", NULL, r, dst_offset, dst_strides, \ src_offset, src_strides, shape); \ int64_t size = 1; \ for (int i = 0; i < r; i++) { size *= shape[i]; } \
rts/c/event_list.h view
@@ -2,11 +2,114 @@ typedef int (*event_report_fn)(struct str_builder*, void*); +// A collection of key-value associations. Used to associate extra data with+// events.+struct kvs {+ // A buffer that contains all value data. Must be freed when the struct kvs is+ // no longer used.+ char *buf;++ // Size of buf in bytes.+ size_t buf_size;++ // Number of bytes used in buf.+ size_t buf_used;++ // Number of associations stored.+ size_t n;++ // Capacity of vals.+ size_t vals_capacity;++ // An array of keys.+ const char* *keys;++ // Indexes into 'buf' that contains the values as zero-terminated strings.+ size_t *vals;+};++static const size_t KVS_INIT_BUF_SIZE = 128;+static const size_t KVS_INIT_NUMKEYS = 8;++void kvs_init(struct kvs* kvs) {+ kvs->buf = malloc(KVS_INIT_BUF_SIZE);+ kvs->buf_size = KVS_INIT_BUF_SIZE;+ kvs->buf_used = 0;+ kvs->vals_capacity = KVS_INIT_NUMKEYS;+ kvs->keys = calloc(kvs->vals_capacity, sizeof(const char*));+ kvs->vals = calloc(kvs->vals_capacity, sizeof(size_t));+ kvs->n = 0;+}++struct kvs* kvs_new(void) {+ struct kvs *kvs = malloc(sizeof(struct kvs));+ kvs_init(kvs);+ return kvs;+}++void kvs_printf(struct kvs* kvs, const char* key, const char* fmt, ...) {+ va_list vl;+ va_start(vl, fmt);++ size_t needed = 1 + (size_t)vsnprintf(NULL, 0, fmt, vl);++ while (kvs->buf_used+needed > kvs->buf_size) {+ kvs->buf_size *= 2;+ kvs->buf = realloc(kvs->buf, kvs->buf_size * sizeof(const char*));+ }++ if (kvs->n == kvs->vals_capacity) {+ kvs->vals_capacity *= 2;+ kvs->vals = realloc(kvs->vals, kvs->vals_capacity * sizeof(size_t));+ kvs->keys = realloc(kvs->keys, kvs->vals_capacity * sizeof(char*));+ }++ kvs->keys[kvs->n] = key;+ kvs->vals[kvs->n] = kvs->buf_used;+ kvs->buf_used += needed;++ va_start(vl, fmt); // Must re-init.+ vsnprintf(&kvs->buf[kvs->vals[kvs->n]], needed, fmt, vl);++ kvs->n++;+}++void kvs_free(struct kvs* kvs) {+ free(kvs->vals);+ free(kvs->keys);+ free(kvs->buf);+}++// Assumes all of the values are valid JSON objects.+void kvs_json(const struct kvs* kvs, struct str_builder *sb) {+ str_builder_char(sb, '{');+ for (size_t i = 0; i < kvs->n; i++) {+ if (i != 0) {+ str_builder_str(sb, ",");+ }+ str_builder_json_str(sb, kvs->keys[i]);+ str_builder_str(sb, ":");+ str_builder_str(sb, &kvs->buf[kvs->vals[i]]);+ }+ str_builder_char(sb, '}');+}++void kvs_log(const struct kvs* kvs, const char* prefix, FILE* f) {+ for (size_t i = 0; i < kvs->n; i++) {+ fprintf(f, "%s%s: %s\n",+ prefix,+ kvs->keys[i],+ &kvs->buf[kvs->vals[i]]);+ }+}+ struct event { void* data; event_report_fn f; const char* name;- char *description;+ const char *provenance;+ // Key-value information that is also to be printed.+ struct kvs *kvs; }; struct event_list {@@ -27,7 +130,8 @@ static void add_event_to_list(struct event_list *l, const char* name,- char* description,+ const char* provenance,+ struct kvs *kvs, void* data, event_report_fn f) { if (l->num_events == l->capacity) {@@ -35,7 +139,9 @@ l->events = realloc(l->events, l->capacity * sizeof(struct event)); } l->events[l->num_events].name = name;- l->events[l->num_events].description = description;+ l->events[l->num_events].provenance =+ provenance ? provenance : "unknown";+ l->events[l->num_events].kvs = kvs; l->events[l->num_events].data = data; l->events[l->num_events].f = f; l->num_events++;@@ -50,13 +156,21 @@ } str_builder_str(sb, "{\"name\":"); str_builder_json_str(sb, l->events[i].name);- str_builder_str(sb, ",\"description\":");- str_builder_json_str(sb, l->events[i].description);- free(l->events[i].description);+ str_builder_str(sb, ",\"provenance\":");+ str_builder_json_str(sb, l->events[i].provenance); if (l->events[i].f(sb, l->events[i].data) != 0) { ret = 1; break; }++ str_builder_str(sb, ",\"details\":");+ if (l->events[i].kvs) {+ kvs_json(l->events[i].kvs, sb);+ kvs_free(l->events[i].kvs);+ } else {+ str_builder_str(sb, "{}");+ }+ str_builder(sb, "}"); } event_list_free(l);
rts/c/gpu.h view
@@ -7,21 +7,22 @@ static int gpu_free_actual(struct futhark_context *ctx, gpu_mem mem); static int gpu_alloc_actual(struct futhark_context *ctx, size_t size, gpu_mem *mem_out); int gpu_launch_kernel(struct futhark_context* ctx,- gpu_kernel kernel, const char *name,+ gpu_kernel kernel,+ const char *name, const char *provenance, const int32_t grid[3], const int32_t block[3], unsigned int shared_mem_bytes, int num_args, void* args[num_args], size_t args_sizes[num_args]);-int gpu_memcpy(struct futhark_context* ctx,+int gpu_memcpy(struct futhark_context* ctx, const char* provenance, gpu_mem dst, int64_t dst_offset, gpu_mem src, int64_t src_offset, int64_t nbytes);-int gpu_scalar_from_device(struct futhark_context* ctx,+int gpu_scalar_from_device(struct futhark_context* ctx, const char* provenance, void *dst, gpu_mem src, size_t offset, size_t size);-int gpu_scalar_to_device(struct futhark_context* ctx,+int gpu_scalar_to_device(struct futhark_context* ctx, const char* provenance, gpu_mem dst, size_t offset, size_t size, void *src); void gpu_create_kernel(struct futhark_context *ctx,@@ -329,6 +330,7 @@ } static int gpu_map_transpose(struct futhark_context* ctx,+ const char* provenance, gpu_kernel kernel_default, gpu_kernel kernel_low_height, gpu_kernel kernel_low_width,@@ -452,14 +454,14 @@ fprintf(ctx->log, "\n"); } - return gpu_launch_kernel(ctx, kernel, name, grid, block,+ return gpu_launch_kernel(ctx, kernel, name, provenance, grid, block, TR_TILE_DIM*(TR_TILE_DIM+1)*elem_size, sizeof(args)/sizeof(args[0]), args, args_sizes); } #define GEN_MAP_TRANSPOSE_GPU2GPU(NAME, ELEM_TYPE) \ static int map_transpose_gpu2gpu_##NAME \- (struct futhark_context* ctx, \+ (struct futhark_context* ctx, const char* provenance, \ gpu_mem dst, int64_t dst_offset, \ gpu_mem src, int64_t src_offset, \ int64_t k, int64_t m, int64_t n) \@@ -467,6 +469,7 @@ return \ gpu_map_transpose \ (ctx, \+ provenance, \ ctx->kernels->map_transpose_##NAME, \ ctx->kernels->map_transpose_##NAME##_low_height, \ ctx->kernels->map_transpose_##NAME##_low_width, \@@ -477,7 +480,7 @@ k, n, m); \ } -static int gpu_lmad_copy(struct futhark_context* ctx,+static int gpu_lmad_copy(struct futhark_context* ctx, const char* provenance, gpu_kernel kernel, int r, gpu_mem dst, int64_t dst_offset, int64_t dst_strides[r], gpu_mem src, int64_t src_offset, int64_t src_strides[r],@@ -524,7 +527,7 @@ } const size_t w = 256; // XXX: hardcoded thread block size. - return gpu_launch_kernel(ctx, kernel, "copy_lmad_dev_to_dev",+ return gpu_launch_kernel(ctx, kernel, "copy_lmad_dev_to_dev", provenance, (const int32_t[3]) {(n+w-1)/w,1,1}, (const int32_t[3]) {w,1,1}, 0, 6+(8*3), args, args_sizes);@@ -532,12 +535,14 @@ #define GEN_LMAD_COPY_ELEMENTS_GPU2GPU(NAME, ELEM_TYPE) \ static int lmad_copy_elements_gpu2gpu_##NAME \- (struct futhark_context* ctx, \+ (struct futhark_context* ctx, const char* provenance, \ int r, \ gpu_mem dst, int64_t dst_offset, int64_t dst_strides[r], \ gpu_mem src, int64_t src_offset, int64_t src_strides[r], \ int64_t shape[r]) { \- return gpu_lmad_copy(ctx, ctx->kernels->lmad_copy_##NAME, r, \+ return gpu_lmad_copy(ctx, provenance, \+ ctx->kernels->lmad_copy_##NAME, \+ r, \ dst, dst_offset, dst_strides, \ src, src_offset, src_strides, \ shape); \@@ -545,32 +550,34 @@ #define GEN_LMAD_COPY_GPU2GPU(NAME, ELEM_TYPE) \ static int lmad_copy_gpu2gpu_##NAME \- (struct futhark_context* ctx, \+ (struct futhark_context* ctx, const char* provenance, \ int r, \ gpu_mem dst, int64_t dst_offset, int64_t dst_strides[r], \ gpu_mem src, int64_t src_offset, int64_t src_strides[r], \ int64_t shape[r]) { \- log_copy(ctx, "GPU to GPU", r, dst_offset, dst_strides, \+ log_copy(ctx, "GPU to GPU", provenance, r, dst_offset, dst_strides, \ src_offset, src_strides, shape); \ int64_t size = 1; \ for (int i = 0; i < r; i++) { size *= shape[i]; } \ if (size == 0) { return FUTHARK_SUCCESS; } \ int64_t k, n, m; \ if (lmad_map_tr(&k, &n, &m, \- r, dst_strides, src_strides, shape)) { \+ r, dst_strides, src_strides, shape)) { \ log_transpose(ctx, k, n, m); \ return map_transpose_gpu2gpu_##NAME \- (ctx, dst, dst_offset, src, src_offset, k, n, m); \+ (ctx, provenance, dst, dst_offset, src, src_offset, k, n, m); \ } else if (lmad_memcpyable(r, dst_strides, src_strides, shape)) { \ if (ctx->logging) {fprintf(ctx->log, "## Flat copy\n\n");} \ return gpu_memcpy(ctx, \+ provenance, \ dst, dst_offset*sizeof(ELEM_TYPE), \ src, src_offset*sizeof(ELEM_TYPE), \ size * sizeof(ELEM_TYPE)); \ } else { \ if (ctx->logging) {fprintf(ctx->log, "## General copy\n\n");} \ return lmad_copy_elements_gpu2gpu_##NAME \- (ctx, r, \+ (ctx, provenance, \+ r, \ dst, dst_offset, dst_strides, \ src, src_offset, src_strides, \ shape); \@@ -578,12 +585,13 @@ } static int-lmad_copy_elements_host2gpu(struct futhark_context *ctx, size_t elem_size,+lmad_copy_elements_host2gpu(struct futhark_context *ctx, const char *provenance,+ size_t elem_size, int r, gpu_mem dst, int64_t dst_offset, int64_t dst_strides[r], unsigned char* src, int64_t src_offset, int64_t src_strides[r], int64_t shape[r]) {- (void)ctx; (void)elem_size; (void)r;+ (void)ctx; (void)provenance; (void)elem_size; (void)r; (void)dst; (void)dst_offset; (void)dst_strides; (void)src; (void)src_offset; (void)src_strides; (void)shape;@@ -592,12 +600,13 @@ } static int-lmad_copy_elements_gpu2host (struct futhark_context *ctx, size_t elem_size,+lmad_copy_elements_gpu2host (struct futhark_context *ctx, const char *provenance,+ size_t elem_size, int r, unsigned char* dst, int64_t dst_offset, int64_t dst_strides[r], gpu_mem src, int64_t src_offset, int64_t src_strides[r], int64_t shape[r]) {- (void)ctx; (void)elem_size; (void)r;+ (void)ctx; (void)provenance; (void)elem_size; (void)r; (void)dst; (void)dst_offset; (void)dst_strides; (void)src; (void)src_offset; (void)src_strides; (void)shape;@@ -605,26 +614,13 @@ return 1; } -#define GEN_LMAD_COPY_ELEMENTS_HOSTGPU(NAME, ELEM_TYPE) \- static int lmad_copy_elements_gpu2gpu_##NAME \- (struct futhark_context* ctx, \- int r, \- gpu_mem dst, int64_t dst_offset, int64_t dst_strides[r], \- gpu_mem src, int64_t src_offset, int64_t src_strides[r], \- int64_t shape[r]) { \- return (ctx, ctx->kernels->lmad_copy_##NAME, r, \- dst, dst_offset, dst_strides, \- src, src_offset, src_strides, \- shape); \- } \---static int lmad_copy_host2gpu(struct futhark_context* ctx, size_t elem_size, bool sync,+static int lmad_copy_host2gpu(struct futhark_context* ctx, const char* provenance,+ size_t elem_size, bool sync, int r, gpu_mem dst, int64_t dst_offset, int64_t dst_strides[r], unsigned char* src, int64_t src_offset, int64_t src_strides[r], int64_t shape[r]) {- log_copy(ctx, "Host to GPU", r, dst_offset, dst_strides,+ log_copy(ctx, "Host to GPU", provenance, r, dst_offset, dst_strides, src_offset, src_strides, shape); int64_t size = elem_size; for (int i = 0; i < r; i++) { size *= shape[i]; }@@ -632,7 +628,8 @@ int64_t k, n, m; if (lmad_memcpyable(r, dst_strides, src_strides, shape)) { if (ctx->logging) {fprintf(ctx->log, "## Flat copy\n\n");}- return memcpy_host2gpu(ctx, sync,+ return memcpy_host2gpu(ctx, provenance,+ sync, dst, dst_offset*elem_size, src, src_offset*elem_size, size);@@ -640,7 +637,8 @@ if (ctx->logging) {fprintf(ctx->log, "## General copy\n\n");} int error; error = lmad_copy_elements_host2gpu- (ctx, elem_size, r,+ (ctx, provenance,+ elem_size, r, dst, dst_offset, dst_strides, src, src_offset, src_strides, shape);@@ -651,12 +649,13 @@ } } -static int lmad_copy_gpu2host(struct futhark_context* ctx, size_t elem_size, bool sync,+static int lmad_copy_gpu2host(struct futhark_context* ctx, const char* provenance,+ size_t elem_size, bool sync, int r, unsigned char* dst, int64_t dst_offset, int64_t dst_strides[r], gpu_mem src, int64_t src_offset, int64_t src_strides[r], int64_t shape[r]) {- log_copy(ctx, "Host to GPU", r, dst_offset, dst_strides,+ log_copy(ctx, "Host to GPU", provenance, r, dst_offset, dst_strides, src_offset, src_strides, shape); int64_t size = elem_size; for (int i = 0; i < r; i++) { size *= shape[i]; }@@ -664,7 +663,8 @@ int64_t k, n, m; if (lmad_memcpyable(r, dst_strides, src_strides, shape)) { if (ctx->logging) {fprintf(ctx->log, "## Flat copy\n\n");}- return memcpy_gpu2host(ctx, sync,+ return memcpy_gpu2host(ctx, provenance,+ sync, dst, dst_offset*elem_size, src, src_offset*elem_size, size);@@ -672,7 +672,7 @@ if (ctx->logging) {fprintf(ctx->log, "## General copy\n\n");} int error; error = lmad_copy_elements_gpu2host- (ctx, elem_size, r,+ (ctx, provenance, elem_size, r, dst, dst_offset, dst_strides, src, src_offset, src_strides, shape);
rts/c/scalar.h view
@@ -21,8 +21,8 @@ #define M_PI 3.141592653589793 #endif -SCALAR_FUN_ATTR int32_t futrts_to_bits32(float x);-SCALAR_FUN_ATTR float futrts_from_bits32(int32_t x);+SCALAR_FUN_ATTR int32_t fptobits_f32_i32(float x);+SCALAR_FUN_ATTR float bitstofp_i32_f32(int32_t x); SCALAR_FUN_ATTR uint8_t add8(uint8_t x, uint8_t y) { return x + y; } SCALAR_FUN_ATTR uint16_t add16(uint16_t x, uint16_t y) { return x + y; }@@ -1222,9 +1222,9 @@ } SCALAR_FUN_ATTR float futrts_copysign32(float x, float y) {- int32_t xb = futrts_to_bits32(x);- int32_t yb = futrts_to_bits32(y);- return futrts_from_bits32((xb & ~(1<<31)) | (yb & (1<<31)));+ int32_t xb = fptobits_f32_i32(x);+ int32_t yb = fptobits_f32_i32(y);+ return bitstofp_i32_f32((xb & ~(1<<31)) | (yb & (1<<31))); } SCALAR_FUN_ATTR float futrts_mad32(float a, float b, float c) {@@ -1300,12 +1300,14 @@ #if defined(ISPC) -SCALAR_FUN_ATTR int32_t futrts_to_bits32(float x) { return intbits(x); }-SCALAR_FUN_ATTR float futrts_from_bits32(int32_t x) { return floatbits(x); }+SCALAR_FUN_ATTR int32_t fptobits_f32_i32(float x) { return intbits(x); }+SCALAR_FUN_ATTR float bitstofp_i32_f32(int32_t x) { return floatbits(x); }+SCALAR_FUN_ATTR uniform int32_t fptobits_f32_i32(uniform float x) { return intbits(x); }+SCALAR_FUN_ATTR uniform float bitstofp_i32_f32(uniform int32_t x) { return floatbits(x); } #else -SCALAR_FUN_ATTR int32_t futrts_to_bits32(float x) {+SCALAR_FUN_ATTR int32_t fptobits_f32_i32(float x) { union { float f; int32_t t;@@ -1315,7 +1317,7 @@ return p.t; } -SCALAR_FUN_ATTR float futrts_from_bits32(int32_t x) {+SCALAR_FUN_ATTR float bitstofp_i32_f32(int32_t x) { union { int32_t f; float t;@@ -1332,8 +1334,8 @@ #ifdef FUTHARK_F64_ENABLED -SCALAR_FUN_ATTR double futrts_from_bits64(int64_t x);-SCALAR_FUN_ATTR int64_t futrts_to_bits64(double x);+SCALAR_FUN_ATTR double bitstofp_i64_f64(int64_t x);+SCALAR_FUN_ATTR int64_t fptobits_f64_i64(double x); #if defined(ISPC) @@ -1379,7 +1381,6 @@ SCALAR_FUN_ATTR double futrts_sqrt64(double x) { return sqrt(x); } SCALAR_FUN_ATTR double futrts_rsqrt64(double x) { return 1/sqrt(x); } -extern "C" unmasked uniform double cbrt(uniform double); SCALAR_FUN_ATTR double futrts_cbrt64(double x) { double res; foreach_active (i) {@@ -1560,7 +1561,7 @@ SCALAR_FUN_ATTR bool ftob_f64_bool(double x) { return x != 0.0; } SCALAR_FUN_ATTR double btof_bool_f64(bool x) { return x ? 1.0 : 0.0; } -SCALAR_FUN_ATTR int64_t futrts_to_bits64(double x) {+SCALAR_FUN_ATTR int64_t fptobits_f64_i64(double x) { int64_t res; foreach_active (i) { uniform double tmp = extract(x, i);@@ -1570,7 +1571,7 @@ return res; } -SCALAR_FUN_ATTR double futrts_from_bits64(int64_t x) {+SCALAR_FUN_ATTR double bitstofp_i64_f64(int64_t x) { double res; foreach_active (i) { uniform int64_t tmp = extract(x, i);@@ -1580,6 +1581,14 @@ return res; } +SCALAR_FUN_ATTR uniform int64_t fptobits_f64_i64(uniform double x) {+ return intbits(x);+}++SCALAR_FUN_ATTR uniform double bitstofp_i64_f64(uniform int64_t x) {+ return doublebits(x);+}+ SCALAR_FUN_ATTR double fmod64(double x, double y) { return x - y * trunc(x/y); }@@ -1597,9 +1606,9 @@ } SCALAR_FUN_ATTR double futrts_copysign64(double x, double y) {- int64_t xb = futrts_to_bits64(x);- int64_t yb = futrts_to_bits64(y);- return futrts_from_bits64((xb & ~(((int64_t)1)<<63)) | (yb & (((int64_t)1)<<63)));+ int64_t xb = fptobits_f64_i64(x);+ int64_t yb = fptobits_f64_i64(y);+ return bitstofp_i64_f64((xb & ~(((int64_t)1)<<63)) | (yb & (((int64_t)1)<<63))); } SCALAR_FUN_ATTR double futrts_mad64(double a, double b, double c) { return a * b + c; }@@ -1806,7 +1815,7 @@ SCALAR_FUN_ATTR bool ftob_f64_bool(double x) { return x != 0; } SCALAR_FUN_ATTR double btof_bool_f64(bool x) { return x ? 1 : 0; } -SCALAR_FUN_ATTR int64_t futrts_to_bits64(double x) {+SCALAR_FUN_ATTR int64_t fptobits_f64_i64(double x) { union { double f; int64_t t;@@ -1816,7 +1825,7 @@ return p.t; } -SCALAR_FUN_ATTR double futrts_from_bits64(int64_t x) {+SCALAR_FUN_ATTR double bitstofp_i64_f64(int64_t x) { union { int64_t f; double t;
rts/c/scalar_f16.h view
@@ -273,14 +273,14 @@ // The CUDA __half type cannot be put in unions for some reason, so we // use bespoke conversion functions instead. #ifdef __CUDA_ARCH__-SCALAR_FUN_ATTR int16_t futrts_to_bits16(f16 x) { return __half_as_ushort(x); }-SCALAR_FUN_ATTR f16 futrts_from_bits16(int16_t x) { return __ushort_as_half(x); }+SCALAR_FUN_ATTR int16_t fptobits_f16_i16(f16 x) { return __half_as_ushort(x); }+SCALAR_FUN_ATTR f16 bitstofp_i16_f16(int16_t x) { return __ushort_as_half(x); } #elif defined(ISPC)-SCALAR_FUN_ATTR int16_t futrts_to_bits16(f16 x) { varying int16_t y = *((varying int16_t * uniform)&x); return y;+SCALAR_FUN_ATTR int16_t fptobits_f16_i16(f16 x) { varying int16_t y = *((varying int16_t * uniform)&x); return y; }-SCALAR_FUN_ATTR f16 futrts_from_bits16(int16_t x) { varying f16 y = *((varying f16 * uniform)&x); return y; }+SCALAR_FUN_ATTR f16 bitstofp_i16_f16(int16_t x) { varying f16 y = *((varying f16 * uniform)&x); return y; } #else-SCALAR_FUN_ATTR int16_t futrts_to_bits16(f16 x) {+SCALAR_FUN_ATTR int16_t fptobits_f16_i16(f16 x) { union { f16 f; int16_t t;@@ -290,7 +290,7 @@ return p.t; } -SCALAR_FUN_ATTR f16 futrts_from_bits16(int16_t x) {+SCALAR_FUN_ATTR f16 bitstofp_i16_f16(int16_t x) { union { int16_t f; f16 t;@@ -359,20 +359,20 @@ // float. Similarly for vstore_half. #ifdef __OPENCL_VERSION__ -SCALAR_FUN_ATTR int16_t futrts_to_bits16(f16 x) {+SCALAR_FUN_ATTR int16_t fptobits_f16_i16(f16 x) { int16_t y; // Violating strict aliasing here. vstore_half((float)x, 0, (half*)&y); return y; } -SCALAR_FUN_ATTR f16 futrts_from_bits16(int16_t x) {+SCALAR_FUN_ATTR f16 bitstofp_i16_f16(int16_t x) { return (f16)vload_half(0, (half*)&x); } #else-SCALAR_FUN_ATTR int16_t futrts_to_bits16(f16 x) { return (int16_t)float2halfbits(x); }-SCALAR_FUN_ATTR f16 futrts_from_bits16(int16_t x) { return halfbits2float((uint16_t)x); }+SCALAR_FUN_ATTR int16_t fptobits_f16_i16(f16 x) { return (int16_t)float2halfbits(x); }+SCALAR_FUN_ATTR f16 bitstofp_i16_f16(int16_t x) { return halfbits2float((uint16_t)x); } SCALAR_FUN_ATTR f16 fsignum16(f16 x) { return futrts_isnan16(x) ? x : (x > 0 ? 1 : 0) - (x < 0 ? 1 : 0); } #endif
rts/c/uniform.h view
@@ -1206,7 +1206,6 @@ return sqrt(x); } -extern "C" unmasked uniform double cbrt(uniform double); static inline uniform double futrts_cbrt64(uniform double x) { return cbrt(x); }@@ -1704,11 +1703,11 @@ return a * b + c; } -static inline uniform int16_t futrts_to_bits16(uniform f16 x) {+static inline uniform int16_t fptobits_f16_i16(uniform f16 x) { return *((uniform int16_t *)&x); } -static inline uniform f16 futrts_from_bits16(uniform int16_t x) {+static inline uniform f16 bitstofp_i16_f16(uniform int16_t x) { return *((uniform f16 *)&x); }
rts/python/scalar.py view
@@ -736,14 +736,12 @@ return np.isinf(x) -def futhark_to_bits64(x):- s = struct.pack(">d", x)- return np.int64(struct.unpack(">q", s)[0])+def fptobits_f64_i64(x):+ return x.view(np.int64) -def futhark_from_bits64(x):- s = struct.pack(">q", x)- return np.float64(struct.unpack(">d", s)[0])+def bitstofp_i64_f64(x):+ return x.view(np.float64) def futhark_log32(x):@@ -902,14 +900,12 @@ return np.isinf(x) -def futhark_to_bits32(x):- s = struct.pack(">f", x)- return np.int32(struct.unpack(">l", s)[0])+def fptobits_f32_i32(x):+ return x.view(np.int32) -def futhark_from_bits32(x):- s = struct.pack(">l", x)- return np.float32(struct.unpack(">f", s)[0])+def bitstofp_i32_f32(x):+ return x.view(np.float32) def futhark_log16(x):@@ -1068,14 +1064,12 @@ return np.isinf(x) -def futhark_to_bits16(x):- s = struct.pack(">e", x)- return np.int16(struct.unpack(">H", s)[0])+def fptobits_f16_i16(x):+ return x.view(np.int16) -def futhark_from_bits16(x):- s = struct.pack(">H", np.uint16(x))- return np.float16(struct.unpack(">e", s)[0])+def bitstofp_i16_f16(x):+ return x.view(np.float16) def futhark_lerp16(v0, v1, t):
+ src-testing/Futhark/AD/DerivativesTests.hs view
@@ -0,0 +1,52 @@+module Futhark.AD.DerivativesTests (tests) where++import Data.Map qualified as M+import Data.Text qualified as T+import Futhark.AD.Derivatives+import Futhark.Analysis.PrimExp+import Futhark.IR.Syntax.Core (nameFromText)+import Futhark.Util.Pretty (prettyString)+import Test.Tasty+import Test.Tasty.HUnit++tests :: TestTree+tests =+ testGroup+ "Futhark.AD.DerivativesTests"+ [ testGroup "Primitive functions" $+ map primFunTest $+ filter (not . (`elem` missing_primfuns) . fst) $+ M.toList primFuns,+ testGroup "BinOps" $ map binOpTest allBinOps,+ testGroup "UnOps" $ map unOpTest allUnOps+ ]+ where+ blank = ValueExp . blankPrimValue++ primFunTest (f, (ts, ret, _)) =+ testCase (T.unpack f) $+ case pdBuiltin (nameFromText f) (map blank ts) of+ Nothing -> assertFailure "pdBuiltin gives Nothing"+ Just v -> map primExpType v @?= replicate (length ts) ret++ -- We know we have no derivatives for these... and they are not+ -- coming any time soon.+ missing_primfuns =+ [ "gamma16",+ "gamma32",+ "gamma64",+ "lgamma16",+ "lgamma32",+ "lgamma64"+ ]++ binOpTest bop =+ testCase (prettyString bop) $+ let t = binOpType bop+ (dx, dy) = pdBinOp bop (blank t) (blank t)+ in (primExpType dx, primExpType dy) @?= (t, t)++ unOpTest bop =+ testCase (prettyString bop) $+ let t = unOpType bop+ in primExpType (pdUnOp bop $ blank t) @?= t
+ src-testing/Futhark/Analysis/AlgSimplifyTests.hs view
@@ -0,0 +1,90 @@+{-# LANGUAGE FlexibleInstances #-}+{-# OPTIONS_GHC -fno-warn-orphans #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}+{-# OPTIONS_GHC -fno-warn-unused-top-binds #-}++module Futhark.Analysis.AlgSimplifyTests+ ( tests,+ )+where++import Control.Monad+import Data.Function ((&))+import Data.List (subsequences)+import Data.Map qualified as M+import Data.Maybe (fromMaybe, mapMaybe)+import Futhark.Analysis.AlgSimplify hiding (add, sub)+import Futhark.Analysis.PrimExp+import Futhark.IR.Syntax.Core+import Test.Tasty+import Test.Tasty.HUnit+import Test.Tasty.QuickCheck++tests :: TestTree+tests =+ testGroup+ "AlgSimplifyTests"+ [ testProperty "simplify is idempotent" $ \(TestableExp e) -> simplify e == simplify (simplify e),+ testProperty "simplify doesn't change exp evalutation result" $+ \(TestableExp e) ->+ evalPrimExp (\_ -> Nothing) e+ == evalPrimExp (\_ -> Nothing) (simplify e)+ ]++eval :: TestableExp -> Int64+eval (TestableExp e) = evalExp e++evalExp :: PrimExp VName -> Int64+evalExp (ValueExp (IntValue (Int64Value i))) = i+evalExp (BinOpExp (Add Int64 OverflowUndef) e1 e2) = evalExp e1 + evalExp e2+evalExp (BinOpExp (Sub Int64 OverflowUndef) e1 e2) = evalExp e1 - evalExp e2+evalExp (BinOpExp (Mul Int64 OverflowUndef) e1 e2) = evalExp e1 * evalExp e2+evalExp _ = undefined++add :: PrimExp VName -> PrimExp VName -> PrimExp VName+add = BinOpExp (Add Int64 OverflowUndef)++sub :: PrimExp VName -> PrimExp VName -> PrimExp VName+sub = BinOpExp (Sub Int64 OverflowUndef)++mul :: PrimExp VName -> PrimExp VName -> PrimExp VName+mul = BinOpExp (Mul Int64 OverflowUndef)++neg :: PrimExp VName -> PrimExp VName+neg = BinOpExp (Sub Int64 OverflowUndef) (val 0)++l :: Int -> PrimExp VName+l i = LeafExp (VName (nameFromString $ show i) i) (IntType Int64)++val :: Int64 -> PrimExp VName+val = ValueExp . IntValue . Int64Value++generateExp :: Gen (PrimExp VName)+generateExp = do+ n <- getSize+ if n <= 1+ then val <$> arbitrary+ else+ oneof+ [ scale (`div` 2) $ generateBinOp add,+ scale (`div` 2) $ generateBinOp sub,+ scale (`div` 2) $ generateBinOp mul,+ scale (`div` 2) generateNeg,+ val <$> arbitrary+ ]++generateBinOp :: (PrimExp VName -> PrimExp VName -> PrimExp VName) -> Gen (PrimExp VName)+generateBinOp op = do+ t1 <- generateExp+ op t1 <$> generateExp++generateNeg :: Gen (PrimExp VName)+generateNeg =+ do neg <$> generateExp++newtype TestableExp = TestableExp (PrimExp VName)+ deriving (Show)++instance Arbitrary TestableExp where+ arbitrary = TestableExp <$> generateExp
+ src-testing/Futhark/Analysis/PrimExp/TableTests.hs view
@@ -0,0 +1,257 @@+module Futhark.Analysis.PrimExp.TableTests (tests) where++import Control.Monad.State.Strict+import Data.Map.Strict qualified as M+import Futhark.Analysis.PrimExp+import Futhark.Analysis.PrimExp.Table+import Futhark.IR.GPU+import Futhark.IR.GPUTests ()+import Futhark.IR.MC+import Futhark.IR.MCTests ()+import Test.Tasty+import Test.Tasty.HUnit++tests :: TestTree+tests = testGroup "AnalyzePrim" [stmToPrimExpsTests]++stmToPrimExpsTests :: TestTree+stmToPrimExpsTests =+ testGroup+ "stmToPrimExps"+ [stmToPrimExpsTestsGPU, stmToPrimExpsTestsMC]++stmToPrimExpsTestsGPU :: TestTree+stmToPrimExpsTestsGPU =+ testGroup+ "GPU"+ $ do+ let scope =+ M.fromList+ [ ("n_5142", FParamName "i64"),+ ("m_5143", FParamName "i64"),+ ("xss_5144", FParamName "[n_5142][m_5143]i64"),+ ("segmap_group_size_5201", LetName "i64"),+ ("segmap_usable_groups_5202", LetName "i64"),+ ("defunc_0_map_res_5203", LetName "[n_5142]i64"),+ ("defunc_0_f_res_5207", LetName "i64"),+ ("i_5208", IndexName Int64),+ ("acc_5209", FParamName "i64"),+ ("b_5210", LetName "i64"),+ ("defunc_0_f_res_5211", LetName "i64")+ ]+ [ testCase "BinOp" $ do+ let stm = "let {defunc_0_f_res_5211 : i64} = add64(acc_5209, b_5210)"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ( "defunc_0_f_res_5211",+ Just+ ( BinOpExp+ (Add Int64 OverflowWrap)+ (LeafExp "acc_5209" (IntType Int64))+ (LeafExp "b_5210" (IntType Int64))+ )+ )+ ]+ res @?= expected,+ testCase "Index" $ do+ let stm = "let {b_5210 : i64} = xss_5144[gtid_5204, i_5208]"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected = M.fromList [("b_5210", Nothing)]+ res @?= expected,+ testCase "Loop" $ do+ let stm = "let {defunc_0_f_res_5207 : i64} = loop {acc_5209 : i64} = {0i64} for i_5208:i64 < m_5143 do { {defunc_0_f_res_5211} }"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ("defunc_0_f_res_5207", Nothing),+ ("i_5208", Just (LeafExp "i_5208" (IntType Int64))),+ ("acc_5209", Just (LeafExp "acc_5209" (IntType Int64)))+ ]+ res @?= expected,+ testCase "Loop body" $ do+ let stm = "let {defunc_0_f_res_5207 : i64} = loop {acc_5209 : i64} = {0i64} for i_5208:i64 < m_5143 do { let {b_5210 : i64} = xss_5144[gtid_5204, i_5208] let {defunc_0_f_res_5211 : i64} = add64(acc_5209, b_5210) in {defunc_0_f_res_5211} }"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ("defunc_0_f_res_5207", Nothing),+ ("i_5208", Just (LeafExp "i_5208" (IntType Int64))),+ ("acc_5209", Just (LeafExp "acc_5209" (IntType Int64))),+ ("b_5210", Nothing),+ ( "defunc_0_f_res_5211",+ Just+ ( BinOpExp+ (Add Int64 OverflowWrap)+ (LeafExp "acc_5209" (IntType Int64))+ (LeafExp "b_5210" (IntType Int64))+ )+ )+ ]+ res @?= expected,+ testCase "SegMap" $+ do+ let stm =+ "let {defunc_0_map_res_5125 : [n_5142]i64} =\+ \ segmap(thread; ; grid=segmap_usable_groups_5124; blocksize=segmap_group_size_5123)\+ \ (gtid_5126 < n_5142) (~phys_tid_5127) : {i64} {\+ \ return {returns lifted_lambda_res_5129} \+ \}"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ("defunc_0_map_res_5125", Nothing),+ ("gtid_5126", Just (LeafExp "gtid_5126" (IntType Int64)))+ ]+ res @?= expected,+ testCase "SegMap body" $+ do+ let stm :: Stm GPU+ stm =+ "let {defunc_0_map_res_5125 : [n_5142]i64} =\+ \ segmap(thread; ; grid=segmap_usable_groups_5124; blocksize=segmap_group_size_5123)\+ \ (gtid_5126 < n_5142) (~phys_tid_5127) : {i64} {\+ \ let {eta_p_5128 : i64} =\+ \ xs_5093[gtid_5126]\+ \ let {lifted_lambda_res_5129 : i64} =\+ \ add64(2i64, eta_p_5128)\+ \ return {returns lifted_lambda_res_5129}\+ \ }"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ("defunc_0_map_res_5125", Nothing),+ ("gtid_5126", Just (LeafExp "gtid_5126" (IntType Int64))),+ ("eta_p_5128", Nothing),+ ( "lifted_lambda_res_5129",+ Just+ ( BinOpExp+ (Add Int64 OverflowWrap)+ (ValueExp (IntValue (Int64Value 2)))+ (LeafExp "eta_p_5128" (IntType Int64))+ )+ )+ ]+ res @?= expected+ ]++stmToPrimExpsTestsMC :: TestTree+stmToPrimExpsTestsMC =+ testGroup+ "MC"+ $ do+ let scope =+ M.fromList+ [ ("n_5142", FParamName "i64"),+ ("m_5143", FParamName "i64"),+ ("xss_5144", FParamName "[n_5142][5143]i64"),+ ("segmap_group_size_5201", LetName "i64"),+ ("segmap_usable_groups_5202", LetName "i64"),+ ("defunc_0_map_res_5203", LetName "[n_5142]i64"),+ ("defunc_0_f_res_5207", LetName "i64"),+ ("i_5208", IndexName Int64),+ ("acc_5209", FParamName "i64"),+ ("b_5210", LetName "i64"),+ ("defunc_0_f_res_5211", LetName "i64")+ ]+ [ testCase "BinOp" $ do+ let stm = "let {defunc_0_f_res_5211 : i64} = add64(acc_5209, b_5210)"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ( "defunc_0_f_res_5211",+ Just+ ( BinOpExp+ (Add Int64 OverflowWrap)+ (LeafExp "acc_5209" (IntType Int64))+ (LeafExp "b_5210" (IntType Int64))+ )+ )+ ]+ res @?= expected,+ testCase "Index" $ do+ let stm = "let {b_5210 : i64} = xss_5144[gtid_5204, i_5208]"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected = M.fromList [("b_5210", Nothing)]+ res @?= expected,+ testCase "Loop" $ do+ let stm = "let {defunc_0_f_res_5207 : i64} = loop {acc_5209 : i64} = {0i64} for i_5208:i64 < m_5143 do { {defunc_0_f_res_5211} }"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ("defunc_0_f_res_5207", Nothing),+ ("i_5208", Just (LeafExp "i_5208" (IntType Int64))),+ ("acc_5209", Just (LeafExp "acc_5209" (IntType Int64)))+ ]+ res @?= expected,+ testCase "Loop body" $ do+ let stm =+ "\+ \let {defunc_0_f_res_5207 : i64} =\+ \ loop {acc_5209 : i64} = {0i64}\+ \ for i_5208:i64 < m_5143 do {\+ \ let {b_5210 : i64} =\+ \ xss_5144[gtid_5204, i_5208]\+ \ let {defunc_0_f_res_5211 : i64} =\+ \ add64(acc_5209, b_5210)\+ \ in {defunc_0_f_res_5211}\+ \ }"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ("defunc_0_f_res_5207", Nothing),+ ("i_5208", Just (LeafExp "i_5208" (IntType Int64))),+ ("acc_5209", Just (LeafExp "acc_5209" (IntType Int64))),+ ("b_5210", Nothing),+ ( "defunc_0_f_res_5211",+ Just+ ( BinOpExp+ (Add Int64 OverflowWrap)+ (LeafExp "acc_5209" (IntType Int64))+ (LeafExp "b_5210" (IntType Int64))+ )+ )+ ]+ res @?= expected,+ testCase "SegMap" $ do+ let stm =+ "let {defunc_0_map_res_5125 : [n_5142]i64} =\+ \ segmap()\+ \ (gtid_5126 < n_5142) (~flat_tid_5112) : {i64} {\+ \ return {returns lifted_lambda_res_5129}\+ \ }"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ("defunc_0_map_res_5125", Nothing),+ ("gtid_5126", Just (LeafExp "gtid_5126" (IntType Int64)))+ ]+ res @?= expected,+ testCase "SegMap body" $ do+ let stm :: Stm MC+ stm =+ "let {defunc_0_map_res_5125 : [n_5142]i64} =\+ \ segmap()\+ \ (gtid_5126 < n_5142) (~flat_tid_5112) : {i64} {\+ \ let {eta_p_5128 : i64} =\+ \ xs_5093[gtid_5126]\+ \ let {lifted_lambda_res_5129 : i64} =\+ \ add64(2i64, eta_p_5128)\+ \ return {returns lifted_lambda_res_5129}\+ \ }"+ let res = execState (stmToPrimExps scope stm) mempty+ let expected =+ M.fromList+ [ ("defunc_0_map_res_5125", Nothing),+ ("gtid_5126", Just (LeafExp "gtid_5126" (IntType Int64))),+ ("eta_p_5128", Nothing),+ ( "lifted_lambda_res_5129",+ Just+ ( BinOpExp+ (Add Int64 OverflowWrap)+ (ValueExp (IntValue (Int64Value 2)))+ (LeafExp "eta_p_5128" (IntType Int64))+ )+ )+ ]+ res @?= expected+ ]
+ src-testing/Futhark/BenchTests.hs view
@@ -0,0 +1,48 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Futhark.BenchTests (tests) where++import Data.Map qualified as M+import Data.Text qualified as T+import Futhark.Bench+import Futhark.ProfileTests ()+import Test.Tasty+import Test.Tasty.QuickCheck++instance Arbitrary RunResult where+ arbitrary = RunResult . getPositive <$> arbitrary++printable :: Gen String+printable = getASCIIString <$> arbitrary++instance Arbitrary DataResult where+ arbitrary =+ DataResult+ <$> (T.pack <$> printable)+ <*> oneof+ [ Left <$> arbText,+ Right+ <$> ( Result+ <$> arbitrary+ <*> arbMap+ <*> oneof [pure Nothing, Just <$> arbText]+ <*> arbitrary+ )+ ]+ where+ arbText = T.pack <$> printable+ arbMap = M.fromList <$> listOf ((,) <$> arbText <*> arbitrary)++-- XXX: we restrict this generator to single datasets to we don't have+-- to worry about duplicates.+instance Arbitrary BenchResult where+ arbitrary = BenchResult <$> printable <*> (pure <$> arbitrary)++encodeDecodeJSON :: TestTree+encodeDecodeJSON = testProperty "encoding and decoding are inverse" prop+ where+ prop :: BenchResult -> Bool+ prop brs = decodeBenchResults (encodeBenchResults [brs]) == Right [brs]++tests :: TestTree+tests = testGroup "Futhark.BenchTests" [encodeDecodeJSON]
+ src-testing/Futhark/IR/GPUTests.hs view
@@ -0,0 +1,20 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Futhark.IR.GPUTests () where++import Data.String+import Futhark.IR.GPU+import Futhark.IR.Parse+import Futhark.IR.SyntaxTests (parseString)++-- There isn't anything to test in this module, but we define some+-- convenience instances.++instance IsString (Stm GPU) where+ fromString = parseString "Stm GPU" parseStmGPU++instance IsString (Body GPU) where+ fromString = parseString "Body GPU" parseBodyGPU++instance IsString (Prog GPU) where+ fromString = parseString "Prog GPU" parseGPU
+ src-testing/Futhark/IR/MCTests.hs view
@@ -0,0 +1,20 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Futhark.IR.MCTests () where++import Data.String+import Futhark.IR.MC+import Futhark.IR.Parse+import Futhark.IR.SyntaxTests (parseString)++-- There isn't anything to test in this module, but we define some+-- convenience instances.++instance IsString (Stm MC) where+ fromString = parseString "Stm MC" parseStmMC++instance IsString (Body MC) where+ fromString = parseString "Body MC" parseBodyMC++instance IsString (Prog MC) where+ fromString = parseString "Prog MC" parseMC
+ src-testing/Futhark/IR/Mem/IntervalTests.hs view
@@ -0,0 +1,68 @@+module Futhark.IR.Mem.IntervalTests+ ( tests,+ )+where++import Futhark.Analysis.AlgSimplify+import Futhark.Analysis.PrimExp.Convert+import Futhark.IR.Mem.Interval+import Futhark.IR.Syntax+import Futhark.IR.Syntax.Core ()+import Test.Tasty+import Test.Tasty.HUnit++-- Actual tests.+tests :: TestTree+tests =+ testGroup+ "IntervalTests"+ testDistributeOffset++name :: String -> Int -> VName+name s = VName (nameFromString s)++testDistributeOffset :: [TestTree]+testDistributeOffset =+ [ testCase "Stride is (nb-b)" $ do+ let n = TPrimExp $ LeafExp (name "n" 1) $ IntType Int64+ b = TPrimExp $ LeafExp (name "b" 2) $ IntType Int64+ res <-+ distributeOffset+ [Prod False [untyped (n * b - b :: TPrimExp Int64 VName)]]+ [ Interval 0 1 (n * b - b),+ Interval 0 b b,+ Interval 0 b 1+ ]+ res == [Interval 1 1 (n * b - b), Interval 0 b b, Interval 0 b 1] @? "Failed",+ testCase "Stride is 1024r" $ do+ let r = TPrimExp $ LeafExp (name "r" 1) $ IntType Int64+ res <-+ distributeOffset+ [Prod False [untyped (1024 :: TPrimExp Int64 VName), untyped r]]+ [ Interval 0 1 (1024 * r),+ Interval 0 32 32,+ Interval 0 32 1+ ]+ res == [Interval 1 1 (1024 * r), Interval 0 32 32, Interval 0 32 1] @? "Failed. Got " <> show res,+ testCase "Stride is 32, offsets are multples of 32" $ do+ let n = TPrimExp $ LeafExp (name "n" 0) $ IntType Int64+ let g1 = TPrimExp $ LeafExp (name "g" 1) $ IntType Int64+ let g2 = TPrimExp $ LeafExp (name "g" 2) $ IntType Int64+ res <-+ distributeOffset+ [ Prod False [untyped (1024 :: TPrimExp Int64 VName)],+ Prod False [untyped (1024 :: TPrimExp Int64 VName), untyped g1],+ Prod False [untyped (32 :: TPrimExp Int64 VName), untyped g2]+ ]+ [ Interval 0 1 (1024 * n),+ Interval 0 1 32,+ Interval 0 32 1+ ]+ res+ == [ Interval 0 1 (1024 * n),+ Interval (32 + 32 * g1 + g2) 1 32,+ Interval 0 32 1+ ]+ @? "Failed. Got "+ <> show res+ ]
+ src-testing/Futhark/IR/Mem/IxFun/Alg.hs view
@@ -0,0 +1,176 @@+-- | A simple index operation representation. Every operation corresponds to a+-- constructor.+module Futhark.IR.Mem.IxFun.Alg+ ( IxFun (..),+ iota,+ offsetIndex,+ permute,+ reshape,+ coerce,+ slice,+ flatSlice,+ expand,+ shape,+ index,+ disjoint,+ )+where++import Data.List qualified as L+import Data.Set qualified as S+import Futhark.IR.Pretty ()+import Futhark.IR.Prop+import Futhark.IR.Syntax+ ( DimIndex (..),+ FlatDimIndex (..),+ FlatSlice (..),+ Slice (..),+ flatSliceDims,+ sliceDims,+ unitSlice,+ )+import Futhark.Util.IntegralExp+import Futhark.Util.Pretty+import Prelude hiding (div, mod, span)++type Shape num = [num]++type Indices num = [num]++type Permutation = [Int]++data IxFun num+ = Direct (Shape num)+ | Permute (IxFun num) Permutation+ | Index (IxFun num) (Slice num)+ | FlatIndex (IxFun num) (FlatSlice num)+ | Reshape (IxFun num) (Shape num)+ | Coerce (IxFun num) (Shape num)+ | OffsetIndex (IxFun num) num+ | Expand num num (IxFun num)+ deriving (Eq, Show)++instance (Pretty num) => Pretty (IxFun num) where+ pretty (Direct dims) =+ "Direct" <> parens (commasep $ map pretty dims)+ pretty (Permute fun perm) = pretty fun <> pretty perm+ pretty (Index fun is) = pretty fun <> pretty is+ pretty (FlatIndex fun is) = pretty fun <> pretty is+ pretty (Reshape fun oldshape) =+ pretty fun+ <> "->reshape"+ <> parens (pretty oldshape)+ pretty (Coerce fun oldshape) =+ pretty fun+ <> "->coerce"+ <> parens (pretty oldshape)+ pretty (OffsetIndex fun i) =+ pretty fun <> "->offset_index" <> parens (pretty i)+ pretty (Expand o p fun) =+ "expand(" <> pretty o <> "," <+> pretty p <> "," <+> pretty fun <> ")"++iota :: Shape num -> IxFun num+iota = Direct++offsetIndex :: IxFun num -> num -> IxFun num+offsetIndex = OffsetIndex++permute :: IxFun num -> Permutation -> IxFun num+permute = Permute++slice :: IxFun num -> Slice num -> IxFun num+slice = Index++flatSlice :: IxFun num -> FlatSlice num -> IxFun num+flatSlice = FlatIndex++expand :: num -> num -> IxFun num -> IxFun num+expand = Expand++reshape :: IxFun num -> Shape num -> IxFun num+reshape = Reshape++coerce :: IxFun num -> Shape num -> IxFun num+coerce = Reshape++shape ::+ (IntegralExp num) =>+ IxFun num ->+ Shape num+shape (Direct dims) =+ dims+shape (Permute ixfun perm) =+ rearrangeShape perm $ shape ixfun+shape (Index _ how) =+ sliceDims how+shape (FlatIndex ixfun how) =+ flatSliceDims how <> tail (shape ixfun)+shape (Reshape _ dims) =+ dims+shape (Coerce _ dims) =+ dims+shape (OffsetIndex ixfun _) =+ shape ixfun+shape (Expand _ _ ixfun) =+ shape ixfun++index ::+ (Eq num, IntegralExp num) =>+ IxFun num ->+ Indices num ->+ num+index (Direct dims) is =+ sum $ zipWith (*) is slicesizes+ where+ slicesizes = drop 1 $ sliceSizes dims+index (Permute fun perm) is_new =+ index fun is_old+ where+ is_old = rearrangeShape (rearrangeInverse perm) is_new+index (Index fun (Slice js)) is =+ index fun (adjust js is)+ where+ adjust (DimFix j : js') is' = j : adjust js' is'+ adjust (DimSlice j _ s : js') (i : is') = j + i * s : adjust js' is'+ adjust _ _ = []+index (FlatIndex fun (FlatSlice offset js)) is =+ index fun $ sum (offset : zipWith f is js) : drop (length js) is+ where+ f i (FlatDimIndex _ s) = i * s+index (Reshape fun newshape) is =+ let new_indices = reshapeIndex (shape fun) newshape is+ in index fun new_indices+index (Coerce fun _) is =+ index fun is+index (OffsetIndex fun i) is =+ case shape fun of+ d : ds ->+ index (Index fun (Slice (DimSlice i (d - i) 1 : map (unitSlice 0) ds))) is+ [] -> error "index: OffsetIndex: underlying index function has rank zero"+index (Expand o p ixfun) is =+ o + p * index ixfun is++allPoints :: (IntegralExp num, Enum num) => [num] -> [[num]]+allPoints dims =+ let total = product dims+ strides = drop 1 $ L.reverse $ scanl (*) 1 $ L.reverse dims+ in map (unflatInd strides) [0 .. total - 1]+ where+ unflatInd strides x =+ fst $+ foldl+ ( \(res, acc) span ->+ (res ++ [acc `div` span], acc `mod` span)+ )+ ([], x)+ strides++disjoint :: (IntegralExp num, Ord num, Enum num) => IxFun num -> IxFun num -> Bool+disjoint ixf1 ixf2 =+ let shp1 = shape ixf1+ points1 = S.fromList $ allPoints shp1+ allIdxs1 = S.map (index ixf1) points1+ shp2 = shape ixf2+ points2 = S.fromList $ allPoints shp2+ allIdxs2 = S.map (index ixf2) points2+ in S.disjoint allIdxs1 allIdxs2
+ src-testing/Futhark/IR/Mem/IxFunTests.hs view
@@ -0,0 +1,571 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Futhark.IR.Mem.IxFunTests+ ( tests,+ )+where++import Data.Bifunctor+import Data.Function ((&))+import Data.List qualified as L+import Data.Map qualified as M+import Data.Text qualified as T+import Futhark.Analysis.PrimExp.Convert+import Futhark.IR.Mem.IxFun.Alg qualified as IxFunAlg+import Futhark.IR.Mem.IxFunWrapper+import Futhark.IR.Mem.IxFunWrapper qualified as IxFunWrap+import Futhark.IR.Mem.LMAD qualified as IxFunLMAD+import Futhark.IR.Prop+import Futhark.IR.Syntax+import Futhark.IR.Syntax.Core ()+import Futhark.Util.IntegralExp qualified as IE+import Futhark.Util.Pretty+import Test.Tasty+import Test.Tasty.HUnit+import Prelude hiding (span)+import Prelude qualified as P++instance IE.IntegralExp Int where+ quot = P.quot+ rem = P.rem+ div = P.div+ mod = P.mod+ pow = (P.^)+ sgn = Just . P.signum++allPoints :: [Int] -> [[Int]]+allPoints dims =+ let total = product dims+ strides = drop 1 $ L.reverse $ scanl (*) 1 $ L.reverse dims+ in map (unflatInd strides) [0 .. total - 1]+ where+ unflatInd :: [Int] -> Int -> [Int]+ unflatInd strides x =+ fst $+ foldl+ ( \(res, acc) span ->+ (res ++ [acc `P.div` span], acc `P.mod` span)+ )+ ([], x)+ strides++compareIxFuns :: Maybe (IxFunLMAD.LMAD Int) -> IxFunAlg.IxFun Int -> Assertion+compareIxFuns (Just ixfunLMAD) ixfunAlg =+ let lmadShape = IxFunLMAD.shape ixfunLMAD+ algShape = IxFunAlg.shape ixfunAlg+ points = allPoints lmadShape+ resLMAD = map (IxFunLMAD.index ixfunLMAD) points+ resAlg = map (IxFunAlg.index ixfunAlg) points+ errorMessage =+ T.unpack . docText $+ "lmad ixfun: "+ <> pretty ixfunLMAD+ </> "alg ixfun: "+ <> pretty ixfunAlg+ </> "lmad shape: "+ <> pretty lmadShape+ </> "alg shape: "+ <> pretty algShape+ </> "lmad points length: "+ <> pretty (length resLMAD)+ </> "alg points length: "+ <> pretty (length resAlg)+ </> "lmad points: "+ <> pretty resLMAD+ </> "alg points: "+ <> pretty resAlg+ in (lmadShape == algShape && resLMAD == resAlg) @? errorMessage+compareIxFuns Nothing ixfunAlg =+ assertFailure $+ unlines+ [ "lmad ixfun: Nothing",+ "alg ixfun: " <> prettyString ixfunAlg+ ]++compareOps :: IxFunWrap.IxFun Int -> Assertion+compareOps (ixfunLMAD, ixfunAlg) = compareIxFuns ixfunLMAD ixfunAlg++compareOpsFailure :: IxFunWrap.IxFun Int -> Assertion+compareOpsFailure (Nothing, _) = pure ()+compareOpsFailure (Just ixfunLMAD, ixfunAlg) =+ assertFailure . T.unpack . docText $+ "Not supposed to be representable as LMAD."+ </> "lmad ixfun: "+ <> pretty ixfunLMAD+ </> "alg ixfun: "+ <> pretty ixfunAlg++-- XXX: Clean this up.+n :: Int+n = 19++slice3 :: Slice Int+slice3 =+ Slice+ [ DimSlice 2 (n `P.div` 3) 3,+ DimFix (n `P.div` 2),+ DimSlice 1 (n `P.div` 2) 2+ ]++-- Actual tests.+tests :: TestTree+tests =+ testGroup "IxFunTests" $+ concat+ [ test_iota,+ test_slice_iota,+ test_slice_reshape_iota1,+ test_permute_slice_iota,+ test_reshape_iota,+ test_reshape_permute_iota,+ test_slice_reshape_iota2,+ test_reshape_slice_iota3,+ test_flatten_strided,+ test_complex1,+ test_complex2,+ test_expand1,+ test_expand2,+ test_expand3,+ test_expand4,+ test_flatSlice_iota,+ test_slice_flatSlice_iota,+ test_flatSlice_flatSlice_iota,+ test_flatSlice_slice_iota,+ test_flatSlice_transpose_slice_iota+ -- TODO: Without z3, these tests fail. Ideally, our internal simplifier+ -- should be able to handle them:+ --+ -- test_disjoint3+ ]++singleton :: TestTree -> [TestTree]+singleton = (: [])++test_iota :: [TestTree]+test_iota =+ singleton . testCase "iota" . compareOps $+ iota [n]++test_slice_iota :: [TestTree]+test_slice_iota =+ singleton . testCase "slice . iota" . compareOps $+ slice (iota [n, n, n]) slice3++test_slice_reshape_iota1 :: [TestTree]+test_slice_reshape_iota1 =+ singleton . testCase "slice . reshape . iota 1" . compareOps $+ slice (reshape (iota [n, n, n]) [n `P.div` 2, n `P.div` 3, 1]) slice3++test_permute_slice_iota :: [TestTree]+test_permute_slice_iota =+ singleton . testCase "permute . slice . iota" . compareOps $+ permute (slice (iota [n, n, n]) slice3) [1, 0]++test_reshape_iota :: [TestTree]+test_reshape_iota =+ -- This tests a pattern that occurs with ScalarSpace.+ singleton . testCase "reshape . zeroslice . iota" . compareOps $+ let s = Slice [DimSlice 0 n 0, DimSlice 0 n 1]+ in reshape (slice (iota [n, n]) s) [1, n, 1, n]++test_reshape_permute_iota :: [TestTree]+test_reshape_permute_iota =+ -- negative reshape test+ singleton . testCase "reshape . permute . iota" . compareOpsFailure $+ let newdims = [n * n, n]+ in reshape (permute (iota [n, n, n]) [1, 2, 0]) newdims++test_slice_reshape_iota2 :: [TestTree]+test_slice_reshape_iota2 =+ singleton . testCase "slice . reshape . iota 2" . compareOps $+ let newdims = [n * n, n]+ slc =+ Slice+ [ DimFix (n `P.div` 2),+ DimSlice 0 n 1+ ]+ in slice (reshape (iota [n, n, n, n]) newdims) slc++test_reshape_slice_iota3 :: [TestTree]+test_reshape_slice_iota3 =+ -- negative reshape test+ singleton . testCase "reshape . slice . iota 3" . compareOpsFailure $+ let newdims = [n * n, n]+ slc =+ Slice+ [ DimFix (n `P.div` 2),+ DimSlice 0 n 1,+ DimSlice 0 (n `P.div` 2) 1,+ DimSlice 0 n 1+ ]+ in reshape (slice (iota [n, n, n, n]) slc) newdims++-- Tests flattening something that is strided - this can occur after+-- memory expansion.+test_flatten_strided :: [TestTree]+test_flatten_strided =+ singleton . testCase "reshape . fix . iota 3d" . compareOps $+ let slc = Slice [DimSlice 0 n 1, DimSlice 0 2 1, DimFix 1]+ in reshape (slice (iota [n, 2, n * n]) slc) [2 * 10]++test_complex1 :: [TestTree]+test_complex1 =+ singleton . testCase "permute . slice . permute . slice . iota 1" . compareOps $+ let slice33 =+ Slice+ [ DimSlice (n - 1) (n `P.div` 3) (-1),+ DimSlice (n - 1) n (-1),+ DimSlice (n - 1) n (-1),+ DimSlice 0 n 1+ ]+ ixfun = permute (slice (iota [n, n, n, n, n]) slice33) [3, 1, 2, 0]+ m = n `P.div` 3+ slice1 =+ Slice+ [ DimSlice 0 n 1,+ DimSlice (n - 1) n (-1),+ DimSlice (n - 1) n (-1),+ DimSlice 1 (m - 2) (-1)+ ]+ ixfun' = slice ixfun slice1+ in ixfun'++test_complex2 :: [TestTree]+test_complex2 =+ singleton . testCase "permute . slice . permute . slice . iota 2" . compareOps $+ let slc2 =+ Slice+ [ DimFix (n `P.div` 2),+ DimSlice (n - 1) (n `P.div` 3) (-1),+ DimSlice (n - 1) n (-1),+ DimSlice (n - 1) n (-1),+ DimSlice 0 n 1+ ]+ ixfun = permute (slice (iota [n, n, n, n, n]) slc2) [3, 1, 2, 0]+ m = n `P.div` 3+ slice1 =+ Slice+ [ DimSlice 0 n 1,+ DimSlice (n - 1) n (-1),+ DimSlice (n - 1) n (-1),+ DimSlice 1 (m - 2) (-1)+ ]+ ixfun' = slice ixfun slice1+ in ixfun'++-- Imitates a case from memory expansion.+test_expand1 :: [TestTree]+test_expand1 =+ [ testCase "expand . iota1d" . compareOps $+ expand t nt (iota [n])+ ]+ where+ t = 3+ nt = 7++-- Imitates another case from memory expansion.+test_expand2 :: [TestTree]+test_expand2 =+ [ testCase "expand . iota2d" . compareOps $+ expand t nt (iota [n, n])+ ]+ where+ t = 3+ nt = 7++test_expand3 :: [TestTree]+test_expand3 =+ [ testCase "expand . permute . iota2d" . compareOps $+ expand t nt (permute (iota [n, n `div` 2]) [1, 0])+ ]+ where+ t = 3+ nt = 7++test_expand4 :: [TestTree]+test_expand4 =+ [ testCase "expand . slice . iota1d" . compareOps $+ expand t nt (slice (iota [n]) (Slice [DimSlice (n `div` 2) (n `div` 2) 1]))+ ]+ where+ t = 3+ nt = 7++test_flatSlice_iota :: [TestTree]+test_flatSlice_iota =+ singleton . testCase "flatSlice . iota" . compareOps $+ flatSlice (iota [n * n * n * n]) $+ FlatSlice 2 [FlatDimIndex (n * 2) 4, FlatDimIndex n 3, FlatDimIndex 1 2]++test_slice_flatSlice_iota :: [TestTree]+test_slice_flatSlice_iota =+ singleton . testCase "slice . flatSlice . iota " . compareOps $+ slice (flatSlice (iota [2 + n * n * n]) flat_slice) $+ Slice [DimFix 2, DimSlice 0 n 1, DimFix 0]+ where+ flat_slice = FlatSlice 2 [FlatDimIndex (n * n) 1, FlatDimIndex n 1, FlatDimIndex 1 1]++test_flatSlice_flatSlice_iota :: [TestTree]+test_flatSlice_flatSlice_iota =+ singleton . testCase "flatSlice . flatSlice . iota " . compareOps $+ flatSlice (flatSlice (iota [10 * 10]) flat_slice_1) flat_slice_2+ where+ flat_slice_1 = FlatSlice 17 [FlatDimIndex 3 27, FlatDimIndex 3 10, FlatDimIndex 3 1]+ flat_slice_2 = FlatSlice 2 [FlatDimIndex 2 (-2)]++test_flatSlice_slice_iota :: [TestTree]+test_flatSlice_slice_iota =+ singleton . testCase "flatSlice . slice . iota " . compareOps $+ flatSlice (slice (iota [210, 100]) $ Slice [DimSlice 10 100 2, DimFix 10]) flat_slice_1+ where+ flat_slice_1 = FlatSlice 17 [FlatDimIndex 3 27, FlatDimIndex 3 10, FlatDimIndex 3 1]++test_flatSlice_transpose_slice_iota :: [TestTree]+test_flatSlice_transpose_slice_iota =+ singleton . testCase "flatSlice . transpose . slice . iota " . compareOps $+ flatSlice (permute (slice (iota [20, 20]) $ Slice [DimSlice 1 5 2, DimSlice 0 5 2]) [1, 0]) flat_slice_1+ where+ flat_slice_1 = FlatSlice 1 [FlatDimIndex 2 2]++-- test_disjoint2 :: [TestTree]+-- test_disjoint2 =+-- let add_nw64 = (+)++-- mul_nw64 = (*)++-- sub64 = (-)++-- vname s i = VName (nameFromString s) i+-- in [ let gtid_8472 = TPrimExp $ LeafExp (vname "gtid" 8472) $ IntType Int64++-- gtid_8473 = TPrimExp $ LeafExp (vname "gtid" 8473) $ IntType Int64++-- gtid_8474 = TPrimExp $ LeafExp (vname "gtid" 8474) $ IntType Int64++-- num_blocks_8284 = TPrimExp $ LeafExp (vname "num_blocks" 8284) $ IntType Int64++-- nonnegs = freeIn [gtid_8472, gtid_8473, gtid_8474, num_blocks_8284]++-- j_m_i_8287 :: TPrimExp Int64 VName+-- j_m_i_8287 = num_blocks_8284 - 1++-- lessthans :: [(VName, PrimExp VName)]+-- lessthans =+-- [ (head $ namesToList $ freeIn gtid_8472, untyped j_m_i_8287),+-- (head $ namesToList $ freeIn gtid_8473, untyped j_m_i_8287),+-- (head $ namesToList $ freeIn gtid_8474, untyped (16 :: TPrimExp Int64 VName))+-- ]++-- lm1 :: IxFunLMAD.LMAD (TPrimExp Int64 VName)+-- lm1 =+-- IxFunLMAD.LMAD+-- 256+-- [ IxFunLMAD.LMADDim 256 0 (sub64 (num_blocks_8284) 1) 0 ,+-- IxFunLMAD.LMADDim 1 0 16 1 ,+-- IxFunLMAD.LMADDim 16 0 16 2+-- ]+-- lm2 :: IxFunLMAD.LMAD (TPrimExp Int64 VName)+-- lm2 =+-- IxFunLMAD.LMAD+-- (add_nw64 (add_nw64 (add_nw64 (add_nw64 (mul_nw64 (256) (num_blocks_8284)) (256)) (mul_nw64 (gtid_8472) (mul_nw64 (256) (num_blocks_8284)))) (mul_nw64 (gtid_8473) (256))) (mul_nw64 (gtid_8474) (16)))+-- [IxFunLMAD.LMADDim 1 0 16 0 ]+-- in testCase (pretty lm1 <> " and " <> pretty lm2) $ IxFunLMAD.disjoint2 lessthans nonnegs lm1 lm2 @? "Failed"+-- ]++-- test_lessThanish :: [TestTree]+-- test_lessThanish =+-- [testCase "0 < 1" $ IxFunLMAD.lessThanish mempty mempty 0 1 @? "Failed"]++-- test_lessThanOrEqualish :: [TestTree]+-- test_lessThanOrEqualish =+-- [testCase "1 <= 1" $ IxFunLMAD.lessThanOrEqualish mempty mempty 1 1 @? "Failed"]++_test_disjoint3 :: [TestTree]+_test_disjoint3 =+ let foo s = VName (nameFromString s)+ add_nw64 = (+)+ add64 = (+)+ mul_nw64 = (*)+ mul64 = (*)+ sub64 = (-)+ sdiv64 = IE.div+ sub_nw64 = (-)+ disjointTester asserts lessthans lm1 lm2 =+ let nonnegs = map (`LeafExp` IntType Int64) $ namesToList $ freeIn lm1 <> freeIn lm2++ scmap =+ M.fromList $+ map (\x -> (x, Prim $ IntType Int64)) $+ namesToList $+ freeIn lm1 <> freeIn lm2 <> freeIn lessthans <> freeIn asserts+ in IxFunLMAD.disjoint3 scmap asserts lessthans nonnegs lm1 lm2+ in [ testCase "lm1 and lm2" $+ let lessthans =+ [ ( i_12214,+ sdiv64 (sub64 n_blab 1) block_size_12121+ ),+ (gtid_12553, add64 1 i_12214)+ ]+ & map (\(v, p) -> (head $ namesToList $ freeIn v, untyped p))++ asserts =+ [ untyped ((2 * block_size_12121 :: TPrimExp Int64 VName) .<. n_blab :: TPrimExp Bool VName),+ untyped ((3 :: TPrimExp Int64 VName) .<. n_blab :: TPrimExp Bool VName)+ ]++ block_size_12121 = TPrimExp $ LeafExp (foo "block_size" 12121) $ IntType Int64+ i_12214 = TPrimExp $ LeafExp (foo "i" 12214) $ IntType Int64+ n_blab = TPrimExp $ LeafExp (foo "n" 1337) $ IntType Int64+ gtid_12553 = TPrimExp $ LeafExp (foo "gtid" 12553) $ IntType Int64++ lm1 =+ IxFunLMAD.LMAD+ (add_nw64 (mul64 block_size_12121 i_12214) (mul_nw64 (add_nw64 gtid_12553 1) (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))+ [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (sub_nw64 (sub_nw64 (add64 1 i_12214) gtid_12553) 1),+ IxFunLMAD.LMADDim 1 (block_size_12121 + 1)+ ]++ lm2 =+ IxFunLMAD.LMAD+ (block_size_12121 * i_12214)+ [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) gtid_12553,+ IxFunLMAD.LMADDim 1 (1 + block_size_12121)+ ]++ lm_w =+ IxFunLMAD.LMAD+ (add_nw64 (add64 (add64 1 n_blab) (mul64 block_size_12121 i_12214)) (mul_nw64 gtid_12553 (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))+ [ IxFunLMAD.LMADDim n_blab block_size_12121,+ IxFunLMAD.LMADDim 1 block_size_12121+ ]++ lm_blocks =+ IxFunLMAD.LMAD+ (block_size_12121 * i_12214 + n_blab + 1)+ [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (i_12214 + 1),+ IxFunLMAD.LMADDim n_blab block_size_12121,+ IxFunLMAD.LMADDim 1 block_size_12121+ ]++ lm_lower_per =+ IxFunLMAD.LMAD+ (block_size_12121 * i_12214)+ [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (i_12214 + 1),+ IxFunLMAD.LMADDim 1 (block_size_12121 + 1)+ ]++ res1 = disjointTester asserts lessthans lm1 lm_w+ res2 = disjointTester asserts lessthans lm2 lm_w+ res3 = disjointTester asserts lessthans lm_lower_per lm_blocks+ in res1 && res2 && res3 @? "Failed",+ testCase "nw second half" $ do+ let lessthans =+ [ ( i_12214,+ sdiv64 (sub64 n_blab 1) block_size_12121+ ),+ (gtid_12553, add64 1 i_12214)+ ]+ & map (\(v, p) -> (head $ namesToList $ freeIn v, untyped p))++ asserts =+ [ untyped ((2 * block_size_12121 :: TPrimExp Int64 VName) .<. n_blab :: TPrimExp Bool VName),+ untyped ((3 :: TPrimExp Int64 VName) .<. n_blab :: TPrimExp Bool VName)+ ]++ block_size_12121 = TPrimExp $ LeafExp (foo "block_size" 12121) $ IntType Int64+ i_12214 = TPrimExp $ LeafExp (foo "i" 12214) $ IntType Int64+ n_blab = TPrimExp $ LeafExp (foo "n" 1337) $ IntType Int64+ gtid_12553 = TPrimExp $ LeafExp (foo "gtid" 12553) $ IntType Int64++ lm1 =+ IxFunLMAD.LMAD+ (add_nw64 (add64 n_blab (sub64 (sub64 (mul64 n_blab (add64 1 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) 1)) (mul_nw64 (add_nw64 gtid_12553 1) (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))+ [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (sub_nw64 (sub_nw64 (sub64 (sub64 (sdiv64 (sub64 n_blab 1) block_size_12121) i_12214) 1) gtid_12553) 1),+ IxFunLMAD.LMADDim n_blab block_size_12121+ ]++ lm2 =+ IxFunLMAD.LMAD+ (add_nw64 (sub64 (sub64 (mul64 n_blab (add64 1 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) 1) (mul_nw64 (add_nw64 gtid_12553 1) (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))+ [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (sub_nw64 (sub_nw64 (sub64 (sub64 (sdiv64 (sub64 n_blab 1) block_size_12121) i_12214) 1) gtid_12553) 1),+ IxFunLMAD.LMADDim 1 (1 + block_size_12121)+ ]++ lm3 =+ IxFunLMAD.LMAD+ (add64 n_blab (sub64 (sub64 (mul64 n_blab (add64 1 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) 1))+ [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) gtid_12553,+ IxFunLMAD.LMADDim n_blab block_size_12121+ ]++ lm4 =+ IxFunLMAD.LMAD+ (sub64 (sub64 (mul64 n_blab (add64 1 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) 1)+ [ IxFunLMAD.LMADDim+ (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121))+ gtid_12553,+ IxFunLMAD.LMADDim+ 1+ (1 + block_size_12121)+ ]++ lm_w =+ IxFunLMAD.LMAD+ (add_nw64 (sub64 (mul64 n_blab (add64 2 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) (mul_nw64 gtid_12553 (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))+ [ IxFunLMAD.LMADDim n_blab block_size_12121,+ IxFunLMAD.LMADDim 1 block_size_12121+ ]++ res1 = disjointTester asserts lessthans lm1 lm_w+ res2 = disjointTester asserts lessthans lm2 lm_w+ res3 = disjointTester asserts lessthans lm3 lm_w+ res4 = disjointTester asserts lessthans lm4 lm_w+ in res1 && res2 && res3 && res4 @? "Failed " <> show [res1, res2, res3, res4],+ testCase "lud long" $+ let lessthans =+ [ bimap+ (head . namesToList . freeIn)+ untyped+ (step, num_blocks - 1 :: TPrimExp Int64 VName)+ ]++ step = TPrimExp $ LeafExp (foo "step" 1337) $ IntType Int64++ num_blocks = TPrimExp $ LeafExp (foo "n" 1338) $ IntType Int64++ lm1 =+ IxFunLMAD.LMAD+ (1024 * num_blocks * (1 + step) + 1024 * step)+ [ IxFunLMAD.LMADDim (1024 * num_blocks) (num_blocks - step - 1),+ IxFunLMAD.LMADDim 32 32,+ IxFunLMAD.LMADDim 1 32+ ]++ lm_w1 =+ IxFunLMAD.LMAD+ (1024 * num_blocks * step + 1024 * step)+ [ IxFunLMAD.LMADDim 32 32,+ IxFunLMAD.LMADDim 1 32+ ]++ lm_w2 =+ IxFunLMAD.LMAD+ ((1 + step) * 1024 * num_blocks + (1 + step) * 1024)+ [ IxFunLMAD.LMADDim (1024 * num_blocks) (num_blocks - step - 1),+ IxFunLMAD.LMADDim 1024 (num_blocks - step - 1),+ IxFunLMAD.LMADDim 1024 1,+ IxFunLMAD.LMADDim 32 1,+ IxFunLMAD.LMADDim 128 8,+ IxFunLMAD.LMADDim 4 8,+ IxFunLMAD.LMADDim 32 4,+ IxFunLMAD.LMADDim 1 4+ ]++ asserts =+ [ untyped ((1 :: TPrimExp Int64 VName) .<. num_blocks :: TPrimExp Bool VName)+ ]++ res1 = disjointTester asserts lessthans lm1 lm_w1+ res2 = disjointTester asserts lessthans lm1 lm_w2+ in res1 && res2 @? "Failed"+ ]
+ src-testing/Futhark/IR/Mem/IxFunWrapper.hs view
@@ -0,0 +1,72 @@+-- | Perform index function operations in both algebraic and LMAD+-- representations.+module Futhark.IR.Mem.IxFunWrapper+ ( IxFun,+ iota,+ permute,+ reshape,+ coerce,+ slice,+ flatSlice,+ expand,+ )+where++import Control.Monad (join)+import Futhark.IR.Mem.IxFun.Alg qualified as IA+import Futhark.IR.Mem.LMAD qualified as I+import Futhark.IR.Syntax (FlatSlice, Slice)+import Futhark.Util.IntegralExp++type Shape num = [num]++type Permutation = [Int]++type IxFun num = (Maybe (I.LMAD num), IA.IxFun num)++iota ::+ (IntegralExp num) =>+ Shape num ->+ IxFun num+iota x = (Just $ I.iota 0 x, IA.iota x)++permute ::+ IxFun num ->+ Permutation ->+ IxFun num+permute (l, a) x = (I.permute <$> l <*> pure x, IA.permute a x)++reshape ::+ (Eq num, IntegralExp num) =>+ IxFun num ->+ Shape num ->+ IxFun num+reshape (l, a) x = (join (I.reshape <$> l <*> pure x), IA.reshape a x)++coerce ::+ IxFun num ->+ Shape num ->+ IxFun num+coerce (l, a) x = (I.coerce <$> l <*> pure x, IA.coerce a x)++slice ::+ (Eq num, IntegralExp num) =>+ IxFun num ->+ Slice num ->+ IxFun num+slice (l, a) x = (I.slice <$> l <*> pure x, IA.slice a x)++flatSlice ::+ (IntegralExp num) =>+ IxFun num ->+ FlatSlice num ->+ IxFun num+flatSlice (l, a) x = (I.flatSlice <$> l <*> pure x, IA.flatSlice a x)++expand ::+ (IntegralExp num) =>+ num ->+ num ->+ IxFun num ->+ IxFun num+expand o p (lf, af) = (Just . I.expand o p =<< lf, IA.expand o p af)
+ src-testing/Futhark/IR/Prop/RearrangeTests.hs view
@@ -0,0 +1,54 @@+module Futhark.IR.Prop.RearrangeTests (tests) where++import Control.Applicative+import Futhark.IR.Prop.Rearrange+import Test.Tasty+import Test.Tasty.HUnit+import Test.Tasty.QuickCheck+import Prelude++tests :: TestTree+tests =+ testGroup "RearrangeTests" $+ isMapTransposeTests+ ++ [isMapTransposeProp]++isMapTransposeTests :: [TestTree]+isMapTransposeTests =+ [ testCase (unwords ["isMapTranspose", show perm, "==", show dres]) $+ isMapTranspose perm @?= dres+ | (perm, dres) <-+ [ ([0, 1, 4, 5, 2, 3], Just (2, 2, 2)),+ ([1, 0, 4, 5, 2, 3], Nothing),+ ([1, 0], Just (0, 1, 1)),+ ([0, 2, 1], Just (1, 1, 1)),+ ([0, 1, 2], Nothing),+ ([1, 0, 2], Nothing)+ ]+ ]++newtype Permutation = Permutation [Int]+ deriving (Eq, Ord, Show)++instance Arbitrary Permutation where+ arbitrary = do+ Positive n <- arbitrary+ Permutation <$> shuffle [0 .. n - 1]++isMapTransposeProp :: TestTree+isMapTransposeProp = testProperty "isMapTranspose corresponds to a map of transpose" prop+ where+ prop :: Permutation -> Bool+ prop (Permutation perm) =+ case isMapTranspose perm of+ Nothing -> True+ Just (r1, r2, r3) ->+ and+ [ r1 >= 0,+ r2 > 0,+ r3 > 0,+ r1 + r2 + r3 == length perm,+ let (mapped, notmapped) = splitAt r1 perm+ (pretrans, posttrans) = splitAt r2 notmapped+ in mapped ++ posttrans ++ pretrans == [0 .. length perm - 1]+ ]
+ src-testing/Futhark/IR/Prop/ReshapeTests.hs view
@@ -0,0 +1,236 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Futhark.IR.Prop.ReshapeTests+ ( tests,+ )+where++import Data.List qualified as L+import Futhark.IR.Prop.Constants+import Futhark.IR.Prop.Reshape+import Futhark.IR.Syntax+import Futhark.IR.SyntaxTests ()+import Test.Tasty+import Test.Tasty.HUnit++intShape :: [Int] -> Shape+intShape = Shape . map (intConst Int32 . toInteger)++reshapeOuterTests :: [TestTree]+reshapeOuterTests =+ [ testCase (unwords ["reshapeOuter", show sc, show n, show shape, "==", show sc_res]) $+ reshapeOuter (intShape sc) n (intShape shape) @?= intShape sc_res+ | (sc, n, shape, sc_res) <-+ [ ([1], 1, [4, 3], [1, 3]),+ ([1], 2, [4, 3], [1]),+ ([2, 2], 1, [4, 3], [2, 2, 3]),+ ([2, 2], 2, [4, 3], [2, 2])+ ]+ ]++reshapeInnerTests :: [TestTree]+reshapeInnerTests =+ [ testCase (unwords ["reshapeInner", show sc, show n, show shape, "==", show sc_res]) $+ reshapeInner (intShape sc) n (intShape shape) @?= intShape sc_res+ | (sc, n, shape, sc_res) <-+ [ ([1], 1, [4, 3], [4, 1]),+ ([1], 0, [4, 3], [1]),+ ([2, 2], 1, [4, 3], [4, 2, 2]),+ ([2, 2], 0, [4, 3], [2, 2])+ ]+ ]++dimFlatten :: Int -> Int -> d -> DimSplice d+dimFlatten i k w = DimSplice i k (Shape [w])++dimUnflatten :: Int -> [d] -> DimSplice d+dimUnflatten i ws = DimSplice i 1 (Shape ws)++dimCoerce :: Int -> d -> DimSplice d+dimCoerce i w = DimSplice i 1 (Shape [w])++dimSplice :: Int -> Int -> [d] -> DimSplice d+dimSplice i n s = DimSplice i n $ Shape s++flipReshapeRearrangeTests :: [TestTree]+flipReshapeRearrangeTests =+ [ testCase+ ( unwords+ [ "flipReshapeRearrange",+ show v0_shape,+ show v1_shape,+ show perm+ ]+ )+ $ flipReshapeRearrange v0_shape v1_shape perm @?= res+ | (v0_shape :: [String], v1_shape, perm, res) <-+ [ ( ["A", "B", "C"],+ ["A", "BC"],+ [1, 0],+ Just [1, 2, 0]+ ),+ ( ["A", "B", "C", "D"],+ ["A", "BCD"],+ [1, 0],+ Just [1, 2, 3, 0]+ ),+ ( ["A"],+ ["B", "C"],+ [1, 0],+ Nothing+ ),+ ( ["A", "B", "C"],+ ["AB", "C"],+ [1, 0],+ Just [2, 0, 1]+ ),+ ( ["A", "B", "C", "D"],+ ["ABC", "D"],+ [1, 0],+ Just [3, 0, 1, 2]+ )+ ]+ ]++flipRearrangeReshapeTests :: [TestTree]+flipRearrangeReshapeTests =+ [ testCase+ ( unwords+ [ "flipRearrangeReshape",+ show perm,+ prettyStringOneLine newshape+ ]+ )+ $ flipRearrangeReshape perm newshape @?= res+ | (perm, newshape :: NewShape String, res) <-+ [ ( [1, 0],+ NewShape+ [dimUnflatten 1 ["B", "C"]]+ (Shape ["A", "B", "C"]),+ Just+ ( NewShape+ [dimUnflatten 0 ["B", "C"]]+ (Shape ["B", "C", "A"]),+ [2, 0, 1]+ )+ ),+ ( [1, 0],+ NewShape+ [dimFlatten 0 2 "AB"]+ (Shape ["AB"]),+ Nothing+ )+ ]+ ]++simplifyTests :: TestTree+simplifyTests =+ testGroup+ "simplifyNewShape"+ [ testCase "Inverse flatten and unflatten - simple case" $+ lhs+ ["A", "B"]+ [dimFlatten 0 2 "AB", dimUnflatten 0 ["A", "B"]]+ @?= Just [],+ testCase "Non-inverse flatten and unflatten - simple case" $+ lhs+ ["A", "B"]+ [dimFlatten 0 2 "AB", dimUnflatten 0 ["C", "D"]]+ @?= Just [dimSplice 0 2 ["C", "D"]],+ testCase "Inverse flatten and unflatten - separated by coercion" $+ lhs+ ["A", "B"]+ [ dimFlatten 0 2 "AB",+ dimCoerce 0 "CD",+ dimUnflatten 0 ["C", "D"]+ ]+ @?= Just [dimSplice 0 2 ["C", "D"]],+ testCase "Two unflattens - simple case" $+ lhs+ ["ABC"]+ [dimUnflatten 0 ["A", "BC"], dimUnflatten 1 ["B", "C"]]+ @?= Just [dimUnflatten 0 ["A", "B", "C"]],+ testCase "Two unflattens with unchanged prefix" $+ lhs+ ["A", "B", "C", "D", "E"]+ [ DimSplice 3 2 $ Shape ["DE"],+ DimSplice 2 2 $ Shape ["CDE"]+ ]+ @?= Just [dimFlatten 2 3 "CDE"],+ testCase "Identity coerce" $+ lhs+ ["A", "B", "C"]+ [dimCoerce 1 "B", dimCoerce 2 "C"]+ @?= Just [],+ testCase "Identity coerce (multiple dimensions)" $+ lhs+ ["A", "B", "C"]+ [DimSplice 1 2 (Shape ["B", "C"])]+ @?= Just [],+ testCase "Identity coerce (with non-identity stuff afterwards)" $+ lhs+ ["B", "CD"]+ [dimCoerce 0 "B", dimUnflatten 1 ["C", "D"]]+ @?= Just [dimUnflatten 1 ["C", "D"]],+ testCase "Get rid of a coerce before an unflatten" $+ lhs+ ["CD"]+ [dimCoerce 0 "AB", dimUnflatten 0 ["A", "B"]]+ @?= Just [dimUnflatten 0 ["A", "B"]],+ testCase "Get rid of a coerce after a flatten" $+ lhs+ ["A", "B", "C"]+ [dimFlatten 0 2 "ABC", dimCoerce 0 "K"]+ @?= Just [dimFlatten 0 2 "K"],+ testCase "Flatten and unflatten (invariant suffix)" $+ lhs+ ["A", "B", "C"]+ [dimFlatten 0 3 "ABC", dimUnflatten 0 ["D", "E", "C"]]+ @?= Just [dimSplice 0 2 ["D", "E"]],+ testCase "Flatten and unflatten (invariant prefix)" $+ lhs+ ["A", "B", "C"]+ [dimFlatten 0 3 "ABC", dimUnflatten 0 ["A", "D", "E"]]+ @?= Just [dimSplice 1 2 ["D", "E"]],+ testCase "Invariant part of splice" $+ lhs+ ["A", "B", "C", "D"]+ [DimSplice 1 3 $ Shape ["BC", "D"]]+ @?= Just [DimSplice 1 2 $ Shape ["BC"]],+ testCase "Necessary coercion" $+ lhs+ ["A", "B"]+ [dimCoerce 0 "C", dimCoerce 1 "D"]+ @?= Nothing,+ testCase "Another necessary coercion" $+ lhs+ ["A", "B", "C"]+ [dimCoerce 0 "A'", dimCoerce 1 "A'", dimCoerce 2 "A'"]+ @?= Nothing,+ testCase "Long with redundancies" $+ lhs+ ["A", "B", "C", "D"]+ [ DimSplice 1 3 $ Shape ["BC", "D"],+ dimCoerce 1 "BC",+ dimCoerce 2 "D",+ dimFlatten 1 2 "BCD",+ dimFlatten 0 2 "ABCD"+ ]+ @?= Just [dimFlatten 0 4 "ABCD"]+ ]+ where+ lhs orig_shape ss =+ let res_shape :: ShapeBase String =+ L.foldl' applySplice (Shape orig_shape) ss+ in dimSplices+ <$> simplifyNewShape (Shape orig_shape) (NewShape ss res_shape)++tests :: TestTree+tests =+ testGroup "ReshapeTests" . mconcat $+ [ reshapeOuterTests,+ reshapeInnerTests,+ flipReshapeRearrangeTests,+ flipRearrangeReshapeTests,+ [simplifyTests]+ ]
+ src-testing/Futhark/IR/PropTests.hs view
@@ -0,0 +1,18 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Futhark.IR.PropTests+ ( tests,+ )+where++import Futhark.IR.Prop.RearrangeTests qualified+import Futhark.IR.Prop.ReshapeTests qualified+import Test.Tasty++tests :: TestTree+tests =+ testGroup+ "PropTests"+ [ Futhark.IR.Prop.ReshapeTests.tests,+ Futhark.IR.Prop.RearrangeTests.tests+ ]
+ src-testing/Futhark/IR/Syntax/CoreTests.hs view
@@ -0,0 +1,100 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Futhark.IR.Syntax.CoreTests (tests) where++import Control.Applicative+import Data.Loc (Loc (..), Pos (..))+import Futhark.IR.Pretty (prettyString)+import Futhark.IR.Syntax.Core+import Language.Futhark.CoreTests ()+import Language.Futhark.PrimitiveTests ()+import Test.QuickCheck+import Test.Tasty+import Test.Tasty.HUnit+import Prelude++instance Arbitrary NoUniqueness where+ arbitrary = pure NoUniqueness++instance (Arbitrary shape, Arbitrary u) => Arbitrary (TypeBase shape u) where+ arbitrary =+ oneof+ [ Prim <$> arbitrary,+ Array <$> arbitrary <*> arbitrary <*> arbitrary+ ]++instance Arbitrary Ident where+ arbitrary = Ident <$> arbitrary <*> arbitrary++instance Arbitrary Rank where+ arbitrary = Rank <$> elements [1 .. 9]++instance Arbitrary Shape where+ arbitrary = Shape . map intconst <$> listOf1 (elements [1 .. 9])+ where+ intconst = Constant . IntValue . Int32Value++subShapeTests :: [TestTree]+subShapeTests =+ [ shape [free 1, free 2] `isSubShapeOf` shape [free 1, free 2],+ shape [free 1, free 3] `isNotSubShapeOf` shape [free 1, free 2],+ shape [free 1] `isNotSubShapeOf` shape [free 1, free 2],+ shape [free 1, free 2] `isSubShapeOf` shape [free 1, Ext 3],+ shape [Ext 1, Ext 2] `isNotSubShapeOf` shape [Ext 1, Ext 1],+ shape [Ext 1, Ext 1] `isSubShapeOf` shape [Ext 1, Ext 2]+ ]+ where+ shape :: [ExtSize] -> ExtShape+ shape = Shape++ free :: Int -> ExtSize+ free = Free . Constant . IntValue . Int32Value . fromIntegral++ isSubShapeOf shape1 shape2 =+ subShapeTest shape1 shape2 True+ isNotSubShapeOf shape1 shape2 =+ subShapeTest shape1 shape2 False++ subShapeTest :: ExtShape -> ExtShape -> Bool -> TestTree+ subShapeTest shape1 shape2 expected =+ testCase+ ( "subshapeOf "+ ++ prettyString shape1+ ++ " "+ ++ prettyString shape2+ ++ " == "+ ++ show expected+ )+ $ shape1 `subShapeOf` shape2 @?= expected++provenanceTests :: [TestTree]+provenanceTests =+ [ testGroup+ "<>"+ [ testCase "simple" $+ (Provenance [] line1 <> Provenance [] line0) @?= Provenance [] lines01,+ testCase "mempty left" $+ (Provenance [] mempty <> Provenance [] line0) @?= Provenance [] line0,+ testCase "mempty right" $+ (Provenance [] line1 <> Provenance [] mempty) @?= Provenance [] line1+ ],+ testGroup+ "stackProvenance"+ [ testCase "encloses" $+ (Provenance [] line0 `stackProvenance` Provenance [] line0_sub)+ @?= Provenance [] line0_sub+ ]+ ]+ where+ line0 = Loc (Pos "" 0 1 0) (Pos "" 0 10 10)+ line0_sub = Loc (Pos "" 0 2 1) (Pos "" 0 9 9)+ line1 = Loc (Pos "" 1 1 0) (Pos "" 1 10 20)+ lines01 = Loc (Pos "" 0 1 0) (Pos "" 1 10 20)++tests :: TestTree+tests =+ testGroup+ "Internal CoreTests"+ [ testGroup "subShape" subShapeTests,+ testGroup "Provenance" provenanceTests+ ]
+ src-testing/Futhark/IR/SyntaxTests.hs view
@@ -0,0 +1,33 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Futhark.IR.SyntaxTests (parseString) where++import Data.String+import Data.Text qualified as T+import Futhark.IR.Parse+import Futhark.IR.Syntax++-- There isn't anything to test in this module, but we define some+-- convenience instances.++parseString :: String -> (FilePath -> T.Text -> Either T.Text a) -> String -> a+parseString desc p =+ either (error . T.unpack) id . p ("IsString " <> desc) . T.pack++instance IsString Type where+ fromString = parseString "Type" parseType++instance IsString DeclExtType where+ fromString = parseString "DeclExtType" parseDeclExtType++instance IsString DeclType where+ fromString = parseString "DeclType" parseDeclType++instance IsString VName where+ fromString = parseString "VName" parseVName++instance IsString SubExp where+ fromString = parseString "SubExp" parseSubExp++instance IsString SubExpRes where+ fromString = parseString "SubExpRes" parseSubExpRes
+ src-testing/Futhark/Internalise/TypesValuesTests.hs view
@@ -0,0 +1,170 @@+module Futhark.Internalise.TypesValuesTests (tests) where++import Control.Monad.Free (Free (..))+import Data.Map qualified as M+import Data.String (fromString)+import Futhark.IR.Syntax hiding (Free)+import Futhark.IR.SyntaxTests ()+import Futhark.Internalise.TypesValues+import Language.Futhark.SyntaxTests ()+import Test.Tasty+import Test.Tasty.HUnit++internaliseTypeTests :: TestTree+internaliseTypeTests =+ testGroup+ "internaliseType"+ [ mkTest+ "[0]()"+ [Free [Pure "[0i64]unit"]],+ mkTest+ "{a: [t_7447][n_7448](f32, f32), b: i64, c: i64}"+ [Free [Pure "[t_7447][n_7448]f32", Pure "[t_7447][n_7448]f32"], Pure "i64", Pure "i64"],+ mkTest+ "([0]i32, {a: f32, b: f32, c: f32, d: [0]((f32, f32), (f32, f32))})"+ [ Free [Pure "[0i64]i32"],+ Pure "f32",+ Pure "f32",+ Pure "f32",+ Free [Pure "[0i64]f32", Pure "[0i64]f32", Pure "[0i64]f32", Pure "[0i64]f32"]+ ],+ mkTest+ "[0]([1]i32, f32)"+ [Free [Free [Pure "[0i64][1i64]i32"], Pure "[0i64]f32"]]+ ]+ where+ mkTest x y =+ testCase (prettyString x) $ internaliseType x @?= y++sumTypeTests :: TestTree+sumTypeTests =+ testGroup+ "internaliseConstructors"+ [ testCase "Dedup of primitives" $+ internaliseConstructors+ ( M.fromList+ [ ("foo", [Pure "i64"]),+ ("bar", [Pure "i64"])+ ]+ )+ @?= ( [Pure "i64"],+ [ ("bar", [0]),+ ("foo", [0])+ ]+ ),+ testCase "Dedup of array" $+ internaliseConstructors+ ( M.fromList+ [ ("foo", [Pure "[?0]i64"]),+ ("bar", [Pure "[?0]i64"])+ ]+ )+ @?= ( [Pure "[?0]i64", Pure "[?0]i64"],+ [ ("bar", [0]),+ ("foo", [1])+ ]+ ),+ testCase+ "Dedup of array of tuple"+ $ internaliseConstructors+ ( M.fromList+ [ ("foo", [Free [Pure "[?0]i64", Pure "[?0]i64"]]),+ ("bar", [Pure "[?0]i64"])+ ]+ )+ @?= ( [Pure "[?0]i64", Free [Pure "[?0]i64", Pure "[?0]i64"]],+ [ ("bar", [0]),+ ("foo", [1, 2])+ ]+ )+ ]++-- Be aware that some of these tests simply reinforce current+-- behaviour - it may be that we want to restrict aliasing even+-- further in the future; these tests would have to be updated in such+-- cases.+inferAliasesTests :: TestTree+inferAliasesTests =+ testGroup+ "inferAliases"+ [ mkTest+ [Free [Pure "[0i64]i32"]]+ [Free [Pure "[?0]i32"]]+ [[("[?0]i32", RetAls [0] [0])]],+ mkTest+ [Free [Pure "[0i64]i32", Pure "[0i64]i32"]]+ [Free [Pure "[0i64]i32", Pure "[0i64]i32"]]+ [ [ ("[0i64]i32", RetAls [0] [0]),+ ("[0i64]i32", RetAls [1] [1])+ ]+ ],+ -- Basically zip.+ mkTest+ [Free [Pure "[n_0]i32"], Free [Pure "[n_0]i32"]]+ [Free [Pure "[n_0]i32", Pure "[n_0]i32"]]+ [ [ ("[n_0]i32", RetAls [] [0]),+ ("[n_0]i32", RetAls [] [1])+ ]+ ],+ mkTest+ [Free [Pure "[0i64]i32"], Free [Pure "[0i64]i32", Pure "[0i64]i32"]]+ [Free [Pure "[?0]i32", Pure "[?0]i32"]]+ [ [ ("[?0]i32", RetAls [1] [0]),+ ("[?0]i32", RetAls [2] [1])+ ]+ ],+ mkTest+ [Free [Pure "[0i64][1i64]i32", Pure "[0i64][1i64]i32"]]+ [Free [Pure "[?0]i32", Pure "[?0]i32"]]+ [ [ ("[?0]i32", RetAls [0] [0]),+ ("[?0]i32", RetAls [1] [1])+ ]+ ],+ -- Basically unzip.+ mkTest+ [Free [Pure "[n_0][n_1]i32", Pure "[n_0][n_1]i32"]]+ [Free [Pure "[?0]i32"], Free [Pure "[?0]i32"]]+ [ [("[?0]i32", RetAls [] [0, 1])],+ [("[?0]i32", RetAls [] [0, 1])]+ ],+ mkTest+ [ Free [Pure "*[n_0][n_1]i32"],+ Free [Pure "[n_2]i64"],+ Free [Pure "[n_3]i64"]+ ]+ [Free [Pure "*[n_0][n_1]i32"]]+ [[("*[n_0][n_1]i32", RetAls [] [])]],+ mkTest+ [Free [Pure "[n_0]i32", Free [Pure "[n_0][n_1]i32"]]]+ [Free [Pure "[n_0]i32"]]+ [[("[n_0]i32", RetAls [1] [0])]],+ mkTest+ []+ [ Free [Pure "[n_0]i32", Free [Pure "[n_0][n_1]i32"]],+ Free [Pure "[n_0]i32"]+ ]+ [ [("[n_0]i32", RetAls [] [0]), ("[n_0][n_1]i32", RetAls [] [1])],+ [("[n_0]i32", RetAls [] [1, 2])]+ ],+ mkTest+ [Free [Pure "[n_0]i32"]]+ [Free [Pure "[m_1][m_1]i32"]]+ [ [("[m_1][m_1]i32", RetAls [0] [0])]+ ]+ ]+ where+ mkTest all_param_ts all_res_ts expected =+ testCase (show all_param_ts <> " " <> show all_res_ts) $+ inferAliases+ (map (fmap fromString) all_param_ts)+ (map (fmap fromString) all_res_ts)+ @?= expected++tests :: TestTree+tests =+ testGroup+ "Futhark.Internalise.TypesValuesTests"+ [ internaliseTypeTests,+ sumTypeTests,+ inferAliasesTests+ ]
+ src-testing/Futhark/Optimise/ArrayLayout/AnalyseTests.hs view
@@ -0,0 +1,241 @@+module Futhark.Optimise.ArrayLayout.AnalyseTests (tests) where++import Data.Map.Strict qualified as M+import Futhark.Analysis.AccessPattern+import Futhark.IR.GPU+import Futhark.IR.GPUTests ()+import Futhark.IR.SyntaxTests ()+import Test.Tasty+import Test.Tasty.HUnit++tests :: TestTree+tests = testGroup "Analyse" [analyseStmTests]++analyseStmTests :: TestTree+analyseStmTests =+ testGroup+ "analyseStm"+ [analyseIndexTests, analyseDimAccessesTests]++analyseIndexTests :: TestTree+analyseIndexTests =+ testGroup+ "analyseIndex"+ $ do+ let arr_name = "xss_5144"+ -- ============================= TestCase0 =============================+ -- Most simple case where we want to manifest an array, hence, we record+ -- the Index in the IndexTable.+ let testCase0 = testCase "2D manifest" $ do+ let ctx =+ mempty+ { parents =+ [ SegOpName (SegmentedMap "defunc_0_map_res_5204"),+ LoopBodyName "defunc_0_f_res_5208"+ ],+ assignments =+ M.fromList+ [ ("gtid_5205", VariableInfo mempty 0 mempty ThreadID),+ ("i_5209", VariableInfo mempty 1 mempty LoopVar)+ ]+ }+ let patternNames = ["b_5211"]+ let dimFixes =+ [ DimFix (Var "gtid_5205"),+ DimFix (Var "i_5209")+ ]+ let indexTable =+ M.fromList+ [ ( SegmentedMap "defunc_0_map_res_5204",+ M.fromList+ [ ( (arr_name, [], [0 .. 1]),+ M.fromList+ [ ( "b_5211",+ [ DimAccess (M.fromList [("gtid_5205", Dependency 0 ThreadID)]) (Just "gtid_5205"),+ DimAccess (M.fromList [("i_5209", Dependency 1 LoopVar)]) (Just "i_5209")+ ]+ )+ ]+ )+ ]+ )+ ]+ let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes+ indexTable' @?= indexTable++ -- ============================= TestCase2 =============================+ -- We don't want to manifest an array with only one dimension, so we don't+ -- record anything in the IndexTable.+ let testCase1 = testCase "1D manifest" $ do+ let ctx =+ mempty+ { parents =+ [ SegOpName (SegmentedMap "defunc_0_map_res_5204"),+ LoopBodyName "defunc_0_f_res_5208"+ ]+ }+ let patternNames = ["b_5211"]+ let dimFixes = [DimFix "i_5209"]++ let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes+ indexTable' @?= mempty++ -- ============================= TestCase1 =============================+ -- We don't want to record anything to the IndexTable when the array is+ -- not accessed inside a SegMap+ -- TODO: Create a similar one for MC with loops+ let testCase2 = testCase "Not inside SegMap" $ do+ let ctx = mempty+ let patternNames = ["b_5211"]+ let dimFixes =+ [ DimFix "gtid_5205",+ DimFix "i_5209"+ ]+ let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes+ indexTable' @?= mempty++ -- ============================= TestCase3 =============================+ -- If an array is allocated inside a loop or SegMap, we want to record that+ -- information in the ArrayName of the IndexTable.+ let testCase3 = testCase "Allocated inside SegMap" $ do+ let parents' =+ [ SegOpName (SegmentedMap "defunc_0_map_res_5204"),+ LoopBodyName "defunc_0_f_res_5208"+ ]+ let ctx =+ mempty+ { parents = parents',+ assignments =+ M.fromList+ [ ("gtid_5205", VariableInfo mempty 0 mempty ThreadID),+ ("i_5209", VariableInfo mempty 1 mempty LoopVar),+ (arr_name, VariableInfo mempty 0 parents' Variable)+ ]+ }+ let patternNames = ["b_5211"]+ let dimFixes =+ [ DimFix "gtid_5205",+ DimFix "i_5209"+ ]+ let indexTable =+ M.fromList+ [ ( SegmentedMap "defunc_0_map_res_5204",+ M.fromList+ [ ( (arr_name, parents', [0 .. 1]),+ M.fromList+ [ ( "b_5211",+ [ DimAccess (M.fromList [("gtid_5205", Dependency 0 ThreadID)]) (Just "gtid_5205"),+ DimAccess (M.fromList [("i_5209", Dependency 1 LoopVar)]) (Just "i_5209")+ ]+ )+ ]+ )+ ]+ )+ ]+ let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes+ indexTable' @?= indexTable++ -- ============================= TestCase4 =============================+ -- If the vars in the index are temporaries, we want to reduce them to+ -- to the thread IDs and or loop counters they are functions of.+ let testCase4 = testCase "Reduce dependencies" $ do+ let ctx =+ mempty+ { parents =+ [ SegOpName (SegmentedMap "defunc_0_map_res_5204"),+ LoopBodyName "defunc_0_f_res_5208"+ ],+ assignments =+ M.fromList+ [ ("gtid_5205", VariableInfo mempty 0 mempty ThreadID),+ ("i_5209", VariableInfo mempty 1 mempty LoopVar),+ ("tmp0_5210", VariableInfo (namesFromList ["gtid_5205"]) 2 mempty Variable),+ ("tmp1_5211", VariableInfo (namesFromList ["i_5209"]) 3 mempty Variable),+ ("k_5212", VariableInfo mempty 1 mempty ConstType)+ ]+ }+ let patternNames = ["b_5211"]+ let dimFixes =+ [ DimFix "tmp0_5210",+ DimFix "tmp1_5211",+ DimFix "k_5212"+ ]+ let indexTable =+ M.fromList+ [ ( SegmentedMap "defunc_0_map_res_5204",+ M.fromList+ [ ( (arr_name, [], [0 .. 2]),+ M.fromList+ [ ( "b_5211",+ [ DimAccess (M.fromList [("gtid_5205", Dependency 0 ThreadID)]) (Just "tmp0_5210"),+ DimAccess (M.fromList [("i_5209", Dependency 1 LoopVar)]) (Just "tmp1_5211"),+ DimAccess mempty (Just "k_5212")+ ]+ )+ ]+ )+ ]+ )+ ]+ let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes+ indexTable' @?= indexTable++ [testCase0, testCase1, testCase2, testCase3, testCase4]++analyseDimAccessesTests :: TestTree+analyseDimAccessesTests = testGroup+ "analyseDimAccesses"+ $ do+ let testCase0 = testCase "Fold" $ do+ let indexTable =+ M.fromList+ [ ( SegmentedMap "defunc_0_map_res_5204",+ M.fromList+ [ ( ("xss_5144", [], [0, 1]),+ M.fromList+ [ ( "b_5211",+ [ DimAccess (M.fromList [("gtid_5205", Dependency 0 ThreadID)]) (Just "gtid_5205"),+ DimAccess (M.fromList [("i_5209", Dependency 1 LoopVar)]) (Just "i_5209")+ ]+ )+ ]+ )+ ]+ )+ ]+ let indexTable' = (analyseDimAccesses @GPU) prog0+ indexTable' @?= indexTable++ [testCase0]+ where+ prog0 :: Prog GPU+ prog0 =+ "\+ \entry(\"main\",\+ \ {xss: [][]i64},\+ \ {[]i64})\+ \ entry_main (n_5142 : i64,\+ \ m_5143 : i64,\+ \ xss_5144 : [n_5142][m_5143]i64)\+ \ : {[n_5142]i64#([2], [0])} = {\+ \ let {segmap_group_size_5202 : i64} =\+ \ get_size(segmap_group_size_5190, thread_block_size)\+ \ let {segmap_usable_groups_5203 : i64} =\+ \ sdiv_up64(n_5142, segmap_group_size_5202)\+ \ let {defunc_0_map_res_5204 : [n_5142]i64} =\+ \ segmap(thread; ; grid=segmap_usable_groups_5203; blocksize=segmap_group_size_5202)\+ \ (gtid_5205 < n_5142) (~phys_tid_5206) : {i64} {\+ \ let {defunc_0_f_res_5208 : i64} =\+ \ loop {acc_5210 : i64} = {0i64}\+ \ for i_5209:i64 < m_5143 do {\+ \ let {b_5211 : i64} =\+ \ xss_5144[gtid_5205, i_5209]\+ \ let {defunc_0_f_res_5212 : i64} =\+ \ add64(acc_5210, b_5211)\+ \ in {defunc_0_f_res_5212}\+ \ }\+ \ return {returns defunc_0_f_res_5208}\+ \ }\+ \ in {defunc_0_map_res_5204}\+ \}"
+ src-testing/Futhark/Optimise/ArrayLayout/LayoutTests.hs view
@@ -0,0 +1,163 @@+module Futhark.Optimise.ArrayLayout.LayoutTests (tests) where++import Data.Map.Strict qualified as M+import Futhark.Analysis.AccessPattern+import Futhark.Analysis.PrimExp+import Futhark.FreshNames+import Futhark.IR.GPU (GPU)+import Futhark.IR.GPUTests ()+import Futhark.Optimise.ArrayLayout.Layout+import Language.Futhark.Core+import Test.Tasty+import Test.Tasty.HUnit++tests :: TestTree+tests =+ testGroup+ "Layout"+ [commonPermutationEliminatorsTests]++commonPermutationEliminatorsTests :: TestTree+commonPermutationEliminatorsTests =+ testGroup+ "commonPermutationEliminators"+ [permutationTests, nestTests, dimAccessTests, constIndexElimTests]++permutationTests :: TestTree+permutationTests =+ testGroup "Permutations" $+ do+ -- This isn't the way to test this, in reality we should provide realistic+ -- access patterns that might result in the given permutations.+ -- Luckily we only use the original access for one check atm.+ [ testCase (unwords [show perm, "->", show res]) $+ commonPermutationEliminators perm [] @?= res+ | (perm, res) <-+ [ ([0], True),+ ([1, 0], False),+ ([0, 1], True),+ ([0, 0], True),+ ([1, 1], True),+ ([1, 2, 0], False),+ ([2, 0, 1], False),+ ([0, 1, 2], True),+ ([1, 0, 2], True),+ ([2, 1, 0], True),+ ([2, 2, 0], True),+ ([2, 1, 1], True),+ ([1, 0, 1], True),+ ([0, 0, 0], True),+ ([0, 1, 2, 3, 4], True),+ ([1, 0, 2, 3, 4], True),+ ([2, 3, 0, 1, 4], True),+ ([3, 4, 2, 0, 1], True),+ ([2, 3, 4, 0, 1], False),+ ([1, 2, 3, 4, 0], False),+ ([3, 4, 0, 1, 2], False)+ ]+ ]++nestTests :: TestTree+nestTests = testGroup "Nests" $+ do+ let names = generateNames 2+ [ testCase (unwords [args, "->", show res]) $+ commonPermutationEliminators [1, 0] nest @?= res+ | (args, nest, res) <-+ [ ("[]", [], False),+ ("[CondBodyName]", [CondBodyName] <*> names, False),+ ("[SegOpName]", [SegOpName . SegmentedMap] <*> names, True),+ ("[LoopBodyName]", [LoopBodyName] <*> names, False),+ ("[SegOpName, CondBodyName]", [SegOpName . SegmentedMap, CondBodyName] <*> names, True),+ ("[CondBodyName, LoopBodyName]", [CondBodyName, LoopBodyName] <*> names, False)+ ]+ ]++dimAccessTests :: TestTree+dimAccessTests = testGroup "DimAccesses" [] -- TODO: Write tests for the part of commonPermutationEliminators that checks the complexity of the DimAccesses.++constIndexElimTests :: TestTree+constIndexElimTests =+ testGroup+ "constIndexElimTests"+ [ testCase "gpu eliminates indexes with constant in any dim" $ do+ let primExpTable =+ M.fromList+ [ ("gtid_4", Just (LeafExp "n_4" (IntType Int64))),+ ("i_5", Just (LeafExp "n_4" (IntType Int64)))+ ]+ layoutTableFromIndexTable primExpTable accessTableGPU @?= mempty,+ testCase "gpu ignores when not last" $ do+ let primExpTable =+ M.fromList+ [ ("gtid_4", Just (LeafExp "gtid_4" (IntType Int64))),+ ("gtid_5", Just (LeafExp "gtid_5" (IntType Int64))),+ ("i_6", Just (LeafExp "i_6" (IntType Int64)))+ ]+ layoutTableFromIndexTable primExpTable accessTableGPUrev+ @?= M.fromList+ [ ( SegmentedMap "mapres_1",+ M.fromList+ [ ( ("a_2", [], [0, 1, 2, 3]),+ M.fromList [("A_3", [2, 3, 0, 1])]+ )+ ]+ )+ ]+ ]+ where+ accessTableGPU :: IndexTable GPU+ accessTableGPU =+ singleAccess+ [ singleParAccess 0 "gtid_4",+ DimAccess mempty Nothing,+ singleSeqAccess 1 "i_5"+ ]++ accessTableGPUrev :: IndexTable GPU+ accessTableGPUrev =+ singleAccess+ [ singleParAccess 1 "gtid_4",+ singleParAccess 2 "gtid_5",+ singleSeqAccess 0 "i_5",+ singleSeqAccess 2 "gtid_4"+ ]++singleAccess :: [DimAccess rep] -> IndexTable rep+singleAccess dims =+ M.fromList+ [ ( sgOp,+ M.fromList+ [ ( ("A_2", [], [0, 1, 2, 3]),+ M.fromList+ [ ( "a_3",+ dims+ )+ ]+ )+ ]+ )+ ]+ where+ sgOp = SegmentedMap {vnameFromSegOp = "mapres_1"}++singleParAccess :: Int -> VName -> DimAccess rep+singleParAccess level name =+ DimAccess+ (M.singleton name $ Dependency level ThreadID)+ (Just name)++singleSeqAccess :: Int -> VName -> DimAccess rep+singleSeqAccess level name =+ DimAccess+ (M.singleton name $ Dependency level LoopVar)+ (Just name)++generateNames :: Int -> [VName]+generateNames count = do+ let (name, source) = newName blankNameSource "i_0"+ fst $ foldl f ([name], source) [1 .. count - 1]+ where+ f (names, source) _ = do+ let (name, source') = newName source (last names)+ (names ++ [name], source')
+ src-testing/Futhark/Optimise/ArrayLayoutTests.hs view
@@ -0,0 +1,15 @@+module Futhark.Optimise.ArrayLayoutTests (tests) where++import Futhark.Analysis.PrimExp.TableTests qualified+import Futhark.Optimise.ArrayLayout.AnalyseTests qualified+import Futhark.Optimise.ArrayLayout.LayoutTests qualified+import Test.Tasty++tests :: TestTree+tests =+ testGroup+ "OptimizeArrayLayoutTests"+ [ Futhark.Optimise.ArrayLayout.AnalyseTests.tests,+ Futhark.Optimise.ArrayLayout.LayoutTests.tests,+ Futhark.Analysis.PrimExp.TableTests.tests+ ]
+ src-testing/Futhark/Optimise/MemoryBlockMerging/GreedyColoringTests.hs view
@@ -0,0 +1,80 @@+module Futhark.Optimise.MemoryBlockMerging.GreedyColoringTests+ ( tests,+ )+where++import Control.Arrow ((***))+import Data.Function ((&))+import Data.Map qualified as M+import Data.Set qualified as S+import Futhark.Optimise.MemoryBlockMerging.GreedyColoring qualified as GreedyColoring+import Test.Tasty+import Test.Tasty.HUnit++tests :: TestTree+tests =+ testGroup+ "GreedyColoringTests"+ [psumTest, allIntersect, emptyGraph, noIntersections, differentSpaces]++psumTest :: TestTree+psumTest =+ testCase "psumTest"+ $ assertEqual+ "Color simple 1-2-3 using two colors"+ ( [(0, "shared"), (1, "shared")] :: [(Int, String)],+ [(1 :: Int, 0), (2, 1), (3, 0)]+ )+ $ (M.toList *** M.toList)+ $ GreedyColoring.colorGraph+ (M.fromList [(1, "shared"), (2, "shared"), (3, "shared")])+ $ S.fromList [(1, 2), (2, 3)]++allIntersect :: TestTree+allIntersect =+ testCase "allIntersect"+ $ assertEqual+ "Color a graph where all values intersect"+ ( [(0, "shared"), (1, "shared"), (2, "shared")] :: [(Int, String)],+ [(1 :: Int, 2), (2, 1), (3, 0)]+ )+ $ (M.toList *** M.toList)+ $ GreedyColoring.colorGraph+ (M.fromList [(1, "shared"), (2, "shared"), (3, "shared")])+ $ S.fromList [(1, 2), (2, 3), (1, 3)]++emptyGraph :: TestTree+emptyGraph =+ testCase "emptyGraph"+ $ assertEqual+ "Color an empty graph"+ ([] :: [(Int, Char)], [] :: [(Int, Int)])+ $ (M.toList *** M.toList)+ $ GreedyColoring.colorGraph M.empty+ $ S.fromList []++noIntersections :: TestTree+noIntersections =+ GreedyColoring.colorGraph+ (M.fromList [(1, "shared"), (2, "shared"), (3, "shared")])+ (S.fromList [])+ & M.toList *** M.toList+ & assertEqual+ "Color nodes with no intersections"+ ( [(0, "shared")] :: [(Int, String)],+ [(1, 0), (2, 0), (3, 0)] :: [(Int, Int)]+ )+ & testCase "noIntersections"++differentSpaces :: TestTree+differentSpaces =+ GreedyColoring.colorGraph+ (M.fromList [(1, "a"), (2, "b"), (3, "c")])+ (S.fromList [])+ & M.toList *** M.toList+ & assertEqual+ "Color nodes with no intersections but in different spaces"+ ( [(0, "c"), (1, "b"), (2, "a")] :: [(Int, String)],+ [(1, 2), (2, 1), (3, 0)] :: [(Int, Int)]+ )+ & testCase "differentSpaces"
+ src-testing/Futhark/Pkg/SolveTests.hs view
@@ -0,0 +1,142 @@+module Futhark.Pkg.SolveTests (tests) where++import Data.Map qualified as M+import Data.Monoid+import Data.Text qualified as T+import Futhark.Pkg.Solve+import Futhark.Pkg.Types+import Test.Tasty+import Test.Tasty.HUnit+import Prelude++semverE :: T.Text -> SemVer+semverE s = case parseVersion s of+ Left err ->+ error $+ T.unpack s+ <> " is not a valid version number: "+ <> errorBundlePretty err+ Right x -> x++-- | A world of packages and interdependencies for testing the solver+-- without touching the outside world.+testEnv :: PkgRevDepInfo+testEnv =+ M.fromList $+ concatMap+ frob+ [ ( "athas",+ [ ( "foo",+ [ ("0.1.0", []),+ ("0.2.0", [("athas/bar", "1.0.0")]),+ ("0.3.0", [])+ ]+ ),+ ("foo@v2", [("2.0.0", [("athas/quux", "0.1.0")])]),+ ("bar", [("1.0.0", [])]),+ ("baz", [("0.1.0", [("athas/foo", "0.3.0")])]),+ ( "quux",+ [ ( "0.1.0",+ [ ("athas/foo", "0.2.0"),+ ("athas/baz", "0.1.0")+ ]+ )+ ]+ ),+ ( "quux_perm",+ [ ( "0.1.0",+ [ ("athas/baz", "0.1.0"),+ ("athas/foo", "0.2.0")+ ]+ )+ ]+ ),+ ("x_bar", [("1.0.0", [("athas/bar", "1.0.0")])]),+ ("x_foo", [("1.0.0", [("athas/foo", "0.3.0")])]),+ ( "tricky",+ [ ( "1.0.0",+ [ ("athas/foo", "0.2.0"),+ ("athas/x_foo", "1.0.0")+ ]+ )+ ]+ )+ ]+ ),+ -- Some mutually recursive packages.+ ( "nasty",+ [ ("foo", [("1.0.0", [("nasty/bar", "1.0.0")])]),+ ("bar", [("1.0.0", [("nasty/foo", "1.0.0")])])+ ]+ )+ ]+ where+ frob (user, repos) = do+ (repo, repo_revs) <- repos+ (rev, deps) <- repo_revs+ let rev' = semverE rev+ onDep (dp, dv) = (dp, (semverE dv, Nothing))+ deps' = PkgRevDeps $ M.fromList $ map onDep deps+ pure ((user <> "/" <> repo, rev'), deps')++newtype SolverRes = SolverRes BuildList+ deriving (Eq)++instance Show SolverRes where+ show (SolverRes bl) = T.unpack $ prettyBuildList bl++solverTest :: PkgPath -> T.Text -> Either T.Text [(PkgPath, T.Text)] -> TestTree+solverTest p v expected =+ testCase (T.unpack $ p <> "-" <> prettySemVer v') $+ fmap SolverRes (solveDepsPure testEnv target)+ @?= expected'+ where+ target = PkgRevDeps $ M.singleton p (v', Nothing)+ v' = semverE v+ expected' = SolverRes . BuildList . M.fromList . map onRes <$> expected+ onRes (dp, dv) = (dp, semverE dv)++tests :: TestTree+tests =+ testGroup+ "SolveTests"+ [ solverTest "athas/foo" "0.1.0" $+ Right [("athas/foo", "0.1.0")],+ solverTest "athas/foo" "0.2.0" $+ Right+ [ ("athas/foo", "0.2.0"),+ ("athas/bar", "1.0.0")+ ],+ solverTest "athas/quux" "0.1.0" $+ Right+ [ ("athas/quux", "0.1.0"),+ ("athas/foo", "0.3.0"),+ ("athas/baz", "0.1.0")+ ],+ solverTest "athas/quux_perm" "0.1.0" $+ Right+ [ ("athas/quux_perm", "0.1.0"),+ ("athas/foo", "0.3.0"),+ ("athas/baz", "0.1.0")+ ],+ solverTest "athas/foo@v2" "2.0.0" $+ Right+ [ ("athas/foo@v2", "2.0.0"),+ ("athas/quux", "0.1.0"),+ ("athas/foo", "0.3.0"),+ ("athas/baz", "0.1.0")+ ],+ solverTest "athas/foo@v3" "3.0.0" $+ Left "Unknown package/version: athas/foo@v3-3.0.0",+ solverTest "nasty/foo" "1.0.0" $+ Right+ [ ("nasty/foo", "1.0.0"),+ ("nasty/bar", "1.0.0")+ ],+ solverTest "athas/tricky" "1.0.0" $+ Right+ [ ("athas/tricky", "1.0.0"),+ ("athas/foo", "0.3.0"),+ ("athas/x_foo", "1.0.0")+ ]+ ]
+ src-testing/Futhark/ProfileTests.hs view
@@ -0,0 +1,23 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Futhark.ProfileTests () where++import Data.Map qualified as M+import Data.Text qualified as T+import Futhark.Profile+import Test.Tasty.QuickCheck++printable :: Gen String+printable = getPrintableString <$> arbitrary++arbText :: Gen T.Text+arbText = T.pack <$> printable++instance Arbitrary ProfilingEvent where+ arbitrary = ProfilingEvent <$> arbText <*> arbitrary <*> arbText <*> arbitrary++instance Arbitrary ProfilingReport where+ arbitrary =+ ProfilingReport+ <$> arbitrary+ <*> (M.fromList <$> listOf ((,) <$> arbText <*> arbitrary))
+ src-testing/Language/Futhark/CoreTests.hs view
@@ -0,0 +1,13 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Language.Futhark.CoreTests () where++import Language.Futhark.Core+import Language.Futhark.PrimitiveTests ()+import Test.QuickCheck++instance Arbitrary Name where+ arbitrary = nameFromString <$> listOf1 (elements ['a' .. 'z'])++instance Arbitrary VName where+ arbitrary = VName <$> arbitrary <*> arbitrary
+ src-testing/Language/Futhark/ParserBenchmarks.hs view
@@ -0,0 +1,23 @@+module Language.Futhark.ParserBenchmarks (benchmarks) where++import Criterion (Benchmark, bench, bgroup, whnf)+import Data.Either (fromRight)+import Data.Text qualified as T+import Futhark.Util (showText)+import Language.Futhark.Parser (parseExp)++bigArray :: Int -> T.Text+bigArray n = "[" <> T.intercalate "," (map ((<> "i32") . showText) [0 .. n - 1]) <> "]"++benchmarks :: Benchmark+benchmarks =+ bgroup+ "Language.Futhark.Parser"+ [ benchIntArray 10000,+ benchIntArray 100000,+ benchIntArray 1000000+ ]+ where+ benchIntArray n =+ bench ("[" <> show n <> "]i32") $+ whnf (fromRight (error "parse error") . parseExp "") (bigArray n)
+ src-testing/Language/Futhark/PrettyTests.hs view
@@ -0,0 +1,35 @@+module Language.Futhark.PrettyTests (tests) where++import Data.Text qualified as T+import Language.Futhark+import Language.Futhark.SyntaxTests ()+import Test.Tasty+import Test.Tasty.HUnit+import Prelude++var :: QualName Name -> UncheckedExp+var x = Var x NoInfo mempty++binOp :: QualName Name -> UncheckedExp -> UncheckedExp -> UncheckedExp+binOp op x y = AppExp (BinOp (op, mempty) NoInfo (x, NoInfo) (y, NoInfo) mempty) NoInfo++tests :: TestTree+tests =+ testGroup+ "Language.Futhark.Pretty"+ [ testCase "No outer parens" $+ p (binOp "+" (var "x") (var "y"))+ @?= "x + y",+ testCase "No redundant parens" $+ p (binOp "+" "x+y" (var "z"))+ @?= "x + y + z",+ testCase "Necessary parens" $+ p (binOp "+" (var "x") "y+z")+ @?= "x + (y + z)",+ testCase "Explicit but redundant parens" $+ p "(x+y)+z"+ @?= "(x + y) + z"+ ]+ where+ p :: UncheckedExp -> T.Text+ p = prettyText
+ src-testing/Language/Futhark/PrimitiveTests.hs view
@@ -0,0 +1,76 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Language.Futhark.PrimitiveTests+ ( tests,+ arbitraryPrimValOfType,+ )+where++import Control.Applicative+import Futhark.Util (convFloat)+import Language.Futhark.Primitive+import Test.QuickCheck+import Test.Tasty+import Test.Tasty.HUnit+import Prelude++tests :: TestTree+tests = testGroup "PrimitiveTests" [propPrimValuesHaveRightType]++propPrimValuesHaveRightType :: TestTree+propPrimValuesHaveRightType =+ testGroup+ "propPrimValuesHaveRightTypes"+ [ testCase (show t ++ " has blank of right type") $+ primValueType (blankPrimValue t) @?= t+ | t <- [minBound .. maxBound]+ ]++instance Arbitrary IntType where+ arbitrary = elements [minBound .. maxBound]++instance Arbitrary FloatType where+ arbitrary = elements [minBound .. maxBound]++instance Arbitrary PrimType where+ arbitrary = elements [minBound .. maxBound]++instance Arbitrary IntValue where+ arbitrary =+ oneof+ [ Int8Value <$> arbitrary,+ Int16Value <$> arbitrary,+ Int32Value <$> arbitrary,+ Int64Value <$> arbitrary+ ]++instance Arbitrary Half where+ arbitrary = (convFloat :: Float -> Half) <$> arbitrary++instance Arbitrary FloatValue where+ arbitrary =+ oneof+ [ Float16Value <$> arbitrary,+ Float32Value <$> arbitrary,+ Float64Value <$> arbitrary+ ]++instance Arbitrary PrimValue where+ arbitrary =+ oneof+ [ IntValue <$> arbitrary,+ FloatValue <$> arbitrary,+ BoolValue <$> arbitrary,+ pure UnitValue+ ]++arbitraryPrimValOfType :: PrimType -> Gen PrimValue+arbitraryPrimValOfType (IntType Int8) = IntValue . Int8Value <$> arbitrary+arbitraryPrimValOfType (IntType Int16) = IntValue . Int16Value <$> arbitrary+arbitraryPrimValOfType (IntType Int32) = IntValue . Int32Value <$> arbitrary+arbitraryPrimValOfType (IntType Int64) = IntValue . Int64Value <$> arbitrary+arbitraryPrimValOfType (FloatType Float16) = FloatValue . Float16Value <$> arbitrary+arbitraryPrimValOfType (FloatType Float32) = FloatValue . Float32Value <$> arbitrary+arbitraryPrimValOfType (FloatType Float64) = FloatValue . Float32Value <$> arbitrary+arbitraryPrimValOfType Bool = BoolValue <$> arbitrary+arbitraryPrimValOfType Unit = pure UnitValue
+ src-testing/Language/Futhark/SemanticTests.hs view
@@ -0,0 +1,24 @@+module Language.Futhark.SemanticTests (tests) where++import Language.Futhark (ImportName (..))+import Language.Futhark.Semantic+import Test.Tasty+import Test.Tasty.HUnit++tests :: TestTree+tests =+ testGroup+ "Semantic objects"+ [ testCase "a" $+ mkInitialImport "a" @?= ImportName "a",+ testCase "./a" $+ mkInitialImport "./a" @?= ImportName "a",+ testCase "a/b -> ../c" $+ mkImportFrom (mkInitialImport "a/b") "../c" @?= ImportName "c",+ testCase "a/b -> ../../c" $+ mkImportFrom (mkInitialImport "a/b") "../../c" @?= ImportName "../c",+ testCase "../a -> b" $+ mkImportFrom (mkInitialImport "../a") "b" @?= ImportName "../b",+ testCase "../a -> ../b" $+ mkImportFrom (mkInitialImport "../a") "../b" @?= ImportName "../../b"+ ]
+ src-testing/Language/Futhark/SyntaxTests.hs view
@@ -0,0 +1,211 @@+{-# OPTIONS_GHC -fno-warn-orphans #-}++module Language.Futhark.SyntaxTests (tests) where++import Control.Applicative hiding (many, some)+import Data.Bifunctor+import Data.Char (isAlpha)+import Data.Functor+import Data.Map qualified as M+import Data.String+import Data.Text qualified as T+import Data.Void+import Language.Futhark+import Language.Futhark.Parser (SyntaxError (syntaxErrorMsg), parseExp, parseType)+import Language.Futhark.Primitive.Parse (constituent, keyword, lexeme)+import Language.Futhark.PrimitiveTests ()+import Test.QuickCheck+import Test.Tasty+import Text.Megaparsec+import Text.Megaparsec.Char.Lexer qualified as L+import Prelude++tests :: TestTree+tests = testGroup "Source SyntaxTests" []++instance Arbitrary BinOp where+ arbitrary = elements [minBound .. maxBound]++instance Arbitrary Uniqueness where+ arbitrary = elements [Unique, Nonunique]++instance Arbitrary PrimType where+ arbitrary =+ oneof+ [ Signed <$> arbitrary,+ Unsigned <$> arbitrary,+ FloatType <$> arbitrary,+ pure Bool+ ]++instance Arbitrary PrimValue where+ arbitrary =+ oneof+ [ SignedValue <$> arbitrary,+ UnsignedValue <$> arbitrary,+ FloatValue <$> arbitrary,+ BoolValue <$> arbitrary+ ]++-- The following dirty instances make it slightly nicer to write unit tests.++instance IsString VName where+ fromString s =+ let (s', '_' : tag) = span (/= '_') s+ in VName (fromString s') (read tag)++instance (IsString v) => IsString (QualName v) where+ fromString = QualName [] . fromString++instance IsString UncheckedTypeExp where+ fromString =+ either (error . T.unpack . syntaxErrorMsg) id+ . parseType "IsString UncheckedTypeExp"+ . fromString++type Parser = Parsec Void T.Text++braces, brackets, parens :: Parser a -> Parser a+braces = between (lexeme "{") (lexeme "}")+brackets = between (lexeme "[") (lexeme "]")+parens = between (lexeme "(") (lexeme ")")++pName :: Parser Name+pName =+ lexeme . fmap nameFromString $+ (:) <$> satisfy isAlpha <*> many (satisfy constituent)++pVName :: Parser VName+pVName = lexeme $ do+ (s, tag) <-+ satisfy constituent+ `manyTill_` try pTag+ <?> "variable name"+ pure $ VName (nameFromString s) tag+ where+ pTag =+ "_" *> L.decimal <* notFollowedBy (satisfy constituent)++pQualName :: Parser (QualName VName)+pQualName = QualName [] <$> pVName++pPrimType :: Parser PrimType+pPrimType =+ choice $+ map+ f+ [ Bool,+ Signed Int8,+ Signed Int16,+ Signed Int32,+ Signed Int64,+ Unsigned Int8,+ Unsigned Int16,+ Unsigned Int32,+ Unsigned Int64,+ FloatType Float32,+ FloatType Float64+ ]+ where+ f t = keyword (prettyText t) $> t++pUniqueness :: Parser Uniqueness+pUniqueness = choice [lexeme "*" $> Unique, pure Nonunique]++pSize :: Parser Size+pSize =+ brackets $+ choice+ [ flip sizeFromInteger mempty <$> lexeme L.decimal,+ flip sizeFromName mempty <$> pQualName+ ]++pScalarNonFun :: Parser (ScalarTypeBase Size Uniqueness)+pScalarNonFun =+ choice+ [ Prim <$> pPrimType,+ pTypeVar,+ tupleRecord <$> parens (pType `sepBy` lexeme ","),+ Record . M.fromList <$> braces (pField `sepBy1` lexeme ",")+ ]+ where+ pField = (,) <$> pName <* lexeme ":" <*> pType+ pTypeVar = TypeVar <$> pUniqueness <*> pQualName <*> many pTypeArg+ pTypeArg =+ choice+ [ TypeArgDim <$> pSize,+ TypeArgType . second (const NoUniqueness) <$> pTypeArgType+ ]+ pTypeArgType =+ choice+ [ Scalar . Prim <$> pPrimType,+ parens pType+ ]++pArrayType :: Parser ResType+pArrayType =+ Array+ <$> pUniqueness+ <*> (Shape <$> some pSize)+ <*> (second (const NoUniqueness) <$> pScalarNonFun)++pNonFunType :: Parser ResType+pNonFunType =+ choice+ [ try pArrayType,+ try $ parens pType,+ Scalar <$> pScalarNonFun+ ]++pScalarType :: Parser (ScalarTypeBase Size Uniqueness)+pScalarType = choice [try pFun, pScalarNonFun]+ where+ pFun =+ pParam <* lexeme "->" <*> pRetType+ pParam =+ choice+ [ try pNamedParam,+ do+ t <- pNonFunType+ pure $ Arrow Nonunique Unnamed (diet $ resToParam t) (toStruct t)+ ]+ pNamedParam = parens $ do+ v <- pVName <* lexeme ":"+ t <- pType+ pure $ Arrow Nonunique (Named v) (diet $ resToParam t) (toStruct t)++pRetType :: Parser ResRetType+pRetType =+ choice+ [ lexeme "?" *> (RetType <$> some (brackets pVName) <* lexeme "." <*> pType),+ RetType [] <$> pType+ ]++pType :: Parser ResType+pType =+ choice [try $ Scalar <$> pScalarType, pArrayType, parens pType]++fromStringParse :: Parser a -> String -> String -> a+fromStringParse p what s =+ either onError id $ parse (p <* eof) "" (T.pack s)+ where+ onError e =+ error $ "not a " <> what <> ": " <> s <> "\n" <> errorBundlePretty e++instance IsString (ScalarTypeBase Size NoUniqueness) where+ fromString =+ fromStringParse (second (const NoUniqueness) <$> pScalarType) "ScalarType"++instance IsString StructType where+ fromString =+ fromStringParse (second (const NoUniqueness) <$> pType) "StructType"++instance IsString StructRetType where+ fromString =+ fromStringParse (second (pure NoUniqueness) <$> pRetType) "StructRetType"++instance IsString ResRetType where+ fromString = fromStringParse pRetType "ResRetType"++instance IsString UncheckedExp where+ fromString = either (error . T.unpack . syntaxErrorMsg) id . parseExp "string literal" . T.pack
+ src-testing/Language/Futhark/TypeChecker/TypesTests.hs view
@@ -0,0 +1,185 @@+module Language.Futhark.TypeChecker.TypesTests (tests) where++import Data.Bifunctor+import Data.List (isInfixOf)+import Data.Map qualified as M+import Data.Text qualified as T+import Futhark.FreshNames+import Futhark.Util.Pretty (docText, prettyTextOneLine)+import Language.Futhark+import Language.Futhark.Semantic+import Language.Futhark.SyntaxTests ()+import Language.Futhark.TypeChecker (initialEnv)+import Language.Futhark.TypeChecker.Monad+import Language.Futhark.TypeChecker.Names (resolveTypeExp)+import Language.Futhark.TypeChecker.Terms+import Language.Futhark.TypeChecker.Types+import Test.Tasty+import Test.Tasty.HUnit++evalTest :: TypeExp (ExpBase NoInfo Name) Name -> Either String ([VName], ResRetType) -> TestTree+evalTest te expected =+ testCase (prettyString te) $+ case (fmap (extract . fst) (run (checkTypeExp checkSizeExp =<< resolveTypeExp te)), expected) of+ (Left got_e, Left expected_e) ->+ let got_e_s = T.unpack $ docText $ prettyTypeError got_e+ in (expected_e `isInfixOf` got_e_s) @? got_e_s+ (Left got_e, Right _) ->+ let got_e_s = T.unpack $ docText $ prettyTypeError got_e+ in assertFailure $ "Failed: " <> got_e_s+ (Right actual_t, Right expected_t) ->+ actual_t @?= expected_t+ (Right actual_t, Left _) ->+ assertFailure $ "Expected error, got: " <> show actual_t+ where+ extract (_, svars, t, _) = (svars, t)+ run = snd . runTypeM env mempty (mkInitialImport "") (newNameSource 100)+ -- We hack up an environment with some predefined type+ -- abbreviations for testing. This is all pretty sensitive to the+ -- specific unique names, so we have to be careful!+ env =+ initialEnv+ { envTypeTable =+ M.fromList+ [ ( "square_1000",+ TypeAbbr+ Unlifted+ [TypeParamDim "n_1001" mempty]+ "[n_1001][n_1001]i32"+ ),+ ( "fun_1100",+ TypeAbbr+ Lifted+ [ TypeParamType Lifted "a_1101" mempty,+ TypeParamType Lifted "b_1102" mempty+ ]+ "a_1101 -> b_1102"+ ),+ ( "pair_1200",+ TypeAbbr+ SizeLifted+ []+ "?[n_1201][m_1202].([n_1201]i64, [m_1202]i64)"+ )+ ]+ <> envTypeTable initialEnv,+ envNameMap =+ M.fromList+ [ ((Type, "square"), "square_1000"),+ ((Type, "fun"), "fun_1100"),+ ((Type, "pair"), "pair_1200")+ ]+ <> envNameMap initialEnv+ }++evalTests :: TestTree+evalTests =+ testGroup+ "Type expression elaboration"+ [ testGroup "Positive tests" (map mkPos pos),+ testGroup "Negative tests" (map mkNeg neg)+ ]+ where+ mkPos (x, y) = evalTest x (Right y)+ mkNeg (x, y) = evalTest x (Left y)+ pos =+ [ ( "[]i32",+ ([], "?[d_100].[d_100]i32")+ ),+ ( "[][]i32",+ ([], "?[d_100][d_101].[d_100][d_101]i32")+ ),+ ( "bool -> []i32",+ ([], "bool -> ?[d_100].[d_100]i32")+ ),+ ( "bool -> []f32 -> []i32",+ (["d_100"], "bool -> [d_100]f32 -> ?[d_101].[d_101]i32")+ ),+ ( "([]i32,[]i32)",+ ([], "?[d_100][d_101].([d_100]i32, [d_101]i32)")+ ),+ ( "{a:[]i32,b:[]i32}",+ ([], "?[d_100][d_101].{a:[d_100]i32, b:[d_101]i32}")+ ),+ ( "?[n].[n][n]bool",+ ([], "?[n_100].[n_100][n_100]bool")+ ),+ ( "([]i32 -> []i32) -> bool -> []i32",+ (["d_100"], "([d_100]i32 -> ?[d_101].[d_101]i32) -> bool -> ?[d_102].[d_102]i32")+ ),+ ( "((k: i64) -> [k]i32 -> [k]i32) -> []i32 -> bool",+ (["d_101"], "((k_100: i64) -> [k_100]i32 -> [k_100]i32) -> [d_101]i32 -> bool")+ ),+ ( "square [10]",+ ([], "[10][10]i32")+ ),+ ( "square []",+ ([], "?[d_100].[d_100][d_100]i32")+ ),+ ( "bool -> square []",+ ([], "bool -> ?[d_100].[d_100][d_100]i32")+ ),+ ( "(k: i64) -> square [k]",+ ([], "(k_100: i64) -> [k_100][k_100]i32")+ ),+ ( "fun i32 bool",+ ([], "i32 -> bool")+ ),+ ( "fun ([]i32) bool",+ ([], "?[d_100].[d_100]i32 -> bool")+ ),+ ( "fun bool ([]i32)",+ ([], "?[d_100].bool -> [d_100]i32")+ ),+ ( "bool -> fun ([]i32) bool",+ ([], "bool -> ?[d_100].[d_100]i32 -> bool")+ ),+ ( "bool -> fun bool ([]i32)",+ ([], "bool -> ?[d_100].bool -> [d_100]i32")+ ),+ ( "pair",+ ([], "?[n_100][m_101].([n_100]i64, [m_101]i64)")+ ),+ ( "(pair,pair)",+ ([], "?[n_100][m_101][n_102][m_103].(([n_100]i64, [m_101]i64), ([n_102]i64, [m_103]i64))")+ )+ ]+ neg =+ [ ("?[n].bool", "Existential size \"n\""),+ ("?[n].bool -> [n]bool", "Existential size \"n\""),+ ("?[n].[n]bool -> [n]bool", "Existential size \"n\""),+ ("?[n].[n]bool -> bool", "Existential size \"n\"")+ ]++substTest :: M.Map VName (Subst StructRetType) -> StructRetType -> StructRetType -> TestTree+substTest m t expected =+ testCase (pretty_m <> ": " <> T.unpack (prettyTextOneLine t)) $+ applySubst (`M.lookup` m) t @?= expected+ where+ pretty_m = T.unpack $ prettyText $ map (first toName) $ M.toList m++-- Some of these tests may be a bit fragile, in that they depend on+-- internal renumbering, which can be arbitrary.+substTests :: TestTree+substTests =+ testGroup+ "Type substitution"+ [ substTest m0 "t_0" "i64",+ substTest m0 "[1]t_0" "[1]i64",+ substTest m0 "?[n_10].[n_10]t_0" "?[n_10].[n_10]i64",+ --+ substTest m1 "t_0" "?[n_1].[n_1]bool",+ substTest m1 "f32 -> t_0" "f32 -> ?[n_1].[n_1]bool",+ substTest m1 "f32 -> f64 -> t_0" "f32 -> f64 -> ?[n_1].[n_1]bool",+ substTest m1 "f32 -> t_0 -> bool" "?[n_1].f32 -> [n_1]bool -> bool",+ substTest m1 "f32 -> t_0 -> t_0" "?[n_1].f32 -> [n_1]bool -> ?[n_2].[n_2]bool"+ ]+ where+ m0 =+ M.fromList [("t_0", Subst [] "i64")]++ m1 =+ M.fromList [("t_0", Subst [] "?[n_1].[n_1]bool")]++tests :: TestTree+tests = testGroup "Basic type operations" [evalTests, substTests]
+ src-testing/Language/Futhark/TypeCheckerTests.hs view
@@ -0,0 +1,11 @@+module Language.Futhark.TypeCheckerTests (tests) where++import Language.Futhark.TypeChecker.TypesTests qualified+import Test.Tasty++tests :: TestTree+tests =+ testGroup+ "Source type checker tests"+ [ Language.Futhark.TypeChecker.TypesTests.tests+ ]
+ src-testing/futhark_benchmarks.hs view
@@ -0,0 +1,10 @@+module Main (main) where++import Criterion.Main+import Language.Futhark.ParserBenchmarks qualified++main :: IO ()+main =+ defaultMain+ [ Language.Futhark.ParserBenchmarks.benchmarks+ ]
+ src-testing/futhark_tests.hs view
@@ -0,0 +1,44 @@+module Main (main) where++import Futhark.AD.DerivativesTests qualified+import Futhark.Analysis.AlgSimplifyTests qualified+import Futhark.BenchTests qualified+import Futhark.IR.Mem.IntervalTests qualified+import Futhark.IR.Mem.IxFunTests qualified+import Futhark.IR.PropTests qualified+import Futhark.IR.Syntax.CoreTests qualified+import Futhark.Internalise.TypesValuesTests qualified+import Futhark.Optimise.ArrayLayoutTests qualified+import Futhark.Optimise.MemoryBlockMerging.GreedyColoringTests qualified+import Futhark.Pkg.SolveTests qualified+import Language.Futhark.PrettyTests qualified+import Language.Futhark.PrimitiveTests qualified+import Language.Futhark.SemanticTests qualified+import Language.Futhark.SyntaxTests qualified+import Language.Futhark.TypeCheckerTests qualified+import Test.Tasty++allTests :: TestTree+allTests =+ testGroup+ ""+ [ Language.Futhark.SyntaxTests.tests,+ Language.Futhark.PrettyTests.tests,+ Futhark.AD.DerivativesTests.tests,+ Futhark.BenchTests.tests,+ Futhark.IR.PropTests.tests,+ Futhark.IR.Syntax.CoreTests.tests,+ Futhark.Pkg.SolveTests.tests,+ Futhark.Internalise.TypesValuesTests.tests,+ Futhark.IR.Mem.IntervalTests.tests,+ Futhark.IR.Mem.IxFunTests.tests,+ Language.Futhark.PrimitiveTests.tests,+ Futhark.Optimise.MemoryBlockMerging.GreedyColoringTests.tests,+ Futhark.Analysis.AlgSimplifyTests.tests,+ Language.Futhark.TypeCheckerTests.tests,+ Language.Futhark.SemanticTests.tests,+ Futhark.Optimise.ArrayLayoutTests.tests+ ]++main :: IO ()+main = defaultMain allTests
src/Futhark/AD/Derivatives.hs view
@@ -357,18 +357,6 @@ Just [b, a, fConst Float32 1] pdBuiltin "mad64" [a, b, _c] = Just [b, a, fConst Float64 1]-pdBuiltin "from_bits16" [_] =- Just [fConst Float16 1]-pdBuiltin "from_bits32" [_] =- Just [fConst Float32 1]-pdBuiltin "from_bits64" [_] =- Just [fConst Float64 1]-pdBuiltin "to_bits16" [_] =- Just [iConst Int16 1]-pdBuiltin "to_bits32" [_] =- Just [iConst Int32 1]-pdBuiltin "to_bits64" [_] =- Just [iConst Int64 1] pdBuiltin "hypot16" [x, y] = Just [ untyped $ isF16 x / isF16 (FunExp "hypot16" [x, y] $ FloatType Float16),
src/Futhark/AD/Rev.hs view
@@ -264,7 +264,14 @@ forM_ (zip branches_free branches_free_adj) $ \(v, v_adj) -> insAdj v =<< copyIfArray v_adj diffStm (Let pat aux (Op soac)) m =- vjpSOAC vjpOps pat aux soac m+ -- We add the attributes from 'aux' to every SOAC (but only SOAC) produced. We+ -- could do this on *every* stm, but it would be very verbose.+ censorStms (fmap addAttrs) $ vjpSOAC vjpOps pat aux soac m+ where+ addAttrs stm+ | Op _ <- stmExp stm =+ attribute (stmAuxAttrs aux) stm+ | otherwise = stm diffStm (Let pat aux loop@Loop {}) m = diffLoop diffStms pat aux loop m -- See Note [Adjoints of accumulators]
src/Futhark/Analysis/AccessPattern.hs view
@@ -228,7 +228,7 @@ -- | Analyse the op for this representation. analyseOp :: Op rep -> Context rep -> [VName] -> (Context rep, IndexTable rep) --- | Analyse each `entry` and accumulate the results.+-- | Analyse each entry and accumulate the results. analyseDimAccesses :: (Analyse rep) => Prog rep -> IndexTable rep analyseDimAccesses = foldMap' analyseFunction . progFuns @@ -308,7 +308,6 @@ then result <> oneName a else -- Otherwise, recurse on its dependencies; -- 0. Add dependencies in ctx to result- let (deps_in_ctx, deps_not_in_ctx) = L.partition (`M.member` local_assignments) $ namesToList (deps var_info)@@ -471,7 +470,7 @@ BinOp _ lsubexp rsubexp -> concatVariableInfos mempty [lsubexp, rsubexp] CmpOp _ lsubexp rsubexp -> concatVariableInfos mempty [lsubexp, rsubexp] ConvOp _ se -> varInfoFromSubExp se- Assert se _ _ -> varInfoFromSubExp se+ Assert se _ -> varInfoFromSubExp se Index name _ -> error $ "unhandled: Index (This should NEVER happen) into " ++ prettyString name Update _ name _slice _subexp ->
src/Futhark/Analysis/Alias.hs view
@@ -82,11 +82,11 @@ AliasTable -> Stm rep -> Stm (Aliases rep)-analyseStm aliases (Let pat (StmAux cs attrs dec) e) =+analyseStm aliases (Let pat aux e) = let e' = analyseExp aliases e pat' = mkAliasedPat pat e'- rep' = (AliasDec $ consumedInExp e', dec)- in Let pat' (StmAux cs attrs rep') e'+ aux' = (AliasDec (consumedInExp e'),) <$> aux+ in Let pat' aux' e' -- | Perform alias analysis on expression. analyseExp ::
src/Futhark/Analysis/LastUse.hs view
@@ -428,7 +428,7 @@ else aliasTransitiveClosure res -- | For each 'PatElem' in the 'Pat', add its aliases to the 'AliasTab' in--- 'LastUseM'. Additionally, 'Names' are added as aliases of all the 'PatElemT'.+-- 'LastUseM'. Additionally, 'Names' are added as aliases of all the 'PatElem'. updateAliasing :: (AliasesOf dec) => -- | Extra names that all 'PatElem' should alias.
src/Futhark/Analysis/PrimExp/Convert.hs view
@@ -48,7 +48,7 @@ Apply (nameFromText h) <$> args' <*> pure [(primRetType t, mempty)]- <*> pure (Safe, mempty, [])+ <*> pure Safe where args' = zip <$> mapM (toSubExp "apply_arg") args <*> pure (repeat Observe) toExp (LeafExp v _) =
src/Futhark/Builder/Class.hs view
@@ -11,6 +11,7 @@ MonadBuilder (..), insertStms, insertStm,+ censorStms, letBind, letBindNames, collectStms_,@@ -103,23 +104,29 @@ -- | Add the given attributes to any statements added by this action. attributing :: (MonadBuilder m) => Attrs -> m a -> m a-attributing attrs = censorStms $ fmap onStm- where- onStm (Let pat aux e) =- Let pat aux {stmAuxAttrs = attrs <> stmAuxAttrs aux} e+attributing attrs = censorStms $ fmap $ attribute attrs -- | Add the certificates and attributes to any statements added by -- this action. auxing :: (MonadBuilder m) => StmAux anyrep -> m a -> m a-auxing (StmAux cs attrs _) = censorStms $ fmap onStm+auxing outer+ | stmAuxCerts outer == mempty,+ stmAuxAttrs outer == mempty,+ stmAuxLoc outer == mempty =+ id+ | otherwise = censorStms $ fmap onStm where onStm (Let pat aux e) = Let pat aux' e where aux' = aux- { stmAuxAttrs = attrs <> stmAuxAttrs aux,- stmAuxCerts = cs <> stmAuxCerts aux+ { stmAuxAttrs = stmAuxAttrs outer <> stmAuxAttrs aux,+ stmAuxCerts = stmAuxCerts outer <> stmAuxCerts aux,+ stmAuxLoc =+ if stmAuxLoc aux == mempty+ then stmAuxLoc outer+ else stmAuxLoc aux } -- | Add a statement with the given pattern and expression.@@ -142,10 +149,10 @@ -- | Like mkLet, but also take attributes and certificates from the -- given 'StmAux'. mkLet' :: (Buildable rep) => [Ident] -> StmAux a -> Exp rep -> Stm rep-mkLet' ids (StmAux cs attrs _) e =+mkLet' ids (StmAux cs attrs loc _) e = let pat = mkExpPat ids e dec = mkExpDec pat e- in Let pat (StmAux cs attrs dec) e+ in Let pat (StmAux cs attrs loc dec) e -- | Add a statement with the given pattern element names and -- expression.
src/Futhark/CLI/Doc.hs view
@@ -16,8 +16,10 @@ import Futhark.Pipeline (FutharkM, Verbosity (..), runFutharkM) import Futhark.Util (directoryContents) import Futhark.Util.Options+import Futhark.Util.Pretty (hPutDoc) import Language.Futhark.Semantic (mkInitialImport) import Language.Futhark.Syntax (DocComment (..), progDoc)+import Language.Futhark.Warnings (prettyWarnings) import System.Directory (createDirectoryIfMissing) import System.Exit import System.FilePath@@ -43,9 +45,10 @@ printDecs cfg dir files imports = do let direct_imports = map (mkInitialImport . normalise . dropExtension) files- (file_htmls, _warnings) =+ (file_htmls, warnings) = do renderFiles direct_imports $ filter (not . ignored) imports+ hPutDoc stderr $ prettyWarnings warnings mapM_ (write . fmap (LT.toStrict . renderHtml)) file_htmls write ("style.css", cssFile) where
src/Futhark/CLI/Misc.hs view
@@ -22,8 +22,8 @@ import Futhark.Util (hashText, interactWithFileSafely) import Futhark.Util.Options import Futhark.Util.Pretty (prettyTextOneLine)+import Language.Futhark.Core (isBuiltin) import Language.Futhark.Parser.Lexer (scanTokensText)-import Language.Futhark.Prop (isBuiltin) import Language.Futhark.Semantic (includeToString) import System.Environment (getExecutablePath) import System.Exit
src/Futhark/CLI/Profile.hs view
@@ -48,7 +48,7 @@ tabulateEvents :: [ProfilingEvent] -> T.Text tabulateEvents = mkRows . M.toList . M.fromListWith comb . map pair where- pair (ProfilingEvent name dur _) = (name, EvSummary 1 dur dur dur)+ pair (ProfilingEvent name dur _ _details) = (name, EvSummary 1 dur dur dur) comb (EvSummary xn xdur xmin xmax) (EvSummary yn ydur ymin ymax) = EvSummary (xn + yn) (xdur + ydur) (min xmin ymin) (max xmax ymax) numpad = 15@@ -92,8 +92,11 @@ timeline :: [ProfilingEvent] -> T.Text timeline = T.unlines . L.intercalate [""] . map onEvent where- onEvent (ProfilingEvent name duration description) =- [name, "Duration: " <> showText duration <> " μs"] <> T.lines description+ onEvent (ProfilingEvent name duration provenance _details) =+ [ name,+ "Duration: " <> showText duration <> " μs",+ "At: " <> provenance+ ] data TargetFiles = TargetFiles { summaryFile :: FilePath,
src/Futhark/CodeGen/Backends/GPU.hs view
@@ -36,6 +36,7 @@ GC.CompilerM op s Name genKernelFunction kernel_name safety arg_params arg_set = do let kernel_fname = "gpu_kernel_" <> kernel_name+ provenance <- GC.provenanceExp GC.libDecl [C.cedecl|static int $id:kernel_fname (struct futhark_context* ctx,@@ -46,7 +47,7 @@ void* args[$int:num_args] = { $inits:(failure_inits<>args_inits) }; size_t args_sizes[$int:num_args] = { $inits:(failure_sizes<>args_sizes) }; return gpu_launch_kernel(ctx, ctx->program->$id:kernel_name,- $string:(prettyString kernel_name),+ $string:(prettyString kernel_name), $exp:provenance, (const typename int32_t[]){grid_x, grid_y, grid_z}, (const typename int32_t[]){block_x, block_y, block_z}, shared_bytes,@@ -162,10 +163,11 @@ dststride_inits = [[C.cinit|$exp:e|] | Count e <- dststride] srcstride_inits = [[C.cinit|$exp:e|] | Count e <- srcstride] shape_inits = [[C.cinit|$exp:e|] | Count e <- shape]+ provenance <- GC.provenanceExp GC.stm [C.cstm| if ((err =- $id:fname(ctx, $int:r,+ $id:fname(ctx, $exp:provenance, $int:r, $exp:dst, $exp:(unCount dstoffset), (typename int64_t[]){ $inits:dststride_inits }, $exp:src, $exp:(unCount srcoffset),@@ -181,11 +183,13 @@ dststride_inits = [[C.cinit|$exp:e|] | Count e <- dststride] srcstride_inits = [[C.cinit|$exp:e|] | Count e <- srcstride] shape_inits = [[C.cinit|$exp:e|] | Count e <- shape]+ provenance <- GC.provenanceExp GC.stm [C.cstm| if ((err = lmad_copy_host2gpu- (ctx, $int:(primByteSize t::Int), $exp:sync', $int:r,+ (ctx, $exp:provenance,+ $int:(primByteSize t::Int), $exp:sync', $int:r, $exp:dst, $exp:(unCount dstoffset), (typename int64_t[]){ $inits:dststride_inits }, $exp:src, $exp:(unCount srcoffset),@@ -262,8 +266,11 @@ readScalarGPU mem i t "device" _ = do val <- newVName "read_res" GC.decl [C.cdecl|$ty:t $id:val;|]+ p <- GC.provenanceExp GC.stm- [C.cstm|if ((err = gpu_scalar_from_device(ctx, &$id:val, $exp:mem, $exp:i * sizeof($ty:t), sizeof($ty:t))) != 0) { goto cleanup; }|]+ [C.cstm|if ((err = gpu_scalar_from_device(ctx, $exp:p, &$id:val, $exp:mem,+ $exp:i * sizeof($ty:t), sizeof($ty:t))) != 0)+ { goto cleanup; }|] GC.stm [C.cstm|if (ctx->failure_is_an_option && futhark_context_sync(ctx) != 0) { err = 1; goto cleanup; }|]@@ -277,8 +284,11 @@ writeScalarGPU mem i t "device" _ val = do val' <- newVName "write_tmp" GC.item [C.citem|$ty:t $id:val' = $exp:val;|]+ p <- GC.provenanceExp GC.stm- [C.cstm|if ((err = gpu_scalar_to_device(ctx, $exp:mem, $exp:i * sizeof($ty:t), sizeof($ty:t), &$id:val')) != 0) { goto cleanup; }|]+ [C.cstm|if ((err = gpu_scalar_to_device(ctx, $exp:p, $exp:mem,+ $exp:i * sizeof($ty:t), sizeof($ty:t), &$id:val')) != 0)+ { goto cleanup; }|] writeScalarGPU _ _ _ space _ _ = error $ "Cannot write to '" ++ space ++ "' memory space." @@ -287,15 +297,18 @@ syncArg GC.CopyNoBarrier = [C.cexp|false|] copyGPU :: GC.Copy OpenCL ()-copyGPU _ dstmem dstidx (Space "device") srcmem srcidx (Space "device") nbytes =+copyGPU _ dstmem dstidx (Space "device") srcmem srcidx (Space "device") nbytes = do+ p <- GC.provenanceExp GC.stm- [C.cstm|err = gpu_memcpy(ctx, $exp:dstmem, $exp:dstidx, $exp:srcmem, $exp:srcidx, $exp:nbytes);|]-copyGPU b dstmem dstidx DefaultSpace srcmem srcidx (Space "device") nbytes =+ [C.cstm|err = gpu_memcpy(ctx, $exp:p, $exp:dstmem, $exp:dstidx, $exp:srcmem, $exp:srcidx, $exp:nbytes);|]+copyGPU b dstmem dstidx DefaultSpace srcmem srcidx (Space "device") nbytes = do+ p <- GC.provenanceExp GC.stm- [C.cstm|err = memcpy_gpu2host(ctx, $exp:(syncArg b), $exp:dstmem, $exp:dstidx, $exp:srcmem, $exp:srcidx, $exp:nbytes);|]-copyGPU b dstmem dstidx (Space "device") srcmem srcidx DefaultSpace nbytes =+ [C.cstm|err = memcpy_gpu2host(ctx, $exp:p, $exp:(syncArg b), $exp:dstmem, $exp:dstidx, $exp:srcmem, $exp:srcidx, $exp:nbytes);|]+copyGPU b dstmem dstidx (Space "device") srcmem srcidx DefaultSpace nbytes = do+ p <- GC.provenanceExp GC.stm- [C.cstm|err = memcpy_host2gpu(ctx, $exp:(syncArg b), $exp:dstmem, $exp:dstidx, $exp:srcmem, $exp:srcidx, $exp:nbytes);|]+ [C.cstm|err = memcpy_host2gpu(ctx, $exp:p, $exp:(syncArg b), $exp:dstmem, $exp:dstidx, $exp:srcmem, $exp:srcidx, $exp:nbytes);|] copyGPU _ _ _ destspace _ _ srcspace _ = error $ "Cannot copy to " ++ show destspace ++ " from " ++ show srcspace
src/Futhark/CodeGen/Backends/GenericC/Code.hs view
@@ -221,13 +221,10 @@ compileCode (Op op) = join $ asks (opsCompiler . envOperations) <*> pure op compileCode Skip = pure ()-compileCode (Comment s code) = do- xs <- collect $ compileCode code- let comment = "// " ++ T.unpack s- stm- [C.cstm|$comment:comment- { $items:xs }- |]+compileCode (Meta (MetaComment s)) = do+ comment s+compileCode (Meta (MetaProvenance (Provenance _ l))) =+ unless (l == mempty) $ comment $ locText l compileCode (TracePrint msg) = do (formatstr, formatargs) <- errorMsgString msg stm [C.cstm|fprintf(ctx->log, $string:formatstr, $args:formatargs);|]@@ -271,6 +268,9 @@ args' <- mapM compileArg args item [C.citem|$tyquals:(volQuals vol) $ty:ct $id:name = $id:(funName fname)($args:args');|] go code+ go (x@(Meta (MetaProvenance p)) : xs) = do+ compileCode x+ localProvenance p $ go xs go (x : xs) = compileCode x >> go xs go [] = pure () compileCode (Assert e msg (loc, locs)) = do
src/Futhark/CodeGen/Backends/GenericC/Monad.hs view
@@ -36,6 +36,7 @@ items, stm, stms,+ comment, decl, headerDecl, publicDef,@@ -60,6 +61,9 @@ collect', contextType, configType,+ localProvenance,+ askProvenance,+ provenanceExp, -- * Building Blocks copyMemoryDefaultSpace,@@ -258,7 +262,9 @@ -- pressure, we keep these allocations around for a long time, and -- record their sizes so we can reuse them if possible (and -- realloc() when needed).- envCachedMem :: M.Map C.Exp VName+ envCachedMem :: M.Map C.Exp VName,+ -- | The provenance of an enclosing 'Imp.MetaProvenance', if any.+ envProvenance :: Provenance } contextContents :: CompilerM op s ([C.FieldGroup], [C.Stm], [C.Stm])@@ -322,7 +328,7 @@ (a, CompilerState s) runCompilerM ops src userstate (CompilerM m) = runState- (runReaderT m (CompilerEnv ops mempty))+ (runReaderT m (CompilerEnv ops mempty mempty)) (newCompilerState src userstate) getUserState :: CompilerM op s s@@ -344,6 +350,23 @@ modify $ \s -> s {compItems = old} pure (x, DL.toList new) +-- | Locally replace (not extend!) the provenance.+localProvenance :: Provenance -> CompilerM op s a -> CompilerM op s a+localProvenance p = local $ \env -> env {envProvenance = p}++-- | The provenance of the closest enclosing 'Imp.MetaProvenance'.+askProvenance :: CompilerM op s Provenance+askProvenance = asks envProvenance++-- | A C expression corresponding to the current provenance.+provenanceExp :: CompilerM op s C.Exp+provenanceExp = do+ p <- askProvenance+ pure $+ if p == mempty+ then [C.cexp|NULL|]+ else [C.cexp|$string:(prettyString p)|]+ -- | Used when we, inside an existing 'CompilerM' action, want to -- generate code for a new function. Use this so that the compiler -- understands that previously declared memory doesn't need to be@@ -358,12 +381,20 @@ where noCached env = env {envCachedMem = mempty} +-- | Insert a block item in the generated code at this point. item :: C.BlockItem -> CompilerM op s () item x = modify $ \s -> s {compItems = DL.snoc (compItems s) x} items :: [C.BlockItem] -> CompilerM op s () items xs = modify $ \s -> s {compItems = DL.append (compItems s) (DL.fromList xs)} +-- | Insert a comment in the generated code at this point. The comment may+-- contain linebreaks, and must not contain any comment markers.+comment :: T.Text -> CompilerM op s ()+comment = mapM_ (f . ("// " <>)) . T.lines+ where+ f s = stm [C.cstm|$escstm:(T.unpack s)|]+ fatMemory :: Space -> CompilerM op s Bool fatMemory ScalarSpace {} = pure False fatMemory _ = asks $ opsFatMemory . envOperations@@ -425,6 +456,7 @@ onClear x = modify $ \s -> s {compClearItems = compClearItems s <> DL.singleton x} +-- | Insert a statement in the generated code at this point. stm :: C.Stm -> CompilerM op s () stm s = item [C.citem|$stm:s|]
src/Futhark/CodeGen/Backends/GenericPython.hs view
@@ -1062,13 +1062,13 @@ -- | Convert from scalar to storage representation for the given type. toStorage :: PrimType -> PyExp -> PyExp toStorage (FloatType Float16) e =- simpleCall "ct.c_int16" [simpleCall "futhark_to_bits16" [e]]+ simpleCall "ct.c_int16" [simpleCall "fptobits_f16_i16" [e]] toStorage t e = simpleCall (compilePrimType t) [e] -- | Convert from storage to scalar representation for the given type. fromStorage :: PrimType -> PyExp -> PyExp fromStorage (FloatType Float16) e =- simpleCall "futhark_from_bits16" [simpleCall "np.int16" [e]]+ simpleCall "bitstofp_i16_f16" [simpleCall "np.int16" [e]] fromStorage t e = simpleCall (compilePrimToNp t) [e] compilePrimValue :: Imp.PrimValue -> PyExp@@ -1306,9 +1306,10 @@ ] name' <- compileVar name stm $ Assign name' $ simpleCall "unwrapArray" [Var arr_name]-compileCode (Imp.Comment s code) = do- code' <- collect $ compileCode code- stm $ Comment (T.unpack s) code'+compileCode (Imp.Meta (Imp.MetaComment s)) =+ stm $ Comment (T.unpack s) []+compileCode (Imp.Meta {}) =+ pure () compileCode (Imp.Assert e msg (loc, locs)) = do e' <- compileExp e (formatstr, formatargs) <- errorMsgString msg
src/Futhark/CodeGen/Backends/MulticoreC.hs view
@@ -203,6 +203,7 @@ benchmarkCode :: Name -> [C.BlockItem] -> GC.CompilerM op s [C.BlockItem] benchmarkCode name code = do event <- newVName "event"+ provenance <- GC.provenanceExp pure [C.citems| struct mc_event* $id:event = mc_event_new(ctx);@@ -215,7 +216,8 @@ lock_lock(&ctx->event_list_lock); add_event(ctx, $string:(nameToString name),- strdup("nothing further"),+ $exp:provenance,+ NULL, $id:event, (typename event_report_fn)mc_event_report); lock_unlock(&ctx->event_list_lock);
src/Futhark/CodeGen/Backends/MulticoreISPC.hs view
@@ -474,13 +474,8 @@ -- All recursive constructors are duplicated here, since not doing so -- would cause use to enter regular generic C codegen with no escape. compileCode :: MCCode -> ISPCCompilerM ()-compileCode (Comment s code) = do- xs <- GC.collect $ compileCode code- let comment = "// " ++ T.unpack s- GC.stm- [C.cstm|$comment:comment- { $items:xs }- |]+compileCode (Meta (MetaComment s)) = do+ GC.comment s compileCode (DeclareScalar name _ t) = do let ct = GC.primTypeToCType t quals <- getVariabilityQuals name@@ -729,7 +724,6 @@ mayProduceError (If _ x y) = mayProduceError x || mayProduceError y mayProduceError (For _ _ x) = mayProduceError x mayProduceError (While _ x) = mayProduceError x-mayProduceError (Comment _ x) = mayProduceError x mayProduceError (Op (ForEachActive _ body)) = mayProduceError body mayProduceError (Op (ForEach _ _ _ body)) = mayProduceError body mayProduceError (Op SegOp {}) = True@@ -1015,8 +1009,6 @@ free = freeIn bound findDeps (While cond x) = do local (<> freeIn cond) $ findDeps x-findDeps (Comment _ x) =- findDeps x findDeps (Op (SegOp _ free _ _ retvals _)) = mapM_ ( \x ->@@ -1064,7 +1056,6 @@ findVarying (If _ x y) = findVarying x ++ findVarying y findVarying (For _ _ x) = findVarying x findVarying (While _ x) = findVarying x-findVarying (Comment _ x) = findVarying x findVarying (Op (ForEachActive _ body)) = findVarying body findVarying (Op (ForEach idx _ _ body)) = idx : findVarying body findVarying (DeclareMem mem _) = [mem]
src/Futhark/CodeGen/Backends/SimpleRep.hs view
@@ -88,12 +88,12 @@ -- | Convert from scalar to storage representation for the given type. toStorage :: PrimType -> C.Exp -> C.Exp-toStorage (FloatType Float16) e = [C.cexp|futrts_to_bits16($exp:e)|]+toStorage (FloatType Float16) e = [C.cexp|fptobits_f16_i16($exp:e)|] toStorage _ e = e -- | Convert from storage to scalar representation for the given type. fromStorage :: PrimType -> C.Exp -> C.Exp-fromStorage (FloatType Float16) e = [C.cexp|futrts_from_bits16($exp:e)|]+fromStorage (FloatType Float16) e = [C.cexp|bitstofp_i16_f16($exp:e)|] fromStorage _ e = e -- | @tupleField i@ is the name of field number @i@ in a tuple.
src/Futhark/CodeGen/ImpCode.hs view
@@ -64,6 +64,7 @@ MemSize, DimSize, Code (..),+ Metadata (..), PrimValue (..), Exp, TExp,@@ -77,6 +78,7 @@ calledFuncs, callGraph, ParamMap,+ foldProvenances, -- * Typed enumerations Bytes,@@ -116,6 +118,7 @@ ErrorMsgPart (..), OpaqueType (..), OpaqueTypes (..),+ Provenance (..), Rank (..), Signedness (..), Space (..),@@ -241,6 +244,15 @@ ArrayZeros Int deriving (Show) +-- | A piece of additional information attached to a piece of code, which should+-- not have any effect on how it is executed.+data Metadata+ = -- | An informative comment that can be inserted into generated code.+ MetaComment T.Text+ | -- | Where this bit of code came from.+ MetaProvenance Provenance+ deriving (Eq, Ord, Show)+ -- | A block of imperative code. Parameterised by an 'Op', which -- allows extensibility. Concrete uses of this type will instantiate -- the type parameter with e.g. a construct for launching GPU kernels.@@ -257,6 +269,11 @@ | -- | While loop. The conditional is (of course) -- re-evaluated before every iteration of the loop. While (TExp Bool) (Code a)+ | -- | Conditional execution.+ If (TExp Bool) (Code a) (Code a)+ | -- | No semantics; just some information about what code is being generated+ -- here.+ Meta Metadata | -- | Declare a memory block variable that will point to -- memory in the given memory space. Note that this is -- distinct from allocation. The memory block must be the@@ -308,16 +325,10 @@ | -- | Function call. The results are written to the -- provided 'VName' variables. Call [VName] Name [Arg]- | -- | Conditional execution.- If (TExp Bool) (Code a) (Code a) | -- | Assert that something must be true. Should it turn -- out not to be true, then report a failure along with -- the given error message.- Assert Exp (ErrorMsg Exp) (SrcLoc, [SrcLoc])- | -- | Has the same semantics as the contained code, but- -- the comment should show up in generated code for ease- -- of inspection.- Comment T.Text (Code a)+ Assert Exp (ErrorMsg Exp) (Loc, [Loc]) | -- | Print the given value to the screen, somehow -- annotated with the given string as a description. If -- no type/value pair, just print the string. This has@@ -369,7 +380,6 @@ go f (If _ x y) = f x <> f y go f (For _ _ x) = f x go f (While _ x) = f x- go f (Comment _ x) = f x go _ _ = mempty declared (DeclareMem mem space) =@@ -409,7 +419,6 @@ calledFuncs f (If _ x y) = calledFuncs f x <> calledFuncs f y calledFuncs f (For _ _ x) = calledFuncs f x calledFuncs f (While _ x) = calledFuncs f x-calledFuncs f (Comment _ x) = calledFuncs f x calledFuncs _ _ = mempty -- | Compute call graph, as per 'calledFuncs', but also include@@ -423,6 +432,16 @@ next = M.map (foldMap grow) cur in if next == cur then cur else loop next +-- | Combine the provenances of all the 'Imp.MetaProvenance' in the provided code.+foldProvenances :: (op -> Provenance) -> Code op -> Provenance+foldProvenances _ (Meta (MetaProvenance p)) = p+foldProvenances f (x :>>: y) = foldProvenances f x <> foldProvenances f y+foldProvenances f (For _ _ c) = foldProvenances f c+foldProvenances f (While _ c) = foldProvenances f c+foldProvenances f (If _ x y) = foldProvenances f x <> foldProvenances f y+foldProvenances f (Op x) = f x+foldProvenances _ _ = mempty+ -- | A mapping from names of tuning parameters to their class, as well -- as which functions make use of them (including transitively). type ParamMap = M.Map Name (SizeClass, S.Set Name)@@ -643,8 +662,10 @@ <+> "<-" <+> pretty fname <> parens (commasep $ map pretty args)- pretty (Comment s code) =- "--" <+> pretty s </> pretty code+ pretty (Meta (MetaComment s)) =+ "--" <+> pretty s+ pretty (Meta (MetaProvenance l)) =+ "@" <+> align (pretty l) pretty (DebugPrint desc (Just e)) = "debug" <+> parens (commasep [pretty (show desc), pretty e]) pretty (DebugPrint desc Nothing) =@@ -721,8 +742,8 @@ pure $ Assert e msg loc traverse _ (Call dests fname args) = pure $ Call dests fname args- traverse f (Comment s code) =- Comment s <$> traverse f code+ traverse _ (Meta s) =+ pure $ Meta s traverse _ (DebugPrint s v) = pure $ DebugPrint s v traverse _ (TracePrint msg) =@@ -738,7 +759,6 @@ declaredIn (x :>>: y) = declaredIn x <> declaredIn y declaredIn (For i _ body) = oneName i <> declaredIn body declaredIn (While _ body) = declaredIn body-declaredIn (Comment _ body) = declaredIn body declaredIn _ = mempty instance FreeIn EntryPoint where@@ -799,8 +819,8 @@ freeIn' e <> foldMap freeIn' msg freeIn' (Op op) = freeIn' op- freeIn' (Comment _ code) =- freeIn' code+ freeIn' (Meta {}) =+ mempty freeIn' (DebugPrint _ v) = maybe mempty freeIn' v freeIn' (TracePrint msg) =
src/Futhark/CodeGen/ImpCode/Multicore.hs view
@@ -194,7 +194,6 @@ go f (If _ x y) = f x <> f y go f (For _ _ x) = f x go f (While _ x) = f x- go f (Comment _ x) = f x go f (Op op) = goOp f op go _ _ = mempty
src/Futhark/CodeGen/ImpGen.hs view
@@ -48,6 +48,7 @@ lookupMemory, lookupAcc, askAttrs,+ askProvenance, -- * Building Blocks TV,@@ -145,6 +146,7 @@ import Futhark.IR.Mem import Futhark.IR.Mem.LMAD qualified as LMAD import Futhark.IR.SOACS (SOACS)+import Futhark.Transform.Rename (renameLambda) import Futhark.Util import Futhark.Util.IntegralExp import Futhark.Util.Pretty hiding (nest, space)@@ -257,7 +259,10 @@ envFunction :: Maybe Name, -- | The set of attributes that are active on the enclosing -- statements (including the one we are currently compiling).- envAttrs :: Attrs+ envAttrs :: Attrs,+ -- | The provenance of whatever we are currently generating code for. This+ -- can be used to insert information in the generated code.+ envProvenance :: Provenance } newEnv :: r -> Operations rep r op -> Imp.Space -> Env rep r op@@ -272,7 +277,8 @@ envVolatility = Imp.Nonvolatile, envEnv = r, envFunction = Nothing,- envAttrs = mempty+ envAttrs = mempty,+ envProvenance = mempty } -- | The symbol table used during compilation.@@ -731,6 +737,12 @@ cb <- asks envStmsCompiler cb alive_after_stms all_stms m +attachProvenance :: Provenance -> Imp.Code op -> Imp.Code op+attachProvenance _ Imp.Skip = Imp.Skip+attachProvenance p c+ | p == mempty = c+ | otherwise = Imp.Meta (Imp.MetaProvenance p) <> c+ defCompileStms :: (Mem rep inner, FreeIn op) => Names ->@@ -745,12 +757,13 @@ void $ compileStms' mempty $ stmsToList all_stms where compileStms' allocs (Let pat aux e : bs) = do- dVars (Just e) (patElems pat)-- e_code <-- localAttrs (stmAuxAttrs aux) $- collect $- compileExp pat e+ e_code <- fmap (attachProvenance (stmAuxLoc aux))+ . localAttrs (stmAuxAttrs aux)+ . collect+ . localProvenance (stmAuxLoc aux)+ $ do+ dVars (Just e) (patElems pat)+ compileExp pat e (live_after, bs_code) <- collect' $ compileStms' (patternAllocs pat <> allocs) bs let dies_here v = (v `notNameIn` live_after) && (v `nameIn` freeIn e_code)@@ -895,14 +908,15 @@ x' <- toExp x y' <- toExp y patElemName pe <~~ Imp.CmpOpExp bop x' y'-defCompileBasicOp _ (Assert e msg loc) = do+defCompileBasicOp _ (Assert e msg) = do e' <- toExp e msg' <- traverse toExp msg- emit $ Imp.Assert e' msg' loc+ Imp.Provenance locs loc <- askProvenance+ emit $ Imp.Assert e' msg' (loc, reverse locs) attrs <- askAttrs when (AttrComp "warn" ["safety_checks"] `inAttrs` attrs) $- uncurry warn loc "Safety check required at run-time."+ warn loc (reverse locs) "Safety check required at run-time." defCompileBasicOp (Pat [pe]) (Index src slice) | Just idxs <- sliceIndices slice = copyDWIM (patElemName pe) [] (Var src) $ map (DimFix . pe64) idxs@@ -981,11 +995,6 @@ defCompileBasicOp _ Reshape {} = pure () defCompileBasicOp _ (UpdateAcc safety acc is vs) = sComment "UpdateAcc" $ do- -- We are abusing the comment mechanism to wrap the operator in- -- braces when we end up generating code. This is necessary because- -- we might otherwise end up declaring lambda parameters (if any)- -- multiple times, as they are duplicated every time we do an- -- UpdateAcc for the same accumulator. let is' = map pe64 is -- We need to figure out whether we are updating a scatter-like@@ -1326,6 +1335,25 @@ localAttrs :: Attrs -> ImpM rep r op a -> ImpM rep r op a localAttrs attrs = local $ \env -> env {envAttrs = attrs <> envAttrs env} +-- | The provenance of whatever we are currently generating code for.+askProvenance :: ImpM rep r op Provenance+askProvenance = asks envProvenance++-- | Wrap any code emitted in the enclosed section with the current provenance,+-- if any.+withProvenance :: ImpM rep r op () -> ImpM rep r op ()+withProvenance m = do+ p <- askProvenance+ if p == mempty+ then m+ else do+ c <- collect m+ emit $ Imp.Meta (Imp.MetaProvenance p) <> c++-- | Replace (*not* extend) the provenance while executing some action.+localProvenance :: Provenance -> ImpM rep r op a -> ImpM rep r op a+localProvenance p = local $ \env -> env {envProvenance = p}+ localOps :: Operations rep r op -> ImpM rep r op a -> ImpM rep r op a localOps ops = local $ \env -> env@@ -1383,6 +1411,7 @@ -- | In the case of a histogram-like accumulator, also sets the index -- parameters. lookupAcc ::+ (Mem rep inner) => VName -> [Imp.TExp Int64] -> ImpM rep r op (VName, Space, [VName], [Imp.TExp Int64], Maybe (Lambda rep))@@ -1394,8 +1423,11 @@ case acc' of Just ([], _) -> error $ "Accumulator with no arrays: " ++ prettyString name- Just (arrs@(arr : _), Just (op, _)) -> do+ Just (arrs@(arr : _), Just (op_orig, _)) -> do space <- lookupArraySpace arr+ -- We must rename the lambda in order to avoid duplicate names in the+ -- likely case where the accumulator is used multiple times.+ op <- renameLambda op_orig let (i_params, ps) = splitAt (length is) $ lambdaParams op zipWithM_ dPrimV_ (map paramName i_params) is pure@@ -1478,7 +1510,7 @@ srclmad = memLocLMAD srcloc srcspace <- entryMemSpace <$> lookupMemory srcmem dstspace <- entryMemSpace <$> lookupMemory dstmem- emit $+ withProvenance . emit $ Imp.Copy t (elements <$> LMAD.shape dstlmad)@@ -1733,11 +1765,11 @@ emit $ Imp.While cond body' -- | Execute a code generation action, wrapping the generated code--- within a 'Imp.Comment' with the given description.+-- within a 'Imp.MetaComment' with the given description. sComment :: T.Text -> ImpM rep r op () -> ImpM rep r op () sComment s code = do code' <- collect code- emit $ Imp.Comment s code'+ emit $ Imp.Meta (Imp.MetaComment s) <> code' sIf :: Imp.TExp Bool -> ImpM rep r op () -> ImpM rep r op () -> ImpM rep r op () sIf cond tbranch fbranch = do
src/Futhark/CodeGen/ImpGen/GPU/Base.hs view
@@ -146,30 +146,38 @@ case safety of Safe -> sWhen (inBounds (Slice (map DimFix is')) dims) _ -> id- boundsCheck $- case op of- Nothing ->- forM_ (zip arrs vs) $ \(arr, v) -> copyDWIMFix arr is' v []- Just lam -> do- dLParams $ lambdaParams lam- let (_x_params, y_params) =- splitAt (length vs) $ map paramName $ lambdaParams lam- forM_ (zip y_params vs) $ \(yp, v) -> copyDWIM yp [] v []- atomics <- kernelAtomics <$> askEnv- case atomicUpdateLocking atomics lam of- AtomicPrim f -> f space arrs is'- AtomicCAS f -> f space arrs is'- AtomicLocking f -> do- c_locks <- M.lookup c . kernelLocks <$> askEnv- case c_locks of- Just (Locks locks num_locks) -> do- let locking =- Locking locks 0 1 0 $- pure . (`rem` fromIntegral num_locks) . flattenIndex dims- f locking space arrs is'- Nothing ->- error $ "Missing locks for " ++ prettyString acc+ boundsCheck $ case op of+ Nothing ->+ forM_ (zip arrs vs) $ \(arr, v) -> copyDWIMFix arr is' v []+ Just lam -> do+ dLParams $ lambdaParams lam+ let (x_params, y_params) =+ splitAt (length vs) $ map paramName $ lambdaParams lam+ forM_ (zip y_params vs) $ \(yp, v) -> copyDWIM yp [] v [] + atomics <- kernelAtomics <$> askEnv+ case (space, atomicUpdateLocking atomics lam) of+ (ScalarSpace {}, _) -> do+ -- In this case we are dealing with an array that simply cannot be+ -- shared, and so we do not (and should not) use an atomic. Ideally,+ -- such cases are optimised away before code generation.+ forM_ (zip x_params arrs) $ \(xp, arr) -> copyDWIMFix xp [] (Var arr) is'+ compileBody' mempty $ lambdaBody lam+ forM_ (zip arrs $ bodyResult $ lambdaBody lam) $ \(arr, r) ->+ copyDWIMFix arr is' (resSubExp r) []+ (_, AtomicPrim f) -> f space arrs is'+ (_, AtomicCAS f) -> f space arrs is'+ (_, AtomicLocking f) -> do+ c_locks <- M.lookup c . kernelLocks <$> askEnv+ case c_locks of+ Just (Locks locks num_locks) -> do+ let locking =+ Locking locks 0 1 0 $+ pure . (`rem` fromIntegral num_locks) . flattenIndex dims+ f locking space arrs is'+ Nothing ->+ error $ "Missing locks for " ++ prettyString acc+ -- | Generate a constant device array of 32-bit integer zeroes with -- the given number of elements. Initialised with a replicate. genZeroes :: String -> Int -> CallKernelGen VName@@ -893,17 +901,9 @@ -- While-loop: Try to insert your value let (toBits, fromBits) = case t of- FloatType Float16 ->- ( \v -> Imp.FunExp "to_bits16" [v] int16,- \v -> Imp.FunExp "from_bits16" [v] t- )- FloatType Float32 ->- ( \v -> Imp.FunExp "to_bits32" [v] int32,- \v -> Imp.FunExp "from_bits32" [v] t- )- FloatType Float64 ->- ( \v -> Imp.FunExp "to_bits64" [v] int64,- \v -> Imp.FunExp "from_bits64" [v] t+ FloatType ft ->+ ( Imp.ConvOpExp (FPToBits ft),+ Imp.ConvOpExp (BitsToFP ft) ) _ -> (id, id) @@ -1239,6 +1239,11 @@ body <- makeAllMemoryGlobal $ subImpM_ (KernelEnv atomics constants locks) ops m uses <- computeKernelUses body $ M.keys $ kAttrConstExps attrs tblock_size <- onBlockSize $ kernelBlockSize constants+ -- XXX: the provenance of the kernel itself is usually boring (it just points+ -- to somewhere in /prelude), so try to synthesize it from the body instead.+ -- It may be that we should do this earlier in the compiler.+ let p = Imp.foldProvenances (const mempty) body+ when (p /= mempty) $ emit $ Imp.Meta $ Imp.MetaProvenance p emit . Imp.Op . Imp.CallKernel $ Imp.Kernel { Imp.kernelBody = body,
src/Futhark/CodeGen/ImpGen/GPU/Block.hs view
@@ -578,6 +578,7 @@ compileBlockOp pat _ = compilerBugS $ "compileBlockOp: cannot compile rhs of binding " ++ prettyString pat +-- | The operations for block-level kernels. blockOperations :: Operations GPUMem KernelEnv Imp.KernelOp blockOperations = (defaultOperations compileBlockOp)@@ -598,6 +599,7 @@ _ -> pure False arrayInSharedMemory Constant {} = pure False +-- | Create a kernel with GPU operations at the block level. sKernelBlock :: String -> VName ->@@ -606,6 +608,8 @@ CallKernelGen () sKernelBlock = sKernel blockOperations $ sExt64 . kernelBlockId +-- | Generate code for writing this result of a block-level kernel. The+-- 'PatElem' and 'KernelResult' must be matched as in the original segop. compileBlockResult :: SegSpace -> PatElem LetDecMem ->
src/Futhark/CodeGen/ImpGen/GPU/ToOpenCL.hs view
@@ -194,7 +194,6 @@ codeMayFail f (For _ _ x) = codeMayFail f x codeMayFail f (While _ x) = codeMayFail f x codeMayFail f (If _ x y) = codeMayFail f x || codeMayFail f y-codeMayFail f (Comment _ x) = codeMayFail f x codeMayFail _ _ = False hostOpMayFail :: ImpGPU.HostOp -> Bool@@ -382,7 +381,6 @@ then (SafetyNone, []) else -- No possible failures in this kernel, so if we make -- it past an initial check, then we are good to go.- ( SafetyCheap, [C.citems|if (*global_failure >= 0) { return; }|] )@@ -663,7 +661,8 @@ pure [C.cty|$tyquals:(volatile++quals) $ty:t|] atomicSpace (Space sid) = sid- atomicSpace _ = "global"+ atomicSpace ScalarSpace {} = error "atomicSpace: cannot do atomics on ScalarSpace"+ atomicSpace DefaultSpace = "global" doAtomic s t old arr ind val op ty = do ind' <- GC.compileExp $ untyped $ unCount ind@@ -896,7 +895,7 @@ typesInCode (If (TPrimExp e) c1 c2) = typesInExp e <> typesInCode c1 <> typesInCode c2 typesInCode (Assert e _ _) = typesInExp e-typesInCode (Comment _ c) = typesInCode c+typesInCode (Meta _) = mempty typesInCode (DebugPrint _ v) = maybe mempty typesInExp v typesInCode (TracePrint msg) = foldMap typesInExp msg typesInCode Op {} = mempty
src/Futhark/CodeGen/ImpGen/Multicore.hs view
@@ -155,9 +155,12 @@ s <- segOpString op let seq_task = Imp.ParallelTask seq_code free_params <- filter (`notElem` retvals) <$> freeParams (par_task, seq_task)- emit . Imp.Op $- Imp.SegOp s free_params seq_task par_task retvals $- scheduling_info (decideScheduling' op seq_code)+ let code =+ Imp.Op $+ Imp.SegOp s free_params seq_task par_task retvals $+ scheduling_info (decideScheduling' op seq_code)+ emit $ Imp.Meta $ Imp.MetaProvenance $ taskProvenance code+ emit code compileSegOp :: Pat LetDecMem ->
src/Futhark/CodeGen/ImpGen/Multicore/Base.hs view
@@ -26,11 +26,11 @@ inISPC, toParam, sLoopNestVectorized,+ taskProvenance, ) where import Control.Monad-import Data.Bifunctor import Data.Map qualified as M import Data.Maybe import Futhark.CodeGen.ImpCode.Multicore qualified as Imp@@ -151,7 +151,6 @@ isLoadBalanced (a Imp.:>>: b) = isLoadBalanced a && isLoadBalanced b isLoadBalanced (Imp.For _ _ a) = isLoadBalanced a isLoadBalanced (Imp.If _ a b) = isLoadBalanced a && isLoadBalanced b-isLoadBalanced (Imp.Comment _ a) = isLoadBalanced a isLoadBalanced Imp.While {} = False isLoadBalanced (Imp.Op (Imp.ParLoop _ code _)) = isLoadBalanced code isLoadBalanced (Imp.Op (Imp.ForEachActive _ a)) = isLoadBalanced a@@ -189,8 +188,6 @@ (mempty, Imp.While cond body) f (Imp.For i bound body) = (mempty, Imp.For i bound body)- f (Imp.Comment s code) =- second (Imp.Comment s) (f code) f Imp.Free {} = mempty f (Imp.If cond tcode fcode) =@@ -491,17 +488,9 @@ bytes <- toIntegral $ primBitSize t let (toBits, fromBits) = case t of- FloatType Float16 ->- ( \v -> Imp.FunExp "to_bits16" [v] int16,- \v -> Imp.FunExp "from_bits16" [v] t- )- FloatType Float32 ->- ( \v -> Imp.FunExp "to_bits32" [v] int32,- \v -> Imp.FunExp "from_bits32" [v] t- )- FloatType Float64 ->- ( \v -> Imp.FunExp "to_bits64" [v] int64,- \v -> Imp.FunExp "from_bits64" [v] t+ FloatType ft ->+ ( Imp.ConvOpExp (FPToBits ft),+ Imp.ConvOpExp (BitsToFP ft) ) _ -> (id, id) @@ -544,3 +533,17 @@ toIntegral 32 = pure int32 toIntegral 64 = pure int64 toIntegral b = error $ "number of bytes is not supported for CAS - " ++ prettyString b++-- | Find the provenance of a task given its body. This is done by folding the+-- provenance of the code in the body.+taskProvenance :: Imp.MCCode -> Provenance+taskProvenance = Imp.foldProvenances onOp+ where+ onOp (Imp.ParLoop _ code _) = taskProvenance code+ onOp (Imp.SegOp _ _ task1 task2 _ _) =+ onTask task1 <> maybe mempty onTask task2+ onOp (Imp.ISPCKernel code _) = taskProvenance code+ onOp (Imp.ForEach _ _ _ code) = taskProvenance code+ onOp (Imp.ForEachActive _ code) = taskProvenance code+ onOp _ = mempty+ onTask (Imp.ParallelTask code) = taskProvenance code
src/Futhark/CodeGen/ImpGen/Multicore/SegScan.hs view
@@ -1,3 +1,5 @@+-- | Multicore code generation for SegScan. Uses a fairly naive multipass+-- algorithm, with no particular locality optimisations. module Futhark.CodeGen.ImpGen.Multicore.SegScan ( compileSegScan, )@@ -12,7 +14,7 @@ import Futhark.Util.IntegralExp (quot, rem) import Prelude hiding (quot, rem) --- Compile a SegScan construct+-- | Compile a SegScan construct. compileSegScan :: Pat LetDecMem -> SegSpace ->
src/Futhark/Compiler/Program.hs view
@@ -46,9 +46,9 @@ import Futhark.Util (interactWithFileSafely, nubOrd, startupTime) import Futhark.Util.Pretty (Doc, align, pretty) import Language.Futhark qualified as E+import Language.Futhark.Core (isBuiltin) import Language.Futhark.Parser (SyntaxError (..), parseFuthark) import Language.Futhark.Prelude-import Language.Futhark.Prop (isBuiltin) import Language.Futhark.Semantic import Language.Futhark.TypeChecker qualified as E import Language.Futhark.Warnings
src/Futhark/IR/Aliases.hs view
@@ -380,10 +380,10 @@ StmAux (ExpDec rep) -> Exp (Aliases rep) -> Stm (Aliases rep)-mkAliasedStm pat (StmAux cs attrs dec) e =+mkAliasedStm pat aux e = Let (mkAliasedPat pat e)- (StmAux cs attrs (AliasDec $ consumedInExp e, dec))+ (fmap (AliasDec (consumedInExp e),) aux) e instance
src/Futhark/IR/Mem/Simplify.hs view
@@ -105,7 +105,7 @@ -- the certificates on it. This can help hoist things that would -- otherwise be stuck inside loops or branches. decertifySafeAlloc :: (SimplifyMemory rep inner) => TopDownRuleOp (Wise rep)-decertifySafeAlloc _ pat (StmAux cs attrs _) op+decertifySafeAlloc _ pat (StmAux cs attrs _ _) op | cs /= mempty, [Mem _] <- patTypes pat, safeOp op =
src/Futhark/IR/Parse.hs view
@@ -27,6 +27,7 @@ import Data.Functor import Data.List (singleton) import Data.List.NonEmpty (NonEmpty (..))+import Data.Loc qualified as L import Data.Maybe import Data.Set qualified as S import Data.Text qualified as T@@ -238,12 +239,31 @@ pErrorMsg :: Parser (ErrorMsg SubExp) pErrorMsg = ErrorMsg <$> braces (pErrorMsgPart `sepBy` pComma) -pSrcLoc :: Parser SrcLoc-pSrcLoc = pStringLiteral $> mempty -- FIXME+lInt :: Parser Int+lInt = lexeme L.decimal -pErrorLoc :: Parser (SrcLoc, [SrcLoc])-pErrorLoc = (,mempty) <$> pSrcLoc+pPos :: Parser L.Pos+pPos =+ L.Pos+ <$> manyTill L.charLiteral (char ':')+ <*> lInt+ <*> (char ':' *> lInt)+ <*> pure (-1) -- Cannot recover offset. +pLocStr :: Parser Loc+pLocStr = do+ start <- pPos+ void $ char '-'+ end <- do+ x <- lInt+ choice+ [ do+ y <- char ':' *> lInt+ pure $ L.Pos (L.posFile start) x y (-1),+ pure $ L.Pos (L.posFile start) (L.posLine start) x (-1)+ ]+ pure $ L.Loc start end+ pIota :: Parser BasicOp pIota = choice $ map p allIntTypes@@ -274,15 +294,7 @@ $> uncurry (Opaque . OpaqueTrace) <*> parens ((,) <$> pStringLiteral <* pComma <*> pSubExp), keyword "copy" $> Replicate mempty . Var <*> parens pVName,- keyword "assert"- *> parens- ( Assert- <$> pSubExp- <* pComma- <*> pErrorMsg- <* pComma- <*> pErrorLoc- ),+ keyword "assert" *> parens (Assert <$> pSubExp <* pComma <*> pErrorMsg), keyword "replicate" *> parens (Replicate <$> pShape <* pComma <*> pSubExp), keyword "reshape"@@ -341,6 +353,8 @@ pConvOp "btoi" (const BToI) (keyword "bool") pIntType, pConvOp "ftob" (const . FToB) pFloatType (keyword "bool"), pConvOp "btof" (const BToF) (keyword "bool") pFloatType,+ pConvOp "fptobits" (const . FPToBits) pFloatType pIntType,+ pConvOp "bitstofp" (const BitsToFP) pIntType pFloatType, -- pIndex, pFlatIndex,@@ -485,7 +499,7 @@ <*> parens (pArg `sepBy` pComma) <* pColon <*> pRetTypes pr- <*> pure (safety, mempty, mempty)+ <*> pure safety pArg = choice@@ -587,11 +601,21 @@ pSubExpRes :: Parser SubExpRes pSubExpRes = SubExpRes <$> pCerts <*> pSubExp +pProvenance :: Parser Provenance+pProvenance =+ choice+ [ lexeme $ between (char '"') (char '"') $ do+ l <- pLocStr `sepBy1` "->"+ pure $ Provenance (init l) (last l),+ pure mempty+ ]+ pStm :: PR rep -> Parser (Stm rep)-pStm pr =- keyword "let" $> Let <*> pPat pr <* pEqual <*> pStmAux <*> pExp pr+pStm pr = do+ loc <- pProvenance+ keyword "let" $> Let <*> pPat pr <* pEqual <*> pStmAux loc <*> pExp pr where- pStmAux = flip StmAux <$> pAttrs <*> pCerts <*> pure (pExpDec pr)+ pStmAux loc = flip StmAux <$> pAttrs <*> pCerts <*> pure loc <*> pure (pExpDec pr) pStms :: PR rep -> Parser (Stms rep) pStms pr = stmsFromList <$> many (pStm pr)
src/Futhark/IR/Pretty.hs view
@@ -148,9 +148,15 @@ instance Pretty Attrs where pretty = hsep . attrAnnots +prettyLoc :: Loc -> Doc a+prettyLoc = pretty . locText++instance Pretty Provenance where+ pretty (Provenance locs loc) = mconcat $ punctuate "->" $ map prettyLoc $ locs ++ [loc]+ instance (Pretty dec) => Pretty (StmAux dec) where- pretty (StmAux cs attrs dec) =- braces $ mconcat $ punctuate semi [pretty cs, pretty attrs, pretty dec]+ pretty (StmAux cs attrs p dec) =+ braces $ mconcat $ punctuate semi [pretty cs, pretty attrs, pretty p, pretty dec] instance (Pretty t) => Pretty (Pat t) where pretty (Pat xs) = braces $ commastack $ map pretty xs@@ -164,13 +170,18 @@ instance (PrettyRep rep) => Pretty (Stm rep) where pretty stm@(Let pat aux e) =- align . hang 2 $+ (locstr <>) . align . hang 2 $ "let" <+> align (pretty pat) <+> case stmannot of [] -> equals </> pretty e _ -> equals </> (stack stmannot </> pretty e) where+ locstr =+ if stmAuxLoc aux == mempty+ then mempty+ else dquotes (pretty (stmAuxLoc aux)) <> line+ stmannot = concat [ maybeToList (ppExpDec (stmAuxDec aux) e),@@ -243,8 +254,8 @@ "concat" <> "@" <> pretty i <> apply (pretty w : pretty x : map pretty xs) pretty (Manifest v perm) = "manifest" <> apply [pretty v, apply (map pretty perm)]- pretty (Assert e msg (loc, _)) =- "assert" <> apply [pretty e, pretty msg, pretty $ show $ locStr loc]+ pretty (Assert e msg) =+ "assert" <> apply [pretty e, pretty msg] pretty (UpdateAcc safety acc is v) = update_acc_str <> apply@@ -312,12 +323,12 @@ MatchFallback -> " <fallback>" MatchEquiv -> " <equiv>" pretty (BasicOp op) = pretty op- pretty (Apply fname args ret (safety, _, _)) =+ pretty (Apply fname args ret safety) = applykw <+> pretty (nameToString fname) <> apply (map (align . prettyArg) args) </> colon- <+> braces (commasep $ map prettyRet ret)+ <+> braces (align $ commasep $ map prettyRet ret) where prettyArg (arg, Consume) = "*" <> pretty arg prettyArg (arg, _) = pretty arg
src/Futhark/IR/Prop.hs view
@@ -28,6 +28,7 @@ defAux, stmCerts, certify,+ attribute, expExtTypesFromPat, attrsForAssert, lamIsBinOp,@@ -167,7 +168,7 @@ -- | A 'StmAux' with empty 'Certs'. defAux :: dec -> StmAux dec-defAux = StmAux mempty mempty+defAux = StmAux mempty mempty mempty -- | The certificates associated with a statement. stmCerts :: Stm rep -> Certs@@ -175,8 +176,13 @@ -- | Add certificates to a statement. certify :: Certs -> Stm rep -> Stm rep-certify cs1 (Let pat (StmAux cs2 attrs dec) e) =- Let pat (StmAux (cs2 <> cs1) attrs dec) e+certify cs1 (Let pat aux e) =+ Let pat (aux {stmAuxCerts = stmAuxCerts aux <> cs1}) e++-- | Add attributes to a statement.+attribute :: Attrs -> Stm rep -> Stm rep+attribute attrs (Let pat aux e) =+ Let pat (aux {stmAuxAttrs = stmAuxAttrs aux <> attrs}) e -- | A handy shorthand for properties that we usually want for things -- we stuff into ASTs.
src/Futhark/IR/Prop/Names.hs view
@@ -307,7 +307,7 @@ ) => FreeIn (Stm rep) where- freeIn' (Let pat (StmAux cs attrs dec) e) =+ freeIn' (Let pat (StmAux cs attrs _ dec) e) = freeIn' cs <> freeIn' attrs <> precomputed dec (freeIn' dec <> freeIn' e <> freeIn' pat)@@ -399,7 +399,7 @@ freeIn' (Attrs _) = mempty instance (FreeIn dec) => FreeIn (StmAux dec) where- freeIn' (StmAux cs attrs dec) = freeIn' cs <> freeIn' attrs <> freeIn' dec+ freeIn' (StmAux cs attrs _ dec) = freeIn' cs <> freeIn' attrs <> freeIn' dec instance (FreeIn a) => FreeIn (MatchDec a) where freeIn' (MatchDec r _) = freeIn' r
src/Futhark/IR/Prop/Types.hs view
@@ -12,6 +12,7 @@ staticShapes1, primType, isAcc,+ isMem, arrayOf, arrayOfRow, arrayOfShape,@@ -297,6 +298,11 @@ isAcc :: TypeBase shape u -> Bool isAcc Acc {} = True isAcc _ = False++-- | Is this a memory block?+isMem :: TypeBase shape u -> Bool+isMem Mem {} = True+isMem _ = False -- | Returns the bottommost type of an array. For @[][]i32@, this -- would be @i32@. If the given type is not an array, it is returned.
src/Futhark/IR/Rephrase.hs view
@@ -56,10 +56,10 @@ -- | Rephrase a statement. rephraseStm :: (Monad m) => Rephraser m from to -> Stm from -> m (Stm to)-rephraseStm rephraser (Let pat (StmAux cs attrs dec) e) =+rephraseStm rephraser (Let pat aux e) = Let <$> rephrasePat (rephraseLetBoundDec rephraser) pat- <*> (StmAux cs attrs <$> rephraseExpDec rephraser dec)+ <*> traverse (rephraseExpDec rephraser) aux <*> rephraseExp rephraser e -- | Rephrase a pattern.
src/Futhark/IR/Syntax.hs view
@@ -204,16 +204,27 @@ data StmAux dec = StmAux { stmAuxCerts :: !Certs, stmAuxAttrs :: Attrs,+ stmAuxLoc :: Provenance, stmAuxDec :: dec } deriving (Ord, Show, Eq) +instance Functor StmAux where+ fmap = fmapDefault++instance Foldable StmAux where+ foldMap = foldMapDefault++instance Traversable StmAux where+ traverse f (StmAux cs attrs loc dec) =+ StmAux cs attrs loc <$> f dec+ instance (Monoid dec) => Monoid (StmAux dec) where- mempty = StmAux mempty mempty mempty+ mempty = StmAux mempty mempty mempty mempty instance (Semigroup dec) => Semigroup (StmAux dec) where- StmAux cs1 attrs1 dec1 <> StmAux cs2 attrs2 dec2 =- StmAux (cs1 <> cs2) (attrs1 <> attrs2) (dec1 <> dec2)+ StmAux cs1 attrs1 loc1 dec1 <> StmAux cs2 attrs2 loc2 dec2 =+ StmAux (cs1 <> cs2) (attrs1 <> attrs2) (loc1 <> loc2) (dec1 <> dec2) -- | A local variable binding. data Stm rep = Let@@ -376,9 +387,10 @@ CmpOp CmpOp SubExp SubExp | -- | Conversion "casting". ConvOp ConvOp SubExp- | -- | Turn a boolean into a certificate, halting the program with the- -- given error message if the boolean is false.- Assert SubExp (ErrorMsg SubExp) (SrcLoc, [SrcLoc])+ | -- | Turn a boolean into a certificate, halting the program with the given+ -- error message if the boolean is false. The error location comes from the+ -- provenance of the statement.+ Assert SubExp (ErrorMsg SubExp) | -- | The certificates for bounds-checking are part of the 'Stm'. Index VName (Slice SubExp) | -- | An in-place update of the given array at the given position.@@ -472,7 +484,7 @@ data Exp rep = -- | A simple (non-recursive) operation. BasicOp BasicOp- | Apply Name [(SubExp, Diet)] [(RetType rep, RetAls)] (Safety, SrcLoc, [SrcLoc])+ | Apply Name [(SubExp, Diet)] [(RetType rep, RetAls)] Safety | -- | A match statement picks a branch by comparing the given -- subexpressions (called the /scrutinee/) with the pattern in -- each of the cases. If none of the cases match, the /default@@ -608,3 +620,25 @@ progFuns :: [FunDef rep] } deriving (Eq, Ord, Show)++-- Note [Tracking Source Locations]+--+-- It is useful for such things as profiling to be able to relate the generated+-- code to the original source code. The Futhark compiler is not great at this,+-- but we have begun to try a bit.+--+-- Each 'Stm' is associated with a 'Provenance', which keeps information about+-- the (single) source expression that gave rise to the statement. This is by+-- itself not challenging (although a single source expression can give rise to+-- multiple core expressions). The real challenge is how to propagate this+-- information when the compiler starts rewriting the program, without every+-- rewrite having to be laboriously aware of provenances. In practice, we stick+-- it in the StmAux and hope that consistent use of such constructs as 'auxing'+-- will mostly do the right thing.+--+-- Another downside of our representation is that it is not flow-sensitive: an+-- expression can be reached in multiple ways and generally the innermost one is+-- picked. This is particularly problematic for the prelude functions (e.g.+-- f32.exp), as it is not exceptionally useful when the provenance simply points+-- at a file in /prelude. We could address this by just special casing /prelude,+-- but that won't help when users write their own libraries.
src/Futhark/IR/Syntax/Core.hs view
@@ -73,6 +73,10 @@ FlatDimIndex (..), flatSliceDims, flatSliceStrides,++ -- * Provenance+ Provenance (..),+ stackProvenance, ) where @@ -82,12 +86,14 @@ import Data.Bifoldable import Data.Bifunctor import Data.Bitraversable+import Data.Loc (locEnd, locStart) import Data.Map.Strict qualified as M import Data.Maybe import Data.Set qualified as S import Data.String import Data.Text qualified as T import Data.Traversable (fmapDefault, foldMapDefault)+import Futhark.Util (splitFromEnd) import Language.Futhark.Core import Language.Futhark.Primitive import Prelude hiding (id, (.))@@ -642,3 +648,37 @@ instance Semigroup OpaqueTypes where OpaqueTypes x <> OpaqueTypes y = OpaqueTypes $ x <> filter ((`notElem` map fst x) . fst) y++-- | Information about what in the original program a given IR statement+-- corresponds to. See Note [Tracking Source Locations].+data Provenance = Provenance [Loc] Loc+ deriving (Eq, Ord, Show)++contains :: Loc -> Loc -> Bool+contains l1 l2 = locStart l1 <= locStart l2 && locEnd l1 >= locEnd l2++clean :: [Loc] -> [Loc]+clean (l : ls) | l == mempty = clean ls+clean (l1 : l2 : ls)+ -- Remove locations that completely enclose a successive location. This is to+ -- remove locations that correspond to lambdas that are immediately applied -+ -- they are pretty boring and just add clutter.+ | l1 `contains` l2 = clean $ l2 : ls+ | otherwise = l1 : clean (l2 : ls)+clean ls = ls++stackProvenance :: Provenance -> Provenance -> Provenance+stackProvenance (Provenance xs x) (Provenance ys y) =+ case splitFromEnd 1 $ clean $ xs <> [x] <> ys <> [y] of+ (zs', [z']) -> Provenance zs' z'+ _ -> mempty -- Zero-information case.++instance Monoid Provenance where+ mempty = Provenance mempty mempty++instance Semigroup Provenance where+ Provenance xs x <> Provenance ys y+ | y == mempty = Provenance xs x+ | x == mempty = Provenance ys y+ | xs == ys = Provenance xs (x <> y)+ | otherwise = Provenance ys y
src/Futhark/IR/Traversals.hs view
@@ -113,10 +113,10 @@ <*> (MatchDec <$> mapM (mapOnBranchType tv) ts <*> pure s) where mapOnCase (Case vs body) = Case vs <$> mapOnBody tv mempty body-mapExpM tv (Apply fname args ret loc) = do+mapExpM tv (Apply fname args ret safety) = do args' <- forM args $ \(arg, d) -> (,) <$> mapOnSubExp tv arg <*> pure d- Apply fname args' <$> mapM (bitraverse (mapOnRetType tv) pure) ret <*> pure loc+ Apply fname args' <$> mapM (bitraverse (mapOnRetType tv) pure) ret <*> pure safety mapExpM tv (BasicOp (Index arr slice)) = BasicOp <$> ( Index@@ -164,8 +164,8 @@ pure $ BasicOp $ Concat i (x' :| ys') size' mapExpM tv (BasicOp (Manifest v perm)) = BasicOp <$> (Manifest <$> mapOnVName tv v <*> pure perm)-mapExpM tv (BasicOp (Assert e msg loc)) =- BasicOp <$> (Assert <$> mapOnSubExp tv e <*> traverse (mapOnSubExp tv) msg <*> pure loc)+mapExpM tv (BasicOp (Assert e msg)) =+ BasicOp <$> (Assert <$> mapOnSubExp tv e <*> traverse (mapOnSubExp tv) msg) mapExpM tv (BasicOp (Opaque op e)) = BasicOp <$> (Opaque op <$> mapOnSubExp tv e) mapExpM tv (BasicOp (UpdateAcc safety v is ses)) =@@ -327,7 +327,7 @@ walkOnVName tv x >> mapM_ (walkOnVName tv) ys >> walkOnSubExp tv size walkExpM tv (BasicOp (Manifest v _)) = walkOnVName tv v-walkExpM tv (BasicOp (Assert e msg _)) =+walkExpM tv (BasicOp (Assert e msg)) = walkOnSubExp tv e >> traverse_ (walkOnSubExp tv) msg walkExpM tv (BasicOp (Opaque _ e)) = walkOnSubExp tv e
src/Futhark/IR/TypeCheck.hs view
@@ -940,7 +940,7 @@ require [Prim int64] ressize checkBasicOp (Manifest arr perm) = checkBasicOp $ Rearrange arr perm -- Basically same thing!-checkBasicOp (Assert e (ErrorMsg parts) _) = do+checkBasicOp (Assert e (ErrorMsg parts)) = do require [Prim Bool] e mapM_ checkPart parts where@@ -1257,7 +1257,9 @@ Stm (Aliases rep) -> TypeM rep a -> TypeM rep a-checkStm stm@(Let pat (StmAux (Certs cs) _ (_, dec)) e) m = do+checkStm stm@(Let pat aux e) m = do+ let Certs cs = stmAuxCerts aux+ (_, dec) = stmAuxDec aux context "When checking certificates" $ mapM_ (requireI [Prim Unit]) cs context "When checking expression annotation" $ checkExpDec dec context ("When matching\n" <> message " " pat <> "\nwith\n" <> message " " e) $
src/Futhark/Internalise/AccurateSizes.hs view
@@ -51,61 +51,56 @@ ensureResultShape :: ErrorMsg SubExp ->- SrcLoc -> [Type] -> Result -> InternaliseM Result-ensureResultShape msg loc =- ensureResultExtShape msg loc . staticShapes+ensureResultShape msg =+ ensureResultExtShape msg . staticShapes ensureResultExtShape :: ErrorMsg SubExp ->- SrcLoc -> [ExtType] -> Result -> InternaliseM Result-ensureResultExtShape msg loc rettype res = do- res' <- ensureResultExtShapeNoCtx msg loc rettype res+ensureResultExtShape msg rettype res = do+ res' <- ensureResultExtShapeNoCtx msg rettype res ts <- mapM subExpResType res' let ctx = extractShapeContext rettype $ map arrayDims ts pure $ subExpsRes ctx ++ res' ensureResultExtShapeNoCtx :: ErrorMsg SubExp ->- SrcLoc -> [ExtType] -> Result -> InternaliseM Result-ensureResultExtShapeNoCtx msg loc rettype es = do+ensureResultExtShapeNoCtx msg rettype es = do es_ts <- mapM subExpResType es let ext_mapping = shapeExtMapping rettype es_ts rettype' = foldr (uncurry fixExt) rettype $ M.toList ext_mapping assertProperShape t (SubExpRes cs se) = let name = "result_proper_shape"- in SubExpRes cs <$> ensureExtShape msg loc t name se+ in SubExpRes cs <$> ensureExtShape msg t name se zipWithM assertProperShape rettype' es ensureExtShape :: ErrorMsg SubExp ->- SrcLoc -> ExtType -> String -> SubExp -> InternaliseM SubExp-ensureExtShape msg loc t name orig+ensureExtShape msg t name orig | Array {} <- t, Var v <- orig =- Var <$> ensureShapeVar msg loc t name v+ Var <$> ensureShapeVar msg t name v | otherwise = pure orig ensureShape :: ErrorMsg SubExp ->- SrcLoc -> Type -> String -> SubExp -> InternaliseM SubExp-ensureShape msg loc = ensureExtShape msg loc . staticShapes1+ensureShape msg = ensureExtShape msg . staticShapes1 -- | Reshape the arguments to a function so that they fit the expected -- shape declarations. Not used to change rank of arguments. Assumes@@ -113,28 +108,26 @@ ensureArgShapes :: (Typed (TypeBase Shape u)) => ErrorMsg SubExp ->- SrcLoc -> [VName] -> [TypeBase Shape u] -> [SubExp] -> InternaliseM [SubExp]-ensureArgShapes msg loc shapes paramts args =+ensureArgShapes msg shapes paramts args = zipWithM ensureArgShape (expectedTypes shapes paramts args) args where ensureArgShape _ (Constant v) = pure $ Constant v ensureArgShape t (Var v) | arrayRank t < 1 = pure $ Var v | otherwise =- ensureShape msg loc t (baseString v) $ Var v+ ensureShape msg t (baseString v) $ Var v ensureShapeVar :: ErrorMsg SubExp ->- SrcLoc -> ExtType -> String -> VName -> InternaliseM VName-ensureShapeVar msg loc t name v+ensureShapeVar msg t name v | Array {} <- t = do newdims <- arrayDims . removeExistentials t <$> lookupType v olddims <- arrayDims <$> lookupType v@@ -143,7 +136,7 @@ else do matches <- zipWithM checkDim newdims olddims all_match <- letSubExp "match" =<< eAll matches- cs <- assert "empty_or_match_cert" all_match msg loc+ cs <- assert "empty_or_match_cert" all_match msg certifying cs $ letExp name $ shapeCoerce newdims v | otherwise = pure v where
src/Futhark/Internalise/Defunctionalise.hs view
@@ -738,7 +738,7 @@ (pats, body, tp) <- etaExpand (RetType [] $ toRes Nonunique $ typeOf e) e let env = foldMap envFromPat pats body' <- localEnv env $ defuncExp' body- pure $ Lambda pats body' Nothing (Info tp) mempty+ pure $ Lambda pats body' Nothing (Info tp) (srclocOf e) | otherwise = defuncExp' e etaExpand :: ResRetType -> Exp -> DefM ([Pat ParamType], Exp, ResRetType)@@ -910,11 +910,11 @@ liftedName _ _ = "defunc" defuncApplyArg ::- String ->+ (String, SrcLoc) -> (Exp, StaticVal) -> ((Maybe VName, Exp), [ParamType]) -> DefM (Exp, StaticVal)-defuncApplyArg fname_s (f', LambdaSV pat lam_e_t lam_e closure_env) ((argext, arg), _) = do+defuncApplyArg (fname_s, floc) (f', LambdaSV pat lam_e_t lam_e closure_env) ((argext, arg), _) = do (arg', arg_sv) <- defuncExp arg let env' = alwaysMatchPatSV pat arg_sv dims = mempty@@ -961,7 +961,7 @@ let f_t = toStruct $ typeOf f' arg_t = toStruct $ typeOf arg' fname_t = foldFunType [toParam Observe f_t, toParam (diet (patternType pat)) arg_t] lifted_rettype- fname' = Var (qualName fname) (Info fname_t) (srclocOf arg)+ fname' = Var (qualName fname) (Info fname_t) floc callret <- unRetType lifted_rettype pure@@ -979,7 +979,7 @@ apply_e = mkApply f' [(argext, arg')] callret pure (apply_e, sv) ---defuncApplyArg fname_s (_, sv) ((_, arg), _) =+defuncApplyArg (fname_s, _) (_, sv) ((_, arg), _) = error $ "defuncApplyArg: cannot apply StaticVal\n" <> show sv@@ -1009,7 +1009,7 @@ let fname = liftedName 0 f (argtypes, _) = unfoldFunType $ typeOf f fmap (first $ updateReturn appres) $- foldM (defuncApplyArg fname) (f', f_sv) $+ foldM (defuncApplyArg (fname, loc)) (f', f_sv) $ NE.zip args $ NE.tails argtypes where
src/Futhark/Internalise/Exps.hs view
@@ -46,7 +46,7 @@ shiftRetAls d (RetAls pals rals) = RetAls pals $ map (+ d) rals internaliseValBind :: VisibleTypes -> E.ValBind -> InternaliseM ()-internaliseValBind types fb@(E.ValBind entry fname _ (Info rettype) tparams params body _ attrs loc) = do+internaliseValBind types fb@(E.ValBind entry fname _ (Info rettype) tparams params body _ attrs _) = do bindingFParams tparams params $ \shapeparams params' -> do let shapenames = map I.paramName shapeparams all_params = map pure shapeparams ++ concat params'@@ -70,7 +70,7 @@ bindExtSizes (E.AppRes (E.toStruct $ E.retType rettype) (E.retDims rettype)) body_res body_res' <-- ensureResultExtShape msg loc (map I.fromDecl rettype') $ subExpsRes body_res+ ensureResultExtShape msg (map I.fromDecl rettype') $ subExpsRes body_res let num_ctx = length (shapeContext rettype') pure ( body_res',@@ -110,7 +110,7 @@ generateEntryPoint :: VisibleTypes -> E.EntryPoint -> E.ValBind -> InternaliseM () generateEntryPoint types (E.EntryPoint e_params e_rettype) vb = do- let (E.ValBind _ ofname _ (Info rettype) tparams params _ _ attrs loc) = vb+ let (E.ValBind _ ofname _ (Info rettype) tparams params _ _ attrs _) = vb bindingFParams tparams params $ \shapeparams params' -> do let all_params = map pure shapeparams ++ concat params' (entry_rettype, retals) =@@ -133,7 +133,7 @@ Just ses -> pure ses Nothing ->- funcall "entry_result" (E.qualName ofname) args loc+ funcall "entry_result" (E.qualName ofname) args ctx <- extractShapeContext (zeroExts $ concat entry_rettype) <$> mapM (fmap I.arrayDims . subExpType) vals@@ -182,17 +182,17 @@ letValExp' name ses = map I.Var <$> letValExp name ses internaliseAppExp :: String -> E.AppRes -> E.AppExp -> InternaliseM [I.SubExp]-internaliseAppExp desc _ (E.Index e idxs loc) = do+internaliseAppExp desc _ (E.Index e idxs _) = do vs <- internaliseExpToVars "indexed" e dims <- case vs of [] -> pure [] -- Will this happen? v : _ -> I.arrayDims <$> lookupType v- (idxs', cs) <- internaliseSlice loc dims idxs+ (idxs', cs) <- internaliseSlice dims idxs let index v = do v_t <- lookupType v pure $ I.BasicOp $ I.Index v $ fullSlice v_t idxs' certifying cs $ mapM (letSubExp desc <=< index) vs-internaliseAppExp desc _ (E.Range start maybe_second end loc) = do+internaliseAppExp desc _ (E.Range start maybe_second end _) = do start' <- internaliseExp1 "range_start" start end' <- internaliseExp1 "range_end" $ case end of DownToExclusive e -> e@@ -325,7 +325,7 @@ I.BasicOp $ I.BinOp I.LogOr step_invalid bounds_invalid valid <- letSubExp "valid" $ I.BasicOp $ I.UnOp (I.Neg I.Bool) invalid- cs <- assert "range_valid_c" valid errmsg loc+ cs <- assert "range_valid_c" valid errmsg step_i64 <- asIntS Int64 step pos_step <-@@ -358,7 +358,6 @@ -- Argument evaluation is outermost-in so that any existential sizes -- created by function applications can be brought into scope. let fname = nameFromString $ prettyString $ baseName $ qualLeaf qfname- loc = srclocOf e arg_desc = nameToString fname ++ "_arg" -- Some functions are magical (overloaded) and we handle that here.@@ -383,26 +382,26 @@ -- arguments (except equality, but those cannot be -- existential), so we can safely ignore the existential -- dimensions.- | Just internalise <- isOverloadedFunction qfname desc loc -> do+ | Just internalise <- isOverloadedFunction qfname desc -> do let prepareArg (arg, _) = (E.toStruct (E.typeOf arg),) <$> internaliseExp "arg" arg internalise =<< mapM prepareArg args- | Just internalise <- isIntrinsicFunction qfname (map fst args) loc ->+ | Just internalise <- isIntrinsicFunction qfname (map fst args) -> internalise desc | baseTag (qualLeaf qfname) <= maxIntrinsicTag, Just (rettype, _) <- M.lookup fname I.builtInFunctions -> do let tag ses = [(se, I.Observe) | se <- ses] args' <- reverse <$> mapM (internaliseArg arg_desc) (reverse args) let args'' = concatMap tag args'- letValExp' desc $ I.Apply fname args'' [(I.Prim rettype, mempty)] (Safe, loc, [])+ letValExp' desc $ I.Apply fname args'' [(I.Prim rettype, mempty)] Safe | otherwise -> do args' <- concat . reverse <$> mapM (internaliseArg arg_desc) (reverse args)- funcall desc qfname args' loc+ funcall desc qfname args' internaliseAppExp desc _ (E.LetPat sizes pat e body _) = internalisePat desc sizes pat e $ internaliseExp desc body internaliseAppExp _ _ (E.LetFun ofname _ _ _) = error $ "Unexpected LetFun " ++ prettyString ofname-internaliseAppExp desc _ (E.Loop sparams mergepat loopinit form loopbody loc) = do+internaliseAppExp desc _ (E.Loop sparams mergepat loopinit form loopbody _) = do ses <- internaliseExp "loop_init" $ loopInitExp loopinit ((loopbody', (form', shapepat, mergepat', mergeinit')), initstms) <- collectStms $ handleForm ses form@@ -422,7 +421,6 @@ args' <- ensureArgShapes "initial loop values have right shape"- loc (map I.paramName shapepat) (map paramType $ shapepat ++ mergepat') args@@ -439,7 +437,6 @@ fmap subExpsRes . ensureArgShapes "shape of loop result does not match shapes in loop parameter"- loc (map (I.paramName . fst) merge) merge_ts . map resSubExp@@ -603,7 +600,7 @@ internaliseExp desc (E.Hole (Info t) loc) = do let msg = docText $ "Reached hole of type: " <> align (pretty t) ts = foldMap toList $ internaliseType (E.toStruct t)- c <- assert "hole_c" (constant False) (errorMsg [ErrorString msg]) loc+ c <- assert "hole_c" (constant False) $ errorMsg [ErrorString msg] case mapM hasStaticShape ts of Nothing -> error $ "Hole at " <> locStr loc <> " has existential type:\n" <> show ts@@ -612,8 +609,8 @@ certifying c $ mapM (fmap I.Var . letExp desc <=< eBlank . I.fromDecl) ts' internaliseExp desc (E.QualParens _ e _) = internaliseExp desc e-internaliseExp desc (E.StringLit vs _) =- fmap pure . letSubExp desc $+internaliseExp desc (E.StringLit vs loc) =+ locating loc . fmap pure . letSubExp desc $ I.BasicOp $ I.ArrayLit (map constant vs) $ I.Prim int8@@ -623,7 +620,7 @@ Just substs -> pure substs Nothing -> pure [I.Var name] internaliseExp desc (E.AppExp e (Info appres)) = do- ses <- internaliseAppExp desc appres e+ ses <- locating e $ internaliseAppExp desc appres e bindExtSizes appres ses pure ses internaliseExp _ (E.TupLit [] _) =@@ -642,9 +639,10 @@ (L noLoc (baseName name)) (E.Var (E.qualName name) t loc) loc-internaliseExp desc (E.ArrayVal vs t _) =- fmap pure . letSubExp desc . I.BasicOp $- I.ArrayVal (map internalisePrimValue vs) (internalisePrimType t)+internaliseExp desc (E.ArrayVal vs t loc) =+ locating loc $+ fmap pure . letSubExp desc . I.BasicOp $+ I.ArrayVal (map internalisePrimValue vs) (internalisePrimType t) internaliseExp desc (E.ArrayLit es (Info arr_t) loc) -- If this is a multidimensional array literal of primitives, we -- treat it specially by flattening it out followed by a reshape.@@ -688,7 +686,6 @@ mapM ( ensureShape "shape of element differs from shape of first element"- loc rt "elem_reshaped" )@@ -709,7 +706,7 @@ Just ([], [e]) internaliseExp desc (E.Ascript e _ _) = internaliseExp desc e-internaliseExp desc (E.Coerce e _ (Info et) loc) = do+internaliseExp desc (E.Coerce e _ (Info et) _) = do ses <- internaliseExp desc e ts <- internaliseCoerceType (E.toStruct et) <$> mapM subExpType ses dt' <- typeExpForError $ toStruct et@@ -718,18 +715,18 @@ let parts = ["Value of (desugared) shape ["] ++ intersperse "][" (map (ErrorVal int64) dims)- ++ ["] cannot match shape of type `"]+ ++ ["] cannot match shape of type \""] ++ dt'- ++ ["`."]- ensureExtShape (errorMsg parts) loc (I.fromDecl t') desc e'-internaliseExp desc (E.Negate e _) = do+ ++ ["\"."]+ ensureExtShape (errorMsg parts) (I.fromDecl t') desc e'+internaliseExp desc (E.Negate e loc) = locating loc $ do e' <- internaliseExp1 "negate_arg" e et <- subExpType e' case et of I.Prim pt -> letTupExp' desc $ I.BasicOp $ I.UnOp (I.Neg pt) e' _ -> error "Futhark.Internalise.internaliseExp: non-primitive type in Negate"-internaliseExp desc (E.Not e _) = do+internaliseExp desc (E.Not e loc) = locating loc $ do e' <- internaliseExp1 "not_arg" e et <- subExpType e' case et of@@ -739,7 +736,7 @@ letTupExp' desc $ I.BasicOp $ I.UnOp (I.Neg I.Bool) e' _ -> error "Futhark.Internalise.internaliseExp: non-int/bool type in Not"-internaliseExp desc (E.Update src slice ve loc) = do+internaliseExp desc (E.Update src slice ve loc) = locating loc $ do ves <- internaliseExp "lw_val" ve srcs <- internaliseExpToVars "src" src (src_dims, ve_dims) <- case (srcs, ves) of@@ -748,7 +745,7 @@ <$> (I.arrayDims <$> lookupType src_v) <*> (I.arrayDims <$> subExpType ve_v) _ -> pure ([], []) -- Will this happen?- (idxs', cs) <- internaliseSlice loc src_dims slice+ (idxs', cs) <- internaliseSlice src_dims slice let src_dims' = sliceDims (Slice idxs') rank = length src_dims' errormsg =@@ -763,10 +760,10 @@ let full_slice = fullSlice sname_t idxs' rowtype = sname_t `setArrayDims` sliceDims full_slice ve'' <-- ensureShape errormsg loc rowtype "lw_val_correct_shape" ve'+ ensureShape errormsg rowtype "lw_val_correct_shape" ve' letInPlace desc sname full_slice $ BasicOp $ SubExp ve'' certifying cs $ map I.Var <$> zipWithM comb srcs ves-internaliseExp desc (E.RecordUpdate src fields ve _ _) = do+internaliseExp desc (E.RecordUpdate src fields ve _ loc) = locating loc $ do src' <- internaliseExp desc src ve' <- internaliseExp desc ve replace (E.typeOf src) fields ve' src'@@ -822,9 +819,9 @@ env {envDoBoundsChecks = False} | otherwise = env {envAttrs = envAttrs env <> oneAttr attr'}-internaliseExp desc (E.Assert e1 e2 (Info check) loc) = do+internaliseExp desc (E.Assert e1 e2 (Info check) loc) = locating loc $ do e1' <- internaliseExp1 "assert_cond" e1- c <- assert "assert_c" e1' (errorMsg [ErrorString $ "Assertion is false: " <> check]) loc+ c <- assert "assert_c" e1' $ errorMsg [ErrorString $ "Assertion is false: " <> check] -- Make sure there are some bindings to certify. certifying c $ mapM rebind =<< internaliseExp desc e2 where@@ -832,7 +829,7 @@ v' <- newVName "assert_res" letBindNames [v'] $ I.BasicOp $ I.SubExp v pure $ I.Var v'-internaliseExp _ (E.Constr c es (Info (E.Scalar (E.Sum fs))) _) = do+internaliseExp _ (E.Constr c es (Info (E.Scalar (E.Sum fs))) loc) = locating loc $ do (ts, constr_map) <- internaliseSumType $ M.map (map E.toStruct) fs es' <- concat <$> mapM (internaliseExp "payload") es @@ -1023,11 +1020,10 @@ m internaliseSlice ::- SrcLoc -> [SubExp] -> [E.DimIndex] -> InternaliseM ([I.DimIndex SubExp], Certs)-internaliseSlice loc dims idxs = do+internaliseSlice dims idxs = do (idxs', oks, parts) <- unzip3 <$> zipWithM internaliseDimIndex dims idxs ok <- letSubExp "index_ok" =<< eAll oks let msg =@@ -1037,7 +1033,7 @@ ++ ["] out of bounds for array of shape ["] ++ intersperse "][" (map (ErrorVal int64) $ take (length idxs) dims) ++ ["]."]- c <- assert "index_certs" ok msg loc+ c <- assert "index_certs" ok msg pure (idxs', c) internaliseDimIndex ::@@ -1186,16 +1182,15 @@ String -> String -> (SubExp -> I.Lambda SOACS -> [SubExp] -> [VName] -> InternaliseM (SOAC SOACS)) ->- (E.Exp, E.Exp, E.Exp, SrcLoc) ->+ (E.Exp, E.Exp, E.Exp) -> InternaliseM [SubExp]-internaliseScanOrReduce desc what f (lam, ne, arr, loc) = do+internaliseScanOrReduce desc what f (lam, ne, arr) = do arrs <- internaliseExpToVars (what ++ "_arr") arr nes <- internaliseExp (what ++ "_ne") ne nes' <- forM (zip nes arrs) $ \(ne', arr') -> do rowtype <- I.stripArray 1 <$> lookupType arr' ensureShape "Row shape of input array does not match shape of neutral element"- loc rowtype (what ++ "_ne_right_shape") ne'@@ -1214,9 +1209,8 @@ E.Exp -> E.Exp -> E.Exp ->- SrcLoc -> InternaliseM [SubExp]-internaliseHist dim desc rf hist op ne buckets img loc = do+internaliseHist dim desc rf hist op ne buckets img = do rf' <- internaliseExp1 "hist_rf" rf ne' <- internaliseExp "hist_ne" ne hist' <- internaliseExpToVars "hist_hist" hist@@ -1228,7 +1222,6 @@ rowtype <- I.stripArray 1 <$> lookupType h ensureShape "Row shape of destination array does not match shape of neutral element"- loc rowtype "hist_ne_right_shape" n@@ -1247,7 +1240,6 @@ mkLambda params $ ensureResultShape "Row shape of value array does not match row shape of hist target"- (srclocOf img) rettype =<< bodyBind body @@ -1333,35 +1325,32 @@ mapM (letSubExp s . I.BasicOp <=< op) vs certifyingNonzero ::- SrcLoc -> IntType -> SubExp -> InternaliseM a -> InternaliseM a-certifyingNonzero loc t x m = do+certifyingNonzero t x m = do zero <- letSubExp "zero" $ I.BasicOp $ CmpOp (CmpEq (IntType t)) x (intConst t 0) nonzero <- letSubExp "nonzero" $ I.BasicOp $ UnOp (I.Neg I.Bool) zero- c <- assert "nonzero_cert" nonzero "division by zero" loc+ c <- assert "nonzero_cert" nonzero "division by zero" certifying c m certifyingNonnegative ::- SrcLoc -> IntType -> SubExp -> InternaliseM a -> InternaliseM a-certifyingNonnegative loc t x m = do+certifyingNonnegative t x m = do nonnegative <- letSubExp "nonnegative" . I.BasicOp $ CmpOp (CmpSle t) (intConst t 0) x- c <- assert "nonzero_cert" nonnegative "negative exponent" loc+ c <- assert "nonzero_cert" nonnegative "negative exponent" certifying c m internaliseBinOp ::- SrcLoc -> String -> E.BinOp -> I.SubExp ->@@ -1369,123 +1358,123 @@ E.PrimType -> E.PrimType -> InternaliseM [I.SubExp]-internaliseBinOp _ desc E.LogAnd x y E.Bool _ =+internaliseBinOp desc E.LogAnd x y E.Bool _ = simpleBinOp desc I.LogAnd x y-internaliseBinOp _ desc E.LogOr x y E.Bool _ =+internaliseBinOp desc E.LogOr x y E.Bool _ = simpleBinOp desc I.LogOr x y-internaliseBinOp _ desc E.Plus x y (E.Signed t) _ =+internaliseBinOp desc E.Plus x y (E.Signed t) _ = simpleBinOp desc (I.Add t I.OverflowWrap) x y-internaliseBinOp _ desc E.Plus x y (E.Unsigned t) _ =+internaliseBinOp desc E.Plus x y (E.Unsigned t) _ = simpleBinOp desc (I.Add t I.OverflowWrap) x y-internaliseBinOp _ desc E.Plus x y (E.FloatType t) _ =+internaliseBinOp desc E.Plus x y (E.FloatType t) _ = simpleBinOp desc (I.FAdd t) x y-internaliseBinOp _ desc E.Minus x y (E.Signed t) _ =+internaliseBinOp desc E.Minus x y (E.Signed t) _ = simpleBinOp desc (I.Sub t I.OverflowWrap) x y-internaliseBinOp _ desc E.Minus x y (E.Unsigned t) _ =+internaliseBinOp desc E.Minus x y (E.Unsigned t) _ = simpleBinOp desc (I.Sub t I.OverflowWrap) x y-internaliseBinOp _ desc E.Minus x y (E.FloatType t) _ =+internaliseBinOp desc E.Minus x y (E.FloatType t) _ = simpleBinOp desc (I.FSub t) x y-internaliseBinOp _ desc E.Times x y (E.Signed t) _ =+internaliseBinOp desc E.Times x y (E.Signed t) _ = simpleBinOp desc (I.Mul t I.OverflowWrap) x y-internaliseBinOp _ desc E.Times x y (E.Unsigned t) _ =+internaliseBinOp desc E.Times x y (E.Unsigned t) _ = simpleBinOp desc (I.Mul t I.OverflowWrap) x y-internaliseBinOp _ desc E.Times x y (E.FloatType t) _ =+internaliseBinOp desc E.Times x y (E.FloatType t) _ = simpleBinOp desc (I.FMul t) x y-internaliseBinOp loc desc E.Divide x y (E.Signed t) _ =- certifyingNonzero loc t y $+internaliseBinOp desc E.Divide x y (E.Signed t) _ =+ certifyingNonzero t y $ simpleBinOp desc (I.SDiv t I.Unsafe) x y-internaliseBinOp loc desc E.Divide x y (E.Unsigned t) _ =- certifyingNonzero loc t y $+internaliseBinOp desc E.Divide x y (E.Unsigned t) _ =+ certifyingNonzero t y $ simpleBinOp desc (I.UDiv t I.Unsafe) x y-internaliseBinOp _ desc E.Divide x y (E.FloatType t) _ =+internaliseBinOp desc E.Divide x y (E.FloatType t) _ = simpleBinOp desc (I.FDiv t) x y-internaliseBinOp _ desc E.Pow x y (E.FloatType t) _ =+internaliseBinOp desc E.Pow x y (E.FloatType t) _ = simpleBinOp desc (I.FPow t) x y-internaliseBinOp loc desc E.Pow x y (E.Signed t) _ =- certifyingNonnegative loc t y $+internaliseBinOp desc E.Pow x y (E.Signed t) _ =+ certifyingNonnegative t y $ simpleBinOp desc (I.Pow t) x y-internaliseBinOp _ desc E.Pow x y (E.Unsigned t) _ =+internaliseBinOp desc E.Pow x y (E.Unsigned t) _ = simpleBinOp desc (I.Pow t) x y-internaliseBinOp loc desc E.Mod x y (E.Signed t) _ =- certifyingNonzero loc t y $+internaliseBinOp desc E.Mod x y (E.Signed t) _ =+ certifyingNonzero t y $ simpleBinOp desc (I.SMod t I.Unsafe) x y-internaliseBinOp loc desc E.Mod x y (E.Unsigned t) _ =- certifyingNonzero loc t y $+internaliseBinOp desc E.Mod x y (E.Unsigned t) _ =+ certifyingNonzero t y $ simpleBinOp desc (I.UMod t I.Unsafe) x y-internaliseBinOp _ desc E.Mod x y (E.FloatType t) _ =+internaliseBinOp desc E.Mod x y (E.FloatType t) _ = simpleBinOp desc (I.FMod t) x y-internaliseBinOp loc desc E.Quot x y (E.Signed t) _ =- certifyingNonzero loc t y $+internaliseBinOp desc E.Quot x y (E.Signed t) _ =+ certifyingNonzero t y $ simpleBinOp desc (I.SQuot t I.Unsafe) x y-internaliseBinOp loc desc E.Quot x y (E.Unsigned t) _ =- certifyingNonzero loc t y $+internaliseBinOp desc E.Quot x y (E.Unsigned t) _ =+ certifyingNonzero t y $ simpleBinOp desc (I.UDiv t I.Unsafe) x y-internaliseBinOp loc desc E.Rem x y (E.Signed t) _ =- certifyingNonzero loc t y $+internaliseBinOp desc E.Rem x y (E.Signed t) _ =+ certifyingNonzero t y $ simpleBinOp desc (I.SRem t I.Unsafe) x y-internaliseBinOp loc desc E.Rem x y (E.Unsigned t) _ =- certifyingNonzero loc t y $+internaliseBinOp desc E.Rem x y (E.Unsigned t) _ =+ certifyingNonzero t y $ simpleBinOp desc (I.UMod t I.Unsafe) x y-internaliseBinOp _ desc E.ShiftR x y (E.Signed t) _ =+internaliseBinOp desc E.ShiftR x y (E.Signed t) _ = simpleBinOp desc (I.AShr t) x y-internaliseBinOp _ desc E.ShiftR x y (E.Unsigned t) _ =+internaliseBinOp desc E.ShiftR x y (E.Unsigned t) _ = simpleBinOp desc (I.LShr t) x y-internaliseBinOp _ desc E.ShiftL x y (E.Signed t) _ =+internaliseBinOp desc E.ShiftL x y (E.Signed t) _ = simpleBinOp desc (I.Shl t) x y-internaliseBinOp _ desc E.ShiftL x y (E.Unsigned t) _ =+internaliseBinOp desc E.ShiftL x y (E.Unsigned t) _ = simpleBinOp desc (I.Shl t) x y-internaliseBinOp _ desc E.Band x y (E.Signed t) _ =+internaliseBinOp desc E.Band x y (E.Signed t) _ = simpleBinOp desc (I.And t) x y-internaliseBinOp _ desc E.Band x y (E.Unsigned t) _ =+internaliseBinOp desc E.Band x y (E.Unsigned t) _ = simpleBinOp desc (I.And t) x y-internaliseBinOp _ desc E.Xor x y (E.Signed t) _ =+internaliseBinOp desc E.Xor x y (E.Signed t) _ = simpleBinOp desc (I.Xor t) x y-internaliseBinOp _ desc E.Xor x y (E.Unsigned t) _ =+internaliseBinOp desc E.Xor x y (E.Unsigned t) _ = simpleBinOp desc (I.Xor t) x y-internaliseBinOp _ desc E.Bor x y (E.Signed t) _ =+internaliseBinOp desc E.Bor x y (E.Signed t) _ = simpleBinOp desc (I.Or t) x y-internaliseBinOp _ desc E.Bor x y (E.Unsigned t) _ =+internaliseBinOp desc E.Bor x y (E.Unsigned t) _ = simpleBinOp desc (I.Or t) x y-internaliseBinOp _ desc E.Equal x y t _ =+internaliseBinOp desc E.Equal x y t _ = simpleCmpOp desc (I.CmpEq $ internalisePrimType t) x y-internaliseBinOp _ desc E.NotEqual x y t _ = do+internaliseBinOp desc E.NotEqual x y t _ = do eq <- letSubExp (desc ++ "true") $ I.BasicOp $ I.CmpOp (I.CmpEq $ internalisePrimType t) x y fmap pure $ letSubExp desc $ I.BasicOp $ I.UnOp (I.Neg I.Bool) eq-internaliseBinOp _ desc E.Less x y (E.Signed t) _ =+internaliseBinOp desc E.Less x y (E.Signed t) _ = simpleCmpOp desc (I.CmpSlt t) x y-internaliseBinOp _ desc E.Less x y (E.Unsigned t) _ =+internaliseBinOp desc E.Less x y (E.Unsigned t) _ = simpleCmpOp desc (I.CmpUlt t) x y-internaliseBinOp _ desc E.Leq x y (E.Signed t) _ =+internaliseBinOp desc E.Leq x y (E.Signed t) _ = simpleCmpOp desc (I.CmpSle t) x y-internaliseBinOp _ desc E.Leq x y (E.Unsigned t) _ =+internaliseBinOp desc E.Leq x y (E.Unsigned t) _ = simpleCmpOp desc (I.CmpUle t) x y-internaliseBinOp _ desc E.Greater x y (E.Signed t) _ =+internaliseBinOp desc E.Greater x y (E.Signed t) _ = simpleCmpOp desc (I.CmpSlt t) y x -- Note the swapped x and y-internaliseBinOp _ desc E.Greater x y (E.Unsigned t) _ =+internaliseBinOp desc E.Greater x y (E.Unsigned t) _ = simpleCmpOp desc (I.CmpUlt t) y x -- Note the swapped x and y-internaliseBinOp _ desc E.Geq x y (E.Signed t) _ =+internaliseBinOp desc E.Geq x y (E.Signed t) _ = simpleCmpOp desc (I.CmpSle t) y x -- Note the swapped x and y-internaliseBinOp _ desc E.Geq x y (E.Unsigned t) _ =+internaliseBinOp desc E.Geq x y (E.Unsigned t) _ = simpleCmpOp desc (I.CmpUle t) y x -- Note the swapped x and y-internaliseBinOp _ desc E.Less x y (E.FloatType t) _ =+internaliseBinOp desc E.Less x y (E.FloatType t) _ = simpleCmpOp desc (I.FCmpLt t) x y-internaliseBinOp _ desc E.Leq x y (E.FloatType t) _ =+internaliseBinOp desc E.Leq x y (E.FloatType t) _ = simpleCmpOp desc (I.FCmpLe t) x y-internaliseBinOp _ desc E.Greater x y (E.FloatType t) _ =+internaliseBinOp desc E.Greater x y (E.FloatType t) _ = simpleCmpOp desc (I.FCmpLt t) y x -- Note the swapped x and y-internaliseBinOp _ desc E.Geq x y (E.FloatType t) _ =+internaliseBinOp desc E.Geq x y (E.FloatType t) _ = simpleCmpOp desc (I.FCmpLe t) y x -- Note the swapped x and y -- Relational operators for booleans.-internaliseBinOp _ desc E.Less x y E.Bool _ =+internaliseBinOp desc E.Less x y E.Bool _ = simpleCmpOp desc I.CmpLlt x y-internaliseBinOp _ desc E.Leq x y E.Bool _ =+internaliseBinOp desc E.Leq x y E.Bool _ = simpleCmpOp desc I.CmpLle x y-internaliseBinOp _ desc E.Greater x y E.Bool _ =+internaliseBinOp desc E.Greater x y E.Bool _ = simpleCmpOp desc I.CmpLlt y x -- Note the swapped x and y-internaliseBinOp _ desc E.Geq x y E.Bool _ =+internaliseBinOp desc E.Geq x y E.Bool _ = simpleCmpOp desc I.CmpLle y x -- Note the swapped x and y-internaliseBinOp _ _ op _ _ t1 t2 =+internaliseBinOp _ op _ _ t1 t2 = error $ "Invalid binary operator " ++ prettyString op@@ -1553,7 +1542,6 @@ mkLambda params $ ensureResultShape (ErrorMsg [ErrorString "unexpected lambda result size"])- (srclocOf lam) rettype =<< bodyBind body @@ -1561,9 +1549,8 @@ isOverloadedFunction :: E.QualName VName -> String ->- SrcLoc -> Maybe ([(E.StructType, [SubExp])] -> InternaliseM [SubExp])-isOverloadedFunction qname desc loc = do+isOverloadedFunction qname desc = do guard $ baseTag (qualLeaf qname) <= maxIntrinsicTag handle $ baseString $ qualLeaf qname where@@ -1625,7 +1612,7 @@ Just $ \[(x_t, [x']), (y_t, [y'])] -> case (x_t, y_t) of (E.Scalar (E.Prim t1), E.Scalar (E.Prim t2)) ->- internaliseBinOp loc desc bop x' y' t1 t2+ internaliseBinOp desc bop x' y' t1 t2 _ -> error "Futhark.Internalise.internaliseExp: non-primitive type in BinOp." handle _ = Nothing @@ -1635,9 +1622,8 @@ isIntrinsicFunction :: E.QualName VName -> [E.Exp] ->- SrcLoc -> Maybe (String -> InternaliseM [SubExp])-isIntrinsicFunction qname args loc = do+isIntrinsicFunction qname args = do guard $ baseTag (qualLeaf qname) <= maxIntrinsicTag let handlers = [ handleSign,@@ -1695,28 +1681,28 @@ fromInt32 (IntLit k' (Info (E.Scalar (E.Prim (E.Signed Int32)))) _) = Just $ fromInteger k' fromInt32 _ = Nothing handleSOACs [lam, ne, arr] "reduce" = Just $ \desc ->- internaliseScanOrReduce desc "reduce" reduce (lam, ne, arr, loc)+ internaliseScanOrReduce desc "reduce" reduce (lam, ne, arr) where reduce w red_lam nes arrs = I.Screma w arrs <$> I.reduceSOAC [Reduce Noncommutative red_lam nes] handleSOACs [lam, ne, arr] "reduce_comm" = Just $ \desc ->- internaliseScanOrReduce desc "reduce" reduce (lam, ne, arr, loc)+ internaliseScanOrReduce desc "reduce" reduce (lam, ne, arr) where reduce w red_lam nes arrs = I.Screma w arrs <$> I.reduceSOAC [Reduce Commutative red_lam nes] handleSOACs [lam, ne, arr] "scan" = Just $ \desc ->- internaliseScanOrReduce desc "scan" reduce (lam, ne, arr, loc)+ internaliseScanOrReduce desc "scan" reduce (lam, ne, arr) where reduce w scan_lam nes arrs = I.Screma w arrs <$> I.scanSOAC [Scan scan_lam nes] handleSOACs [rf, dest, op, ne, buckets, img] "hist_1d" = Just $ \desc ->- internaliseHist 1 desc rf dest op ne buckets img loc+ internaliseHist 1 desc rf dest op ne buckets img handleSOACs [rf, dest, op, ne, buckets, img] "hist_2d" = Just $ \desc ->- internaliseHist 2 desc rf dest op ne buckets img loc+ internaliseHist 2 desc rf dest op ne buckets img handleSOACs [rf, dest, op, ne, buckets, img] "hist_3d" = Just $ \desc ->- internaliseHist 3 desc rf dest op ne buckets img loc+ internaliseHist 3 desc rf dest op ne buckets img handleSOACs _ _ = Nothing handleAccs [dest, f, bs] "scatter_stream" = Just $ \desc ->@@ -1761,20 +1747,16 @@ .&&. pe64 m' .>=. 0 dim_ok_cert <-- assert- "dim_ok_cert"- dim_ok- ( ErrorMsg- [ "Cannot unflatten array of shape [",- ErrorVal int64 old_dim,- "] to array of shape [",- ErrorVal int64 n',- "][",- ErrorVal int64 m',- "]"- ]- )- loc+ assert "dim_ok_cert" dim_ok $+ ErrorMsg+ [ "Cannot unflatten array of shape [",+ ErrorVal int64 old_dim,+ "] to array of shape [",+ ErrorVal int64 n',+ "][",+ ErrorVal int64 m',+ "]"+ ] certifying dim_ok_cert $ forM arrs $ \arr' -> do arr_t <- lookupType arr'@@ -1831,17 +1813,17 @@ mapM (letSubExp desc . BasicOp . Replicate mempty . I.Var) =<< internaliseExpToVars desc x handleRest [arr, offset, n1, s1, n2, s2] "flat_index_2d" = Just $ \desc -> do- flatIndexHelper desc loc arr offset [(n1, s1), (n2, s2)]+ flatIndexHelper desc arr offset [(n1, s1), (n2, s2)] handleRest [arr1, offset, s1, s2, arr2] "flat_update_2d" = Just $ \desc -> do- flatUpdateHelper desc loc arr1 offset [s1, s2] arr2+ flatUpdateHelper desc arr1 offset [s1, s2] arr2 handleRest [arr, offset, n1, s1, n2, s2, n3, s3] "flat_index_3d" = Just $ \desc -> do- flatIndexHelper desc loc arr offset [(n1, s1), (n2, s2), (n3, s3)]+ flatIndexHelper desc arr offset [(n1, s1), (n2, s2), (n3, s3)] handleRest [arr1, offset, s1, s2, s3, arr2] "flat_update_3d" = Just $ \desc -> do- flatUpdateHelper desc loc arr1 offset [s1, s2, s3] arr2+ flatUpdateHelper desc arr1 offset [s1, s2, s3] arr2 handleRest [arr, offset, n1, s1, n2, s2, n3, s3, n4, s4] "flat_index_4d" = Just $ \desc -> do- flatIndexHelper desc loc arr offset [(n1, s1), (n2, s2), (n3, s3), (n4, s4)]+ flatIndexHelper desc arr offset [(n1, s1), (n2, s2), (n3, s3), (n4, s4)] handleRest [arr1, offset, s1, s2, s3, s4, arr2] "flat_update_4d" = Just $ \desc -> do- flatUpdateHelper desc loc arr1 offset [s1, s2, s3, s4] arr2+ flatUpdateHelper desc arr1 offset [s1, s2, s3, s4] arr2 handleRest _ _ = Nothing toSigned int_to e desc = do@@ -1901,7 +1883,6 @@ "write_cert" cmp "length of index and value array does not match"- loc certifying c $ letExp (baseString sv ++ "_write_sv") $ shapeCoerce (I.shapeDims (reshapeOuter (I.Shape [si_w]) 1 sv_shape)) sv@@ -1924,7 +1905,6 @@ letSubExp "write_res" $ I.BasicOp $ I.SubExp $ I.Var name ensureResultShape "scatter value has wrong size"- loc bodyTypes (subExpsRes results) @@ -1940,8 +1920,8 @@ spec = zip3 sa_ws (repeat 1) sas letTupExp' desc $ I.Op $ I.Scatter si_w sivs spec lam -flatIndexHelper :: String -> SrcLoc -> E.Exp -> E.Exp -> [(E.Exp, E.Exp)] -> InternaliseM [SubExp]-flatIndexHelper desc loc arr offset slices = do+flatIndexHelper :: String -> E.Exp -> E.Exp -> [(E.Exp, E.Exp)] -> InternaliseM [SubExp]+flatIndexHelper desc arr offset slices = do arrs <- internaliseExpToVars "arr" arr offset' <- internaliseExp1 "offset" offset old_dim <- I.arraysSize 0 <$> mapM lookupType arrs@@ -1980,14 +1960,16 @@ offset_inbounds_down [offset_inbounds_up, min_in_bounds, max_in_bounds] - c <- assert "bounds_cert" all_bounds (ErrorMsg [ErrorString $ "Flat slice out of bounds: " <> prettyText old_dim <> " and " <> prettyText slices']) loc+ c <-+ assert "bounds_cert" all_bounds $+ ErrorMsg [ErrorString $ "Flat slice out of bounds: " <> prettyText old_dim <> " and " <> prettyText slices'] let slice = I.FlatSlice offset' $ map (uncurry FlatDimIndex) slices' certifying c $ forM arrs $ \arr' -> letSubExp desc $ I.BasicOp $ I.FlatIndex arr' slice -flatUpdateHelper :: String -> SrcLoc -> E.Exp -> E.Exp -> [E.Exp] -> E.Exp -> InternaliseM [SubExp]-flatUpdateHelper desc loc arr1 offset slices arr2 = do+flatUpdateHelper :: String -> E.Exp -> E.Exp -> [E.Exp] -> E.Exp -> InternaliseM [SubExp]+flatUpdateHelper desc arr1 offset slices arr2 = do arrs1 <- internaliseExpToVars "arr" arr1 offset' <- internaliseExp1 "offset" offset old_dim <- I.arraysSize 0 <$> mapM lookupType arrs1@@ -2028,7 +2010,9 @@ offset_inbounds_down [offset_inbounds_up, min_in_bounds, max_in_bounds] - c <- assert "bounds_cert" all_bounds (ErrorMsg [ErrorString $ "Flat slice out of bounds: " <> prettyText old_dim <> " and " <> prettyText slices']) loc+ c <-+ assert "bounds_cert" all_bounds $+ ErrorMsg [ErrorString $ "Flat slice out of bounds: " <> prettyText old_dim <> " and " <> prettyText slices'] let slice = I.FlatSlice offset' $ map (uncurry FlatDimIndex) slices' certifying c $ forM (zip arrs1 arrs2) $ \(arr1', arr2') ->@@ -2038,9 +2022,8 @@ String -> QualName VName -> [SubExp] ->- SrcLoc -> InternaliseM [SubExp]-funcall desc (QualName _ fname) args loc = do+funcall desc (QualName _ fname) args = do (shapes, value_paramts, fun_params, rettype_fun) <- lookupFunction fname argts <- mapM subExpType args @@ -2051,7 +2034,6 @@ args' <- ensureArgShapes "function arguments of wrong shape"- loc (map I.paramName fun_params) (map I.paramType fun_params) (shapeargs ++ args)@@ -2074,7 +2056,7 @@ safety <- askSafety attrs <- asks envAttrs attributing attrs . letValExp' desc $- I.Apply (internaliseFunName fname) (zip args' diets) ts (safety, loc, mempty)+ I.Apply (internaliseFunName fname) (zip args' diets) ts safety -- Bind existential names defined by an expression, based on the -- concrete values that expression evaluated to. This most@@ -2220,9 +2202,11 @@ (resultBodyM [next_one]) sizeExpForError :: E.Size -> InternaliseM [ErrorMsgPart SubExp]-sizeExpForError e = do- e' <- internaliseExp1 "size" e- pure ["[", ErrorVal int64 e', "]"]+sizeExpForError e+ | e == anySize = pure ["[]"]+ | otherwise = do+ e' <- internaliseExp1 "size" e+ pure ["[", ErrorVal int64 e', "]"] typeExpForError :: E.TypeBase Size u -> InternaliseM [ErrorMsgPart SubExp] typeExpForError (E.Scalar (E.Prim t)) = pure [ErrorString $ prettyText t]
src/Futhark/Internalise/FullNormalise.hs view
@@ -218,7 +218,7 @@ let y = Var (qualName yn) (Info $ toStruct yty) mempty ret' = applySubst (pSubst x y) ret body =- mkApply (Var op ty mempty) [(xext, x), (Nothing, y)] $+ mkApply (Var op ty loc) [(xext, x), (Nothing, y)] $ AppRes (toStruct ret') exts nameExp final $ Lambda [Id yn (Info yty) mempty] body Nothing (Info (RetType dims ret')) loc where@@ -231,7 +231,7 @@ y <- getOrdering False e let x = Var (qualName xn) (Info $ toStruct xty) mempty ret' = applySubst (pSubst x y) ret- body = mkApply (Var op ty mempty) [(Nothing, x), (yext, y)] $ AppRes (toStruct ret') []+ body = mkApply (Var op ty loc) [(Nothing, x), (yext, y)] $ AppRes (toStruct ret') [] nameExp final $ Lambda [Id xn (Info xty) mempty] body Nothing (Info (RetType dims ret')) loc where pSubst x y vn
src/Futhark/Internalise/Lambdas.hs view
@@ -33,7 +33,6 @@ mkLambda params $ ensureResultShape (ErrorMsg [ErrorString "shape of result does not match shape of initial value"])- (srclocOf lam) rettype' =<< bodyBind body
src/Futhark/Internalise/Monad.hs view
@@ -16,6 +16,7 @@ bindFunction, bindConstant, assert,+ locating, -- * Convenient reexports module Futhark.Tools,@@ -49,7 +50,8 @@ { envSubsts :: VarSubsts, envDoBoundsChecks :: Bool, envSafe :: Bool,- envAttrs :: Attrs+ envAttrs :: Attrs,+ envLoc :: Loc } data InternaliseState = InternaliseState@@ -115,7 +117,8 @@ { envSubsts = mempty, envDoBoundsChecks = True, envSafe = safe,- envAttrs = mempty+ envAttrs = mempty,+ envLoc = mempty } newState src = InternaliseState@@ -185,18 +188,16 @@ { stateConstSubsts = M.insert cname substs $ stateConstSubsts s } --- | Construct an 'Assert' statement, but taking attributes into--- account. Always use this function, and never construct 'Assert'--- directly in the internaliser!+-- | Construct an 'Assert' statement, but taking attributes into account. Always+-- use this function, and never construct 'Assert' directly in the internaliser! assert :: String -> SubExp -> ErrorMsg SubExp ->- SrcLoc -> InternaliseM Certs-assert desc se msg loc = assertingOne $ do+assert desc se msg = assertingOne $ do attrs <- asks $ attrsForAssert . envAttrs- attributing attrs $ letExp desc $ BasicOp $ Assert se msg (loc, mempty)+ attributing attrs $ letExp desc $ BasicOp $ Assert se msg -- | Execute the given action if 'envDoBoundsChecks' is true, otherwise -- just return an empty list.@@ -215,3 +216,13 @@ InternaliseM VName -> InternaliseM Certs assertingOne m = asserting $ Certs . pure <$> m++-- | Attach the provided location to all statements produced during execution of+-- this action.+locating :: (Located a) => a -> InternaliseM b -> InternaliseM b+locating a+ | loc == mempty || isBuiltinLoc loc = id+ | otherwise = censorStms $ fmap onStm+ where+ loc = locOf a+ onStm (Let pat aux e) = Let pat (aux {stmAuxLoc = Provenance mempty loc}) e
src/Futhark/LSP/Tool.hs view
@@ -20,7 +20,7 @@ import Futhark.LSP.State (State (..), getStaleContent, getStaleMapping) import Futhark.Util.Loc (Loc (Loc, NoLoc), Pos (Pos)) import Futhark.Util.Pretty (prettyText)-import Language.Futhark.Prop (isBuiltinLoc)+import Language.Futhark.Core (isBuiltinLoc) import Language.Futhark.Query ( AtPos (AtName), BoundTo (..),
src/Futhark/Optimise/ArrayLayout/Layout.hs view
@@ -59,10 +59,10 @@ isInscrutable op@(BinOpExp {}) counter = if counter then -- Calculate stride and offset for loop-counters and thread-IDs- case reduceStrideAndOffset op of- -- Maximum allowable stride, might need tuning.- Just (s, _) -> s > 8- Nothing -> isInscrutableExp op+ case reduceStrideAndOffset op of+ -- Maximum allowable stride, might need tuning.+ Just (s, _) -> s > 8+ Nothing -> isInscrutableExp op else isInscrutableExp op isInscrutable op _ = isInscrutableExp op
src/Futhark/Optimise/ArrayLayout/Transform.hs view
@@ -17,7 +17,7 @@ import Futhark.IR.MC import Futhark.Optimise.ArrayLayout.Layout (Layout, LayoutTable, Permutation) -class (Layout rep, PrimExpAnalysis rep) => Transform rep where+class (Layout rep, ExpDec rep ~ (), PrimExpAnalysis rep) => Transform rep where onOp :: (Monad m) => SOACMapper rep rep m ->@@ -60,7 +60,7 @@ transformSegOpGPU perm_table expmap stm@(Let pat aux _) op = -- Optimization: Only traverse the body of the SegOp if it is -- represented in the layout table- case M.lookup patternName (M.mapKeys vnameFromSegOp perm_table) of+ case M.lookup pat_name (M.mapKeys vnameFromSegOp perm_table) of Nothing -> do addStm stm pure (perm_table, M.fromList [(name, stm) | name <- patNames pat] <> expmap)@@ -69,14 +69,14 @@ identitySegOpMapper { mapOnSegOpBody = case segLevel op of SegBlock {} -> transformSegGroupKernelBody perm_table expmap- _ -> transformSegThreadKernelBody perm_table patternName+ _ -> transformSegThreadKernelBody perm_table (stmAuxLoc aux) pat_name } op' <- mapSegOpM mapper op let stm' = Let pat aux $ Op $ SegOp op' addStm stm' pure (perm_table, M.fromList [(name, stm') | name <- patNames pat] <> expmap) where- patternName = patElemName . head $ patElems pat+ pat_name = patElemName . head $ patElems pat transformSegOpMC :: LayoutTable -> ExpMap MC -> Stm MC -> Maybe (SegOp () MC) -> SegOp () MC -> TransformM MC (LayoutTable, ExpMap MC) transformSegOpMC perm_table expmap (Let pat aux _) maybe_par_segop seqSegOp@@ -84,7 +84,7 @@ | Just par_segop <- maybe_par_segop = -- Optimization: Only traverse the body of the SegOp if it is -- represented in the layout table- case M.lookup patternName (M.mapKeys vnameFromSegOp perm_table) of+ case M.lookup pat_name (M.mapKeys vnameFromSegOp perm_table) of Nothing -> add $ Just par_segop Just _ -> add . Just =<< mapSegOpM mapper par_segop where@@ -94,8 +94,12 @@ let stm' = Let pat aux $ Op $ ParOp maybe_par_segop' seqSegOp' addStm stm' pure (perm_table, M.fromList [(name, stm') | name <- patNames pat] <> expmap)- mapper = identitySegOpMapper {mapOnSegOpBody = transformKernelBody perm_table expmap patternName}- patternName = patElemName . head $ patElems pat+ mapper =+ identitySegOpMapper+ { mapOnSegOpBody =+ transformKernelBody perm_table expmap (stmAuxLoc aux) pat_name+ }+ pat_name = patElemName . head $ patElems pat transformRestOp :: (Transform rep, BuilderOps rep) => LayoutTable -> ExpMap rep -> Stm rep -> TransformM rep (LayoutTable, ExpMap rep) transformRestOp perm_table expmap (Let pat aux e) = do@@ -127,14 +131,15 @@ transformSegThreadKernelBody :: (Transform rep, BuilderOps rep) => LayoutTable ->+ Provenance -> VName -> KernelBody rep -> TransformM rep (KernelBody rep)-transformSegThreadKernelBody perm_table seg_name kbody = do+transformSegThreadKernelBody perm_table p seg_name kbody = do evalStateT ( traverseKernelBodyArrayIndexes seg_name- (ensureTransformedAccess perm_table)+ (ensureTransformedAccess perm_table p) kbody ) mempty@@ -143,15 +148,16 @@ (Transform rep, BuilderOps rep) => LayoutTable -> ExpMap rep ->+ Provenance -> VName -> KernelBody rep -> TransformM rep (KernelBody rep)-transformKernelBody perm_table expmap seg_name (KernelBody b stms res) = do+transformKernelBody perm_table expmap p seg_name (KernelBody b stms res) = do stms' <- transformStms perm_table expmap stms evalStateT ( traverseKernelBodyArrayIndexes seg_name- (ensureTransformedAccess perm_table)+ (ensureTransformedAccess perm_table p) (KernelBody b stms' res) ) mempty@@ -176,14 +182,14 @@ stms' <- stmsFromList <$> mapM onStm (stmsToList stms) pure $ Body bdec stms' bres - onStm (Let pat dec (BasicOp (Index arr is))) =- Let pat dec . oldOrNew <$> coalesce seg_name patternName arr is+ onStm (Let pat aux (BasicOp (Index arr is))) =+ Let pat aux . oldOrNew <$> coalesce seg_name pat_name arr is where oldOrNew Nothing = BasicOp $ Index arr is oldOrNew (Just (arr', is')) = BasicOp $ Index arr' is'- patternName = patElemName . head $ patElems pat+ pat_name = patElemName . head $ patElems pat onStm (Let pat dec e) = Let pat dec <$> mapExpM mapper e @@ -212,8 +218,9 @@ ensureTransformedAccess :: (MonadBuilder m) => LayoutTable ->+ Provenance -> ArrayIndexTransform (StateT Replacements m)-ensureTransformedAccess perm_table seg_name idx_name arr slice = do+ensureTransformedAccess perm_table p seg_name idx_name arr slice = do -- Check if the array has the optimal layout in memory. -- If it does not, replace it with a manifest to allocate -- it with the optimal layout@@ -227,6 +234,8 @@ Just arr' -> pure $ Just (arr', slice) Nothing -> replace perm =<< lift (manifest perm arr) where+ aux = (defAux ()) {stmAuxLoc = p}+ replace perm arr' = do -- Store the fact that we have seen this array + permutation -- so we don't make duplicate manifests@@ -235,7 +244,7 @@ pure $ Just (arr', slice) manifest perm array =- letExp (baseString array ++ "_coalesced") $+ auxing aux . letExp (baseString array ++ "_coalesced") $ BasicOp (Manifest array perm) lookupPermutation :: LayoutTable -> VName -> IndexExprName -> VName -> Maybe Permutation
src/Futhark/Optimise/ArrayShortCircuiting.hs view
@@ -118,14 +118,14 @@ (Mem rep inner, LetDec rep ~ LetDecMem) => Stm rep -> UpdateM (inner rep) (Stm rep)-replaceInStm (Let (Pat elems) (StmAux c a d) e) = do+replaceInStm (Let (Pat elems) (StmAux c a loc d) e) = do elems' <- mapM replaceInPatElem elems e' <- replaceInExp elems' e entries <- asks (M.elems . envCoalesceTab) let c' = case filter (\entry -> (map patElemName elems `L.intersect` M.keys (vartab entry)) /= []) entries of [] -> c entries' -> c <> foldMap certs entries'- pure $ Let (Pat elems') (StmAux c' a d) e'+ pure $ Let (Pat elems') (StmAux c' a loc d) e' where replaceInPatElem :: PatElem LetDecMem -> UpdateM inner (PatElem LetDecMem) replaceInPatElem p@(PatElem vname (MemArray _ _ u _)) =
src/Futhark/Optimise/ArrayShortCircuiting/ArrayCoalescing.hs view
@@ -252,9 +252,9 @@ Nothing -> acc _ -> acc --- | Short-circuit handler for 'GPUMem' 'Op'.+-- | Short-circuit handler for t'GPUMem' t'Op'. ----- When the 'Op' is a 'SegOp', we handle it accordingly, otherwise we do+-- When the t'Op' is a t'SegOp', we handle it accordingly, otherwise we do -- nothing. shortCircuitGPUMem :: LUTabFun ->@@ -1250,14 +1250,12 @@ info' = info {vartab = M.insert b mem_info vtab} in if safe_4 then -- array creation point, successful coalescing verified!- let (a_acc', s_acc') = markSuccessCoal (a_acc, s_acc) mb info' in ((a_acc', inhb), s_acc') else -- this is an invertible alias case of the kind -- @ let b = alias a @ -- @ let x[i] = b @ -- do not promote, but update the index function- ((M.insert mb info' a_acc, inhb), s_acc) _ -> (failed, s_acc) -- fail! @@ -1674,7 +1672,6 @@ } in M.insert m_r etry' activeCoals_tab else -- make them both optimistically depend on each other- let opts_x_new = M.insert r m_r (optdeps etry) -- Here we should translate the @ind_b@ field of @mem_info@ -- across the existential introduced by the if-then-else
src/Futhark/Optimise/ArrayShortCircuiting/TopdownAnalysis.hs view
@@ -180,7 +180,7 @@ nonNegatives = nonNegatives env <> innerNonNegatives (patNames pat) inner, knownLessThan = knownLessThan env <> innerKnownLessThan inner }-updateTopdownEnv env stm@(Let (Pat _) _ (BasicOp (Assert se _ _))) =+updateTopdownEnv env stm@(Let (Pat _) _ (BasicOp (Assert se _))) = env { scope = scope env <> scopeOf stm, td_asserts = se : td_asserts env
src/Futhark/Optimise/BlkRegTiling.hs view
@@ -136,7 +136,6 @@ -- if i and j are out of range than css[i,j] -- is garbage anyways and should not be written. -- so fits_ij should be always true!!!- (le64 iii + le64 i + pe64 ry * le64 ltid_y .<. pe64 height_A) .&&. (le64 jjj + le64 j + pe64 rx * le64 ltid_x .<. pe64 width_B) )
src/Futhark/Optimise/CSE.hs view
@@ -196,41 +196,34 @@ | patElemName pe `nameIn` consumed = Consume | otherwise = Observe --- A small amount of normalisation of expressions that otherwise would--- be different for pointless reasons.-normExp :: Exp lore -> Exp lore-normExp (Apply fname args ret (safety, _, _)) =- Apply fname args ret (safety, mempty, mempty)-normExp e = e- cseInStm :: (ASTRep rep) => Names -> Stm rep -> ([Stm rep] -> CSEM rep a) -> CSEM rep a-cseInStm consumed (Let pat (StmAux cs attrs edec) e) m = do+cseInStm consumed (Let pat aux e) m = do CSEState (esubsts, nsubsts) cse_arrays <- ask- let e' = normExp $ substituteNames nsubsts e+ let e' = substituteNames nsubsts e pat' = substituteNames nsubsts pat if not (alreadyAliases e) && any (bad cse_arrays) (patElems pat)- then m [Let pat' (StmAux cs attrs edec) e']- else case M.lookup (edec, e') esubsts of+ then m [Let pat' aux e']+ else case M.lookup (stmAuxDec aux, e') esubsts of Just (subcs, subpat) -> do- let subsumes = all (`elem` unCerts subcs) (unCerts cs)+ let subsumes = all (`elem` unCerts subcs) (unCerts (stmAuxCerts aux)) -- We can only do a plain name substitution if it doesn't -- violate any certificate dependencies. local (if subsumes then addNameSubst pat' subpat else id) $ do let lets =- [ Let (Pat [patElem']) (StmAux cs attrs edec) $+ [ Let (Pat [patElem']) aux $ BasicOp (SubExp $ Var $ patElemName patElem) | (name, patElem) <- zip (patNames pat') $ patElems subpat, let patElem' = patElem {patElemName = name} ] m lets _ ->- local (addExpSubst pat' edec cs e') $- m [Let pat' (StmAux cs attrs edec) e']+ local (addExpSubst pat' (stmAuxDec aux) (stmAuxCerts aux) e') $+ m [Let pat' aux e'] where alreadyAliases (BasicOp Index {}) = True alreadyAliases (BasicOp Reshape {}) = True
src/Futhark/Optimise/Fusion.hs view
@@ -350,7 +350,6 @@ pat1_acc_nms <- namesFromList $ take n $ map patElemName $ patElems pat1, -- not $ namesIntersect (freeIn soac) pat1_acc_nms all ((`notNameIn` pat1_acc_nms) . getName) edges = do- let empty_aux = StmAux mempty mempty mempty wlam <- fst <$> doFusionInLambda wlam0 bdy' <- runBodyBuilder $ inScopeOf wlam $ do@@ -360,7 +359,7 @@ let other_pr1 = drop n $ zip (patElems pat1) wlam_res forM_ other_pr1 $ \(pat_elm, bdy_res) -> do let (nm, se, tp) = (patElemName pat_elm, resSubExp bdy_res, patElemType pat_elm)- aux = empty_aux {stmAuxCerts = resCerts bdy_res}+ aux = (defAux ()) {stmAuxCerts = resCerts bdy_res} addStm $ Let (Pat [PatElem nm tp]) aux $ BasicOp $ SubExp se -- add the soac stmt soac' <- H.toExp soac@@ -552,16 +551,26 @@ lam' <- fst <$> doFusionInLambda lam pure (incoming, node, StmNode (Let pat aux (WithAcc inputs lam')), outgoing) SoacNode ots pat soac aux -> do- let lam = H.lambda soac- lam' <- inScopeOf lam $ case soac of- H.Stream {} ->- dontFuseScans $ fst <$> doFusionInLambda lam+ soac' <- case soac of+ H.Stream w inputs accs lam ->+ H.Stream w inputs accs <$> dontFuseScans (onLambda lam)+ H.Screma w inputs (ScremaForm lam scans reds) ->+ H.Screma w inputs+ <$> ( ScremaForm+ <$> doFuseScans (onLambda lam)+ <*> mapM onScan scans+ <*> mapM onRed reds+ ) _ ->- doFuseScans $ fst <$> doFusionInLambda lam- let nodeT' = SoacNode ots pat (H.setLambda lam' soac) aux+ H.setLambda <$> doFuseScans (onLambda (H.lambda soac)) <*> pure soac+ let nodeT' = SoacNode ots pat soac' aux pure (incoming, node, nodeT', outgoing) _ -> pure c where+ onLambda lam = inScopeOf lam . fmap fst $ doFusionInLambda lam+ onScan (Scan lam nes) = Scan <$> onLambda lam <*> pure nes+ onRed (Reduce comm lam nes) = Reduce comm <$> onLambda lam <*> pure nes+ doFusionWithDelayed :: Body SOACS -> [(NodeT, [EdgeT])] -> FusionM (Body SOACS) doFusionWithDelayed (Body () stms res) extraNodes = inScopeOf stms $ do stm_node <- mapM (finalizeNode . fst) extraNodes
src/Futhark/Optimise/Fusion/TryFusion.hs view
@@ -408,6 +408,10 @@ fail "Cannot fuse a scatter with anything else than a scatter or a map" (_, SOAC.Scatter {}, _) -> fail "Cannot fuse a scatter with anything else than a scatter or a map"+ (_, SOAC.Hist {}, _) ->+ fail "Cannot fuse a Hist with anything else than a Hist or a Map"+ (SOAC.Hist {}, _, _) ->+ fail "Cannot fuse a Hist with anything else than a Hist or a Map" ---------------------------- -- Stream-Stream Fusions: -- ----------------------------
src/Futhark/Optimise/InliningDeadFun.hs view
@@ -220,10 +220,11 @@ Pat Type -> StmAux dec -> [(SubExp, Diet)] ->- (Safety, SrcLoc, [SrcLoc]) ->+ Safety ->+ Provenance -> FunDef SOACS -> m (Stms SOACS)-inlineFunction pat aux args (safety, loc, locs) fun = do+inlineFunction pat aux args safety p fun = do Body _ stms res <- renameBody $ mkBody (param_stms <> body_stms) (bodyResult (funDefBody fun)) pure $ stms <> stmsFromList (zipWith bindSubExpRes (patIdents pat) res)@@ -234,9 +235,7 @@ <$> zipWith bindSubExp (map paramIdent $ funDefParams fun) (map fst args) body_stms =- addLocations (stmAuxAttrs aux) safety (filter notmempty (loc : locs)) $- bodyStms $- funDefBody fun+ addLocations (stmAuxAttrs aux) safety p $ bodyStms $ funDefBody fun -- Note that the sizes of arrays may not be correct at this -- point - it is crucial that we run copy propagation before@@ -247,8 +246,6 @@ bindSubExpRes ident (SubExpRes cs se) = certify cs $ bindSubExp ident se - notmempty = (/= mempty) . locOf- inlineInStms :: (MonadFreshNames m) => M.Map Name (FunDef SOACS) ->@@ -264,11 +261,11 @@ m (Body SOACS) inlineInBody fdmap = onBody where- inline (Let pat aux (Apply fname args _ what) : rest)+ inline (Let pat aux (Apply fname args _ safety) : rest) | Just fd <- M.lookup fname fdmap, not $ "noinline" `inAttrs` funDefAttrs fd, not $ "noinline" `inAttrs` stmAuxAttrs aux =- (<>) <$> inlineFunction pat aux args what fd <*> inline rest+ (<>) <$> inlineFunction pat aux args safety (stmAuxLoc aux) fd <*> inline rest inline (stm@(Let _ _ BasicOp {}) : rest) = (oneStm stm <>) <$> inline rest inline (stm : rest) =@@ -292,39 +289,43 @@ onLambda (Lambda params ret body) = Lambda params ret <$> onBody body --- Propagate source locations and attributes to the inlined--- statements. Attributes are propagated only when applicable (this--- probably means that every supported attribute needs to be handled--- specially here).-addLocations :: Attrs -> Safety -> [SrcLoc] -> Stms SOACS -> Stms SOACS-addLocations attrs caller_safety more_locs = fmap onStm+traceLocs :: Provenance -> StmAux () -> StmAux ()+traceLocs p aux =+ aux {stmAuxLoc = stackProvenance p $ stmAuxLoc aux}++-- Propagate source locations and attributes to the inlined statements.+-- Attributes are propagated only when applicable (this probably means that+-- every supported attribute needs to be handled specially here).+addLocations :: Attrs -> Safety -> Provenance -> Stms SOACS -> Stms SOACS+addLocations attrs caller_safety p = fmap onStm where- onStm (Let pat aux (Apply fname args t (safety, loc, locs))) =+ onStm (Let pat aux (BasicOp (Assert cond desc))) = Let pat aux' $- Apply fname args t (min caller_safety safety, loc, locs ++ more_locs)- where- aux' = aux {stmAuxAttrs = attrs <> stmAuxAttrs aux}- onStm (Let pat aux (BasicOp (Assert cond desc (loc, locs)))) =- Let pat (withAttrs (attrsForAssert attrs) aux) $ case caller_safety of- Safe -> BasicOp $ Assert cond desc (loc, locs ++ more_locs)+ Safe -> BasicOp $ Assert cond desc Unsafe -> BasicOp $ SubExp $ Constant UnitValue+ where+ aux' = traceLocs p (withAttrs (attrsForAssert attrs) aux)+ onStm (Let pat aux (Apply fname args t safety)) =+ Let pat aux' $ Apply fname args t $ min caller_safety safety+ where+ aux' = traceLocs p $ aux {stmAuxAttrs = attrs <> stmAuxAttrs aux} onStm (Let pat aux (Op soac)) =- Let pat (withAttrs attrs' aux) $- Op $- runIdentity $- mapSOACM- identitySOACMapper- { mapOnSOACLambda = pure . onLambda- }- soac+ Let pat aux' . Op $+ runIdentity $+ mapSOACM+ identitySOACMapper+ { mapOnSOACLambda = pure . onLambda+ }+ soac where+ aux' = traceLocs p $ withAttrs attrs' aux attrs' = attrs `withoutAttrs` for_assert for_assert = attrsForAssert attrs onLambda lam = lam {lambdaBody = onBody for_assert $ lambdaBody lam} onStm (Let pat aux e) =- Let pat aux $ onExp e+ Let pat (traceLocs p aux) $ onExp e onExp = mapExp@@ -336,9 +337,7 @@ onBody attrs' body = body- { bodyStms =- addLocations attrs' caller_safety more_locs $- bodyStms body+ { bodyStms = addLocations attrs' caller_safety p $ bodyStms body } -- | Remove functions not ultimately called from an entry point or a
src/Futhark/Optimise/MergeGPUBodies.hs view
@@ -111,10 +111,10 @@ -- This creates sequences of GPUBody statements that can be merged into single -- kernels. reorderStm :: AliasTable -> Stm (Aliases GPU) -> ReorderM AliasTable-reorderStm aliases (Let pat (StmAux cs attrs _) e) = do+reorderStm aliases (Let pat (StmAux cs attrs loc _) e) = do (e', deps) <- lift (transformExp aliases e) let pat' = removePatAliases pat- let stm' = Let pat' (StmAux cs attrs ()) e'+ let stm' = Let pat' (StmAux cs attrs loc ()) e' let pes' = patElems pat' -- Array aliases can be seen as a directed graph where vertices are arrays@@ -489,19 +489,19 @@ | otherwise = SQ.singleton <$> foldrM merge empty stms where- empty = Let mempty (StmAux mempty mempty ()) noop+ empty = Let mempty (defAux ()) noop noop = Op (GPUBody [] (Body () SQ.empty [])) merge :: Stm GPU -> Stm GPU -> ReorderM (Stm GPU) merge stm0 stm1- | Let pat0 (StmAux cs0 attrs0 _) (Op (GPUBody types0 body)) <- stm0,- Let pat1 (StmAux cs1 attrs1 _) (Op (GPUBody types1 body1)) <- stm1 =+ | Let pat0 (StmAux cs0 attrs0 _ _) (Op (GPUBody types0 body)) <- stm0,+ Let pat1 (StmAux cs1 attrs1 _ _) (Op (GPUBody types1 body1)) <- stm1 = do Body _ stms0 res0 <- execRewrite (rewriteBody body) let Body _ stms1 res1 = body1 pat' = pat0 <> pat1- aux' = StmAux (cs0 <> cs1) (attrs0 <> attrs1) ()+ aux' = StmAux (cs0 <> cs1) (attrs0 <> attrs1) mempty () types' = types0 ++ types1 body' = Body () (stms0 <> stms1) (res0 <> res1) in pure (Let pat' aux' (Op (GPUBody types' body')))@@ -530,11 +530,11 @@ rewriteStms = mapM rewriteStm rewriteStm :: Stm GPU -> RewriteM (Stm GPU)-rewriteStm (Let (Pat pes) (StmAux cs attrs _) e) = do+rewriteStm (Let (Pat pes) (StmAux cs attrs loc _) e) = do pat' <- Pat <$> mapM rewritePatElem pes cs' <- rewriteCerts cs e' <- rewriteExp e- pure $ Let pat' (StmAux cs' attrs ()) e'+ pure $ Let pat' (StmAux cs' attrs loc ()) e' rewritePatElem :: PatElem Type -> RewriteM (PatElem Type) rewritePatElem (PatElem n t) =@@ -616,10 +616,9 @@ let t = row_t `arrayOfRow` intConst Int64 1 let pat = Pat [PatElem name t]- let aux = StmAux mempty mempty () let e = BasicOp (ArrayLit [se] row_t) - modify (|> Let pat aux e)+ modify (|> Let pat (defAux ()) e) pure name -- | @referConst c@ adds @let x = c@ to the rewrite prologue and returns the@@ -630,10 +629,9 @@ let t = Prim (primValueType c) let pat = Pat [PatElem name t]- let aux = StmAux mempty mempty () let e = BasicOp (SubExp $ Constant c) - modify (|> Let pat aux e)+ modify (|> Let pat (defAux ()) e) pure name -- | Produce a fresh name, using the given string as a template.
src/Futhark/Optimise/ReduceDeviceSyncs.hs view
@@ -136,11 +136,10 @@ let e' = BasicOp $ Replicate (Shape dims) (Var v') let repl = Let pat' (stmAux stm) e' - let aux = StmAux mempty mempty () let slice = map sliceDim (arrayDims arr_t) let slice' = slice ++ [DimFix $ intConst Int64 0] let idx = BasicOp $ Index n' (Slice slice')- let index = Let (stmPat stm) aux idx+ let index = Let (stmPat stm) (defAux ()) idx pure (out |> repl |> index) BasicOp {} ->@@ -479,7 +478,7 @@ -- | A shorthand for binding a single variable to an expression. bind :: PatElem Type -> Exp GPU -> Stm GPU-bind pe = Let (Pat [pe]) (StmAux mempty mempty ())+bind pe = Let (Pat [pe]) (defAux ()) -- | Returns the array alias of @se@ if it is a variable that has been migrated -- to device. Otherwise returns @Nothing@.@@ -606,7 +605,7 @@ let pes = patElems (stmPat stm) pat <- Pat <$> mapM arrayizePatElem pes- let aux = StmAux mempty mempty ()+ let aux = defAux () let types = map patElemType pes let res = map (SubExpRes mempty . Var . patElemName) pes let body = Body () (prologue |> stm) res@@ -711,9 +710,9 @@ bnd :: Stms GPU -> (PatElem Type, SubExpRes) -> Stms GPU bnd out (pe, SubExpRes cs se) | Just t' <- peelArray 1 (typeOf pe) =- out |> Let (Pat [pe]) (StmAux cs mempty ()) (BasicOp $ ArrayLit [se] t')+ out |> Let (Pat [pe]) (StmAux cs mempty mempty ()) (BasicOp $ ArrayLit [se] t') | otherwise =- out |> Let (Pat [pe]) (StmAux cs mempty ()) (BasicOp $ SubExp se)+ out |> Let (Pat [pe]) (StmAux cs mempty mempty ()) (BasicOp $ SubExp se) -- | Rewrite all bindings introduced by a single statement (to ensure they are -- unique) and fix any dependencies that are broken as a result of migration or@@ -745,9 +744,9 @@ -- | Fix any 'StmAux' certificate references that are broken as a result of -- migration or rewriting. rewriteStmAux :: StmAux () -> RewriteM (StmAux ())-rewriteStmAux (StmAux certs attrs _) = do- certs' <- renameCerts certs- pure (StmAux certs' attrs ())+rewriteStmAux aux = do+ certs' <- renameCerts $ stmAuxCerts aux+ pure $ aux {stmAuxCerts = certs'} -- | Rewrite the bindings introduced by an expression (to ensure they are -- unique) and fix any dependencies that are broken as a result of migration or
src/Futhark/Optimise/Simplify/Engine.hs view
@@ -296,10 +296,10 @@ auxing aux . letBind pat $ Match [cond'] [Case [Just (BoolValue True)] taken_body] untaken_body $ MatchDec if_ts MatchFallback-protectIf _ _ taken (Let pat aux (BasicOp (Assert cond msg loc))) = do+protectIf _ _ taken (Let pat aux (BasicOp (Assert cond msg))) = do not_taken <- letSubExp "loop_not_taken" $ BasicOp $ UnOp (Neg Bool) taken cond' <- letSubExp "protect_assert_disj" $ BasicOp $ BinOp LogOr not_taken cond- auxing aux $ letBind pat $ BasicOp $ Assert cond' msg loc+ auxing aux $ letBind pat $ BasicOp $ Assert cond' msg protectIf protect _ taken (Let pat aux (Op op)) | Just m <- protect taken pat op = auxing aux m@@ -423,11 +423,11 @@ (SimplifiableRep rep) => Stm (Wise rep) -> SimpleM rep (Stm (Wise rep))-nonrecSimplifyStm (Let pat (StmAux cs attrs (_, dec)) e) = do+nonrecSimplifyStm (Let pat (StmAux cs attrs loc (_, dec)) e) = do cs' <- simplify cs e' <- simplifyExpBase e (pat', pat_cs) <- collectCerts $ traverse simplify $ removePatWisdom pat- let aux' = StmAux (cs' <> pat_cs) attrs dec+ let aux' = StmAux (cs' <> pat_cs) attrs loc dec pure $ mkWiseStm pat' aux' e' -- Bottom-up simplify a statement. Recurses into sub-Bodies and Ops.@@ -439,9 +439,9 @@ Stm (Wise rep) -> UT.UsageTable -> SimpleM rep (Stms (Wise rep), Stm (Wise rep))-recSimplifyStm (Let pat (StmAux cs attrs (_, dec)) e) usage = do+recSimplifyStm (Let pat (StmAux cs attrs loc (_, dec)) e) usage = do ((e', e_hoisted), e_cs) <- collectCerts $ simplifyExp (usage <> UT.usageInPat pat) pat e- let aux' = StmAux (cs <> e_cs) attrs dec+ let aux' = StmAux (cs <> e_cs) attrs loc dec pure (e_hoisted, mkWiseStm (removePatWisdom pat) aux' e') hoistStms ::
src/Futhark/Optimise/Simplify/Rep.hs view
@@ -252,9 +252,9 @@ StmAux (ExpDec rep) -> Exp (Wise rep) -> Stm (Wise rep)-mkWiseStm pat (StmAux cs attrs dec) e =+mkWiseStm pat aux e = let pat' = addWisdomToPat pat e- in Let pat' (StmAux cs attrs $ mkWiseExpDec pat' dec e) e+ in Let pat' (flip (mkWiseExpDec pat') e <$> aux) e -- | Produce simplifier information for an expression. mkWiseExpDec ::
src/Futhark/Optimise/Simplify/Rules.hs view
@@ -95,17 +95,12 @@ removeUnnecessaryCopy _ _ _ _ = Skip constantFoldPrimFun :: (BuilderOps rep) => TopDownRuleGeneric rep-constantFoldPrimFun _ (Let pat (StmAux cs attrs _) (Apply fname args _ _))+constantFoldPrimFun _ (Let pat aux (Apply fname args _ _)) | Just args' <- mapM (isConst . fst) args, Just (_, _, fun) <- M.lookup (nameToText fname) primFuns, Just result <- fun args' =- Simplify $- certifying cs $- attributing attrs $- letBind pat $- BasicOp $- SubExp $- Constant result+ Simplify . auxing aux . letBind pat $+ BasicOp (SubExp $ Constant result) where isConst (Constant v) = Just v isConst _ = Nothing@@ -124,11 +119,11 @@ emptyArrayToScratch _ _ = Skip simplifyIndex :: (BuilderOps rep) => BottomUpRuleBasicOp rep-simplifyIndex (vtable, used) pat@(Pat [pe]) (StmAux cs attrs _) (Index idd inds)+simplifyIndex (vtable, used) pat@(Pat [pe]) aux (Index idd inds) | Just m <- simplifyIndexing vtable seType idd inds consumed consuming =- Simplify $ certifying cs $ do+ Simplify $ certifying (stmAuxCerts aux) $ do res <- m- attributing attrs $ case res of+ attributing (stmAuxAttrs aux) $ case res of SubExpResult cs' se -> certifying cs' $ letBindNames (patNames pat) $ BasicOp $ SubExp se IndexResult extra_cs idd' inds' ->
src/Futhark/Optimise/Simplify/Rules/BasicOp.hs view
@@ -102,14 +102,12 @@ -- Still need a copy because Concat produces a fresh array. Simplify $ auxing aux $ letBind pat $ BasicOp $ Replicate mempty $ Var x -- concat xs (concat ys zs) == concat xs ys zs-simplifyConcat (vtable, _) pat (StmAux cs attrs _) (Concat i (x :| xs) new_d)+simplifyConcat (vtable, _) pat aux (Concat i (x :| xs) new_d) | x' /= x || concat xs' /= xs =- Simplify $- certifying (cs <> x_cs <> mconcat xs_cs) $- attributing attrs $- letBind pat $- BasicOp $- Concat i (x' :| zs ++ concat xs') new_d+ Simplify . auxing aux . certifying (x_cs <> mconcat xs_cs) $+ letBind pat $+ BasicOp $+ Concat i (x' :| zs ++ concat xs') new_d where (x' : zs, x_cs) = isConcat x (xs', xs_cs) = unzip $ map isConcat xs@@ -198,16 +196,16 @@ reshapeAll (arrayShape v_t) (arrayShape dest_t) letBind pat $ BasicOp $ Replicate mempty v_reshaped _ -> letBind pat $ BasicOp $ ArrayLit [se] $ rowType dest_t-ruleBasicOp vtable pat (StmAux cs1 attrs _) (Update safety1 dest1 is1 (Var v1))+ruleBasicOp vtable pat aux (Update safety1 dest1 is1 (Var v1)) | Just (Update safety2 dest2 is2 se2, cs2) <- ST.lookupBasicOp v1 vtable, Just (Replicate (Shape []) (Var v3), cs3) <- ST.lookupBasicOp dest2 vtable, Just (Index v4 is4, cs4) <- ST.lookupBasicOp v3 vtable, is4 == is1, v4 == dest1 =- Simplify $- certifying (cs1 <> cs2 <> cs3 <> cs4) $ do+ Simplify . auxing aux $+ certifying (cs2 <> cs3 <> cs4) $ do is5 <- subExpSlice $ sliceSlice (primExpSlice is1) (primExpSlice is2)- attributing attrs $ letBind pat $ BasicOp $ Update (max safety1 safety2) dest1 is5 se2+ letBind pat $ BasicOp $ Update (max safety1 safety2) dest1 is5 se2 ruleBasicOp vtable pat _ (CmpOp (CmpEq t) se1 se2) | Just m <- simplifyWith se1 se2 = Simplify m | Just m <- simplifyWith se2 se1 = Simplify m
src/Futhark/Optimise/Simplify/Rules/Match.hs view
@@ -40,9 +40,9 @@ new_default : _ <- reverse always_matches = Simplify $ letBind pat $ Match cond cases' (caseBody new_default) ifdec -- Remove caseless match.-ruleMatch _ pat (StmAux cs _ _) (_, [], defbody, _) = Simplify $ do+ruleMatch _ pat aux (_, [], defbody, _) = Simplify $ do defbody_res <- bodyBind defbody- certifying cs $ forM_ (zip (patElems pat) defbody_res) $ \(pe, res) ->+ certifying (stmAuxCerts aux) $ forM_ (zip (patElems pat) defbody_res) $ \(pe, res) -> certifying (resCerts res) . letBind (Pat [pe]) $ BasicOp (SubExp $ resSubExp res) -- IMPROVE: the following two rules can be generalised to work in more
src/Futhark/Optimise/Simplify/Rules/Simple.hs view
@@ -263,7 +263,7 @@ -- If expression is true then just replace assertion. simplifyAssert :: SimpleRule rep-simplifyAssert _ _ (Assert (Constant (BoolValue True)) _ _) =+simplifyAssert _ _ (Assert (Constant (BoolValue True)) _) = constRes UnitValue simplifyAssert _ _ _ = Nothing
src/Futhark/Pass/ExplicitAllocations.hs view
@@ -615,8 +615,11 @@ allocInFunBody (map (const $ Just space) rettype) fbody let num_extra_params = length params' - length params num_extra_rets = length mem_rets+ -- The mem_pals is an over-approximation, like in the case for Apply.+ mem_pals = map fst $ filter (isMem . paramType . snd) $ zip [0 ..] params'+ mem_als = RetAls mem_pals mempty rettype' =- map (,RetAls mempty mempty) mem_rets+ map (,mem_als) mem_rets ++ zip (memoryInDeclExtType space (length mem_rets) (map fst rettype)) (map (shiftRetAls num_extra_params num_extra_rets . snd) rettype)@@ -915,16 +918,20 @@ allocInExp (Apply fname args rettype loc) = do args' <- funcallArgs args space <- askDefaultSpace- -- We assume that every array is going to be in its own memory.- let num_extra_args = length args' - length args+ args_ts <- mapM (subExpType . fst) args'+ -- We assume that every array is going to be in its own memory. Further, we+ -- assume that every result memory block can alias any argument memory block.+ -- This is an overapproximation that can be loosened in the future.+ let mem_als = RetAls (map fst $ filter (isMem . snd) $ zip [0 ..] args_ts) mempty+ mems = replicate num_arrays (MemMem space, mem_als)+ num_extra_args = length args' - length args rettype' =- mems space+ mems ++ zip (memoryInDeclExtType space num_arrays (map fst rettype)) (map (shiftRetAls num_extra_args num_arrays . snd) rettype) pure $ Apply fname args' rettype' loc where- mems space = replicate num_arrays (MemMem space, RetAls mempty mempty) num_arrays = length $ filter ((> 0) . arrayRank . declExtTypeOf . fst) rettype allocInExp (Match ses cases defbody (MatchDec rets ifsort)) = do (defbody', def_reqs) <- allocInMatchBody rets defbody
src/Futhark/Pass/ExtractKernels.hs view
@@ -392,7 +392,7 @@ transformStm path (Let pat aux (Op (Screma w arrs form))) | Just lam <- isMapSOAC form = onMap path $ MapLoop pat aux w lam arrs-transformStm path (Let pat aux@(StmAux cs _ _) (Op (Screma w arrs form)))+transformStm path (Let pat aux (Op (Screma w arrs form))) | Just scans <- isScanSOAC form, Scan scan_lam nes <- singleScan scans, Just do_iswim <- iswim pat w scan_lam $ zip nes arrs = do@@ -425,6 +425,8 @@ =<< (mkBody <$> paralleliseInner path' <*> pure (varsRes (patNames pat))) versionScanRed path pat aux w map_lam paralleliseOuter outerParallelBody innerParallelBody+ where+ cs = stmAuxCerts aux transformStm path (Let res_pat aux (Op (Screma w arrs form))) | Just [Reduce comm red_fun nes] <- isReduceSOAC form, let comm'@@ -434,7 +436,7 @@ types <- asksScope scopeForSOACs stms <- fst <$> runBuilderT (simplifyStms =<< collectStms_ (auxing aux do_irwim)) types transformStms path $ stmsToList stms-transformStm path (Let pat aux@(StmAux cs _ _) (Op (Screma w arrs form)))+transformStm path (Let pat aux (Op (Screma w arrs form))) | Just (reds, map_lam) <- isRedomapSOAC form = do let paralleliseOuter = runBuilder_ $ do red_ops <- forM reds $ \(Reduce comm red_lam nes) -> do@@ -465,11 +467,13 @@ =<< (mkBody <$> paralleliseInner path' <*> pure (varsRes (patNames pat))) versionScanRed path pat aux w map_lam paralleliseOuter outerParallelBody innerParallelBody-transformStm path (Let pat (StmAux cs _ _) (Op (Screma w arrs form))) = do+ where+ cs = stmAuxCerts aux+transformStm path (Let pat aux (Op (Screma w arrs form))) = do -- This screma is too complicated for us to immediately do -- anything, so split it up and try again. scope <- asksScope scopeForSOACs- transformStms path . map (certify cs) . stmsToList . snd+ transformStms path . map (certify (stmAuxCerts aux)) . stmsToList . snd =<< runBuilderT (dissectScrema pat w form arrs) scope transformStm path (Let pat _ (Op (Stream w arrs nes fold_fun))) = do -- Remove the stream and leave the body parallel. It will be@@ -526,7 +530,7 @@ addStms stms letBind (Pat [res_pe]) $ Op $ SegOp kernel ---transformStm _ (Let pat (StmAux cs _ _) (Op (Scatter w ivs as lam))) = runBuilder_ $ do+transformStm _ (Let pat aux (Op (Scatter w ivs as lam))) = runBuilder_ $ do let lam' = soacsLambdaToGPU lam write_i <- newVName "write_i" let krets = do@@ -547,10 +551,10 @@ inputs (patTypes pat) body- certifying cs $ do+ certifying (stmAuxCerts aux) $ do addStms stms letBind pat $ Op $ SegOp kernel-transformStm _ (Let orig_pat (StmAux cs _ _) (Op (Hist w imgs ops bucket_fun))) = do+transformStm _ (Let orig_pat aux (Op (Hist w imgs ops bucket_fun))) = do let bfun' = soacsLambdaToGPU bucket_fun -- It is important not to launch unnecessarily many threads for@@ -558,7 +562,7 @@ -- subhistograms as well. runBuilder_ $ do lvl <- segThreadCapped [w] "seghist" $ NoRecommendation SegNoVirt- addStms =<< histKernel onLambda lvl orig_pat [] [] cs w ops bfun' imgs+ addStms =<< histKernel onLambda lvl orig_pat [] [] (stmAuxCerts aux) w ops bfun' imgs where onLambda = pure . soacsLambdaToGPU transformStm _ stm =
src/Futhark/Pass/ExtractKernels/DistributeNests.hs view
@@ -334,13 +334,13 @@ distributeMapBodyStms orig_acc = distribute <=< onStms orig_acc . stmsToList where onStms acc [] = pure acc- onStms acc (Let pat (StmAux cs _ _) (Op (Stream w arrs accs lam)) : stms) = do+ onStms acc (Let pat aux (Op (Stream w arrs accs lam)) : stms) = do types <- asksScope scopeForSOACs stream_stms <- snd <$> runBuilderT (sequentialStreamWholeArray pat w accs lam arrs) types stream_stms' <- runReaderT (copyPropagateInStms simpleSOACS types stream_stms) types- onStms acc $ stmsToList (fmap (certify cs) stream_stms') ++ stms+ onStms acc $ stmsToList (fmap (certify (stmAuxCerts aux)) stream_stms') ++ stms onStms acc (stm : stms) = -- It is important that stm is in scope if 'maybeDistributeStm' -- wants to distribute, even if this causes the slightly silly@@ -463,7 +463,7 @@ distributeMapBodyStms acc stms -- Parallelise segmented scatters.-maybeDistributeStm stm@(Let pat (StmAux cs _ _) (Op (Scatter w ivs as lam))) acc =+maybeDistributeStm stm@(Let pat aux (Op (Scatter w ivs as lam))) acc = distributeSingleStm acc stm >>= \case Just (kernels, res, nest, acc') | Just (perm, pat_unused) <- permutationAndMissing pat res ->@@ -471,12 +471,12 @@ nest' <- expandKernelNest pat_unused nest lam' <- soacsLambda lam addPostStms kernels- postStm =<< segmentedScatterKernel nest' perm pat cs w lam' ivs as+ postStm =<< segmentedScatterKernel nest' perm pat (stmAuxCerts aux) w lam' ivs as pure acc' _ -> addStmToAcc stm acc -- Parallelise segmented Hist.-maybeDistributeStm stm@(Let pat (StmAux cs _ _) (Op (Hist w as ops lam))) acc =+maybeDistributeStm stm@(Let pat aux (Op (Hist w as ops lam))) acc = distributeSingleStm acc stm >>= \case Just (kernels, res, nest, acc') | Just (perm, pat_unused) <- permutationAndMissing pat res ->@@ -484,7 +484,7 @@ lam' <- soacsLambda lam nest' <- expandKernelNest pat_unused nest addPostStms kernels- postStm =<< segmentedHistKernel nest' perm cs w ops lam' as+ postStm =<< segmentedHistKernel nest' perm (stmAuxCerts aux) w ops lam' as pure acc' _ -> addStmToAcc stm acc@@ -507,7 +507,7 @@ -- -- If the scan cannot be distributed by itself, it will be -- sequentialised in the default case for this function.-maybeDistributeStm stm@(Let pat (StmAux cs _ _) (Op (Screma w arrs form))) acc+maybeDistributeStm stm@(Let pat aux (Op (Screma w arrs form))) acc | Just (scans, map_lam) <- isScanomapSOAC form, Scan lam nes <- singleScan scans = distributeSingleStm acc stm >>= \case@@ -519,7 +519,7 @@ nest' <- expandKernelNest pat_unused nest map_lam' <- soacsLambda map_lam localScope (typeEnvFromDistAcc acc') $- segmentedScanomapKernel nest' perm cs w lam map_lam' nes arrs+ segmentedScanomapKernel nest' perm (stmAuxCerts aux) w lam map_lam' nes arrs >>= kernelOrNot mempty stm acc kernels acc' _ -> addStmToAcc stm acc@@ -536,7 +536,7 @@ -- -- If the reduction cannot be distributed by itself, it will be -- sequentialised in the default case for this function.-maybeDistributeStm stm@(Let pat (StmAux cs _ _) (Op (Screma w arrs form))) acc+maybeDistributeStm stm@(Let pat aux (Op (Screma w arrs form))) acc | Just (reds, map_lam) <- isRedomapSOAC form, Reduce comm lam nes <- singleReduce reds = distributeSingleStm acc stm >>= \case@@ -554,15 +554,15 @@ | commutativeLambda lam = Commutative | otherwise = comm - regularSegmentedRedomapKernel nest' perm cs w comm' lam' map_lam' nes arrs+ regularSegmentedRedomapKernel nest' perm (stmAuxCerts aux) w comm' lam' map_lam' nes arrs >>= kernelOrNot mempty stm acc kernels acc' _ -> addStmToAcc stm acc-maybeDistributeStm (Let pat (StmAux cs _ _) (Op (Screma w arrs form))) acc = do+maybeDistributeStm (Let pat aux (Op (Screma w arrs form))) acc = do -- This Screma is too complicated for us to immediately do -- anything, so split it up and try again. scope <- asksScope scopeForSOACs- distributeMapBodyStms acc . fmap (certify cs) . snd+ distributeMapBodyStms acc . fmap (certify (stmAuxCerts aux)) . snd =<< runBuilderT (dissectScrema pat w form arrs) scope maybeDistributeStm stm@(Let _ aux (BasicOp (Replicate shape (Var stm_arr)))) acc = do distributeSingleUnaryStm acc stm stm_arr $ \nest outerpat arr ->@@ -771,7 +771,7 @@ -- KernelNest we produce here is technically not sensible, but it's -- good enough for flatKernel to work. let nesting =- MapNesting scatter_pat (StmAux cs mempty ()) scatter_w $ zip (lambdaParams lam) ivs+ MapNesting scatter_pat (StmAux cs mempty mempty ()) scatter_w $ zip (lambdaParams lam) ivs nest' = pushInnerKernelNesting (scatter_pat, bodyResult $ lambdaBody lam) nesting nest (ispace, kernel_inps) <- flatKernel nest'
src/Futhark/Pkg/Types.hs view
@@ -282,7 +282,7 @@ pPkgPath = T.pack- <$> some (alphaNumChar <|> oneOf ("@-/.:_" :: String))+ <$> some (alphaNumChar <|> oneOf ("@-/.:_~" :: String)) <?> "package path" pRequired =
src/Futhark/Profile.hs view
@@ -19,21 +19,26 @@ -- | A thing that has occurred during execution. data ProfilingEvent = ProfilingEvent- { -- | Short, single line.+ { -- | Short, single line, not instance-specific. eventName :: T.Text, -- | In microseconds. eventDuration :: Double,- -- | Long, may be multiple lines.- eventDescription :: T.Text+ -- | The provenance of the event - that is, from where in the original+ -- program it originates.+ eventProvenance :: T.Text,+ -- | Arbitrary additional information, probably in the form of a dictionary,+ -- but that depends on the backend.+ eventDetails :: JSON.Value } deriving (Eq, Ord, Show) instance JSON.ToJSON ProfilingEvent where- toJSON (ProfilingEvent name duration description) =+ toJSON (ProfilingEvent name duration provenance details) = JSON.object [ ("name", JSON.toJSON name), ("duration", JSON.toJSON duration),- ("description", JSON.toJSON description)+ ("provenance", JSON.toJSON provenance),+ ("details", details) ] instance JSON.FromJSON ProfilingEvent where@@ -41,7 +46,8 @@ ProfilingEvent <$> o JSON..: "name" <*> o JSON..: "duration"- <*> o JSON..: "description"+ <*> o JSON..: "provenance"+ <*> o JSON..: "details" -- | A profiling report contains all profiling information for a -- single benchmark (meaning a single invocation on an entry point on@@ -53,11 +59,14 @@ } deriving (Eq, Ord, Show) +mapToJSON :: (JSON.ToJSON v) => M.Map T.Text v -> JSON.Value+mapToJSON = JSON.object . map (bimap JSON.fromText JSON.toJSON) . M.toList+ instance JSON.ToJSON ProfilingReport where toJSON (ProfilingReport events memory) = JSON.object [ ("events", JSON.toJSON events),- ("memory", JSON.object $ map (bimap JSON.fromText JSON.toJSON) $ M.toList memory)+ ("memory", mapToJSON memory) ] instance JSON.FromJSON ProfilingReport where
src/Futhark/Script.hs view
@@ -162,13 +162,7 @@ parseExp :: Parsec Void T.Text () -> Parsec Void T.Text Exp parseExp sep = choice- [ lexeme sep "let"- $> Let- <*> pPat- <* lexeme sep "="- <*> parseExp sep- <* lexeme sep "in"- <*> parseExp sep,+ [ pLet, try $ Call <$> parseFunc <*> many pAtom, pAtom ]@@ -179,6 +173,17 @@ pComma = lexeme sep "," mkTuple [v] = v mkTuple vs = Tuple vs++ pLet =+ lexeme sep "let"+ $> Let+ <*> pPat+ <* lexeme sep "="+ <*> parseExp sep+ <*> choice+ [ lexeme sep "in" *> parseExp sep,+ pLet+ ] pAtom = choice
src/Futhark/Transform/Rename.hs view
@@ -245,8 +245,8 @@ rename = pure instance (Rename dec) => Rename (StmAux dec) where- rename (StmAux cs attrs dec) =- StmAux <$> rename cs <*> rename attrs <*> rename dec+ rename (StmAux cs attrs loc dec) =+ StmAux <$> rename cs <*> rename attrs <*> pure loc <*> rename dec instance Rename SubExpRes where rename (SubExpRes cs se) = SubExpRes <$> rename cs <*> rename se
src/Futhark/Transform/Substitute.hs view
@@ -80,10 +80,11 @@ substituteNames _ attrs = attrs instance (Substitute dec) => Substitute (StmAux dec) where- substituteNames substs (StmAux cs attrs dec) =+ substituteNames substs (StmAux cs attrs loc dec) = StmAux (substituteNames substs cs) (substituteNames substs attrs)+ loc (substituteNames substs dec) instance (Substitute dec) => Substitute (Param dec) where
src/Language/Futhark/Core.hs view
@@ -18,6 +18,8 @@ locText, locTextRel, prettyStacktrace,+ isBuiltin,+ isBuiltinLoc, -- * Name handling Name,@@ -54,6 +56,7 @@ import Futhark.Util.Loc import Futhark.Util.Pretty import Numeric.Half+import System.FilePath (takeDirectory) import Prelude hiding (id, (.)) -- | The uniqueness attribute of a type. This essentially indicates@@ -160,6 +163,18 @@ -- | 'locStrRel', but for text. locTextRel :: (Located a, Located b) => a -> b -> T.Text locTextRel a b = T.pack $ locStrRel a b++-- | Is this include part of the built-in prelude?+isBuiltin :: FilePath -> Bool+isBuiltin = (== "/prelude") . takeDirectory++-- | Is the position of this thing builtin as per 'isBuiltin'? Things+-- without location are considered not built-in.+isBuiltinLoc :: (Located a) => a -> Bool+isBuiltinLoc x =+ case locOf x of+ NoLoc -> False+ Loc pos _ -> isBuiltin $ posFile pos -- | Given a list of strings representing entries in the stack trace -- and the index of the frame to highlight, produce a final
src/Language/Futhark/Interpreter.hs view
@@ -1017,15 +1017,13 @@ Just _ -> pure v Nothing -> bad loc env . docText $- "Value `"- <> prettyValue v- <> "` of shape `"- <> pretty (valueShape v)- <> "` cannot match shape of type `"- <> pretty te- <> "` (`"- <> pretty t'- <> "`)"+ "Value"+ <+> dquotes (prettyValue v)+ <+> "of shape"+ <+> dquotes (pretty (valueShape v))+ <+> "cannot match shape of type"+ <+> dquotes (pretty te)+ <+> parens (dquotes (pretty t')) eval _ (IntLit v (Info t) _) = case t of Scalar (Prim (Signed it)) ->@@ -1640,6 +1638,7 @@ case x of (ValuePrim (UnsignedValue x')) -> pure $ ValuePrim $ SignedValue x'+ ValueAD {} -> pure x -- FIXME: these do not carry signs. _ -> error $ "Cannot sign: " <> show x | "unsign_" `T.isPrefixOf` s = Just $@@ -1647,6 +1646,7 @@ case x of (ValuePrim (SignedValue x')) -> pure $ ValuePrim $ UnsignedValue x'+ ValueAD {} -> pure x -- FIXME: these do not carry signs. _ -> error $ "Cannot unsign: " <> show x def "map" = Just $ TermPoly Nothing $ \t -> do@@ -2101,11 +2101,19 @@ expectJust "jvp: differentiation failed" $ mapM ( \on -> case on of- -- If it is a JVP variable of the correct depth, return its primal and derivative+ -- If it is a JVP variable of the correct depth, return+ -- its primal and derivative (ValueAD d (AD.JVP (AD.JVPValue pv dv))) | d == depth -> Just (putAD pv, putAD dv) -- Otherwise, its partial derivatives are all 0- _ -> (on,) . ValuePrim . putV . P.blankPrimValue . P.primValueType . AD.primitive <$> getAD on+ _ ->+ (on,)+ . ValuePrim+ . putV+ . P.blankPrimValue+ . P.primValueType+ . AD.primitive+ <$> getAD on ) o' @@ -2117,15 +2125,11 @@ pure $ toTuple [ov, od] where modifyValue f v = snd $ valueAccum (\a b -> (a + 1, f a b)) 0 v- modifyValueM f v =- snd- <$> valueAccumLM- ( \a b -> do- b' <- f a b- pure (a + 1, b')- )- 0- v+ modifyValueM f v = snd <$> valueAccumLM step 0 v+ where+ step a b = do+ b' <- f a b+ pure (a + 1, b') expectJust _ (Just v) = v expectJust s Nothing = error s
src/Language/Futhark/Interpreter/AD.hs view
@@ -377,7 +377,6 @@ if r > 0 then pure (ss', rs') else -- Otherwise, derive the tape- if r == 0 then do let s'' = fromJust (M.lookup (-uid' - 1) ss')
src/Language/Futhark/Primitive.hs view
@@ -566,6 +566,10 @@ UIToFP IntType FloatType | -- | Convert a signed integer to a floating-point value. SIToFP IntType FloatType+ | -- | Convert floating point number to its bitwise representation.+ FPToBits FloatType+ | -- | Convert bitwise representation to a floating point number.+ BitsToFP FloatType | -- | Convert an integer to a boolean value. Zero -- becomes false; anything else is true. IToB IntType@@ -653,6 +657,8 @@ FPToSI <$> allFloatTypes <*> allIntTypes, UIToFP <$> allIntTypes <*> allFloatTypes, SIToFP <$> allIntTypes <*> allFloatTypes,+ FPToBits <$> allFloatTypes,+ BitsToFP <$> allFloatTypes, IToB <$> allIntTypes, BToI <$> allIntTypes, FToB <$> allFloatTypes,@@ -930,12 +936,30 @@ doConvOp (FPToSI _ to) (FloatValue v) = Just $ IntValue $ doFPToSI v to doConvOp (UIToFP _ to) (IntValue v) = Just $ FloatValue $ doUIToFP v to doConvOp (SIToFP _ to) (IntValue v) = Just $ FloatValue $ doSIToFP v to+doConvOp FPToBits {} (FloatValue (Float16Value x)) =+ Just $ IntValue $ Int16Value $ fromIntegral $ halfToWord x+doConvOp FPToBits {} (FloatValue (Float32Value x)) =+ Just $ IntValue $ Int32Value $ fromIntegral $ floatToWord x+doConvOp FPToBits {} (FloatValue (Float64Value x)) =+ Just $ IntValue $ Int64Value $ fromIntegral $ doubleToWord x+doConvOp BitsToFP {} (IntValue (Int16Value x)) =+ Just $ FloatValue $ Float16Value $ wordToHalf $ fromIntegral x+doConvOp BitsToFP {} (IntValue (Int32Value x)) =+ Just $ FloatValue $ Float32Value $ wordToFloat $ fromIntegral x+doConvOp BitsToFP {} (IntValue (Int64Value x)) =+ Just $ FloatValue $ Float64Value $ wordToDouble $ fromIntegral x doConvOp (IToB _) (IntValue v) = Just $ BoolValue $ intToInt64 v /= 0 doConvOp (BToI to) (BoolValue v) = Just $ IntValue $ intValue to $ if v then 1 else 0 :: Int doConvOp (FToB _) (FloatValue v) = Just $ BoolValue $ floatToDouble v /= 0 doConvOp (BToF to) (BoolValue v) = Just $ FloatValue $ floatValue to $ if v then 1 else 0 :: Double doConvOp _ _ = Nothing +-- | The integer type with the same size as the given floating point type.+matchingInt :: FloatType -> IntType+matchingInt Float16 = Int16+matchingInt Float32 = Int32+matchingInt Float64 = Int64+ -- | Turn the conversion the other way around. Note that most -- conversions are lossy, so there is no guarantee the value will -- round-trip.@@ -947,6 +971,8 @@ flipConvOp (FPToSI from to) = SIToFP to from flipConvOp (UIToFP from to) = FPToSI to from flipConvOp (SIToFP from to) = FPToSI to from+flipConvOp (FPToBits from) = BitsToFP from+flipConvOp (BitsToFP to) = FPToBits to flipConvOp (IToB from) = BToI from flipConvOp (BToI to) = IToB to flipConvOp (FToB from) = BToF from@@ -1161,6 +1187,8 @@ convOpType (FPToSI from to) = (FloatType from, IntType to) convOpType (UIToFP from to) = (IntType from, FloatType to) convOpType (SIToFP from to) = (IntType from, FloatType to)+convOpType (FPToBits from) = (FloatType from, IntType $ matchingInt from)+convOpType (BitsToFP to) = (IntType $ matchingInt to, FloatType to) convOpType (IToB from) = (IntType from, Bool) convOpType (BToI to) = (Bool, IntType to) convOpType (FToB from) = (FloatType from, Bool)@@ -1534,60 +1562,6 @@ _ -> Nothing ) ),- ( "to_bits16",- ( [FloatType Float16],- IntType Int16,- \case- [FloatValue (Float16Value x)] ->- Just $ IntValue $ Int16Value $ fromIntegral $ halfToWord x- _ -> Nothing- )- ),- ( "to_bits32",- ( [FloatType Float32],- IntType Int32,- \case- [FloatValue (Float32Value x)] ->- Just $ IntValue $ Int32Value $ fromIntegral $ floatToWord x- _ -> Nothing- )- ),- ( "to_bits64",- ( [FloatType Float64],- IntType Int64,- \case- [FloatValue (Float64Value x)] ->- Just $ IntValue $ Int64Value $ fromIntegral $ doubleToWord x- _ -> Nothing- )- ),- ( "from_bits16",- ( [IntType Int16],- FloatType Float16,- \case- [IntValue (Int16Value x)] ->- Just $ FloatValue $ Float16Value $ wordToHalf $ fromIntegral x- _ -> Nothing- )- ),- ( "from_bits32",- ( [IntType Int32],- FloatType Float32,- \case- [IntValue (Int32Value x)] ->- Just $ FloatValue $ Float32Value $ wordToFloat $ fromIntegral x- _ -> Nothing- )- ),- ( "from_bits64",- ( [IntType Int64],- FloatType Float64,- \case- [IntValue (Int64Value x)] ->- Just $ FloatValue $ Float64Value $ wordToDouble $ fromIntegral x- _ -> Nothing- )- ), f16_3 "lerp16" (\v0 v1 t -> v0 + (v1 - v0) * max 0 (min 1 t)), f32_3 "lerp32" (\v0 v1 t -> v0 + (v1 - v0) * max 0 (min 1 t)), f64_3 "lerp64" (\v0 v1 t -> v0 + (v1 - v0) * max 0 (min 1 t)),@@ -1950,6 +1924,8 @@ convOpFun FPToSI {} = "fptosi" convOpFun UIToFP {} = "uitofp" convOpFun SIToFP {} = "sitofp"+convOpFun FPToBits {} = "fptobits"+convOpFun BitsToFP {} = "bitstofp" convOpFun IToB {} = "itob" convOpFun BToI {} = "btoi" convOpFun FToB {} = "ftob"
src/Language/Futhark/Prop.hs view
@@ -7,8 +7,6 @@ Intrinsic (..), intrinsics, intrinsicVar,- isBuiltin,- isBuiltinLoc, maxIntrinsicTag, namesToPrimTypes, qualName,@@ -135,7 +133,6 @@ import Data.Foldable import Data.List (genericLength, isPrefixOf, sortOn) import Data.List.NonEmpty qualified as NE-import Data.Loc (Loc (..), posFile) import Data.Map.Strict qualified as M import Data.Maybe import Data.Ord@@ -147,7 +144,6 @@ import Language.Futhark.Syntax import Language.Futhark.Traversals import Language.Futhark.Tuple-import System.FilePath (takeDirectory) -- | The name of the default program entry point (@main@). defaultEntryPoint :: Name@@ -1197,18 +1193,6 @@ Prim $ Signed Int64 tupInt64 x = tupleRecord $ replicate x $ Scalar $ Prim $ Signed Int64---- | Is this include part of the built-in prelude?-isBuiltin :: FilePath -> Bool-isBuiltin = (== "/prelude") . takeDirectory---- | Is the position of this thing builtin as per 'isBuiltin'? Things--- without location are considered not built-in.-isBuiltinLoc :: (Located a) => a -> Bool-isBuiltinLoc x =- case locOf x of- NoLoc -> False- Loc pos _ -> isBuiltin $ posFile pos -- | The largest tag used by an intrinsic - this can be used to -- determine whether a 'VName' refers to an intrinsic or a user-defined name.
src/Language/Futhark/Syntax.hs view
@@ -1377,6 +1377,7 @@ mkApplyUT f x = AppExp (Apply f (NE.singleton (NoInfo, x)) (srcspan f x)) NoInfo +-- | Retrieve the expression for the initial values of loop parameters. loopInitExp :: LoopInitBase Info VName -> ExpBase Info VName loopInitExp (LoopInitExplicit e) = e loopInitExp (LoopInitImplicit (Info e)) = e
src/Language/Futhark/TypeChecker/Consumption.hs view
@@ -674,16 +674,25 @@ LoopInitExplicit e -> contain $ first LoopInitExplicit <$> checkArg [] param_t e consumed arg_cons- free_bound <- boundFreeInExp body - let bad = any (`M.member` arg_cons) . boundAliases . aliases . snd- forM_ (filter bad $ M.toList free_bound) $ \(v, _) -> do- v' <- describeVar v- addError loop_loc mempty $- "Loop body uses"- <+> v'- <> " (or an alias),"- </> "but this is consumed by the initial loop argument."+ let checkFree what e = do+ free_bound <- boundFreeInExp e++ let bad = any (`M.member` arg_cons) . boundAliases . aliases . snd+ forM_ (filter bad $ M.toList free_bound) $ \(v, _) -> do+ v' <- describeVar v+ addError loop_loc mempty $+ what+ <+> "uses"+ <+> v'+ <> " (or an alias),"+ </> "but this is consumed by the initial loop argument."++ checkFree "Loop body" body++ case form of+ While cond -> checkFree "Loop condition" cond+ _ -> pure () v <- VName "internal_loop_result" <$> incCounter modify $ \s -> s {stateNames = M.insert v (NameLoopRes (srclocOf loop_loc)) $ stateNames s}
− unittests/Futhark/AD/DerivativesTests.hs
@@ -1,52 +0,0 @@-module Futhark.AD.DerivativesTests (tests) where--import Data.Map qualified as M-import Data.Text qualified as T-import Futhark.AD.Derivatives-import Futhark.Analysis.PrimExp-import Futhark.IR.Syntax.Core (nameFromText)-import Futhark.Util.Pretty (prettyString)-import Test.Tasty-import Test.Tasty.HUnit--tests :: TestTree-tests =- testGroup- "Futhark.AD.DerivativesTests"- [ testGroup "Primitive functions" $- map primFunTest $- filter (not . (`elem` missing_primfuns) . fst) $- M.toList primFuns,- testGroup "BinOps" $ map binOpTest allBinOps,- testGroup "UnOps" $ map unOpTest allUnOps- ]- where- blank = ValueExp . blankPrimValue-- primFunTest (f, (ts, ret, _)) =- testCase (T.unpack f) $- case pdBuiltin (nameFromText f) (map blank ts) of- Nothing -> assertFailure "pdBuiltin gives Nothing"- Just v -> map primExpType v @?= replicate (length ts) ret-- -- We know we have no derivatives for these... and they are not- -- coming any time soon.- missing_primfuns =- [ "gamma16",- "gamma32",- "gamma64",- "lgamma16",- "lgamma32",- "lgamma64"- ]-- binOpTest bop =- testCase (prettyString bop) $- let t = binOpType bop- (dx, dy) = pdBinOp bop (blank t) (blank t)- in (primExpType dx, primExpType dy) @?= (t, t)-- unOpTest bop =- testCase (prettyString bop) $- let t = unOpType bop- in primExpType (pdUnOp bop $ blank t) @?= t
− unittests/Futhark/Analysis/AlgSimplifyTests.hs
@@ -1,90 +0,0 @@-{-# LANGUAGE FlexibleInstances #-}-{-# OPTIONS_GHC -fno-warn-orphans #-}-{-# OPTIONS_GHC -fno-warn-unused-imports #-}-{-# OPTIONS_GHC -fno-warn-unused-matches #-}-{-# OPTIONS_GHC -fno-warn-unused-top-binds #-}--module Futhark.Analysis.AlgSimplifyTests- ( tests,- )-where--import Control.Monad-import Data.Function ((&))-import Data.List (subsequences)-import Data.Map qualified as M-import Data.Maybe (fromMaybe, mapMaybe)-import Futhark.Analysis.AlgSimplify hiding (add, sub)-import Futhark.Analysis.PrimExp-import Futhark.IR.Syntax.Core-import Test.Tasty-import Test.Tasty.HUnit-import Test.Tasty.QuickCheck--tests :: TestTree-tests =- testGroup- "AlgSimplifyTests"- [ testProperty "simplify is idempotent" $ \(TestableExp e) -> simplify e == simplify (simplify e),- testProperty "simplify doesn't change exp evalutation result" $- \(TestableExp e) ->- evalPrimExp (\_ -> Nothing) e- == evalPrimExp (\_ -> Nothing) (simplify e)- ]--eval :: TestableExp -> Int64-eval (TestableExp e) = evalExp e--evalExp :: PrimExp VName -> Int64-evalExp (ValueExp (IntValue (Int64Value i))) = i-evalExp (BinOpExp (Add Int64 OverflowUndef) e1 e2) = evalExp e1 + evalExp e2-evalExp (BinOpExp (Sub Int64 OverflowUndef) e1 e2) = evalExp e1 - evalExp e2-evalExp (BinOpExp (Mul Int64 OverflowUndef) e1 e2) = evalExp e1 * evalExp e2-evalExp _ = undefined--add :: PrimExp VName -> PrimExp VName -> PrimExp VName-add = BinOpExp (Add Int64 OverflowUndef)--sub :: PrimExp VName -> PrimExp VName -> PrimExp VName-sub = BinOpExp (Sub Int64 OverflowUndef)--mul :: PrimExp VName -> PrimExp VName -> PrimExp VName-mul = BinOpExp (Mul Int64 OverflowUndef)--neg :: PrimExp VName -> PrimExp VName-neg = BinOpExp (Sub Int64 OverflowUndef) (val 0)--l :: Int -> PrimExp VName-l i = LeafExp (VName (nameFromString $ show i) i) (IntType Int64)--val :: Int64 -> PrimExp VName-val = ValueExp . IntValue . Int64Value--generateExp :: Gen (PrimExp VName)-generateExp = do- n <- getSize- if n <= 1- then val <$> arbitrary- else- oneof- [ scale (`div` 2) $ generateBinOp add,- scale (`div` 2) $ generateBinOp sub,- scale (`div` 2) $ generateBinOp mul,- scale (`div` 2) generateNeg,- val <$> arbitrary- ]--generateBinOp :: (PrimExp VName -> PrimExp VName -> PrimExp VName) -> Gen (PrimExp VName)-generateBinOp op = do- t1 <- generateExp- op t1 <$> generateExp--generateNeg :: Gen (PrimExp VName)-generateNeg =- do neg <$> generateExp--newtype TestableExp = TestableExp (PrimExp VName)- deriving (Show)--instance Arbitrary TestableExp where- arbitrary = TestableExp <$> generateExp
− unittests/Futhark/Analysis/PrimExp/TableTests.hs
@@ -1,257 +0,0 @@-module Futhark.Analysis.PrimExp.TableTests (tests) where--import Control.Monad.State.Strict-import Data.Map.Strict qualified as M-import Futhark.Analysis.PrimExp-import Futhark.Analysis.PrimExp.Table-import Futhark.IR.GPU-import Futhark.IR.GPUTests ()-import Futhark.IR.MC-import Futhark.IR.MCTests ()-import Test.Tasty-import Test.Tasty.HUnit--tests :: TestTree-tests = testGroup "AnalyzePrim" [stmToPrimExpsTests]--stmToPrimExpsTests :: TestTree-stmToPrimExpsTests =- testGroup- "stmToPrimExps"- [stmToPrimExpsTestsGPU, stmToPrimExpsTestsMC]--stmToPrimExpsTestsGPU :: TestTree-stmToPrimExpsTestsGPU =- testGroup- "GPU"- $ do- let scope =- M.fromList- [ ("n_5142", FParamName "i64"),- ("m_5143", FParamName "i64"),- ("xss_5144", FParamName "[n_5142][m_5143]i64"),- ("segmap_group_size_5201", LetName "i64"),- ("segmap_usable_groups_5202", LetName "i64"),- ("defunc_0_map_res_5203", LetName "[n_5142]i64"),- ("defunc_0_f_res_5207", LetName "i64"),- ("i_5208", IndexName Int64),- ("acc_5209", FParamName "i64"),- ("b_5210", LetName "i64"),- ("defunc_0_f_res_5211", LetName "i64")- ]- [ testCase "BinOp" $ do- let stm = "let {defunc_0_f_res_5211 : i64} = add64(acc_5209, b_5210)"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ( "defunc_0_f_res_5211",- Just- ( BinOpExp- (Add Int64 OverflowWrap)- (LeafExp "acc_5209" (IntType Int64))- (LeafExp "b_5210" (IntType Int64))- )- )- ]- res @?= expected,- testCase "Index" $ do- let stm = "let {b_5210 : i64} = xss_5144[gtid_5204, i_5208]"- let res = execState (stmToPrimExps scope stm) mempty- let expected = M.fromList [("b_5210", Nothing)]- res @?= expected,- testCase "Loop" $ do- let stm = "let {defunc_0_f_res_5207 : i64} = loop {acc_5209 : i64} = {0i64} for i_5208:i64 < m_5143 do { {defunc_0_f_res_5211} }"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ("defunc_0_f_res_5207", Nothing),- ("i_5208", Just (LeafExp "i_5208" (IntType Int64))),- ("acc_5209", Just (LeafExp "acc_5209" (IntType Int64)))- ]- res @?= expected,- testCase "Loop body" $ do- let stm = "let {defunc_0_f_res_5207 : i64} = loop {acc_5209 : i64} = {0i64} for i_5208:i64 < m_5143 do { let {b_5210 : i64} = xss_5144[gtid_5204, i_5208] let {defunc_0_f_res_5211 : i64} = add64(acc_5209, b_5210) in {defunc_0_f_res_5211} }"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ("defunc_0_f_res_5207", Nothing),- ("i_5208", Just (LeafExp "i_5208" (IntType Int64))),- ("acc_5209", Just (LeafExp "acc_5209" (IntType Int64))),- ("b_5210", Nothing),- ( "defunc_0_f_res_5211",- Just- ( BinOpExp- (Add Int64 OverflowWrap)- (LeafExp "acc_5209" (IntType Int64))- (LeafExp "b_5210" (IntType Int64))- )- )- ]- res @?= expected,- testCase "SegMap" $- do- let stm =- "let {defunc_0_map_res_5125 : [n_5142]i64} =\- \ segmap(thread; ; grid=segmap_usable_groups_5124; blocksize=segmap_group_size_5123)\- \ (gtid_5126 < n_5142) (~phys_tid_5127) : {i64} {\- \ return {returns lifted_lambda_res_5129} \- \}"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ("defunc_0_map_res_5125", Nothing),- ("gtid_5126", Just (LeafExp "gtid_5126" (IntType Int64)))- ]- res @?= expected,- testCase "SegMap body" $- do- let stm :: Stm GPU- stm =- "let {defunc_0_map_res_5125 : [n_5142]i64} =\- \ segmap(thread; ; grid=segmap_usable_groups_5124; blocksize=segmap_group_size_5123)\- \ (gtid_5126 < n_5142) (~phys_tid_5127) : {i64} {\- \ let {eta_p_5128 : i64} =\- \ xs_5093[gtid_5126]\- \ let {lifted_lambda_res_5129 : i64} =\- \ add64(2i64, eta_p_5128)\- \ return {returns lifted_lambda_res_5129}\- \ }"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ("defunc_0_map_res_5125", Nothing),- ("gtid_5126", Just (LeafExp "gtid_5126" (IntType Int64))),- ("eta_p_5128", Nothing),- ( "lifted_lambda_res_5129",- Just- ( BinOpExp- (Add Int64 OverflowWrap)- (ValueExp (IntValue (Int64Value 2)))- (LeafExp "eta_p_5128" (IntType Int64))- )- )- ]- res @?= expected- ]--stmToPrimExpsTestsMC :: TestTree-stmToPrimExpsTestsMC =- testGroup- "MC"- $ do- let scope =- M.fromList- [ ("n_5142", FParamName "i64"),- ("m_5143", FParamName "i64"),- ("xss_5144", FParamName "[n_5142][5143]i64"),- ("segmap_group_size_5201", LetName "i64"),- ("segmap_usable_groups_5202", LetName "i64"),- ("defunc_0_map_res_5203", LetName "[n_5142]i64"),- ("defunc_0_f_res_5207", LetName "i64"),- ("i_5208", IndexName Int64),- ("acc_5209", FParamName "i64"),- ("b_5210", LetName "i64"),- ("defunc_0_f_res_5211", LetName "i64")- ]- [ testCase "BinOp" $ do- let stm = "let {defunc_0_f_res_5211 : i64} = add64(acc_5209, b_5210)"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ( "defunc_0_f_res_5211",- Just- ( BinOpExp- (Add Int64 OverflowWrap)- (LeafExp "acc_5209" (IntType Int64))- (LeafExp "b_5210" (IntType Int64))- )- )- ]- res @?= expected,- testCase "Index" $ do- let stm = "let {b_5210 : i64} = xss_5144[gtid_5204, i_5208]"- let res = execState (stmToPrimExps scope stm) mempty- let expected = M.fromList [("b_5210", Nothing)]- res @?= expected,- testCase "Loop" $ do- let stm = "let {defunc_0_f_res_5207 : i64} = loop {acc_5209 : i64} = {0i64} for i_5208:i64 < m_5143 do { {defunc_0_f_res_5211} }"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ("defunc_0_f_res_5207", Nothing),- ("i_5208", Just (LeafExp "i_5208" (IntType Int64))),- ("acc_5209", Just (LeafExp "acc_5209" (IntType Int64)))- ]- res @?= expected,- testCase "Loop body" $ do- let stm =- "\- \let {defunc_0_f_res_5207 : i64} =\- \ loop {acc_5209 : i64} = {0i64}\- \ for i_5208:i64 < m_5143 do {\- \ let {b_5210 : i64} =\- \ xss_5144[gtid_5204, i_5208]\- \ let {defunc_0_f_res_5211 : i64} =\- \ add64(acc_5209, b_5210)\- \ in {defunc_0_f_res_5211}\- \ }"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ("defunc_0_f_res_5207", Nothing),- ("i_5208", Just (LeafExp "i_5208" (IntType Int64))),- ("acc_5209", Just (LeafExp "acc_5209" (IntType Int64))),- ("b_5210", Nothing),- ( "defunc_0_f_res_5211",- Just- ( BinOpExp- (Add Int64 OverflowWrap)- (LeafExp "acc_5209" (IntType Int64))- (LeafExp "b_5210" (IntType Int64))- )- )- ]- res @?= expected,- testCase "SegMap" $ do- let stm =- "let {defunc_0_map_res_5125 : [n_5142]i64} =\- \ segmap()\- \ (gtid_5126 < n_5142) (~flat_tid_5112) : {i64} {\- \ return {returns lifted_lambda_res_5129}\- \ }"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ("defunc_0_map_res_5125", Nothing),- ("gtid_5126", Just (LeafExp "gtid_5126" (IntType Int64)))- ]- res @?= expected,- testCase "SegMap body" $ do- let stm :: Stm MC- stm =- "let {defunc_0_map_res_5125 : [n_5142]i64} =\- \ segmap()\- \ (gtid_5126 < n_5142) (~flat_tid_5112) : {i64} {\- \ let {eta_p_5128 : i64} =\- \ xs_5093[gtid_5126]\- \ let {lifted_lambda_res_5129 : i64} =\- \ add64(2i64, eta_p_5128)\- \ return {returns lifted_lambda_res_5129}\- \ }"- let res = execState (stmToPrimExps scope stm) mempty- let expected =- M.fromList- [ ("defunc_0_map_res_5125", Nothing),- ("gtid_5126", Just (LeafExp "gtid_5126" (IntType Int64))),- ("eta_p_5128", Nothing),- ( "lifted_lambda_res_5129",- Just- ( BinOpExp- (Add Int64 OverflowWrap)- (ValueExp (IntValue (Int64Value 2)))- (LeafExp "eta_p_5128" (IntType Int64))- )- )- ]- res @?= expected- ]
− unittests/Futhark/BenchTests.hs
@@ -1,48 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Futhark.BenchTests (tests) where--import Data.Map qualified as M-import Data.Text qualified as T-import Futhark.Bench-import Futhark.ProfileTests ()-import Test.Tasty-import Test.Tasty.QuickCheck--instance Arbitrary RunResult where- arbitrary = RunResult . getPositive <$> arbitrary--printable :: Gen String-printable = getASCIIString <$> arbitrary--instance Arbitrary DataResult where- arbitrary =- DataResult- <$> (T.pack <$> printable)- <*> oneof- [ Left <$> arbText,- Right- <$> ( Result- <$> arbitrary- <*> arbMap- <*> oneof [pure Nothing, Just <$> arbText]- <*> arbitrary- )- ]- where- arbText = T.pack <$> printable- arbMap = M.fromList <$> listOf ((,) <$> arbText <*> arbitrary)---- XXX: we restrict this generator to single datasets to we don't have--- to worry about duplicates.-instance Arbitrary BenchResult where- arbitrary = BenchResult <$> printable <*> (pure <$> arbitrary)--encodeDecodeJSON :: TestTree-encodeDecodeJSON = testProperty "encoding and decoding are inverse" prop- where- prop :: BenchResult -> Bool- prop brs = decodeBenchResults (encodeBenchResults [brs]) == Right [brs]--tests :: TestTree-tests = testGroup "Futhark.BenchTests" [encodeDecodeJSON]
− unittests/Futhark/IR/GPUTests.hs
@@ -1,20 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Futhark.IR.GPUTests () where--import Data.String-import Futhark.IR.GPU-import Futhark.IR.Parse-import Futhark.IR.SyntaxTests (parseString)---- There isn't anything to test in this module, but we define some--- convenience instances.--instance IsString (Stm GPU) where- fromString = parseString "Stm GPU" parseStmGPU--instance IsString (Body GPU) where- fromString = parseString "Body GPU" parseBodyGPU--instance IsString (Prog GPU) where- fromString = parseString "Prog GPU" parseGPU
− unittests/Futhark/IR/MCTests.hs
@@ -1,20 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Futhark.IR.MCTests () where--import Data.String-import Futhark.IR.MC-import Futhark.IR.Parse-import Futhark.IR.SyntaxTests (parseString)---- There isn't anything to test in this module, but we define some--- convenience instances.--instance IsString (Stm MC) where- fromString = parseString "Stm MC" parseStmMC--instance IsString (Body MC) where- fromString = parseString "Body MC" parseBodyMC--instance IsString (Prog MC) where- fromString = parseString "Prog MC" parseMC
− unittests/Futhark/IR/Mem/IntervalTests.hs
@@ -1,68 +0,0 @@-module Futhark.IR.Mem.IntervalTests- ( tests,- )-where--import Futhark.Analysis.AlgSimplify-import Futhark.Analysis.PrimExp.Convert-import Futhark.IR.Mem.Interval-import Futhark.IR.Syntax-import Futhark.IR.Syntax.Core ()-import Test.Tasty-import Test.Tasty.HUnit---- Actual tests.-tests :: TestTree-tests =- testGroup- "IntervalTests"- testDistributeOffset--name :: String -> Int -> VName-name s = VName (nameFromString s)--testDistributeOffset :: [TestTree]-testDistributeOffset =- [ testCase "Stride is (nb-b)" $ do- let n = TPrimExp $ LeafExp (name "n" 1) $ IntType Int64- b = TPrimExp $ LeafExp (name "b" 2) $ IntType Int64- res <-- distributeOffset- [Prod False [untyped (n * b - b :: TPrimExp Int64 VName)]]- [ Interval 0 1 (n * b - b),- Interval 0 b b,- Interval 0 b 1- ]- res == [Interval 1 1 (n * b - b), Interval 0 b b, Interval 0 b 1] @? "Failed",- testCase "Stride is 1024r" $ do- let r = TPrimExp $ LeafExp (name "r" 1) $ IntType Int64- res <-- distributeOffset- [Prod False [untyped (1024 :: TPrimExp Int64 VName), untyped r]]- [ Interval 0 1 (1024 * r),- Interval 0 32 32,- Interval 0 32 1- ]- res == [Interval 1 1 (1024 * r), Interval 0 32 32, Interval 0 32 1] @? "Failed. Got " <> show res,- testCase "Stride is 32, offsets are multples of 32" $ do- let n = TPrimExp $ LeafExp (name "n" 0) $ IntType Int64- let g1 = TPrimExp $ LeafExp (name "g" 1) $ IntType Int64- let g2 = TPrimExp $ LeafExp (name "g" 2) $ IntType Int64- res <-- distributeOffset- [ Prod False [untyped (1024 :: TPrimExp Int64 VName)],- Prod False [untyped (1024 :: TPrimExp Int64 VName), untyped g1],- Prod False [untyped (32 :: TPrimExp Int64 VName), untyped g2]- ]- [ Interval 0 1 (1024 * n),- Interval 0 1 32,- Interval 0 32 1- ]- res- == [ Interval 0 1 (1024 * n),- Interval (32 + 32 * g1 + g2) 1 32,- Interval 0 32 1- ]- @? "Failed. Got "- <> show res- ]
− unittests/Futhark/IR/Mem/IxFun/Alg.hs
@@ -1,176 +0,0 @@--- | A simple index operation representation. Every operation corresponds to a--- constructor.-module Futhark.IR.Mem.IxFun.Alg- ( IxFun (..),- iota,- offsetIndex,- permute,- reshape,- coerce,- slice,- flatSlice,- expand,- shape,- index,- disjoint,- )-where--import Data.List qualified as L-import Data.Set qualified as S-import Futhark.IR.Pretty ()-import Futhark.IR.Prop-import Futhark.IR.Syntax- ( DimIndex (..),- FlatDimIndex (..),- FlatSlice (..),- Slice (..),- flatSliceDims,- sliceDims,- unitSlice,- )-import Futhark.Util.IntegralExp-import Futhark.Util.Pretty-import Prelude hiding (div, mod, span)--type Shape num = [num]--type Indices num = [num]--type Permutation = [Int]--data IxFun num- = Direct (Shape num)- | Permute (IxFun num) Permutation- | Index (IxFun num) (Slice num)- | FlatIndex (IxFun num) (FlatSlice num)- | Reshape (IxFun num) (Shape num)- | Coerce (IxFun num) (Shape num)- | OffsetIndex (IxFun num) num- | Expand num num (IxFun num)- deriving (Eq, Show)--instance (Pretty num) => Pretty (IxFun num) where- pretty (Direct dims) =- "Direct" <> parens (commasep $ map pretty dims)- pretty (Permute fun perm) = pretty fun <> pretty perm- pretty (Index fun is) = pretty fun <> pretty is- pretty (FlatIndex fun is) = pretty fun <> pretty is- pretty (Reshape fun oldshape) =- pretty fun- <> "->reshape"- <> parens (pretty oldshape)- pretty (Coerce fun oldshape) =- pretty fun- <> "->coerce"- <> parens (pretty oldshape)- pretty (OffsetIndex fun i) =- pretty fun <> "->offset_index" <> parens (pretty i)- pretty (Expand o p fun) =- "expand(" <> pretty o <> "," <+> pretty p <> "," <+> pretty fun <> ")"--iota :: Shape num -> IxFun num-iota = Direct--offsetIndex :: IxFun num -> num -> IxFun num-offsetIndex = OffsetIndex--permute :: IxFun num -> Permutation -> IxFun num-permute = Permute--slice :: IxFun num -> Slice num -> IxFun num-slice = Index--flatSlice :: IxFun num -> FlatSlice num -> IxFun num-flatSlice = FlatIndex--expand :: num -> num -> IxFun num -> IxFun num-expand = Expand--reshape :: IxFun num -> Shape num -> IxFun num-reshape = Reshape--coerce :: IxFun num -> Shape num -> IxFun num-coerce = Reshape--shape ::- (IntegralExp num) =>- IxFun num ->- Shape num-shape (Direct dims) =- dims-shape (Permute ixfun perm) =- rearrangeShape perm $ shape ixfun-shape (Index _ how) =- sliceDims how-shape (FlatIndex ixfun how) =- flatSliceDims how <> tail (shape ixfun)-shape (Reshape _ dims) =- dims-shape (Coerce _ dims) =- dims-shape (OffsetIndex ixfun _) =- shape ixfun-shape (Expand _ _ ixfun) =- shape ixfun--index ::- (Eq num, IntegralExp num) =>- IxFun num ->- Indices num ->- num-index (Direct dims) is =- sum $ zipWith (*) is slicesizes- where- slicesizes = drop 1 $ sliceSizes dims-index (Permute fun perm) is_new =- index fun is_old- where- is_old = rearrangeShape (rearrangeInverse perm) is_new-index (Index fun (Slice js)) is =- index fun (adjust js is)- where- adjust (DimFix j : js') is' = j : adjust js' is'- adjust (DimSlice j _ s : js') (i : is') = j + i * s : adjust js' is'- adjust _ _ = []-index (FlatIndex fun (FlatSlice offset js)) is =- index fun $ sum (offset : zipWith f is js) : drop (length js) is- where- f i (FlatDimIndex _ s) = i * s-index (Reshape fun newshape) is =- let new_indices = reshapeIndex (shape fun) newshape is- in index fun new_indices-index (Coerce fun _) is =- index fun is-index (OffsetIndex fun i) is =- case shape fun of- d : ds ->- index (Index fun (Slice (DimSlice i (d - i) 1 : map (unitSlice 0) ds))) is- [] -> error "index: OffsetIndex: underlying index function has rank zero"-index (Expand o p ixfun) is =- o + p * index ixfun is--allPoints :: (IntegralExp num, Enum num) => [num] -> [[num]]-allPoints dims =- let total = product dims- strides = drop 1 $ L.reverse $ scanl (*) 1 $ L.reverse dims- in map (unflatInd strides) [0 .. total - 1]- where- unflatInd strides x =- fst $- foldl- ( \(res, acc) span ->- (res ++ [acc `div` span], acc `mod` span)- )- ([], x)- strides--disjoint :: (IntegralExp num, Ord num, Enum num) => IxFun num -> IxFun num -> Bool-disjoint ixf1 ixf2 =- let shp1 = shape ixf1- points1 = S.fromList $ allPoints shp1- allIdxs1 = S.map (index ixf1) points1- shp2 = shape ixf2- points2 = S.fromList $ allPoints shp2- allIdxs2 = S.map (index ixf2) points2- in S.disjoint allIdxs1 allIdxs2
− unittests/Futhark/IR/Mem/IxFunTests.hs
@@ -1,571 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Futhark.IR.Mem.IxFunTests- ( tests,- )-where--import Data.Bifunctor-import Data.Function ((&))-import Data.List qualified as L-import Data.Map qualified as M-import Data.Text qualified as T-import Futhark.Analysis.PrimExp.Convert-import Futhark.IR.Mem.IxFun.Alg qualified as IxFunAlg-import Futhark.IR.Mem.IxFunWrapper-import Futhark.IR.Mem.IxFunWrapper qualified as IxFunWrap-import Futhark.IR.Mem.LMAD qualified as IxFunLMAD-import Futhark.IR.Prop-import Futhark.IR.Syntax-import Futhark.IR.Syntax.Core ()-import Futhark.Util.IntegralExp qualified as IE-import Futhark.Util.Pretty-import Test.Tasty-import Test.Tasty.HUnit-import Prelude hiding (span)-import Prelude qualified as P--instance IE.IntegralExp Int where- quot = P.quot- rem = P.rem- div = P.div- mod = P.mod- pow = (P.^)- sgn = Just . P.signum--allPoints :: [Int] -> [[Int]]-allPoints dims =- let total = product dims- strides = drop 1 $ L.reverse $ scanl (*) 1 $ L.reverse dims- in map (unflatInd strides) [0 .. total - 1]- where- unflatInd :: [Int] -> Int -> [Int]- unflatInd strides x =- fst $- foldl- ( \(res, acc) span ->- (res ++ [acc `P.div` span], acc `P.mod` span)- )- ([], x)- strides--compareIxFuns :: Maybe (IxFunLMAD.LMAD Int) -> IxFunAlg.IxFun Int -> Assertion-compareIxFuns (Just ixfunLMAD) ixfunAlg =- let lmadShape = IxFunLMAD.shape ixfunLMAD- algShape = IxFunAlg.shape ixfunAlg- points = allPoints lmadShape- resLMAD = map (IxFunLMAD.index ixfunLMAD) points- resAlg = map (IxFunAlg.index ixfunAlg) points- errorMessage =- T.unpack . docText $- "lmad ixfun: "- <> pretty ixfunLMAD- </> "alg ixfun: "- <> pretty ixfunAlg- </> "lmad shape: "- <> pretty lmadShape- </> "alg shape: "- <> pretty algShape- </> "lmad points length: "- <> pretty (length resLMAD)- </> "alg points length: "- <> pretty (length resAlg)- </> "lmad points: "- <> pretty resLMAD- </> "alg points: "- <> pretty resAlg- in (lmadShape == algShape && resLMAD == resAlg) @? errorMessage-compareIxFuns Nothing ixfunAlg =- assertFailure $- unlines- [ "lmad ixfun: Nothing",- "alg ixfun: " <> prettyString ixfunAlg- ]--compareOps :: IxFunWrap.IxFun Int -> Assertion-compareOps (ixfunLMAD, ixfunAlg) = compareIxFuns ixfunLMAD ixfunAlg--compareOpsFailure :: IxFunWrap.IxFun Int -> Assertion-compareOpsFailure (Nothing, _) = pure ()-compareOpsFailure (Just ixfunLMAD, ixfunAlg) =- assertFailure . T.unpack . docText $- "Not supposed to be representable as LMAD."- </> "lmad ixfun: "- <> pretty ixfunLMAD- </> "alg ixfun: "- <> pretty ixfunAlg---- XXX: Clean this up.-n :: Int-n = 19--slice3 :: Slice Int-slice3 =- Slice- [ DimSlice 2 (n `P.div` 3) 3,- DimFix (n `P.div` 2),- DimSlice 1 (n `P.div` 2) 2- ]---- Actual tests.-tests :: TestTree-tests =- testGroup "IxFunTests" $- concat- [ test_iota,- test_slice_iota,- test_slice_reshape_iota1,- test_permute_slice_iota,- test_reshape_iota,- test_reshape_permute_iota,- test_slice_reshape_iota2,- test_reshape_slice_iota3,- test_flatten_strided,- test_complex1,- test_complex2,- test_expand1,- test_expand2,- test_expand3,- test_expand4,- test_flatSlice_iota,- test_slice_flatSlice_iota,- test_flatSlice_flatSlice_iota,- test_flatSlice_slice_iota,- test_flatSlice_transpose_slice_iota- -- TODO: Without z3, these tests fail. Ideally, our internal simplifier- -- should be able to handle them:- --- -- test_disjoint3- ]--singleton :: TestTree -> [TestTree]-singleton = (: [])--test_iota :: [TestTree]-test_iota =- singleton . testCase "iota" . compareOps $- iota [n]--test_slice_iota :: [TestTree]-test_slice_iota =- singleton . testCase "slice . iota" . compareOps $- slice (iota [n, n, n]) slice3--test_slice_reshape_iota1 :: [TestTree]-test_slice_reshape_iota1 =- singleton . testCase "slice . reshape . iota 1" . compareOps $- slice (reshape (iota [n, n, n]) [n `P.div` 2, n `P.div` 3, 1]) slice3--test_permute_slice_iota :: [TestTree]-test_permute_slice_iota =- singleton . testCase "permute . slice . iota" . compareOps $- permute (slice (iota [n, n, n]) slice3) [1, 0]--test_reshape_iota :: [TestTree]-test_reshape_iota =- -- This tests a pattern that occurs with ScalarSpace.- singleton . testCase "reshape . zeroslice . iota" . compareOps $- let s = Slice [DimSlice 0 n 0, DimSlice 0 n 1]- in reshape (slice (iota [n, n]) s) [1, n, 1, n]--test_reshape_permute_iota :: [TestTree]-test_reshape_permute_iota =- -- negative reshape test- singleton . testCase "reshape . permute . iota" . compareOpsFailure $- let newdims = [n * n, n]- in reshape (permute (iota [n, n, n]) [1, 2, 0]) newdims--test_slice_reshape_iota2 :: [TestTree]-test_slice_reshape_iota2 =- singleton . testCase "slice . reshape . iota 2" . compareOps $- let newdims = [n * n, n]- slc =- Slice- [ DimFix (n `P.div` 2),- DimSlice 0 n 1- ]- in slice (reshape (iota [n, n, n, n]) newdims) slc--test_reshape_slice_iota3 :: [TestTree]-test_reshape_slice_iota3 =- -- negative reshape test- singleton . testCase "reshape . slice . iota 3" . compareOpsFailure $- let newdims = [n * n, n]- slc =- Slice- [ DimFix (n `P.div` 2),- DimSlice 0 n 1,- DimSlice 0 (n `P.div` 2) 1,- DimSlice 0 n 1- ]- in reshape (slice (iota [n, n, n, n]) slc) newdims---- Tests flattening something that is strided - this can occur after--- memory expansion.-test_flatten_strided :: [TestTree]-test_flatten_strided =- singleton . testCase "reshape . fix . iota 3d" . compareOps $- let slc = Slice [DimSlice 0 n 1, DimSlice 0 2 1, DimFix 1]- in reshape (slice (iota [n, 2, n * n]) slc) [2 * 10]--test_complex1 :: [TestTree]-test_complex1 =- singleton . testCase "permute . slice . permute . slice . iota 1" . compareOps $- let slice33 =- Slice- [ DimSlice (n - 1) (n `P.div` 3) (-1),- DimSlice (n - 1) n (-1),- DimSlice (n - 1) n (-1),- DimSlice 0 n 1- ]- ixfun = permute (slice (iota [n, n, n, n, n]) slice33) [3, 1, 2, 0]- m = n `P.div` 3- slice1 =- Slice- [ DimSlice 0 n 1,- DimSlice (n - 1) n (-1),- DimSlice (n - 1) n (-1),- DimSlice 1 (m - 2) (-1)- ]- ixfun' = slice ixfun slice1- in ixfun'--test_complex2 :: [TestTree]-test_complex2 =- singleton . testCase "permute . slice . permute . slice . iota 2" . compareOps $- let slc2 =- Slice- [ DimFix (n `P.div` 2),- DimSlice (n - 1) (n `P.div` 3) (-1),- DimSlice (n - 1) n (-1),- DimSlice (n - 1) n (-1),- DimSlice 0 n 1- ]- ixfun = permute (slice (iota [n, n, n, n, n]) slc2) [3, 1, 2, 0]- m = n `P.div` 3- slice1 =- Slice- [ DimSlice 0 n 1,- DimSlice (n - 1) n (-1),- DimSlice (n - 1) n (-1),- DimSlice 1 (m - 2) (-1)- ]- ixfun' = slice ixfun slice1- in ixfun'---- Imitates a case from memory expansion.-test_expand1 :: [TestTree]-test_expand1 =- [ testCase "expand . iota1d" . compareOps $- expand t nt (iota [n])- ]- where- t = 3- nt = 7---- Imitates another case from memory expansion.-test_expand2 :: [TestTree]-test_expand2 =- [ testCase "expand . iota2d" . compareOps $- expand t nt (iota [n, n])- ]- where- t = 3- nt = 7--test_expand3 :: [TestTree]-test_expand3 =- [ testCase "expand . permute . iota2d" . compareOps $- expand t nt (permute (iota [n, n `div` 2]) [1, 0])- ]- where- t = 3- nt = 7--test_expand4 :: [TestTree]-test_expand4 =- [ testCase "expand . slice . iota1d" . compareOps $- expand t nt (slice (iota [n]) (Slice [DimSlice (n `div` 2) (n `div` 2) 1]))- ]- where- t = 3- nt = 7--test_flatSlice_iota :: [TestTree]-test_flatSlice_iota =- singleton . testCase "flatSlice . iota" . compareOps $- flatSlice (iota [n * n * n * n]) $- FlatSlice 2 [FlatDimIndex (n * 2) 4, FlatDimIndex n 3, FlatDimIndex 1 2]--test_slice_flatSlice_iota :: [TestTree]-test_slice_flatSlice_iota =- singleton . testCase "slice . flatSlice . iota " . compareOps $- slice (flatSlice (iota [2 + n * n * n]) flat_slice) $- Slice [DimFix 2, DimSlice 0 n 1, DimFix 0]- where- flat_slice = FlatSlice 2 [FlatDimIndex (n * n) 1, FlatDimIndex n 1, FlatDimIndex 1 1]--test_flatSlice_flatSlice_iota :: [TestTree]-test_flatSlice_flatSlice_iota =- singleton . testCase "flatSlice . flatSlice . iota " . compareOps $- flatSlice (flatSlice (iota [10 * 10]) flat_slice_1) flat_slice_2- where- flat_slice_1 = FlatSlice 17 [FlatDimIndex 3 27, FlatDimIndex 3 10, FlatDimIndex 3 1]- flat_slice_2 = FlatSlice 2 [FlatDimIndex 2 (-2)]--test_flatSlice_slice_iota :: [TestTree]-test_flatSlice_slice_iota =- singleton . testCase "flatSlice . slice . iota " . compareOps $- flatSlice (slice (iota [210, 100]) $ Slice [DimSlice 10 100 2, DimFix 10]) flat_slice_1- where- flat_slice_1 = FlatSlice 17 [FlatDimIndex 3 27, FlatDimIndex 3 10, FlatDimIndex 3 1]--test_flatSlice_transpose_slice_iota :: [TestTree]-test_flatSlice_transpose_slice_iota =- singleton . testCase "flatSlice . transpose . slice . iota " . compareOps $- flatSlice (permute (slice (iota [20, 20]) $ Slice [DimSlice 1 5 2, DimSlice 0 5 2]) [1, 0]) flat_slice_1- where- flat_slice_1 = FlatSlice 1 [FlatDimIndex 2 2]---- test_disjoint2 :: [TestTree]--- test_disjoint2 =--- let add_nw64 = (+)---- mul_nw64 = (*)---- sub64 = (-)---- vname s i = VName (nameFromString s) i--- in [ let gtid_8472 = TPrimExp $ LeafExp (vname "gtid" 8472) $ IntType Int64---- gtid_8473 = TPrimExp $ LeafExp (vname "gtid" 8473) $ IntType Int64---- gtid_8474 = TPrimExp $ LeafExp (vname "gtid" 8474) $ IntType Int64---- num_blocks_8284 = TPrimExp $ LeafExp (vname "num_blocks" 8284) $ IntType Int64---- nonnegs = freeIn [gtid_8472, gtid_8473, gtid_8474, num_blocks_8284]---- j_m_i_8287 :: TPrimExp Int64 VName--- j_m_i_8287 = num_blocks_8284 - 1---- lessthans :: [(VName, PrimExp VName)]--- lessthans =--- [ (head $ namesToList $ freeIn gtid_8472, untyped j_m_i_8287),--- (head $ namesToList $ freeIn gtid_8473, untyped j_m_i_8287),--- (head $ namesToList $ freeIn gtid_8474, untyped (16 :: TPrimExp Int64 VName))--- ]---- lm1 :: IxFunLMAD.LMAD (TPrimExp Int64 VName)--- lm1 =--- IxFunLMAD.LMAD--- 256--- [ IxFunLMAD.LMADDim 256 0 (sub64 (num_blocks_8284) 1) 0 ,--- IxFunLMAD.LMADDim 1 0 16 1 ,--- IxFunLMAD.LMADDim 16 0 16 2--- ]--- lm2 :: IxFunLMAD.LMAD (TPrimExp Int64 VName)--- lm2 =--- IxFunLMAD.LMAD--- (add_nw64 (add_nw64 (add_nw64 (add_nw64 (mul_nw64 (256) (num_blocks_8284)) (256)) (mul_nw64 (gtid_8472) (mul_nw64 (256) (num_blocks_8284)))) (mul_nw64 (gtid_8473) (256))) (mul_nw64 (gtid_8474) (16)))--- [IxFunLMAD.LMADDim 1 0 16 0 ]--- in testCase (pretty lm1 <> " and " <> pretty lm2) $ IxFunLMAD.disjoint2 lessthans nonnegs lm1 lm2 @? "Failed"--- ]---- test_lessThanish :: [TestTree]--- test_lessThanish =--- [testCase "0 < 1" $ IxFunLMAD.lessThanish mempty mempty 0 1 @? "Failed"]---- test_lessThanOrEqualish :: [TestTree]--- test_lessThanOrEqualish =--- [testCase "1 <= 1" $ IxFunLMAD.lessThanOrEqualish mempty mempty 1 1 @? "Failed"]--_test_disjoint3 :: [TestTree]-_test_disjoint3 =- let foo s = VName (nameFromString s)- add_nw64 = (+)- add64 = (+)- mul_nw64 = (*)- mul64 = (*)- sub64 = (-)- sdiv64 = IE.div- sub_nw64 = (-)- disjointTester asserts lessthans lm1 lm2 =- let nonnegs = map (`LeafExp` IntType Int64) $ namesToList $ freeIn lm1 <> freeIn lm2-- scmap =- M.fromList $- map (\x -> (x, Prim $ IntType Int64)) $- namesToList $- freeIn lm1 <> freeIn lm2 <> freeIn lessthans <> freeIn asserts- in IxFunLMAD.disjoint3 scmap asserts lessthans nonnegs lm1 lm2- in [ testCase "lm1 and lm2" $- let lessthans =- [ ( i_12214,- sdiv64 (sub64 n_blab 1) block_size_12121- ),- (gtid_12553, add64 1 i_12214)- ]- & map (\(v, p) -> (head $ namesToList $ freeIn v, untyped p))-- asserts =- [ untyped ((2 * block_size_12121 :: TPrimExp Int64 VName) .<. n_blab :: TPrimExp Bool VName),- untyped ((3 :: TPrimExp Int64 VName) .<. n_blab :: TPrimExp Bool VName)- ]-- block_size_12121 = TPrimExp $ LeafExp (foo "block_size" 12121) $ IntType Int64- i_12214 = TPrimExp $ LeafExp (foo "i" 12214) $ IntType Int64- n_blab = TPrimExp $ LeafExp (foo "n" 1337) $ IntType Int64- gtid_12553 = TPrimExp $ LeafExp (foo "gtid" 12553) $ IntType Int64-- lm1 =- IxFunLMAD.LMAD- (add_nw64 (mul64 block_size_12121 i_12214) (mul_nw64 (add_nw64 gtid_12553 1) (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))- [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (sub_nw64 (sub_nw64 (add64 1 i_12214) gtid_12553) 1),- IxFunLMAD.LMADDim 1 (block_size_12121 + 1)- ]-- lm2 =- IxFunLMAD.LMAD- (block_size_12121 * i_12214)- [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) gtid_12553,- IxFunLMAD.LMADDim 1 (1 + block_size_12121)- ]-- lm_w =- IxFunLMAD.LMAD- (add_nw64 (add64 (add64 1 n_blab) (mul64 block_size_12121 i_12214)) (mul_nw64 gtid_12553 (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))- [ IxFunLMAD.LMADDim n_blab block_size_12121,- IxFunLMAD.LMADDim 1 block_size_12121- ]-- lm_blocks =- IxFunLMAD.LMAD- (block_size_12121 * i_12214 + n_blab + 1)- [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (i_12214 + 1),- IxFunLMAD.LMADDim n_blab block_size_12121,- IxFunLMAD.LMADDim 1 block_size_12121- ]-- lm_lower_per =- IxFunLMAD.LMAD- (block_size_12121 * i_12214)- [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (i_12214 + 1),- IxFunLMAD.LMADDim 1 (block_size_12121 + 1)- ]-- res1 = disjointTester asserts lessthans lm1 lm_w- res2 = disjointTester asserts lessthans lm2 lm_w- res3 = disjointTester asserts lessthans lm_lower_per lm_blocks- in res1 && res2 && res3 @? "Failed",- testCase "nw second half" $ do- let lessthans =- [ ( i_12214,- sdiv64 (sub64 n_blab 1) block_size_12121- ),- (gtid_12553, add64 1 i_12214)- ]- & map (\(v, p) -> (head $ namesToList $ freeIn v, untyped p))-- asserts =- [ untyped ((2 * block_size_12121 :: TPrimExp Int64 VName) .<. n_blab :: TPrimExp Bool VName),- untyped ((3 :: TPrimExp Int64 VName) .<. n_blab :: TPrimExp Bool VName)- ]-- block_size_12121 = TPrimExp $ LeafExp (foo "block_size" 12121) $ IntType Int64- i_12214 = TPrimExp $ LeafExp (foo "i" 12214) $ IntType Int64- n_blab = TPrimExp $ LeafExp (foo "n" 1337) $ IntType Int64- gtid_12553 = TPrimExp $ LeafExp (foo "gtid" 12553) $ IntType Int64-- lm1 =- IxFunLMAD.LMAD- (add_nw64 (add64 n_blab (sub64 (sub64 (mul64 n_blab (add64 1 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) 1)) (mul_nw64 (add_nw64 gtid_12553 1) (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))- [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (sub_nw64 (sub_nw64 (sub64 (sub64 (sdiv64 (sub64 n_blab 1) block_size_12121) i_12214) 1) gtid_12553) 1),- IxFunLMAD.LMADDim n_blab block_size_12121- ]-- lm2 =- IxFunLMAD.LMAD- (add_nw64 (sub64 (sub64 (mul64 n_blab (add64 1 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) 1) (mul_nw64 (add_nw64 gtid_12553 1) (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))- [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) (sub_nw64 (sub_nw64 (sub64 (sub64 (sdiv64 (sub64 n_blab 1) block_size_12121) i_12214) 1) gtid_12553) 1),- IxFunLMAD.LMADDim 1 (1 + block_size_12121)- ]-- lm3 =- IxFunLMAD.LMAD- (add64 n_blab (sub64 (sub64 (mul64 n_blab (add64 1 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) 1))- [ IxFunLMAD.LMADDim (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121)) gtid_12553,- IxFunLMAD.LMADDim n_blab block_size_12121- ]-- lm4 =- IxFunLMAD.LMAD- (sub64 (sub64 (mul64 n_blab (add64 1 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) 1)- [ IxFunLMAD.LMADDim- (add_nw64 (mul_nw64 block_size_12121 n_blab) (mul_nw64 (-1) block_size_12121))- gtid_12553,- IxFunLMAD.LMADDim- 1- (1 + block_size_12121)- ]-- lm_w =- IxFunLMAD.LMAD- (add_nw64 (sub64 (mul64 n_blab (add64 2 (mul64 block_size_12121 (add64 1 i_12214)))) block_size_12121) (mul_nw64 gtid_12553 (sub64 (mul64 block_size_12121 n_blab) block_size_12121)))- [ IxFunLMAD.LMADDim n_blab block_size_12121,- IxFunLMAD.LMADDim 1 block_size_12121- ]-- res1 = disjointTester asserts lessthans lm1 lm_w- res2 = disjointTester asserts lessthans lm2 lm_w- res3 = disjointTester asserts lessthans lm3 lm_w- res4 = disjointTester asserts lessthans lm4 lm_w- in res1 && res2 && res3 && res4 @? "Failed " <> show [res1, res2, res3, res4],- testCase "lud long" $- let lessthans =- [ bimap- (head . namesToList . freeIn)- untyped- (step, num_blocks - 1 :: TPrimExp Int64 VName)- ]-- step = TPrimExp $ LeafExp (foo "step" 1337) $ IntType Int64-- num_blocks = TPrimExp $ LeafExp (foo "n" 1338) $ IntType Int64-- lm1 =- IxFunLMAD.LMAD- (1024 * num_blocks * (1 + step) + 1024 * step)- [ IxFunLMAD.LMADDim (1024 * num_blocks) (num_blocks - step - 1),- IxFunLMAD.LMADDim 32 32,- IxFunLMAD.LMADDim 1 32- ]-- lm_w1 =- IxFunLMAD.LMAD- (1024 * num_blocks * step + 1024 * step)- [ IxFunLMAD.LMADDim 32 32,- IxFunLMAD.LMADDim 1 32- ]-- lm_w2 =- IxFunLMAD.LMAD- ((1 + step) * 1024 * num_blocks + (1 + step) * 1024)- [ IxFunLMAD.LMADDim (1024 * num_blocks) (num_blocks - step - 1),- IxFunLMAD.LMADDim 1024 (num_blocks - step - 1),- IxFunLMAD.LMADDim 1024 1,- IxFunLMAD.LMADDim 32 1,- IxFunLMAD.LMADDim 128 8,- IxFunLMAD.LMADDim 4 8,- IxFunLMAD.LMADDim 32 4,- IxFunLMAD.LMADDim 1 4- ]-- asserts =- [ untyped ((1 :: TPrimExp Int64 VName) .<. num_blocks :: TPrimExp Bool VName)- ]-- res1 = disjointTester asserts lessthans lm1 lm_w1- res2 = disjointTester asserts lessthans lm1 lm_w2- in res1 && res2 @? "Failed"- ]
− unittests/Futhark/IR/Mem/IxFunWrapper.hs
@@ -1,72 +0,0 @@--- | Perform index function operations in both algebraic and LMAD--- representations.-module Futhark.IR.Mem.IxFunWrapper- ( IxFun,- iota,- permute,- reshape,- coerce,- slice,- flatSlice,- expand,- )-where--import Control.Monad (join)-import Futhark.IR.Mem.IxFun.Alg qualified as IA-import Futhark.IR.Mem.LMAD qualified as I-import Futhark.IR.Syntax (FlatSlice, Slice)-import Futhark.Util.IntegralExp--type Shape num = [num]--type Permutation = [Int]--type IxFun num = (Maybe (I.LMAD num), IA.IxFun num)--iota ::- (IntegralExp num) =>- Shape num ->- IxFun num-iota x = (Just $ I.iota 0 x, IA.iota x)--permute ::- IxFun num ->- Permutation ->- IxFun num-permute (l, a) x = (I.permute <$> l <*> pure x, IA.permute a x)--reshape ::- (Eq num, IntegralExp num) =>- IxFun num ->- Shape num ->- IxFun num-reshape (l, a) x = (join (I.reshape <$> l <*> pure x), IA.reshape a x)--coerce ::- IxFun num ->- Shape num ->- IxFun num-coerce (l, a) x = (I.coerce <$> l <*> pure x, IA.coerce a x)--slice ::- (Eq num, IntegralExp num) =>- IxFun num ->- Slice num ->- IxFun num-slice (l, a) x = (I.slice <$> l <*> pure x, IA.slice a x)--flatSlice ::- (IntegralExp num) =>- IxFun num ->- FlatSlice num ->- IxFun num-flatSlice (l, a) x = (I.flatSlice <$> l <*> pure x, IA.flatSlice a x)--expand ::- (IntegralExp num) =>- num ->- num ->- IxFun num ->- IxFun num-expand o p (lf, af) = (Just . I.expand o p =<< lf, IA.expand o p af)
− unittests/Futhark/IR/Prop/RearrangeTests.hs
@@ -1,54 +0,0 @@-module Futhark.IR.Prop.RearrangeTests (tests) where--import Control.Applicative-import Futhark.IR.Prop.Rearrange-import Test.Tasty-import Test.Tasty.HUnit-import Test.Tasty.QuickCheck-import Prelude--tests :: TestTree-tests =- testGroup "RearrangeTests" $- isMapTransposeTests- ++ [isMapTransposeProp]--isMapTransposeTests :: [TestTree]-isMapTransposeTests =- [ testCase (unwords ["isMapTranspose", show perm, "==", show dres]) $- isMapTranspose perm @?= dres- | (perm, dres) <-- [ ([0, 1, 4, 5, 2, 3], Just (2, 2, 2)),- ([1, 0, 4, 5, 2, 3], Nothing),- ([1, 0], Just (0, 1, 1)),- ([0, 2, 1], Just (1, 1, 1)),- ([0, 1, 2], Nothing),- ([1, 0, 2], Nothing)- ]- ]--newtype Permutation = Permutation [Int]- deriving (Eq, Ord, Show)--instance Arbitrary Permutation where- arbitrary = do- Positive n <- arbitrary- Permutation <$> shuffle [0 .. n - 1]--isMapTransposeProp :: TestTree-isMapTransposeProp = testProperty "isMapTranspose corresponds to a map of transpose" prop- where- prop :: Permutation -> Bool- prop (Permutation perm) =- case isMapTranspose perm of- Nothing -> True- Just (r1, r2, r3) ->- and- [ r1 >= 0,- r2 > 0,- r3 > 0,- r1 + r2 + r3 == length perm,- let (mapped, notmapped) = splitAt r1 perm- (pretrans, posttrans) = splitAt r2 notmapped- in mapped ++ posttrans ++ pretrans == [0 .. length perm - 1]- ]
− unittests/Futhark/IR/Prop/ReshapeTests.hs
@@ -1,236 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Futhark.IR.Prop.ReshapeTests- ( tests,- )-where--import Data.List qualified as L-import Futhark.IR.Prop.Constants-import Futhark.IR.Prop.Reshape-import Futhark.IR.Syntax-import Futhark.IR.SyntaxTests ()-import Test.Tasty-import Test.Tasty.HUnit--intShape :: [Int] -> Shape-intShape = Shape . map (intConst Int32 . toInteger)--reshapeOuterTests :: [TestTree]-reshapeOuterTests =- [ testCase (unwords ["reshapeOuter", show sc, show n, show shape, "==", show sc_res]) $- reshapeOuter (intShape sc) n (intShape shape) @?= intShape sc_res- | (sc, n, shape, sc_res) <-- [ ([1], 1, [4, 3], [1, 3]),- ([1], 2, [4, 3], [1]),- ([2, 2], 1, [4, 3], [2, 2, 3]),- ([2, 2], 2, [4, 3], [2, 2])- ]- ]--reshapeInnerTests :: [TestTree]-reshapeInnerTests =- [ testCase (unwords ["reshapeInner", show sc, show n, show shape, "==", show sc_res]) $- reshapeInner (intShape sc) n (intShape shape) @?= intShape sc_res- | (sc, n, shape, sc_res) <-- [ ([1], 1, [4, 3], [4, 1]),- ([1], 0, [4, 3], [1]),- ([2, 2], 1, [4, 3], [4, 2, 2]),- ([2, 2], 0, [4, 3], [2, 2])- ]- ]--dimFlatten :: Int -> Int -> d -> DimSplice d-dimFlatten i k w = DimSplice i k (Shape [w])--dimUnflatten :: Int -> [d] -> DimSplice d-dimUnflatten i ws = DimSplice i 1 (Shape ws)--dimCoerce :: Int -> d -> DimSplice d-dimCoerce i w = DimSplice i 1 (Shape [w])--dimSplice :: Int -> Int -> [d] -> DimSplice d-dimSplice i n s = DimSplice i n $ Shape s--flipReshapeRearrangeTests :: [TestTree]-flipReshapeRearrangeTests =- [ testCase- ( unwords- [ "flipReshapeRearrange",- show v0_shape,- show v1_shape,- show perm- ]- )- $ flipReshapeRearrange v0_shape v1_shape perm @?= res- | (v0_shape :: [String], v1_shape, perm, res) <-- [ ( ["A", "B", "C"],- ["A", "BC"],- [1, 0],- Just [1, 2, 0]- ),- ( ["A", "B", "C", "D"],- ["A", "BCD"],- [1, 0],- Just [1, 2, 3, 0]- ),- ( ["A"],- ["B", "C"],- [1, 0],- Nothing- ),- ( ["A", "B", "C"],- ["AB", "C"],- [1, 0],- Just [2, 0, 1]- ),- ( ["A", "B", "C", "D"],- ["ABC", "D"],- [1, 0],- Just [3, 0, 1, 2]- )- ]- ]--flipRearrangeReshapeTests :: [TestTree]-flipRearrangeReshapeTests =- [ testCase- ( unwords- [ "flipRearrangeReshape",- show perm,- prettyStringOneLine newshape- ]- )- $ flipRearrangeReshape perm newshape @?= res- | (perm, newshape :: NewShape String, res) <-- [ ( [1, 0],- NewShape- [dimUnflatten 1 ["B", "C"]]- (Shape ["A", "B", "C"]),- Just- ( NewShape- [dimUnflatten 0 ["B", "C"]]- (Shape ["B", "C", "A"]),- [2, 0, 1]- )- ),- ( [1, 0],- NewShape- [dimFlatten 0 2 "AB"]- (Shape ["AB"]),- Nothing- )- ]- ]--simplifyTests :: TestTree-simplifyTests =- testGroup- "simplifyNewShape"- [ testCase "Inverse flatten and unflatten - simple case" $- lhs- ["A", "B"]- [dimFlatten 0 2 "AB", dimUnflatten 0 ["A", "B"]]- @?= Just [],- testCase "Non-inverse flatten and unflatten - simple case" $- lhs- ["A", "B"]- [dimFlatten 0 2 "AB", dimUnflatten 0 ["C", "D"]]- @?= Just [dimSplice 0 2 ["C", "D"]],- testCase "Inverse flatten and unflatten - separated by coercion" $- lhs- ["A", "B"]- [ dimFlatten 0 2 "AB",- dimCoerce 0 "CD",- dimUnflatten 0 ["C", "D"]- ]- @?= Just [dimSplice 0 2 ["C", "D"]],- testCase "Two unflattens - simple case" $- lhs- ["ABC"]- [dimUnflatten 0 ["A", "BC"], dimUnflatten 1 ["B", "C"]]- @?= Just [dimUnflatten 0 ["A", "B", "C"]],- testCase "Two unflattens with unchanged prefix" $- lhs- ["A", "B", "C", "D", "E"]- [ DimSplice 3 2 $ Shape ["DE"],- DimSplice 2 2 $ Shape ["CDE"]- ]- @?= Just [dimFlatten 2 3 "CDE"],- testCase "Identity coerce" $- lhs- ["A", "B", "C"]- [dimCoerce 1 "B", dimCoerce 2 "C"]- @?= Just [],- testCase "Identity coerce (multiple dimensions)" $- lhs- ["A", "B", "C"]- [DimSplice 1 2 (Shape ["B", "C"])]- @?= Just [],- testCase "Identity coerce (with non-identity stuff afterwards)" $- lhs- ["B", "CD"]- [dimCoerce 0 "B", dimUnflatten 1 ["C", "D"]]- @?= Just [dimUnflatten 1 ["C", "D"]],- testCase "Get rid of a coerce before an unflatten" $- lhs- ["CD"]- [dimCoerce 0 "AB", dimUnflatten 0 ["A", "B"]]- @?= Just [dimUnflatten 0 ["A", "B"]],- testCase "Get rid of a coerce after a flatten" $- lhs- ["A", "B", "C"]- [dimFlatten 0 2 "ABC", dimCoerce 0 "K"]- @?= Just [dimFlatten 0 2 "K"],- testCase "Flatten and unflatten (invariant suffix)" $- lhs- ["A", "B", "C"]- [dimFlatten 0 3 "ABC", dimUnflatten 0 ["D", "E", "C"]]- @?= Just [dimSplice 0 2 ["D", "E"]],- testCase "Flatten and unflatten (invariant prefix)" $- lhs- ["A", "B", "C"]- [dimFlatten 0 3 "ABC", dimUnflatten 0 ["A", "D", "E"]]- @?= Just [dimSplice 1 2 ["D", "E"]],- testCase "Invariant part of splice" $- lhs- ["A", "B", "C", "D"]- [DimSplice 1 3 $ Shape ["BC", "D"]]- @?= Just [DimSplice 1 2 $ Shape ["BC"]],- testCase "Necessary coercion" $- lhs- ["A", "B"]- [dimCoerce 0 "C", dimCoerce 1 "D"]- @?= Nothing,- testCase "Another necessary coercion" $- lhs- ["A", "B", "C"]- [dimCoerce 0 "A'", dimCoerce 1 "A'", dimCoerce 2 "A'"]- @?= Nothing,- testCase "Long with redundancies" $- lhs- ["A", "B", "C", "D"]- [ DimSplice 1 3 $ Shape ["BC", "D"],- dimCoerce 1 "BC",- dimCoerce 2 "D",- dimFlatten 1 2 "BCD",- dimFlatten 0 2 "ABCD"- ]- @?= Just [dimFlatten 0 4 "ABCD"]- ]- where- lhs orig_shape ss =- let res_shape :: ShapeBase String =- L.foldl' applySplice (Shape orig_shape) ss- in dimSplices- <$> simplifyNewShape (Shape orig_shape) (NewShape ss res_shape)--tests :: TestTree-tests =- testGroup "ReshapeTests" . mconcat $- [ reshapeOuterTests,- reshapeInnerTests,- flipReshapeRearrangeTests,- flipRearrangeReshapeTests,- [simplifyTests]- ]
− unittests/Futhark/IR/PropTests.hs
@@ -1,18 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Futhark.IR.PropTests- ( tests,- )-where--import Futhark.IR.Prop.RearrangeTests qualified-import Futhark.IR.Prop.ReshapeTests qualified-import Test.Tasty--tests :: TestTree-tests =- testGroup- "PropTests"- [ Futhark.IR.Prop.ReshapeTests.tests,- Futhark.IR.Prop.RearrangeTests.tests- ]
− unittests/Futhark/IR/Syntax/CoreTests.hs
@@ -1,70 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Futhark.IR.Syntax.CoreTests (tests) where--import Control.Applicative-import Futhark.IR.Pretty (prettyString)-import Futhark.IR.Syntax.Core-import Language.Futhark.CoreTests ()-import Language.Futhark.PrimitiveTests ()-import Test.QuickCheck-import Test.Tasty-import Test.Tasty.HUnit-import Prelude--tests :: TestTree-tests = testGroup "Internal CoreTests" subShapeTests--subShapeTests :: [TestTree]-subShapeTests =- [ shape [free 1, free 2] `isSubShapeOf` shape [free 1, free 2],- shape [free 1, free 3] `isNotSubShapeOf` shape [free 1, free 2],- shape [free 1] `isNotSubShapeOf` shape [free 1, free 2],- shape [free 1, free 2] `isSubShapeOf` shape [free 1, Ext 3],- shape [Ext 1, Ext 2] `isNotSubShapeOf` shape [Ext 1, Ext 1],- shape [Ext 1, Ext 1] `isSubShapeOf` shape [Ext 1, Ext 2]- ]- where- shape :: [ExtSize] -> ExtShape- shape = Shape-- free :: Int -> ExtSize- free = Free . Constant . IntValue . Int32Value . fromIntegral-- isSubShapeOf shape1 shape2 =- subShapeTest shape1 shape2 True- isNotSubShapeOf shape1 shape2 =- subShapeTest shape1 shape2 False-- subShapeTest :: ExtShape -> ExtShape -> Bool -> TestTree- subShapeTest shape1 shape2 expected =- testCase- ( "subshapeOf "- ++ prettyString shape1- ++ " "- ++ prettyString shape2- ++ " == "- ++ show expected- )- $ shape1 `subShapeOf` shape2 @?= expected--instance Arbitrary NoUniqueness where- arbitrary = pure NoUniqueness--instance (Arbitrary shape, Arbitrary u) => Arbitrary (TypeBase shape u) where- arbitrary =- oneof- [ Prim <$> arbitrary,- Array <$> arbitrary <*> arbitrary <*> arbitrary- ]--instance Arbitrary Ident where- arbitrary = Ident <$> arbitrary <*> arbitrary--instance Arbitrary Rank where- arbitrary = Rank <$> elements [1 .. 9]--instance Arbitrary Shape where- arbitrary = Shape . map intconst <$> listOf1 (elements [1 .. 9])- where- intconst = Constant . IntValue . Int32Value
− unittests/Futhark/IR/SyntaxTests.hs
@@ -1,33 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Futhark.IR.SyntaxTests (parseString) where--import Data.String-import Data.Text qualified as T-import Futhark.IR.Parse-import Futhark.IR.Syntax---- There isn't anything to test in this module, but we define some--- convenience instances.--parseString :: String -> (FilePath -> T.Text -> Either T.Text a) -> String -> a-parseString desc p =- either (error . T.unpack) id . p ("IsString " <> desc) . T.pack--instance IsString Type where- fromString = parseString "Type" parseType--instance IsString DeclExtType where- fromString = parseString "DeclExtType" parseDeclExtType--instance IsString DeclType where- fromString = parseString "DeclType" parseDeclType--instance IsString VName where- fromString = parseString "VName" parseVName--instance IsString SubExp where- fromString = parseString "SubExp" parseSubExp--instance IsString SubExpRes where- fromString = parseString "SubExpRes" parseSubExpRes
− unittests/Futhark/Internalise/TypesValuesTests.hs
@@ -1,170 +0,0 @@-module Futhark.Internalise.TypesValuesTests (tests) where--import Control.Monad.Free (Free (..))-import Data.Map qualified as M-import Data.String (fromString)-import Futhark.IR.Syntax hiding (Free)-import Futhark.IR.SyntaxTests ()-import Futhark.Internalise.TypesValues-import Language.Futhark.SyntaxTests ()-import Test.Tasty-import Test.Tasty.HUnit--internaliseTypeTests :: TestTree-internaliseTypeTests =- testGroup- "internaliseType"- [ mkTest- "[0]()"- [Free [Pure "[0i64]unit"]],- mkTest- "{a: [t_7447][n_7448](f32, f32), b: i64, c: i64}"- [Free [Pure "[t_7447][n_7448]f32", Pure "[t_7447][n_7448]f32"], Pure "i64", Pure "i64"],- mkTest- "([0]i32, {a: f32, b: f32, c: f32, d: [0]((f32, f32), (f32, f32))})"- [ Free [Pure "[0i64]i32"],- Pure "f32",- Pure "f32",- Pure "f32",- Free [Pure "[0i64]f32", Pure "[0i64]f32", Pure "[0i64]f32", Pure "[0i64]f32"]- ],- mkTest- "[0]([1]i32, f32)"- [Free [Free [Pure "[0i64][1i64]i32"], Pure "[0i64]f32"]]- ]- where- mkTest x y =- testCase (prettyString x) $ internaliseType x @?= y--sumTypeTests :: TestTree-sumTypeTests =- testGroup- "internaliseConstructors"- [ testCase "Dedup of primitives" $- internaliseConstructors- ( M.fromList- [ ("foo", [Pure "i64"]),- ("bar", [Pure "i64"])- ]- )- @?= ( [Pure "i64"],- [ ("bar", [0]),- ("foo", [0])- ]- ),- testCase "Dedup of array" $- internaliseConstructors- ( M.fromList- [ ("foo", [Pure "[?0]i64"]),- ("bar", [Pure "[?0]i64"])- ]- )- @?= ( [Pure "[?0]i64", Pure "[?0]i64"],- [ ("bar", [0]),- ("foo", [1])- ]- ),- testCase- "Dedup of array of tuple"- $ internaliseConstructors- ( M.fromList- [ ("foo", [Free [Pure "[?0]i64", Pure "[?0]i64"]]),- ("bar", [Pure "[?0]i64"])- ]- )- @?= ( [Pure "[?0]i64", Free [Pure "[?0]i64", Pure "[?0]i64"]],- [ ("bar", [0]),- ("foo", [1, 2])- ]- )- ]---- Be aware that some of these tests simply reinforce current--- behaviour - it may be that we want to restrict aliasing even--- further in the future; these tests would have to be updated in such--- cases.-inferAliasesTests :: TestTree-inferAliasesTests =- testGroup- "inferAliases"- [ mkTest- [Free [Pure "[0i64]i32"]]- [Free [Pure "[?0]i32"]]- [[("[?0]i32", RetAls [0] [0])]],- mkTest- [Free [Pure "[0i64]i32", Pure "[0i64]i32"]]- [Free [Pure "[0i64]i32", Pure "[0i64]i32"]]- [ [ ("[0i64]i32", RetAls [0] [0]),- ("[0i64]i32", RetAls [1] [1])- ]- ],- -- Basically zip.- mkTest- [Free [Pure "[n_0]i32"], Free [Pure "[n_0]i32"]]- [Free [Pure "[n_0]i32", Pure "[n_0]i32"]]- [ [ ("[n_0]i32", RetAls [] [0]),- ("[n_0]i32", RetAls [] [1])- ]- ],- mkTest- [Free [Pure "[0i64]i32"], Free [Pure "[0i64]i32", Pure "[0i64]i32"]]- [Free [Pure "[?0]i32", Pure "[?0]i32"]]- [ [ ("[?0]i32", RetAls [1] [0]),- ("[?0]i32", RetAls [2] [1])- ]- ],- mkTest- [Free [Pure "[0i64][1i64]i32", Pure "[0i64][1i64]i32"]]- [Free [Pure "[?0]i32", Pure "[?0]i32"]]- [ [ ("[?0]i32", RetAls [0] [0]),- ("[?0]i32", RetAls [1] [1])- ]- ],- -- Basically unzip.- mkTest- [Free [Pure "[n_0][n_1]i32", Pure "[n_0][n_1]i32"]]- [Free [Pure "[?0]i32"], Free [Pure "[?0]i32"]]- [ [("[?0]i32", RetAls [] [0, 1])],- [("[?0]i32", RetAls [] [0, 1])]- ],- mkTest- [ Free [Pure "*[n_0][n_1]i32"],- Free [Pure "[n_2]i64"],- Free [Pure "[n_3]i64"]- ]- [Free [Pure "*[n_0][n_1]i32"]]- [[("*[n_0][n_1]i32", RetAls [] [])]],- mkTest- [Free [Pure "[n_0]i32", Free [Pure "[n_0][n_1]i32"]]]- [Free [Pure "[n_0]i32"]]- [[("[n_0]i32", RetAls [1] [0])]],- mkTest- []- [ Free [Pure "[n_0]i32", Free [Pure "[n_0][n_1]i32"]],- Free [Pure "[n_0]i32"]- ]- [ [("[n_0]i32", RetAls [] [0]), ("[n_0][n_1]i32", RetAls [] [1])],- [("[n_0]i32", RetAls [] [1, 2])]- ],- mkTest- [Free [Pure "[n_0]i32"]]- [Free [Pure "[m_1][m_1]i32"]]- [ [("[m_1][m_1]i32", RetAls [0] [0])]- ]- ]- where- mkTest all_param_ts all_res_ts expected =- testCase (show all_param_ts <> " " <> show all_res_ts) $- inferAliases- (map (fmap fromString) all_param_ts)- (map (fmap fromString) all_res_ts)- @?= expected--tests :: TestTree-tests =- testGroup- "Futhark.Internalise.TypesValuesTests"- [ internaliseTypeTests,- sumTypeTests,- inferAliasesTests- ]
− unittests/Futhark/Optimise/ArrayLayout/AnalyseTests.hs
@@ -1,241 +0,0 @@-module Futhark.Optimise.ArrayLayout.AnalyseTests (tests) where--import Data.Map.Strict qualified as M-import Futhark.Analysis.AccessPattern-import Futhark.IR.GPU-import Futhark.IR.GPUTests ()-import Futhark.IR.SyntaxTests ()-import Test.Tasty-import Test.Tasty.HUnit--tests :: TestTree-tests = testGroup "Analyse" [analyseStmTests]--analyseStmTests :: TestTree-analyseStmTests =- testGroup- "analyseStm"- [analyseIndexTests, analyseDimAccessesTests]--analyseIndexTests :: TestTree-analyseIndexTests =- testGroup- "analyseIndex"- $ do- let arr_name = "xss_5144"- -- ============================= TestCase0 =============================- -- Most simple case where we want to manifest an array, hence, we record- -- the Index in the IndexTable.- let testCase0 = testCase "2D manifest" $ do- let ctx =- mempty- { parents =- [ SegOpName (SegmentedMap "defunc_0_map_res_5204"),- LoopBodyName "defunc_0_f_res_5208"- ],- assignments =- M.fromList- [ ("gtid_5205", VariableInfo mempty 0 mempty ThreadID),- ("i_5209", VariableInfo mempty 1 mempty LoopVar)- ]- }- let patternNames = ["b_5211"]- let dimFixes =- [ DimFix (Var "gtid_5205"),- DimFix (Var "i_5209")- ]- let indexTable =- M.fromList- [ ( SegmentedMap "defunc_0_map_res_5204",- M.fromList- [ ( (arr_name, [], [0 .. 1]),- M.fromList- [ ( "b_5211",- [ DimAccess (M.fromList [("gtid_5205", Dependency 0 ThreadID)]) (Just "gtid_5205"),- DimAccess (M.fromList [("i_5209", Dependency 1 LoopVar)]) (Just "i_5209")- ]- )- ]- )- ]- )- ]- let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes- indexTable' @?= indexTable-- -- ============================= TestCase2 =============================- -- We don't want to manifest an array with only one dimension, so we don't- -- record anything in the IndexTable.- let testCase1 = testCase "1D manifest" $ do- let ctx =- mempty- { parents =- [ SegOpName (SegmentedMap "defunc_0_map_res_5204"),- LoopBodyName "defunc_0_f_res_5208"- ]- }- let patternNames = ["b_5211"]- let dimFixes = [DimFix "i_5209"]-- let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes- indexTable' @?= mempty-- -- ============================= TestCase1 =============================- -- We don't want to record anything to the IndexTable when the array is- -- not accessed inside a SegMap- -- TODO: Create a similar one for MC with loops- let testCase2 = testCase "Not inside SegMap" $ do- let ctx = mempty- let patternNames = ["b_5211"]- let dimFixes =- [ DimFix "gtid_5205",- DimFix "i_5209"- ]- let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes- indexTable' @?= mempty-- -- ============================= TestCase3 =============================- -- If an array is allocated inside a loop or SegMap, we want to record that- -- information in the ArrayName of the IndexTable.- let testCase3 = testCase "Allocated inside SegMap" $ do- let parents' =- [ SegOpName (SegmentedMap "defunc_0_map_res_5204"),- LoopBodyName "defunc_0_f_res_5208"- ]- let ctx =- mempty- { parents = parents',- assignments =- M.fromList- [ ("gtid_5205", VariableInfo mempty 0 mempty ThreadID),- ("i_5209", VariableInfo mempty 1 mempty LoopVar),- (arr_name, VariableInfo mempty 0 parents' Variable)- ]- }- let patternNames = ["b_5211"]- let dimFixes =- [ DimFix "gtid_5205",- DimFix "i_5209"- ]- let indexTable =- M.fromList- [ ( SegmentedMap "defunc_0_map_res_5204",- M.fromList- [ ( (arr_name, parents', [0 .. 1]),- M.fromList- [ ( "b_5211",- [ DimAccess (M.fromList [("gtid_5205", Dependency 0 ThreadID)]) (Just "gtid_5205"),- DimAccess (M.fromList [("i_5209", Dependency 1 LoopVar)]) (Just "i_5209")- ]- )- ]- )- ]- )- ]- let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes- indexTable' @?= indexTable-- -- ============================= TestCase4 =============================- -- If the vars in the index are temporaries, we want to reduce them to- -- to the thread IDs and or loop counters they are functions of.- let testCase4 = testCase "Reduce dependencies" $ do- let ctx =- mempty- { parents =- [ SegOpName (SegmentedMap "defunc_0_map_res_5204"),- LoopBodyName "defunc_0_f_res_5208"- ],- assignments =- M.fromList- [ ("gtid_5205", VariableInfo mempty 0 mempty ThreadID),- ("i_5209", VariableInfo mempty 1 mempty LoopVar),- ("tmp0_5210", VariableInfo (namesFromList ["gtid_5205"]) 2 mempty Variable),- ("tmp1_5211", VariableInfo (namesFromList ["i_5209"]) 3 mempty Variable),- ("k_5212", VariableInfo mempty 1 mempty ConstType)- ]- }- let patternNames = ["b_5211"]- let dimFixes =- [ DimFix "tmp0_5210",- DimFix "tmp1_5211",- DimFix "k_5212"- ]- let indexTable =- M.fromList- [ ( SegmentedMap "defunc_0_map_res_5204",- M.fromList- [ ( (arr_name, [], [0 .. 2]),- M.fromList- [ ( "b_5211",- [ DimAccess (M.fromList [("gtid_5205", Dependency 0 ThreadID)]) (Just "tmp0_5210"),- DimAccess (M.fromList [("i_5209", Dependency 1 LoopVar)]) (Just "tmp1_5211"),- DimAccess mempty (Just "k_5212")- ]- )- ]- )- ]- )- ]- let (_, indexTable') = analyseIndex ctx patternNames arr_name dimFixes- indexTable' @?= indexTable-- [testCase0, testCase1, testCase2, testCase3, testCase4]--analyseDimAccessesTests :: TestTree-analyseDimAccessesTests = testGroup- "analyseDimAccesses"- $ do- let testCase0 = testCase "Fold" $ do- let indexTable =- M.fromList- [ ( SegmentedMap "defunc_0_map_res_5204",- M.fromList- [ ( ("xss_5144", [], [0, 1]),- M.fromList- [ ( "b_5211",- [ DimAccess (M.fromList [("gtid_5205", Dependency 0 ThreadID)]) (Just "gtid_5205"),- DimAccess (M.fromList [("i_5209", Dependency 1 LoopVar)]) (Just "i_5209")- ]- )- ]- )- ]- )- ]- let indexTable' = (analyseDimAccesses @GPU) prog0- indexTable' @?= indexTable-- [testCase0]- where- prog0 :: Prog GPU- prog0 =- "\- \entry(\"main\",\- \ {xss: [][]i64},\- \ {[]i64})\- \ entry_main (n_5142 : i64,\- \ m_5143 : i64,\- \ xss_5144 : [n_5142][m_5143]i64)\- \ : {[n_5142]i64#([2], [0])} = {\- \ let {segmap_group_size_5202 : i64} =\- \ get_size(segmap_group_size_5190, thread_block_size)\- \ let {segmap_usable_groups_5203 : i64} =\- \ sdiv_up64(n_5142, segmap_group_size_5202)\- \ let {defunc_0_map_res_5204 : [n_5142]i64} =\- \ segmap(thread; ; grid=segmap_usable_groups_5203; blocksize=segmap_group_size_5202)\- \ (gtid_5205 < n_5142) (~phys_tid_5206) : {i64} {\- \ let {defunc_0_f_res_5208 : i64} =\- \ loop {acc_5210 : i64} = {0i64}\- \ for i_5209:i64 < m_5143 do {\- \ let {b_5211 : i64} =\- \ xss_5144[gtid_5205, i_5209]\- \ let {defunc_0_f_res_5212 : i64} =\- \ add64(acc_5210, b_5211)\- \ in {defunc_0_f_res_5212}\- \ }\- \ return {returns defunc_0_f_res_5208}\- \ }\- \ in {defunc_0_map_res_5204}\- \}"
− unittests/Futhark/Optimise/ArrayLayout/LayoutTests.hs
@@ -1,163 +0,0 @@-module Futhark.Optimise.ArrayLayout.LayoutTests (tests) where--import Data.Map.Strict qualified as M-import Futhark.Analysis.AccessPattern-import Futhark.Analysis.PrimExp-import Futhark.FreshNames-import Futhark.IR.GPU (GPU)-import Futhark.IR.GPUTests ()-import Futhark.Optimise.ArrayLayout.Layout-import Language.Futhark.Core-import Test.Tasty-import Test.Tasty.HUnit--tests :: TestTree-tests =- testGroup- "Layout"- [commonPermutationEliminatorsTests]--commonPermutationEliminatorsTests :: TestTree-commonPermutationEliminatorsTests =- testGroup- "commonPermutationEliminators"- [permutationTests, nestTests, dimAccessTests, constIndexElimTests]--permutationTests :: TestTree-permutationTests =- testGroup "Permutations" $- do- -- This isn't the way to test this, in reality we should provide realistic- -- access patterns that might result in the given permutations.- -- Luckily we only use the original access for one check atm.- [ testCase (unwords [show perm, "->", show res]) $- commonPermutationEliminators perm [] @?= res- | (perm, res) <-- [ ([0], True),- ([1, 0], False),- ([0, 1], True),- ([0, 0], True),- ([1, 1], True),- ([1, 2, 0], False),- ([2, 0, 1], False),- ([0, 1, 2], True),- ([1, 0, 2], True),- ([2, 1, 0], True),- ([2, 2, 0], True),- ([2, 1, 1], True),- ([1, 0, 1], True),- ([0, 0, 0], True),- ([0, 1, 2, 3, 4], True),- ([1, 0, 2, 3, 4], True),- ([2, 3, 0, 1, 4], True),- ([3, 4, 2, 0, 1], True),- ([2, 3, 4, 0, 1], False),- ([1, 2, 3, 4, 0], False),- ([3, 4, 0, 1, 2], False)- ]- ]--nestTests :: TestTree-nestTests = testGroup "Nests" $- do- let names = generateNames 2- [ testCase (unwords [args, "->", show res]) $- commonPermutationEliminators [1, 0] nest @?= res- | (args, nest, res) <-- [ ("[]", [], False),- ("[CondBodyName]", [CondBodyName] <*> names, False),- ("[SegOpName]", [SegOpName . SegmentedMap] <*> names, True),- ("[LoopBodyName]", [LoopBodyName] <*> names, False),- ("[SegOpName, CondBodyName]", [SegOpName . SegmentedMap, CondBodyName] <*> names, True),- ("[CondBodyName, LoopBodyName]", [CondBodyName, LoopBodyName] <*> names, False)- ]- ]--dimAccessTests :: TestTree-dimAccessTests = testGroup "DimAccesses" [] -- TODO: Write tests for the part of commonPermutationEliminators that checks the complexity of the DimAccesses.--constIndexElimTests :: TestTree-constIndexElimTests =- testGroup- "constIndexElimTests"- [ testCase "gpu eliminates indexes with constant in any dim" $ do- let primExpTable =- M.fromList- [ ("gtid_4", Just (LeafExp "n_4" (IntType Int64))),- ("i_5", Just (LeafExp "n_4" (IntType Int64)))- ]- layoutTableFromIndexTable primExpTable accessTableGPU @?= mempty,- testCase "gpu ignores when not last" $ do- let primExpTable =- M.fromList- [ ("gtid_4", Just (LeafExp "gtid_4" (IntType Int64))),- ("gtid_5", Just (LeafExp "gtid_5" (IntType Int64))),- ("i_6", Just (LeafExp "i_6" (IntType Int64)))- ]- layoutTableFromIndexTable primExpTable accessTableGPUrev- @?= M.fromList- [ ( SegmentedMap "mapres_1",- M.fromList- [ ( ("a_2", [], [0, 1, 2, 3]),- M.fromList [("A_3", [2, 3, 0, 1])]- )- ]- )- ]- ]- where- accessTableGPU :: IndexTable GPU- accessTableGPU =- singleAccess- [ singleParAccess 0 "gtid_4",- DimAccess mempty Nothing,- singleSeqAccess 1 "i_5"- ]-- accessTableGPUrev :: IndexTable GPU- accessTableGPUrev =- singleAccess- [ singleParAccess 1 "gtid_4",- singleParAccess 2 "gtid_5",- singleSeqAccess 0 "i_5",- singleSeqAccess 2 "gtid_4"- ]--singleAccess :: [DimAccess rep] -> IndexTable rep-singleAccess dims =- M.fromList- [ ( sgOp,- M.fromList- [ ( ("A_2", [], [0, 1, 2, 3]),- M.fromList- [ ( "a_3",- dims- )- ]- )- ]- )- ]- where- sgOp = SegmentedMap {vnameFromSegOp = "mapres_1"}--singleParAccess :: Int -> VName -> DimAccess rep-singleParAccess level name =- DimAccess- (M.singleton name $ Dependency level ThreadID)- (Just name)--singleSeqAccess :: Int -> VName -> DimAccess rep-singleSeqAccess level name =- DimAccess- (M.singleton name $ Dependency level LoopVar)- (Just name)--generateNames :: Int -> [VName]-generateNames count = do- let (name, source) = newName blankNameSource "i_0"- fst $ foldl f ([name], source) [1 .. count - 1]- where- f (names, source) _ = do- let (name, source') = newName source (last names)- (names ++ [name], source')
− unittests/Futhark/Optimise/ArrayLayoutTests.hs
@@ -1,15 +0,0 @@-module Futhark.Optimise.ArrayLayoutTests (tests) where--import Futhark.Analysis.PrimExp.TableTests qualified-import Futhark.Optimise.ArrayLayout.AnalyseTests qualified-import Futhark.Optimise.ArrayLayout.LayoutTests qualified-import Test.Tasty--tests :: TestTree-tests =- testGroup- "OptimizeArrayLayoutTests"- [ Futhark.Optimise.ArrayLayout.AnalyseTests.tests,- Futhark.Optimise.ArrayLayout.LayoutTests.tests,- Futhark.Analysis.PrimExp.TableTests.tests- ]
− unittests/Futhark/Optimise/MemoryBlockMerging/GreedyColoringTests.hs
@@ -1,80 +0,0 @@-module Futhark.Optimise.MemoryBlockMerging.GreedyColoringTests- ( tests,- )-where--import Control.Arrow ((***))-import Data.Function ((&))-import Data.Map qualified as M-import Data.Set qualified as S-import Futhark.Optimise.MemoryBlockMerging.GreedyColoring qualified as GreedyColoring-import Test.Tasty-import Test.Tasty.HUnit--tests :: TestTree-tests =- testGroup- "GreedyColoringTests"- [psumTest, allIntersect, emptyGraph, noIntersections, differentSpaces]--psumTest :: TestTree-psumTest =- testCase "psumTest"- $ assertEqual- "Color simple 1-2-3 using two colors"- ( [(0, "shared"), (1, "shared")] :: [(Int, String)],- [(1 :: Int, 0), (2, 1), (3, 0)]- )- $ (M.toList *** M.toList)- $ GreedyColoring.colorGraph- (M.fromList [(1, "shared"), (2, "shared"), (3, "shared")])- $ S.fromList [(1, 2), (2, 3)]--allIntersect :: TestTree-allIntersect =- testCase "allIntersect"- $ assertEqual- "Color a graph where all values intersect"- ( [(0, "shared"), (1, "shared"), (2, "shared")] :: [(Int, String)],- [(1 :: Int, 2), (2, 1), (3, 0)]- )- $ (M.toList *** M.toList)- $ GreedyColoring.colorGraph- (M.fromList [(1, "shared"), (2, "shared"), (3, "shared")])- $ S.fromList [(1, 2), (2, 3), (1, 3)]--emptyGraph :: TestTree-emptyGraph =- testCase "emptyGraph"- $ assertEqual- "Color an empty graph"- ([] :: [(Int, Char)], [] :: [(Int, Int)])- $ (M.toList *** M.toList)- $ GreedyColoring.colorGraph M.empty- $ S.fromList []--noIntersections :: TestTree-noIntersections =- GreedyColoring.colorGraph- (M.fromList [(1, "shared"), (2, "shared"), (3, "shared")])- (S.fromList [])- & M.toList *** M.toList- & assertEqual- "Color nodes with no intersections"- ( [(0, "shared")] :: [(Int, String)],- [(1, 0), (2, 0), (3, 0)] :: [(Int, Int)]- )- & testCase "noIntersections"--differentSpaces :: TestTree-differentSpaces =- GreedyColoring.colorGraph- (M.fromList [(1, "a"), (2, "b"), (3, "c")])- (S.fromList [])- & M.toList *** M.toList- & assertEqual- "Color nodes with no intersections but in different spaces"- ( [(0, "c"), (1, "b"), (2, "a")] :: [(Int, String)],- [(1, 2), (2, 1), (3, 0)] :: [(Int, Int)]- )- & testCase "differentSpaces"
− unittests/Futhark/Pkg/SolveTests.hs
@@ -1,142 +0,0 @@-module Futhark.Pkg.SolveTests (tests) where--import Data.Map qualified as M-import Data.Monoid-import Data.Text qualified as T-import Futhark.Pkg.Solve-import Futhark.Pkg.Types-import Test.Tasty-import Test.Tasty.HUnit-import Prelude--semverE :: T.Text -> SemVer-semverE s = case parseVersion s of- Left err ->- error $- T.unpack s- <> " is not a valid version number: "- <> errorBundlePretty err- Right x -> x---- | A world of packages and interdependencies for testing the solver--- without touching the outside world.-testEnv :: PkgRevDepInfo-testEnv =- M.fromList $- concatMap- frob- [ ( "athas",- [ ( "foo",- [ ("0.1.0", []),- ("0.2.0", [("athas/bar", "1.0.0")]),- ("0.3.0", [])- ]- ),- ("foo@v2", [("2.0.0", [("athas/quux", "0.1.0")])]),- ("bar", [("1.0.0", [])]),- ("baz", [("0.1.0", [("athas/foo", "0.3.0")])]),- ( "quux",- [ ( "0.1.0",- [ ("athas/foo", "0.2.0"),- ("athas/baz", "0.1.0")- ]- )- ]- ),- ( "quux_perm",- [ ( "0.1.0",- [ ("athas/baz", "0.1.0"),- ("athas/foo", "0.2.0")- ]- )- ]- ),- ("x_bar", [("1.0.0", [("athas/bar", "1.0.0")])]),- ("x_foo", [("1.0.0", [("athas/foo", "0.3.0")])]),- ( "tricky",- [ ( "1.0.0",- [ ("athas/foo", "0.2.0"),- ("athas/x_foo", "1.0.0")- ]- )- ]- )- ]- ),- -- Some mutually recursive packages.- ( "nasty",- [ ("foo", [("1.0.0", [("nasty/bar", "1.0.0")])]),- ("bar", [("1.0.0", [("nasty/foo", "1.0.0")])])- ]- )- ]- where- frob (user, repos) = do- (repo, repo_revs) <- repos- (rev, deps) <- repo_revs- let rev' = semverE rev- onDep (dp, dv) = (dp, (semverE dv, Nothing))- deps' = PkgRevDeps $ M.fromList $ map onDep deps- pure ((user <> "/" <> repo, rev'), deps')--newtype SolverRes = SolverRes BuildList- deriving (Eq)--instance Show SolverRes where- show (SolverRes bl) = T.unpack $ prettyBuildList bl--solverTest :: PkgPath -> T.Text -> Either T.Text [(PkgPath, T.Text)] -> TestTree-solverTest p v expected =- testCase (T.unpack $ p <> "-" <> prettySemVer v') $- fmap SolverRes (solveDepsPure testEnv target)- @?= expected'- where- target = PkgRevDeps $ M.singleton p (v', Nothing)- v' = semverE v- expected' = SolverRes . BuildList . M.fromList . map onRes <$> expected- onRes (dp, dv) = (dp, semverE dv)--tests :: TestTree-tests =- testGroup- "SolveTests"- [ solverTest "athas/foo" "0.1.0" $- Right [("athas/foo", "0.1.0")],- solverTest "athas/foo" "0.2.0" $- Right- [ ("athas/foo", "0.2.0"),- ("athas/bar", "1.0.0")- ],- solverTest "athas/quux" "0.1.0" $- Right- [ ("athas/quux", "0.1.0"),- ("athas/foo", "0.3.0"),- ("athas/baz", "0.1.0")- ],- solverTest "athas/quux_perm" "0.1.0" $- Right- [ ("athas/quux_perm", "0.1.0"),- ("athas/foo", "0.3.0"),- ("athas/baz", "0.1.0")- ],- solverTest "athas/foo@v2" "2.0.0" $- Right- [ ("athas/foo@v2", "2.0.0"),- ("athas/quux", "0.1.0"),- ("athas/foo", "0.3.0"),- ("athas/baz", "0.1.0")- ],- solverTest "athas/foo@v3" "3.0.0" $- Left "Unknown package/version: athas/foo@v3-3.0.0",- solverTest "nasty/foo" "1.0.0" $- Right- [ ("nasty/foo", "1.0.0"),- ("nasty/bar", "1.0.0")- ],- solverTest "athas/tricky" "1.0.0" $- Right- [ ("athas/tricky", "1.0.0"),- ("athas/foo", "0.3.0"),- ("athas/x_foo", "1.0.0")- ]- ]
− unittests/Futhark/ProfileTests.hs
@@ -1,23 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Futhark.ProfileTests () where--import Data.Map qualified as M-import Data.Text qualified as T-import Futhark.Profile-import Test.Tasty.QuickCheck--printable :: Gen String-printable = getPrintableString <$> arbitrary--arbText :: Gen T.Text-arbText = T.pack <$> printable--instance Arbitrary ProfilingEvent where- arbitrary = ProfilingEvent <$> arbText <*> arbitrary <*> arbText--instance Arbitrary ProfilingReport where- arbitrary =- ProfilingReport- <$> arbitrary- <*> (M.fromList <$> listOf ((,) <$> arbText <*> arbitrary))
− unittests/Language/Futhark/CoreTests.hs
@@ -1,13 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Language.Futhark.CoreTests () where--import Language.Futhark.Core-import Language.Futhark.PrimitiveTests ()-import Test.QuickCheck--instance Arbitrary Name where- arbitrary = nameFromString <$> listOf1 (elements ['a' .. 'z'])--instance Arbitrary VName where- arbitrary = VName <$> arbitrary <*> arbitrary
− unittests/Language/Futhark/PrimitiveTests.hs
@@ -1,76 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Language.Futhark.PrimitiveTests- ( tests,- arbitraryPrimValOfType,- )-where--import Control.Applicative-import Futhark.Util (convFloat)-import Language.Futhark.Primitive-import Test.QuickCheck-import Test.Tasty-import Test.Tasty.HUnit-import Prelude--tests :: TestTree-tests = testGroup "PrimitiveTests" [propPrimValuesHaveRightType]--propPrimValuesHaveRightType :: TestTree-propPrimValuesHaveRightType =- testGroup- "propPrimValuesHaveRightTypes"- [ testCase (show t ++ " has blank of right type") $- primValueType (blankPrimValue t) @?= t- | t <- [minBound .. maxBound]- ]--instance Arbitrary IntType where- arbitrary = elements [minBound .. maxBound]--instance Arbitrary FloatType where- arbitrary = elements [minBound .. maxBound]--instance Arbitrary PrimType where- arbitrary = elements [minBound .. maxBound]--instance Arbitrary IntValue where- arbitrary =- oneof- [ Int8Value <$> arbitrary,- Int16Value <$> arbitrary,- Int32Value <$> arbitrary,- Int64Value <$> arbitrary- ]--instance Arbitrary Half where- arbitrary = (convFloat :: Float -> Half) <$> arbitrary--instance Arbitrary FloatValue where- arbitrary =- oneof- [ Float16Value <$> arbitrary,- Float32Value <$> arbitrary,- Float64Value <$> arbitrary- ]--instance Arbitrary PrimValue where- arbitrary =- oneof- [ IntValue <$> arbitrary,- FloatValue <$> arbitrary,- BoolValue <$> arbitrary,- pure UnitValue- ]--arbitraryPrimValOfType :: PrimType -> Gen PrimValue-arbitraryPrimValOfType (IntType Int8) = IntValue . Int8Value <$> arbitrary-arbitraryPrimValOfType (IntType Int16) = IntValue . Int16Value <$> arbitrary-arbitraryPrimValOfType (IntType Int32) = IntValue . Int32Value <$> arbitrary-arbitraryPrimValOfType (IntType Int64) = IntValue . Int64Value <$> arbitrary-arbitraryPrimValOfType (FloatType Float16) = FloatValue . Float16Value <$> arbitrary-arbitraryPrimValOfType (FloatType Float32) = FloatValue . Float32Value <$> arbitrary-arbitraryPrimValOfType (FloatType Float64) = FloatValue . Float32Value <$> arbitrary-arbitraryPrimValOfType Bool = BoolValue <$> arbitrary-arbitraryPrimValOfType Unit = pure UnitValue
− unittests/Language/Futhark/SemanticTests.hs
@@ -1,24 +0,0 @@-module Language.Futhark.SemanticTests (tests) where--import Language.Futhark (ImportName (..))-import Language.Futhark.Semantic-import Test.Tasty-import Test.Tasty.HUnit--tests :: TestTree-tests =- testGroup- "Semantic objects"- [ testCase "a" $- mkInitialImport "a" @?= ImportName "a",- testCase "./a" $- mkInitialImport "./a" @?= ImportName "a",- testCase "a/b -> ../c" $- mkImportFrom (mkInitialImport "a/b") "../c" @?= ImportName "c",- testCase "a/b -> ../../c" $- mkImportFrom (mkInitialImport "a/b") "../../c" @?= ImportName "../c",- testCase "../a -> b" $- mkImportFrom (mkInitialImport "../a") "b" @?= ImportName "../b",- testCase "../a -> ../b" $- mkImportFrom (mkInitialImport "../a") "../b" @?= ImportName "../../b"- ]
− unittests/Language/Futhark/SyntaxTests.hs
@@ -1,208 +0,0 @@-{-# OPTIONS_GHC -fno-warn-orphans #-}--module Language.Futhark.SyntaxTests (tests) where--import Control.Applicative hiding (many, some)-import Data.Bifunctor-import Data.Char (isAlpha)-import Data.Functor-import Data.Map qualified as M-import Data.String-import Data.Text qualified as T-import Data.Void-import Language.Futhark-import Language.Futhark.Parser-import Language.Futhark.Primitive.Parse (constituent, keyword, lexeme)-import Language.Futhark.PrimitiveTests ()-import Test.QuickCheck-import Test.Tasty-import Text.Megaparsec-import Text.Megaparsec.Char.Lexer qualified as L-import Prelude--tests :: TestTree-tests = testGroup "Source SyntaxTests" []--instance Arbitrary BinOp where- arbitrary = elements [minBound .. maxBound]--instance Arbitrary Uniqueness where- arbitrary = elements [Unique, Nonunique]--instance Arbitrary PrimType where- arbitrary =- oneof- [ Signed <$> arbitrary,- Unsigned <$> arbitrary,- FloatType <$> arbitrary,- pure Bool- ]--instance Arbitrary PrimValue where- arbitrary =- oneof- [ SignedValue <$> arbitrary,- UnsignedValue <$> arbitrary,- FloatValue <$> arbitrary,- BoolValue <$> arbitrary- ]---- The following dirty instances make it slightly nicer to write unit tests.--instance IsString VName where- fromString s =- let (s', '_' : tag) = span (/= '_') s- in VName (fromString s') (read tag)--instance (IsString v) => IsString (QualName v) where- fromString = QualName [] . fromString--instance IsString UncheckedTypeExp where- fromString =- either (error . T.unpack . syntaxErrorMsg) id- . parseType "IsString UncheckedTypeExp"- . fromString--type Parser = Parsec Void T.Text--braces, brackets, parens :: Parser a -> Parser a-braces = between (lexeme "{") (lexeme "}")-brackets = between (lexeme "[") (lexeme "]")-parens = between (lexeme "(") (lexeme ")")--pName :: Parser Name-pName =- lexeme . fmap nameFromString $- (:) <$> satisfy isAlpha <*> many (satisfy constituent)--pVName :: Parser VName-pVName = lexeme $ do- (s, tag) <-- satisfy constituent- `manyTill_` try pTag- <?> "variable name"- pure $ VName (nameFromString s) tag- where- pTag =- "_" *> L.decimal <* notFollowedBy (satisfy constituent)--pQualName :: Parser (QualName VName)-pQualName = QualName [] <$> pVName--pPrimType :: Parser PrimType-pPrimType =- choice $- map- f- [ Bool,- Signed Int8,- Signed Int16,- Signed Int32,- Signed Int64,- Unsigned Int8,- Unsigned Int16,- Unsigned Int32,- Unsigned Int64,- FloatType Float32,- FloatType Float64- ]- where- f t = keyword (prettyText t) $> t--pUniqueness :: Parser Uniqueness-pUniqueness = choice [lexeme "*" $> Unique, pure Nonunique]--pSize :: Parser Size-pSize =- brackets $- choice- [ flip sizeFromInteger mempty <$> lexeme L.decimal,- flip sizeFromName mempty <$> pQualName- ]--pScalarNonFun :: Parser (ScalarTypeBase Size Uniqueness)-pScalarNonFun =- choice- [ Prim <$> pPrimType,- pTypeVar,- tupleRecord <$> parens (pType `sepBy` lexeme ","),- Record . M.fromList <$> braces (pField `sepBy1` lexeme ",")- ]- where- pField = (,) <$> pName <* lexeme ":" <*> pType- pTypeVar = TypeVar <$> pUniqueness <*> pQualName <*> many pTypeArg- pTypeArg =- choice- [ TypeArgDim <$> pSize,- TypeArgType . second (const NoUniqueness) <$> pTypeArgType- ]- pTypeArgType =- choice- [ Scalar . Prim <$> pPrimType,- parens pType- ]--pArrayType :: Parser ResType-pArrayType =- Array- <$> pUniqueness- <*> (Shape <$> some pSize)- <*> (second (const NoUniqueness) <$> pScalarNonFun)--pNonFunType :: Parser ResType-pNonFunType =- choice- [ try pArrayType,- try $ parens pType,- Scalar <$> pScalarNonFun- ]--pScalarType :: Parser (ScalarTypeBase Size Uniqueness)-pScalarType = choice [try pFun, pScalarNonFun]- where- pFun =- pParam <* lexeme "->" <*> pRetType- pParam =- choice- [ try pNamedParam,- do- t <- pNonFunType- pure $ Arrow Nonunique Unnamed (diet $ resToParam t) (toStruct t)- ]- pNamedParam = parens $ do- v <- pVName <* lexeme ":"- t <- pType- pure $ Arrow Nonunique (Named v) (diet $ resToParam t) (toStruct t)--pRetType :: Parser ResRetType-pRetType =- choice- [ lexeme "?" *> (RetType <$> some (brackets pVName) <* lexeme "." <*> pType),- RetType [] <$> pType- ]--pType :: Parser ResType-pType =- choice [try $ Scalar <$> pScalarType, pArrayType, parens pType]--fromStringParse :: Parser a -> String -> String -> a-fromStringParse p what s =- either onError id $ parse (p <* eof) "" (T.pack s)- where- onError e =- error $ "not a " <> what <> ": " <> s <> "\n" <> errorBundlePretty e--instance IsString (ScalarTypeBase Size NoUniqueness) where- fromString =- fromStringParse (second (const NoUniqueness) <$> pScalarType) "ScalarType"--instance IsString StructType where- fromString =- fromStringParse (second (const NoUniqueness) <$> pType) "StructType"--instance IsString StructRetType where- fromString =- fromStringParse (second (pure NoUniqueness) <$> pRetType) "StructRetType"--instance IsString ResRetType where- fromString = fromStringParse pRetType "ResRetType"
− unittests/Language/Futhark/TypeChecker/TypesTests.hs
@@ -1,185 +0,0 @@-module Language.Futhark.TypeChecker.TypesTests (tests) where--import Data.Bifunctor-import Data.List (isInfixOf)-import Data.Map qualified as M-import Data.Text qualified as T-import Futhark.FreshNames-import Futhark.Util.Pretty (docText, prettyTextOneLine)-import Language.Futhark-import Language.Futhark.Semantic-import Language.Futhark.SyntaxTests ()-import Language.Futhark.TypeChecker (initialEnv)-import Language.Futhark.TypeChecker.Monad-import Language.Futhark.TypeChecker.Names (resolveTypeExp)-import Language.Futhark.TypeChecker.Terms-import Language.Futhark.TypeChecker.Types-import Test.Tasty-import Test.Tasty.HUnit--evalTest :: TypeExp (ExpBase NoInfo Name) Name -> Either String ([VName], ResRetType) -> TestTree-evalTest te expected =- testCase (prettyString te) $- case (fmap (extract . fst) (run (checkTypeExp checkSizeExp =<< resolveTypeExp te)), expected) of- (Left got_e, Left expected_e) ->- let got_e_s = T.unpack $ docText $ prettyTypeError got_e- in (expected_e `isInfixOf` got_e_s) @? got_e_s- (Left got_e, Right _) ->- let got_e_s = T.unpack $ docText $ prettyTypeError got_e- in assertFailure $ "Failed: " <> got_e_s- (Right actual_t, Right expected_t) ->- actual_t @?= expected_t- (Right actual_t, Left _) ->- assertFailure $ "Expected error, got: " <> show actual_t- where- extract (_, svars, t, _) = (svars, t)- run = snd . runTypeM env mempty (mkInitialImport "") (newNameSource 100)- -- We hack up an environment with some predefined type- -- abbreviations for testing. This is all pretty sensitive to the- -- specific unique names, so we have to be careful!- env =- initialEnv- { envTypeTable =- M.fromList- [ ( "square_1000",- TypeAbbr- Unlifted- [TypeParamDim "n_1001" mempty]- "[n_1001][n_1001]i32"- ),- ( "fun_1100",- TypeAbbr- Lifted- [ TypeParamType Lifted "a_1101" mempty,- TypeParamType Lifted "b_1102" mempty- ]- "a_1101 -> b_1102"- ),- ( "pair_1200",- TypeAbbr- SizeLifted- []- "?[n_1201][m_1202].([n_1201]i64, [m_1202]i64)"- )- ]- <> envTypeTable initialEnv,- envNameMap =- M.fromList- [ ((Type, "square"), "square_1000"),- ((Type, "fun"), "fun_1100"),- ((Type, "pair"), "pair_1200")- ]- <> envNameMap initialEnv- }--evalTests :: TestTree-evalTests =- testGroup- "Type expression elaboration"- [ testGroup "Positive tests" (map mkPos pos),- testGroup "Negative tests" (map mkNeg neg)- ]- where- mkPos (x, y) = evalTest x (Right y)- mkNeg (x, y) = evalTest x (Left y)- pos =- [ ( "[]i32",- ([], "?[d_100].[d_100]i32")- ),- ( "[][]i32",- ([], "?[d_100][d_101].[d_100][d_101]i32")- ),- ( "bool -> []i32",- ([], "bool -> ?[d_100].[d_100]i32")- ),- ( "bool -> []f32 -> []i32",- (["d_100"], "bool -> [d_100]f32 -> ?[d_101].[d_101]i32")- ),- ( "([]i32,[]i32)",- ([], "?[d_100][d_101].([d_100]i32, [d_101]i32)")- ),- ( "{a:[]i32,b:[]i32}",- ([], "?[d_100][d_101].{a:[d_100]i32, b:[d_101]i32}")- ),- ( "?[n].[n][n]bool",- ([], "?[n_100].[n_100][n_100]bool")- ),- ( "([]i32 -> []i32) -> bool -> []i32",- (["d_100"], "([d_100]i32 -> ?[d_101].[d_101]i32) -> bool -> ?[d_102].[d_102]i32")- ),- ( "((k: i64) -> [k]i32 -> [k]i32) -> []i32 -> bool",- (["d_101"], "((k_100: i64) -> [k_100]i32 -> [k_100]i32) -> [d_101]i32 -> bool")- ),- ( "square [10]",- ([], "[10][10]i32")- ),- ( "square []",- ([], "?[d_100].[d_100][d_100]i32")- ),- ( "bool -> square []",- ([], "bool -> ?[d_100].[d_100][d_100]i32")- ),- ( "(k: i64) -> square [k]",- ([], "(k_100: i64) -> [k_100][k_100]i32")- ),- ( "fun i32 bool",- ([], "i32 -> bool")- ),- ( "fun ([]i32) bool",- ([], "?[d_100].[d_100]i32 -> bool")- ),- ( "fun bool ([]i32)",- ([], "?[d_100].bool -> [d_100]i32")- ),- ( "bool -> fun ([]i32) bool",- ([], "bool -> ?[d_100].[d_100]i32 -> bool")- ),- ( "bool -> fun bool ([]i32)",- ([], "bool -> ?[d_100].bool -> [d_100]i32")- ),- ( "pair",- ([], "?[n_100][m_101].([n_100]i64, [m_101]i64)")- ),- ( "(pair,pair)",- ([], "?[n_100][m_101][n_102][m_103].(([n_100]i64, [m_101]i64), ([n_102]i64, [m_103]i64))")- )- ]- neg =- [ ("?[n].bool", "Existential size \"n\""),- ("?[n].bool -> [n]bool", "Existential size \"n\""),- ("?[n].[n]bool -> [n]bool", "Existential size \"n\""),- ("?[n].[n]bool -> bool", "Existential size \"n\"")- ]--substTest :: M.Map VName (Subst StructRetType) -> StructRetType -> StructRetType -> TestTree-substTest m t expected =- testCase (pretty_m <> ": " <> T.unpack (prettyTextOneLine t)) $- applySubst (`M.lookup` m) t @?= expected- where- pretty_m = T.unpack $ prettyText $ map (first toName) $ M.toList m---- Some of these tests may be a bit fragile, in that they depend on--- internal renumbering, which can be arbitrary.-substTests :: TestTree-substTests =- testGroup- "Type substitution"- [ substTest m0 "t_0" "i64",- substTest m0 "[1]t_0" "[1]i64",- substTest m0 "?[n_10].[n_10]t_0" "?[n_10].[n_10]i64",- --- substTest m1 "t_0" "?[n_1].[n_1]bool",- substTest m1 "f32 -> t_0" "f32 -> ?[n_1].[n_1]bool",- substTest m1 "f32 -> f64 -> t_0" "f32 -> f64 -> ?[n_1].[n_1]bool",- substTest m1 "f32 -> t_0 -> bool" "?[n_1].f32 -> [n_1]bool -> bool",- substTest m1 "f32 -> t_0 -> t_0" "?[n_1].f32 -> [n_1]bool -> ?[n_2].[n_2]bool"- ]- where- m0 =- M.fromList [("t_0", Subst [] "i64")]-- m1 =- M.fromList [("t_0", Subst [] "?[n_1].[n_1]bool")]--tests :: TestTree-tests = testGroup "Basic type operations" [evalTests, substTests]
− unittests/Language/Futhark/TypeCheckerTests.hs
@@ -1,11 +0,0 @@-module Language.Futhark.TypeCheckerTests (tests) where--import Language.Futhark.TypeChecker.TypesTests qualified-import Test.Tasty--tests :: TestTree-tests =- testGroup- "Source type checker tests"- [ Language.Futhark.TypeChecker.TypesTests.tests- ]
− unittests/futhark_tests.hs
@@ -1,42 +0,0 @@-module Main (main) where--import Futhark.AD.DerivativesTests qualified-import Futhark.Analysis.AlgSimplifyTests qualified-import Futhark.BenchTests qualified-import Futhark.IR.Mem.IntervalTests qualified-import Futhark.IR.Mem.IxFunTests qualified-import Futhark.IR.PropTests qualified-import Futhark.IR.Syntax.CoreTests qualified-import Futhark.Internalise.TypesValuesTests qualified-import Futhark.Optimise.ArrayLayoutTests qualified-import Futhark.Optimise.MemoryBlockMerging.GreedyColoringTests qualified-import Futhark.Pkg.SolveTests qualified-import Language.Futhark.PrimitiveTests qualified-import Language.Futhark.SemanticTests qualified-import Language.Futhark.SyntaxTests qualified-import Language.Futhark.TypeCheckerTests qualified-import Test.Tasty--allTests :: TestTree-allTests =- testGroup- ""- [ Language.Futhark.SyntaxTests.tests,- Futhark.AD.DerivativesTests.tests,- Futhark.BenchTests.tests,- Futhark.IR.PropTests.tests,- Futhark.IR.Syntax.CoreTests.tests,- Futhark.Pkg.SolveTests.tests,- Futhark.Internalise.TypesValuesTests.tests,- Futhark.IR.Mem.IntervalTests.tests,- Futhark.IR.Mem.IxFunTests.tests,- Language.Futhark.PrimitiveTests.tests,- Futhark.Optimise.MemoryBlockMerging.GreedyColoringTests.tests,- Futhark.Analysis.AlgSimplifyTests.tests,- Language.Futhark.TypeCheckerTests.tests,- Language.Futhark.SemanticTests.tests,- Futhark.Optimise.ArrayLayoutTests.tests- ]--main :: IO ()-main = defaultMain allTests