Re: iphash vs iptreemap

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On Thu, 19 Jun 2008, Nishit Shah wrote:

> 	If I have list of only IP Addresses, which set type is better to use
> in terms of Matching speed and memory ? iphash or iptreemap ?

Good questions! I'd say iptree(map) is faster. But if the IP addresses are 
random, then iphash can use less memory than iptree(map), if the probes 
parameter of the hash is small.

> 	Does the decision depends of number of IP Addresses ?

Not really, the number of addresses are a neutral factor. But if you 
create an iphash with small hashsize (compared to the IP addresses 
planned to store), it can be slow when adding the IP addresses due to 
rehashing if it has to grow the hash. 

Best regards,
Jozsef
-
E-mail  : kadlec@xxxxxxxxxxxxxxxxx, kadlec@xxxxxxxxxxxx
PGP key : http://www.kfki.hu/~kadlec/pgp_public_key.txt
Address : KFKI Research Institute for Particle and Nuclear Physics
          H-1525 Budapest 114, POB. 49, Hungary
--
To unsubscribe from this list: send the line "unsubscribe netfilter" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux