From 7c15d1e8c3104f6855adb6d09e768af022566b2d Mon Sep 17 00:00:00 2001 From: lijunlong Date: Sat, 28 Mar 2020 12:31:16 +0800 Subject: [PATCH] add bench mark for bls sign and verify --- lib/sigs/bls/bls_bench_test.go | 58 ++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 lib/sigs/bls/bls_bench_test.go diff --git a/lib/sigs/bls/bls_bench_test.go b/lib/sigs/bls/bls_bench_test.go new file mode 100644 index 000000000..883d1bd15 --- /dev/null +++ b/lib/sigs/bls/bls_bench_test.go @@ -0,0 +1,58 @@ +package bls + +import ( + "crypto/rand" + "github.com/filecoin-project/go-address" + "testing" +) + +func Benchmark_blsSigner_Sign(b *testing.B) { + signer := blsSigner{} + b.ResetTimer() + for i:=0;i