GHC.CmmToAsm.CFG.Weight

ghc-lib-parser-9.10.1.20250103: The GHC API, decoupled from GHC versions

Safe Haskell | Ignore
Language | GHC2021

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 #

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 #

Default edge weights

parseWeights :: String -> Weights -> Weights #