r885 - trunk/varnish-cache/bin/varnishd

phk at projects.linpro.no phk at projects.linpro.no
Tue Aug 22 10:06:46 CEST 2006


Author: phk
Date: 2006-08-22 10:06:46 +0200 (Tue, 22 Aug 2006)
New Revision: 885

Modified:
   trunk/varnish-cache/bin/varnishd/hash_classic.c
Log:
Additional marginal improvement:

Sort on length of key, then on digest.



Modified: trunk/varnish-cache/bin/varnishd/hash_classic.c
===================================================================
--- trunk/varnish-cache/bin/varnishd/hash_classic.c	2006-08-22 07:52:33 UTC (rev 884)
+++ trunk/varnish-cache/bin/varnishd/hash_classic.c	2006-08-22 08:06:46 UTC (rev 885)
@@ -202,8 +202,10 @@
 				continue;
 			if (kl > he->klen)
 				break;
-			if (he->digest != digest)
+			if (he->digest < digest)
 				continue;
+			if (he->digest > digest)
+				break;
 			if (memcmp(he->key, key1, kl1))
 				continue;
 			if (memcmp(he->key + kl1, key2, kl2))




More information about the varnish-commit mailing list