-
Notifications
You must be signed in to change notification settings - Fork 310
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: rename pedersen typescript methods to be called hash
instead of compress
#3047
Conversation
@@ -28,6 +28,34 @@ describe('pedersen', () => { | |||
expect(result).toEqual(new Fr(2152386650411553803409271316104075950536496387580531018130718456431861859990n)); | |||
}); | |||
|
|||
it('pedersenCompressAndHashSame', async () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are a bunch of "crutch" tests that show that a lot of the pedersen methods are effectively the same or some are just supersets.
Once I remove the c_binds for them, these will also disappear since they won't be available anymore
import { pedersenCompressInputs } from '@aztec/circuits.js/barretenberg'; | ||
import { pedersenHashInputs } from '@aztec/circuits.js/barretenberg'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the main change in the PR,compress
to Hash
* @deprecated Don't call pedersen directly in production code. Instead, create suitably-named functions for specific | ||
* purposes. | ||
*/ | ||
export function pedersenCompressInputs(wasm: IWasmModule, inputs: Buffer[]): Buffer { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed this as this is the same as pedersenHashInputs
Benchmark resultsNo metrics with a significant change found. Detailed resultsAll benchmarks are run on txs on the This benchmark source data is available in JSON format on S3 here. Values are compared against data from master at commit L2 block published to L1Each column represents the number of txs on an L2 block published to L1.
L2 chain processingEach column represents the number of blocks on the L2 chain where each block has 16 txs.
Circuits statsStats on running time and I/O sizes collected for every circuit run across all benchmarks.
MiscellaneousTransaction sizes based on how many contracts are deployed in the tx.
|
7ac8d37
to
245e44b
Compare
Related to #3029
Checklist:
Remove the checklist to signal you've completed it. Enable auto-merge if the PR is ready to merge.