ghc-lib-0.20220901: The GHC API, decoupled from GHC versions
Safe HaskellSafe-Inferred
LanguageHaskell2010

GHC.StgToCmm.Closure

Synopsis

Documentation

idPrimRep :: Id -> PrimRep Source #

Assumes that there is precisely one PrimRep of the type. This assumption holds after unarise. See Note [Post-unarisation invariants]

addIdReps :: [NonVoid Id] -> [NonVoid (PrimRep, Id)] Source #

Assumes that Ids have one PrimRep, which holds after unarisation. See Note [Post-unarisation invariants]

addArgReps :: [NonVoid StgArg] -> [NonVoid (PrimRep, StgArg)] Source #

Assumes that arguments have one PrimRep, which holds after unarisation. See Note [Post-unarisation invariants]

argPrimRep :: StgArg -> PrimRep Source #

Assumes that the argument has one PrimRep, which holds after unarisation. See Note [Post-unarisation invariants]

newtype NonVoid a Source #

Constructors

NonVoid a 

Instances

Instances details
Show a => Show (NonVoid a) Source # 
Instance details

Defined in GHC.StgToCmm.Closure

Methods

showsPrec :: Int -> NonVoid a -> ShowS #

show :: NonVoid a -> String #

showList :: [NonVoid a] -> ShowS #

Outputable a => Outputable (NonVoid a) Source # 
Instance details

Defined in GHC.StgToCmm.Closure

Methods

ppr :: NonVoid a -> SDoc #

Eq a => Eq (NonVoid a) Source # 
Instance details

Defined in GHC.StgToCmm.Closure

Methods

(==) :: NonVoid a -> NonVoid a -> Bool #

(/=) :: NonVoid a -> NonVoid a -> Bool #

assertNonVoidIds :: [Id] -> [NonVoid Id] Source #

Used in places where some invariant ensures that all these Ids are non-void; e.g. constructor field binders in case expressions. See Note [Post-unarisation invariants] in GHC.Stg.Unarise.

assertNonVoidStgArgs :: [StgArg] -> [NonVoid StgArg] Source #

Used in places where some invariant ensures that all these arguments are non-void; e.g. constructor arguments. See Note [Post-unarisation invariants] in GHC.Stg.Unarise.

LambdaFormInfo

data LambdaFormInfo #

Information about an identifier, from the code generator's point of view. Every identifier is bound to a LambdaFormInfo in the environment, which gives the code generator enough info to be able to tail call or return that identifier.

Instances

Instances details
Outputable LambdaFormInfo 
Instance details

Defined in GHC.StgToCmm.Types

Methods

ppr :: LambdaFormInfo -> SDoc #

data StandardFormInfo #

StandardFormInfo tells whether this thunk has one of a small number of standard forms

Instances

Instances details
Outputable StandardFormInfo 
Instance details

Defined in GHC.StgToCmm.Types

Methods

ppr :: StandardFormInfo -> SDoc #

Eq StandardFormInfo 
Instance details

Defined in GHC.StgToCmm.Types

lfDynTag :: Platform -> LambdaFormInfo -> DynTag Source #

Return the tag in the low order bits of a variable bound to this LambdaForm

Used by other modules

data CgLoc Source #

Instances

Instances details
OutputableP Platform CgLoc Source # 
Instance details

Defined in GHC.StgToCmm.Closure

Methods

pdoc :: Platform -> CgLoc -> SDoc #

data CallMethod Source #

Instances

Instances details
Outputable CallMethod Source # 
Instance details

Defined in GHC.StgToCmm.Closure

Methods

ppr :: CallMethod -> SDoc #

ClosureInfo

Inspection

Labels

Predicates

InfoTables

mkClosureInfoTableLabel :: Platform -> Id -> LambdaFormInfo -> CLabel Source #

Get the info table label for a *thunk*.