...

Package xxhash

import "github.com/cespare/xxhash"
Overview
Index
Subdirectories

Overview ▾

Package xxhash implements the 64-bit variant of xxHash (XXH64) as described at http://cyan4973.github.io/xxHash/.

func New

func New() hash.Hash64

New creates a new hash.Hash64 that implements the 64-bit xxHash algorithm.

func Sum64

func Sum64(b []byte) uint64

Sum64 computes the 64-bit xxHash digest of b.

func Sum64String

func Sum64String(s string) uint64

Sum64String computes the 64-bit xxHash digest of s. It may be faster than Sum64([]byte(s)) by avoiding a copy.

TODO(caleb): Consider removing this if an optimization is ever added to make it unnecessary: https://golang.org/issue/2205.

TODO(caleb): We still have a function call; we could instead write Go/asm copies of Sum64 for strings to squeeze out a bit more speed.

Subdirectories

Name Synopsis
..
v2 Package xxhash implements the 64-bit variant of xxHash (XXH64) as described at http://cyan4973.github.io/xxHash/.
dynamic
xxhsum
xxhsum