Hi everybody,
Here is the classical world wide used ELF:
size_t Hash(const String& key)
{
UInt32 hash = 0;
for (size_t i = 0; i < key.GetLength(); ++i)
{
hash = (hash << 4) + key[i];
const UInt32 g = hash & 0xF0000000;
if (g != 0)
hash ^= g >> 24;
hash &= ~g;
}
return hash;
}
The problem is it's a 32bits algorithm which doesn't fit size_t for 64bits.
I tried to search information for a proper 64bits ELF hashing but could not find information.
Any help to understand how to have a proper 64bits ELF hashing would be very helpful.
Thanks a lot!