comparison xml/en/docs/hash.xml @ 625:af3f38e349eb

Removed terminal whitespace and fixed apostrophes used.
author Ruslan Ermilov <ru@nginx.com>
date Sat, 11 Aug 2012 04:55:25 +0000
parents 764fbac1b8b4
children d1446e47d17d
comparison
equal deleted inserted replaced
624:4b5163be537f 625:af3f38e349eb
12 12
13 <section> 13 <section>
14 14
15 <para> 15 <para>
16 To quickly process static sets of data such as server names, 16 To quickly process static sets of data such as server names,
17 <link doc="http/ngx_http_map_module.xml" id="map"/> directive's values, 17 <link doc="http/ngx_http_map_module.xml" id="map"/> directive’s values,
18 MIME types, names of request header strings, 18 MIME types, names of request header strings,
19 nginx uses hash tables. 19 nginx uses hash tables.
20 During the start and each re-configuration nginx selects the 20 During the start and each re-configuration nginx selects the
21 minimum possible sizes of hash tables such that the bucket size 21 minimum possible sizes of hash tables such that the bucket size
22 that stores keys with identical hash values does not exceed the 22 that stores keys with identical hash values does not exceed the
30 and <link doc="http/ngx_http_core_module.xml" id="server_names_hash_bucket_size"/>. 30 and <link doc="http/ngx_http_core_module.xml" id="server_names_hash_bucket_size"/>.
31 </para> 31 </para>
32 32
33 <para> 33 <para>
34 The hash bucket size parameter is aligned to the size that is a 34 The hash bucket size parameter is aligned to the size that is a
35 multiple of the processor's cache line size. This speeds up 35 multiple of the processor’s cache line size. This speeds up
36 key search in a hash on modern processors by reducing the number 36 key search in a hash on modern processors by reducing the number
37 of memory accesses. 37 of memory accesses.
38 If hash bucket size is equal to one processor's cache line size 38 If hash bucket size is equal to one processor’s cache line size
39 then the number of memory accesses during the key search will be 39 then the number of memory accesses during the key search will be
40 two in the worst case&mdash;first to compute the bucket address, 40 two in the worst case&mdash;first to compute the bucket address,
41 and second during the key search inside the bucket. 41 and second during the key search inside the bucket.
42 Therefore, if nginx emits the message requesting to increase 42 Therefore, if nginx emits the message requesting to increase
43 either hash max size or hash bucket size then the first parameter 43 either hash max size or hash bucket size then the first parameter