This is a preparation commit for segwit, but won't hurt to include ahead of time.
It is necessary as the relayed serialization will depend on what the peer requests.
This is a preparation commit for segwit, but won't hurt to include ahead of time.
It is necessary as the relayed serialization will depend on what the peer requests.
I think with segwit we're getting at the point we're going to need so many backports for 0.12.2 we'd better just release 0.13 early...
utACK https://github.com/bitcoin/bitcoin/pull/7877/commits/38c310299cfef419d42744362b90c1700b598953
I'd agree with backporting this "early" (as soon as it is merged into master) to avoid confusion and cherry-pick conflicts due to "out-of-order" cherry-picks, but it seems this is already conflicting on 0.12, so better leave such conflicting cherry-picks to a separate pull request with review before merge.
@MarcoFalke My segwit-base branch is 0.12-based, and includes backports from master and other pull requests needed already.
I'd agree with backporting this "early" (as soon as it is merged into master)
That would rule out merging this for now - there is a release in progress on the 0.12 branch, so only things that are critical enough to warrant a rc3 should be merged there right now.
But I'd prefer to backport this as part of other segwit changes, also to have the context clear.
ACK 38c310299cfef419d42744362b90c1700b598953
In case anyone else has the same thought: I was wondering what the memory usage ratio was between a CTransaction and its serialization; it seems to be about 1.4x as big, which is small enough that it should be better to store the CTransaction than both of the serializations that would generally be needed post-segwit. (Also serialization seems to be fast enough that it's not worth worrying about doing it for each peer.)
utACK 38c310299cfef419d42744362b90c1700b598953
nice, I had the same change locally for a different reason. Freebie :)
utACK.
I was wondering what the memory usage ratio was between a CTransaction and its serialization; it seems to be about 1.4x as big, which is small enough that it should be better to store the CTransaction than both of the serializations that would generally be needed post-segwit. (Also serialization seems to be fast enough that it's not worth worrying about doing it for each peer.)
Thanks for checking this, it was in the back of my mind as well.