Benchee v0.12.0 Benchee.Benchmark View Source

Functions related to building and running benchmarking scenarios. Exposes benchmark/4 and measure/3 functions.

Link to this section Summary

Functions

Takes the current suite and adds a new benchmarking scenario (represented by a %Scenario{} struct) to the suite’s scenarios. If there are inputs in the suite’s config, a scenario will be added for the given function for each input

Kicks off the benchmarking of all scenarios in the suite by passing the list of scenarios and a scenario context to our benchmark runner. For more information on how bencharmks are actually run, see Benchee.Benchmark.Runner.run_scenarios/2

Public access for the key representing no input for a scenario

Link to this section Types

Link to this type job_name() View Source
job_name() :: String.t() | atom()

Link to this section Functions

Link to this function benchmark(suite, job_name, function, printer \\ Printer) View Source
benchmark(Benchee.Suite.t(), job_name(), (... -> any()), module()) :: Benchee.Suite.t()

Takes the current suite and adds a new benchmarking scenario (represented by a %Scenario{} struct) to the suite’s scenarios. If there are inputs in the suite’s config, a scenario will be added for the given function for each input.

Link to this function measure(suite, printer \\ Printer, runner \\ Runner) View Source
measure(Benchee.Suite.t(), module(), module()) :: Benchee.Suite.t()

Kicks off the benchmarking of all scenarios in the suite by passing the list of scenarios and a scenario context to our benchmark runner. For more information on how bencharmks are actually run, see Benchee.Benchmark.Runner.run_scenarios/2.

Public access for the key representing no input for a scenario.