Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- setMode :: SimplMode -> SimplEnv -> SimplEnv
- getMode :: SimplEnv -> SimplMode
- updMode :: (SimplMode -> SimplMode) -> SimplEnv -> SimplEnv
- seDynFlags :: SimplEnv -> DynFlags
- data SimplEnv = SimplEnv {
- seMode :: SimplMode
- seTvSubst :: TvSubstEnv
- seCvSubst :: CvSubstEnv
- seIdSubst :: SimplIdSubst
- seInScope :: InScopeSet
- pprSimplEnv :: SimplEnv -> SDoc
- mkSimplEnv :: SimplMode -> SimplEnv
- extendIdSubst :: SimplEnv -> Id -> SimplSR -> SimplEnv
- extendTvSubst :: SimplEnv -> TyVar -> Type -> SimplEnv
- extendCvSubst :: SimplEnv -> CoVar -> Coercion -> SimplEnv
- zapSubstEnv :: SimplEnv -> SimplEnv
- setSubstEnv :: SimplEnv -> TvSubstEnv -> CvSubstEnv -> SimplIdSubst -> SimplEnv
- getInScope :: SimplEnv -> InScopeSet
- setInScopeFromE :: SimplEnv -> SimplEnv -> SimplEnv
- setInScopeFromF :: SimplEnv -> SimplFloats -> SimplEnv
- setInScopeSet :: SimplEnv -> InScopeSet -> SimplEnv
- modifyInScope :: SimplEnv -> CoreBndr -> SimplEnv
- addNewInScopeIds :: SimplEnv -> [CoreBndr] -> SimplEnv
- getSimplRules :: SimplM RuleEnv
- data SimplSR
- = DoneEx OutExpr (Maybe JoinArity)
- | DoneId OutId
- | ContEx TvSubstEnv CvSubstEnv SimplIdSubst InExpr
- mkContEx :: SimplEnv -> InExpr -> SimplSR
- substId :: SimplEnv -> InId -> SimplSR
- lookupRecBndr :: SimplEnv -> InId -> OutId
- refineFromInScope :: InScopeSet -> Var -> Var
- simplNonRecBndr :: SimplEnv -> InBndr -> SimplM (SimplEnv, OutBndr)
- simplNonRecJoinBndr :: SimplEnv -> InBndr -> Mult -> OutType -> SimplM (SimplEnv, OutBndr)
- simplRecBndrs :: SimplEnv -> [InBndr] -> SimplM SimplEnv
- simplRecJoinBndrs :: SimplEnv -> [InBndr] -> Mult -> OutType -> SimplM SimplEnv
- simplBinder :: SimplEnv -> InBndr -> SimplM (SimplEnv, OutBndr)
- simplBinders :: SimplEnv -> [InBndr] -> SimplM (SimplEnv, [OutBndr])
- substTy :: SimplEnv -> Type -> Type
- substTyVar :: SimplEnv -> TyVar -> Type
- getTCvSubst :: SimplEnv -> TCvSubst
- substCo :: SimplEnv -> Coercion -> Coercion
- substCoVar :: SimplEnv -> CoVar -> Coercion
- data SimplFloats = SimplFloats {}
- emptyFloats :: SimplEnv -> SimplFloats
- mkRecFloats :: SimplFloats -> SimplFloats
- mkFloatBind :: SimplEnv -> OutBind -> (SimplFloats, SimplEnv)
- addLetFloats :: SimplFloats -> LetFloats -> SimplFloats
- addJoinFloats :: SimplFloats -> JoinFloats -> SimplFloats
- addFloats :: SimplFloats -> SimplFloats -> SimplFloats
- extendFloats :: SimplFloats -> OutBind -> SimplFloats
- wrapFloats :: SimplFloats -> OutExpr -> OutExpr
- doFloatFromRhs :: TopLevelFlag -> RecFlag -> Bool -> SimplFloats -> OutExpr -> Bool
- getTopFloatBinds :: SimplFloats -> [CoreBind]
- data LetFloats
- letFloatBinds :: LetFloats -> [CoreBind]
- emptyLetFloats :: LetFloats
- unitLetFloat :: OutBind -> LetFloats
- addLetFlts :: LetFloats -> LetFloats -> LetFloats
- mapLetFloats :: LetFloats -> ((Id, CoreExpr) -> (Id, CoreExpr)) -> LetFloats
- type JoinFloat = OutBind
- type JoinFloats = OrdList JoinFloat
- emptyJoinFloats :: JoinFloats
- wrapJoinFloats :: JoinFloats -> OutExpr -> OutExpr
- wrapJoinFloatsX :: SimplFloats -> OutExpr -> (SimplFloats, OutExpr)
- unitJoinFloat :: OutBind -> JoinFloats
- addJoinFlts :: JoinFloats -> JoinFloats -> JoinFloats
The simplifier mode
seDynFlags :: SimplEnv -> DynFlags Source #
Environments
SimplEnv | |
|
pprSimplEnv :: SimplEnv -> SDoc Source #
mkSimplEnv :: SimplMode -> SimplEnv Source #
zapSubstEnv :: SimplEnv -> SimplEnv Source #
setSubstEnv :: SimplEnv -> TvSubstEnv -> CvSubstEnv -> SimplIdSubst -> SimplEnv Source #
getInScope :: SimplEnv -> InScopeSet Source #
setInScopeFromF :: SimplEnv -> SimplFloats -> SimplEnv Source #
setInScopeSet :: SimplEnv -> InScopeSet -> SimplEnv Source #
Substitution results
A substitution result.
DoneEx OutExpr (Maybe JoinArity) | |
DoneId OutId | |
ContEx TvSubstEnv CvSubstEnv SimplIdSubst InExpr |
refineFromInScope :: InScopeSet -> Var -> Var Source #
Simplifying Id
binders
getTCvSubst :: SimplEnv -> TCvSubst Source #
Floats
data SimplFloats Source #
Instances
Outputable SimplFloats Source # | |
Defined in GHC.Core.Opt.Simplify.Env |
emptyFloats :: SimplEnv -> SimplFloats Source #
mkRecFloats :: SimplFloats -> SimplFloats Source #
mkFloatBind :: SimplEnv -> OutBind -> (SimplFloats, SimplEnv) Source #
addLetFloats :: SimplFloats -> LetFloats -> SimplFloats Source #
addJoinFloats :: SimplFloats -> JoinFloats -> SimplFloats Source #
addFloats :: SimplFloats -> SimplFloats -> SimplFloats Source #
extendFloats :: SimplFloats -> OutBind -> SimplFloats Source #
wrapFloats :: SimplFloats -> OutExpr -> OutExpr Source #
doFloatFromRhs :: TopLevelFlag -> RecFlag -> Bool -> SimplFloats -> OutExpr -> Bool Source #
getTopFloatBinds :: SimplFloats -> [CoreBind] Source #
LetFloats
letFloatBinds :: LetFloats -> [CoreBind] Source #
unitLetFloat :: OutBind -> LetFloats Source #
JoinFloats
type JoinFloats = OrdList JoinFloat Source #
wrapJoinFloats :: JoinFloats -> OutExpr -> OutExpr Source #
wrapJoinFloatsX :: SimplFloats -> OutExpr -> (SimplFloats, OutExpr) Source #
unitJoinFloat :: OutBind -> JoinFloats Source #
addJoinFlts :: JoinFloats -> JoinFloats -> JoinFloats Source #