add bench/oading-benchmark.pl
gfx [Mon, 6 Jul 2009 07:20:16 +0000 (16:20 +0900)]
bench/loading-benchmark.pl [new file with mode: 0755]

diff --git a/bench/loading-benchmark.pl b/bench/loading-benchmark.pl
new file mode 100755 (executable)
index 0000000..3719350
--- /dev/null
@@ -0,0 +1,14 @@
+#!perl -w\r
+use strict;\r
+use Benchmark qw(:all);\r
+\r
+my $module = 'Moose';\r
+\r
+cmpthese timethese 10 => {\r
+       released => sub{\r
+               system($^X, '-e', "require $module") == 0 or die;\r
+       },\r
+       blead => sub{\r
+               system($^X, '-Iblib/lib', '-Iblib/arch', '-e', "require $module") == 0 or die;\r
+       },\r
+};\r