Bitcoin Forum

Bitcoin => Pools => Topic started by: Peter Todd on March 10, 2013, 01:59:50 AM



Title: Blocking uneconomic UTXO creation
Post by: Peter Todd on March 10, 2013, 01:59:50 AM
I've created a patch (https://github.com/petertodd/bitcoin/tree/block-uneconomic-utxo-creation) that blocks the creation of transaction outputs whose value is smaller than the fee per KB the transaction is paying. Basically it's blocking the creation of transaction outputs that would cost more to spend than they are worth. Because it determines this by fee, it's adaptive, and will automatically adjust as fees change. At the same time, if someone creates a really high fee transaction, like the recent 93BTC one, there is an upper limit, so you'll still collect it and profit.

Ultimately the issue is right now SatoshiDice is creating huge amounts of "you lost" transaction outputs that have a value so small they don't make sense to spend; >50% of the unspent transaction outputs are for just one satoshi. This hurts pool operators because while transaction history can be stored on slow hard-drives, and in the future pruned away, the set of all unspent transactions must be stored in fast memory so when your pool receives a new block you can validate every transaction spend, and start working on a new block. The bigger the UTXO set gets, the more RAM you need to provision for the computers your pool runs on.

If pool operators adopt this patch I expect SatoshiDice will simply change their failed bet outputs to always be > the transaction fee, and thus users will be able to spend those outputs. You'll still collect the large fees SatoshiDice is paying to miners, yet keep your costs down in the long run, and keep Bitcoin viable as a decentralized currency.


Title: Re: Blocking uneconomic UTXO creation
Post by: solex on March 11, 2013, 10:47:10 PM
retep, that patch sounds like great progress.

Regarding SD. the minimum bet is 0.01 BTC, so the minimum payout is 5,000 satoshi as it always returns at least 0.5%

Ok. I just checked on github and based on the latest revision dust is considered < 100,000 satoshi
However, the fx rate is 3 times higher since that was decided, so 33,000 is a reasonable comparison now. So any SatoshiDice bet above 0.07 will not leave a dust amount for a loss.
https://github.com/bitcoin/bitcoin/pull/2100

Since then I sampled a few thousand recent bets and found that 54% are 0.06 or less.


Title: Re: Blocking uneconomic UTXO creation
Post by: hobbes on April 15, 2013, 12:35:45 PM
Does the patch allow 0 value tx? These don't have to be spent but can be pruned right away.

This nice timestamping service is the reason for my question:
http://vog.github.io/bitcoinproof/

It creates an address by hashing your data.


Title: Re: Blocking uneconomic UTXO creation
Post by: Peter Todd on April 15, 2013, 01:53:49 PM
Does the patch allow 0 value tx? These don't have to be spent but can be pruned right away.

This nice timestamping service is the reason for my question:
http://vog.github.io/bitcoinproof/

It creates an address by hashing your data.

Such outputs can still be spent, so no it does not allow them. However, see my post here about prunable outputs: https://bitcointalk.org/index.php?topic=151329.msg1844144#msg1844144

I'm curious, have you tried my OpenTimestamps (https://github.com/opentimestamps/) stuff? If so, what did you think?


Title: Re: Blocking uneconomic UTXO creation
Post by: hobbes on April 15, 2013, 03:52:37 PM
Does the patch allow 0 value tx? These don't have to be spent but can be pruned right away.

This nice timestamping service is the reason for my question:
http://vog.github.io/bitcoinproof/

It creates an address by hashing your data.

Such outputs can still be spent, so no it does not allow them. However, see my post here about prunable outputs: https://bitcointalk.org/index.php?topic=151329.msg1844144#msg1844144
Interesting what you guys have going under the hood :)

I realized nobody would want his timestamping to be pruned so you would have to make it a spendable tx anyway.   :)

Quote
I'm curious, have you tried my OpenTimestamps (https://github.com/opentimestamps/) stuff? If so, what did you think?
It looks very sophisticated. The other one is so simple it is brilliant in it's way.