unionlabs / union

The trust-minimized, zero-knowledge bridging protocol, designed for censorship resistance, extremely high security, and usage in decentralized finance.
https://union.build
Apache License 2.0
373 stars 28 forks source link

Solidity gas optimizations #37

Closed KaiserKarel closed 1 year ago

KaiserKarel commented 1 year ago

Figure out where we can cut gas by optimizing the UpdateClient and ReceivePacket handlers.

For the former, we currently apply:

More optimizations (probably v2):

For packets, the relayer could bulk them and provide a ZKP of aggregated membership proof verification (circuit yet to be done).

hussein-aitlahcen commented 1 year ago

Closing.