Giuseppe Ottaviano
Giuseppe Ottaviano
Hi Malfoy, you can find an example of usage in the unit tests, specifically https://github.com/ot/emphf/blob/master/compute_mphf_generic.hpp for building the data structure and https://github.com/ot/emphf/blob/master/test_mphf_generic.hpp for lookups. I agree that is not as...
No, that shouldn't happen. On how many keys are you trying to build the hash? For small key sets a special case might be needed and I haven't tested that.
> a simple counter-example is an array of the same number [0.1] \* 128, the algorithm will return indice 1 instead of indice 0, which is surely wrong. That doesn't...
That still doesn't satisfy the invariant (in this case, that error(low) > target). I'm not sure you're familiar with standard algorithm correctness proofs, see for example https://en.wikipedia.org/wiki/Loop_invariant. In the algorithm...
> For example edge cases sush as error(i) == error(j) This is not an edge case, and the algorithm still works. About the preconditions, you can check them before running...
Hi, I haven't touched that code for a while, but there should be no limitation on the size of the vectors, just on the _maximum excess_ inside the vector, which...
A few points - The comment is a bit misleading, it should read "retrieves at least 56 bits, **limited to the available bits in the bitvector**". What this function does...
> FWIW, I don't understand why this optimization can be disabled depending on the value of hardware_constructive_interference_size; it seems to me that no matter what your cache line size is,...
If I understand correctly the intent of the patch, it is just to extend the optimization to relocatable but non-trivially copyable types, correct? And we need the `memcpy` instead of...
> Yes, but only in this place, which uses relocation Move-assignment should benefit from this too, why not use it there as well?