GHC.CmmToAsm.CFG.Weight

ghc-9.2.0.20210422: The GHC API

Safe Haskell | Safe-Inferred
Language | Haskell2010

GHC.CmmToAsm.CFG.Weight

Synopsis

- data Weights = Weights {
  - uncondWeight :: Int
  - condBranchWeight :: Int
  - switchWeight :: Int
  - callWeight :: Int
  - likelyCondWeight :: Int
  - unlikelyCondWeight :: Int
  - infoTablePenalty :: Int
  - backEdgeBonus :: Int
  }
- defaultWeights :: Weights
- parseWeights :: String -> Weights -> Weights

# Documentation

data Weights Source #

Edge weights to use when generating a CFG from CMM

Constructors

Weights |
Fields uncondWeight :: Int condBranchWeight :: Int switchWeight :: Int callWeight :: Int likelyCondWeight :: Int unlikelyCondWeight :: Int infoTablePenalty :: Int backEdgeBonus :: Int

defaultWeights :: Weights Source #

Default edge weights

parseWeights :: String -> Weights -> Weights Source #