@aztec/l1-artifacts 5.0.0-rc.2 → 5.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -17,7 +17,7 @@ uint256 constant NUMBER_UNSHIFTED = 36;
17
17
  uint256 constant NUMBER_TO_BE_SHIFTED = 5;
18
18
  uint256 constant PAIRING_POINTS_SIZE = 8;
19
19
 
20
- uint256 constant VK_HASH = 0x1c402774c68364f9d83168357306f0374fe1fa4703108a42119fc4438be58ccc;
20
+ uint256 constant VK_HASH = 0x2f0ca3e610369fc41f7fb8a69995a96428fbf69d7dffd2b576e63ba4d9511ee1;
21
21
  uint256 constant CIRCUIT_SIZE = 16777216;
22
22
  uint256 constant LOG_N = 24;
23
23
  uint256 constant NUMBER_PUBLIC_INPUTS = 119;
@@ -78,60 +78,60 @@ uint256 internal constant VK_NUM_PUBLIC_INPUTS_LOC = 0x1020;
78
78
  uint256 internal constant VK_PUB_INPUTS_OFFSET_LOC = 0x1040;
79
79
  uint256 internal constant Q_M_X_LOC = 0x1060;
80
80
  uint256 internal constant Q_M_Y_LOC = 0x1080;
81
- uint256 internal constant Q_C_X_LOC = 0x10a0;
82
- uint256 internal constant Q_C_Y_LOC = 0x10c0;
83
- uint256 internal constant Q_L_X_LOC = 0x10e0;
84
- uint256 internal constant Q_L_Y_LOC = 0x1100;
85
- uint256 internal constant Q_R_X_LOC = 0x1120;
86
- uint256 internal constant Q_R_Y_LOC = 0x1140;
87
- uint256 internal constant Q_O_X_LOC = 0x1160;
88
- uint256 internal constant Q_O_Y_LOC = 0x1180;
89
- uint256 internal constant Q_4_X_LOC = 0x11a0;
90
- uint256 internal constant Q_4_Y_LOC = 0x11c0;
91
- uint256 internal constant Q_LOOKUP_X_LOC = 0x11e0;
92
- uint256 internal constant Q_LOOKUP_Y_LOC = 0x1200;
93
- uint256 internal constant Q_ARITH_X_LOC = 0x1220;
94
- uint256 internal constant Q_ARITH_Y_LOC = 0x1240;
95
- uint256 internal constant Q_DELTA_RANGE_X_LOC = 0x1260;
96
- uint256 internal constant Q_DELTA_RANGE_Y_LOC = 0x1280;
97
- uint256 internal constant Q_ELLIPTIC_X_LOC = 0x12a0;
98
- uint256 internal constant Q_ELLIPTIC_Y_LOC = 0x12c0;
99
- uint256 internal constant Q_MEMORY_X_LOC = 0x12e0;
100
- uint256 internal constant Q_MEMORY_Y_LOC = 0x1300;
101
- uint256 internal constant Q_NNF_X_LOC = 0x1320;
102
- uint256 internal constant Q_NNF_Y_LOC = 0x1340;
103
- uint256 internal constant Q_POSEIDON_2_EXTERNAL_X_LOC = 0x1360;
104
- uint256 internal constant Q_POSEIDON_2_EXTERNAL_Y_LOC = 0x1380;
105
- uint256 internal constant Q_POSEIDON_2_INTERNAL_X_LOC = 0x13a0;
106
- uint256 internal constant Q_POSEIDON_2_INTERNAL_Y_LOC = 0x13c0;
107
- uint256 internal constant SIGMA_1_X_LOC = 0x13e0;
108
- uint256 internal constant SIGMA_1_Y_LOC = 0x1400;
109
- uint256 internal constant SIGMA_2_X_LOC = 0x1420;
110
- uint256 internal constant SIGMA_2_Y_LOC = 0x1440;
111
- uint256 internal constant SIGMA_3_X_LOC = 0x1460;
112
- uint256 internal constant SIGMA_3_Y_LOC = 0x1480;
113
- uint256 internal constant SIGMA_4_X_LOC = 0x14a0;
114
- uint256 internal constant SIGMA_4_Y_LOC = 0x14c0;
115
- uint256 internal constant ID_1_X_LOC = 0x14e0;
116
- uint256 internal constant ID_1_Y_LOC = 0x1500;
117
- uint256 internal constant ID_2_X_LOC = 0x1520;
118
- uint256 internal constant ID_2_Y_LOC = 0x1540;
119
- uint256 internal constant ID_3_X_LOC = 0x1560;
120
- uint256 internal constant ID_3_Y_LOC = 0x1580;
121
- uint256 internal constant ID_4_X_LOC = 0x15a0;
122
- uint256 internal constant ID_4_Y_LOC = 0x15c0;
123
- uint256 internal constant TABLE_1_X_LOC = 0x15e0;
124
- uint256 internal constant TABLE_1_Y_LOC = 0x1600;
125
- uint256 internal constant TABLE_2_X_LOC = 0x1620;
126
- uint256 internal constant TABLE_2_Y_LOC = 0x1640;
127
- uint256 internal constant TABLE_3_X_LOC = 0x1660;
128
- uint256 internal constant TABLE_3_Y_LOC = 0x1680;
129
- uint256 internal constant TABLE_4_X_LOC = 0x16a0;
130
- uint256 internal constant TABLE_4_Y_LOC = 0x16c0;
131
- uint256 internal constant LAGRANGE_FIRST_X_LOC = 0x16e0;
132
- uint256 internal constant LAGRANGE_FIRST_Y_LOC = 0x1700;
133
- uint256 internal constant LAGRANGE_LAST_X_LOC = 0x1720;
134
- uint256 internal constant LAGRANGE_LAST_Y_LOC = 0x1740;
81
+ uint256 internal constant Q_L_X_LOC = 0x10a0;
82
+ uint256 internal constant Q_L_Y_LOC = 0x10c0;
83
+ uint256 internal constant Q_R_X_LOC = 0x10e0;
84
+ uint256 internal constant Q_R_Y_LOC = 0x1100;
85
+ uint256 internal constant Q_O_X_LOC = 0x1120;
86
+ uint256 internal constant Q_O_Y_LOC = 0x1140;
87
+ uint256 internal constant Q_4_X_LOC = 0x1160;
88
+ uint256 internal constant Q_4_Y_LOC = 0x1180;
89
+ uint256 internal constant Q_C_X_LOC = 0x11a0;
90
+ uint256 internal constant Q_C_Y_LOC = 0x11c0;
91
+ uint256 internal constant Q_ARITH_X_LOC = 0x11e0;
92
+ uint256 internal constant Q_ARITH_Y_LOC = 0x1200;
93
+ uint256 internal constant SIGMA_1_X_LOC = 0x1220;
94
+ uint256 internal constant SIGMA_1_Y_LOC = 0x1240;
95
+ uint256 internal constant SIGMA_2_X_LOC = 0x1260;
96
+ uint256 internal constant SIGMA_2_Y_LOC = 0x1280;
97
+ uint256 internal constant SIGMA_3_X_LOC = 0x12a0;
98
+ uint256 internal constant SIGMA_3_Y_LOC = 0x12c0;
99
+ uint256 internal constant SIGMA_4_X_LOC = 0x12e0;
100
+ uint256 internal constant SIGMA_4_Y_LOC = 0x1300;
101
+ uint256 internal constant ID_1_X_LOC = 0x1320;
102
+ uint256 internal constant ID_1_Y_LOC = 0x1340;
103
+ uint256 internal constant ID_2_X_LOC = 0x1360;
104
+ uint256 internal constant ID_2_Y_LOC = 0x1380;
105
+ uint256 internal constant ID_3_X_LOC = 0x13a0;
106
+ uint256 internal constant ID_3_Y_LOC = 0x13c0;
107
+ uint256 internal constant ID_4_X_LOC = 0x13e0;
108
+ uint256 internal constant ID_4_Y_LOC = 0x1400;
109
+ uint256 internal constant LAGRANGE_FIRST_X_LOC = 0x1420;
110
+ uint256 internal constant LAGRANGE_FIRST_Y_LOC = 0x1440;
111
+ uint256 internal constant LAGRANGE_LAST_X_LOC = 0x1460;
112
+ uint256 internal constant LAGRANGE_LAST_Y_LOC = 0x1480;
113
+ uint256 internal constant Q_LOOKUP_X_LOC = 0x14a0;
114
+ uint256 internal constant Q_LOOKUP_Y_LOC = 0x14c0;
115
+ uint256 internal constant TABLE_1_X_LOC = 0x14e0;
116
+ uint256 internal constant TABLE_1_Y_LOC = 0x1500;
117
+ uint256 internal constant TABLE_2_X_LOC = 0x1520;
118
+ uint256 internal constant TABLE_2_Y_LOC = 0x1540;
119
+ uint256 internal constant TABLE_3_X_LOC = 0x1560;
120
+ uint256 internal constant TABLE_3_Y_LOC = 0x1580;
121
+ uint256 internal constant TABLE_4_X_LOC = 0x15a0;
122
+ uint256 internal constant TABLE_4_Y_LOC = 0x15c0;
123
+ uint256 internal constant Q_DELTA_RANGE_X_LOC = 0x15e0;
124
+ uint256 internal constant Q_DELTA_RANGE_Y_LOC = 0x1600;
125
+ uint256 internal constant Q_ELLIPTIC_X_LOC = 0x1620;
126
+ uint256 internal constant Q_ELLIPTIC_Y_LOC = 0x1640;
127
+ uint256 internal constant Q_MEMORY_X_LOC = 0x1660;
128
+ uint256 internal constant Q_MEMORY_Y_LOC = 0x1680;
129
+ uint256 internal constant Q_NNF_X_LOC = 0x16a0;
130
+ uint256 internal constant Q_NNF_Y_LOC = 0x16c0;
131
+ uint256 internal constant Q_POSEIDON_2_EXTERNAL_X_LOC = 0x16e0;
132
+ uint256 internal constant Q_POSEIDON_2_EXTERNAL_Y_LOC = 0x1700;
133
+ uint256 internal constant Q_POSEIDON_2_INTERNAL_X_LOC = 0x1720;
134
+ uint256 internal constant Q_POSEIDON_2_INTERNAL_Y_LOC = 0x1740;
135
135
 
