ghc-lib-parser-9.8.2.20240223: The GHC API, decoupled from GHC versions
Safe HaskellNone
LanguageHaskell2010

GHC.Stg.Syntax

Synopsis

Documentation

data StgArg #

Constructors

StgVarArg Id 
StgLitArg Literal 

Instances

Instances details
Outputable StgArg # 
Instance details

Defined in GHC.Stg.Syntax

Methods

ppr :: StgArg -> SDoc #

data GenStgTopBinding (pass :: StgPass) #

A top-level binding.

data GenStgBinding (pass :: StgPass) #

Constructors

StgNonRec (BinderP pass) (GenStgRhs pass) 
StgRec [(BinderP pass, GenStgRhs pass)] 

Instances

Instances details
OutputablePass pass => Outputable (GenStgBinding pass) # 
Instance details

Defined in GHC.Stg.Syntax

Methods

ppr :: GenStgBinding pass -> SDoc #

data GenStgExpr (pass :: StgPass) #

Instances

Instances details
OutputablePass pass => Outputable (GenStgExpr pass) # 
Instance details

Defined in GHC.Stg.Syntax

Methods

ppr :: GenStgExpr pass -> SDoc #

data GenStgRhs (pass :: StgPass) #

Constructors

StgRhsClosure 

Fields

StgRhsCon CostCentreStack DataCon ConstructorNumber [StgTickish] [StgArg] Type 

Instances

Instances details
OutputablePass pass => Outputable (GenStgRhs pass) # 
Instance details

Defined in GHC.Stg.Syntax

Methods

ppr :: GenStgRhs pass -> SDoc #

data GenStgAlt (pass :: StgPass) #

Constructors

GenStgAlt 

Fields

data AltType #

Instances

Instances details
Outputable AltType # 
Instance details

Defined in GHC.Stg.Syntax

Methods

ppr :: AltType -> SDoc #

data StgPass #

Used as a data type index for the stgSyn AST

Constructors

Vanilla 
LiftLams

Use internally by the lambda lifting pass

InferTaggedBinders

Tag inference information on binders. See Note [Tag inference passes] in GHC.Stg.InferTags

InferTagged

Tag inference information put on relevant StgApp nodes See Note [Tag inference passes] in GHC.Stg.InferTags

CodeGen 

type family BinderP (pass :: StgPass) #

Instances

Instances details
type BinderP 'CodeGen # 
Instance details

Defined in GHC.Stg.Syntax

type BinderP 'InferTagged # 
Instance details

Defined in GHC.Stg.Syntax

type BinderP 'InferTaggedBinders # 
Instance details

Defined in GHC.Stg.Syntax

type BinderP 'LiftLams # 
Instance details

Defined in GHC.Stg.Syntax

type BinderP 'Vanilla # 
Instance details

Defined in GHC.Stg.Syntax

type family XRhsClosure (pass :: StgPass) #

Instances

Instances details
type XRhsClosure 'CodeGen #

Code gen needs to track non-global free vars

Instance details

Defined in GHC.Stg.Syntax

type XRhsClosure 'InferTagged # 
Instance details

Defined in GHC.Stg.Syntax

type XRhsClosure 'InferTaggedBinders # 
Instance details

Defined in GHC.Stg.Syntax

type XRhsClosure 'LiftLams # 
Instance details

Defined in GHC.Stg.Syntax

type XRhsClosure 'Vanilla # 
Instance details

Defined in GHC.Stg.Syntax

type family XLet (pass :: StgPass) #

Instances

Instances details
type XLet 'CodeGen # 
Instance details

Defined in GHC.Stg.Syntax

type XLet 'InferTagged # 
Instance details

Defined in GHC.Stg.Syntax

type XLet 'InferTaggedBinders # 
Instance details

Defined in GHC.Stg.Syntax

type XLet 'LiftLams # 
Instance details

Defined in GHC.Stg.Syntax

type XLet 'Vanilla # 
Instance details

Defined in GHC.Stg.Syntax

type family XLetNoEscape (pass :: StgPass) #

Instances

Instances details
type XLetNoEscape 'CodeGen # 
Instance details

Defined in GHC.Stg.Syntax

type XLetNoEscape 'InferTagged # 
Instance details

Defined in GHC.Stg.Syntax

type XLetNoEscape 'InferTaggedBinders # 
Instance details

Defined in GHC.Stg.Syntax

type XLetNoEscape 'LiftLams # 
Instance details

