mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-11-27 08:12:18 -08:00
use djb2 hash for now
This commit is contained in:
1 parent
4298f3d5f6
commit
344cd8ffbf
1 file changed
+7
-1
@@ -419,7 +419,13 @@ ASYNC_WORK_DEF(rdim_bake_idx_runs_work)
|
|||||||
internal U64
|
internal U64
|
||||||
rdim_help_hash(RDIM_String8 string)
|
rdim_help_hash(RDIM_String8 string)
|
||||||
{
|
{
|
||||||
return XXH3_64bits(string.str, string.size);
|
U64 hash = 5381;
|
||||||
|
U8 *ptr = string.str;
|
||||||
|
U8 *opl = string.str + string.size;
|
||||||
|
for (;ptr < opl; ++ptr) {
|
||||||
|
hash = ((hash << 5) + hash) + (*ptr);
|
||||||
|
}
|
||||||
|
return hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
internal void
|
internal void
|
||||||
|
|||||||
Reference in new issue
Block a user