Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(385)

Side by Side Diff: source/test/perf/DateFmtPerf/DateFmtPerf.cpp

Issue 1621843002: ICU 56 update step 1 (Closed) Base URL: https://chromium.googlesource.com/chromium/deps/icu.git@561
Patch Set: Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 ********************************************************************** 2 **********************************************************************
3 * Copyright (c) 2002-2011,International Business Machines 3 * Copyright (c) 2002-2014,International Business Machines
4 * Corporation and others. All Rights Reserved. 4 * Corporation and others. All Rights Reserved.
5 ********************************************************************** 5 **********************************************************************
6 ********************************************************************** 6 **********************************************************************
7 */ 7 */
8 8
9 #include "DateFmtPerf.h" 9 #include "DateFmtPerf.h"
10 #include "uoptions.h" 10 #include "uoptions.h"
11 #include <stdio.h> 11 #include <stdio.h>
12 #include <fstream> 12 #include <fstream>
13 13
(...skipping 21 matching lines...) Expand all
35 TESTCASE(1,DateFmt10000); 35 TESTCASE(1,DateFmt10000);
36 TESTCASE(2,DateFmt100000); 36 TESTCASE(2,DateFmt100000);
37 TESTCASE(3,BreakItWord250); 37 TESTCASE(3,BreakItWord250);
38 TESTCASE(4,BreakItWord10000); 38 TESTCASE(4,BreakItWord10000);
39 TESTCASE(5,BreakItChar250); 39 TESTCASE(5,BreakItChar250);
40 TESTCASE(6,BreakItChar10000); 40 TESTCASE(6,BreakItChar10000);
41 TESTCASE(7,NumFmt10000); 41 TESTCASE(7,NumFmt10000);
42 TESTCASE(8,NumFmt100000); 42 TESTCASE(8,NumFmt100000);
43 TESTCASE(9,Collation10000); 43 TESTCASE(9,Collation10000);
44 TESTCASE(10,Collation100000); 44 TESTCASE(10,Collation100000);
45 TESTCASE(11, DIFCreate250);
46 TESTCASE(12, DIFCreate10000);
47 TESTCASE(13, TimeZoneCreate250);
48 TESTCASE(14, TimeZoneCreate10000);
49 TESTCASE(15, DTPatternGeneratorCreate250);
50 TESTCASE(16, DTPatternGeneratorCreate10000);
51 TESTCASE(17, DTPatternGeneratorCopy250);
52 TESTCASE(18, DTPatternGeneratorCopy10000);
53 TESTCASE(19, DTPatternGeneratorBestValue250);
54 TESTCASE(20, DTPatternGeneratorBestValue10000);
55 TESTCASE(21,DateFmtCopy250);
56 TESTCASE(22,DateFmtCopy10000);
57 TESTCASE(23,DateFmtCreate250);
58 TESTCASE(24,DateFmtCreate10000);
59
45 60
46 default: 61 default:
47 name = ""; 62 name = "";
48 return NULL; 63 return NULL;
49 } 64 }
50 return NULL; 65 return NULL;
51 } 66 }
52 67
53 68
54 UPerfFunction* DateFormatPerfTest::DateFmt250(){ 69 UPerfFunction* DateFormatPerfTest::DateFmt250(){
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 CollationFunction* func= new CollationFunction(40, locale); 115 CollationFunction* func= new CollationFunction(40, locale);
101 return func; 116 return func;
102 } 117 }
103 118
104 UPerfFunction* DateFormatPerfTest::Collation100000(){ 119 UPerfFunction* DateFormatPerfTest::Collation100000(){
105 CollationFunction* func= new CollationFunction(400, locale); 120 CollationFunction* func= new CollationFunction(400, locale);
106 return func; 121 return func;
107 } 122 }
108 123
109 124
125 UPerfFunction *DateFormatPerfTest::DIFCreate250() {
126 DIFCreateFunction* func = new DIFCreateFunction(250, locale);
127 return func;
128 }
129
130 UPerfFunction *DateFormatPerfTest::DIFCreate10000() {
131 DIFCreateFunction* func = new DIFCreateFunction(10000, locale);
132 return func;
133 }
134
135 UPerfFunction *DateFormatPerfTest::TimeZoneCreate250() {
136 return new TimeZoneCreateFunction(250, locale);
137 }
138
139 UPerfFunction *DateFormatPerfTest::TimeZoneCreate10000() {
140 return new TimeZoneCreateFunction(10000, locale);
141 }
142
143 UPerfFunction *DateFormatPerfTest::DTPatternGeneratorCreate250() {
144 return new DTPatternGeneratorCreateFunction(250, locale);
145 }
146
147 UPerfFunction *DateFormatPerfTest::DTPatternGeneratorCreate10000() {
148 return new DTPatternGeneratorCreateFunction(10000, locale);
149 }
150
151 UPerfFunction *DateFormatPerfTest::DTPatternGeneratorCopy250() {
152 return new DTPatternGeneratorCopyFunction(250, locale);
153 }
154
155 UPerfFunction *DateFormatPerfTest::DTPatternGeneratorCopy10000() {
156 return new DTPatternGeneratorCopyFunction(10000, locale);
157 }
158
159 UPerfFunction *DateFormatPerfTest::DTPatternGeneratorBestValue250() {
160 return new DTPatternGeneratorBestValueFunction(250, locale);
161 }
162
163 UPerfFunction *DateFormatPerfTest::DTPatternGeneratorBestValue10000() {
164 return new DTPatternGeneratorBestValueFunction(10000, locale);
165 }
166
167 UPerfFunction* DateFormatPerfTest::DateFmtCopy250(){
168 return new DateFmtCopyFunction(250, locale);
169 }
170
171 UPerfFunction* DateFormatPerfTest::DateFmtCopy10000(){
172 return new DateFmtCopyFunction(10000, locale);
173 }
174
175 UPerfFunction* DateFormatPerfTest::DateFmtCreate250(){
176 return new DateFmtCreateFunction(250, locale);
177 }
178
179 UPerfFunction* DateFormatPerfTest::DateFmtCreate10000(){
180 return new DateFmtCreateFunction(10000, locale);
181 }
182
110 183
111 int main(int argc, const char* argv[]){ 184 int main(int argc, const char* argv[]){
112 185
113 // -x Filename.xml 186 // -x Filename.xml
114 if((argc>1)&&(strcmp(argv[1],"-x") == 0)) 187 if((argc>1)&&(strcmp(argv[1],"-x") == 0))
115 { 188 {
116 if(argc < 3) { 189 if(argc < 3) {
117 fprintf(stderr, "Usage: %s -x <outfile>.xml\n", argv[0]) ; 190 fprintf(stderr, "Usage: %s -x <outfile>.xml\n", argv[0]) ;
118 return 1; 191 return 1;
119 // not enough arguments 192 // not enough arguments
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 281
209 if(test.run()==FALSE){ 282 if(test.run()==FALSE){
210 cout << "run failed!" << endl; 283 cout << "run failed!" << endl;
211 fprintf(stderr,"FAILED: Tests could not be run please check the argument s.\n"); 284 fprintf(stderr,"FAILED: Tests could not be run please check the argument s.\n");
212 return -1; 285 return -1;
213 } 286 }
214 cout << "done!" << endl; 287 cout << "done!" << endl;
215 288
216 return 0; 289 return 0;
217 } 290 }
OLDNEW
« no previous file with comments | « source/test/perf/DateFmtPerf/DateFmtPerf.h ('k') | source/test/perf/DateFmtPerf/DateFmtPerf.vcxproj » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698