mirror of
https://github.com/franklynwang/EcneProject.git
synced 2026-01-10 06:07:55 -05:00
Fixed Install issues with previous version.
This commit is contained in:
@@ -522,5 +522,5 @@ template BigModInv(n, k) {
|
||||
}
|
||||
}
|
||||
|
||||
//component main = BigLessThan(86,3);
|
||||
component main = BigMultShortLong(86,3);
|
||||
|
||||
|
||||
11
Circom_Functions/straightforward.circom
Normal file
11
Circom_Functions/straightforward.circom
Normal file
@@ -0,0 +1,11 @@
|
||||
pragma circom 2.0.2;
|
||||
|
||||
template Main() {
|
||||
signal input a;
|
||||
signal input b;
|
||||
signal output out;
|
||||
|
||||
out <== a;
|
||||
}
|
||||
|
||||
component main = Main();
|
||||
51
Circom_Functions/tornado_circuits/merkleTree.circom
Normal file
51
Circom_Functions/tornado_circuits/merkleTree.circom
Normal file
@@ -0,0 +1,51 @@
|
||||
include "../circomlib/circuits/mimcsponge.circom";
|
||||
|
||||
// Computes MiMC([left, right])
|
||||
template HashLeftRight() {
|
||||
signal input left;
|
||||
signal input right;
|
||||
signal output hash;
|
||||
|
||||
component hasher = MiMCSponge(2, 1);
|
||||
hasher.ins[0] <== left;
|
||||
hasher.ins[1] <== right;
|
||||
hasher.k <== 0;
|
||||
hash <== hasher.outs[0];
|
||||
}
|
||||
|
||||
// if s == 0 returns [in[0], in[1]]
|
||||
// if s == 1 returns [in[1], in[0]]
|
||||
template DualMux() {
|
||||
signal input in[2];
|
||||
signal input s;
|
||||
signal output out[2];
|
||||
|
||||
s * (1 - s) === 0
|
||||
out[0] <== (in[1] - in[0])*s + in[0];
|
||||
out[1] <== (in[0] - in[1])*s + in[1];
|
||||
}
|
||||
|
||||
// Verifies that merkle proof is correct for given merkle root and a leaf
|
||||
// pathIndices input is an array of 0/1 selectors telling whether given pathElement is on the left or right side of merkle path
|
||||
template MerkleTreeChecker(levels) {
|
||||
signal input leaf;
|
||||
signal input root;
|
||||
signal input pathElements[levels];
|
||||
signal input pathIndices[levels];
|
||||
|
||||
component selectors[levels];
|
||||
component hashers[levels];
|
||||
|
||||
for (var i = 0; i < levels; i++) {
|
||||
selectors[i] = DualMux();
|
||||
selectors[i].in[0] <== i == 0 ? leaf : hashers[i - 1].hash;
|
||||
selectors[i].in[1] <== pathElements[i];
|
||||
selectors[i].s <== pathIndices[i];
|
||||
|
||||
hashers[i] = HashLeftRight();
|
||||
hashers[i].left <== selectors[i].out[0];
|
||||
hashers[i].right <== selectors[i].out[1];
|
||||
}
|
||||
|
||||
root === hashers[levels - 1].hash;
|
||||
}
|
||||
67
Circom_Functions/tornado_circuits/withdraw.circom
Normal file
67
Circom_Functions/tornado_circuits/withdraw.circom
Normal file
@@ -0,0 +1,67 @@
|
||||
include "../circomlib/circuits/bitify.circom";
|
||||
include "../circomlib/circuits/pedersen.circom";
|
||||
include "merkleTree.circom";
|
||||
|
||||
// computes Pedersen(nullifier + secret)
|
||||
template CommitmentHasher() {
|
||||
signal input nullifier;
|
||||
signal input secret;
|
||||
signal output commitment;
|
||||
signal output nullifierHash;
|
||||
|
||||
component commitmentHasher = Pedersen(496);
|
||||
component nullifierHasher = Pedersen(248);
|
||||
component nullifierBits = Num2Bits(248);
|
||||
component secretBits = Num2Bits(248);
|
||||
nullifierBits.in <== nullifier;
|
||||
secretBits.in <== secret;
|
||||
for (var i = 0; i < 248; i++) {
|
||||
nullifierHasher.in[i] <== nullifierBits.out[i];
|
||||
commitmentHasher.in[i] <== nullifierBits.out[i];
|
||||
commitmentHasher.in[i + 248] <== secretBits.out[i];
|
||||
}
|
||||
|
||||
commitment <== commitmentHasher.out[0];
|
||||
nullifierHash <== nullifierHasher.out[0];
|
||||
}
|
||||
|
||||
// Verifies that commitment that corresponds to given secret and nullifier is included in the merkle tree of deposits
|
||||
template Withdraw(levels) {
|
||||
signal input root;
|
||||
signal input nullifierHash;
|
||||
signal input recipient; // not taking part in any computations
|
||||
signal input relayer; // not taking part in any computations
|
||||
signal input fee; // not taking part in any computations
|
||||
signal input refund; // not taking part in any computations
|
||||
signal input nullifier;
|
||||
signal input secret;
|
||||
signal input pathElements[levels];
|
||||
signal input pathIndices[levels];
|
||||
|
||||
component hasher = CommitmentHasher();
|
||||
hasher.nullifier <== nullifier;
|
||||
hasher.secret <== secret;
|
||||
hasher.nullifierHash === nullifierHash;
|
||||
|
||||
component tree = MerkleTreeChecker(levels);
|
||||
tree.leaf <== hasher.commitment;
|
||||
tree.root <== root;
|
||||
for (var i = 0; i < levels; i++) {
|
||||
tree.pathElements[i] <== pathElements[i];
|
||||
tree.pathIndices[i] <== pathIndices[i];
|
||||
}
|
||||
|
||||
// Add hidden signals to make sure that tampering with recipient or fee will invalidate the snark proof
|
||||
// Most likely it is not required, but it's better to stay on the safe side and it only takes 2 constraints
|
||||
// Squares are used to prevent optimizer from removing those constraints
|
||||
signal recipientSquare;
|
||||
signal feeSquare;
|
||||
signal relayerSquare;
|
||||
signal refundSquare;
|
||||
recipientSquare <== recipient * recipient;
|
||||
feeSquare <== fee * fee;
|
||||
relayerSquare <== relayer * relayer;
|
||||
refundSquare <== refund * refund;
|
||||
}
|
||||
|
||||
component main = Withdraw(20);
|
||||
@@ -62,10 +62,6 @@ git-tree-sha1 = "44c37b4636bc54afac5c574d2d02b625349d6582"
|
||||
uuid = "34da2185-b29b-5c13-b0c7-acf172513d20"
|
||||
version = "3.41.0"
|
||||
|
||||
[[CompilerSupportLibraries_jll]]
|
||||
deps = ["Artifacts", "Libdl"]
|
||||
uuid = "e66e0078-7015-5450-92f7-15fbd957f2ae"
|
||||
|
||||
[[DataAPI]]
|
||||
git-tree-sha1 = "cc70b17275652eb47bc9e5f81635981f13cea5c8"
|
||||
uuid = "9a962f9c-6df0-11e9-0e5d-c546b8b5ee8a"
|
||||
@@ -128,30 +124,12 @@ uuid = "9fa8497b-333b-5362-9e8d-4d0656e87820"
|
||||
deps = ["Artifacts", "Libdl"]
|
||||
uuid = "781609d7-10c4-51f6-84f2-b8444358ff6d"
|
||||
|
||||
[[Genie]]
|
||||
deps = ["ArgParse", "Dates", "Distributed", "EzXML", "FilePathsBase", "HTTP", "HttpCommon", "Inflector", "JSON3", "Logging", "Markdown", "MbedTLS", "Millboard", "Nettle", "OrderedCollections", "Pkg", "REPL", "Reexport", "Revise", "SHA", "Serialization", "Sockets", "UUIDs", "Unicode", "YAML"]
|
||||
git-tree-sha1 = "0c3fca7f8ea58b7ef852646d14e5ff99e653e018"
|
||||
uuid = "c43c736e-a2d1-11e8-161f-af95117fbd1e"
|
||||
version = "3.0.0"
|
||||
|
||||
[[GroupsCore]]
|
||||
deps = ["Markdown", "Random"]
|
||||
git-tree-sha1 = "9e1a5e9f3b81ad6a5c613d181664a0efc6fe6dd7"
|
||||
uuid = "d5909c97-4eac-4ecc-a3dc-fdd0858a4120"
|
||||
version = "0.4.0"
|
||||
|
||||
[[HTTP]]
|
||||
deps = ["Base64", "Dates", "IniFile", "Logging", "MbedTLS", "NetworkOptions", "Sockets", "URIs"]
|
||||
git-tree-sha1 = "0fa77022fe4b511826b39c894c90daf5fce3334a"
|
||||
uuid = "cd3eb016-35fb-5094-929b-558a96fad6f3"
|
||||
version = "0.9.17"
|
||||
|
||||
[[HttpCommon]]
|
||||
deps = ["Dates", "Nullables", "Test", "URIParser"]
|
||||
git-tree-sha1 = "46313284237aa6ca67a6bce6d6fbd323d19cff59"
|
||||
uuid = "77172c1b-203f-54ac-aa54-3f1198fe9f90"
|
||||
version = "0.5.0"
|
||||
|
||||
[[Inflector]]
|
||||
deps = ["Unicode"]
|
||||
git-tree-sha1 = "8555b54ddf27806b070ce1d1cf623e1feb13750c"
|
||||
@@ -234,7 +212,7 @@ uuid = "94ce4f54-9a6c-5748-9c1c-f9c7231a4531"
|
||||
version = "1.16.1+1"
|
||||
|
||||
[[LinearAlgebra]]
|
||||
deps = ["Libdl", "libblastrampoline_jll"]
|
||||
deps = ["Libdl"]
|
||||
uuid = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
|
||||
|
||||
[[Logging]]
|
||||
@@ -298,15 +276,6 @@ version = "3.7.2+0"
|
||||
[[NetworkOptions]]
|
||||
uuid = "ca575930-c2e3-43a9-ace4-1e988b2c1908"
|
||||
|
||||
[[Nullables]]
|
||||
git-tree-sha1 = "8f87854cc8f3685a60689d8edecaa29d2251979b"
|
||||
uuid = "4d1e1d77-625e-5b40-9113-a560ec7a8ecd"
|
||||
version = "1.0.0"
|
||||
|
||||
[[OpenBLAS_jll]]
|
||||
deps = ["Artifacts", "CompilerSupportLibraries_jll", "Libdl"]
|
||||
uuid = "4536629a-c528-5b80-bd46-f80d51c5b363"
|
||||
|
||||
[[OrderedCollections]]
|
||||
git-tree-sha1 = "85f8e6578bf1f9ee0d11e7bb1b1456435479d47c"
|
||||
uuid = "bac558e1-5e72-5ebc-8fee-abe8a469f55d"
|
||||
@@ -365,7 +334,7 @@ deps = ["InteractiveUtils", "Markdown", "Sockets", "Unicode"]
|
||||
uuid = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb"
|
||||
|
||||
[[Random]]
|
||||
deps = ["SHA", "Serialization"]
|
||||
deps = ["Serialization"]
|
||||
uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
|
||||
|
||||
[[RandomExtensions]]
|
||||
@@ -521,10 +490,6 @@ version = "0.4.7"
|
||||
deps = ["Libdl"]
|
||||
uuid = "83775a58-1f1d-513f-b197-d71354ab007a"
|
||||
|
||||
[[libblastrampoline_jll]]
|
||||
deps = ["Artifacts", "Libdl", "OpenBLAS_jll"]
|
||||
uuid = "8e850b90-86db-534c-a0d3-1478176c7d93"
|
||||
|
||||
[[nghttp2_jll]]
|
||||
deps = ["Artifacts", "Libdl"]
|
||||
uuid = "8e850ede-7688-5339-a07c-302acd2aaf8d"
|
||||
|
||||
@@ -11,7 +11,6 @@ CSV = "336ed68f-0bac-5ca0-87d4-7b16caf5d00b"
|
||||
Combinatorics = "861a8166-3701-5b0c-9a16-15d98fcdc6aa"
|
||||
DataStructures = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8"
|
||||
Dates = "ade2ca70-3891-5945-98fb-dc099432e06a"
|
||||
Genie = "c43c736e-a2d1-11e8-161f-af95117fbd1e"
|
||||
JSON = "682c06a0-de6a-54ab-a142-c8b1cf79cde6"
|
||||
JuliaFormatter = "98e50ef6-434e-11e9-1051-2b60c6c9e899"
|
||||
PkgTemplates = "14b8a8f1-9102-5b29-a752-f990bacb7fe1"
|
||||
|
||||
16
bad_bd_check.circom
Normal file
16
bad_bd_check.circom
Normal file
@@ -0,0 +1,16 @@
|
||||
pragma circom 2.0.0;
|
||||
|
||||
template Num2Bits(){
|
||||
signal input x;
|
||||
signal output b0;
|
||||
signal output b1;
|
||||
signal output b2;
|
||||
b0 <-- x & 1;
|
||||
b1 <-- (x >> 1) & 1;
|
||||
b2 <-- (x >> 2) & 1;
|
||||
2 * b0 + b1 === x;
|
||||
b1 * (b1 - 1) === 0;
|
||||
b2 * (b2 - 1) === 0;
|
||||
}
|
||||
|
||||
component main = Num2Bits();
|
||||
BIN
bad_bd_check.r1cs
Normal file
BIN
bad_bd_check.r1cs
Normal file
Binary file not shown.
4
bad_bd_check.sym
Normal file
4
bad_bd_check.sym
Normal file
@@ -0,0 +1,4 @@
|
||||
1,1,0,main.b0
|
||||
2,2,0,main.b1
|
||||
3,3,0,main.b2
|
||||
4,4,0,main.x
|
||||
BIN
bigmult86_3.r1cs
BIN
bigmult86_3.r1cs
Binary file not shown.
BIN
bigmultmodp86_3.r1cs
Normal file
BIN
bigmultmodp86_3.r1cs
Normal file
Binary file not shown.
BIN
bigmultshortlong86_3.r1cs
Normal file
BIN
bigmultshortlong86_3.r1cs
Normal file
Binary file not shown.
2837
ecne_circomlib_tests/Bits2Point_strict@pointbits.sym
Normal file
2837
ecne_circomlib_tests/Bits2Point_strict@pointbits.sym
Normal file
File diff suppressed because it is too large
Load Diff
1283
ecne_circomlib_tests/Num2Bits_strict@bitify.sym
Normal file
1283
ecne_circomlib_tests/Num2Bits_strict@bitify.sym
Normal file
File diff suppressed because it is too large
Load Diff
258
ecne_circomlib_tests/Point2Bits@pointbits.sym
Normal file
258
ecne_circomlib_tests/Point2Bits@pointbits.sym
Normal file
@@ -0,0 +1,258 @@
|
||||
1,1,0,main.out[0]
|
||||
2,2,0,main.out[1]
|
||||
3,3,0,main.out[2]
|
||||
4,4,0,main.out[3]
|
||||
5,5,0,main.out[4]
|
||||
6,6,0,main.out[5]
|
||||
7,7,0,main.out[6]
|
||||
8,8,0,main.out[7]
|
||||
9,9,0,main.out[8]
|
||||
10,10,0,main.out[9]
|
||||
11,11,0,main.out[10]
|
||||
12,12,0,main.out[11]
|
||||
13,13,0,main.out[12]
|
||||
14,14,0,main.out[13]
|
||||
15,15,0,main.out[14]
|
||||
16,16,0,main.out[15]
|
||||
17,17,0,main.out[16]
|
||||
18,18,0,main.out[17]
|
||||
19,19,0,main.out[18]
|
||||
20,20,0,main.out[19]
|
||||
21,21,0,main.out[20]
|
||||
22,22,0,main.out[21]
|
||||
23,23,0,main.out[22]
|
||||
24,24,0,main.out[23]
|
||||
25,25,0,main.out[24]
|
||||
26,26,0,main.out[25]
|
||||
27,27,0,main.out[26]
|
||||
28,28,0,main.out[27]
|
||||
29,29,0,main.out[28]
|
||||
30,30,0,main.out[29]
|
||||
31,31,0,main.out[30]
|
||||
32,32,0,main.out[31]
|
||||
33,33,0,main.out[32]
|
||||
34,34,0,main.out[33]
|
||||
35,35,0,main.out[34]
|
||||
36,36,0,main.out[35]
|
||||
37,37,0,main.out[36]
|
||||
38,38,0,main.out[37]
|
||||
39,39,0,main.out[38]
|
||||
40,40,0,main.out[39]
|
||||
41,41,0,main.out[40]
|
||||
42,42,0,main.out[41]
|
||||
43,43,0,main.out[42]
|
||||
44,44,0,main.out[43]
|
||||
45,45,0,main.out[44]
|
||||
46,46,0,main.out[45]
|
||||
47,47,0,main.out[46]
|
||||
48,48,0,main.out[47]
|
||||
49,49,0,main.out[48]
|
||||
50,50,0,main.out[49]
|
||||
51,51,0,main.out[50]
|
||||
52,52,0,main.out[51]
|
||||
53,53,0,main.out[52]
|
||||
54,54,0,main.out[53]
|
||||
55,55,0,main.out[54]
|
||||
56,56,0,main.out[55]
|
||||
57,57,0,main.out[56]
|
||||
58,58,0,main.out[57]
|
||||
59,59,0,main.out[58]
|
||||
60,60,0,main.out[59]
|
||||
61,61,0,main.out[60]
|
||||
62,62,0,main.out[61]
|
||||
63,63,0,main.out[62]
|
||||
64,64,0,main.out[63]
|
||||
65,65,0,main.out[64]
|
||||
66,66,0,main.out[65]
|
||||
67,67,0,main.out[66]
|
||||
68,68,0,main.out[67]
|
||||
69,69,0,main.out[68]
|
||||
70,70,0,main.out[69]
|
||||
71,71,0,main.out[70]
|
||||
72,72,0,main.out[71]
|
||||
73,73,0,main.out[72]
|
||||
74,74,0,main.out[73]
|
||||
75,75,0,main.out[74]
|
||||
76,76,0,main.out[75]
|
||||
77,77,0,main.out[76]
|
||||
78,78,0,main.out[77]
|
||||
79,79,0,main.out[78]
|
||||
80,80,0,main.out[79]
|
||||
81,81,0,main.out[80]
|
||||
82,82,0,main.out[81]
|
||||
83,83,0,main.out[82]
|
||||
84,84,0,main.out[83]
|
||||
85,85,0,main.out[84]
|
||||
86,86,0,main.out[85]
|
||||
87,87,0,main.out[86]
|
||||
88,88,0,main.out[87]
|
||||
89,89,0,main.out[88]
|
||||
90,90,0,main.out[89]
|
||||
91,91,0,main.out[90]
|
||||
92,92,0,main.out[91]
|
||||
93,93,0,main.out[92]
|
||||
94,94,0,main.out[93]
|
||||
95,95,0,main.out[94]
|
||||
96,96,0,main.out[95]
|
||||
97,97,0,main.out[96]
|
||||
98,98,0,main.out[97]
|
||||
99,99,0,main.out[98]
|
||||
100,100,0,main.out[99]
|
||||
101,101,0,main.out[100]
|
||||
102,102,0,main.out[101]
|
||||
103,103,0,main.out[102]
|
||||
104,104,0,main.out[103]
|
||||
105,105,0,main.out[104]
|
||||
106,106,0,main.out[105]
|
||||
107,107,0,main.out[106]
|
||||
108,108,0,main.out[107]
|
||||
109,109,0,main.out[108]
|
||||
110,110,0,main.out[109]
|
||||
111,111,0,main.out[110]
|
||||
112,112,0,main.out[111]
|
||||
113,113,0,main.out[112]
|
||||
114,114,0,main.out[113]
|
||||
115,115,0,main.out[114]
|
||||
116,116,0,main.out[115]
|
||||
117,117,0,main.out[116]
|
||||
118,118,0,main.out[117]
|
||||
119,119,0,main.out[118]
|
||||
120,120,0,main.out[119]
|
||||
121,121,0,main.out[120]
|
||||
122,122,0,main.out[121]
|
||||
123,123,0,main.out[122]
|
||||
124,124,0,main.out[123]
|
||||
125,125,0,main.out[124]
|
||||
126,126,0,main.out[125]
|
||||
127,127,0,main.out[126]
|
||||
128,128,0,main.out[127]
|
||||
129,129,0,main.out[128]
|
||||
130,130,0,main.out[129]
|
||||
131,131,0,main.out[130]
|
||||
132,132,0,main.out[131]
|
||||
133,133,0,main.out[132]
|
||||
134,134,0,main.out[133]
|
||||
135,135,0,main.out[134]
|
||||
136,136,0,main.out[135]
|
||||
137,137,0,main.out[136]
|
||||
138,138,0,main.out[137]
|
||||
139,139,0,main.out[138]
|
||||
140,140,0,main.out[139]
|
||||
141,141,0,main.out[140]
|
||||
142,142,0,main.out[141]
|
||||
143,143,0,main.out[142]
|
||||
144,144,0,main.out[143]
|
||||
145,145,0,main.out[144]
|
||||
146,146,0,main.out[145]
|
||||
147,147,0,main.out[146]
|
||||
148,148,0,main.out[147]
|
||||
149,149,0,main.out[148]
|
||||
150,150,0,main.out[149]
|
||||
151,151,0,main.out[150]
|
||||
152,152,0,main.out[151]
|
||||
153,153,0,main.out[152]
|
||||
154,154,0,main.out[153]
|
||||
155,155,0,main.out[154]
|
||||
156,156,0,main.out[155]
|
||||
157,157,0,main.out[156]
|
||||
158,158,0,main.out[157]
|
||||
159,159,0,main.out[158]
|
||||
160,160,0,main.out[159]
|
||||
161,161,0,main.out[160]
|
||||
162,162,0,main.out[161]
|
||||
163,163,0,main.out[162]
|
||||
164,164,0,main.out[163]
|
||||
165,165,0,main.out[164]
|
||||
166,166,0,main.out[165]
|
||||
167,167,0,main.out[166]
|
||||
168,168,0,main.out[167]
|
||||
169,169,0,main.out[168]
|
||||
170,170,0,main.out[169]
|
||||
171,171,0,main.out[170]
|
||||
172,172,0,main.out[171]
|
||||
173,173,0,main.out[172]
|
||||
174,174,0,main.out[173]
|
||||
175,175,0,main.out[174]
|
||||
176,176,0,main.out[175]
|
||||
177,177,0,main.out[176]
|
||||
178,178,0,main.out[177]
|
||||
179,179,0,main.out[178]
|
||||
180,180,0,main.out[179]
|
||||
181,181,0,main.out[180]
|
||||
182,182,0,main.out[181]
|
||||
183,183,0,main.out[182]
|
||||
184,184,0,main.out[183]
|
||||
185,185,0,main.out[184]
|
||||
186,186,0,main.out[185]
|
||||
187,187,0,main.out[186]
|
||||
188,188,0,main.out[187]
|
||||
189,189,0,main.out[188]
|
||||
190,190,0,main.out[189]
|
||||
191,191,0,main.out[190]
|
||||
192,192,0,main.out[191]
|
||||
193,193,0,main.out[192]
|
||||
194,194,0,main.out[193]
|
||||
195,195,0,main.out[194]
|
||||
196,196,0,main.out[195]
|
||||
197,197,0,main.out[196]
|
||||
198,198,0,main.out[197]
|
||||
199,199,0,main.out[198]
|
||||
200,200,0,main.out[199]
|
||||
201,201,0,main.out[200]
|
||||
202,202,0,main.out[201]
|
||||
203,203,0,main.out[202]
|
||||
204,204,0,main.out[203]
|
||||
205,205,0,main.out[204]
|
||||
206,206,0,main.out[205]
|
||||
207,207,0,main.out[206]
|
||||
208,208,0,main.out[207]
|
||||
209,209,0,main.out[208]
|
||||
210,210,0,main.out[209]
|
||||
211,211,0,main.out[210]
|
||||
212,212,0,main.out[211]
|
||||
213,213,0,main.out[212]
|
||||
214,214,0,main.out[213]
|
||||
215,215,0,main.out[214]
|
||||
216,216,0,main.out[215]
|
||||
217,217,0,main.out[216]
|
||||
218,218,0,main.out[217]
|
||||
219,219,0,main.out[218]
|
||||
220,220,0,main.out[219]
|
||||
221,221,0,main.out[220]
|
||||
222,222,0,main.out[221]
|
||||
223,223,0,main.out[222]
|
||||
224,224,0,main.out[223]
|
||||
225,225,0,main.out[224]
|
||||
226,226,0,main.out[225]
|
||||
227,227,0,main.out[226]
|
||||
228,228,0,main.out[227]
|
||||
229,229,0,main.out[228]
|
||||
230,230,0,main.out[229]
|
||||
231,231,0,main.out[230]
|
||||
232,232,0,main.out[231]
|
||||
233,233,0,main.out[232]
|
||||
234,234,0,main.out[233]
|
||||
235,235,0,main.out[234]
|
||||
236,236,0,main.out[235]
|
||||
237,237,0,main.out[236]
|
||||
238,238,0,main.out[237]
|
||||
239,239,0,main.out[238]
|
||||
240,240,0,main.out[239]
|
||||
241,241,0,main.out[240]
|
||||
242,242,0,main.out[241]
|
||||
243,243,0,main.out[242]
|
||||
244,244,0,main.out[243]
|
||||
245,245,0,main.out[244]
|
||||
246,246,0,main.out[245]
|
||||
247,247,0,main.out[246]
|
||||
248,248,0,main.out[247]
|
||||
249,249,0,main.out[248]
|
||||
250,250,0,main.out[249]
|
||||
251,251,0,main.out[250]
|
||||
252,252,0,main.out[251]
|
||||
253,253,0,main.out[252]
|
||||
254,254,0,main.out[253]
|
||||
255,255,0,main.out[254]
|
||||
256,256,0,main.out[255]
|
||||
257,257,0,main.in[0]
|
||||
258,258,0,main.in[1]
|
||||
2833
ecne_circomlib_tests/Point2Bits_Strict@pointbits.sym
Normal file
2833
ecne_circomlib_tests/Point2Bits_Strict@pointbits.sym
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,6 +1,6 @@
|
||||
using Dates
|
||||
import R1CSConstraintSolver: solveWithTrustedFunctions
|
||||
|
||||
solveWithTrustedFunctions("bad_bd_check.r1cs", "Bad Bound Check", input_sym="bad_bd_check.sym", debug=true, printRes=true)
|
||||
solveWithTrustedFunctions("bad_bd_check.r1cs", "Bad Bound Check", input_sym="bad_bd_check.sym", debug=false, printRes=true)
|
||||
|
||||
solveWithTrustedFunctions("good_bd_check.r1cs", "Good Bound Check", input_sym="good_bd_check.sym", debug=true, printRes=true)
|
||||
solveWithTrustedFunctions("good_bd_check.r1cs", "Good Bound Check", input_sym="good_bd_check.sym", debug=false, printRes=true)
|
||||
14
good_bd_check.circom
Normal file
14
good_bd_check.circom
Normal file
@@ -0,0 +1,14 @@
|
||||
pragma circom 2.0.0;
|
||||
|
||||
template Num2Bits(){
|
||||
signal input x;
|
||||
signal output b0;
|
||||
signal output b1;
|
||||
b0 <-- x & 1;
|
||||
b1 <-- (x >> 1) & 1;
|
||||
2 * b0 + b1 === x;
|
||||
b0 * (b0 - 1) === 0;
|
||||
b1 * (b1 - 1) === 0;
|
||||
}
|
||||
|
||||
component main = Num2Bits();
|
||||
BIN
good_bd_check.r1cs
Normal file
BIN
good_bd_check.r1cs
Normal file
Binary file not shown.
3
good_bd_check.sym
Normal file
3
good_bd_check.sym
Normal file
@@ -0,0 +1,3 @@
|
||||
1,1,0,main.b0
|
||||
2,2,0,main.b1
|
||||
3,3,0,main.x
|
||||
@@ -23,6 +23,437 @@ const bjj_p =
|
||||
|
||||
F = AbstractAlgebra.GF(bjj_p)
|
||||
|
||||
function nonzeroKeys(lin_term::DefaultDict{Base.Int64,AbstractAlgebra.GFElem{BigInt}})
|
||||
nzero = Set()
|
||||
for i in keys(lin_term)
|
||||
if lin_term[i] != F(0)
|
||||
push!(nzero, i)
|
||||
end
|
||||
end
|
||||
return nzero
|
||||
end
|
||||
|
||||
function getVariables(equation::R1CSEquation)
|
||||
s = Set()
|
||||
for i in keys(equation.a)
|
||||
if equation.a[i] != F(0)
|
||||
push!(s, i)
|
||||
end
|
||||
end
|
||||
|
||||
for i in keys(equation.b)
|
||||
if equation.b[i] != F(0)
|
||||
push!(s, i)
|
||||
end
|
||||
end
|
||||
|
||||
for i in keys(equation.c)
|
||||
if equation.c[i] != F(0)
|
||||
push!(s, i)
|
||||
end
|
||||
end
|
||||
return s
|
||||
end
|
||||
|
||||
function squareRoot(
|
||||
field::AbstractAlgebra.GFField{BigInt},
|
||||
a::AbstractAlgebra.GFElem{BigInt},
|
||||
)::AbstractAlgebra.GFElem{BigInt}
|
||||
if a == 0
|
||||
return 0
|
||||
end
|
||||
m = bjj_p
|
||||
e = 0
|
||||
q = m - 1
|
||||
while (q % 2 == 0)
|
||||
e += 1
|
||||
q = div(q, 2)
|
||||
end
|
||||
pow2 = 2^(e - 1)
|
||||
z = 1
|
||||
while true
|
||||
x = field(rand(1:m-1))
|
||||
z = x^q
|
||||
if z^pow2 != field(1) # found QNR
|
||||
break
|
||||
end
|
||||
end
|
||||
y = z
|
||||
r = e
|
||||
x = a^(div(q - 1, 2))
|
||||
v = a * x
|
||||
w = v * x
|
||||
while (w != 1)
|
||||
k = 0
|
||||
temp_w = w
|
||||
while true
|
||||
temp_w *= temp_w
|
||||
k += 1
|
||||
if temp_w == 1
|
||||
break
|
||||
end
|
||||
end
|
||||
d = y^(2^(r - k - 1))
|
||||
y = d * d
|
||||
r = k
|
||||
v = d * v
|
||||
w = w * y
|
||||
end
|
||||
return v
|
||||
end
|
||||
|
||||
function solveQuadratic(
|
||||
field::AbstractAlgebra.GFField{BigInt},
|
||||
a::AbstractAlgebra.GFElem{BigInt},
|
||||
b::AbstractAlgebra.GFElem{BigInt},
|
||||
c::AbstractAlgebra.GFElem{BigInt},
|
||||
)
|
||||
if a == 0
|
||||
if b == 0
|
||||
if c == 0
|
||||
return "YES"
|
||||
else
|
||||
return "NO"
|
||||
end
|
||||
else
|
||||
return [AbstractAlgebra.divexact(-c, b)]
|
||||
end
|
||||
else
|
||||
disc = b * b - field(4) * a * c
|
||||
rt = squareRoot(field, disc)
|
||||
if rt != 0
|
||||
return [
|
||||
AbstractAlgebra.divexact(-b + disc, field(2) * a),
|
||||
AbstractAlgebra.divexact(-b - disc, field(2) * a),
|
||||
]
|
||||
else
|
||||
return [AbstractAlgebra.divexact(-b, field(2) * a)]
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
mutable struct VariableState # This represents all the information known about variables.
|
||||
index::Base.Int64
|
||||
is_known::Bool # have nonzero-information
|
||||
unique::Bool # we know the value for sure
|
||||
values::Vector{AbstractAlgebra.GFElem{BigInt}} # A list of potential values that this variable can take.
|
||||
lb::AbstractAlgebra.GFElem{BigInt}
|
||||
ub::AbstractAlgebra.GFElem{BigInt}
|
||||
bounds_negative::Bool
|
||||
abz::Base.Int64
|
||||
VariableState(a::Base.Int64) = begin
|
||||
new(a, false, false, [], F(0), F(-1), false, -1)
|
||||
end
|
||||
|
||||
VariableState(
|
||||
a::Base.Int64,
|
||||
is_known::Bool,
|
||||
unique::Bool,
|
||||
values::Vector{AbstractAlgebra.GFElem{BigInt}},
|
||||
lb::AbstractAlgebra.GFElem{BigInt},
|
||||
ub::AbstractAlgebra.GFElem{BigInt},
|
||||
bounds_negative::Bool,
|
||||
abz::Base.Int64,
|
||||
) = begin
|
||||
new(a, is_known, unique, values, lb, ub, bounds_negative, -1)
|
||||
end
|
||||
end
|
||||
|
||||
begin
|
||||
function make_unique(a::VariableState)
|
||||
return VariableState(
|
||||
a.index,
|
||||
true,
|
||||
true,
|
||||
a.values,
|
||||
a.lb,
|
||||
a.ub,
|
||||
a.bounds_negative,
|
||||
a.abz,
|
||||
)
|
||||
end
|
||||
|
||||
function make_values(
|
||||
a::VariableState,
|
||||
new_values::Vector{AbstractAlgebra.GFElem{BigInt}},
|
||||
)
|
||||
return VariableState(
|
||||
a.index,
|
||||
true,
|
||||
a.unique,
|
||||
new_values,
|
||||
a.lb,
|
||||
a.ub,
|
||||
a.bounds_negative,
|
||||
a.abz,
|
||||
)
|
||||
end
|
||||
|
||||
function make_bounds(
|
||||
a::VariableState,
|
||||
lb::AbstractAlgebra.GFElem{BigInt},
|
||||
ub::AbstractAlgebra.GFElem{BigInt},
|
||||
neg_bounds::Bool=false,
|
||||
)
|
||||
# lies between lb and ub
|
||||
return VariableState(a.index, true, a.unique, a.values, lb, ub, neg_bounds, a.abz)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
# check if these two dictionaries have the same multiset of values
|
||||
function checkNonZeroValues(
|
||||
map1::DefaultDict{Base.Int64,AbstractAlgebra.GFElem{BigInt}},
|
||||
map2::DefaultDict{Base.Int64,AbstractAlgebra.GFElem{BigInt}},
|
||||
)
|
||||
x1 = counter(values(map1))
|
||||
x2 = counter(values(map2))
|
||||
for ele in keys(x1)
|
||||
if ele != F(0)
|
||||
if x1[ele] != x2[ele]
|
||||
return false
|
||||
end
|
||||
end
|
||||
end
|
||||
for ele in keys(x2)
|
||||
if ele != F(0)
|
||||
if x1[ele] != x2[ele]
|
||||
return false
|
||||
end
|
||||
end
|
||||
end
|
||||
return true
|
||||
end
|
||||
|
||||
function hash_r1cs_equation(
|
||||
e::R1CSEquation
|
||||
)
|
||||
l = vcat(sort!([x.d for x in values(e.a)]), sort!([x.d for x in values(e.b)]), sort!([x.d for x in values(e.c)]))
|
||||
l = [x for x in l if x != 0]
|
||||
|
||||
return hash(l)
|
||||
end
|
||||
|
||||
function abstraction(
|
||||
function_name::String,
|
||||
constraints::Array{R1CSEquation},
|
||||
known_inputs::Array{Base.Int64},
|
||||
sub_equation::Array{R1CSEquation},
|
||||
known_outputs::Array{Base.Int64},
|
||||
printRes::Bool=false,
|
||||
)
|
||||
if printRes
|
||||
println("known inputs", known_inputs)
|
||||
println("called abstraction")
|
||||
println("big #: ", length(constraints))
|
||||
println("small #: ", length(sub_equation))
|
||||
end
|
||||
a = time()
|
||||
hashed_constraints = [hash_r1cs_equation(x) for x in constraints]
|
||||
hashed_sub_equation = [hash_r1cs_equation(x) for x in sub_equation]
|
||||
f = time()
|
||||
if printRes
|
||||
println("compute hash ", f - a)
|
||||
end
|
||||
candidates = []
|
||||
for i in 1:length(constraints)-length(sub_equation)+1
|
||||
matches = true
|
||||
for j in 1:length(sub_equation)-1
|
||||
if hashed_constraints[i+j-1] != hashed_sub_equation[j]
|
||||
matches = false
|
||||
break
|
||||
end
|
||||
end
|
||||
if matches
|
||||
push!(candidates, i)
|
||||
end
|
||||
end
|
||||
b = time()
|
||||
if printRes
|
||||
println("hash match ", b - f)
|
||||
end
|
||||
matches = [] # contains index, as well as (orig_var -> new_var maps)
|
||||
appearance_map_orig = DefaultDict{
|
||||
Base.Int64,
|
||||
Vector{Tuple{Base.Int64,AbstractAlgebra.GFElem{BigInt}}},
|
||||
}(Vector{Tuple{Base.Int64,AbstractAlgebra.GFElem{BigInt}}})
|
||||
sub_eq_counter = 1
|
||||
# one can also do this witha a Rabin-Karp Hash.
|
||||
for j = 1:length(sub_equation)
|
||||
for eq in [sub_equation[j].a, sub_equation[j].b, sub_equation[j].c]
|
||||
for term in eq
|
||||
if term[2] != F(0)
|
||||
tup = (sub_eq_counter, F(term[2]))
|
||||
push!(appearance_map_orig[term[1]], tup)
|
||||
end
|
||||
end
|
||||
sub_eq_counter += 1
|
||||
end
|
||||
end
|
||||
for i in candidates
|
||||
# try each of the things that the hash matches.
|
||||
works = true
|
||||
appearance_map_cur = DefaultDict{
|
||||
Base.Int64,
|
||||
Vector{Tuple{Base.Int64,AbstractAlgebra.GFElem{BigInt}}},
|
||||
}(Vector{Tuple{Base.Int64,AbstractAlgebra.GFElem{BigInt}}})
|
||||
app_counter = 0
|
||||
function addEquation(eq1, eq2)
|
||||
if !checkNonZeroValues(eq1, eq2)
|
||||
return false
|
||||
end
|
||||
for term in eq1
|
||||
if term[2] != F(0)
|
||||
tup = (app_counter, F(term[2]))
|
||||
push!(appearance_map_cur[term[1]], tup)
|
||||
end
|
||||
end
|
||||
return true
|
||||
end
|
||||
for j = 1:length(sub_equation)
|
||||
app_counter += 1
|
||||
if !addEquation(constraints[i+j-1].a, sub_equation[j].a)
|
||||
works = false
|
||||
break
|
||||
end
|
||||
app_counter += 1
|
||||
if !addEquation(constraints[i+j-1].b, sub_equation[j].b)
|
||||
works = false
|
||||
break
|
||||
end
|
||||
app_counter += 1
|
||||
if !addEquation(constraints[i+j-1].c, sub_equation[j].c)
|
||||
works = false
|
||||
break
|
||||
end
|
||||
end
|
||||
if !works
|
||||
continue
|
||||
end
|
||||
|
||||
l1 = sort(collect(appearance_map_cur), by=x -> [(y[1], y[2].d) for y in x[2]])
|
||||
l2 = sort(collect(appearance_map_orig), by=x -> [(y[1], y[2].d) for y in x[2]])
|
||||
if length(l1) != length(l2)
|
||||
continue
|
||||
else
|
||||
works = true
|
||||
for i = 1:length(l1)
|
||||
if l1[i][2] != l2[i][2]
|
||||
works = false
|
||||
break
|
||||
end
|
||||
end
|
||||
if !works
|
||||
continue
|
||||
end
|
||||
end
|
||||
# first appearances check
|
||||
push!(matches, (i, Dict(l2[x][1] => l1[x][1] for x = 1:length(l1))))
|
||||
end
|
||||
c = time()
|
||||
if printRes
|
||||
println("found matches ", c - b)
|
||||
end
|
||||
red_cons = []
|
||||
special_cons = []
|
||||
cur_idx = 1
|
||||
i = 1
|
||||
total_vars = maximum([
|
||||
maximum([
|
||||
maximum(keys(constraints[i].a)),
|
||||
maximum(keys(constraints[i].b)),
|
||||
maximum(keys(constraints[i].c)),
|
||||
]) for i = 1:length(constraints)
|
||||
])
|
||||
while i <= length(constraints)
|
||||
#println(i)
|
||||
if ((cur_idx > length(matches)) || (i != matches[cur_idx][1]))
|
||||
push!(red_cons, constraints[i])
|
||||
i += 1
|
||||
else
|
||||
# the transformed inputs / outputs under matches[cur_idx][2].
|
||||
#println("known inputs", known_inputs)
|
||||
#println("known outputs", known_outputs)
|
||||
push!(
|
||||
special_cons,
|
||||
(
|
||||
function_name,
|
||||
[matches[cur_idx][2][x] for x in known_inputs if x != 1],
|
||||
[matches[cur_idx][2][x] for x in known_outputs],
|
||||
),
|
||||
)
|
||||
i += length(sub_equation)
|
||||
cur_idx += 1
|
||||
end
|
||||
end
|
||||
d = time()
|
||||
if printRes
|
||||
println("solved question ", d - c)
|
||||
println("abstractions found ", length(special_cons))
|
||||
end
|
||||
return (special_cons), Array{R1CSEquation}(red_cons)
|
||||
end
|
||||
|
||||
function printState(x::VariableState)
|
||||
bounds = [x.lb.d, x.ub.d]
|
||||
if bounds[1] == 0 && bounds[2] == 21888242871839275222246405745257275088548364400416034343698204186575808495616
|
||||
bounds = []
|
||||
end
|
||||
println(
|
||||
"Uniquely Determined: ",
|
||||
x.unique)
|
||||
|
||||
if bounds == []
|
||||
println("Bounds: None")
|
||||
else
|
||||
println("Bounds: [", bounds[1], ", ", bounds[2], "]")
|
||||
end
|
||||
if x.values != []
|
||||
println(
|
||||
"All possible values: ",
|
||||
sort!([val.d for val in x.values])
|
||||
)
|
||||
end
|
||||
println()
|
||||
|
||||
end
|
||||
|
||||
function fix_number(x::BigInt)
|
||||
if x > 21888242871839275222246405745257275088548363400416034343698204186575808495517
|
||||
return x -
|
||||
21888242871839275222246405745257275088548364400416034343698204186575808495617
|
||||
else
|
||||
return x
|
||||
end
|
||||
end
|
||||
|
||||
# a utility for pretty printing equations
|
||||
function printEquation(x::R1CSEquation, index_to_signal::Array{String,1})
|
||||
function get_lin(x)
|
||||
if length(nonzeroKeys(x)) == 0
|
||||
return "0"
|
||||
end
|
||||
function fix_signal(key)
|
||||
if key > 0
|
||||
return index_to_signal[key]
|
||||
else
|
||||
return 1
|
||||
end
|
||||
end
|
||||
return "(" *
|
||||
join(
|
||||
[
|
||||
string(fix_number(x[key].d)) * " * " * string(fix_signal(key - 1)) * ""
|
||||
for key in nonzeroKeys(x)
|
||||
],
|
||||
" + ",
|
||||
) * ")"
|
||||
end
|
||||
str1 = get_lin(x.a)
|
||||
str2 = get_lin(x.b)
|
||||
str3 = get_lin(x.c)
|
||||
println(str1 * " * " * str2 * " = " * str3)
|
||||
end
|
||||
|
||||
function readJSON(filename::String)
|
||||
dict = Dict()
|
||||
@@ -70,9 +501,7 @@ end
|
||||
|
||||
function solveWithTrustedFunctions(
|
||||
input_r1cs::String,
|
||||
input_sym::String,
|
||||
input_r1cs_name::String,
|
||||
json_result::Dict{String, Any};
|
||||
input_r1cs_name::String;
|
||||
trusted_r1cs::Vector{String}=Vector{String}([]),
|
||||
trusted_r1cs_names::Vector{String}=Vector{String}([]),
|
||||
debug::Bool=false,
|
||||
@@ -81,7 +510,7 @@ function solveWithTrustedFunctions(
|
||||
input_sym::String="",
|
||||
secp_solve::Bool=false
|
||||
)
|
||||
|
||||
a = Dates.now()
|
||||
@assert (length(trusted_r1cs) == length(trusted_r1cs_names))
|
||||
equations_main, knowns_main, outs_main, num_variables = readR1CS(input_r1cs)
|
||||
function_list = []
|
||||
@@ -118,39 +547,34 @@ function solveWithTrustedFunctions(
|
||||
println(specials)
|
||||
return true
|
||||
end
|
||||
result = SolveConstraintsSymbolic(reduced, specials, knowns_main, debug, outs_main, num_variables, input_sym, secp_solve, json_result)
|
||||
b = Dates.now()
|
||||
println("time to prep inputs ", b - a)
|
||||
result = SolveConstraintsSymbolic(reduced, specials, knowns_main, debug, outs_main, num_variables, input_sym, secp_solve)
|
||||
if result == true
|
||||
if length(function_list) != 0
|
||||
if printRes
|
||||
msg = (
|
||||
"R1CS function " *
|
||||
input_r1cs_name *
|
||||
" has sound constraints assuming trusted functions " *
|
||||
join([trusted_r1cs_names[i] for i = 1:length(function_list)], ", "),
|
||||
)
|
||||
println(msg)
|
||||
json_result["result"] = msg
|
||||
msg = "R1CS function " *
|
||||
input_r1cs_name *
|
||||
" has sound constraints assuming trusted functions " *
|
||||
join([trusted_r1cs_names[i] for i = 1:length(function_list)], ", "), println(msg)
|
||||
#json_result["result"] = msg
|
||||
end
|
||||
return true
|
||||
else
|
||||
if printRes
|
||||
msg = (
|
||||
"R1CS function " *
|
||||
input_r1cs_name *
|
||||
" has sound constraints (No trusted functions needed!)",
|
||||
)
|
||||
msg = "R1CS function " *
|
||||
input_r1cs_name *
|
||||
" has sound constraints (No trusted functions needed!)"
|
||||
println(msg)
|
||||
json_result["result"] = msg
|
||||
#json_result["result"] = msg
|
||||
end
|
||||
return true
|
||||
end
|
||||
else
|
||||
if printRes
|
||||
msg = (
|
||||
"R1CS function " * input_r1cs_name * " has potentially unsound constraints",
|
||||
)
|
||||
msg = "R1CS function " * input_r1cs_name * " has potentially unsound constraints"
|
||||
println(msg)
|
||||
json_result["result"] = msg
|
||||
#json_result["result"] = msg
|
||||
end
|
||||
return false
|
||||
end
|
||||
@@ -165,8 +589,9 @@ function SolveConstraintsSymbolic(
|
||||
num_variables::Int=-1,
|
||||
input_sym::String="default.sym",
|
||||
secp_solve::Bool=false,
|
||||
json_result::Dict{String, Any}=Dict("result" => "empty", "constraints" => ["empty"]),
|
||||
)
|
||||
time_begin_solve = Dates.now()
|
||||
|
||||
num_unknowns =
|
||||
[length(setdiff(getVariables(x), Set(known_variables))) for x in constraints]
|
||||
in_queue = [false for x = 1:length(constraints)]
|
||||
@@ -187,9 +612,11 @@ function SolveConstraintsSymbolic(
|
||||
push!(l, j)
|
||||
end
|
||||
end
|
||||
for i in target_variables
|
||||
push!(l, i)
|
||||
end
|
||||
all_nontrivial_vars = Set(l)
|
||||
println("all var length")
|
||||
println(length(all_nontrivial_vars))
|
||||
|
||||
|
||||
q = Queue{Int64}()
|
||||
for i = 1:length(constraints)
|
||||
@@ -198,14 +625,6 @@ function SolveConstraintsSymbolic(
|
||||
in_queue[i] = true
|
||||
end
|
||||
end
|
||||
#num_variables = maximum([
|
||||
# maximum([
|
||||
# maximum(keys(constraints[i].a)),
|
||||
# maximum(keys(constraints[i].b)),
|
||||
# maximum(keys(constraints[i].c)),
|
||||
# ]) for i = 1:length(constraints)
|
||||
#])
|
||||
#println("num variables", num_variables)
|
||||
variable_to_indices = DefaultDict{Base.Int64,Vector{Int64}}(Vector{Int64})
|
||||
for i = 1:length(constraints)
|
||||
for j in getVariables(constraints[i])
|
||||
@@ -281,6 +700,9 @@ function SolveConstraintsSymbolic(
|
||||
nzk_c = [nonzeroKeys(constraints[i].c) for i = 1:length(constraints)]
|
||||
num_unique = 0
|
||||
display_eq = [true for i = 1:length(constraints)]
|
||||
setup_done = Dates.now()
|
||||
println("setup solver ", setup_done - time_begin_solve)
|
||||
|
||||
while true
|
||||
prog_made = false
|
||||
if (prev_successful_steps == successful_steps)
|
||||
@@ -1160,13 +1582,13 @@ function SolveConstraintsSymbolic(
|
||||
end
|
||||
end
|
||||
|
||||
if debug
|
||||
if true
|
||||
println(
|
||||
"Target variables solved for ",
|
||||
"Solved for ",
|
||||
target_unique,
|
||||
" variables out of ",
|
||||
" target variables out of ",
|
||||
length(target_variables),
|
||||
" total variables",
|
||||
" total target variables",
|
||||
)
|
||||
end
|
||||
function_good = false
|
||||
@@ -1174,57 +1596,52 @@ function SolveConstraintsSymbolic(
|
||||
function_good = true
|
||||
end
|
||||
## in this case, we solved for all the target variables, which means that we're in good shape.
|
||||
|
||||
println("------ Bad Constraints ------")
|
||||
println()
|
||||
## parse sym file with csv reader
|
||||
if input_sym != ""
|
||||
csv_reader = CSV.File(input_sym; header=["i1", "i2", "i3", "signal"], skipto=0)
|
||||
index_to_signal = String[]
|
||||
for row in csv_reader
|
||||
push!(index_to_signal, "$(row.signal)")
|
||||
end
|
||||
|
||||
csv_reader = CSV.File(input_sym; header=["i1", "i2", "i3", "signal"], skipto=0)
|
||||
index_to_signal = String[]
|
||||
|
||||
for row in csv_reader
|
||||
push!(index_to_signal, "$(row.signal)")
|
||||
end
|
||||
|
||||
# remove first entry
|
||||
pop!(json_result["constraints"])
|
||||
|
||||
for i = 1:length(constraints)
|
||||
all_unique = true
|
||||
for var in getVariables(constraints[i])
|
||||
if !variable_states[var].unique
|
||||
all_unique = false
|
||||
for i = 1:length(constraints)
|
||||
all_unique = true
|
||||
for var in getVariables(constraints[i])
|
||||
if !variable_states[var].unique
|
||||
all_unique = false
|
||||
end
|
||||
end
|
||||
end
|
||||
if all_unique
|
||||
continue
|
||||
end
|
||||
#if equation_solved[i]
|
||||
# continue
|
||||
#end
|
||||
#if !display_eq[i]
|
||||
# continue
|
||||
#end
|
||||
println("constraint #", i)
|
||||
printEquation(constraints[i], index_to_signal)
|
||||
for j in getVariables(constraints[i])
|
||||
if j == 1
|
||||
if all_unique
|
||||
continue
|
||||
end
|
||||
if length(getVariables(constraints[i])) > 3
|
||||
#if equation_solved[i]
|
||||
# continue
|
||||
#end
|
||||
#if !display_eq[i]
|
||||
# continue
|
||||
#end
|
||||
println("constraint #", i)
|
||||
printEquation(constraints[i], index_to_signal)
|
||||
for j in getVariables(constraints[i])
|
||||
if j == 1
|
||||
continue
|
||||
end
|
||||
println(index_to_signal[j-1])
|
||||
printState(variable_states[j])
|
||||
end
|
||||
end
|
||||
println("------ All Variables ------")
|
||||
println()
|
||||
for i in all_nontrivial_vars
|
||||
if i == 1
|
||||
continue
|
||||
end
|
||||
println(index_to_signal[j-1])
|
||||
printState(variable_states[j])
|
||||
println(index_to_signal[i-1])
|
||||
printState(variable_states[i])
|
||||
end
|
||||
end
|
||||
for i in all_nontrivial_vars
|
||||
if i == 1
|
||||
continue
|
||||
end
|
||||
println("constraint #", i)
|
||||
println(printEquation(constraints[i], index_to_signal))
|
||||
|
||||
push!(json_result["constraints"], printEquation(constraints[i], index_to_signal))
|
||||
end
|
||||
return function_good
|
||||
end
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ end
|
||||
|
||||
|
||||
@testset "secpAddUnequal given BigMultModP, BigLessThan" begin
|
||||
@test solveWithTrustedFunctions("../secp256k1.r1cs", "secpAddUnequal", trusted_r1cs=["../bigmultmodp.r1cs", "../biglessthan.r1cs"], trusted_r1cs_names=["BigMultModP", "BigLessThan"], printRes=false)
|
||||
@test solveWithTrustedFunctions("../secp256k1.r1cs", "secpAddUnequal", trusted_r1cs=["../bigmultmodp.r1cs", "../biglessthan.r1cs"], trusted_r1cs_names=["BigMultModP", "BigLessThan"], secp_solve=true, printRes=false)
|
||||
end
|
||||
|
||||
|
||||
|
||||
722
tornadocash_circuits/merkleTree.sym
Normal file
722
tornadocash_circuits/merkleTree.sym
Normal file
@@ -0,0 +1,722 @@
|
||||
1,1,4,main.leaf
|
||||
2,2,4,main.root
|
||||
3,3,4,main.pathElements[0]
|
||||
4,4,4,main.pathElements[1]
|
||||
5,5,4,main.pathElements[2]
|
||||
6,6,4,main.pathElements[3]
|
||||
7,7,4,main.pathElements[4]
|
||||
8,8,4,main.pathElements[5]
|
||||
9,9,4,main.pathElements[6]
|
||||
10,10,4,main.pathElements[7]
|
||||
11,11,4,main.pathElements[8]
|
||||
12,12,4,main.pathElements[9]
|
||||
13,13,4,main.pathElements[10]
|
||||
14,14,4,main.pathElements[11]
|
||||
15,15,4,main.pathElements[12]
|
||||
16,16,4,main.pathElements[13]
|
||||
17,17,4,main.pathElements[14]
|
||||
18,18,4,main.pathElements[15]
|
||||
19,19,4,main.pathElements[16]
|
||||
20,20,4,main.pathElements[17]
|
||||
21,21,4,main.pathElements[18]
|
||||
22,22,4,main.pathElements[19]
|
||||
23,23,4,main.pathIndices[0]
|
||||
24,24,4,main.pathIndices[1]
|
||||
25,25,4,main.pathIndices[2]
|
||||
26,26,4,main.pathIndices[3]
|
||||
27,27,4,main.pathIndices[4]
|
||||
28,28,4,main.pathIndices[5]
|
||||
29,29,4,main.pathIndices[6]
|
||||
30,30,4,main.pathIndices[7]
|
||||
31,31,4,main.pathIndices[8]
|
||||
32,32,4,main.pathIndices[9]
|
||||
33,33,4,main.pathIndices[10]
|
||||
34,34,4,main.pathIndices[11]
|
||||
35,35,4,main.pathIndices[12]
|
||||
36,36,4,main.pathIndices[13]
|
||||
37,37,4,main.pathIndices[14]
|
||||
38,38,4,main.pathIndices[15]
|
||||
39,39,4,main.pathIndices[16]
|
||||
40,40,4,main.pathIndices[17]
|
||||
41,41,4,main.pathIndices[18]
|
||||
42,42,4,main.pathIndices[19]
|
||||
43,43,3,main.hashers[0].hash
|
||||
44,44,3,main.hashers[0].left
|
||||
45,45,3,main.hashers[0].right
|
||||
46,46,2,main.hashers[0].hasher.outs[0]
|
||||
47,47,2,main.hashers[0].hasher.ins[0]
|
||||
48,48,2,main.hashers[0].hasher.ins[1]
|
||||
49,49,2,main.hashers[0].hasher.k
|
||||
50,50,1,main.hashers[0].hasher.S[0].xL_out
|
||||
51,51,1,main.hashers[0].hasher.S[0].xR_out
|
||||
52,52,1,main.hashers[0].hasher.S[0].xL_in
|
||||
53,53,1,main.hashers[0].hasher.S[0].xR_in
|
||||
54,54,1,main.hashers[0].hasher.S[0].k
|
||||
55,55,1,main.hashers[0].hasher.S[0].t2[0]
|
||||
56,56,1,main.hashers[0].hasher.S[0].t2[1]
|
||||
57,57,1,main.hashers[0].hasher.S[0].t4[0]
|
||||
58,58,1,main.hashers[0].hasher.S[0].t4[1]
|
||||
59,59,1,main.hashers[0].hasher.S[0].xL[0]
|
||||
60,60,1,main.hashers[0].hasher.S[0].xR[0]
|
||||
61,61,1,main.hashers[0].hasher.S[1].xL_out
|
||||
62,62,1,main.hashers[0].hasher.S[1].xR_out
|
||||
63,63,1,main.hashers[0].hasher.S[1].xL_in
|
||||
64,64,1,main.hashers[0].hasher.S[1].xR_in
|
||||
65,65,1,main.hashers[0].hasher.S[1].k
|
||||
66,66,1,main.hashers[0].hasher.S[1].t2[0]
|
||||
67,67,1,main.hashers[0].hasher.S[1].t2[1]
|
||||
68,68,1,main.hashers[0].hasher.S[1].t4[0]
|
||||
69,69,1,main.hashers[0].hasher.S[1].t4[1]
|
||||
70,70,1,main.hashers[0].hasher.S[1].xL[0]
|
||||
71,71,1,main.hashers[0].hasher.S[1].xR[0]
|
||||
72,72,3,main.hashers[1].hash
|
||||
73,73,3,main.hashers[1].left
|
||||
74,74,3,main.hashers[1].right
|
||||
75,75,2,main.hashers[1].hasher.outs[0]
|
||||
76,76,2,main.hashers[1].hasher.ins[0]
|
||||
77,77,2,main.hashers[1].hasher.ins[1]
|
||||
78,78,2,main.hashers[1].hasher.k
|
||||
79,79,1,main.hashers[1].hasher.S[0].xL_out
|
||||
80,80,1,main.hashers[1].hasher.S[0].xR_out
|
||||
81,81,1,main.hashers[1].hasher.S[0].xL_in
|
||||
82,82,1,main.hashers[1].hasher.S[0].xR_in
|
||||
83,83,1,main.hashers[1].hasher.S[0].k
|
||||
84,84,1,main.hashers[1].hasher.S[0].t2[0]
|
||||
85,85,1,main.hashers[1].hasher.S[0].t2[1]
|
||||
86,86,1,main.hashers[1].hasher.S[0].t4[0]
|
||||
87,87,1,main.hashers[1].hasher.S[0].t4[1]
|
||||
88,88,1,main.hashers[1].hasher.S[0].xL[0]
|
||||
89,89,1,main.hashers[1].hasher.S[0].xR[0]
|
||||
90,90,1,main.hashers[1].hasher.S[1].xL_out
|
||||
91,91,1,main.hashers[1].hasher.S[1].xR_out
|
||||
92,92,1,main.hashers[1].hasher.S[1].xL_in
|
||||
93,93,1,main.hashers[1].hasher.S[1].xR_in
|
||||
94,94,1,main.hashers[1].hasher.S[1].k
|
||||
95,95,1,main.hashers[1].hasher.S[1].t2[0]
|
||||
96,96,1,main.hashers[1].hasher.S[1].t2[1]
|
||||
97,97,1,main.hashers[1].hasher.S[1].t4[0]
|
||||
98,98,1,main.hashers[1].hasher.S[1].t4[1]
|
||||
99,99,1,main.hashers[1].hasher.S[1].xL[0]
|
||||
100,100,1,main.hashers[1].hasher.S[1].xR[0]
|
||||
101,101,3,main.hashers[2].hash
|
||||
102,102,3,main.hashers[2].left
|
||||
103,103,3,main.hashers[2].right
|
||||
104,104,2,main.hashers[2].hasher.outs[0]
|
||||
105,105,2,main.hashers[2].hasher.ins[0]
|
||||
106,106,2,main.hashers[2].hasher.ins[1]
|
||||
107,107,2,main.hashers[2].hasher.k
|
||||
108,108,1,main.hashers[2].hasher.S[0].xL_out
|
||||
109,109,1,main.hashers[2].hasher.S[0].xR_out
|
||||
110,110,1,main.hashers[2].hasher.S[0].xL_in
|
||||
111,111,1,main.hashers[2].hasher.S[0].xR_in
|
||||
112,112,1,main.hashers[2].hasher.S[0].k
|
||||
113,113,1,main.hashers[2].hasher.S[0].t2[0]
|
||||
114,114,1,main.hashers[2].hasher.S[0].t2[1]
|
||||
115,115,1,main.hashers[2].hasher.S[0].t4[0]
|
||||
116,116,1,main.hashers[2].hasher.S[0].t4[1]
|
||||
117,117,1,main.hashers[2].hasher.S[0].xL[0]
|
||||
118,118,1,main.hashers[2].hasher.S[0].xR[0]
|
||||
119,119,1,main.hashers[2].hasher.S[1].xL_out
|
||||
120,120,1,main.hashers[2].hasher.S[1].xR_out
|
||||
121,121,1,main.hashers[2].hasher.S[1].xL_in
|
||||
122,122,1,main.hashers[2].hasher.S[1].xR_in
|
||||
123,123,1,main.hashers[2].hasher.S[1].k
|
||||
124,124,1,main.hashers[2].hasher.S[1].t2[0]
|
||||
125,125,1,main.hashers[2].hasher.S[1].t2[1]
|
||||
126,126,1,main.hashers[2].hasher.S[1].t4[0]
|
||||
127,127,1,main.hashers[2].hasher.S[1].t4[1]
|
||||
128,128,1,main.hashers[2].hasher.S[1].xL[0]
|
||||
129,129,1,main.hashers[2].hasher.S[1].xR[0]
|
||||
130,130,3,main.hashers[3].hash
|
||||
131,131,3,main.hashers[3].left
|
||||
132,132,3,main.hashers[3].right
|
||||
133,133,2,main.hashers[3].hasher.outs[0]
|
||||
134,134,2,main.hashers[3].hasher.ins[0]
|
||||
135,135,2,main.hashers[3].hasher.ins[1]
|
||||
136,136,2,main.hashers[3].hasher.k
|
||||
137,137,1,main.hashers[3].hasher.S[0].xL_out
|
||||
138,138,1,main.hashers[3].hasher.S[0].xR_out
|
||||
139,139,1,main.hashers[3].hasher.S[0].xL_in
|
||||
140,140,1,main.hashers[3].hasher.S[0].xR_in
|
||||
141,141,1,main.hashers[3].hasher.S[0].k
|
||||
142,142,1,main.hashers[3].hasher.S[0].t2[0]
|
||||
143,143,1,main.hashers[3].hasher.S[0].t2[1]
|
||||
144,144,1,main.hashers[3].hasher.S[0].t4[0]
|
||||
145,145,1,main.hashers[3].hasher.S[0].t4[1]
|
||||
146,146,1,main.hashers[3].hasher.S[0].xL[0]
|
||||
147,147,1,main.hashers[3].hasher.S[0].xR[0]
|
||||
148,148,1,main.hashers[3].hasher.S[1].xL_out
|
||||
149,149,1,main.hashers[3].hasher.S[1].xR_out
|
||||
150,150,1,main.hashers[3].hasher.S[1].xL_in
|
||||
151,151,1,main.hashers[3].hasher.S[1].xR_in
|
||||
152,152,1,main.hashers[3].hasher.S[1].k
|
||||
153,153,1,main.hashers[3].hasher.S[1].t2[0]
|
||||
154,154,1,main.hashers[3].hasher.S[1].t2[1]
|
||||
155,155,1,main.hashers[3].hasher.S[1].t4[0]
|
||||
156,156,1,main.hashers[3].hasher.S[1].t4[1]
|
||||
157,157,1,main.hashers[3].hasher.S[1].xL[0]
|
||||
158,158,1,main.hashers[3].hasher.S[1].xR[0]
|
||||
159,159,3,main.hashers[4].hash
|
||||
160,160,3,main.hashers[4].left
|
||||
161,161,3,main.hashers[4].right
|
||||
162,162,2,main.hashers[4].hasher.outs[0]
|
||||
163,163,2,main.hashers[4].hasher.ins[0]
|
||||
164,164,2,main.hashers[4].hasher.ins[1]
|
||||
165,165,2,main.hashers[4].hasher.k
|
||||
166,166,1,main.hashers[4].hasher.S[0].xL_out
|
||||
167,167,1,main.hashers[4].hasher.S[0].xR_out
|
||||
168,168,1,main.hashers[4].hasher.S[0].xL_in
|
||||
169,169,1,main.hashers[4].hasher.S[0].xR_in
|
||||
170,170,1,main.hashers[4].hasher.S[0].k
|
||||
171,171,1,main.hashers[4].hasher.S[0].t2[0]
|
||||
172,172,1,main.hashers[4].hasher.S[0].t2[1]
|
||||
173,173,1,main.hashers[4].hasher.S[0].t4[0]
|
||||
174,174,1,main.hashers[4].hasher.S[0].t4[1]
|
||||
175,175,1,main.hashers[4].hasher.S[0].xL[0]
|
||||
176,176,1,main.hashers[4].hasher.S[0].xR[0]
|
||||
177,177,1,main.hashers[4].hasher.S[1].xL_out
|
||||
178,178,1,main.hashers[4].hasher.S[1].xR_out
|
||||
179,179,1,main.hashers[4].hasher.S[1].xL_in
|
||||
180,180,1,main.hashers[4].hasher.S[1].xR_in
|
||||
181,181,1,main.hashers[4].hasher.S[1].k
|
||||
182,182,1,main.hashers[4].hasher.S[1].t2[0]
|
||||
183,183,1,main.hashers[4].hasher.S[1].t2[1]
|
||||
184,184,1,main.hashers[4].hasher.S[1].t4[0]
|
||||
185,185,1,main.hashers[4].hasher.S[1].t4[1]
|
||||
186,186,1,main.hashers[4].hasher.S[1].xL[0]
|
||||
187,187,1,main.hashers[4].hasher.S[1].xR[0]
|
||||
188,188,3,main.hashers[5].hash
|
||||
189,189,3,main.hashers[5].left
|
||||
190,190,3,main.hashers[5].right
|
||||
191,191,2,main.hashers[5].hasher.outs[0]
|
||||
192,192,2,main.hashers[5].hasher.ins[0]
|
||||
193,193,2,main.hashers[5].hasher.ins[1]
|
||||
194,194,2,main.hashers[5].hasher.k
|
||||
195,195,1,main.hashers[5].hasher.S[0].xL_out
|
||||
196,196,1,main.hashers[5].hasher.S[0].xR_out
|
||||
197,197,1,main.hashers[5].hasher.S[0].xL_in
|
||||
198,198,1,main.hashers[5].hasher.S[0].xR_in
|
||||
199,199,1,main.hashers[5].hasher.S[0].k
|
||||
200,200,1,main.hashers[5].hasher.S[0].t2[0]
|
||||
201,201,1,main.hashers[5].hasher.S[0].t2[1]
|
||||
202,202,1,main.hashers[5].hasher.S[0].t4[0]
|
||||
203,203,1,main.hashers[5].hasher.S[0].t4[1]
|
||||
204,204,1,main.hashers[5].hasher.S[0].xL[0]
|
||||
205,205,1,main.hashers[5].hasher.S[0].xR[0]
|
||||
206,206,1,main.hashers[5].hasher.S[1].xL_out
|
||||
207,207,1,main.hashers[5].hasher.S[1].xR_out
|
||||
208,208,1,main.hashers[5].hasher.S[1].xL_in
|
||||
209,209,1,main.hashers[5].hasher.S[1].xR_in
|
||||
210,210,1,main.hashers[5].hasher.S[1].k
|
||||
211,211,1,main.hashers[5].hasher.S[1].t2[0]
|
||||
212,212,1,main.hashers[5].hasher.S[1].t2[1]
|
||||
213,213,1,main.hashers[5].hasher.S[1].t4[0]
|
||||
214,214,1,main.hashers[5].hasher.S[1].t4[1]
|
||||
215,215,1,main.hashers[5].hasher.S[1].xL[0]
|
||||
216,216,1,main.hashers[5].hasher.S[1].xR[0]
|
||||
217,217,3,main.hashers[6].hash
|
||||
218,218,3,main.hashers[6].left
|
||||
219,219,3,main.hashers[6].right
|
||||
220,220,2,main.hashers[6].hasher.outs[0]
|
||||
221,221,2,main.hashers[6].hasher.ins[0]
|
||||
222,222,2,main.hashers[6].hasher.ins[1]
|
||||
223,223,2,main.hashers[6].hasher.k
|
||||
224,224,1,main.hashers[6].hasher.S[0].xL_out
|
||||
225,225,1,main.hashers[6].hasher.S[0].xR_out
|
||||
226,226,1,main.hashers[6].hasher.S[0].xL_in
|
||||
227,227,1,main.hashers[6].hasher.S[0].xR_in
|
||||
228,228,1,main.hashers[6].hasher.S[0].k
|
||||
229,229,1,main.hashers[6].hasher.S[0].t2[0]
|
||||
230,230,1,main.hashers[6].hasher.S[0].t2[1]
|
||||
231,231,1,main.hashers[6].hasher.S[0].t4[0]
|
||||
232,232,1,main.hashers[6].hasher.S[0].t4[1]
|
||||
233,233,1,main.hashers[6].hasher.S[0].xL[0]
|
||||
234,234,1,main.hashers[6].hasher.S[0].xR[0]
|
||||
235,235,1,main.hashers[6].hasher.S[1].xL_out
|
||||
236,236,1,main.hashers[6].hasher.S[1].xR_out
|
||||
237,237,1,main.hashers[6].hasher.S[1].xL_in
|
||||
238,238,1,main.hashers[6].hasher.S[1].xR_in
|
||||
239,239,1,main.hashers[6].hasher.S[1].k
|
||||
240,240,1,main.hashers[6].hasher.S[1].t2[0]
|
||||
241,241,1,main.hashers[6].hasher.S[1].t2[1]
|
||||
242,242,1,main.hashers[6].hasher.S[1].t4[0]
|
||||
243,243,1,main.hashers[6].hasher.S[1].t4[1]
|
||||
244,244,1,main.hashers[6].hasher.S[1].xL[0]
|
||||
245,245,1,main.hashers[6].hasher.S[1].xR[0]
|
||||
246,246,3,main.hashers[7].hash
|
||||
247,247,3,main.hashers[7].left
|
||||
248,248,3,main.hashers[7].right
|
||||
249,249,2,main.hashers[7].hasher.outs[0]
|
||||
250,250,2,main.hashers[7].hasher.ins[0]
|
||||
251,251,2,main.hashers[7].hasher.ins[1]
|
||||
252,252,2,main.hashers[7].hasher.k
|
||||
253,253,1,main.hashers[7].hasher.S[0].xL_out
|
||||
254,254,1,main.hashers[7].hasher.S[0].xR_out
|
||||
255,255,1,main.hashers[7].hasher.S[0].xL_in
|
||||
256,256,1,main.hashers[7].hasher.S[0].xR_in
|
||||
257,257,1,main.hashers[7].hasher.S[0].k
|
||||
258,258,1,main.hashers[7].hasher.S[0].t2[0]
|
||||
259,259,1,main.hashers[7].hasher.S[0].t2[1]
|
||||
260,260,1,main.hashers[7].hasher.S[0].t4[0]
|
||||
261,261,1,main.hashers[7].hasher.S[0].t4[1]
|
||||
262,262,1,main.hashers[7].hasher.S[0].xL[0]
|
||||
263,263,1,main.hashers[7].hasher.S[0].xR[0]
|
||||
264,264,1,main.hashers[7].hasher.S[1].xL_out
|
||||
265,265,1,main.hashers[7].hasher.S[1].xR_out
|
||||
266,266,1,main.hashers[7].hasher.S[1].xL_in
|
||||
267,267,1,main.hashers[7].hasher.S[1].xR_in
|
||||
268,268,1,main.hashers[7].hasher.S[1].k
|
||||
269,269,1,main.hashers[7].hasher.S[1].t2[0]
|
||||
270,270,1,main.hashers[7].hasher.S[1].t2[1]
|
||||
271,271,1,main.hashers[7].hasher.S[1].t4[0]
|
||||
272,272,1,main.hashers[7].hasher.S[1].t4[1]
|
||||
273,273,1,main.hashers[7].hasher.S[1].xL[0]
|
||||
274,274,1,main.hashers[7].hasher.S[1].xR[0]
|
||||
275,275,3,main.hashers[8].hash
|
||||
276,276,3,main.hashers[8].left
|
||||
277,277,3,main.hashers[8].right
|
||||
278,278,2,main.hashers[8].hasher.outs[0]
|
||||
279,279,2,main.hashers[8].hasher.ins[0]
|
||||
280,280,2,main.hashers[8].hasher.ins[1]
|
||||
281,281,2,main.hashers[8].hasher.k
|
||||
282,282,1,main.hashers[8].hasher.S[0].xL_out
|
||||
283,283,1,main.hashers[8].hasher.S[0].xR_out
|
||||
284,284,1,main.hashers[8].hasher.S[0].xL_in
|
||||
285,285,1,main.hashers[8].hasher.S[0].xR_in
|
||||
286,286,1,main.hashers[8].hasher.S[0].k
|
||||
287,287,1,main.hashers[8].hasher.S[0].t2[0]
|
||||
288,288,1,main.hashers[8].hasher.S[0].t2[1]
|
||||
289,289,1,main.hashers[8].hasher.S[0].t4[0]
|
||||
290,290,1,main.hashers[8].hasher.S[0].t4[1]
|
||||
291,291,1,main.hashers[8].hasher.S[0].xL[0]
|
||||
292,292,1,main.hashers[8].hasher.S[0].xR[0]
|
||||
293,293,1,main.hashers[8].hasher.S[1].xL_out
|
||||
294,294,1,main.hashers[8].hasher.S[1].xR_out
|
||||
295,295,1,main.hashers[8].hasher.S[1].xL_in
|
||||
296,296,1,main.hashers[8].hasher.S[1].xR_in
|
||||
297,297,1,main.hashers[8].hasher.S[1].k
|
||||
298,298,1,main.hashers[8].hasher.S[1].t2[0]
|
||||
299,299,1,main.hashers[8].hasher.S[1].t2[1]
|
||||
300,300,1,main.hashers[8].hasher.S[1].t4[0]
|
||||
301,301,1,main.hashers[8].hasher.S[1].t4[1]
|
||||
302,302,1,main.hashers[8].hasher.S[1].xL[0]
|
||||
303,303,1,main.hashers[8].hasher.S[1].xR[0]
|
||||
304,304,3,main.hashers[9].hash
|
||||
305,305,3,main.hashers[9].left
|
||||
306,306,3,main.hashers[9].right
|
||||
307,307,2,main.hashers[9].hasher.outs[0]
|
||||
308,308,2,main.hashers[9].hasher.ins[0]
|
||||
309,309,2,main.hashers[9].hasher.ins[1]
|
||||
310,310,2,main.hashers[9].hasher.k
|
||||
311,311,1,main.hashers[9].hasher.S[0].xL_out
|
||||
312,312,1,main.hashers[9].hasher.S[0].xR_out
|
||||
313,313,1,main.hashers[9].hasher.S[0].xL_in
|
||||
314,314,1,main.hashers[9].hasher.S[0].xR_in
|
||||
315,315,1,main.hashers[9].hasher.S[0].k
|
||||
316,316,1,main.hashers[9].hasher.S[0].t2[0]
|
||||
317,317,1,main.hashers[9].hasher.S[0].t2[1]
|
||||
318,318,1,main.hashers[9].hasher.S[0].t4[0]
|
||||
319,319,1,main.hashers[9].hasher.S[0].t4[1]
|
||||
320,320,1,main.hashers[9].hasher.S[0].xL[0]
|
||||
321,321,1,main.hashers[9].hasher.S[0].xR[0]
|
||||
322,322,1,main.hashers[9].hasher.S[1].xL_out
|
||||
323,323,1,main.hashers[9].hasher.S[1].xR_out
|
||||
324,324,1,main.hashers[9].hasher.S[1].xL_in
|
||||
325,325,1,main.hashers[9].hasher.S[1].xR_in
|
||||
326,326,1,main.hashers[9].hasher.S[1].k
|
||||
327,327,1,main.hashers[9].hasher.S[1].t2[0]
|
||||
328,328,1,main.hashers[9].hasher.S[1].t2[1]
|
||||
329,329,1,main.hashers[9].hasher.S[1].t4[0]
|
||||
330,330,1,main.hashers[9].hasher.S[1].t4[1]
|
||||
331,331,1,main.hashers[9].hasher.S[1].xL[0]
|
||||
332,332,1,main.hashers[9].hasher.S[1].xR[0]
|
||||
333,333,3,main.hashers[10].hash
|
||||
334,334,3,main.hashers[10].left
|
||||
335,335,3,main.hashers[10].right
|
||||
336,336,2,main.hashers[10].hasher.outs[0]
|
||||
337,337,2,main.hashers[10].hasher.ins[0]
|
||||
338,338,2,main.hashers[10].hasher.ins[1]
|
||||
339,339,2,main.hashers[10].hasher.k
|
||||
340,340,1,main.hashers[10].hasher.S[0].xL_out
|
||||
341,341,1,main.hashers[10].hasher.S[0].xR_out
|
||||
342,342,1,main.hashers[10].hasher.S[0].xL_in
|
||||
343,343,1,main.hashers[10].hasher.S[0].xR_in
|
||||
344,344,1,main.hashers[10].hasher.S[0].k
|
||||
345,345,1,main.hashers[10].hasher.S[0].t2[0]
|
||||
346,346,1,main.hashers[10].hasher.S[0].t2[1]
|
||||
347,347,1,main.hashers[10].hasher.S[0].t4[0]
|
||||
348,348,1,main.hashers[10].hasher.S[0].t4[1]
|
||||
349,349,1,main.hashers[10].hasher.S[0].xL[0]
|
||||
350,350,1,main.hashers[10].hasher.S[0].xR[0]
|
||||
351,351,1,main.hashers[10].hasher.S[1].xL_out
|
||||
352,352,1,main.hashers[10].hasher.S[1].xR_out
|
||||
353,353,1,main.hashers[10].hasher.S[1].xL_in
|
||||
354,354,1,main.hashers[10].hasher.S[1].xR_in
|
||||
355,355,1,main.hashers[10].hasher.S[1].k
|
||||
356,356,1,main.hashers[10].hasher.S[1].t2[0]
|
||||
357,357,1,main.hashers[10].hasher.S[1].t2[1]
|
||||
358,358,1,main.hashers[10].hasher.S[1].t4[0]
|
||||
359,359,1,main.hashers[10].hasher.S[1].t4[1]
|
||||
360,360,1,main.hashers[10].hasher.S[1].xL[0]
|
||||
361,361,1,main.hashers[10].hasher.S[1].xR[0]
|
||||
362,362,3,main.hashers[11].hash
|
||||
363,363,3,main.hashers[11].left
|
||||
364,364,3,main.hashers[11].right
|
||||
365,365,2,main.hashers[11].hasher.outs[0]
|
||||
366,366,2,main.hashers[11].hasher.ins[0]
|
||||
367,367,2,main.hashers[11].hasher.ins[1]
|
||||
368,368,2,main.hashers[11].hasher.k
|
||||
369,369,1,main.hashers[11].hasher.S[0].xL_out
|
||||
370,370,1,main.hashers[11].hasher.S[0].xR_out
|
||||
371,371,1,main.hashers[11].hasher.S[0].xL_in
|
||||
372,372,1,main.hashers[11].hasher.S[0].xR_in
|
||||
373,373,1,main.hashers[11].hasher.S[0].k
|
||||
374,374,1,main.hashers[11].hasher.S[0].t2[0]
|
||||
375,375,1,main.hashers[11].hasher.S[0].t2[1]
|
||||
376,376,1,main.hashers[11].hasher.S[0].t4[0]
|
||||
377,377,1,main.hashers[11].hasher.S[0].t4[1]
|
||||
378,378,1,main.hashers[11].hasher.S[0].xL[0]
|
||||
379,379,1,main.hashers[11].hasher.S[0].xR[0]
|
||||
380,380,1,main.hashers[11].hasher.S[1].xL_out
|
||||
381,381,1,main.hashers[11].hasher.S[1].xR_out
|
||||
382,382,1,main.hashers[11].hasher.S[1].xL_in
|
||||
383,383,1,main.hashers[11].hasher.S[1].xR_in
|
||||
384,384,1,main.hashers[11].hasher.S[1].k
|
||||
385,385,1,main.hashers[11].hasher.S[1].t2[0]
|
||||
386,386,1,main.hashers[11].hasher.S[1].t2[1]
|
||||
387,387,1,main.hashers[11].hasher.S[1].t4[0]
|
||||
388,388,1,main.hashers[11].hasher.S[1].t4[1]
|
||||
389,389,1,main.hashers[11].hasher.S[1].xL[0]
|
||||
390,390,1,main.hashers[11].hasher.S[1].xR[0]
|
||||
391,391,3,main.hashers[12].hash
|
||||
392,392,3,main.hashers[12].left
|
||||
393,393,3,main.hashers[12].right
|
||||
394,394,2,main.hashers[12].hasher.outs[0]
|
||||
395,395,2,main.hashers[12].hasher.ins[0]
|
||||
396,396,2,main.hashers[12].hasher.ins[1]
|
||||
397,397,2,main.hashers[12].hasher.k
|
||||
398,398,1,main.hashers[12].hasher.S[0].xL_out
|
||||
399,399,1,main.hashers[12].hasher.S[0].xR_out
|
||||
400,400,1,main.hashers[12].hasher.S[0].xL_in
|
||||
401,401,1,main.hashers[12].hasher.S[0].xR_in
|
||||
402,402,1,main.hashers[12].hasher.S[0].k
|
||||
403,403,1,main.hashers[12].hasher.S[0].t2[0]
|
||||
404,404,1,main.hashers[12].hasher.S[0].t2[1]
|
||||
405,405,1,main.hashers[12].hasher.S[0].t4[0]
|
||||
406,406,1,main.hashers[12].hasher.S[0].t4[1]
|
||||
407,407,1,main.hashers[12].hasher.S[0].xL[0]
|
||||
408,408,1,main.hashers[12].hasher.S[0].xR[0]
|
||||
409,409,1,main.hashers[12].hasher.S[1].xL_out
|
||||
410,410,1,main.hashers[12].hasher.S[1].xR_out
|
||||
411,411,1,main.hashers[12].hasher.S[1].xL_in
|
||||
412,412,1,main.hashers[12].hasher.S[1].xR_in
|
||||
413,413,1,main.hashers[12].hasher.S[1].k
|
||||
414,414,1,main.hashers[12].hasher.S[1].t2[0]
|
||||
415,415,1,main.hashers[12].hasher.S[1].t2[1]
|
||||
416,416,1,main.hashers[12].hasher.S[1].t4[0]
|
||||
417,417,1,main.hashers[12].hasher.S[1].t4[1]
|
||||
418,418,1,main.hashers[12].hasher.S[1].xL[0]
|
||||
419,419,1,main.hashers[12].hasher.S[1].xR[0]
|
||||
420,420,3,main.hashers[13].hash
|
||||
421,421,3,main.hashers[13].left
|
||||
422,422,3,main.hashers[13].right
|
||||
423,423,2,main.hashers[13].hasher.outs[0]
|
||||
424,424,2,main.hashers[13].hasher.ins[0]
|
||||
425,425,2,main.hashers[13].hasher.ins[1]
|
||||
426,426,2,main.hashers[13].hasher.k
|
||||
427,427,1,main.hashers[13].hasher.S[0].xL_out
|
||||
428,428,1,main.hashers[13].hasher.S[0].xR_out
|
||||
429,429,1,main.hashers[13].hasher.S[0].xL_in
|
||||
430,430,1,main.hashers[13].hasher.S[0].xR_in
|
||||
431,431,1,main.hashers[13].hasher.S[0].k
|
||||
432,432,1,main.hashers[13].hasher.S[0].t2[0]
|
||||
433,433,1,main.hashers[13].hasher.S[0].t2[1]
|
||||
434,434,1,main.hashers[13].hasher.S[0].t4[0]
|
||||
435,435,1,main.hashers[13].hasher.S[0].t4[1]
|
||||
436,436,1,main.hashers[13].hasher.S[0].xL[0]
|
||||
437,437,1,main.hashers[13].hasher.S[0].xR[0]
|
||||
438,438,1,main.hashers[13].hasher.S[1].xL_out
|
||||
439,439,1,main.hashers[13].hasher.S[1].xR_out
|
||||
440,440,1,main.hashers[13].hasher.S[1].xL_in
|
||||
441,441,1,main.hashers[13].hasher.S[1].xR_in
|
||||
442,442,1,main.hashers[13].hasher.S[1].k
|
||||
443,443,1,main.hashers[13].hasher.S[1].t2[0]
|
||||
444,444,1,main.hashers[13].hasher.S[1].t2[1]
|
||||
445,445,1,main.hashers[13].hasher.S[1].t4[0]
|
||||
446,446,1,main.hashers[13].hasher.S[1].t4[1]
|
||||
447,447,1,main.hashers[13].hasher.S[1].xL[0]
|
||||
448,448,1,main.hashers[13].hasher.S[1].xR[0]
|
||||
449,449,3,main.hashers[14].hash
|
||||
450,450,3,main.hashers[14].left
|
||||
451,451,3,main.hashers[14].right
|
||||
452,452,2,main.hashers[14].hasher.outs[0]
|
||||
453,453,2,main.hashers[14].hasher.ins[0]
|
||||
454,454,2,main.hashers[14].hasher.ins[1]
|
||||
455,455,2,main.hashers[14].hasher.k
|
||||
456,456,1,main.hashers[14].hasher.S[0].xL_out
|
||||
457,457,1,main.hashers[14].hasher.S[0].xR_out
|
||||
458,458,1,main.hashers[14].hasher.S[0].xL_in
|
||||
459,459,1,main.hashers[14].hasher.S[0].xR_in
|
||||
460,460,1,main.hashers[14].hasher.S[0].k
|
||||
461,461,1,main.hashers[14].hasher.S[0].t2[0]
|
||||
462,462,1,main.hashers[14].hasher.S[0].t2[1]
|
||||
463,463,1,main.hashers[14].hasher.S[0].t4[0]
|
||||
464,464,1,main.hashers[14].hasher.S[0].t4[1]
|
||||
465,465,1,main.hashers[14].hasher.S[0].xL[0]
|
||||
466,466,1,main.hashers[14].hasher.S[0].xR[0]
|
||||
467,467,1,main.hashers[14].hasher.S[1].xL_out
|
||||
468,468,1,main.hashers[14].hasher.S[1].xR_out
|
||||
469,469,1,main.hashers[14].hasher.S[1].xL_in
|
||||
470,470,1,main.hashers[14].hasher.S[1].xR_in
|
||||
471,471,1,main.hashers[14].hasher.S[1].k
|
||||
472,472,1,main.hashers[14].hasher.S[1].t2[0]
|
||||
473,473,1,main.hashers[14].hasher.S[1].t2[1]
|
||||
474,474,1,main.hashers[14].hasher.S[1].t4[0]
|
||||
475,475,1,main.hashers[14].hasher.S[1].t4[1]
|
||||
476,476,1,main.hashers[14].hasher.S[1].xL[0]
|
||||
477,477,1,main.hashers[14].hasher.S[1].xR[0]
|
||||
478,478,3,main.hashers[15].hash
|
||||
479,479,3,main.hashers[15].left
|
||||
480,480,3,main.hashers[15].right
|
||||
481,481,2,main.hashers[15].hasher.outs[0]
|
||||
482,482,2,main.hashers[15].hasher.ins[0]
|
||||
483,483,2,main.hashers[15].hasher.ins[1]
|
||||
484,484,2,main.hashers[15].hasher.k
|
||||
485,485,1,main.hashers[15].hasher.S[0].xL_out
|
||||
486,486,1,main.hashers[15].hasher.S[0].xR_out
|
||||
487,487,1,main.hashers[15].hasher.S[0].xL_in
|
||||
488,488,1,main.hashers[15].hasher.S[0].xR_in
|
||||
489,489,1,main.hashers[15].hasher.S[0].k
|
||||
490,490,1,main.hashers[15].hasher.S[0].t2[0]
|
||||
491,491,1,main.hashers[15].hasher.S[0].t2[1]
|
||||
492,492,1,main.hashers[15].hasher.S[0].t4[0]
|
||||
493,493,1,main.hashers[15].hasher.S[0].t4[1]
|
||||
494,494,1,main.hashers[15].hasher.S[0].xL[0]
|
||||
495,495,1,main.hashers[15].hasher.S[0].xR[0]
|
||||
496,496,1,main.hashers[15].hasher.S[1].xL_out
|
||||
497,497,1,main.hashers[15].hasher.S[1].xR_out
|
||||
498,498,1,main.hashers[15].hasher.S[1].xL_in
|
||||
499,499,1,main.hashers[15].hasher.S[1].xR_in
|
||||
500,500,1,main.hashers[15].hasher.S[1].k
|
||||
501,501,1,main.hashers[15].hasher.S[1].t2[0]
|
||||
502,502,1,main.hashers[15].hasher.S[1].t2[1]
|
||||
503,503,1,main.hashers[15].hasher.S[1].t4[0]
|
||||
504,504,1,main.hashers[15].hasher.S[1].t4[1]
|
||||
505,505,1,main.hashers[15].hasher.S[1].xL[0]
|
||||
506,506,1,main.hashers[15].hasher.S[1].xR[0]
|
||||
507,507,3,main.hashers[16].hash
|
||||
508,508,3,main.hashers[16].left
|
||||
509,509,3,main.hashers[16].right
|
||||
510,510,2,main.hashers[16].hasher.outs[0]
|
||||
511,511,2,main.hashers[16].hasher.ins[0]
|
||||
512,512,2,main.hashers[16].hasher.ins[1]
|
||||
513,513,2,main.hashers[16].hasher.k
|
||||
514,514,1,main.hashers[16].hasher.S[0].xL_out
|
||||
515,515,1,main.hashers[16].hasher.S[0].xR_out
|
||||
516,516,1,main.hashers[16].hasher.S[0].xL_in
|
||||
517,517,1,main.hashers[16].hasher.S[0].xR_in
|
||||
518,518,1,main.hashers[16].hasher.S[0].k
|
||||
519,519,1,main.hashers[16].hasher.S[0].t2[0]
|
||||
520,520,1,main.hashers[16].hasher.S[0].t2[1]
|
||||
521,521,1,main.hashers[16].hasher.S[0].t4[0]
|
||||
522,522,1,main.hashers[16].hasher.S[0].t4[1]
|
||||
523,523,1,main.hashers[16].hasher.S[0].xL[0]
|
||||
524,524,1,main.hashers[16].hasher.S[0].xR[0]
|
||||
525,525,1,main.hashers[16].hasher.S[1].xL_out
|
||||
526,526,1,main.hashers[16].hasher.S[1].xR_out
|
||||
527,527,1,main.hashers[16].hasher.S[1].xL_in
|
||||
528,528,1,main.hashers[16].hasher.S[1].xR_in
|
||||
529,529,1,main.hashers[16].hasher.S[1].k
|
||||
530,530,1,main.hashers[16].hasher.S[1].t2[0]
|
||||
531,531,1,main.hashers[16].hasher.S[1].t2[1]
|
||||
532,532,1,main.hashers[16].hasher.S[1].t4[0]
|
||||
533,533,1,main.hashers[16].hasher.S[1].t4[1]
|
||||
534,534,1,main.hashers[16].hasher.S[1].xL[0]
|
||||
535,535,1,main.hashers[16].hasher.S[1].xR[0]
|
||||
536,536,3,main.hashers[17].hash
|
||||
537,537,3,main.hashers[17].left
|
||||
538,538,3,main.hashers[17].right
|
||||
539,539,2,main.hashers[17].hasher.outs[0]
|
||||
540,540,2,main.hashers[17].hasher.ins[0]
|
||||
541,541,2,main.hashers[17].hasher.ins[1]
|
||||
542,542,2,main.hashers[17].hasher.k
|
||||
543,543,1,main.hashers[17].hasher.S[0].xL_out
|
||||
544,544,1,main.hashers[17].hasher.S[0].xR_out
|
||||
545,545,1,main.hashers[17].hasher.S[0].xL_in
|
||||
546,546,1,main.hashers[17].hasher.S[0].xR_in
|
||||
547,547,1,main.hashers[17].hasher.S[0].k
|
||||
548,548,1,main.hashers[17].hasher.S[0].t2[0]
|
||||
549,549,1,main.hashers[17].hasher.S[0].t2[1]
|
||||
550,550,1,main.hashers[17].hasher.S[0].t4[0]
|
||||
551,551,1,main.hashers[17].hasher.S[0].t4[1]
|
||||
552,552,1,main.hashers[17].hasher.S[0].xL[0]
|
||||
553,553,1,main.hashers[17].hasher.S[0].xR[0]
|
||||
554,554,1,main.hashers[17].hasher.S[1].xL_out
|
||||
555,555,1,main.hashers[17].hasher.S[1].xR_out
|
||||
556,556,1,main.hashers[17].hasher.S[1].xL_in
|
||||
557,557,1,main.hashers[17].hasher.S[1].xR_in
|
||||
558,558,1,main.hashers[17].hasher.S[1].k
|
||||
559,559,1,main.hashers[17].hasher.S[1].t2[0]
|
||||
560,560,1,main.hashers[17].hasher.S[1].t2[1]
|
||||
561,561,1,main.hashers[17].hasher.S[1].t4[0]
|
||||
562,562,1,main.hashers[17].hasher.S[1].t4[1]
|
||||
563,563,1,main.hashers[17].hasher.S[1].xL[0]
|
||||
564,564,1,main.hashers[17].hasher.S[1].xR[0]
|
||||
565,565,3,main.hashers[18].hash
|
||||
566,566,3,main.hashers[18].left
|
||||
567,567,3,main.hashers[18].right
|
||||
568,568,2,main.hashers[18].hasher.outs[0]
|
||||
569,569,2,main.hashers[18].hasher.ins[0]
|
||||
570,570,2,main.hashers[18].hasher.ins[1]
|
||||
571,571,2,main.hashers[18].hasher.k
|
||||
572,572,1,main.hashers[18].hasher.S[0].xL_out
|
||||
573,573,1,main.hashers[18].hasher.S[0].xR_out
|
||||
574,574,1,main.hashers[18].hasher.S[0].xL_in
|
||||
575,575,1,main.hashers[18].hasher.S[0].xR_in
|
||||
576,576,1,main.hashers[18].hasher.S[0].k
|
||||
577,577,1,main.hashers[18].hasher.S[0].t2[0]
|
||||
578,578,1,main.hashers[18].hasher.S[0].t2[1]
|
||||
579,579,1,main.hashers[18].hasher.S[0].t4[0]
|
||||
580,580,1,main.hashers[18].hasher.S[0].t4[1]
|
||||
581,581,1,main.hashers[18].hasher.S[0].xL[0]
|
||||
582,582,1,main.hashers[18].hasher.S[0].xR[0]
|
||||
583,583,1,main.hashers[18].hasher.S[1].xL_out
|
||||
584,584,1,main.hashers[18].hasher.S[1].xR_out
|
||||
585,585,1,main.hashers[18].hasher.S[1].xL_in
|
||||
586,586,1,main.hashers[18].hasher.S[1].xR_in
|
||||
587,587,1,main.hashers[18].hasher.S[1].k
|
||||
588,588,1,main.hashers[18].hasher.S[1].t2[0]
|
||||
589,589,1,main.hashers[18].hasher.S[1].t2[1]
|
||||
590,590,1,main.hashers[18].hasher.S[1].t4[0]
|
||||
591,591,1,main.hashers[18].hasher.S[1].t4[1]
|
||||
592,592,1,main.hashers[18].hasher.S[1].xL[0]
|
||||
593,593,1,main.hashers[18].hasher.S[1].xR[0]
|
||||
594,594,3,main.hashers[19].hash
|
||||
595,595,3,main.hashers[19].left
|
||||
596,596,3,main.hashers[19].right
|
||||
597,597,2,main.hashers[19].hasher.outs[0]
|
||||
598,598,2,main.hashers[19].hasher.ins[0]
|
||||
599,599,2,main.hashers[19].hasher.ins[1]
|
||||
600,600,2,main.hashers[19].hasher.k
|
||||
601,601,1,main.hashers[19].hasher.S[0].xL_out
|
||||
602,602,1,main.hashers[19].hasher.S[0].xR_out
|
||||
603,603,1,main.hashers[19].hasher.S[0].xL_in
|
||||
604,604,1,main.hashers[19].hasher.S[0].xR_in
|
||||
605,605,1,main.hashers[19].hasher.S[0].k
|
||||
606,606,1,main.hashers[19].hasher.S[0].t2[0]
|
||||
607,607,1,main.hashers[19].hasher.S[0].t2[1]
|
||||
608,608,1,main.hashers[19].hasher.S[0].t4[0]
|
||||
609,609,1,main.hashers[19].hasher.S[0].t4[1]
|
||||
610,610,1,main.hashers[19].hasher.S[0].xL[0]
|
||||
611,611,1,main.hashers[19].hasher.S[0].xR[0]
|
||||
612,612,1,main.hashers[19].hasher.S[1].xL_out
|
||||
613,613,1,main.hashers[19].hasher.S[1].xR_out
|
||||
614,614,1,main.hashers[19].hasher.S[1].xL_in
|
||||
615,615,1,main.hashers[19].hasher.S[1].xR_in
|
||||
616,616,1,main.hashers[19].hasher.S[1].k
|
||||
617,617,1,main.hashers[19].hasher.S[1].t2[0]
|
||||
618,618,1,main.hashers[19].hasher.S[1].t2[1]
|
||||
619,619,1,main.hashers[19].hasher.S[1].t4[0]
|
||||
620,620,1,main.hashers[19].hasher.S[1].t4[1]
|
||||
621,621,1,main.hashers[19].hasher.S[1].xL[0]
|
||||
622,622,1,main.hashers[19].hasher.S[1].xR[0]
|
||||
623,623,0,main.selectors[0].outp[0]
|
||||
624,624,0,main.selectors[0].outp[1]
|
||||
625,625,0,main.selectors[0].inp[0]
|
||||
626,626,0,main.selectors[0].inp[1]
|
||||
627,627,0,main.selectors[0].s
|
||||
628,628,0,main.selectors[1].outp[0]
|
||||
629,629,0,main.selectors[1].outp[1]
|
||||
630,630,0,main.selectors[1].inp[0]
|
||||
631,631,0,main.selectors[1].inp[1]
|
||||
632,632,0,main.selectors[1].s
|
||||
633,633,0,main.selectors[2].outp[0]
|
||||
634,634,0,main.selectors[2].outp[1]
|
||||
635,635,0,main.selectors[2].inp[0]
|
||||
636,636,0,main.selectors[2].inp[1]
|
||||
637,637,0,main.selectors[2].s
|
||||
638,638,0,main.selectors[3].outp[0]
|
||||
639,639,0,main.selectors[3].outp[1]
|
||||
640,640,0,main.selectors[3].inp[0]
|
||||
641,641,0,main.selectors[3].inp[1]
|
||||
642,642,0,main.selectors[3].s
|
||||
643,643,0,main.selectors[4].outp[0]
|
||||
644,644,0,main.selectors[4].outp[1]
|
||||
645,645,0,main.selectors[4].inp[0]
|
||||
646,646,0,main.selectors[4].inp[1]
|
||||
647,647,0,main.selectors[4].s
|
||||
648,648,0,main.selectors[5].outp[0]
|
||||
649,649,0,main.selectors[5].outp[1]
|
||||
650,650,0,main.selectors[5].inp[0]
|
||||
651,651,0,main.selectors[5].inp[1]
|
||||
652,652,0,main.selectors[5].s
|
||||
653,653,0,main.selectors[6].outp[0]
|
||||
654,654,0,main.selectors[6].outp[1]
|
||||
655,655,0,main.selectors[6].inp[0]
|
||||
656,656,0,main.selectors[6].inp[1]
|
||||
657,657,0,main.selectors[6].s
|
||||
658,658,0,main.selectors[7].outp[0]
|
||||
659,659,0,main.selectors[7].outp[1]
|
||||
660,660,0,main.selectors[7].inp[0]
|
||||
661,661,0,main.selectors[7].inp[1]
|
||||
662,662,0,main.selectors[7].s
|
||||
663,663,0,main.selectors[8].outp[0]
|
||||
664,664,0,main.selectors[8].outp[1]
|
||||
665,665,0,main.selectors[8].inp[0]
|
||||
666,666,0,main.selectors[8].inp[1]
|
||||
667,667,0,main.selectors[8].s
|
||||
668,668,0,main.selectors[9].outp[0]
|
||||
669,669,0,main.selectors[9].outp[1]
|
||||
670,670,0,main.selectors[9].inp[0]
|
||||
671,671,0,main.selectors[9].inp[1]
|
||||
672,672,0,main.selectors[9].s
|
||||
673,673,0,main.selectors[10].outp[0]
|
||||
674,674,0,main.selectors[10].outp[1]
|
||||
675,675,0,main.selectors[10].inp[0]
|
||||
676,676,0,main.selectors[10].inp[1]
|
||||
677,677,0,main.selectors[10].s
|
||||
678,678,0,main.selectors[11].outp[0]
|
||||
679,679,0,main.selectors[11].outp[1]
|
||||
680,680,0,main.selectors[11].inp[0]
|
||||
681,681,0,main.selectors[11].inp[1]
|
||||
682,682,0,main.selectors[11].s
|
||||
683,683,0,main.selectors[12].outp[0]
|
||||
684,684,0,main.selectors[12].outp[1]
|
||||
685,685,0,main.selectors[12].inp[0]
|
||||
686,686,0,main.selectors[12].inp[1]
|
||||
687,687,0,main.selectors[12].s
|
||||
688,688,0,main.selectors[13].outp[0]
|
||||
689,689,0,main.selectors[13].outp[1]
|
||||
690,690,0,main.selectors[13].inp[0]
|
||||
691,691,0,main.selectors[13].inp[1]
|
||||
692,692,0,main.selectors[13].s
|
||||
693,693,0,main.selectors[14].outp[0]
|
||||
694,694,0,main.selectors[14].outp[1]
|
||||
695,695,0,main.selectors[14].inp[0]
|
||||
696,696,0,main.selectors[14].inp[1]
|
||||
697,697,0,main.selectors[14].s
|
||||
698,698,0,main.selectors[15].outp[0]
|
||||
699,699,0,main.selectors[15].outp[1]
|
||||
700,700,0,main.selectors[15].inp[0]
|
||||
701,701,0,main.selectors[15].inp[1]
|
||||
702,702,0,main.selectors[15].s
|
||||
703,703,0,main.selectors[16].outp[0]
|
||||
704,704,0,main.selectors[16].outp[1]
|
||||
705,705,0,main.selectors[16].inp[0]
|
||||
706,706,0,main.selectors[16].inp[1]
|
||||
707,707,0,main.selectors[16].s
|
||||
708,708,0,main.selectors[17].outp[0]
|
||||
709,709,0,main.selectors[17].outp[1]
|
||||
710,710,0,main.selectors[17].inp[0]
|
||||
711,711,0,main.selectors[17].inp[1]
|
||||
712,712,0,main.selectors[17].s
|
||||
713,713,0,main.selectors[18].outp[0]
|
||||
714,714,0,main.selectors[18].outp[1]
|
||||
715,715,0,main.selectors[18].inp[0]
|
||||
716,716,0,main.selectors[18].inp[1]
|
||||
717,717,0,main.selectors[18].s
|
||||
718,718,0,main.selectors[19].outp[0]
|
||||
719,719,0,main.selectors[19].outp[1]
|
||||
720,720,0,main.selectors[19].inp[0]
|
||||
721,721,0,main.selectors[19].inp[1]
|
||||
722,722,0,main.selectors[19].s
|
||||
@@ -66,4 +66,4 @@ template Withdraw(levels) {
|
||||
refundSquare <== refund * refund;
|
||||
}
|
||||
|
||||
component main = CommitmentHasher();
|
||||
component main = Withdraw(20);
|
||||
BIN
tornadocash_circuits/withdraw.r1cs
Normal file
BIN
tornadocash_circuits/withdraw.r1cs
Normal file
Binary file not shown.
Reference in New Issue
Block a user