Skip to content
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

feat: add Sha256 precompile #576

Closed
gbotrel opened this issue Mar 15, 2023 · 2 comments
Closed

feat: add Sha256 precompile #576

gbotrel opened this issue Mar 15, 2023 · 2 comments
Labels
P3: Low Issue priority: low zk-evm

Comments

@gbotrel
Copy link
Collaborator

gbotrel commented Mar 15, 2023

Before closing issue ensure we have a constraint count + a matching test with the exact interface.

@gbotrel gbotrel added zk-evm P3: Low Issue priority: low labels Mar 15, 2023
@ivokub
Copy link
Collaborator

ivokub commented May 2, 2023

Status update: round function is working using table lookups. Right now working on improving table lookups for shifts and rotations, and implementing full hash function.

@ivokub
Copy link
Collaborator

ivokub commented Jul 3, 2023

Done in #689. Complexity:

blocks 1  bytes 55   constraints R1CS 152256 SCS 592937
blocks 2  bytes 119  constraints R1CS 172083 SCS 660254
blocks 3  bytes 183  constraints R1CS 191911 SCS 727571
blocks 4  bytes 247  constraints R1CS 211738 SCS 794887
blocks 5  bytes 311  constraints R1CS 231566 SCS 862204
blocks 6  bytes 375  constraints R1CS 251393 SCS 929520
blocks 7  bytes 439  constraints R1CS 271220 SCS 996836
blocks 8  bytes 503  constraints R1CS 291049 SCS 1064152
blocks 9  bytes 567  constraints R1CS 310876 SCS 1131468
blocks 10 bytes 631  constraints R1CS 330703 SCS 1198784
blocks 11 bytes 695  constraints R1CS 350531 SCS 1266100
blocks 12 bytes 759  constraints R1CS 370359 SCS 1333416
blocks 13 bytes 823  constraints R1CS 390186 SCS 1400732
blocks 14 bytes 887  constraints R1CS 410013 SCS 1468048
blocks 15 bytes 951  constraints R1CS 429842 SCS 1535364
blocks 16 bytes 1015 constraints R1CS 449668 SCS 1602680
blocks 17 bytes 1079 constraints R1CS 469496 SCS 1669996
blocks 18 bytes 1143 constraints R1CS 489324 SCS 1737312
blocks 19 bytes 1207 constraints R1CS 509151 SCS 1804628
blocks 20 bytes 1271 constraints R1CS 528979 SCS 1871944

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P3: Low Issue priority: low zk-evm
Projects
None yet
Development

No branches or pull requests

2 participants