From 1df8a3e64ba67acab935716eeddae2c2afbd9cab Mon Sep 17 00:00:00 2001 From: "Emil J. Tywoniak" Date: Mon, 11 Nov 2024 15:46:25 +0100 Subject: [PATCH] hashlib: legacy mkhash_add -> djb2_add --- kernel/hashlib.h | 2 +- kernel/rtlil.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/hashlib.h b/kernel/hashlib.h index f66baa4297d..3be33ebd9ea 100644 --- a/kernel/hashlib.h +++ b/kernel/hashlib.h @@ -54,7 +54,7 @@ const int hashtable_size_trigger = 2; const int hashtable_size_factor = 3; namespace legacy { - inline uint32_t mkhash_add(uint32_t a, uint32_t b) { + inline uint32_t djb2_add(uint32_t a, uint32_t b) { return ((a << 5) + a) + b; } }; diff --git a/kernel/rtlil.h b/kernel/rtlil.h index eaf2eaf8ead..2b3d274a2e9 100644 --- a/kernel/rtlil.h +++ b/kernel/rtlil.h @@ -1862,7 +1862,7 @@ inline Hasher RTLIL::SigBit::hash_eat(Hasher h) const { inline Hasher RTLIL::SigBit::hash_top() const { Hasher h; if (wire) { - h.force(hashlib::legacy::mkhash_add(wire->name.index_, offset)); + h.force(hashlib::legacy::djb2_add(wire->name.index_, offset)); return h; } h.force(data);