]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
[master] comments
authorEvan Hunt <each@isc.org>
Wed, 9 Dec 2015 16:54:04 +0000 (08:54 -0800)
committerEvan Hunt <each@isc.org>
Wed, 9 Dec 2015 16:54:04 +0000 (08:54 -0800)
lib/dns/name.c
lib/dns/rbt.c
lib/isc/include/isc/hash.h

index 80ebe5a76770f099155f5a826d30d98e44f14be6..fc886e020bccc9925e61d0306ae148a627ee0495 100644 (file)
@@ -635,6 +635,7 @@ dns_name_fullcompare(const dns_name_t *name1, const dns_name_t *name2,
                else
                        count = count2;
 
+               /* Loop unrolled for performance */
                while (count > 3) {
                        chdiff = (int)maptolower[label1[0]] -
                                 (int)maptolower[label2[0]];
@@ -665,7 +666,8 @@ dns_name_fullcompare(const dns_name_t *name1, const dns_name_t *name2,
                        label2 += 4;
                }
                while (count-- > 0) {
-                       chdiff = (int)maptolower[*label1++] - (int)maptolower[*label2++];
+                       chdiff = (int)maptolower[*label1++] -
+                                (int)maptolower[*label2++];
                        if (chdiff != 0) {
                                *orderp = chdiff;
                                goto done;
@@ -759,6 +761,7 @@ dns_name_equal(const dns_name_t *name1, const dns_name_t *name2) {
 
                INSIST(count <= 63); /* no bitstring support */
 
+               /* Loop unrolled for performance */
                while (count > 3) {
                        c = maptolower[label1[0]];
                        if (c != maptolower[label2[0]])
index a414e678bfdcf3c95f466e28231fae3780df2bbf..015dcdbc9d9e52369ce0901f5fe2cb23b4d57bd7 100644 (file)
@@ -350,7 +350,8 @@ hexdump(const char *desc, unsigned char *data, size_t size) {
 
 #ifdef DNS_RBT_USEHASH
 
-/* Upper node is the parent of the root of the passed node's
+/*
+ * Upper node is the parent of the root of the passed node's
  * subtree. The passed node must not be NULL.
  */
 static inline dns_rbtnode_t *
index fe344a0159cbdbb0158470a9c18fbc67ae46a984..8904e597a4495346fdeb60f429846d29a8dcfd08 100644 (file)
@@ -218,7 +218,8 @@ isc_hash_function_reverse(const void *data, size_t length,
  * isc_hash_function() calculates the hash from start to end over the
  * input data. isc_hash_function_reverse() calculates the hash from the
  * end to the start over the input data. The difference in order is
- * useful in incremental hashing.
+ * useful in incremental hashing; for example, a previously hashed
+ * value for 'com' can be used as input when hashing 'example.com'.
  *
  * This is a new variant of isc_hash_calc() and will supercede
  * isc_hash_calc() eventually.