]> git.saurik.com Git - apple/icu.git/blob - icuSources/test/perf/ubrkperf/UBrkPerf.pl
ICU-6.2.4.tar.gz
[apple/icu.git] / icuSources / test / perf / ubrkperf / UBrkPerf.pl
1 #!/usr/bin/perl
2 # ********************************************************************
3 # * COPYRIGHT:
4 # * Copyright (c) 2002, International Business Machines Corporation and
5 # * others. All Rights Reserved.
6 # ********************************************************************
7
8 use strict;
9
10 use lib '../perldriver';
11
12 use PerfFramework;
13
14 my $options = {
15 "title"=>"BreakIterator performance regression (ICU 2.0, 2.2 and 2.4)",
16 "headers"=>"ICU20 ICU22 ICU24",
17 "operationIs"=>"code point",
18 "eventIs"=>"break",
19 "passes"=>"10",
20 "time"=>"5",
21 #"outputType"=>"HTML",
22 "dataDir"=>"c:/src/perf/data",
23 "outputDir"=>"../results"
24 };
25
26 # programs
27 # tests will be done for all the programs. Results will be stored and connected
28 my $m1 = "-- -m char";
29 my $m2 = "-- -m word";
30 my $m3 = "-- -m line";
31 my $m4 = "-- -m sentence";
32
33 my $m;
34
35 if(@_ >= 0) {
36 $m = "-- -m ".shift;
37 } else {
38 $m = $m1;
39 }
40
41 my $p1 = "ubrkperf20.exe";
42 my $p2 = "ubrkperf22.exe";
43 my $p3 = "ubrkperf24.exe";
44
45 my $dataFiles = {
46 "en", ["thesis.txt",
47 #"2drvb10.txt",
48 #"ulyss10.txt",
49 "nvsbl10.txt",
50 "vfear11a.txt",
51 "TestNames_Asian.txt",
52 "TestNames_Chinese.txt",
53 "TestNames_Japanese.txt",
54 "TestNames_Japanese_h.txt",
55 "TestNames_Japanese_k.txt",
56 "TestNames_Korean.txt",
57 "TestNames_Latin.txt",
58 "TestNames_SerbianSH.txt",
59 "TestNames_SerbianSR.txt",
60 "TestNames_Thai.txt",
61 "Testnames_Russian.txt",
62 ],
63 #"th", ["TestNames_Thai.txt", "th18057.txt"]
64 };
65
66
67 my $tests = {
68 "TestForwardChar", ["$p1 $m1 TestICUForward", "$p2 $m1 TestICUForward", "$p3 $m1 TestICUForward"],
69 "TestForwardWord", ["$p1 $m2 TestICUForward", "$p2 $m2 TestICUForward", "$p3 $m2 TestICUForward"],
70 "TestForwardLine", ["$p1 $m3 TestICUForward", "$p2 $m3 TestICUForward", "$p3 $m3 TestICUForward"],
71 "TestForwardSentence", ["$p1 $m4 TestICUForward", "$p2 $m4 TestICUForward", "$p3 $m4 TestICUForward"],
72
73 "TestIsBoundChar", ["$p1 $m1 TestICUIsBound", "$p2 $m1 TestICUIsBound", "$p3 $m1 TestICUIsBound"],
74 "TestIsBoundWord", ["$p1 $m2 TestICUIsBound", "$p2 $m2 TestICUIsBound", "$p3 $m2 TestICUIsBound"],
75 "TestIsBoundLine", ["$p1 $m3 TestICUIsBound", "$p2 $m3 TestICUIsBound", "$p3 $m3 TestICUIsBound"],
76 "TestIsBoundSentence", ["$p1 $m4 TestICUIsBound", "$p2 $m4 TestICUIsBound", "$p3 $m4 TestICUIsBound"],
77
78 };
79
80 runTests($options, $tests, $dataFiles);
81
82