136
136
  /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/
137
137
  /* PROOF INDICIES */
@@ -360,34 +360,34 @@ uint256 internal constant SUMCHECK_UNIVARIATE_23_7_LOC = 0x3240;
360
360
  /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/
361
361
  /* PROOF INDICIES - SUMCHECK EVALUATIONS */
362
362
  /*.•°:°.´+˚.*°.˚:*.´•*.+°.•°:´*.´•*.•°.•°:°.´:•˚°.*°.˚:*.´+°.•*/
363
- uint256 internal constant QM_EVAL_LOC = 0x3260;
364
- uint256 internal constant QC_EVAL_LOC = 0x3280;
365
- uint256 internal constant QL_EVAL_LOC = 0x32a0;
366
- uint256 internal constant QR_EVAL_LOC = 0x32c0;
367
- uint256 internal constant QO_EVAL_LOC = 0x32e0;
368
- uint256 internal constant Q4_EVAL_LOC = 0x3300;
369
- uint256 internal constant QLOOKUP_EVAL_LOC = 0x3320;
370
- uint256 internal constant QARITH_EVAL_LOC = 0x3340;
371
- uint256 internal constant QRANGE_EVAL_LOC = 0x3360;
372
- uint256 internal constant QELLIPTIC_EVAL_LOC = 0x3380;
373
- uint256 internal constant QMEMORY_EVAL_LOC = 0x33a0;
374
- uint256 internal constant QNNF_EVAL_LOC = 0x33c0;
375
- uint256 internal constant QPOSEIDON2_EXTERNAL_EVAL_LOC = 0x33e0;
376
- uint256 internal constant QPOSEIDON2_INTERNAL_EVAL_LOC = 0x3400;
377
- uint256 internal constant SIGMA1_EVAL_LOC = 0x3420;
378
- uint256 internal constant SIGMA2_EVAL_LOC = 0x3440;
379
- uint256 internal constant SIGMA3_EVAL_LOC = 0x3460;
380
- uint256 internal constant SIGMA4_EVAL_LOC = 0x3480;
381
- uint256 internal constant ID1_EVAL_LOC = 0x34a0;
382
- uint256 internal constant ID2_EVAL_LOC = 0x34c0;
383
- uint256 internal constant ID3_EVAL_LOC = 0x34e0;
384
- uint256 internal constant ID4_EVAL_LOC = 0x3500;
385
- uint256 internal constant TABLE1_EVAL_LOC = 0x3520;
386
- uint256 internal constant TABLE2_EVAL_LOC = 0x3540;
387
- uint256 internal constant TABLE3_EVAL_LOC = 0x3560;
388
- uint256 internal constant TABLE4_EVAL_LOC = 0x3580;
389
- uint256 internal constant LAGRANGE_FIRST_EVAL_LOC = 0x35a0;
390
- uint256 internal constant LAGRANGE_LAST_EVAL_LOC = 0x35c0;
363
+ uint256 internal constant SIGMA1_EVAL_LOC = 0x3260;
364
+ uint256 internal constant SIGMA2_EVAL_LOC = 0x3280;
365
+ uint256 internal constant SIGMA3_EVAL_LOC = 0x32a0;
366
+ uint256 internal constant SIGMA4_EVAL_LOC = 0x32c0;
367
+ uint256 internal constant ID1_EVAL_LOC = 0x32e0;
368
+ uint256 internal constant ID2_EVAL_LOC = 0x3300;
369
+ uint256 internal constant ID3_EVAL_LOC = 0x3320;
370
+ uint256 internal constant ID4_EVAL_LOC = 0x3340;
371
+ uint256 internal constant LAGRANGE_FIRST_EVAL_LOC = 0x3360;
372
+ uint256 internal constant LAGRANGE_LAST_EVAL_LOC = 0x3380;
373
+ uint256 internal constant QLOOKUP_EVAL_LOC = 0x33a0;
374
+ uint256 internal constant TABLE1_EVAL_LOC = 0x33c0;
375
+ uint256 internal constant TABLE2_EVAL_LOC = 0x33e0;
376
+ uint256 internal constant TABLE3_EVAL_LOC = 0x3400;
377
+ uint256 internal constant TABLE4_EVAL_LOC = 0x3420;
378
+ uint256 internal constant QM_EVAL_LOC = 0x3440;
379
+ uint256 internal constant QR_EVAL_LOC = 0x3460;
380
+ uint256 internal constant QO_EVAL_LOC = 0x3480;
381
+ uint256 internal constant QC_EVAL_LOC = 0x34a0;
382
+ uint256 internal constant QL_EVAL_LOC = 0x34c0;
383
+ uint256 internal constant Q4_EVAL_LOC = 0x34e0;
384
+ uint256 internal constant QARITH_EVAL_LOC = 0x3500;
385
+ uint256 internal constant QRANGE_EVAL_LOC = 0x3520;
386
+ uint256 internal constant QELLIPTIC_EVAL_LOC = 0x3540;
387
+ uint256 internal constant QMEMORY_EVAL_LOC = 0x3560;
388
+ uint256 internal constant QNNF_EVAL_LOC = 0x3580;
389
+ uint256 internal constant QPOSEIDON2_EXTERNAL_EVAL_LOC = 0x35a0;
390
+ uint256 internal constant QPOSEIDON2_INTERNAL_EVAL_LOC = 0x35c0;
391
391
  uint256 internal constant W1_EVAL_LOC = 0x35e0;
392
392
  uint256 internal constant W2_EVAL_LOC = 0x3600;
393
393
  uint256 internal constant W3_EVAL_LOC = 0x3620;
@@ -1526,62 +1526,62 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
1526
1526
  //
1527
1527
  // Although defined at the top of the file, it is used towards the end of the algorithm when batching in the commitment scheme.
1528
1528
  function loadVk() {
1529
- mstore(Q_L_X_LOC, 0x0844b1f3f3ce523797bb577ea51468cb4c10fd5bb6e8cc8bad59e5b329a2ca4b)
1530
- mstore(Q_L_Y_LOC, 0x2c693f1c6dd1466abf98cd0a54411c003aafdc00eb7669d16569f688bbfae0f2)
1531
- mstore(Q_R_X_LOC, 0x2457f224793f587f9d88552d60380525cbc85364fdeab006874ba6aafeb75504)
1532
- mstore(Q_R_Y_LOC, 0x18301d1e25236e63fc381dac17b71f1d9fa6b6b654fc3dd708516e6ee570b39a)
1533
- mstore(Q_O_X_LOC, 0x0f64e72f336059481b931cada45906ae6bf19001302e61dd87ee1434b17ae65b)
1534
- mstore(Q_O_Y_LOC, 0x247950df9838e335aa2c476e9194d14400acb3a7e2332579c1c3ac03c6c69341)
1535
- mstore(Q_4_X_LOC, 0x0913769450d27fea234542b3c947608f5b6d4d6168192fe0f86232c9dc840fbd)
1536
- mstore(Q_4_Y_LOC, 0x0191bee6eef9340533ab68524eff56037a790668e6298146b183de4aa46884c9)
1537
- mstore(Q_M_X_LOC, 0x1c14e5f21402e0d686de60e6a229098ed9bcb1ed7025185a9dafafe184f1b301)
1538
- mstore(Q_M_Y_LOC, 0x1851649a1b3caf8690c252223335c2534d35e25657aafad2a5faa7eee0513d52)
1539
- mstore(Q_C_X_LOC, 0x0d3c36041b2944a2b520c93fc0c195213044048586d4ba62f1d9e36e9b4b97cc)
1540
- mstore(Q_C_Y_LOC, 0x18933b3c2a7bd010776cce9ae2c673e2834f19b01e30abeb33daaa1c719368ad)
1529
+ mstore(Q_L_X_LOC, 0x017a8a0cf3a397ce7756b794ce207dfc776a84b4840c200af82743eed57509bd)
1530
+ mstore(Q_L_Y_LOC, 0x000b1d68189c34958a2e13a63481f8d87bf370138c46a761aaca8a173b03a9d3)
1531
+ mstore(Q_R_X_LOC, 0x1198ceb6897eb5bf185382fd9db5f67c2f42beacab00de0dd999afe5c34ec7db)
1532
+ mstore(Q_R_Y_LOC, 0x1bc9c3e7c7b553aa0249bb5d30a789fdd8adb9f851b27a22a5ee184a7a254692)
1533
+ mstore(Q_O_X_LOC, 0x0557105248ea360bb0f11dbd5caad011fa37dd5ecb7df2f8b18513e3c5098a07)
1534
+ mstore(Q_O_Y_LOC, 0x096c3a3df86035e547d418dc08af89b5a97f4458eecc857f65bb0963b50f9970)
1535
+ mstore(Q_4_X_LOC, 0x0cb7f4d0baab55a4cc5569f75f4bd17576c9c763df44fffff4e1a0ef48295f19)
1536
+ mstore(Q_4_Y_LOC, 0x12b85145d1912e2993f1ce6553b9950eb3cf84e90cf3dcab20f007f4f191589d)
1537
+ mstore(Q_M_X_LOC, 0x2d8a0a581ac18e6939e7e7af80a7d540d1f620e7177df74fe24f558c7b104557)
1538
+ mstore(Q_M_Y_LOC, 0x1fe4782c8244ea17f5f19997f0725e650ac023119d3aecfbee4db3f93ea1ba1c)
1539
+ mstore(Q_C_X_LOC, 0x1c8a93c71eba79121c4d0272d5a4140a36c40be7bf7c7640eb5b6aede0c4e82e)
1540
+ mstore(Q_C_Y_LOC, 0x1cf91310860fabc4e9198abdaa7b3ed64b4b9fb67cc63b5adc6ca2bcbd3253c1)
1541
1541
  mstore(Q_LOOKUP_X_LOC, 0x240c61ca01a9d4825953d57fb86faac15533fc645dae5893626b1720bef4c8f6)
1542
1542
  mstore(Q_LOOKUP_Y_LOC, 0x2a4c84ccc7881879778269b15736cf76a4068b1d3bb0e280ebe63a7842508c49)
1543
- mstore(Q_ARITH_X_LOC, 0x01aef7fd8603861d3b6ea731e0bfab11344e17324daef70786e6a3f6d71d9104)
1544
- mstore(Q_ARITH_Y_LOC, 0x0c70fef890848c4bbb1353da54a284da94d0d1968aa91dd599fcbffd5f811546)
1545
- mstore(Q_DELTA_RANGE_X_LOC, 0x03862f8cd5397ab376e3cb558cf7c2e391fd96784b50035407a1e8ebb59674c8)
1546
- mstore(Q_DELTA_RANGE_Y_LOC, 0x25b20c02a03cda43d502efb8d921b40cadb66e902bff6398ee6f7eb2cebb46c5)
1547
- mstore(Q_ELLIPTIC_X_LOC, 0x21c4290e2e7bf809270d2bf1f25fd6d73c05c39604f3338b7c866f73b8abdf54)
1548
- mstore(Q_ELLIPTIC_Y_LOC, 0x2a0ffacf11be4e07dc09c5ecc172480a5253c7c2c8b14b18122b70b1cfd846ea)
1549
- mstore(Q_MEMORY_X_LOC, 0x1c873d2216343667a387315a6fd881950e4b65c7b8595044265ac13f3b0fee09)
1550
- mstore(Q_MEMORY_Y_LOC, 0x08f32e99247087ae0b20496c02eed72460f1297c28b5f7d2554bb3b42169ea9f)
1551
- mstore(Q_NNF_X_LOC, 0x16773c9df74718089426ef16c4d717e0d875be1958b4b955815b2cac852b3aa2)
1552
- mstore(Q_NNF_Y_LOC, 0x0947b7debc76cf8f6dc6bbeb6678babdb48f80085c660c64cdb55e274d7f59bd)
1553
- mstore(Q_POSEIDON_2_EXTERNAL_X_LOC, 0x2cd9a5e1d4f75dc6e8990f58907d3d6a0fd45c5cd67297e642a13ae6077e26b5)
1554
- mstore(Q_POSEIDON_2_EXTERNAL_Y_LOC, 0x0c6fb3260de474eea2e25ec5fa92c73fc441060748d7dcc81578e4ff6ff94c1e)
1555
- mstore(Q_POSEIDON_2_INTERNAL_X_LOC, 0x0c6ea0af2a059dc6abca89b67b923a9663f1a3a2030dda597b502690cb881a57)
1556
- mstore(Q_POSEIDON_2_INTERNAL_Y_LOC, 0x0f6a9dce00826bcb1310e0d8bb406e5ac3e009f98f92044784130e661c31c200)
1557
- mstore(SIGMA_1_X_LOC, 0x12cabe8e354b8012d06c309f627f9b596d1bb452a16931a3accfe65f89f3d7fd)
1558
- mstore(SIGMA_1_Y_LOC, 0x22f8f5e6c7cccbe668e0ba05a9eb602016f160d14bf48ead1a26d9da65032473)
1559
- mstore(SIGMA_2_X_LOC, 0x07648f07e65ecbfcf76e1a7ae2022f51fc76fed9e09cc598e5e8aa8c98fbd0aa)
1560
- mstore(SIGMA_2_Y_LOC, 0x041725ac06e8d7f597b4d4211736769e05e5a9c9d779cfa5616fb2f5270fb59d)
1561
- mstore(SIGMA_3_X_LOC, 0x22b86ed214beeb1a8501da509ecb31f0cf63eb11a0b27149ec13996616e4e066)
1562
- mstore(SIGMA_3_Y_LOC, 0x15e8b1597f3cde47479cbc2846cf89b182f40f441326cd9fcf100be52842bf0c)
1563
- mstore(SIGMA_4_X_LOC, 0x283c608bf43a14ead3a28db66f157315b42cc5c213afe615fbfd76594a41468c)
1564
- mstore(SIGMA_4_Y_LOC, 0x068e68a714f68dc7a73be9d122836c35c822b0cd905f8ac7bc9235a98e5b7c50)
1543
+ mstore(Q_ARITH_X_LOC, 0x1d6762984350fdc556daef887e843d0c48ad9b6abba6bb7a32daadfafba9e3d7)
1544
+ mstore(Q_ARITH_Y_LOC, 0x0bea8022cae52ea805ea2453efbf696a9b8a346fc98b496c8dc245fe9ac62591)
1545
+ mstore(Q_DELTA_RANGE_X_LOC, 0x1cf67109fd502f661c92fdb1f4f73b6a1068bf5f0bab6ce2d606fbccbfff1d22)
1546
+ mstore(Q_DELTA_RANGE_Y_LOC, 0x05311ac817e970a0d2b9f8300bb5928a7bfdf95ed29b2f1da5ba08185fc3da86)
1547
+ mstore(Q_ELLIPTIC_X_LOC, 0x0ec16681196c2d137b00078695601906af1c60a47f04f75c26224256e9e0963e)
1548
+ mstore(Q_ELLIPTIC_Y_LOC, 0x1a2a0528b7d4c19adfcc974fa0531311a7e7934d65798705582eb5fcd42dded1)
1549
+ mstore(Q_MEMORY_X_LOC, 0x20588c1fa5935f23278d006804a78fb7830b4609665b901291dae8588ed8891f)
1550
+ mstore(Q_MEMORY_Y_LOC, 0x24f783d3b24e1d26712bf598f580deae90ef70ec78b097e10612e1b162f2bff9)
1551
+ mstore(Q_NNF_X_LOC, 0x149d8ac87dc66f73f91d298c338332cc2015b4b79bc7a960fa9176c463da2704)
1552
+ mstore(Q_NNF_Y_LOC, 0x07bd36e609f9c695ae51065a0ac0dc2d601c1fcb771f7767b012b0fce84646b5)
1553
+ mstore(Q_POSEIDON_2_EXTERNAL_X_LOC, 0x1a91ab71218d3010556e443c181471fcf83e00a3cc81f944259037777b212a9f)
1554
+ mstore(Q_POSEIDON_2_EXTERNAL_Y_LOC, 0x2af8ae980d3fd0fde23ffef59b1a4d991375b850c5a9463867453a7cd3850ee0)
1555
+ mstore(Q_POSEIDON_2_INTERNAL_X_LOC, 0x02cc26c0ce63be81d3f53b06aaa90cfac5b1cfc925b25a835af9369dca819ae0)
1556
+ mstore(Q_POSEIDON_2_INTERNAL_Y_LOC, 0x02d94c7a87d26c97a92d67ab0f6bb320a11a65a9129431d5dce11e3aa37ad700)
1557
+ mstore(SIGMA_1_X_LOC, 0x1d48dccf1c179d23528264773bfc39ee28b9f91ac57eb242a2fad7d721b21393)
1558
+ mstore(SIGMA_1_Y_LOC, 0x0e77686b0597e42ca7293b93a15d654e57c75053abe0bec01789cf633f26ebb5)
1559
+ mstore(SIGMA_2_X_LOC, 0x0f9b447eeb4285e715dbdc8d42f2f856165f666cd9720b7c772291d2d3563803)
1560
+ mstore(SIGMA_2_Y_LOC, 0x157423173855e0b30e65b033bfd06fe6e660ac6123f6f7b4d38eae12a7175241)
1561
+ mstore(SIGMA_3_X_LOC, 0x28919740422e36ab96f10f2559851daf51c9a7cb0e77a49cfc4fd9af501d7789)
1562
+ mstore(SIGMA_3_Y_LOC, 0x21f2abf738927e842de9363f1b9b4718f9ea8de517a1241bcad3681a4acde43f)
1563
+ mstore(SIGMA_4_X_LOC, 0x0d29ed188cf2ba817d1d0f41533b08c1f92aecca31052637c6220774d83c760e)
1564
+ mstore(SIGMA_4_Y_LOC, 0x0b8ed0ab98b1236524380a8fce7b75a9bb84ea8e7d3f27bdb61903a40ea41337)
1565
1565
  mstore(TABLE_1_X_LOC, 0x290fb60f4114fa50e92897a66d9a86b7e1c60e6f84a4df2dc1d020da1537bab8)
1566
1566
  mstore(TABLE_1_Y_LOC, 0x087bcd143b8021cae339bd062d6d837a34a3a502e6eaf2326a765d0703d31c01)
1567
1567
  mstore(TABLE_2_X_LOC, 0x22e84aa48f8510653f8f7b7c9c8fa3ab838de294018587a7587990e0b1f92e8d)
1568
1568
  mstore(TABLE_2_Y_LOC, 0x0ed854b35b0c13c96ef3b3071676b3524a1aa3fb28791d3d908840a5d1765872)
1569
1569
  mstore(TABLE_3_X_LOC, 0x2be3b503e1119c1b4d7545a1ac3b10b9f82ed04da805bd4242f30aac7a03b8f8)
1570
1570
  mstore(TABLE_3_Y_LOC, 0x0f45d075a4f5045b58c0084bf7abac45fd1def643fb0dc0479d534c0afa1a371)
1571
- mstore(TABLE_4_X_LOC, 0x0062938b54cd25ea97caa7befde407ef00ac024bf57a0233cd9f788547efc978)
1572
- mstore(TABLE_4_Y_LOC, 0x14a352f69b14198e8aaca710b488491bdd80cad250f91480d9f8088917298e85)
1573
- mstore(ID_1_X_LOC, 0x2950b38ce225ab1bfc3362e32a60e49647d3f6ccc9a9b7963882bedf92e13f26)
1574
- mstore(ID_1_Y_LOC, 0x20830060a9d49506960606484e96d2a9d62d8bb3ac9a011be374b03812d086d7)
1575
- mstore(ID_2_X_LOC, 0x1a4ee85adfff14c0941293da3441c2460f50e121df7d86879dc9987ae9acfb20)
1576
- mstore(ID_2_Y_LOC, 0x141949e0b9987380fd71215d58b26b61e4f9d2b1c6262903b2694c65664719ca)
1577
- mstore(ID_3_X_LOC, 0x190b134ce69a49ea61c6bf36e322a4a92ed1e6f58032919b13ae10f61b09e67b)
1578
- mstore(ID_3_Y_LOC, 0x1bd6d25a2657fee7c36d4d15c65306c012bc3825f769eacac9c8c7ede39c6e59)
1579
- mstore(ID_4_X_LOC, 0x013779e17b748fcf14f7dac626e74f2f58db4798ff6ccac71f3f22ac8ca7377f)
1580
- mstore(ID_4_Y_LOC, 0x22fc1eabda6370b0a48acd4e1c3563da250eee43c12e1c42de0e5b2de155d1a0)
1571
+ mstore(TABLE_4_X_LOC, 0x2b4d0112219c6226700ca100a7d27041173ba6ae9f0dcd977df77401d7024afe)
1572
+ mstore(TABLE_4_Y_LOC, 0x2da309999fbd4c76c28ddde2da2b34231b220013cbab34646c4ea3009fc10ac9)
1573
+ mstore(ID_1_X_LOC, 0x29f14e4c60fd58035b68f2be26a5dcea1c3ad5fc3868d993adeddcac9498050b)
1574
+ mstore(ID_1_Y_LOC, 0x19a254472a10d0e40e4fead233818b6de94b4fcab014024a76ce3264002edefa)
1575
+ mstore(ID_2_X_LOC, 0x1ade6820202a78e54d0cb4efa6d2bd5f4adcdeb540846a592e36fc63c70cff1b)
1576
+ mstore(ID_2_Y_LOC, 0x05ab5d398f3133326f329ae0f879278a66e69e81b196e237783c473c9d1303c5)
1577
+ mstore(ID_3_X_LOC, 0x00b123a85cfe234991ef02f69b53f3c9883b6ac538882dcbbbb5a0f12b6e92c3)
1578
+ mstore(ID_3_Y_LOC, 0x2ae7702684c2041e013b0ac1c8262ed40a191492f9faee8603bfe9ed903a426e)
1579
+ mstore(ID_4_X_LOC, 0x01a83b27ff04eace4c79d9e60dc762b5781968d615a57436286379c83e4260fa)
1580
+ mstore(ID_4_Y_LOC, 0x2771df16d8b5458b2820a44053f1f7f994ca87a927ed7282a71730c80e759ed9)
1581
1581
  mstore(LAGRANGE_FIRST_X_LOC, 0x2a56ce41f6b0be13b9c26747621b821eee81b23a887f299049b14c11e98460d6)
1582
1582
  mstore(LAGRANGE_FIRST_Y_LOC, 0x1aa98f2de3ddda547d8f6de4e725ded5827d6338c78656c0d12ca1aea6ef2c7c)
1583
- mstore(LAGRANGE_LAST_X_LOC, 0x23f14331c966aabdf52b2e46388e79258c53970b38c3e092db579a3af155b5e8)
1584
- mstore(LAGRANGE_LAST_Y_LOC, 0x23b0b07bbfb0d652b8a36f5355ec5d0117dafc86b0becca758ae1622cd4689a6)
1583
+ mstore(LAGRANGE_LAST_X_LOC, 0x1786179d723e6f94e6b65beec4a94e2cb1f36946e74d70b4e186ca051e8c2b16)
1584
+ mstore(LAGRANGE_LAST_Y_LOC, 0x132ed90a46a33fbf9d0748162a877c8e6a0428d714bae03ce03d8847ab10b844)
1585
1585
  }