Defined in GHC.Stg.Syntax

type XLetNoEscape 'Vanilla # 
Instance details

Defined in GHC.Stg.Syntax

data NoExtFieldSilent #

Like NoExtField, but with an Outputable instance that returns empty.

Instances

Instances details
Data NoExtFieldSilent # 
Instance details

Defined in GHC.Stg.Syntax

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> NoExtFieldSilent -> c NoExtFieldSilent #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c NoExtFieldSilent #

toConstr :: NoExtFieldSilent -> Constr #

dataTypeOf :: NoExtFieldSilent -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c NoExtFieldSilent) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c NoExtFieldSilent) #

gmapT :: (forall b. Data b => b -> b) -> NoExtFieldSilent -> NoExtFieldSilent #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> NoExtFieldSilent -> r #

gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> NoExtFieldSilent -> r #

gmapQ :: (forall d. Data d => d -> u) -> NoExtFieldSilent -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> NoExtFieldSilent -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> NoExtFieldSilent -> m NoExtFieldSilent #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> NoExtFieldSilent -> m NoExtFieldSilent #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> NoExtFieldSilent -> m NoExtFieldSilent #

Outputable NoExtFieldSilent # 
Instance details

Defined in GHC.Stg.Syntax

Methods

ppr :: NoExtFieldSilent -> SDoc #

Eq NoExtFieldSilent # 
Instance details

Defined in GHC.Stg.Syntax

Ord NoExtFieldSilent # 
Instance details

Defined in GHC.Stg.Syntax

noExtFieldSilent :: NoExtFieldSilent #

Used when constructing a term with an unused extension point that should not appear in pretty-printed output at all.

data UpdateFlag #

Instances

Instances details
Outputable UpdateFlag # 
Instance details

Defined in GHC.Stg.Syntax

Methods

ppr :: UpdateFlag -> SDoc #

data ConstructorNumber #

When `-fdistinct-constructor-tables` is turned on then each usage of a constructor is given an unique number and an info table is generated for each different constructor.

Constructors

NoNumber 
Numbered Int 

Instances

Instances details
Outputable ConstructorNumber # 
Instance details

Defined in GHC.Stg.Syntax

data StgOp #

Instances

Instances details
Outputable StgOp # 
Instance details

Defined in GHC.Stg.Syntax

Methods

ppr :: StgOp -> SDoc #

freeVarsOfRhs :: forall (pass :: StgPass). XRhsClosure pass ~ DIdSet => GenStgRhs pass -> DIdSet #

isDllConApp :: Platform -> Bool -> Module -> DataCon -> [StgArg] -> Bool #

Does this constructor application refer to anything in a different *Windows* DLL? If so, we can't allocate it statically

stgArgType :: StgArg -> Type #

Type of an StgArg

Very half baked because we have lost the type arguments.

stgCaseBndrInScope #

Arguments

:: AltType 
-> Bool

unarised?

-> Bool 

Given an alt type and whether the program is unarised, return whether the case binder is in scope.

Case binders of unboxed tuple or unboxed sum type always dead after the unariser has run. See Note [Post-unarisation invariants].

data StgPprOpts #

STG pretty-printing options

Constructors

StgPprOpts 

Fields

panicStgPprOpts :: StgPprOpts #

STG pretty-printing options used for panic messages

shortStgPprOpts :: StgPprOpts #

STG pretty-printing options used for short messages

pprStgExpr :: forall (pass :: StgPass). OutputablePass pass => StgPprOpts -> GenStgExpr pass -> SDoc #

pprStgRhs :: forall (pass :: StgPass). OutputablePass pass => StgPprOpts -> GenStgRhs pass -> SDoc #

pprStgBinding :: forall (pass :: StgPass). OutputablePass pass => StgPprOpts -> GenStgBinding pass -> SDoc #

pprStgAlt :: forall (pass :: StgPass). OutputablePass pass => StgPprOpts -> Bool -> GenStgAlt pass -> SDoc #

pprStgTopBinding :: forall (pass :: StgPass). OutputablePass pass => StgPprOpts -> GenStgTopBinding pass -> SDoc #

pprGenStgTopBindings :: forall (pass :: StgPass). OutputablePass pass => StgPprOpts -> [GenStgTopBinding pass] -> SDoc #

pprStgTopBindings :: forall (pass :: StgPass). OutputablePass pass => StgPprOpts -> [GenStgTopBinding pass] -> SDoc #