package multicore-bench

  1. Overview
  2. Docs

Command line interface for a benchmark executable.

val run : benchmarks:(string * Suite.t) list -> ?budgetf:float -> ?filters:string list -> ?debug:bool -> ?argv:string array -> ?flush:bool -> unit -> unit

run ~benchmarks () interprets command line arguments and runs the benchmarks suites based on the arguments.

Optional arguments:

  • ~budgetf: A budget (usually) in seconds passed to each benchmark suite. This defaults to a small number so that a benchmark suite can be used as a test.
  • ~filters: A list of regular expressions to match names of benchmark suites. If any regular expression matches the name of benchmark, then that benchmark will be run. Defaults to [].
  • ~argv: Array of command line arguments. Defaults to Sys.argv.
  • ~flush: Whether to flush the standard output after writing it. Defaults to true.

Command line arguments take precedence over the optional arguments. In other words, you can specify the optional arguments to give defaults for the benchmark executable.

OCaml

Innovation. Community. Security.