Skip to content

Feat/7683/batch filler repayment#200

Merged
kss-t1 merged 27 commits into
canaryfrom
feat/7683/batch-filler-repayment
Oct 8, 2025
Merged

Feat/7683/batch filler repayment#200
kss-t1 merged 27 commits into
canaryfrom
feat/7683/batch-filler-repayment

Conversation

@kss-t1

@kss-t1 kss-t1 commented Sep 26, 2025

Copy link
Copy Markdown
Member

Description

Batch repayments for the 7683 intent fillers to optimize their gas costs.

  • allows to process Proofs of Read in a batch
  • when processing a batch of 7683 repayments, does some smart tricks to minimalise number of _transferTokenOut calls

Also introduces generic batch proof verification to xChainRead.

Functionality of processing a PoRs one by one was unchanged.

Motivation and Context

We want to beat bridging prices of our competition, so we want to show best profitability for solvers. Hence the gas optimization.

How Has This Been Tested?

Unit test which confirms correctness and gas savings. In the unit test, a simple Merkle Trie implementation was used to create Merkle Trie.

Types of changes (remove all unchecked types)

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Style (style only changes)
  • Docs
  • Refactor (code that does not add new functionality nor fixes a bug)

Checklist:

  • If my change requires a change to the documentation, I have updated the documentation accordingly, and in either case, have checked this box to attest to my assessment of this requirement with regard to my change.
  • If my change requires additions or updates to any deployment scripts to ensure that the protocol is functional (Makefile, Dockerfile, Forge Script, etc.), I have made these changes, and in either case, have checked this box to attest to my assessment of this requirement with regard to my change.
  • If my change requires additional test coverage, I have created those tests accordingly, and in either case, have checked this box to attest to my assessment of this requirement with regard to my change.

@kss-t1 kss-t1 marked this pull request as ready for review September 26, 2025 15:58
@kss-t1 kss-t1 requested a review from evchip September 26, 2025 15:58
@evchip

evchip commented Sep 28, 2025

Copy link
Copy Markdown
Contributor

@kss-t1 forge fmt please

@evchip

evchip commented Sep 28, 2025

Copy link
Copy Markdown
Contributor

Not tested.

y no u unit test?

Comment thread contracts/src/7683/T1ERC7683.sol Outdated
Comment thread contracts/src/7683/T1ERC7683.sol Outdated
Comment thread contracts/src/7683/T1ERC7683.sol Outdated

@evchip evchip left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Found a few issues on first pass.

@kss-t1 kss-t1 requested a review from evchip October 7, 2025 09:48
Comment thread contracts/src/test/utils/MurkyMerkleBase.sol
@kss-t1 kss-t1 merged commit fc0246e into canary Oct 8, 2025
4 checks passed
@kss-t1 kss-t1 deleted the feat/7683/batch-filler-repayment branch October 8, 2025 09:43
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.

2 participants