Merge pull request #7 from nspcc-dev/feat/mbpers
Report benchmark results in MB/s
This commit is contained in:
commit
5c06a9fa8f
2 changed files with 4 additions and 2 deletions
|
@ -31,8 +31,8 @@ The example of how it works can be seen in tests.
|
||||||
## AVX vs AVX2 version
|
## AVX vs AVX2 version
|
||||||
|
|
||||||
```
|
```
|
||||||
BenchmarkAVX-8 300 3566248 ns/op 64 B/op 4 allocs/op
|
BenchmarkAVX-8 500 3579980 ns/op 27.93 MB/s 64 B/op 4 allocs/op
|
||||||
BenchmarkAVX2-8 500 2857174 ns/op 64 B/op 2 allocs/op
|
BenchmarkAVX2-8 500 2997518 ns/op 33.36 MB/s 64 B/op 2 allocs/op
|
||||||
```
|
```
|
||||||
|
|
||||||
# Contributing
|
# Contributing
|
||||||
|
|
|
@ -75,6 +75,7 @@ func BenchmarkAVX(b *testing.B) {
|
||||||
_, _ = d.Write(data)
|
_, _ = d.Write(data)
|
||||||
d.checkSum()
|
d.checkSum()
|
||||||
}
|
}
|
||||||
|
b.SetBytes(int64(len(data)))
|
||||||
}
|
}
|
||||||
|
|
||||||
func BenchmarkAVX2(b *testing.B) {
|
func BenchmarkAVX2(b *testing.B) {
|
||||||
|
@ -88,6 +89,7 @@ func BenchmarkAVX2(b *testing.B) {
|
||||||
_, _ = d.Write(data)
|
_, _ = d.Write(data)
|
||||||
d.checkSum()
|
d.checkSum()
|
||||||
}
|
}
|
||||||
|
b.SetBytes(int64(len(data)))
|
||||||
}
|
}
|
||||||
|
|
||||||
func TestHomomorphism(t *testing.T) {
|
func TestHomomorphism(t *testing.T) {
|
||||||
|
|
Loading…
Reference in a new issue