1586
1586
 
1587
1587
  // Prime field order - placing on the stack
@@ -1835,7 +1835,7 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
1835
1835
  // 8 points are sent as it is enough to uniquely identify the polynomial
1836
1836
  let read_off := SUMCHECK_UNIVARIATE_0_0_LOC
1837
1837
  let write_off := SUM_U_CHALLENGE_0
1838
- for {} lt(read_off, QM_EVAL_LOC) {} {
1838
+ for {} lt(read_off, SIGMA1_EVAL_LOC) {} {
1839
1839
  // Increase by 20 * batched relation length (8)
1840
1840
  // 0x20 * 0x8 = 0x100
1841
1841
  mcopy(0x20, read_off, 0x100)
@@ -1900,7 +1900,7 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
1900
1900
  //
1901
1901
  // Hash of all of the above evaluations
1902
1902
  // Number of bytes to copy = 0x20 * NUMBER_OF_ENTITIES (41) = 0x520
1903
- mcopy(0x20, QM_EVAL_LOC, 0x520)
1903
+ mcopy(0x20, SIGMA1_EVAL_LOC, 0x520)
1904
1904
  prev_challenge := mod(keccak256(0x00, 0x540), p)
1905
1905
  mstore(0x00, prev_challenge)
1906
1906
 
@@ -3487,12 +3487,12 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
3487
3487
  let contribution_0 :=
3488
3488
  addmod(identity, mulmod(addmod(q_arith, sub(p, 1), p), mload(W4_SHIFT_EVAL_LOC), p), p)
3489
3489
  contribution_0 := mulmod(mulmod(contribution_0, q_arith, p), mload(POW_PARTIAL_EVALUATION_LOC), p)
3490
- mstore(SUBRELATION_EVAL_0_LOC, contribution_0)
3490
+ mstore(SUBRELATION_EVAL_6_LOC, contribution_0)
3491
3491
 
3492
3492
  let contribution_1 := mulmod(extra_small_addition_gate_identity, addmod(q_arith, sub(p, 1), p), p)
3493
3493
  contribution_1 := mulmod(contribution_1, q_arith, p)
3494
3494
  contribution_1 := mulmod(contribution_1, mload(POW_PARTIAL_EVALUATION_LOC), p)
3495
- mstore(SUBRELATION_EVAL_1_LOC, contribution_1)
3495
+ mstore(SUBRELATION_EVAL_7_LOC, contribution_1)
3496
3496
  }
3497
3497
 
3498
3498
  /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/
@@ -3561,14 +3561,14 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
3561
3561
  )
