Home | History | Annotate | Download | only in collperf
      1 #!/usr/bin/perl
      2 #  ********************************************************************
      3 #  * COPYRIGHT:
      4 #  * Copyright (c) 2008, International Business Machines Corporation and
      5 #  * others. All Rights Reserved.
      6 #  ********************************************************************
      7 
      8 #use strict;
      9 
     10 use lib '../perldriver';
     11 
     12 require "../perldriver/Common.pl";
     13 
     14 use PerfFramework;
     15 
     16 my $options = {
     17 	       "title"=>"Collation performanceregression: ICU (".$ICUPreviousVersion." and ".$ICULatestVersion.")",
     18            "headers"=>"ICU".$ICUPreviousVersion." ICU".$ICULatestVersion,
     19 	       "operationIs"=>"unicode String",
     20 	       "passes"=>"1",
     21 	       "time"=>"2",
     22 	       #"outputType"=>"HTML",
     23 	       "dataDir"=>$CollationDataPath,
     24            "outputDir"=>"../results"
     25 	      };
     26 
     27 # programs
     28 # tests will be done for all the programs. Results will be stored and connected
     29 my $p1, $p2;
     30 
     31 if ($OnWindows) {
     32 	$p1 = $ICUPathPrevious."/collperf/$WindowsPlatform/Release/collperf.exe";
     33 	$p2 = $ICUPathLatest."/collperf/$WindowsPlatform/Release/collperf.exe";
     34 } else {
     35 	$p1 = $ICUPathPrevious."/collperf/collperf";
     36 	$p2 = $ICUPathLatest."/collperf/collperf";
     37 }
     38 
     39 
     40 my $tests = { 
     41 	     "Key Gen ICU null",  ["$p1 TestIcu_KeyGen_null", "$p2 TestIcu_KeyGen_null"],
     42 	     "Key Gen ICU len",  ["$p1 TestIcu_KeyGen_len", "$p2 TestIcu_KeyGen_len"],
     43 	     "Iteration icu forward null",  ["$p1 TestIcu_ForwardIter_null", "$p2 TestIcu_ForwardIter_null"],
     44 	     "Iteration icu forward len",  ["$p1 TestIcu_ForwardIter_len", "$p2 TestIcu_ForwardIter_len"],
     45 	     "Iteration icu backward null",  ["$p1 TestIcu_BackwardIter_null", "$p2 TestIcu_BackwardIter_null"],
     46 	     "Iteration icu backward len",  ["$p1 TestIcu_BackwardIter_len", "$p2 TestIcu_BackwardIter_len"],
     47 	     "Iteration/all icu forward null",  ["$p1 TestIcu_ForwardIter_all_null", "$p2 TestIcu_ForwardIter_all_null"],
     48 	     "Iteration/all icu forward len",  ["$p1 TestIcu_ForwardIter_all_len", "$p2 TestIcu_ForwardIter_all_len"],
     49 	     "Iteration/all icu backward null",  ["$p1 TestIcu_BackwardIter_all_null", "$p2 TestIcu_BackwardIter_all_null"],
     50 	     "Iteration/all icu backward len",  ["$p1 TestIcu_BackwardIter_all_len", "$p2 TestIcu_BackwardIter_all_len"],
     51 	     "qsort icu strcoll null",  ["$p1 TestIcu_qsort_strcoll_null", "$p2 TestIcu_qsort_strcoll_null"],
     52 	     "qsort icu strcoll len",  ["$p1 TestIcu_qsort_strcoll_len", "$p2 TestIcu_qsort_strcoll_len"],
     53 	     "qsort icu use key",  ["$p1 TestIcu_qsort_usekey", "$p2 TestIcu_qsort_usekey"],
     54 	     "Binary Search icu strcoll null",  ["$p1 TestIcu_BinarySearch_strcoll_null", "$p2 TestIcu_BinarySearch_strcoll_null"],
     55 	     "Binary Search icu strcoll len",  ["$p1 TestIcu_BinarySearch_strcoll_len", "$p2 TestIcu_BinarySearch_strcoll_len"],
     56 	     "Binary Search icu use key",  ["$p1 TestIcu_BinarySearch_usekey", "$p2 TestIcu_BinarySearch_usekey"],
     57 	     "Binary Search icu u_strcmp",  ["$p1 TestIcu_BinarySearch_strcmp", "$p2 TestIcu_BinarySearch_strcmp"],
     58 	     "Binary Search icu cmpCPO",  ["$p1 TestIcu_BinarySearch_cmpCPO", "$p2 TestIcu_BinarySearch_cmpCPO"],
     59 	    };
     60 
     61 my $dataFiles = {
     62 		 "",
     63 		 [
     64 		  "TestNames_Asian.txt",
     65 		  "TestNames_Chinese.txt",
     66 		  "TestNames_Japanese.txt",
     67 		  "TestNames_Japanese_h.txt",
     68 		  "TestNames_Japanese_k.txt",
     69 		  "TestNames_Korean.txt",
     70 		  "TestNames_Latin.txt",
     71 		  "Testnames_Russian.txt",
     72 		  "TestNames_SerbianSH.txt",
     73 		  "TestNames_SerbianSR.txt",
     74 		  "TestNames_Simplified_Chinese.txt",
     75 		  "TestNames_Thai.txt"
     76 		 ]
     77 		};
     78 
     79 runTests($options, $tests, $dataFiles);
     80