Hi everybody, my first message, I hope I do not mess this up.
I was contemplating writing a Compile Time Hash Containers library and I
wrote a test implementation for sets and benchmarked it against mostly
ska:: sets since they are the best.
Document is here:
https://docs.google.com/document/d/1IsUiWl3K0h2pgttYgMt67CxgJ3zeXBKZEA7hvAQ5...
It is quite long, but it aims to provide a introduction to the problem for
people unfamiliar with details of hashing, and also it goes into a lot of
discussions, if you care just about the numbers you can skip the "boring
parts".
My interpretation of benchmarks is that it performs very well in some
cases, decently in others, but I am biased. :)
Code is not available online since I do not want to dump a test project
online without extensive documentation, but if somebody has a problem that
may be benefited by this test implementation feel free to let me know, I
would be happy to get some real world feedback on prototype.
Limitations is that test implementation only works for sets, so no maps and
if your objects are not integers you will probably not get much speedup.
Also if your set has more than 100ish items GCC will run out of memory and
VC++ does not compile code at all, so clang is the only way for most use
cases today.
One more disclaimer is that I do not want this library to be some beast
like ranges that takes years to implement, so if after reading the document
you consider implementation quite basic I won't be offended :) In other
words I feel that library like this although relatively simple compared to
regular Boost libraries can provide quite a lot of benefit for some
usecases where people really really care about performance of hash
containers where values are known during compile time.
I know you can not predict the future of an unimplemented library, but I
would be happy with some general feedback, and if you think this library
would be nice boost proposal I would be interested in some pointers wrt how
to proceed.
If somebody wonders how user code looks at the moment:
#include "cxhash_set.h"
// also could be a result of constexpr function, no need for initializer
list
static constexpr std::array