3562
3562
 
3563
3563
  acc := mulmod(acc, mload(POW_PARTIAL_EVALUATION_LOC), p)
3564
- mstore(SUBRELATION_EVAL_2_LOC, acc)
3564
+ mstore(SUBRELATION_EVAL_0_LOC, acc)
3565
3565
 
3566
3566
  acc := mulmod(
3567
3567
  mulmod(mload(LAGRANGE_LAST_EVAL_LOC), mload(Z_PERM_SHIFT_EVAL_LOC), p),
3568
3568
  mload(POW_PARTIAL_EVALUATION_LOC),
3569
3569
  p
3570
3570
  )
3571
- mstore(SUBRELATION_EVAL_3_LOC, acc)
3571
+ mstore(SUBRELATION_EVAL_1_LOC, acc)
3572
3572
  }
3573
3573
 
3574
3574
  // Contribution 4: z_perm initialization (lagrange_first * z_perm = 0)
@@ -3578,7 +3578,7 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
3578
3578
  mload(POW_PARTIAL_EVALUATION_LOC),
3579
3579
  p
3580
3580
  )
3581
- mstore(SUBRELATION_EVAL_4_LOC, acc)
3581
+ mstore(SUBRELATION_EVAL_2_LOC, acc)
3582
3582
  }
3583
3583
  }
3584
3584
 
@@ -3643,9 +3643,9 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
3643
3643
  let read_tag_boolean_relation := mulmod(read_tag, addmod(read_tag, sub(p, 1), p), p)
3644
3644
  read_tag_boolean_relation := mulmod(read_tag_boolean_relation, mload(POW_PARTIAL_EVALUATION_LOC), p)
3645
3645
 
3646
- mstore(SUBRELATION_EVAL_5_LOC, accumulator_none)
3647
- mstore(SUBRELATION_EVAL_6_LOC, accumulator_one)
3648
- mstore(SUBRELATION_EVAL_7_LOC, read_tag_boolean_relation)
3646
+ mstore(SUBRELATION_EVAL_3_LOC, accumulator_none)
3647
+ mstore(SUBRELATION_EVAL_4_LOC, accumulator_one)
3648
+ mstore(SUBRELATION_EVAL_5_LOC, read_tag_boolean_relation)
3649
3649
  }
3650
3650
 
3651
3651
  /*´:°•.°+.*•´.*:˚.°*.˚•´.°:°•.°•.*•´.*:˚.°*.˚•´.°:°•.°+.*•´.*:*/
@@ -4567,165 +4567,147 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
4567
4567
  // mem.batchingChallenge = mem.batchingChallenge * tp.rho;
4568
4568
  // }
4569
4569
 
4570
- // Calculate the scalars and batching challenge for the unshifted entities
4571
- // 0: QM_EVAL_LOC
4570
+ // Iteration order matches UltraFlavor_Generated::EntityId. Scalar slot N = entity index N + 1
4571
+ // pairs with vk[N] in the batchMul block below.
4572
+
4573
+ // 0: SIGMA1_EVAL_LOC
4572
4574
  mstore(BATCH_SCALAR_1_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4573
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QM_EVAL_LOC), batching_challenge, p), p)
4575
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(SIGMA1_EVAL_LOC), batching_challenge, p), p)
4574
4576
  batching_challenge := mulmod(batching_challenge, rho, p)
4575
4577
 
4576
- // 1: QC_EVAL_LOC
4578
+ // 1: SIGMA2_EVAL_LOC
4577
4579
  mstore(BATCH_SCALAR_2_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4578
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QC_EVAL_LOC), batching_challenge, p), p)
4580
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(SIGMA2_EVAL_LOC), batching_challenge, p), p)
4579
4581
  batching_challenge := mulmod(batching_challenge, rho, p)
4580
4582
 
4581
- // 2: QL_EVAL_LOC
4583
+ // 2: SIGMA3_EVAL_LOC
4582
4584
  mstore(BATCH_SCALAR_3_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4583
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QL_EVAL_LOC), batching_challenge, p), p)
4585
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(SIGMA3_EVAL_LOC), batching_challenge, p), p)
4584
4586
  batching_challenge := mulmod(batching_challenge, rho, p)
4585
4587
 
4586
- // 3: QR_EVAL_LOC
4588
+ // 3: SIGMA4_EVAL_LOC
4587
4589
  mstore(BATCH_SCALAR_4_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4588
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QR_EVAL_LOC), batching_challenge, p), p)
4590
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(SIGMA4_EVAL_LOC), batching_challenge, p), p)
4589
4591
  batching_challenge := mulmod(batching_challenge, rho, p)
4590
4592
 
4591
- // 4: QO_EVAL_LOC
4593
+ // 4: ID1_EVAL_LOC
4592
4594
  mstore(BATCH_SCALAR_5_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4593
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QO_EVAL_LOC), batching_challenge, p), p)
4595
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(ID1_EVAL_LOC), batching_challenge, p), p)
4594
4596
  batching_challenge := mulmod(batching_challenge, rho, p)
4595
4597
 
4596
- // 5: Q4_EVAL_LOC
4598
+ // 5: ID2_EVAL_LOC
4597
4599
  mstore(BATCH_SCALAR_6_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4598
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(Q4_EVAL_LOC), batching_challenge, p), p)
4600
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(ID2_EVAL_LOC), batching_challenge, p), p)
4599
4601
  batching_challenge := mulmod(batching_challenge, rho, p)
4600
4602
 
4601
- // 6: QLOOKUP_EVAL_LOC
4603
+ // 6: ID3_EVAL_LOC
4602
4604
  mstore(BATCH_SCALAR_7_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4603
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QLOOKUP_EVAL_LOC), batching_challenge, p), p)
4605
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(ID3_EVAL_LOC), batching_challenge, p), p)
4604
4606
  batching_challenge := mulmod(batching_challenge, rho, p)
4605
4607
 
4606
- // 7: QARITH_EVAL_LOC
4608
+ // 7: ID4_EVAL_LOC
4607
4609
  mstore(BATCH_SCALAR_8_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4608
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QARITH_EVAL_LOC), batching_challenge, p), p)
4610
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(ID4_EVAL_LOC), batching_challenge, p), p)
4609
4611
  batching_challenge := mulmod(batching_challenge, rho, p)
4610
4612
 
4611
- // 8: QRANGE_EVAL_LOC
4613
+ // 8: LAGRANGE_FIRST_EVAL_LOC
4612
4614
  mstore(BATCH_SCALAR_9_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4613
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QRANGE_EVAL_LOC), batching_challenge, p), p)
4615
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(LAGRANGE_FIRST_EVAL_LOC), batching_challenge, p), p)
4614
4616
  batching_challenge := mulmod(batching_challenge, rho, p)
4615
4617
 
4616
- // 9: QELLIPTIC_EVAL_LOC
4618
+ // 9: LAGRANGE_LAST_EVAL_LOC
4617
4619
  mstore(BATCH_SCALAR_10_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4618
- batched_evaluation := addmod(
4619
- batched_evaluation,
4620
- mulmod(mload(QELLIPTIC_EVAL_LOC), batching_challenge, p),
4621
- p
4622
- )
4620
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(LAGRANGE_LAST_EVAL_LOC), batching_challenge, p), p)
4623
4621
  batching_challenge := mulmod(batching_challenge, rho, p)
4624
4622
 
4625
- // 10: QMEMORY_EVAL_LOC
4623
+ // 10: QLOOKUP_EVAL_LOC
4626
4624
  mstore(BATCH_SCALAR_11_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4627
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QMEMORY_EVAL_LOC), batching_challenge, p), p)
4625
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QLOOKUP_EVAL_LOC), batching_challenge, p), p)
4628
4626
  batching_challenge := mulmod(batching_challenge, rho, p)
4629
4627
 
4630
- // 11: QNNF_EVAL_LOC
4628
+ // 11: TABLE1_EVAL_LOC
4631
4629
  mstore(BATCH_SCALAR_12_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4632
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(QNNF_EVAL_LOC), batching_challenge, p), p)
4630
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(TABLE1_EVAL_LOC), batching_challenge, p), p)
4633
4631
  batching_challenge := mulmod(batching_challenge, rho, p)
4634
4632
 
4635
- // 12: QPOSEIDON2_EXTERNAL_EVAL_LOC
4633
+ // 12: TABLE2_EVAL_LOC
4636
4634
  mstore(BATCH_SCALAR_13_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4637
- batched_evaluation := addmod(
4638
- batched_evaluation,
4639
- mulmod(mload(QPOSEIDON2_EXTERNAL_EVAL_LOC), batching_challenge, p),
4640
- p
4641
- )
4635
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(TABLE2_EVAL_LOC), batching_challenge, p), p)
4642
4636
  batching_challenge := mulmod(batching_challenge, rho, p)
