criterion-0.6.0.1: Robust, reliable performance measurement and analysis

Portability | GHC
Stability | experimental
Maintainer | bos@serpentine.com

Criterion.Config

Description

Benchmarking configuration.

Synopsis

- data Config = Config {
  - cfgBanner :: Last String
  - cfgConfInterval :: Last Double
  - cfgPerformGC :: Last Bool
  - cfgPrintExit :: PrintExit
  - cfgResamples :: Last Int
  - cfgReport :: Last FilePath
  - cfgSamples :: Last Int
  - cfgSummaryFile :: Last FilePath
  - cfgTemplate :: Last FilePath
  - cfgVerbosity :: Last Verbosity
  }
- data PrintExit
  - = Nada
  - | List
  - | Version
  - | Help
- data Verbosity
  - = Quiet
  - | Normal
  - | Verbose
- defaultConfig :: Config
- fromLJ :: (Config -> Last a) -> Config -> a
- ljust :: a -> Last a

# Documentation

data Config

Top-level program configuration.

Constructors

Config |

Fields

cfgBanner :: Last String

  The "version" banner to print.

cfgConfInterval :: Last Double

  Confidence interval to use.

cfgPerformGC :: Last Bool

  Whether to run the GC between passes.

cfgPrintExit :: PrintExit

  Whether to print information and exit.

cfgResamples :: Last Int

  Number of resamples to perform.

cfgReport :: Last FilePath

  Filename of report.

cfgSamples :: Last Int

  Number of samples to collect.

cfgSummaryFile :: Last FilePath

  Filename of summary CSV.

cfgTemplate :: Last FilePath

  Filename of report template.

cfgVerbosity :: Last Verbosity

  Whether to run verbosely.

Instances

Eq Config |
Read Config |
Show Config |
Typeable Config |
Monoid Config |
MonadReader Config Criterion |

data PrintExit

Print some information and exit, without running any benchmarks.

Constructors

Nada | Do not actually print-and-exit. (Default.)
List | Print a list of known benchmarks.
Version | Print version information (if known).
Help | Print a help/usaage message.

Instances

Bounded PrintExit |
Enum PrintExit |
Eq PrintExit |
Data PrintExit |
Ord PrintExit |
Read PrintExit |
Show PrintExit |
Typeable PrintExit |
Monoid PrintExit |

data Verbosity

Control the amount of information displayed.

Constructors

Quiet |
Normal |
Verbose |

Instances

Bounded Verbosity |
Enum Verbosity |
Eq Verbosity |
Ord Verbosity |
Read Verbosity |
Show Verbosity |
Typeable Verbosity |

defaultConfig :: Config

A configuration with sensible defaults.

fromLJ

Arguments

:: (Config -> Last a) | Field to access.
-> Config | Default to use.
-> a |

Deconstructor for `Last` values.

ljust :: a -> Last a

Constructor for `Last` values.