GHC.StgToJS.Profiling

ghc-9.10.0.20240426: The GHC API

Safe Haskell | None
Language | GHC2021

GHC.StgToJS.Profiling

Contents

- Predicates
- helpers

Synopsis

- initCostCentres :: CollectedCCs -> G ()
- emitCostCentreDecl :: CostCentre -> G ()
- emitCostCentreStackDecl :: CostCentreStack -> G ()
- enterCostCentreFun :: CostCentreStack -> JStgStat
- enterCostCentreThunk :: JStgStat
- setCC :: CostCentre -> Bool -> Bool -> G JStgStat
- pushRestoreCCS :: JStgStat
- jCurrentCCS :: JStgExpr
- jCafCCS :: JStgExpr
- jSystemCCS :: JStgExpr
- costCentreLbl :: CostCentre -> G Ident
- costCentreStackLbl :: CostCentreStack -> G (Maybe Ident)
- singletonCCSLbl :: CostCentre -> G Ident
- ccsVarJ :: CostCentreStack -> G (Maybe JStgExpr)
- profiling :: G Bool
- ifProfiling :: Monoid m => m -> G m
- ifProfilingM :: Monoid m => G m -> G m
- profStat :: StgToJSConfig -> JStgStat -> JStgStat

# Documentation

initCostCentres :: CollectedCCs -> G () Source #

emitCostCentreDecl :: CostCentre -> G () Source #

emitCostCentreStackDecl :: CostCentreStack -> G () Source #

enterCostCentreFun :: CostCentreStack -> JStgStat Source #

enterCostCentreThunk :: JStgStat Source #

setCC :: CostCentre -> Bool -> Bool -> G JStgStat Source #

pushRestoreCCS :: JStgStat Source #

jCurrentCCS :: JStgExpr Source #

jCafCCS :: JStgExpr Source #

jSystemCCS :: JStgExpr Source #

costCentreLbl :: CostCentre -> G Ident Source #

costCentreStackLbl :: CostCentreStack -> G (Maybe Ident) Source #

singletonCCSLbl :: CostCentre -> G Ident Source #

ccsVarJ :: CostCentreStack -> G (Maybe JStgExpr) Source #

# Predicates

profiling :: G Bool Source #

ifProfiling :: Monoid m => m -> G m Source #

ifProfilingM :: Monoid m => G m -> G m Source #

# helpers

profStat :: StgToJSConfig -> JStgStat -> JStgStat Source #

If profiling is enabled, then use input JStgStat, else ignore