mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-19 19:30:44 +00:00
crypto/keccak: fix lint
This commit is contained in:
parent
052eb75c06
commit
7e89310d9c
2 changed files with 0 additions and 22 deletions
|
|
@ -1,3 +0,0 @@
|
||||||
|
|
||||||
|
|
||||||
package keccak
|
|
||||||
|
|
@ -208,22 +208,3 @@ func BenchmarkPermutationFunction(b *testing.B) {
|
||||||
keccakF1600(&lanes)
|
keccakF1600(&lanes)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// benchmarkHash tests the speed to hash num buffers of buflen each.
|
|
||||||
func benchmarkHash(b *testing.B, h hash.Hash, size, num int) {
|
|
||||||
b.StopTimer()
|
|
||||||
h.Reset()
|
|
||||||
data := sequentialBytes(size)
|
|
||||||
b.SetBytes(int64(size * num))
|
|
||||||
b.StartTimer()
|
|
||||||
|
|
||||||
var state []byte
|
|
||||||
for i := 0; i < b.N; i++ {
|
|
||||||
for j := 0; j < num; j++ {
|
|
||||||
h.Write(data)
|
|
||||||
}
|
|
||||||
state = h.Sum(state[:0])
|
|
||||||
}
|
|
||||||
b.StopTimer()
|
|
||||||
h.Reset()
|
|
||||||
}
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue