ghc-6.12.2: The GHC APISource codeContentsIndex
OptimizationFuel
Description

Optimisation fuel is used to control the amount of work the optimiser does.

Every optimisation step consumes a certain amount of fuel and stops when it runs out of fuel. This can be used e.g. to debug optimiser bugs: Run the optimiser with varying amount of fuel to find out the exact number of steps where a bug is introduced in the output.

Documentation
data OptimizationFuel Source
show/hide Instances
canRewriteWithFuel :: OptimizationFuel -> BoolSource
maybeRewriteWithFuel :: OptimizationFuel -> Maybe a -> Maybe aSource
oneLessFuel :: OptimizationFuel -> OptimizationFuelSource
data OptFuelState Source
initOptFuelState :: IO OptFuelStateSource
tankFilledTo :: Int -> OptimizationFuelSource
diffFuel :: OptimizationFuel -> OptimizationFuel -> IntSource
type FuelConsumer a = OptimizationFuel -> (a, OptimizationFuel)Source
class Monad m => FuelUsingMonad m whereSource
Methods
fuelRemaining :: m OptimizationFuelSource
fuelDecrement :: String -> OptimizationFuel -> OptimizationFuel -> m ()Source
fuelDec1 :: m ()Source
fuelExhausted :: m BoolSource
lastFuelPass :: m StringSource
show/hide Instances
data FuelState Source
runFuelIO :: OptFuelState -> FuelMonad a -> IO aSource
fuelConsumingPass :: String -> FuelConsumer a -> FuelMonad aSource
data FuelMonad a Source
show/hide Instances
liftUniq :: UniqSM x -> FuelMonad xSource
lGraphOfGraph :: Graph m l -> FuelMonad (LGraph m l)Source
Produced by Haddock version 2.6.1