lbrycrd/src/bench
Wladimir J. van der Laan 028b0d963c
Merge #13425: Moving final scriptSig construction from CombineSignatures to ProduceSignature (PSBT signer logic)
b81560029 Remove CombineSignatures and replace tests (Andrew Chow)
ed94c8b55 Replace CombineSignatures with ProduceSignature (Andrew Chow)
0422beb9b Make SignatureData able to store signatures and scripts (Andrew Chow)
b6edb4f5e Inline Sign1 and SignN (Andrew Chow)

Pull request description:

  Currently CombineSignatures is used to create the final scriptSig or an input. However ProduceSignature is capable of doing this itself. Using both CombineSignatures and ProduceSignature results in code duplication which is unnecessary.

  To move the scriptSig construction to ProduceSignatures, the SignatureData class contains two maps to hold pubkeys mapped to signatures, and script ids mapped to scripts. DataFromTransaction is extended to be able to extract signatures, their public keys, and scripts from existing ScriptSigs.

  The SignaureData are then passed down to SignStep which can use the aforementioned maps to get the signatures, pubkeys, and scripts that it needs, falling back to the actual SigningProvider and SignatureCreator if the data are not available in the SignatureData.

  Additionally, Sign1 and SignN have been removed and their functionality inlined into SignStep since Sign1 is really just a wrapper around CreateSig.

  Since ProduceSignature can produce the final scriptSig or scriptWitness by using SignatureData which has extracted data from the transaction, CombineSignatures is unnecessary as ProduceSignature is able to replicate all of CombineSignatures' functionality.

  This also furthers BIP 174 support and begins moving towards a BIP 174 style backend.

  The tests have also been updated to use the new combining methodology.

Tree-SHA512: 78cd58a4ebe37f79229bd5eee2958a0bb45cd7f36d0e993eee13ff685b3665dd76ef2dfd5f47d34678995bb587f5594100ee5f6c09b1c69ee96d3684d470d01e
2018-07-05 17:18:50 +02:00
..
data Add deserialize + CheckBlock benchmarks, and a full block hex 2016-11-09 11:27:59 -08:00
.gitignore Ignore bench_bitcoin binary. 2015-10-06 17:46:12 +02:00
base58.cpp Increment MIT Licence copyright header year on files modified in 2017 2018-01-03 02:26:56 +09:00
bench.cpp benchmark: Removed bench/perf.cpp 2018-04-18 19:53:10 -07:00
bench.h trivial: Mark overrides as such. 2018-05-20 09:15:39 +02:00
bench_bitcoin.cpp bench: Use non-throwing ParseDouble(...) instead of throwing boost::lexical_cast<double>(...) 2018-06-03 21:30:39 +02:00
block_assemble.cpp bench: Add missing pow.h header 2018-06-24 19:25:03 +02:00
ccoins_caching.cpp Increment MIT Licence copyright header year on files modified in 2017 2018-01-03 02:26:56 +09:00
checkblock.cpp Increment MIT Licence copyright header year on files modified in 2017 2018-01-03 02:26:56 +09:00
checkqueue.cpp Increment MIT Licence copyright header year on files modified in 2017 2018-01-03 02:26:56 +09:00
coin_selection.cpp bench: Simplify CoinSelection 2018-06-28 14:28:42 +01:00
crypto_hash.cpp Specialized double sha256 for 64 byte inputs 2018-05-29 14:05:00 -07:00
examples.cpp Do not use uppercase characters in source code filenames 2018-05-23 16:07:37 +02:00
lockedpool.cpp Merge #12048: Use best-fit strategy in Arena, now O(log(n)) instead O(n) 2018-03-22 14:28:37 +01:00
mempool_eviction.cpp bench: Amend mempool_eviction test for witness txs 2018-04-17 19:51:47 -04:00
merkle_root.cpp Use bracket syntax includes ("#include <foo.h>") 2018-06-06 11:09:05 +02:00
prevector.cpp Make it clear which functions that are intended to be translation unit local 2018-05-03 21:47:40 +02:00
rollingbloom.cpp Increment MIT Licence copyright header year on files modified in 2017 2018-01-03 02:26:56 +09:00
verify_script.cpp Make SignatureData able to store signatures and scripts 2018-07-03 17:18:52 -07:00