]>
Commit | Line | Data |
---|---|---|
46f4442e A |
1 | #!/usr/bin/perl |
2 | # ******************************************************************** | |
3 | # * COPYRIGHT: | |
57a6839d | 4 | # * Copyright (c) 2005-2013, International Business Machines Corporation and |
46f4442e A |
5 | # * others. All Rights Reserved. |
6 | # ******************************************************************** | |
7 | ||
8 | #use strict; | |
9 | ||
10 | require "../perldriver/Common.pl"; | |
11 | ||
12 | use lib '../perldriver'; | |
13 | ||
14 | use PerfFramework; | |
15 | ||
16 | my $options = { | |
57a6839d A |
17 | "title"=>"UnicodeSet span()/contains() performance", |
18 | "headers"=>"Bv Bv0", | |
19 | "operationIs"=>"tested Unicode code point", | |
20 | "passes"=>"3", | |
21 | "time"=>"2", | |
22 | #"outputType"=>"HTML", | |
23 | "dataDir"=>$UDHRDataPath, | |
24 | "outputDir"=>"../results" | |
25 | }; | |
46f4442e A |
26 | |
27 | # programs | |
28 | # tests will be done for all the programs. Results will be stored and connected | |
29 | my $p; | |
30 | if ($OnWindows) { | |
57a6839d | 31 | $p = "cd ".$ICULatest."/bin && ".$ICUPathLatest."/unisetperf/$WindowsPlatform/Release/unisetperf.exe"; |
46f4442e | 32 | } else { |
57a6839d | 33 | $p = "LD_LIBRARY_PATH=".$ICULatest."/source/lib:".$ICULatest."/source/tools/ctestfw ".$ICUPathLatest."/unisetperf/unisetperf"; |
46f4442e | 34 | } |
46f4442e A |
35 | |
36 | my $tests = { | |
57a6839d A |
37 | "Contains", |
38 | [ | |
39 | "$p,Contains --type Bv", | |
40 | "$p,Contains --type Bv0" | |
41 | ], | |
42 | "SpanUTF16", | |
43 | [ | |
44 | "$p,SpanUTF16 --type Bv", | |
45 | "$p,SpanUTF16 --type Bv0" | |
46 | ] | |
47 | }; | |
46f4442e A |
48 | |
49 | my $dataFiles = { | |
57a6839d A |
50 | "", |
51 | [ | |
52 | "udhr_eng.txt", | |
53 | "udhr_deu_1996.txt", | |
54 | "udhr_fra.txt", | |
55 | "udhr_rus.txt", | |
56 | "udhr_tha.txt", | |
57 | "udhr_jpn.txt", | |
58 | "udhr_cmn_hans.txt", | |
59 | "udhr_cmn_hant.txt", | |
60 | "udhr_jpn.html" | |
61 | ] | |
62 | }; | |
46f4442e A |
63 | |
64 | runTests($options, $tests, $dataFiles); | |
65 | ||
66 | $options = { | |
57a6839d A |
67 | "title"=>"UnicodeSet span()/contains() performance", |
68 | "headers"=>"Bv BvF Bvp BvpF L Bvl", | |
69 | "operationIs"=>"tested Unicode code point", | |
70 | "passes"=>"3", | |
71 | "time"=>"2", | |
72 | #"outputType"=>"HTML", | |
73 | "dataDir"=>$UDHRDataPath, | |
74 | "outputDir"=>"../results" | |
75 | }; | |
46f4442e A |
76 | |
77 | $tests = { | |
57a6839d A |
78 | "SpanUTF8", |
79 | [ | |
80 | "$p,SpanUTF8 --type Bv", | |
81 | "$p,SpanUTF8 --type BvF", | |
82 | "$p,SpanUTF8 --type Bvp", | |
83 | "$p,SpanUTF8 --type BvpF", | |
84 | "$p,SpanUTF8 --type L", | |
85 | "$p,SpanUTF8 --type Bvl" | |
86 | ] | |
87 | }; | |
46f4442e A |
88 | |
89 | runTests($options, $tests, $dataFiles); |