2 **********************************************************************
3 * Copyright (c) 2002-2005, International Business Machines
4 * Corporation and others. All Rights Reserved.
5 **********************************************************************
6 **********************************************************************
9 * This Program tests the performance of ICU's Normalization engine against Windows
10 * to run it use the command like
12 * c:\normperf.exe -s C:\work\ICUCupertinoRep\icu4c\collation-perf-data -i 10 -p 15 -f TestNames_Asian.txt -u -e UTF-8 -l
18 int main(int argc
, const char* argv
[]){
19 UErrorCode status
= U_ZERO_ERROR
;
20 ConverterPerformanceTest
test(argc
, argv
, status
);
21 if(U_FAILURE(status
)){
24 if(test
.run()==FALSE
){
25 fprintf(stderr
,"FAILED: Tests could not be run please check the arguments.\n");
32 ConverterPerformanceTest::ConverterPerformanceTest(int32_t argc
, const char* argv
[], UErrorCode
& status
)
33 : UPerfTest(argc
,argv
,status
){
37 ConverterPerformanceTest::~ConverterPerformanceTest(){
41 UPerfFunction
* ConverterPerformanceTest::runIndexedTest(int32_t index
, UBool exec
,const char* &name
, char* par
) {
43 TESTCASE(0,TestICU_CleanOpenAllConverters
);// This calls u_cleanup()
44 TESTCASE(1,TestICU_OpenAllConverters
);// This doesn't call u_cleanup()
46 TESTCASE(2,TestICU_UTF8_ToUnicode
);
47 TESTCASE(3,TestICU_UTF8_FromUnicode
);
48 TESTCASE(4,TestWinANSI_UTF8_ToUnicode
);
49 TESTCASE(5,TestWinANSI_UTF8_FromUnicode
);
50 TESTCASE(6,TestWinIML2_UTF8_ToUnicode
);
51 TESTCASE(7,TestWinIML2_UTF8_FromUnicode
);
53 TESTCASE(8,TestICU_Latin1_ToUnicode
);
54 TESTCASE(9,TestICU_Latin1_FromUnicode
);
55 TESTCASE(10,TestWinIML2_Latin1_ToUnicode
);
56 TESTCASE(11,TestWinIML2_Latin1_FromUnicode
);
58 TESTCASE(12,TestICU_Latin8_ToUnicode
);
59 TESTCASE(13,TestICU_Latin8_FromUnicode
);
60 TESTCASE(14,TestWinIML2_Latin8_ToUnicode
);
61 TESTCASE(15,TestWinIML2_Latin8_FromUnicode
);
63 TESTCASE(16,TestICU_EBCDIC_Arabic_ToUnicode
);
64 TESTCASE(17,TestICU_EBCDIC_Arabic_FromUnicode
);
65 TESTCASE(18,TestWinIML2_EBCDIC_Arabic_ToUnicode
);
66 TESTCASE(19,TestWinIML2_EBCDIC_Arabic_FromUnicode
);
68 TESTCASE(20,TestICU_SJIS_ToUnicode
);
69 TESTCASE(21,TestICU_SJIS_FromUnicode
);
70 TESTCASE(22,TestWinIML2_SJIS_ToUnicode
);
71 TESTCASE(23,TestWinIML2_SJIS_FromUnicode
);
73 TESTCASE(24,TestICU_EUCJP_ToUnicode
);
74 TESTCASE(25,TestICU_EUCJP_FromUnicode
);
75 TESTCASE(26,TestWinIML2_EUCJP_ToUnicode
);
76 TESTCASE(27,TestWinIML2_EUCJP_FromUnicode
);
78 TESTCASE(28,TestICU_GB2312_FromUnicode
);
79 TESTCASE(29,TestICU_GB2312_ToUnicode
);
80 TESTCASE(30,TestWinIML2_GB2312_ToUnicode
);
81 TESTCASE(31,TestWinIML2_GB2312_FromUnicode
);
83 TESTCASE(32,TestICU_ISO2022KR_ToUnicode
);
84 TESTCASE(33,TestICU_ISO2022KR_FromUnicode
);
85 TESTCASE(34,TestWinIML2_ISO2022KR_ToUnicode
);
86 TESTCASE(35,TestWinIML2_ISO2022KR_FromUnicode
);
88 TESTCASE(36,TestICU_ISO2022JP_ToUnicode
);
89 TESTCASE(37,TestICU_ISO2022JP_FromUnicode
);
90 TESTCASE(38,TestWinIML2_ISO2022JP_ToUnicode
);
91 TESTCASE(39,TestWinIML2_ISO2022JP_FromUnicode
);
93 TESTCASE(40,TestWinANSI_Latin1_ToUnicode
);
94 TESTCASE(41,TestWinANSI_Latin1_FromUnicode
);
96 TESTCASE(42,TestWinANSI_Latin8_ToUnicode
);
97 TESTCASE(43,TestWinANSI_Latin8_FromUnicode
);
99 TESTCASE(44,TestWinANSI_SJIS_ToUnicode
);
100 TESTCASE(45,TestWinANSI_SJIS_FromUnicode
);
102 TESTCASE(46,TestWinANSI_EUCJP_ToUnicode
);
103 TESTCASE(47,TestWinANSI_EUCJP_FromUnicode
);
105 TESTCASE(48,TestWinANSI_GB2312_ToUnicode
);
106 TESTCASE(49,TestWinANSI_GB2312_FromUnicode
);
108 TESTCASE(50,TestWinANSI_ISO2022KR_ToUnicode
);
109 TESTCASE(51,TestWinANSI_ISO2022KR_FromUnicode
);
111 TESTCASE(52,TestWinANSI_ISO2022JP_ToUnicode
);
112 TESTCASE(53,TestWinANSI_ISO2022JP_FromUnicode
);
122 UPerfFunction
* ConverterPerformanceTest::TestICU_CleanOpenAllConverters() {
123 UErrorCode status
= U_ZERO_ERROR
;
124 UPerfFunction
* pf
= new ICUOpenAllConvertersFunction(TRUE
, status
);
125 if(U_FAILURE(status
)){
131 UPerfFunction
* ConverterPerformanceTest::TestICU_OpenAllConverters() {
132 UErrorCode status
= U_ZERO_ERROR
;
133 UPerfFunction
* pf
= new ICUOpenAllConvertersFunction(FALSE
, status
);
134 if(U_FAILURE(status
)){
140 UPerfFunction
* ConverterPerformanceTest::TestICU_UTF8_FromUnicode(){
141 UErrorCode status
= U_ZERO_ERROR
;
142 ICUFromUnicodePerfFunction
* pf
= new ICUFromUnicodePerfFunction("utf-8",utf8_uniSource
, LENGTHOF(utf8_uniSource
), status
);
143 if(U_FAILURE(status
)){
149 UPerfFunction
* ConverterPerformanceTest::TestICU_UTF8_ToUnicode(){
150 UErrorCode status
= U_ZERO_ERROR
;
151 UPerfFunction
* pf
= new ICUToUnicodePerfFunction("utf-8",(char*)utf8_encSource
, LENGTHOF(utf8_encSource
), status
);
152 if(U_FAILURE(status
)){
159 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_UTF8_FromUnicode(){
160 UErrorCode status
= U_ZERO_ERROR
;
161 UPerfFunction
* pf
= new WinIMultiLanguage2FromUnicodePerfFunction("utf-8",utf8_uniSource
, LENGTHOF(utf8_uniSource
), status
);
162 if(U_FAILURE(status
)){
168 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_UTF8_ToUnicode(){
169 UErrorCode status
= U_ZERO_ERROR
;
170 UPerfFunction
* pf
= new WinIMultiLanguage2ToUnicodePerfFunction("utf-8",(char*)utf8_encSource
, LENGTHOF(utf8_encSource
), status
);
171 if(U_FAILURE(status
)){
177 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_UTF8_FromUnicode(){
178 UErrorCode status
= U_ZERO_ERROR
;
179 UPerfFunction
* pf
= new WinANSIFromUnicodePerfFunction("utf-8",utf8_uniSource
, LENGTHOF(utf8_uniSource
), status
);
180 if(U_FAILURE(status
)){
186 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_UTF8_ToUnicode(){
187 UErrorCode status
= U_ZERO_ERROR
;
188 UPerfFunction
* pf
= new WinANSIToUnicodePerfFunction("utf-8",(char*)utf8_encSource
, LENGTHOF(utf8_encSource
), status
);
189 if(U_FAILURE(status
)){
197 UPerfFunction
* ConverterPerformanceTest::TestICU_Latin1_FromUnicode(){
198 UErrorCode status
= U_ZERO_ERROR
;
199 ICUFromUnicodePerfFunction
* pf
= new ICUFromUnicodePerfFunction("iso-8859-1",latin1_uniSource
, LENGTHOF(latin1_uniSource
), status
);
200 if(U_FAILURE(status
)){
206 UPerfFunction
* ConverterPerformanceTest::TestICU_Latin1_ToUnicode(){
207 UErrorCode status
= U_ZERO_ERROR
;
208 UPerfFunction
* pf
= new ICUToUnicodePerfFunction("iso-8859-1",(char*)latin1_encSource
, LENGTHOF(latin1_encSource
), status
);
209 if(U_FAILURE(status
)){
216 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_Latin1_FromUnicode(){
217 UErrorCode status
= U_ZERO_ERROR
;
218 UPerfFunction
* pf
= new WinIMultiLanguage2FromUnicodePerfFunction("iso-8859-1",latin1_uniSource
, LENGTHOF(latin1_uniSource
), status
);
219 if(U_FAILURE(status
)){
225 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_Latin1_ToUnicode(){
226 UErrorCode status
= U_ZERO_ERROR
;
227 UPerfFunction
* pf
= new WinIMultiLanguage2ToUnicodePerfFunction("iso-8859-1",(char*)latin1_encSource
, LENGTHOF(latin1_encSource
), status
);
228 if(U_FAILURE(status
)){
234 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_Latin1_FromUnicode(){
235 UErrorCode status
= U_ZERO_ERROR
;
236 UPerfFunction
* pf
= new WinANSIFromUnicodePerfFunction("iso-8859-1",latin1_uniSource
, LENGTHOF(latin1_uniSource
), status
);
237 if(U_FAILURE(status
)){
243 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_Latin1_ToUnicode(){
244 UErrorCode status
= U_ZERO_ERROR
;
245 UPerfFunction
* pf
= new WinANSIToUnicodePerfFunction("iso-8859-1",(char*)latin1_encSource
, LENGTHOF(latin1_encSource
), status
);
246 if(U_FAILURE(status
)){
254 UPerfFunction
* ConverterPerformanceTest::TestICU_Latin8_FromUnicode(){
255 UErrorCode status
= U_ZERO_ERROR
;
256 ICUFromUnicodePerfFunction
* pf
= new ICUFromUnicodePerfFunction("iso-8859-8",latin8_uniSource
, LENGTHOF(latin8_uniSource
), status
);
257 if(U_FAILURE(status
)){
263 UPerfFunction
* ConverterPerformanceTest::TestICU_Latin8_ToUnicode(){
264 UErrorCode status
= U_ZERO_ERROR
;
265 UPerfFunction
* pf
= new ICUToUnicodePerfFunction("iso-8859-8",(char*)latin8_encSource
, LENGTHOF(latin8_encSource
), status
);
266 if(U_FAILURE(status
)){
273 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_Latin8_FromUnicode(){
274 UErrorCode status
= U_ZERO_ERROR
;
275 UPerfFunction
* pf
= new WinIMultiLanguage2FromUnicodePerfFunction("iso-8859-8",latin8_uniSource
, LENGTHOF(latin8_uniSource
), status
);
276 if(U_FAILURE(status
)){
282 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_Latin8_ToUnicode(){
283 UErrorCode status
= U_ZERO_ERROR
;
284 UPerfFunction
* pf
= new WinIMultiLanguage2ToUnicodePerfFunction("iso-8859-8",(char*)latin8_encSource
, LENGTHOF(latin8_encSource
), status
);
285 if(U_FAILURE(status
)){
290 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_Latin8_FromUnicode(){
291 UErrorCode status
= U_ZERO_ERROR
;
292 UPerfFunction
* pf
= new WinANSIFromUnicodePerfFunction("iso-8859-8",latin8_uniSource
, LENGTHOF(latin8_uniSource
), status
);
293 if(U_FAILURE(status
)){
299 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_Latin8_ToUnicode(){
300 UErrorCode status
= U_ZERO_ERROR
;
301 UPerfFunction
* pf
= new WinANSIToUnicodePerfFunction("iso-8859-8",(char*)latin8_encSource
, LENGTHOF(latin8_encSource
), status
);
302 if(U_FAILURE(status
)){
311 UPerfFunction
* ConverterPerformanceTest::TestICU_EBCDIC_Arabic_FromUnicode(){
312 UErrorCode status
= U_ZERO_ERROR
;
313 ICUFromUnicodePerfFunction
* pf
= new ICUFromUnicodePerfFunction("x-EBCDIC-Arabic",ebcdic_arabic_uniSource
, LENGTHOF(ebcdic_arabic_uniSource
), status
);
314 if(U_FAILURE(status
)){
320 UPerfFunction
* ConverterPerformanceTest::TestICU_EBCDIC_Arabic_ToUnicode(){
321 UErrorCode status
= U_ZERO_ERROR
;
322 UPerfFunction
* pf
= new ICUToUnicodePerfFunction("x-EBCDIC-Arabic",(char*)ebcdic_arabic_encSource
, LENGTHOF(ebcdic_arabic_encSource
), status
);
323 if(U_FAILURE(status
)){
330 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_EBCDIC_Arabic_FromUnicode(){
331 UErrorCode status
= U_ZERO_ERROR
;
332 UPerfFunction
* pf
= new WinIMultiLanguage2FromUnicodePerfFunction("x-EBCDIC-Arabic",ebcdic_arabic_uniSource
, LENGTHOF(ebcdic_arabic_uniSource
), status
);
333 if(U_FAILURE(status
)){
339 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_EBCDIC_Arabic_ToUnicode(){
340 UErrorCode status
= U_ZERO_ERROR
;
341 UPerfFunction
* pf
= new WinIMultiLanguage2ToUnicodePerfFunction("x-EBCDIC-Arabic",(char*)ebcdic_arabic_encSource
, LENGTHOF(ebcdic_arabic_encSource
), status
);
342 if(U_FAILURE(status
)){
348 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_EBCDIC_Arabic_FromUnicode(){
349 UErrorCode status
= U_ZERO_ERROR
;
350 UPerfFunction
* pf
= new WinANSIFromUnicodePerfFunction("x-EBCDIC-Arabic",ebcdic_arabic_uniSource
, LENGTHOF(ebcdic_arabic_uniSource
), status
);
351 if(U_FAILURE(status
)){
357 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_EBCDIC_Arabic_ToUnicode(){
358 UErrorCode status
= U_ZERO_ERROR
;
359 UPerfFunction
* pf
= new WinANSIToUnicodePerfFunction("x-EBCDIC-Arabic",(char*)ebcdic_arabic_encSource
, LENGTHOF(ebcdic_arabic_encSource
), status
);
360 if(U_FAILURE(status
)){
368 UPerfFunction
* ConverterPerformanceTest::TestICU_SJIS_FromUnicode(){
369 UErrorCode status
= U_ZERO_ERROR
;
370 ICUFromUnicodePerfFunction
* pf
= new ICUFromUnicodePerfFunction("sjis",sjis_uniSource
, LENGTHOF(sjis_uniSource
), status
);
371 if(U_FAILURE(status
)){
377 UPerfFunction
* ConverterPerformanceTest::TestICU_SJIS_ToUnicode(){
378 UErrorCode status
= U_ZERO_ERROR
;
379 UPerfFunction
* pf
= new ICUToUnicodePerfFunction("sjis",(char*)sjis_encSource
, LENGTHOF(sjis_encSource
), status
);
380 if(U_FAILURE(status
)){
387 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_SJIS_FromUnicode(){
388 UErrorCode status
= U_ZERO_ERROR
;
389 UPerfFunction
* pf
= new WinIMultiLanguage2FromUnicodePerfFunction("sjis",sjis_uniSource
, LENGTHOF(sjis_uniSource
), status
);
390 if(U_FAILURE(status
)){
396 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_SJIS_ToUnicode(){
397 UErrorCode status
= U_ZERO_ERROR
;
398 UPerfFunction
* pf
= new WinIMultiLanguage2ToUnicodePerfFunction("sjis",(char*)sjis_encSource
, LENGTHOF(sjis_encSource
), status
);
399 if(U_FAILURE(status
)){
405 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_SJIS_FromUnicode(){
406 UErrorCode status
= U_ZERO_ERROR
;
407 UPerfFunction
* pf
= new WinANSIFromUnicodePerfFunction("sjis",sjis_uniSource
, LENGTHOF(sjis_uniSource
), status
);
408 if(U_FAILURE(status
)){
414 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_SJIS_ToUnicode(){
415 UErrorCode status
= U_ZERO_ERROR
;
416 UPerfFunction
* pf
= new WinANSIToUnicodePerfFunction("sjis",(char*)sjis_encSource
, LENGTHOF(sjis_encSource
), status
);
417 if(U_FAILURE(status
)){
427 UPerfFunction
* ConverterPerformanceTest::TestICU_EUCJP_FromUnicode(){
428 UErrorCode status
= U_ZERO_ERROR
;
429 ICUFromUnicodePerfFunction
* pf
= new ICUFromUnicodePerfFunction("euc-jp",eucjp_uniSource
, LENGTHOF(eucjp_uniSource
), status
);
430 if(U_FAILURE(status
)){
436 UPerfFunction
* ConverterPerformanceTest::TestICU_EUCJP_ToUnicode(){
437 UErrorCode status
= U_ZERO_ERROR
;
438 UPerfFunction
* pf
= new ICUToUnicodePerfFunction("euc-jp",(char*)eucjp_encSource
, LENGTHOF(eucjp_encSource
), status
);
439 if(U_FAILURE(status
)){
446 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_EUCJP_FromUnicode(){
447 UErrorCode status
= U_ZERO_ERROR
;
448 UPerfFunction
* pf
= new WinIMultiLanguage2FromUnicodePerfFunction("euc-jp",eucjp_uniSource
, LENGTHOF(eucjp_uniSource
), status
);
449 if(U_FAILURE(status
)){
455 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_EUCJP_ToUnicode(){
456 UErrorCode status
= U_ZERO_ERROR
;
457 UPerfFunction
* pf
= new WinIMultiLanguage2ToUnicodePerfFunction("euc-jp",(char*)eucjp_encSource
, LENGTHOF(eucjp_encSource
), status
);
458 if(U_FAILURE(status
)){
464 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_EUCJP_FromUnicode(){
465 UErrorCode status
= U_ZERO_ERROR
;
466 UPerfFunction
* pf
= new WinANSIFromUnicodePerfFunction("euc-jp",eucjp_uniSource
, LENGTHOF(eucjp_uniSource
), status
);
467 if(U_FAILURE(status
)){
473 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_EUCJP_ToUnicode(){
474 UErrorCode status
= U_ZERO_ERROR
;
475 UPerfFunction
* pf
= new WinANSIToUnicodePerfFunction("euc-jp",(char*)eucjp_encSource
, LENGTHOF(eucjp_encSource
), status
);
476 if(U_FAILURE(status
)){
486 UPerfFunction
* ConverterPerformanceTest::TestICU_GB2312_FromUnicode(){
487 UErrorCode status
= U_ZERO_ERROR
;
488 ICUFromUnicodePerfFunction
* pf
= new ICUFromUnicodePerfFunction("gb2312",gb2312_uniSource
, LENGTHOF(gb2312_uniSource
), status
);
489 if(U_FAILURE(status
)){
495 UPerfFunction
* ConverterPerformanceTest::TestICU_GB2312_ToUnicode(){
496 UErrorCode status
= U_ZERO_ERROR
;
497 UPerfFunction
* pf
= new ICUToUnicodePerfFunction("gb2312",(char*)gb2312_encSource
, LENGTHOF(gb2312_encSource
), status
);
498 if(U_FAILURE(status
)){
505 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_GB2312_FromUnicode(){
506 UErrorCode status
= U_ZERO_ERROR
;
507 UPerfFunction
* pf
= new WinIMultiLanguage2FromUnicodePerfFunction("gb2312",gb2312_uniSource
, LENGTHOF(gb2312_uniSource
), status
);
508 if(U_FAILURE(status
)){
514 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_GB2312_ToUnicode(){
515 UErrorCode status
= U_ZERO_ERROR
;
516 UPerfFunction
* pf
= new WinIMultiLanguage2ToUnicodePerfFunction("gb2312",(char*)gb2312_encSource
, LENGTHOF(gb2312_encSource
), status
);
517 if(U_FAILURE(status
)){
523 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_GB2312_FromUnicode(){
524 UErrorCode status
= U_ZERO_ERROR
;
525 UPerfFunction
* pf
= new WinANSIFromUnicodePerfFunction("gb2312",gb2312_uniSource
, LENGTHOF(gb2312_uniSource
), status
);
526 if(U_FAILURE(status
)){
532 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_GB2312_ToUnicode(){
533 UErrorCode status
= U_ZERO_ERROR
;
534 UPerfFunction
* pf
= new WinANSIToUnicodePerfFunction("gb2312",(char*)gb2312_encSource
, LENGTHOF(gb2312_encSource
), status
);
535 if(U_FAILURE(status
)){
544 UPerfFunction
* ConverterPerformanceTest::TestICU_ISO2022KR_FromUnicode(){
545 UErrorCode status
= U_ZERO_ERROR
;
546 ICUFromUnicodePerfFunction
* pf
= new ICUFromUnicodePerfFunction("iso-2022-kr",iso2022kr_uniSource
, LENGTHOF(iso2022kr_uniSource
), status
);
547 if(U_FAILURE(status
)){
553 UPerfFunction
* ConverterPerformanceTest::TestICU_ISO2022KR_ToUnicode(){
554 UErrorCode status
= U_ZERO_ERROR
;
555 UPerfFunction
* pf
= new ICUToUnicodePerfFunction("iso-2022-kr",(char*)iso2022kr_encSource
, LENGTHOF(iso2022kr_encSource
), status
);
556 if(U_FAILURE(status
)){
563 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_ISO2022KR_FromUnicode(){
564 UErrorCode status
= U_ZERO_ERROR
;
565 UPerfFunction
* pf
= new WinIMultiLanguage2FromUnicodePerfFunction("iso-2022-kr",iso2022kr_uniSource
, LENGTHOF(iso2022kr_uniSource
), status
);
566 if(U_FAILURE(status
)){
572 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_ISO2022KR_ToUnicode(){
573 UErrorCode status
= U_ZERO_ERROR
;
574 UPerfFunction
* pf
= new WinIMultiLanguage2ToUnicodePerfFunction("iso-2022-kr",(char*)iso2022kr_encSource
, LENGTHOF(iso2022kr_encSource
), status
);
575 if(U_FAILURE(status
)){
581 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_ISO2022KR_FromUnicode(){
582 UErrorCode status
= U_ZERO_ERROR
;
583 UPerfFunction
* pf
= new WinANSIFromUnicodePerfFunction("iso-2022-kr",iso2022kr_uniSource
, LENGTHOF(iso2022kr_uniSource
), status
);
584 if(U_FAILURE(status
)){
590 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_ISO2022KR_ToUnicode(){
591 UErrorCode status
= U_ZERO_ERROR
;
592 UPerfFunction
* pf
= new WinANSIToUnicodePerfFunction("iso-2022-kr",(char*)iso2022kr_encSource
, LENGTHOF(iso2022kr_encSource
), status
);
593 if(U_FAILURE(status
)){
601 UPerfFunction
* ConverterPerformanceTest::TestICU_ISO2022JP_FromUnicode(){
602 UErrorCode status
= U_ZERO_ERROR
;
603 ICUFromUnicodePerfFunction
* pf
= new ICUFromUnicodePerfFunction("iso-2022-jp",iso2022jp_uniSource
, LENGTHOF(iso2022jp_uniSource
), status
);
604 if(U_FAILURE(status
)){
610 UPerfFunction
* ConverterPerformanceTest::TestICU_ISO2022JP_ToUnicode(){
611 UErrorCode status
= U_ZERO_ERROR
;
612 UPerfFunction
* pf
= new ICUToUnicodePerfFunction("iso-2022-jp",(char*)iso2022jp_encSource
, LENGTHOF(iso2022jp_encSource
), status
);
613 if(U_FAILURE(status
)){
620 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_ISO2022JP_FromUnicode(){
621 UErrorCode status
= U_ZERO_ERROR
;
622 UPerfFunction
* pf
= new WinIMultiLanguage2FromUnicodePerfFunction("iso-2022-jp",iso2022jp_uniSource
, LENGTHOF(iso2022jp_uniSource
), status
);
623 if(U_FAILURE(status
)){
629 UPerfFunction
* ConverterPerformanceTest::TestWinIML2_ISO2022JP_ToUnicode(){
630 UErrorCode status
= U_ZERO_ERROR
;
631 UPerfFunction
* pf
= new WinIMultiLanguage2ToUnicodePerfFunction("iso-2022-jp",(char*)iso2022jp_encSource
, LENGTHOF(iso2022jp_encSource
), status
);
632 if(U_FAILURE(status
)){
638 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_ISO2022JP_FromUnicode(){
639 UErrorCode status
= U_ZERO_ERROR
;
640 UPerfFunction
* pf
= new WinANSIFromUnicodePerfFunction("iso-2022-jp",iso2022jp_uniSource
, LENGTHOF(iso2022jp_uniSource
), status
);
641 if(U_FAILURE(status
)){
647 UPerfFunction
* ConverterPerformanceTest::TestWinANSI_ISO2022JP_ToUnicode(){
648 UErrorCode status
= U_ZERO_ERROR
;
649 UPerfFunction
* pf
= new WinANSIToUnicodePerfFunction("iso-2022-jp",(char*)iso2022jp_encSource
, LENGTHOF(iso2022jp_encSource
), status
);
650 if(U_FAILURE(status
)){