Safe Haskell | Ignore |
---|---|
Language | Haskell2010 |
Unfolding creation
Synopsis
- noUnfolding :: Unfolding
- mkUnfolding :: UnfoldingOpts -> UnfoldingSource -> Bool -> Bool -> CoreExpr -> Maybe UnfoldingCache -> Unfolding
- mkCoreUnfolding :: UnfoldingSource -> Bool -> CoreExpr -> Maybe UnfoldingCache -> UnfoldingGuidance -> Unfolding
- mkFinalUnfolding :: UnfoldingOpts -> UnfoldingSource -> DmdSig -> CoreExpr -> Unfolding
- mkFinalUnfolding' :: UnfoldingOpts -> UnfoldingSource -> DmdSig -> CoreExpr -> Maybe UnfoldingCache -> Unfolding
- mkSimpleUnfolding :: UnfoldingOpts -> CoreExpr -> Unfolding
- mkWorkerUnfolding :: SimpleOpts -> (CoreExpr -> CoreExpr) -> Unfolding -> Unfolding
- mkInlineUnfoldingWithArity :: SimpleOpts -> UnfoldingSource -> Arity -> CoreExpr -> Unfolding
- mkInlineUnfoldingNoArity :: SimpleOpts -> UnfoldingSource -> CoreExpr -> Unfolding
- mkInlinableUnfolding :: SimpleOpts -> UnfoldingSource -> CoreExpr -> Unfolding
- mkWrapperUnfolding :: SimpleOpts -> CoreExpr -> Arity -> Unfolding
- mkCompulsoryUnfolding :: CoreExpr -> Unfolding
- mkCompulsoryUnfolding' :: SimpleOpts -> CoreExpr -> Unfolding
- mkDFunUnfolding :: [Var] -> DataCon -> [CoreExpr] -> Unfolding
- mkDataConUnfolding :: CoreExpr -> Unfolding
- specUnfolding :: SimpleOpts -> [Var] -> (CoreExpr -> CoreExpr) -> [CoreArg] -> Unfolding -> Unfolding
- certainlyWillInline :: UnfoldingOpts -> IdInfo -> CoreExpr -> Maybe Unfolding
Documentation
noUnfolding :: Unfolding Source #
There is no known Unfolding
mkUnfolding :: UnfoldingOpts -> UnfoldingSource -> Bool -> Bool -> CoreExpr -> Maybe UnfoldingCache -> Unfolding Source #
mkCoreUnfolding :: UnfoldingSource -> Bool -> CoreExpr -> Maybe UnfoldingCache -> UnfoldingGuidance -> Unfolding Source #
mkFinalUnfolding :: UnfoldingOpts -> UnfoldingSource -> DmdSig -> CoreExpr -> Unfolding Source #
mkFinalUnfolding' :: UnfoldingOpts -> UnfoldingSource -> DmdSig -> CoreExpr -> Maybe UnfoldingCache -> Unfolding Source #
mkSimpleUnfolding :: UnfoldingOpts -> CoreExpr -> Unfolding Source #
mkWorkerUnfolding :: SimpleOpts -> (CoreExpr -> CoreExpr) -> Unfolding -> Unfolding Source #
mkInlineUnfoldingWithArity :: SimpleOpts -> UnfoldingSource -> Arity -> CoreExpr -> Unfolding Source #
Make an INLINE unfolding that will be used once the RHS has been saturated to the given arity.
mkInlineUnfoldingNoArity :: SimpleOpts -> UnfoldingSource -> CoreExpr -> Unfolding Source #
Make an INLINE unfolding that may be used unsaturated (ug_unsat_ok = unSaturatedOk) and that is reported as having its manifest arity (the number of outer lambdas applications will resolve before doing any work).
mkInlinableUnfolding :: SimpleOpts -> UnfoldingSource -> CoreExpr -> Unfolding Source #
mkWrapperUnfolding :: SimpleOpts -> CoreExpr -> Arity -> Unfolding Source #
mkCompulsoryUnfolding :: CoreExpr -> Unfolding Source #
Used for things that absolutely must be unfolded
mkCompulsoryUnfolding' :: SimpleOpts -> CoreExpr -> Unfolding Source #
Same as mkCompulsoryUnfolding
but simplifies the unfolding first
specUnfolding :: SimpleOpts -> [Var] -> (CoreExpr -> CoreExpr) -> [CoreArg] -> Unfolding -> Unfolding Source #
certainlyWillInline :: UnfoldingOpts -> IdInfo -> CoreExpr -> Maybe Unfolding Source #
Sees if the unfolding is pretty certain to inline. If so, return a *stable* unfolding for it, that will always inline. The CoreExpr is the WW'd and simplified RHS. In contrast, the unfolding template might not have been WW'd yet.