table of contents
Dumbbench::Instance::Cmd(3) | User Contributed Perl Documentation | Dumbbench::Instance::Cmd(3) |
NAME¶
Dumbbench::Instance::Cmd - Benchmarks an external command
SYNOPSIS¶
use Dumbbench; my $bench = Dumbbench->new( target_rel_precision => 0.005, # seek ~0.5% initial_runs => 20, # the higher the more reliable ); $bench->add_instances( Dumbbench::Instance::Cmd->new(name => 'mauve', command => [qw(perl -e 'something')]), # ... more things to benchmark ... ); $bench->run(); # ...
DESCRIPTION¶
This class inherits from Dumbbench::Instance and implements benchmarking of external commands.
METHODS¶
new¶
Constructor that takes named arguments.
In addition to the properties of the base class, the "Dumbbench::Instance::Cmd" constructor requires a "command" parameter. "command" can either be string specifying the external command with its options or (preferably) a reference to an array of command-name and options (as with the ordinary "system" builtin).
Optionally, you can provide a "dry_run_command" option. It has the same structure and purpose as the "command" option, but it is used for the dry-runs. If "dry_run_command" is not specified, the dry-run will consist of starting another process that immediately exits.
command¶
Returns the command that was set on object construction.
dry_run_command¶
Returns the command that was set for dry-runs on object construction.
SEE ALSO¶
Dumbbench, Dumbbench::Instance, Dumbbench::Instance::PerlEval, Dumbbench::Instance::PerlSub, Dumbbench::Result
Benchmark
Number::WithError does the Gaussian error propagation.
SOOT can optionally generate histograms from the timing distributions.
AUTHOR¶
Steffen Mueller, <smueller@cpan.org>
COPYRIGHT AND LICENSE¶
Copyright (C) 2010 by Steffen Mueller
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.1 or, at your option, any later version of Perl 5 you may have available.
2024-10-16 | perl v5.40.0 |