First i'd like to thank you for the remarkable job
you've acomplished on Judy!
i've made some simple tests recently comparing
judy and almost-standard C++ hash tables, namely
the gcc implementation.
and it seems that judy performs 2 times worse than
the general purpose hash table! :(
AFAIK this is because the compiler is able to
optimize the c++ example because it has full access
to it's source code and in the case with Judy it
doesn't. compiling Judy from sources with maximum
optimizations turned on doesn't seem to help it.
of course the __gnu_cxx::hash_map benefints
greatly from the larger number of hash buckets, but
if we turn optimization off it performs 3 times worse
therefore i suppose if one had the header only Judy
implementation she can get two/three times faster
have i missed something?
and here are the test results.
this is the judy implemetation from the first example
> gcc -O3 -msse2 -march=pentium4 -o simple
Storing 1000000 random numbers in a Judy scalable
Insertion of 1000000 indexes took 1.061 microsec/
Retrieval of 1000000 indexes took 0.577 microsec/
and here are the results for __gnu_cxx::hash_map
> g++ -O3 -msse2 -march=pentium4 -o
Begin storing 1000000 random numbers in a
Insertion of 1000000 indexes took 1.134 microsec/
Retrieval of 1000000 indexes took 0.284 microsec/
please see attached files for full source code(the
common_hash.cc is attached, and simple.c can be
copy-pasted from the example pdf, sf.net allows
attaching only one file :( ).