1
0
mirror of https://github.com/fumiama/blake2b-simd.git synced 2026-06-05 10:10:28 +08:00
Go to file
Harshavardhana 3a46db1cb4 Detect SSE automatically and enable corresponding optimized code path.
With this change, following happens.

```
if sse {
   compressSSE()
   return
}
compressGeneric()
```

compressGeneric is used as a fallback when SSE is not detected.
2016-06-28 02:51:14 -07:00
2016-06-24 20:09:36 +02:00
2016-06-28 10:23:10 +02:00

BLAKE2b-SIMD

Pure Go implementation of BLAKE2b using SIMD optimizations.

Introduction

This package is based on the pure go BLAKE2b implementation of Dmitry Chestnykh and merges it with the (cgo dependent) SSE optimized BLAKE2 implementation (which in turn is based on official implementation. It does so by using Go's Assembler for amd64 architectures with a fallback for other architectures.

It gives roughly a 3x performance improvement over the non-optimized go version.

Benchmarks

Dura 1 GB
blake2b-SIMD 1.59s
blake2b 4.66s
Description
Fast hashing using pure Go implementation of BLAKE2b with SIMD instructions
Readme Apache-2.0 230 KiB
Languages
Go 51.4%
Assembly 48.6%