Home | History | Annotate | only in /external/icu/icu4c/source/test/perf/collationperf
Up to higher level directory
NameDateSize
collperf.cpp22-Oct-202057K
CollPerf.pl22-Oct-20208.4K
Makefile.in22-Oct-20202K
readme.html22-Oct-20203.1K

readme.html

      1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
      2 <HTML>
      3 
      4 <HEAD>
      5 	<META HTTP-EQUIV="Content-Type" CONTENT="text/html;CHARSET=iso-8859-1">
      6         <meta name="Copyright" content="Copyright (C) 2016 and later: Unicode, Inc. and others.
      7         License & terms of use: http://www.unicode.org/copyright.html#License
      8         Copyright (c) 2002-2008, International Business Machines Corporation and others. All Rights Reserved.">
      9 	<META NAME="GENERATOR" Content="Visual Page 2.0 for Windows">
     10 	<TITLE>collperf</TITLE>
     11 </HEAD>
     12 
     13 <BODY BGCOLOR="white">
     14 
     15 <H2>collperf</H2>
     16 <P>collperf is a test program for comparing collation performance and key lengths of ICU, Windows native collation
     17 and Unix/POSIX collation. It operates on a file of lines (names, for example), and performs one of three tests:</P>
     18 
     19 <OL>
     20 	<LI>Sort Key generation. Report on key lengths and key generation times.
     21 	<LI>Binary search. Report the average time required to look up each of the names (file lines) from the file in
     22 	a sorted list of all of the names.
     23 	<LI>Quick Sort. Report the time required to sort the file in memory, using the C library qsort function. The file
     24 	order is randomized prior to the sort.
     25 </OL>
     26 
     27 <P>
     28 <P><B>Usage Summary</B></P>
     29 
     30 <BLOCKQUOTE>
     31 	<P>
     32 	<TABLE BORDER="0" WIDTH="100%" BGCOLOR="#FFFBF0">
     33 		<TR>
     34 			<TD WIDTH="100%">
     35 				<P><TT>collperf -help</TT>
     36 				<BLOCKQUOTE>
     37 					<PRE><TT>Usage: strperf options...
     38 -help                  Display this message.
     39 -file file_name        utf-16 format file of names
     40 -locale name           ICU locale to use. Default is en_US
     41 -langid 0x1234         Windows Language ID number. Default 0x409 (en_US)
     42                        see http://msdn.microsoft.com/library/psdk/winbase/nls_8xo3.htm
     43 -win                   Run test using Windows native services. (ICU is default)
     44 -unix                  Run test using Unix strxfrm, strcoll services.
     45 -uselen                Use API with string lengths. Default is null-terminated strings
     46 -usekeys               Run tests using sortkeys rather than strcoll
     47 -loop nnnn             Loopcount for test. Adjust for reasonable total running time.
     48 -terse                 Terse numbers-only output. Intended for use by scripts.
     49 -french                French accent ordering
     50 -norm                  Normalizing mode on
     51 -shifted               Shifted mode
     52 -lower                 Lower case first
     53 -upper                 Upper case first
     54 -case                  Enable separate case level
     55 -level n               Sort level, 1 to 5, for Primary, Secndary, Tertiary, Quaternary, Identical
     56 -binsearch             Binary Search timing test
     57 -keygen                Sort Key Generation timing test
     58 -qsort                 Quicksort timing test</TT></PRE>
     59 				</BLOCKQUOTE>
     60 			</TD>
     61 		</TR>
     62 	</TABLE>
     63 </P>
     64 </BLOCKQUOTE>
     65 
     66 <P><B>Example</B></P>
     67 
     68 <BLOCKQUOTE>
     69 	<P>
     70 	<TABLE BORDER="0" WIDTH="100%" BGCOLOR="#FFFBF0">
     71 		<TR>
     72 			<TD WIDTH="100%"><TT>C:\&gt;collperf -loop 200 -file latin.txt -keygen -shifted -level 4<BR>
     73 				file &quot;latin.txt&quot;, 7604 lines.<BR>
     74 				Sort Key Generation: total # of keys = 197704<BR>
     75 				Sort Key Generation: time per key = 4253 ns<BR>
     76 				Key Length / character = 1.730054</TT></TD>
     77 		</TR>
     78 	</TABLE>
     79 
     80 </BLOCKQUOTE>
     81 
     82 <P>
     83 
     84 </BODY>
     85 
     86 </HTML>
     87