#!perl

use 5.010001;
use strict;
use warnings;

use Benchmark::Command;

Benchmark::Command::run(
    undef,
    {
        'none'         => [$^X, "-e1"],
        'Exporter'     => [$^X, "-e", "use Exporter"],
        'Getopt::Long' => [$^X, "-e", "use Getopt::Long"],
        'Carp'         => [$^X, "-e", "use Carp"],
        'File::Spec'   => [$^X, "-e", "use File::Spec"],
        'FindBin'      => [$^X, "-e", "use FindBin"],
    },
);

# ABSTRACT: Benchmark startup time of various Perl modules commonly used in code preamble
# PODNAME: bench-startup-preamble-modules

__END__

=pod

=encoding UTF-8

=head1 NAME

bench-startup-preamble-modules - Benchmark startup time of various Perl modules commonly used in code preamble

=head1 VERSION

This document describes version 0.01 of bench-startup-preamble-modules (from Perl distribution App-BenchStartupPreambleModules), released on 2015-06-14.

=head1 SYNOPSIS

 % bench-startup-preamble-modules

Sample output:

                          Rate       FindBin Getopt::Long    File::Spec         Carp    Exporter   none
 FindBin      116.223+-0.045/s            --        -5.7%        -46.6%       -52.4%      -83.9% -87.8%
 Getopt::Long 123.306+-0.092/s          6.1%           --        -43.4%       -49.5%      -82.9% -87.1%
 File::Spec     217.69+-0.18/s   87.3+-0.17%  76.54+-0.2%            --       -10.8%      -69.8% -77.2%
 Carp           244.15+-0.17/s 110.07+-0.17%  98.01+-0.2%  12.16+-0.12%           --      -66.1% -74.4%
 Exporter         720.2+-1.9/s   519.7+-1.6%  484.1+-1.6% 230.85+-0.91% 194.98+-0.8%          -- -24.5%
 none             954.1+-2.6/s   720.9+-2.3%  673.8+-2.2%   338.3+-1.2%  290.8+-1.1% 32.47+-0.5%     --
 
 Average times:
   none        :     1.0481ms
   Exporter    :     1.3885ms
   Carp        :     4.0958ms
   File::Spec  :     4.5937ms
   Getopt::Long:     8.1099ms
   FindBin     :     8.6041ms

=head1 SEE ALSO

L<bench-startup-pragmas>

=head1 HOMEPAGE

Please visit the project's homepage at L<https://metacpan.org/release/App-BenchStartupPreambleModules>.

=head1 SOURCE

Source repository is at L<https://github.com/perlancar/perl-App-BenchStartupPreambleModules>.

=head1 BUGS

Please report any bugs or feature requests on the bugtracker website L<https://rt.cpan.org/Public/Dist/Display.html?Name=App-BenchStartupPreambleModules>

When submitting a bug or request, please include a test-file or a
patch to an existing test-file that illustrates the bug or desired
feature.

=head1 AUTHOR

perlancar <perlancar@cpan.org>

=head1 COPYRIGHT AND LICENSE

This software is copyright (c) 2015 by perlancar@cpan.org.

This is free software; you can redistribute it and/or modify it under
the same terms as the Perl 5 programming language system itself.

=cut
