{"type":"rich","version":"1.0","author_name":"npub1g6vxlp4e0nyhs2dqxxcryztyf5f5hyuaq93nw4r87zcnv0sdsa0qqsl5wd","author_url":"https://nostr.ae/npub1g6vxlp4e0nyhs2dqxxcryztyf5f5hyuaq93nw4r87zcnv0sdsa0qqsl5wd","provider_name":"njump","provider_url":"https://nostr.ae","html":"📅 Original date posted:2015-05-16\n📝 Original message:On Sat, May 16, 2015 at 1:22 AM, Rusty Russell \u003crusty at rustcorp.com.au\u003e\nwrote:\n\n\u003e Some tweaks:\n\u003e\n\u003e 1) Nomenclature: call tx_size \"tx_cost\" and real_size \"tx_bytes\"?\n\u003e\n\nFair enough.\n\n\u003e\n\u003e 2) If we have a reasonable hard *byte* limit, I don't think that we need\n\u003e    the MAX().  In fact, it's probably OK to go negative.\n\u003e\n\nI agree, we want people to compress the UTXO space and a transaction with\n100 inputs and one output is great.\n\nIt may have privacy problem though.\n\n\n\u003e\n\u003e 3) ... or maybe not, if any consumed UTXO was generated before the soft\n\u003e    fork (reducing Tier's perverse incentive).\n\u003e\n\nThe incentive problem can be fixed by excluding UTXOs from blocks before a\ncertain count.\n\nUTXOs in blocks before 375000 don't count.\n\n\n\u003e\n\u003e 4) How do we measure UTXO size?  There are some constant-ish things in\n\u003e    there (eg. txid as key, height, outnum, amount).  Maybe just add 32\n\u003e    to scriptlen?\n\u003e\n\nThey can be stored as a fixed digest.  That can be any size, depending on\nsecurity requirements.\n\nGmaxwell's cost proposal is 3-4 bytes per UTXO change.  It isn't\n4*UXTO.size - 3*UTXO.size\n\nIt is only a small nudge.  With only 10% of the block space to play with it\ncan't be massive.\n\nThis requires that transactions include scriptPubKey information when\nbroadcasting them.\n\n\n\u003e\n\u003e 5) Add a CHECKSIG cost.  Naively, since we allow 20,000 CHECKSIGs and\n\u003e    1MB blocks, that implies a cost of 50 bytes per CHECKSIG (but counted\n\u003e    correctly, unlike now).\n\u003e\n\u003e This last one implies that the initial cost limit would be 2M, but in\n\u003e practice probably somewhere in the middle.\n\u003e\n\u003e   tx_cost = 50*num-CHECKSIG\n\u003e                 + tx_bytes\n\u003e                 + 4*utxo_created_size\n\u003e                 - 3*utxo_consumed_size\n\u003e\n\u003e \u003e A 250 byte transaction with 2 inputs and 2 outputs would have an adjusted\n\u003e \u003e size of 252 bytes.\n\u003e\n\u003e Now cost == 352.\n\u003e\n\nThat is to large a cost for a 10% block change.  It could be included in\nthe block size hard fork though.  I think have one combined \"cost\" for\ntransactions is good.  It means much fewer spread out transaction checks.\nThe code for the cost formula would be in one place.\n-------------- next part --------------\nAn HTML attachment was scrubbed...\nURL: \u003chttp://lists.linuxfoundation.org/pipermail/bitcoin-dev/attachments/20150516/8e5f1099/attachment.html\u003e"}
