GHC.StgToCmm.Heap

ghc-8.10.7: The GHC API

Safe Haskell | None
Language | Haskell2010

GHC.StgToCmm.Heap

Synopsis

- getVirtHp :: FCode VirtualHpOffset
- setVirtHp :: VirtualHpOffset -> FCode ()
- setRealHp :: VirtualHpOffset -> FCode ()
- getHpRelOffset :: VirtualHpOffset -> FCode CmmExpr
- entryHeapCheck :: ClosureInfo -> Maybe LocalReg -> Int -> [LocalReg] -> FCode () -> FCode ()
- altHeapCheck :: [LocalReg] -> FCode a -> FCode a
- noEscapeHeapCheck :: [LocalReg] -> FCode a -> FCode a
- altHeapCheckReturnsTo :: [LocalReg] -> Label -> ByteOff -> FCode a -> FCode a
- heapStackCheckGen :: Maybe CmmExpr -> Maybe CmmExpr -> FCode ()
- entryHeapCheck' :: Bool -> CmmExpr -> Int -> [LocalReg] -> FCode () -> FCode ()
- mkStaticClosureFields :: DynFlags -> CmmInfoTable -> CostCentreStack -> CafInfo -> [CmmLit] -> [CmmLit]
- mkStaticClosure :: DynFlags -> CLabel -> CostCentreStack -> [CmmLit] -> [CmmLit] -> [CmmLit] -> [CmmLit] -> [CmmLit]
- allocDynClosure :: Maybe Id -> CmmInfoTable -> LambdaFormInfo -> CmmExpr -> CmmExpr -> [(NonVoid StgArg, VirtualHpOffset)] -> FCode CmmExpr
- allocDynClosureCmm :: Maybe Id -> CmmInfoTable -> LambdaFormInfo -> CmmExpr -> CmmExpr -> [(CmmExpr, ByteOff)] -> FCode CmmExpr
- allocHeapClosure :: SMRep -> CmmExpr -> CmmExpr -> [(CmmExpr, ByteOff)] -> FCode CmmExpr
- emitSetDynHdr :: CmmExpr -> CmmExpr -> CmmExpr -> FCode ()

# Documentation

getVirtHp :: FCode VirtualHpOffset #

setVirtHp :: VirtualHpOffset -> FCode () #

setRealHp :: VirtualHpOffset -> FCode () #

getHpRelOffset :: VirtualHpOffset -> FCode CmmExpr #

entryHeapCheck :: ClosureInfo -> Maybe LocalReg -> Int -> [LocalReg] -> FCode () -> FCode () #

altHeapCheck :: [LocalReg] -> FCode a -> FCode a #

noEscapeHeapCheck :: [LocalReg] -> FCode a -> FCode a #

altHeapCheckReturnsTo :: [LocalReg] -> Label -> ByteOff -> FCode a -> FCode a #

heapStackCheckGen :: Maybe CmmExpr -> Maybe CmmExpr -> FCode () #

entryHeapCheck' :: Bool -> CmmExpr -> Int -> [LocalReg] -> FCode () -> FCode () #

lower-level version for CmmParse

mkStaticClosureFields :: DynFlags -> CmmInfoTable -> CostCentreStack -> CafInfo -> [CmmLit] -> [CmmLit] #

mkStaticClosure :: DynFlags -> CLabel -> CostCentreStack -> [CmmLit] -> [CmmLit] -> [CmmLit] -> [CmmLit] -> [CmmLit] #

allocDynClosure :: Maybe Id -> CmmInfoTable -> LambdaFormInfo -> CmmExpr -> CmmExpr -> [(NonVoid StgArg, VirtualHpOffset)] -> FCode CmmExpr #

allocDynClosureCmm :: Maybe Id -> CmmInfoTable -> LambdaFormInfo -> CmmExpr -> CmmExpr -> [(CmmExpr, ByteOff)] -> FCode CmmExpr #

allocHeapClosure #

Arguments

:: SMRep | representation of the object
-> CmmExpr | info pointer
-> CmmExpr | cost centre
-> [(CmmExpr, ByteOff)] | payload
-> FCode CmmExpr | returns the address of the object

Low-level heap object allocation.

emitSetDynHdr :: CmmExpr -> CmmExpr -> CmmExpr -> FCode () #