File tree 2 files changed +29
-0
lines changed
2 files changed +29
-0
lines changed Original file line number Diff line number Diff line change @@ -29,6 +29,7 @@ bench_bench_bitcoin_SOURCES = \
29
29
bench/data.h \
30
30
bench/descriptors.cpp \
31
31
bench/duplicate_inputs.cpp \
32
+ bench/ellswift.cpp \
32
33
bench/examples.cpp \
33
34
bench/gcs_filter.cpp \
34
35
bench/hashpadding.cpp \
Original file line number Diff line number Diff line change
1
+ // Copyright (c) 2016-2020 The Bitcoin Core developers
2
+ // Distributed under the MIT software license, see the accompanying
3
+ // file COPYING or http://www.opensource.org/licenses/mit-license.php.
4
+
5
+ #include < bench/bench.h>
6
+
7
+ #include < key.h>
8
+ #include < random.h>
9
+
10
+ #include < array>
11
+
12
+ static void EllSwiftEncode (benchmark::Bench& bench)
13
+ {
14
+ ECC_Start ();
15
+
16
+ std::array<uint8_t , 32 > rnd32;
17
+ GetRandBytes (rnd32);
18
+
19
+ CKey key;
20
+ key.MakeNewKey (true );
21
+
22
+ bench.batch (1 ).unit (" pubkey" ).run ([&] {
23
+ key.EllSwiftEncode (rnd32);
24
+ });
25
+ ECC_Stop ();
26
+ }
27
+
28
+ BENCHMARK (EllSwiftEncode);
You can’t perform that action at this time.
0 commit comments