View Source BeamBenchmarks.Bencherl (beam_benchmarks v0.2.0)

Bencherl benchmarks

See https://github.com/softlab-ntua/bencherl

Summary

Types

Options for running bencherl tests

Functions

Run bencherl's bang test

Run bencherl's big test

Run bencherl's ehb test

Run bencherl's ets_random_ops test

Run bencherl's ets_test test

Run bencherl's genstress test

Run bencherl's mbrot test

Run bencherl's moves test

Run bencherl's orbit_int test

Run bencherl's parallel test

Run bencherl's pcmark test

Run bencherl's ran test

Run all bencherl tests

Run bencherl's serialmsg test

Run bencherl's timer_wheel test

Types

bencherl_options()

@type bencherl_options() :: [
  version: bencherl_version(),
  number_of_cores: non_neg_integer()
]

Options for running bencherl tests

  • version - run a :short, :intermediate, :long version. Default is :short.
  • number_of_cores - the number of cores to use. Default is the number of schedulers.

bencherl_version()

@type bencherl_version() :: :short | :intermediate | :long

Functions

bang(opts \\ [])

Run bencherl's bang test

A benchmark for many-to-one message passing that spawns one receiver and multiple senders that flood the receiver with messages.

big(opts \\ [])

Run bencherl's big test

A benchmark that implements a many-to-many message passing scenario.

ehb(opts \\ [])

Run bencherl's ehb test

This is an implementation of hackbench in Erlang, a benchmark and stress test for Linux schedulers.

ets_random_ops(opts \\ [])

@spec ets_random_ops(bencherl_options()) :: BeamBenchmarks.Results.t()

Run bencherl's ets_random_ops test

This benchmark creates an ETS table and spawns several readers and writers that perform a certain number of reads (lookups) and writes (inserts), respectively, to that table.

ets_test(opts \\ [])

Run bencherl's ets_test test

This benchmark creates an ETS table and spawns several readers and writers that perform a certain number of reads (lookups) and writes (inserts), respectively, to that table.

genstress(opts \\ [])

@spec genstress(bencherl_options()) :: BeamBenchmarks.Results.t()

Run bencherl's genstress test

This is a generic server benchmark that spawns an echo server and a number of clients.

mbrot(opts \\ [])

Run bencherl's mbrot test

This benchmark extrapolates the coordinates of a 2-D complex plane that correspond to the pixels of a 2-D image of a specific resolution.

moves(opts \\ [])

Run bencherl's moves test

Parallel benchmark program that solves the moves problem. A description of the moves problem can be found in the ETS implementation report that can be found here:

https://github.com/kjellwinblad/ets_impl_project

orbit_int(opts \\ [])

@spec orbit_int(bencherl_options()) :: BeamBenchmarks.Results.t()

Run bencherl's orbit_int test

This benchmark operates on a distributed hash table, and follows a master/worker architecture.

parallel(opts \\ [])

Run bencherl's parallel test

A benchmark for parallel execution that spawns a number of processes, each of which creates a list of $N$ timestamps and, after it checks that each element of the list is strictly greater than its previous one (as promised by the implementation of erlang:now/0), it sends the result to its parent.

pcmark(opts \\ [])

Run bencherl's pcmark test

This benchmark is also about ETS operations. It creates five ETS tables, fills them with values, and then spawns a certain number of processes that read the contents of those tables and update them. As soon as one process finishes, a new process is spawned, until a certain total number of processes has been reached. The benchmark is parameterized by the number of initial processes and the total number of processes.

ran(opts \\ [])

Run bencherl's ran test

Another benchmark for parallel execution that spawns a certain number of processes, each of which generates a list of ten thousand random integers, sorts it and sends its first half to the parent process. The benchmark receives the number of processes as a parameter.

run_all(opts \\ [])

@spec run_all(bencherl_options()) :: [non_neg_integer()]

Run all bencherl tests

serialmsg(opts \\ [])

@spec serialmsg(bencherl_options()) :: BeamBenchmarks.Results.t()

Run bencherl's serialmsg test

A benchmark about message proxying through a dispatcher. The benchmark spawns a certain number of receivers, one dispatcher, and a certain number of generators. The dispatcher forwards the messages that it receives from generators to the appropriate receiver. Each generator sends a number of messages to a specific receiver.

timer_wheel(opts \\ [])

@spec timer_wheel(bencherl_options()) :: BeamBenchmarks.Results.t()

Run bencherl's timer_wheel test

A timer management benchmark that spawns a certain number of processes that exchange ping and pong messages.