mirror of
https://github.com/TeaOSLab/EdgeNode.git
synced 2025-11-12 06:10:25 +08:00
采用更快的Hash算法
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
package ttlcache
|
||||
|
||||
import "github.com/dchest/siphash"
|
||||
import "github.com/cespare/xxhash"
|
||||
|
||||
func HashKey(key []byte) uint64 {
|
||||
return siphash.Hash(0, 0, key)
|
||||
return xxhash.Sum64(key)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user