mirror of https://github.com/YosysHQ/yosys.git
hashlib: legacy mkhash_add -> djb2_add
This commit is contained in:
parent
4e29ec1854
commit
1df8a3e64b
|
@ -54,7 +54,7 @@ const int hashtable_size_trigger = 2;
|
||||||
const int hashtable_size_factor = 3;
|
const int hashtable_size_factor = 3;
|
||||||
|
|
||||||
namespace legacy {
|
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;
|
return ((a << 5) + a) + b;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -1862,7 +1862,7 @@ inline Hasher RTLIL::SigBit::hash_eat(Hasher h) const {
|
||||||
inline Hasher RTLIL::SigBit::hash_top() const {
|
inline Hasher RTLIL::SigBit::hash_top() const {
|
||||||
Hasher h;
|
Hasher h;
|
||||||
if (wire) {
|
if (wire) {
|
||||||
h.force(hashlib::legacy::mkhash_add(wire->name.index_, offset));
|
h.force(hashlib::legacy::djb2_add(wire->name.index_, offset));
|
||||||
return h;
|
return h;
|
||||||
}
|
}
|
||||||
h.force(data);
|
h.force(data);
|
||||||
|
|
Loading…
Reference in New Issue