[bitcoin-dev] Composite priority: combining fees and bitcoin-days into one number

Jonathan Toomim j at toom.im
Wed Oct 28 22:41:39 UTC 2015


On Oct 28, 2015, at 12:13 AM, Luke Dashjr <luke at dashjr.org> wrote:

> On Wednesday, October 28, 2015 4:26:52 AM Jonathan Toomim via bitcoin-dev
> wrote:
> 
> This is all in the realm of node policy, which must be easy to
> modify/customise in a flexible manner. So simplifying other code in a way that
> makes the policy harder to configure is not a welcome change.
> 
> That is, by making the code simpler, if you make custom policies (such as the
> current default) harder, it is better to leave the main code less simple.

I think the only custom policy that this change would make harder to implement is the current default policy of 5% reserved space. Right now, in e.g. CreateNewBlock, you have two loops, each of which follows a completely different policy, plus additional code for corner cases like ensuring that a tx isn't added twice. If I were a miner and a mediocre programmer (which I actually am, on both accounts), and I wanted to change the mining policy, I would probably take a look at that code, groan, give up, and go sharpen my pickaxe instead.

This change could be written in an abstract way. We could define an API that is calibrated on the whole mempool, then has a method that takes transactions and returns priority scores.

If someone wanted to write a reserved-space algorithm in this priority API scheme, then they could just set it up so that most transactions would get a priority score between e.g. zero and 8999, and any transactions that were supposed to be prioritized would get a priority level over 9000. Easy enough?


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 496 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.linuxfoundation.org/pipermail/bitcoin-dev/attachments/20151028/a63666af/attachment.sig>


More information about the bitcoin-dev mailing list