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

GHC.StgToCmm.CgUtils

Synopsis

Documentation

fixStgRegisters :: DynFlags -> RawCmmDecl -> RawCmmDecl Source #

Fixup global registers so that they assign to locations within the RegTable if they aren't pinned for the current target.

baseRegOffset :: DynFlags -> GlobalReg -> Int Source #

get_GlobalReg_addr :: DynFlags -> GlobalReg -> CmmExpr Source #

We map STG registers onto appropriate CmmExprs. Either they map to real machine registers or stored as offsets from BaseReg. Given a GlobalReg, get_GlobalReg_addr always produces the register table address for it.