4643
4637
 
4644
- // 13: QPOSEIDON2_INTERNAL_EVAL_LOC
4638
+ // 13: TABLE3_EVAL_LOC
4645
4639
  mstore(BATCH_SCALAR_14_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4646
- batched_evaluation := addmod(
4647
- batched_evaluation,
4648
- mulmod(mload(QPOSEIDON2_INTERNAL_EVAL_LOC), batching_challenge, p),
4649
- p
4650
- )
4640
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(TABLE3_EVAL_LOC), batching_challenge, p), p)
4651
4641
  batching_challenge := mulmod(batching_challenge, rho, p)
4652
4642
 
4653
- // 14: SIGMA1_EVAL_LOC
4643
+ // 14: TABLE4_EVAL_LOC
4654
4644
  mstore(BATCH_SCALAR_15_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4655
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(SIGMA1_EVAL_LOC), batching_challenge, p), p)
4645
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(TABLE4_EVAL_LOC), batching_challenge, p), p)
4656
4646
  batching_challenge := mulmod(batching_challenge, rho, p)
4657
4647
 
4658
- // 15: SIGMA2_EVAL_LOC
4648
+ // 15: QM_EVAL_LOC
4659
4649
  mstore(BATCH_SCALAR_16_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4660
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(SIGMA2_EVAL_LOC), batching_challenge, p), p)
4650
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QM_EVAL_LOC), batching_challenge, p), p)
4661
4651
  batching_challenge := mulmod(batching_challenge, rho, p)
4662
4652
 
4663
- // 16: SIGMA3_EVAL_LOC
4653
+ // 16: QR_EVAL_LOC
4664
4654
  mstore(BATCH_SCALAR_17_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4665
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(SIGMA3_EVAL_LOC), batching_challenge, p), p)
4655
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QR_EVAL_LOC), batching_challenge, p), p)
4666
4656
  batching_challenge := mulmod(batching_challenge, rho, p)
4667
4657
 
4668
- // 17: SIGMA4_EVAL_LOC
4658
+ // 17: QO_EVAL_LOC
4669
4659
  mstore(BATCH_SCALAR_18_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4670
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(SIGMA4_EVAL_LOC), batching_challenge, p), p)
4660
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QO_EVAL_LOC), batching_challenge, p), p)
4671
4661
  batching_challenge := mulmod(batching_challenge, rho, p)
4672
4662
 
4673
- // 18: ID1_EVAL_LOC
4663
+ // 18: QC_EVAL_LOC
4674
4664
  mstore(BATCH_SCALAR_19_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4675
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(ID1_EVAL_LOC), batching_challenge, p), p)
4665
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QC_EVAL_LOC), batching_challenge, p), p)
4676
4666
  batching_challenge := mulmod(batching_challenge, rho, p)
4677
4667
 
4678
- // 19: ID2_EVAL_LOC
4668
+ // 19: QL_EVAL_LOC
4679
4669
  mstore(BATCH_SCALAR_20_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4680
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(ID2_EVAL_LOC), batching_challenge, p), p)
4670
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QL_EVAL_LOC), batching_challenge, p), p)
4681
4671
  batching_challenge := mulmod(batching_challenge, rho, p)
4682
4672
 
4683
- // 20: ID3_EVAL_LOC
4673
+ // 20: Q4_EVAL_LOC
4684
4674
  mstore(BATCH_SCALAR_21_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4685
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(ID3_EVAL_LOC), batching_challenge, p), p)
4675
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(Q4_EVAL_LOC), batching_challenge, p), p)
4686
4676
  batching_challenge := mulmod(batching_challenge, rho, p)
4687
4677
 
4688
- // 21: ID4_EVAL_LOC
4678
+ // 21: QARITH_EVAL_LOC
4689
4679
  mstore(BATCH_SCALAR_22_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4690
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(ID4_EVAL_LOC), batching_challenge, p), p)
4680
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QARITH_EVAL_LOC), batching_challenge, p), p)
4691
4681
  batching_challenge := mulmod(batching_challenge, rho, p)
4692
4682
 
4693
- // 22: TABLE1_EVAL_LOC
4683
+ // 22: QRANGE_EVAL_LOC
4694
4684
  mstore(BATCH_SCALAR_23_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4695
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(TABLE1_EVAL_LOC), batching_challenge, p), p)
4685
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QRANGE_EVAL_LOC), batching_challenge, p), p)
4696
4686
  batching_challenge := mulmod(batching_challenge, rho, p)
4697
4687
 
4698
- // 23: TABLE2_EVAL_LOC
4688
+ // 23: QELLIPTIC_EVAL_LOC
4699
4689
  mstore(BATCH_SCALAR_24_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4700
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(TABLE2_EVAL_LOC), batching_challenge, p), p)
4690
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QELLIPTIC_EVAL_LOC), batching_challenge, p), p)
4701
4691
  batching_challenge := mulmod(batching_challenge, rho, p)
4702
4692
 
4703
- // 24: TABLE3_EVAL_LOC
4693
+ // 24: QMEMORY_EVAL_LOC
4704
4694
  mstore(BATCH_SCALAR_25_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4705
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(TABLE3_EVAL_LOC), batching_challenge, p), p)
4695
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QMEMORY_EVAL_LOC), batching_challenge, p), p)
4706
4696
  batching_challenge := mulmod(batching_challenge, rho, p)
4707
4697
 
4708
- // 25: TABLE4_EVAL_LOC
4698
+ // 25: QNNF_EVAL_LOC
4709
4699
  mstore(BATCH_SCALAR_26_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4710
- batched_evaluation := addmod(batched_evaluation, mulmod(mload(TABLE4_EVAL_LOC), batching_challenge, p), p)
4700
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QNNF_EVAL_LOC), batching_challenge, p), p)
4711
4701
  batching_challenge := mulmod(batching_challenge, rho, p)
4712
4702
 
4713
- // 26: LAGRANGE_FIRST_EVAL_LOC
4703
+ // 26: QPOSEIDON2_EXTERNAL_EVAL_LOC
4714
4704
  mstore(BATCH_SCALAR_27_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4715
- batched_evaluation := addmod(
4716
- batched_evaluation,
4717
- mulmod(mload(LAGRANGE_FIRST_EVAL_LOC), batching_challenge, p),
4718
- p
4719
- )
4705
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QPOSEIDON2_EXTERNAL_EVAL_LOC), batching_challenge, p), p)
4720
4706
  batching_challenge := mulmod(batching_challenge, rho, p)
4721
4707
 
4722
- // 27: LAGRANGE_LAST_EVAL_LOC
4708
+ // 27: QPOSEIDON2_INTERNAL_EVAL_LOC
4723
4709
  mstore(BATCH_SCALAR_28_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4724
- batched_evaluation := addmod(
4725
- batched_evaluation,
4726
- mulmod(mload(LAGRANGE_LAST_EVAL_LOC), batching_challenge, p),
4727
- p
4728
- )
4710
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(QPOSEIDON2_INTERNAL_EVAL_LOC), batching_challenge, p), p)
4729
4711
  batching_challenge := mulmod(batching_challenge, rho, p)
4730
4712
 
4731
4713
  // 28: W1_EVAL_LOC
@@ -4755,29 +4737,17 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
4755
4737
 
4756
4738
  // 33: LOOKUP_INVERSES_EVAL_LOC
4757
4739
  mstore(BATCH_SCALAR_34_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4758
- batched_evaluation := addmod(
4759
- batched_evaluation,
4760
- mulmod(mload(LOOKUP_INVERSES_EVAL_LOC), batching_challenge, p),
4761
- p
4762
- )
4740
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(LOOKUP_INVERSES_EVAL_LOC), batching_challenge, p), p)
4763
4741
  batching_challenge := mulmod(batching_challenge, rho, p)
4764
4742
 
4765
4743
  // 34: LOOKUP_READ_COUNTS_EVAL_LOC
4766
4744
  mstore(BATCH_SCALAR_35_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4767
- batched_evaluation := addmod(
4768
- batched_evaluation,
4769
- mulmod(mload(LOOKUP_READ_COUNTS_EVAL_LOC), batching_challenge, p),
4770
- p
4771
- )
4745
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(LOOKUP_READ_COUNTS_EVAL_LOC), batching_challenge, p), p)
4772
4746
  batching_challenge := mulmod(batching_challenge, rho, p)
4773
4747
 
4774
4748
  // 35: LOOKUP_READ_TAGS_EVAL_LOC
4775
4749
  mstore(BATCH_SCALAR_36_LOC, mulmod(neg_unshifted_scalar, batching_challenge, p))
4776
- batched_evaluation := addmod(
4777
- batched_evaluation,
4778
- mulmod(mload(LOOKUP_READ_TAGS_EVAL_LOC), batching_challenge, p),
4779
- p
4780
- )
4750
+ batched_evaluation := addmod(batched_evaluation, mulmod(mload(LOOKUP_READ_TAGS_EVAL_LOC), batching_challenge, p), p)
4781
4751
  batching_challenge := mulmod(batching_challenge, rho, p)
4782
4752
 
4783
4753
  // Unrolled for NUMBER_OF_SHIFTED_ENTITIES = 5
@@ -4933,8 +4903,9 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
4933
4903
  // Accumulate vk points
4934
4904
  loadVk()
4935
4905
  {
4936
- // Accumulator = accumulator + scalar[1] * vk[0]
4937
- mcopy(G1_LOCATION, Q_M_X_LOC, 0x40)
4906
+ // VK batchMul order matches UltraFlavor_Generated::EntityId precomputed layout.
4907
+ // Accumulator = accumulator + scalar[1] * vk[0] (sigma_1)
4908
+ mcopy(G1_LOCATION, SIGMA_1_X_LOC, 0x40)
4938
4909
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_1_LOC))
4939
4910
  precomp_success_flag := and(
4940
4911
  precomp_success_flag,
@@ -4945,8 +4916,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
4945
4916
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
4946
4917
  )
4947
4918
 
4948
- // Accumulator = accumulator + scalar[2] * vk[1]
4949
- mcopy(G1_LOCATION, Q_C_X_LOC, 0x40)
4919
+ // Accumulator = accumulator + scalar[2] * vk[1] (sigma_2)
4920
+ mcopy(G1_LOCATION, SIGMA_2_X_LOC, 0x40)
4950
4921
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_2_LOC))
4951
4922
  precomp_success_flag := and(
4952
4923
  precomp_success_flag,
@@ -4957,8 +4928,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
4957
4928
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
4958
4929
  )
4959
4930
 
4960
- // Accumulator = accumulator + scalar[3] * vk[2]
4961
- mcopy(G1_LOCATION, Q_L_X_LOC, 0x40)
4931
+ // Accumulator = accumulator + scalar[3] * vk[2] (sigma_3)
4932
+ mcopy(G1_LOCATION, SIGMA_3_X_LOC, 0x40)
4962
4933
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_3_LOC))
4963
4934
  precomp_success_flag := and(
4964
4935
  precomp_success_flag,
@@ -4969,8 +4940,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
4969
4940
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
4970
4941
  )
4971
4942
 
4972
- // Accumulator = accumulator + scalar[4] * vk[3]
4973
- mcopy(G1_LOCATION, Q_R_X_LOC, 0x40)
4943
+ // Accumulator = accumulator + scalar[4] * vk[3] (sigma_4)
4944
+ mcopy(G1_LOCATION, SIGMA_4_X_LOC, 0x40)
4974
4945
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_4_LOC))
4975
4946
  precomp_success_flag := and(
4976
4947
  precomp_success_flag,
@@ -4981,8 +4952,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
4981
4952
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
4982
4953
  )
4983
4954
 
4984
- // Accumulator = accumulator + scalar[5] * vk[4]
4985
- mcopy(G1_LOCATION, Q_O_X_LOC, 0x40)
4955
+ // Accumulator = accumulator + scalar[5] * vk[4] (id_1)
4956
+ mcopy(G1_LOCATION, ID_1_X_LOC, 0x40)
4986
4957
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_5_LOC))
4987
4958
  precomp_success_flag := and(
4988
4959
  precomp_success_flag,
@@ -4993,8 +4964,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
4993
4964
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
4994
4965
  )
4995
4966
 
4996
- // Accumulator = accumulator + scalar[6] * vk[5]
4997
- mcopy(G1_LOCATION, Q_4_X_LOC, 0x40)
4967
+ // Accumulator = accumulator + scalar[6] * vk[5] (id_2)
4968
+ mcopy(G1_LOCATION, ID_2_X_LOC, 0x40)
4998
4969
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_6_LOC))
4999
4970
  precomp_success_flag := and(
5000
4971
  precomp_success_flag,
@@ -5005,8 +4976,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5005
4976
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5006
4977
  )
5007
4978
 
5008
- // Accumulator = accumulator + scalar[7] * vk[6]
5009
- mcopy(G1_LOCATION, Q_LOOKUP_X_LOC, 0x40)
4979
+ // Accumulator = accumulator + scalar[7] * vk[6] (id_3)
4980
+ mcopy(G1_LOCATION, ID_3_X_LOC, 0x40)
5010
4981
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_7_LOC))
5011
4982
  precomp_success_flag := and(
5012
4983
  precomp_success_flag,
@@ -5017,8 +4988,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5017
4988
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5018
4989
  )
5019
4990
 
5020
- // Accumulator = accumulator + scalar[8] * vk[7]
5021
- mcopy(G1_LOCATION, Q_ARITH_X_LOC, 0x40)
4991
+ // Accumulator = accumulator + scalar[8] * vk[7] (id_4)
4992
+ mcopy(G1_LOCATION, ID_4_X_LOC, 0x40)
5022
4993
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_8_LOC))
5023
4994
  precomp_success_flag := and(
5024
4995
  precomp_success_flag,
@@ -5029,8 +5000,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5029
5000
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5030
5001
  )
5031
5002
 
5032
- // Accumulator = accumulator + scalar[9] * vk[8]
5033
- mcopy(G1_LOCATION, Q_DELTA_RANGE_X_LOC, 0x40)
5003
+ // Accumulator = accumulator + scalar[9] * vk[8] (lagrange_first)
5004
+ mcopy(G1_LOCATION, LAGRANGE_FIRST_X_LOC, 0x40)
5034
5005
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_9_LOC))
5035
5006
  precomp_success_flag := and(
5036
5007
  precomp_success_flag,
@@ -5041,8 +5012,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5041
5012
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5042
5013
  )
5043
5014
 
5044
- // Accumulator = accumulator + scalar[10] * vk[9]
5045
- mcopy(G1_LOCATION, Q_ELLIPTIC_X_LOC, 0x40)
5015
+ // Accumulator = accumulator + scalar[10] * vk[9] (lagrange_last)
5016
+ mcopy(G1_LOCATION, LAGRANGE_LAST_X_LOC, 0x40)
5046
5017
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_10_LOC))
5047
5018
  precomp_success_flag := and(
5048
5019
  precomp_success_flag,
@@ -5053,8 +5024,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5053
5024
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5054
5025
  )
5055
5026
 
5056
- // Accumulator = accumulator + scalar[11] * vk[10]
5057
- mcopy(G1_LOCATION, Q_MEMORY_X_LOC, 0x40)
5027
+ // Accumulator = accumulator + scalar[11] * vk[10] (q_lookup)
5028
+ mcopy(G1_LOCATION, Q_LOOKUP_X_LOC, 0x40)
5058
5029
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_11_LOC))
5059
5030
  precomp_success_flag := and(
5060
5031
  precomp_success_flag,
@@ -5065,8 +5036,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5065
5036
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5066
5037
  )
5067
5038
 
5068
- // Accumulator = accumulator + scalar[12] * vk[11]
5069
- mcopy(G1_LOCATION, Q_NNF_X_LOC, 0x40)
5039
+ // Accumulator = accumulator + scalar[12] * vk[11] (table_1)
5040
+ mcopy(G1_LOCATION, TABLE_1_X_LOC, 0x40)
5070
5041
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_12_LOC))
5071
5042
  precomp_success_flag := and(
5072
5043
  precomp_success_flag,
@@ -5077,8 +5048,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5077
5048
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5078
5049
  )
5079
5050
 
5080
- // Accumulator = accumulator + scalar[13] * vk[12]
5081
- mcopy(G1_LOCATION, Q_POSEIDON_2_EXTERNAL_X_LOC, 0x40)
5051
+ // Accumulator = accumulator + scalar[13] * vk[12] (table_2)
5052
+ mcopy(G1_LOCATION, TABLE_2_X_LOC, 0x40)
5082
5053
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_13_LOC))
5083
5054
  precomp_success_flag := and(
5084
5055
  precomp_success_flag,
@@ -5089,8 +5060,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5089
5060
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5090
5061
  )
5091
5062
 
5092
- // Accumulator = accumulator + scalar[14] * vk[13]
5093
- mcopy(G1_LOCATION, Q_POSEIDON_2_INTERNAL_X_LOC, 0x40)
5063
+ // Accumulator = accumulator + scalar[14] * vk[13] (table_3)
5064
+ mcopy(G1_LOCATION, TABLE_3_X_LOC, 0x40)
5094
5065
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_14_LOC))
5095
5066
  precomp_success_flag := and(
5096
5067
  precomp_success_flag,
@@ -5101,8 +5072,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5101
5072
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5102
5073
  )
5103
5074
 
5104
- // Accumulator = accumulator + scalar[15] * vk[14]
5105
- mcopy(G1_LOCATION, SIGMA_1_X_LOC, 0x40)
5075
+ // Accumulator = accumulator + scalar[15] * vk[14] (table_4)
5076
+ mcopy(G1_LOCATION, TABLE_4_X_LOC, 0x40)
5106
5077
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_15_LOC))
5107
5078
  precomp_success_flag := and(
5108
5079
  precomp_success_flag,
@@ -5113,8 +5084,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5113
5084
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5114
5085
  )
