ghc-7.0.4: The GHC API

StgCmmMonad

# Documentation

data FCode a Source

Instances

Monad FCode |

initC :: DynFlags -> Module -> FCode a -> IO aSource

thenC :: FCode () -> FCode a -> FCode aSource

thenFC :: FCode a -> (a -> FCode c) -> FCode cSource

listCs :: [FCode ()] -> FCode ()Source

listFCs :: [FCode a] -> FCode [a]Source

mapCs :: (a -> FCode ()) -> [a] -> FCode ()Source

mapFCs :: (a -> FCode b) -> [a] -> FCode [b]Source

returnFC :: a -> FCode aSource

fixC :: (a -> FCode a) -> FCode aSource

fixC_ :: (a -> FCode a) -> FCode ()Source

nopC :: FCode ()Source

whenC :: Bool -> FCode () -> FCode ()Source

newUnique :: FCode Unique Source

newUniqSupply :: FCode UniqSupply Source

emit :: CmmAGraph -> FCode ()Source

emitData :: Section -> [CmmStatic] -> FCode ()Source

emitProc :: CmmInfo -> CLabel -> CmmFormals -> CmmAGraph -> FCode ()Source

emitProcWithConvention :: Convention -> CmmInfo -> CLabel -> CmmFormals -> CmmAGraph -> FCode ()Source

emitSimpleProc :: CLabel -> CmmAGraph -> FCode ()Source

getCmm :: FCode () -> FCode CmmZ Source

cgStmtsToBlocks :: CmmAGraph -> FCode CmmGraph Source

getCodeR :: FCode a -> FCode (a, CmmAGraph)Source

getCode :: FCode a -> FCode CmmAGraph Source

getHeapUsage :: (VirtualHpOffset -> FCode a) -> FCode aSource

forkClosureBody :: FCode () -> FCode ()Source

forkStatics :: FCode a -> FCode aSource

forkAlts :: [FCode a] -> FCode [a]Source

forkProc :: FCode a -> FCode aSource

codeOnly :: FCode () -> FCode ()Source

type ConTagZ = Int Source

data Sequel Source

Constructors

Return Bool |
AssignTo [LocalReg] Bool |

Instances

Show Sequel |

withSequel :: Sequel -> FCode () -> FCode ()Source

getSequel :: FCode Sequel Source

setSRTLabel :: CLabel -> FCode a -> FCode aSource

getSRTLabel :: FCode CLabel Source

setTickyCtrLabel :: CLabel -> FCode () -> FCode ()Source

getTickyCtrLabel :: FCode CLabel Source

withUpdFrameOff :: UpdFrameOffset -> FCode () -> FCode ()Source

getUpdFrameOff :: FCode UpdFrameOffset Source

initUpdFrameOff :: UpdFrameOffset Source

data HeapUsage Source

Constructors

HeapUsage |

Fields

virtHp :: VirtualHpOffset
realHp :: VirtualHpOffset

type VirtualHpOffset = WordOff Source

initHpUsage :: HeapUsage Source

getHpUsage :: FCode HeapUsage Source

setHpUsage :: HeapUsage -> FCode ()Source

heapHWM :: HeapUsage -> VirtualHpOffset Source

setVirtHp :: VirtualHpOffset -> FCode ()Source

getVirtHp :: FCode VirtualHpOffset Source

setRealHp :: VirtualHpOffset -> FCode ()Source

getModuleName :: FCode Module Source

getState :: FCode CgState Source

setState :: CgState -> FCode ()Source

getInfoDown :: FCode CgInfoDownwards Source

getDynFlags :: FCode DynFlags Source

getThisPackage :: FCode PackageId Source

data CgIdInfo Source

Constructors

CgIdInfo |

Fields

cg_id :: Id
cg_lf :: LambdaFormInfo
cg_loc :: CgLoc
cg_rep :: PrimRep
cg_tag :: !DynTag

Instances

Outputable CgIdInfo |

data CgLoc Source

Constructors

CmmLoc CmmExpr |
LneLoc BlockId [LocalReg] |

Instances

Outputable CgLoc |

getBinds :: FCode CgBindingsSource

setBinds :: CgBindings -> FCode ()Source

getStaticBinds :: FCode CgBindingsSource

data CgInfoDownwards Source

Constructors

MkCgInfoDown |

Fields

cgd_dflags :: DynFlags
cgd_mod :: Module
cgd_statics :: CgBindings
cgd_srt_lbl :: CLabel
cgd_updfr_off :: UpdFrameOffset
cgd_ticky :: CLabel
cgd_sequel :: Sequel

data CgState Source

Constructors

MkCgState |

Fields

cgs_stmts :: CmmAGraph
cgs_tops :: OrdList CmmTopZ
cgs_binds :: CgBindings
cgs_hp_usg :: HeapUsage
cgs_uniqs :: UniqSupply