From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from sog-mx-2.v43.ch3.sourceforge.com ([172.29.43.192] helo=mx.sourceforge.net) by sfs-ml-1.v29.ch3.sourceforge.com with esmtp (Exim 4.76) (envelope-from ) id 1YtZye-0002tD-OD for bitcoin-development@lists.sourceforge.net; Sat, 16 May 2015 11:09:56 +0000 Received-SPF: pass (sog-mx-2.v43.ch3.sourceforge.com: domain of gmail.com designates 209.85.192.54 as permitted sender) client-ip=209.85.192.54; envelope-from=tier.nolan@gmail.com; helo=mail-qg0-f54.google.com; Received: from mail-qg0-f54.google.com ([209.85.192.54]) by sog-mx-2.v43.ch3.sourceforge.com with esmtps (TLSv1:RC4-SHA:128) (Exim 4.76) id 1YtZyd-0002kN-Jc for bitcoin-development@lists.sourceforge.net; Sat, 16 May 2015 11:09:56 +0000 Received: by qgew3 with SMTP id w3so22260899qge.2 for ; Sat, 16 May 2015 04:09:50 -0700 (PDT) MIME-Version: 1.0 X-Received: by 10.55.56.201 with SMTP id f192mr28749201qka.88.1431774590163; Sat, 16 May 2015 04:09:50 -0700 (PDT) Received: by 10.140.85.241 with HTTP; Sat, 16 May 2015 04:09:50 -0700 (PDT) In-Reply-To: <87a8x5l6bt.fsf@rustcorp.com.au> References: <16096345.A1MpJQQkRW@crushinator> <87a8x5l6bt.fsf@rustcorp.com.au> Date: Sat, 16 May 2015 12:09:50 +0100 Message-ID: From: Tier Nolan Cc: Bitcoin Development Content-Type: multipart/alternative; boundary=001a11459238d86087051630ff21 X-Spam-Score: 2.4 (++) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for sender-domain 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (tier.nolan[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record 1.2 MISSING_HEADERS Missing To: header 1.0 HTML_MESSAGE BODY: HTML included in message -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 1.9 MALFORMED_FREEMAIL Bad headers on message from free email service -0.1 AWL AWL: Adjusted score from AWL reputation of From: address X-Headers-End: 1YtZyd-0002kN-Jc Subject: Re: [Bitcoin-development] Proposed alternatives to the 20MB step function X-BeenThere: bitcoin-development@lists.sourceforge.net X-Mailman-Version: 2.1.9 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 16 May 2015 11:09:56 -0000 --001a11459238d86087051630ff21 Content-Type: text/plain; charset=UTF-8 On Sat, May 16, 2015 at 1:22 AM, Rusty Russell wrote: > Some tweaks: > > 1) Nomenclature: call tx_size "tx_cost" and real_size "tx_bytes"? > Fair enough. > > 2) If we have a reasonable hard *byte* limit, I don't think that we need > the MAX(). In fact, it's probably OK to go negative. > I agree, we want people to compress the UTXO space and a transaction with 100 inputs and one output is great. It may have privacy problem though. > > 3) ... or maybe not, if any consumed UTXO was generated before the soft > fork (reducing Tier's perverse incentive). > The incentive problem can be fixed by excluding UTXOs from blocks before a certain count. UTXOs in blocks before 375000 don't count. > > 4) How do we measure UTXO size? There are some constant-ish things in > there (eg. txid as key, height, outnum, amount). Maybe just add 32 > to scriptlen? > They can be stored as a fixed digest. That can be any size, depending on security requirements. Gmaxwell's cost proposal is 3-4 bytes per UTXO change. It isn't 4*UXTO.size - 3*UTXO.size It is only a small nudge. With only 10% of the block space to play with it can't be massive. This requires that transactions include scriptPubKey information when broadcasting them. > > 5) Add a CHECKSIG cost. Naively, since we allow 20,000 CHECKSIGs and > 1MB blocks, that implies a cost of 50 bytes per CHECKSIG (but counted > correctly, unlike now). > > This last one implies that the initial cost limit would be 2M, but in > practice probably somewhere in the middle. > > tx_cost = 50*num-CHECKSIG > + tx_bytes > + 4*utxo_created_size > - 3*utxo_consumed_size > > > A 250 byte transaction with 2 inputs and 2 outputs would have an adjusted > > size of 252 bytes. > > Now cost == 352. > That is to large a cost for a 10% block change. It could be included in the block size hard fork though. I think have one combined "cost" for transactions is good. It means much fewer spread out transaction checks. The code for the cost formula would be in one place. --001a11459238d86087051630ff21 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
On S= at, May 16, 2015 at 1:22 AM, Rusty Russell <rusty@rustcorp.com.au&= gt; wrote:
Some tweaks:

1) Nomenclature: call tx_size "tx_cost" and real_size "tx_by= tes"?

Fair enough.

2) If we have a reasonable hard *byte* limit, I don't think that we nee= d
=C2=A0 =C2=A0the MAX().=C2=A0 In fact, it's probably OK to go negative.=

I agree, we want people to compress th= e UTXO space and a transaction with 100 inputs and one output is great.
=
It may have privacy problem though.
=C2=A0

3) ... or maybe not, if any consumed UTXO was generated before the soft
=C2=A0 =C2=A0fork (reducing Tier's perverse incentive).

The incentive problem can be fixed by excluding UTXOs = from blocks before a certain count.

UTXOs in blocks befor= e 375000 don't count.
=C2=A0

4) How do we measure UTXO size?=C2=A0 There are some constant-ish things in=
=C2=A0 =C2=A0there (eg. txid as key, height, outnum, amount).=C2=A0 Maybe j= ust add 32
=C2=A0 =C2=A0to scriptlen?

They can be = stored as a fixed digest.=C2=A0 That can be any size, depending on security= requirements.

Gmaxwell's cost proposal is 3-4 bytes = per UTXO change.=C2=A0 It isn't 4*UXTO.size - 3*UTXO.size

It is = only a small nudge.=C2=A0 With only 10% of the block space to play with it = can't be massive.

This requires that trans= actions include scriptPubKey information when broadcasting them.
<= div>=C2=A0

5) Add a CHECKSIG cost.=C2=A0 Naively, since we allow 20,000 CHECKSIGs and<= br> =C2=A0 =C2=A01MB blocks, that implies a cost of 50 bytes per CHECKSIG (but = counted
=C2=A0 =C2=A0correctly, unlike now).

This last one implies that the initial cost limit would be 2M, but in
practice probably somewhere in the middle.

=C2=A0 tx_cost =3D 50*num-CHECKSIG
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 + tx_bytes
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 + 4*utxo_created_si= ze
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 - 3*utxo_consumed_s= ize

> A 250 byte transaction with 2 inputs and 2 outputs would have an adjus= ted
> size of 252 bytes.

Now cost =3D=3D 352.

That is to = large a cost for a 10% block change.=C2=A0 It could be included in the bloc= k size hard fork though.=C2=A0 I think have one combined "cost" f= or transactions is good.=C2=A0 It means much fewer spread out transaction c= hecks.=C2=A0 The code for the cost formula would be in one place.
=
--001a11459238d86087051630ff21--