576
|
1 #!/usr/bin/perl -w
|
|
2 use strict;
|
|
3 use constant CMD => "./fastmem2-k7";
|
|
4
|
|
5 sub dobench {
|
|
6 my $i;
|
|
7 my ($runs, $sleep, $command) = @_;
|
|
8 for($i = 0; $i < $runs; $i++) {
|
|
9 sleep $sleep;
|
|
10 system $command;
|
|
11 }
|
|
12 }
|
|
13
|
|
14 print "Single run of sse bench with 1sec sleep:\n";
|
|
15 &dobench(1,1,CMD);
|
|
16 print "Sleeping 10seconds before starting next bench!\n";
|
|
17 sleep 10;
|
|
18 print "10 runs of sse bench with 0sec sleep:\n";
|
|
19 &dobench(10,0,CMD);
|
|
20 print "Sleeping 10seconds before starting next bench!\n";
|
|
21 sleep 10;
|
|
22 print "10 runs of sse bench with 1sec sleep:\n";
|
|
23 &dobench(10,1,CMD);
|
|
24 print "Sleeping 10seconds before starting next bench!\n";
|
|
25 sleep 10;
|
|
26 print "10 runs of sse bench with 2sec sleep:\n";
|
|
27 &dobench(10,2,CMD);
|
|
28 print "Sleeping 10seconds before starting next bench!\n";
|
|
29 sleep 10;
|
|
30 print "10 runs of sse bench with 3sec sleep:\n";
|
|
31 &dobench(10,3,CMD);
|
|
32 print "Bench finished!\n";
|