5115
5086
 
5116
- // Accumulator = accumulator + scalar[16] * vk[15]
5117
- mcopy(G1_LOCATION, SIGMA_2_X_LOC, 0x40)
5087
+ // Accumulator = accumulator + scalar[16] * vk[15] (q_m)
5088
+ mcopy(G1_LOCATION, Q_M_X_LOC, 0x40)
5118
5089
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_16_LOC))
5119
5090
  precomp_success_flag := and(
5120
5091
  precomp_success_flag,
@@ -5125,8 +5096,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5125
5096
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5126
5097
  )
5127
5098
 
5128
- // Accumulator = accumulator + scalar[17] * vk[16]
5129
- mcopy(G1_LOCATION, SIGMA_3_X_LOC, 0x40)
5099
+ // Accumulator = accumulator + scalar[17] * vk[16] (q_r)
5100
+ mcopy(G1_LOCATION, Q_R_X_LOC, 0x40)
5130
5101
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_17_LOC))
5131
5102
  precomp_success_flag := and(
5132
5103
  precomp_success_flag,
@@ -5137,8 +5108,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5137
5108
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5138
5109
  )
5139
5110
 
5140
- // Accumulator = accumulator + scalar[18] * vk[17]
5141
- mcopy(G1_LOCATION, SIGMA_4_X_LOC, 0x40)
5111
+ // Accumulator = accumulator + scalar[18] * vk[17] (q_o)
5112
+ mcopy(G1_LOCATION, Q_O_X_LOC, 0x40)
5142
5113
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_18_LOC))
5143
5114
  precomp_success_flag := and(
5144
5115
  precomp_success_flag,
@@ -5149,8 +5120,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5149
5120
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5150
5121
  )
5151
5122
 
5152
- // Accumulator = accumulator + scalar[19] * vk[18]
5153
- mcopy(G1_LOCATION, ID_1_X_LOC, 0x40)
5123
+ // Accumulator = accumulator + scalar[19] * vk[18] (q_c)
5124
+ mcopy(G1_LOCATION, Q_C_X_LOC, 0x40)
5154
5125
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_19_LOC))
5155
5126
  precomp_success_flag := and(
5156
5127
  precomp_success_flag,
@@ -5161,8 +5132,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5161
5132
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5162
5133
  )
5163
5134
 
5164
- // Accumulator = accumulator + scalar[20] * vk[19]
5165
- mcopy(G1_LOCATION, ID_2_X_LOC, 0x40)
5135
+ // Accumulator = accumulator + scalar[20] * vk[19] (q_l)
5136
+ mcopy(G1_LOCATION, Q_L_X_LOC, 0x40)
5166
5137
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_20_LOC))
5167
5138
  precomp_success_flag := and(
5168
5139
  precomp_success_flag,
@@ -5173,8 +5144,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5173
5144
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5174
5145
  )
5175
5146
 
5176
- // Accumulator = accumulator + scalar[21] * vk[20]
5177
- mcopy(G1_LOCATION, ID_3_X_LOC, 0x40)
5147
+ // Accumulator = accumulator + scalar[21] * vk[20] (q_4)
5148
+ mcopy(G1_LOCATION, Q_4_X_LOC, 0x40)
5178
5149
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_21_LOC))
5179
5150
  precomp_success_flag := and(
5180
5151
  precomp_success_flag,
@@ -5185,8 +5156,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5185
5156
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5186
5157
  )
5187
5158
 
5188
- // Accumulator = accumulator + scalar[22] * vk[21]
5189
- mcopy(G1_LOCATION, ID_4_X_LOC, 0x40)
5159
+ // Accumulator = accumulator + scalar[22] * vk[21] (q_arith)
5160
+ mcopy(G1_LOCATION, Q_ARITH_X_LOC, 0x40)
5190
5161
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_22_LOC))
5191
5162
  precomp_success_flag := and(
5192
5163
  precomp_success_flag,
@@ -5197,8 +5168,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5197
5168
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5198
5169
  )
5199
5170
 
5200
- // Accumulator = accumulator + scalar[23] * vk[22]
5201
- mcopy(G1_LOCATION, TABLE_1_X_LOC, 0x40)
5171
+ // Accumulator = accumulator + scalar[23] * vk[22] (q_delta_range)
5172
+ mcopy(G1_LOCATION, Q_DELTA_RANGE_X_LOC, 0x40)
5202
5173
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_23_LOC))
5203
5174
  precomp_success_flag := and(
5204
5175
  precomp_success_flag,
@@ -5209,8 +5180,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5209
5180
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5210
5181
  )
5211
5182
 
5212
- // Accumulator = accumulator + scalar[24] * vk[23]
5213
- mcopy(G1_LOCATION, TABLE_2_X_LOC, 0x40)
5183
+ // Accumulator = accumulator + scalar[24] * vk[23] (q_elliptic)
5184
+ mcopy(G1_LOCATION, Q_ELLIPTIC_X_LOC, 0x40)
5214
5185
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_24_LOC))
5215
5186
  precomp_success_flag := and(
5216
5187
  precomp_success_flag,
@@ -5221,8 +5192,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5221
5192
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5222
5193
  )
5223
5194
 
5224
- // Accumulator = accumulator + scalar[25] * vk[24]
5225
- mcopy(G1_LOCATION, TABLE_3_X_LOC, 0x40)
5195
+ // Accumulator = accumulator + scalar[25] * vk[24] (q_memory)
5196
+ mcopy(G1_LOCATION, Q_MEMORY_X_LOC, 0x40)
5226
5197
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_25_LOC))
5227
5198
  precomp_success_flag := and(
5228
5199
  precomp_success_flag,
@@ -5233,8 +5204,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5233
5204
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5234
5205
  )
5235
5206
 
5236
- // Accumulator = accumulator + scalar[26] * vk[25]
5237
- mcopy(G1_LOCATION, TABLE_4_X_LOC, 0x40)
5207
+ // Accumulator = accumulator + scalar[26] * vk[25] (q_nnf)
5208
+ mcopy(G1_LOCATION, Q_NNF_X_LOC, 0x40)
5238
5209
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_26_LOC))
5239
5210
  precomp_success_flag := and(
5240
5211
  precomp_success_flag,
@@ -5245,8 +5216,8 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5245
5216
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5246
5217
  )
5247
5218
 
5248
- // Accumulator = accumulator + scalar[27] * [lagrange_first]
5249
- mcopy(G1_LOCATION, LAGRANGE_FIRST_X_LOC, 0x40)
5219
+ // Accumulator = accumulator + scalar[27] * vk[26] (q_poseidon2_external)
5220
+ mcopy(G1_LOCATION, Q_POSEIDON_2_EXTERNAL_X_LOC, 0x40)
5250
5221
  mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_27_LOC))
5251
5222
  precomp_success_flag := and(
5252
5223
  precomp_success_flag,
@@ -5257,10 +5228,9 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5257
5228
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5258
5229
  )
5259
5230
 
5260
- // Accumulator = accumulator + constant_term_acc * G (generator)
5261
- mstore(G1_LOCATION, 0x01) // G1 generator x
5262
- mstore(add(G1_LOCATION, 0x20), 0x02) // G1 generator y
5263
- mstore(SCALAR_LOCATION, constant_term_acc)
5231
+ // Accumulator = accumulator + scalar[28] * vk[27] (q_poseidon2_internal)
5232
+ mcopy(G1_LOCATION, Q_POSEIDON_2_INTERNAL_X_LOC, 0x40)
5233
+ mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_28_LOC))
5264
5234
  precomp_success_flag := and(
5265
5235
  precomp_success_flag,
5266
5236
  staticcall(gas(), 7, G1_LOCATION, 0x60, ACCUMULATOR_2, 0x40)
@@ -5270,9 +5240,10 @@ uint256 internal constant SS_GEMINI_EVALS_LOC = 0x40;
5270
5240
  staticcall(gas(), 6, ACCUMULATOR, 0x80, ACCUMULATOR, 0x40)
5271
5241
  )
5272
5242
 
5273
- // Accumulator = accumulator + scalar[28] * vk[27]
5274
- mcopy(G1_LOCATION, LAGRANGE_LAST_X_LOC, 0x40)
5275
- mstore(SCALAR_LOCATION, mload(BATCH_SCALAR_28_LOC))
5243
+ // Accumulator = accumulator + constant_term_acc * G (generator)
5244
+ mstore(G1_LOCATION, 0x01) // G1 generator x
5245
+ mstore(add(G1_LOCATION, 0x20), 0x02) // G1 generator y
5246
+ mstore(SCALAR_LOCATION, constant_term_acc)
5276
5247
  precomp_success_flag := and(
5277
5248
  precomp_success_flag,
5278
5249
  staticcall(gas(), 7, G1_LOCATION, 0x60, ACCUMULATOR_2, 0x40)