Skip to content

Conversation

@waamm
Copy link
Collaborator

@waamm waamm commented Dec 23, 2025

Description

  • Got rid of duplicate ark_serialize code (noticed by @ibalajiarun )
  • Removed duplicate correlated_randomness code, and moved corresponding tests
  • Slightly refactored our arkworks random point generation so its output is an affine point instead of curve point
  • Modified vanishing_poly::from_roots() function, should be at least 10x faster now
  • Doubled FFT_THRESH for the blstrs code, performs better on my M4 Max
  • Wrote benches for the arkworks and blstrs SCRAPE tests
  • Made functions in chunky/chunks public so they can be used in tests
  • Changed chunked_elgamal::PublicParameters to be generic over a CurveGroup rather than a Pairing
  • Slightly edited PVSS tests by making WeightedConfigBlstrs generic (to WeightedConfig<T>), and adding a test / benchmark case
  • Renamed SubTranscript to Subtranscript
  • Deleted aptos_crypto/error.rs
  • Small fixes to aptos_crypto/benches/README.md
  • Small fixes to aptos_crypto/benches/run-range-proof-benches.rs
  • Also added PVSS benches to aptos_crypto/benches
  • Added pcs bench and serialization bench and ldt bench
  • Added serialization component to pvss bench
  • Removed Scalar from Fiat-Shamir code, and added a PolynomialCommitmentScheme trait for merlin transcripts
  • Added a PolynomialCommitmentScheme trait
  • Added a preliminary version of Zeromorph (currently just for benchmarking purposes).
  • Finally deleted a lot of unweighted chunky code.
  • Added srs.rs. Is a neat way to gather SRS functionality, but also is an order of magnitude faster at generating them than our previous code due to G.batch_mul()
  • Adds chunky_v2

How Has This Been Tested?

Key Areas to Review

Type of Change

  • New feature
  • Bug fix
  • Breaking change
  • Performance improvement
  • Refactoring
  • Dependency update
  • Documentation update
  • Tests

Which Components or Systems Does This Change Impact?

  • Validator Node
  • Full Node (API, Indexer, etc.)
  • Move/Aptos Virtual Machine
  • Aptos Framework
  • Aptos CLI/SDK
  • Developer Infrastructure
  • Move Compiler
  • Other (specify): this code is not yet being used

Checklist

  • I have read and followed the CONTRIBUTING doc
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I identified and added all stakeholders and component owners affected by this change as reviewers
  • I tested both happy and unhappy path of the functionality
  • I have made corresponding changes to the documentation

Note

Adds new polynomial commitment and PVSS capabilities, consolidates serialization, and improves performance with math and API tweaks.

  • Introduces pcs module with PolynomialCommitmentScheme trait and Zeromorph implementation (setup/commit/open/verify) plus benches
  • Generalizes Fiat–Shamir (drops Scalar, adds PCS helpers) and adds arkworks::srs with faster batch_mul-based generators
  • Optimizes vanishing_poly::from_roots and adjusts random point APIs to return affine; doubles blstrs FFT_THRESH
  • Refactors PVSS chunky code: generic PublicParameters over CurveGroup, new chunky_v2, weighted transcript rename (SubTranscript -> Subtranscript), decrypt helpers; removes unweighted code
  • Replaces local ark_serialize with aptos_crypto::arkworks::serialization across modules; deletes aptos_crypto::error and switches to anyhow
  • Adds benches and tooling: PCS, LDT, serialization, PVSS (scripts, table printers, README updates); minor Cargo updates (rayon/itertools) and misc fixes
  • Updates batch-encryption to new serialization APIs and renamed PVSS types

Written by Cursor Bugbot for commit 52740cf. This will update automatically on new commits. Configure here.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

@waamm waamm enabled auto-merge (squash) January 17, 2026 02:11
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions
Copy link
Contributor

✅ Forge suite compat success on d49896be27f4c071cdaeb4a2e6ddc0ddd97a93c5 ==> 52740cf1b4fd10aa9d7072de32fd78cee48a44e7

Compatibility test results for d49896be27f4c071cdaeb4a2e6ddc0ddd97a93c5 ==> 52740cf1b4fd10aa9d7072de32fd78cee48a44e7 (PR)
1. Check liveness of validators at old version: d49896be27f4c071cdaeb4a2e6ddc0ddd97a93c5
compatibility::simple-validator-upgrade::liveness-check : committed: 13325.85 txn/s, latency: 2615.14 ms, (p50: 2700 ms, p70: 3000, p90: 3300 ms, p99: 3700 ms), latency samples: 436780
2. Upgrading first Validator to new version: 52740cf1b4fd10aa9d7072de32fd78cee48a44e7
compatibility::simple-validator-upgrade::single-validator-upgrade : committed: 5709.29 txn/s, latency: 5913.79 ms, (p50: 6600 ms, p70: 6700, p90: 6800 ms, p99: 6900 ms), latency samples: 197480
3. Upgrading rest of first batch to new version: 52740cf1b4fd10aa9d7072de32fd78cee48a44e7
compatibility::simple-validator-upgrade::half-validator-upgrade : committed: 5909.67 txn/s, latency: 5749.35 ms, (p50: 6300 ms, p70: 6600, p90: 6700 ms, p99: 6800 ms), latency samples: 203240
4. upgrading second batch to new version: 52740cf1b4fd10aa9d7072de32fd78cee48a44e7
compatibility::simple-validator-upgrade::rest-validator-upgrade : committed: 9861.76 txn/s, latency: 3298.95 ms, (p50: 3200 ms, p70: 3800, p90: 4600 ms, p99: 5000 ms), latency samples: 324120
5. check swarm health
Compatibility test for d49896be27f4c071cdaeb4a2e6ddc0ddd97a93c5 ==> 52740cf1b4fd10aa9d7072de32fd78cee48a44e7 passed
Test Ok

@github-actions
Copy link
Contributor

✅ Forge suite realistic_env_max_load success on 52740cf1b4fd10aa9d7072de32fd78cee48a44e7

two traffics test: inner traffic : committed: 13565.71 txn/s, latency: 2779.62 ms, (p50: 2700 ms, p70: 2900, p90: 3000 ms, p99: 3600 ms), latency samples: 5053060
two traffics test : committed: 100.00 txn/s, latency: 734.11 ms, (p50: 700 ms, p70: 800, p90: 800 ms, p99: 1300 ms), latency samples: 1700
Latency breakdown for phase 0: ["MempoolToBlockCreation: max: 2.305, avg: 2.206", "ConsensusProposalToOrdered: max: 0.168, avg: 0.166", "ConsensusOrderedToCommit: max: 0.050, avg: 0.045", "ConsensusProposalToCommit: max: 0.215, avg: 0.211"]
Max non-epoch-change gap was: 0 rounds at version 0 (avg 0.00) [limit 4], 0.83s no progress at version 16125 (avg 0.07s) [limit 15].
Max epoch-change gap was: 0 rounds at version 0 (avg 0.00) [limit 4], 0.57s no progress at version 5785172 (avg 0.42s) [limit 16].
Test Ok

@github-actions
Copy link
Contributor

✅ Forge suite framework_upgrade success on d49896be27f4c071cdaeb4a2e6ddc0ddd97a93c5 ==> 52740cf1b4fd10aa9d7072de32fd78cee48a44e7

Compatibility test results for d49896be27f4c071cdaeb4a2e6ddc0ddd97a93c5 ==> 52740cf1b4fd10aa9d7072de32fd78cee48a44e7 (PR)
Upgrade the nodes to version: 52740cf1b4fd10aa9d7072de32fd78cee48a44e7
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 2181.61 txn/s, submitted: 2188.43 txn/s, failed submission: 6.82 txn/s, expired: 6.82 txn/s, latency: 1325.77 ms, (p50: 1200 ms, p70: 1500, p90: 1800 ms, p99: 3000 ms), latency samples: 198240
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 2263.81 txn/s, submitted: 2272.12 txn/s, failed submission: 8.31 txn/s, expired: 8.31 txn/s, latency: 1265.09 ms, (p50: 1200 ms, p70: 1500, p90: 1800 ms, p99: 3000 ms), latency samples: 206942
5. check swarm health
Compatibility test for d49896be27f4c071cdaeb4a2e6ddc0ddd97a93c5 ==> 52740cf1b4fd10aa9d7072de32fd78cee48a44e7 passed
Upgrade the remaining nodes to version: 52740cf1b4fd10aa9d7072de32fd78cee48a44e7
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 2030.37 txn/s, submitted: 2036.85 txn/s, failed submission: 6.49 txn/s, expired: 6.49 txn/s, latency: 1849.10 ms, (p50: 1200 ms, p70: 1500, p90: 2000 ms, p99: 11700 ms), latency samples: 175222
Test Ok

@waamm waamm merged commit 6c3a7df into main Jan 17, 2026
48 checks passed
@waamm waamm deleted the wicher/more-dkg-edits branch January 17, 2026 12:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants