Sign in
foss-eda-tools
/
third_party
/
shuttle
/
sky130
/
mpw-007
/
slot-003
/
ea3acb4629819f691b5063ad64102cfb034fc481
/
.
/
verilog
/
dv
/
microwatt
/
spi_flash
/
hash.h
blob: 88c3d98689b409080708601c6750c0c8d85cdaef [
file
] [
log
] [
blame
]
#ifndef
__HASH_H
#define
__HASH_H
#define
GOLDEN_RATIO_64
0x61C8864680B583EBull
static
inline
uint64_t
hash_64
(
uint64_t
val
,
uint32_t
bits
)
{
return
val
*
GOLDEN_RATIO_64
>>
(
64
-
bits
);
}
#endif