class Benchmark::IPS::Report

Perform operations like add new entry, run comparison between entries.
Report contains benchamrking entries.

def add_entry label, microseconds, iters, ips, ips_sd, measurement_cycle

Returns:
  • (Entry) - Last added entry.

Parameters:
  • measurement_cycle (Integer) -- Number of cycles.
  • ips_sd (Float) -- Standard deviation of iterations per second.
  • ips (Float) -- Average Iterations per second.
  • iters (Integer) -- Iterations.
  • microseconds (Integer) -- Measured time in microsecond.
  • label (String) -- Entry label.
def add_entry label, microseconds, iters, ips, ips_sd, measurement_cycle
  @entries << Entry.new(label, microseconds, iters, ips, ips_sd, measurement_cycle)
  @entries.last
end

def initialize

Instantiate the Report.
def initialize
  @entries = []
end

def run_comparison

Run comparison of entries.
def run_comparison
  Benchmark.compare(*@entries)
end