1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
|
Delivery-date: Mon, 12 May 2025 10:21:24 -0700
Received: from mail-oo1-f60.google.com ([209.85.161.60])
by mail.fairlystable.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256
(Exim 4.94.2)
(envelope-from <bitcoindev+bncBDML5DFJWQEBBCW4RDAQMGQE3ECBT2Y@googlegroups.com>)
id 1uEWqB-00010F-TX
for bitcoindev@gnusha.org; Mon, 12 May 2025 10:21:24 -0700
Received: by mail-oo1-f60.google.com with SMTP id 006d021491bc7-6049e1c6629sf4128668eaf.1
for <bitcoindev@gnusha.org>; Mon, 12 May 2025 10:21:23 -0700 (PDT)
ARC-Seal: i=2; a=rsa-sha256; t=1747070478; cv=pass;
d=google.com; s=arc-20240605;
b=ffoooZVIxlpj9gDV7hQyespTqZyUYHYhRNTXqLZsCjrrB0Me4T9dLgQRCP9qXKzbvD
L1M6fZsS1umQp6gCB0T0hoL3A8hHe69/cSEs+FFglkqgttNLgPxAFQR05NfEOM3zNpbI
U1ciNNU2XuWxUwBvLbBSf/KnDZj39TJFX8/u3M7p7Ap9DwonHArq2Yz0mBN3du4mB/Qq
GdKMDmPfjZaOXdP4BxM09rZci+SKwp8dkKJxYdBTQrLLbSCuOB4hyF4ccJiPJID7Dpc5
l2aiSOHQsmX0fYwJ53N4DMtEb16BxZyM2q5L27YPxJp2BGo35Dd92v5gOXBcgIc9J/Y8
WHjg==
ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605;
h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post
:list-id:mailing-list:precedence:to:subject:message-id:date:from
:mime-version:sender:dkim-signature:dkim-signature;
bh=/mQS6yoMDat4DP4wGT9sQaWLUgunRB/kGKpR0FR4p+Q=;
fh=oatLYyggxyYl/3W2ZO1uUtN1q20BCFH6mg2wh9GBzYg=;
b=hybmdiZr54w1GIW/Y4x/4fAg8iFKEtSX6X4mpPA9KSMPey6UFiGmeUDryhgjzTrRA8
X7HPccLuLmLG10Y7L84L3A7pMFt3L86oGWl/lTnayO7oXO3e9cUqFadWbeCukzg12ILp
pS1OjhQebRiqV+Jobznsp9svOn8g1r4ixlNzmsAc5OOvD9mbyCjjrsJGRIia5+aSvmp7
RdK/tohsGmkSynohVCXLNTxSBtHjRd5xU3VTFPF8JutgWXQQO5XzJDQDubF7Y4Sskf0D
aRWF8X3+GeYz0cshAHwzyO8mHjt1jlAimgQaM5gCTDkuLBKiAXHa9SmHtqZAH/P7Up9G
tjNQ==;
darn=gnusha.org
ARC-Authentication-Results: i=2; gmr-mx.google.com;
dkim=pass header.i=@gmail.com header.s=20230601 header.b="RP/vxoNJ";
spf=pass (google.com: domain of stewart.chris1234@gmail.com designates 2607:f8b0:4864:20::112e as permitted sender) smtp.mailfrom=stewart.chris1234@gmail.com;
dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com;
dara=pass header.i=@googlegroups.com
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=googlegroups.com; s=20230601; t=1747070478; x=1747675278; darn=gnusha.org;
h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post
:list-id:mailing-list:precedence:x-original-authentication-results
:x-original-sender:to:subject:message-id:date:from:mime-version
:sender:from:to:cc:subject:date:message-id:reply-to;
bh=/mQS6yoMDat4DP4wGT9sQaWLUgunRB/kGKpR0FR4p+Q=;
b=MLWiDHmBMMynb2Z/yuDpfblrgLtdgffdRIuSJaBNfe6jqY5SIs2+fWvHPzzF/7Cokv
LqAv9lo8fZuOGdKLjPV/I/mK5nPSmVyiEMT468HQ3L1n4MZBjI8lIZ2c6jQs2oBP6rp8
ldJtPBud5A0zbbjQRgyJiLW5R6e6f3is9TJY91CQdVHijF1lOYDd0MFOkczM1aWkMP8Z
FiNHy1tlbe1le33MT+ynchr51USFXLs7VMDQGoj0i19v/jf16IDfShPxXtW5kNHcSE0i
+xozCad3veSGK7Fftf+yfsv4+bbUTZVjxUD1nRLP8ZM037kpAilXdwx0kz3ViCBj9TCp
27gg==
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=20230601; t=1747070478; x=1747675278; darn=gnusha.org;
h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post
:list-id:mailing-list:precedence:x-original-authentication-results
:x-original-sender:to:subject:message-id:date:from:mime-version:from
:to:cc:subject:date:message-id:reply-to;
bh=/mQS6yoMDat4DP4wGT9sQaWLUgunRB/kGKpR0FR4p+Q=;
b=O7aDfU82HOmPs2r/0+KZSZvdBaWhy6BjxU2Vmld1N6F3gmy+UXtkPZHyCvHsXK64YR
48gXtkGPjg9R4cGI6YkICtVHt9NlYSnTXrXIkAdgbfnbabGqyjr3qLf7TxmtRxXO2bJX
WbsvWMixlBoIGAPf+OQ3suv9lx6z+VU3cqng8AaYtP1mBwfGGx2d5t87wR7GArMA6M0T
jTE4eXdZBIiwQomx4OhcHXajDY/9/4HZBDhruM6ozW7CTO6biJM4EWmV5p5C+WN6M0wl
DauU98uwcCZxCwVcuq7qwhpZLHLkC3K0v4dEODLDp/JueEWJU1Bt8+rgWMWJGxR7WNk3
eH2A==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20230601; t=1747070478; x=1747675278;
h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post
:list-id:mailing-list:precedence:x-original-authentication-results
:x-original-sender:to:subject:message-id:date:from:mime-version
:x-beenthere:x-gm-message-state:sender:from:to:cc:subject:date
:message-id:reply-to;
bh=/mQS6yoMDat4DP4wGT9sQaWLUgunRB/kGKpR0FR4p+Q=;
b=qInVvCq/rcduvTrMbsOyB2atBKI0ixMnv/9NyEgWgi4gOi+jnm6UePYf0R8fk57Eut
5RrrIczYblPBHzjRaXqnefQ+rYYmifwJi470mxOB279V52c4QxYwkivDP8OhuGhZ8un1
62Godr4+b0MMREHGPOXRn7GT30m7VXxZFZZMhLJl9IOmXvZ/PSFevlYcO9enkHw7h2Jy
FI8D7efJEsD9zWyVlamOhzjC8KBUWP/ZgBwR2HjHO1GfvGgmIe9muVaUBZ1Ts2phjesZ
ooPrcUMuhiWZIEh13nRyJnuhZD73uDvv9GS6TM2kUFYNeDGU6a9cbE1Delcq94Zq9nqd
5UJw==
Sender: bitcoindev@googlegroups.com
X-Forwarded-Encrypted: i=2; AJvYcCWRi7Qc01D7OE5BoDCyAdmIvtSh5MJlpvAp8t9afp0NKUw2Copl12++usXpTiklH3PoqiL2ntJAh7/v@gnusha.org
X-Gm-Message-State: AOJu0YytXQlW5Jgy8pteLhiW6m8UeLGGVshcdBXYRPGOUroAAQ+CskFA
nbJJzBU1J1R/CMczR26PAZD6WteJ2F5O5QIZ+mdb+xqizWVqvutY
X-Google-Smtp-Source: AGHT+IEBKeja3xV/t6zHSbOxHTcgE42TeXpp2aek7xNSCwHUb7K24d2+xCuvVDCfVeahJhTFDsxtjw==
X-Received: by 2002:a05:6820:1f07:b0:606:26bb:db78 with SMTP id 006d021491bc7-6084c126876mr7840473eaf.8.1747070477515;
Mon, 12 May 2025 10:21:17 -0700 (PDT)
X-BeenThere: bitcoindev@googlegroups.com; h=AVT/gBHX4DmQbZnzXnlwnwHV8gqSd2RRkH2mVtLah6/9ywIhfw==
Received: by 2002:a05:6820:c28a:b0:608:3554:1a64 with SMTP id
006d021491bc7-60835541bbdls1259336eaf.0.-pod-prod-01-us; Mon, 12 May 2025
10:21:13 -0700 (PDT)
X-Received: by 2002:a05:6808:1885:b0:401:e7c0:62bd with SMTP id 5614622812f47-4037fe1e47amr8162855b6e.3.1747070473796;
Mon, 12 May 2025 10:21:13 -0700 (PDT)
Received: by 2002:a05:6808:83c3:b0:3f9:f009:458e with SMTP id 5614622812f47-4037ff61fe9msb6e;
Mon, 12 May 2025 09:15:23 -0700 (PDT)
X-Received: by 2002:a05:6a20:c78c:b0:1f5:80a3:b006 with SMTP id adf61e73a8af0-215abb3fa24mr19450105637.21.1747066521943;
Mon, 12 May 2025 09:15:21 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; t=1747066521; cv=none;
d=google.com; s=arc-20240605;
b=eowdTQgBqoBX1wEwY5GVSAdyKCJPM/ebp2Vluqmc4+dcRZYFa2+RQpIQ6TJvOBvkBM
6sN0DKKkTs0ySfBHBZpe6C60FBeGdIrMDDoEfQYVKhcHhUA3PJ3VCeU0H5IcOqjle8gt
vjA1oL0d+FKKt7XZ0Yvv0UFwhd2LMzdlmg+/BsrXmSB2QjpZqdhAocn6+6HEMmRlstJ1
lkHsKkiNB+foWVzK4UFoaDtAKeNg5s08c6k1YtSG4IEMtkhvJZ8lbcN7blpVKFVnrZcs
tWofl+5P05mUJ6Wda7q2iX1rUuPgnQeqhHE6A0EgQlRdKJZ6XmDXDDqd9maRlh5JlD3Y
YVtw==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605;
h=to:subject:message-id:date:from:mime-version:dkim-signature;
bh=Ii0Pt21FQml6Ke9BGxTiylZ2NQXXRLOPb7fhZr8AOfY=;
fh=DMP0F9ULS1guKiqimntQRCN8ZraraesEgQuVcn7F0Z0=;
b=CX4UnP/OSOpgRilVqU4vJT7Hf8j4x3YQVBluEZLLPy0ITvFQ4vzm27mLQE9qtfLAYK
G1y88yH8gKzgyKDyvgkQ3FnZOpVlZdR2tTN85TnuABN2sT0Xz2tejcg2EVVmgoq5o7I9
BRuB6ymd5CobbdcPeSZsNsxPX0ZEx79ynnjFbAsV90VuKUqKvLJ+1NJzovoVU5sO4alj
DivNNMCyHLLxDjRmfNKSDmEdJ5Eo8TiPTWzd/FzSgnlG3qXVA6W+fwcKBfIZNUpw8si4
Su+vZnTtlgMRHOJaBHKTsMK+0Z8CX/Zd9gO6OtjFotG+mDXEeDMvlJFxzSyTB7TEnA3u
LVpA==;
dara=google.com
ARC-Authentication-Results: i=1; gmr-mx.google.com;
dkim=pass header.i=@gmail.com header.s=20230601 header.b="RP/vxoNJ";
spf=pass (google.com: domain of stewart.chris1234@gmail.com designates 2607:f8b0:4864:20::112e as permitted sender) smtp.mailfrom=stewart.chris1234@gmail.com;
dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com;
dara=pass header.i=@googlegroups.com
Received: from mail-yw1-x112e.google.com (mail-yw1-x112e.google.com. [2607:f8b0:4864:20::112e])
by gmr-mx.google.com with ESMTPS id 41be03b00d2f7-b2347a01525si353296a12.2.2025.05.12.09.15.21
for <bitcoindev@googlegroups.com>
(version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128);
Mon, 12 May 2025 09:15:21 -0700 (PDT)
Received-SPF: pass (google.com: domain of stewart.chris1234@gmail.com designates 2607:f8b0:4864:20::112e as permitted sender) client-ip=2607:f8b0:4864:20::112e;
Received: by mail-yw1-x112e.google.com with SMTP id 00721157ae682-7082ad1355bso39291277b3.1
for <bitcoindev@googlegroups.com>; Mon, 12 May 2025 09:15:21 -0700 (PDT)
X-Gm-Gg: ASbGncugHYOyxfMtMS9AMOmnAsktI6bOmfLZk+KWY+2ojhBkQ5zw87Lw9CH0gAdU+cL
JU5FpwC5BdYbiZFqAdjrfzK5F1qL8G4B/e63dB7HJ1Esatmk7saLNlm5pF1F8T+99RLerorLDK/
FJb2Ao/Ur2AWiAvbOWDjPkzoHEGY+niNc=
X-Received: by 2002:a05:690c:610e:b0:708:3532:ec94 with SMTP id
00721157ae682-70a3f86f205mr178462907b3.0.1747066520813; Mon, 12 May 2025
09:15:20 -0700 (PDT)
MIME-Version: 1.0
From: Chris Stewart <stewart.chris1234@gmail.com>
Date: Mon, 12 May 2025 11:15:10 -0500
X-Gm-Features: AX0GCFu604EDHiGOz2vKje18oW4ZzzimHnhTfWGzGqRAb8rzlGEKsQioKCAQlpY
Message-ID: <CAGL6+mH+9iq5_SR-Fa5zVZRoTpHasX7xoprYeJZRd5D80J1GqA@mail.gmail.com>
Subject: [bitcoindev] [Proposal] 64-bit arithmetic in Script
To: Bitcoin Development Mailing List <bitcoindev@googlegroups.com>
Content-Type: multipart/alternative; boundary="0000000000005f48e30634f29f98"
X-Original-Sender: stewart.chris1234@gmail.com
X-Original-Authentication-Results: gmr-mx.google.com; dkim=pass
header.i=@gmail.com header.s=20230601 header.b="RP/vxoNJ"; spf=pass
(google.com: domain of stewart.chris1234@gmail.com designates
2607:f8b0:4864:20::112e as permitted sender) smtp.mailfrom=stewart.chris1234@gmail.com;
dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com;
dara=pass header.i=@googlegroups.com
Precedence: list
Mailing-list: list bitcoindev@googlegroups.com; contact bitcoindev+owners@googlegroups.com
List-ID: <bitcoindev.googlegroups.com>
X-Google-Group-Id: 786775582512
List-Post: <https://groups.google.com/group/bitcoindev/post>, <mailto:bitcoindev@googlegroups.com>
List-Help: <https://groups.google.com/support/>, <mailto:bitcoindev+help@googlegroups.com>
List-Archive: <https://groups.google.com/group/bitcoindev
List-Subscribe: <https://groups.google.com/group/bitcoindev/subscribe>, <mailto:bitcoindev+subscribe@googlegroups.com>
List-Unsubscribe: <mailto:googlegroups-manage+786775582512+unsubscribe@googlegroups.com>,
<https://groups.google.com/group/bitcoindev/subscribe>
X-Spam-Score: -0.5 (/)
--0000000000005f48e30634f29f98
Content-Type: text/plain; charset="UTF-8"
This soft fork proposal extends the range of numeric operands in Script
from -2^31+1 to 2^31-1, to -2^63+1 to 2^63-1. It further expands the result
range for arithmetic operations from -2^63 to 2^63-1, to -2^127 to 2^127-
1.
All existing opcodes[1
<https://github.com/Christewart/bips/blob/2025-03-17-64bit-pt2/bip-XXXX.mediawiki#cite_note-1>
] that interpret stack elements as numbers are upgraded to support 64-bit
parameters.
The existing number encoding format[2
<https://github.com/Christewart/bips/blob/2025-03-17-64bit-pt2/bip-XXXX.mediawiki#cite_note-2>
] and arithmetic semantics[3
<https://github.com/Christewart/bips/blob/2025-03-17-64bit-pt2/bip-XXXX.mediawiki#cite_note-3>
] from the original Bitcoin implementation are preserved, while enhancing
the supported precision.
https://github.com/Christewart/bips/blob/2025-03-17-64bit-pt2/bip-XXXX.mediawiki
The purpose for this BIP is to lay the groundwork for introducing amounts
into Script. This document takes no opinion on how this is done.
I've prototyped a few different proposals now introducing amount locks into
Script[0][1] and feel like this proposal is stable enough for serious
review.
-Chris
[0] - https://delvingbitcoin.org/t/op-inout-amount/549/4?u=chris_stewart_5
[1] - https://delvingbitcoin.org/t/op-inout-amount/549/5?u=chris_stewart_5
--
You received this message because you are subscribed to the Google Groups "Bitcoin Development Mailing List" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bitcoindev+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/bitcoindev/CAGL6%2BmH%2B9iq5_SR-Fa5zVZRoTpHasX7xoprYeJZRd5D80J1GqA%40mail.gmail.com.
--0000000000005f48e30634f29f98
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
<div dir=3D"ltr"><p dir=3D"auto">This soft fork proposal extends the range =
of numeric operands in Script from -2^<sup>31</sup>+1 to 2^<sup>31</sup>-1,=
to -2^<sup>63</sup>+1 to 2^<sup>63</sup>-1.
It further expands the result range for arithmetic operations from -2^<sup>=
63</sup> to 2^<sup>63</sup>-1, to -2^<sup>127</sup> to 2^<sup>127</sup>- 1.
</p>
<p dir=3D"auto">All existing opcodes<sup id=3D"gmail-user-content-cite_ref-=
1-0">[<a href=3D"https://github.com/Christewart/bips/blob/2025-03-17-64bit-=
pt2/bip-XXXX.mediawiki#cite_note-1">1</a>]</sup>=20
that interpret stack elements as numbers are upgraded to support 64-bit par=
ameters.
</p>
<p dir=3D"auto">The existing number encoding format<sup id=3D"gmail-user-co=
ntent-cite_ref-2-0">[<a href=3D"https://github.com/Christewart/bips/blob/20=
25-03-17-64bit-pt2/bip-XXXX.mediawiki#cite_note-2">2</a>]</sup>=20
and arithmetic semantics<sup id=3D"gmail-user-content-cite_ref-3-0">[<a hre=
f=3D"https://github.com/Christewart/bips/blob/2025-03-17-64bit-pt2/bip-XXXX=
.mediawiki#cite_note-3">3</a>]</sup>=20
from the original Bitcoin implementation are preserved, while enhancing the=
supported precision.</p><p dir=3D"auto"><a href=3D"https://github.com/Chri=
stewart/bips/blob/2025-03-17-64bit-pt2/bip-XXXX.mediawiki">https://github.c=
om/Christewart/bips/blob/2025-03-17-64bit-pt2/bip-XXXX.mediawiki</a></p><p>=
The purpose for this BIP is to lay the groundwork for introducing amounts i=
nto Script. This document takes no opinion on how this is done.</p><p>I'=
;ve prototyped a few different proposals now introducing amount locks into =
Script[0][1] and feel like this proposal is stable enough for serious revie=
w.</p><p>-Chris</p><p>[0] - <a href=3D"https://delvingbitcoin.org/t/op-inou=
t-amount/549/4?u=3Dchris_stewart_5">https://delvingbitcoin.org/t/op-inout-a=
mount/549/4?u=3Dchris_stewart_5</a></p><p>[1] - <a href=3D"https://delvingb=
itcoin.org/t/op-inout-amount/549/5?u=3Dchris_stewart_5">https://delvingbitc=
oin.org/t/op-inout-amount/549/5?u=3Dchris_stewart_5</a></p><p><br></p><br><=
/div>
<p></p>
-- <br />
You received this message because you are subscribed to the Google Groups &=
quot;Bitcoin Development Mailing List" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to <a href=3D"mailto:bitcoindev+unsubscribe@googlegroups.com">bitcoind=
ev+unsubscribe@googlegroups.com</a>.<br />
To view this discussion visit <a href=3D"https://groups.google.com/d/msgid/=
bitcoindev/CAGL6%2BmH%2B9iq5_SR-Fa5zVZRoTpHasX7xoprYeJZRd5D80J1GqA%40mail.g=
mail.com?utm_medium=3Demail&utm_source=3Dfooter">https://groups.google.com/=
d/msgid/bitcoindev/CAGL6%2BmH%2B9iq5_SR-Fa5zVZRoTpHasX7xoprYeJZRd5D80J1GqA%=
40mail.gmail.com</a>.<br />
--0000000000005f48e30634f29f98--
|