-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
10-17% Gas reduction for checks, hash tests (#52)
- Loading branch information
1 parent
4f9f5b8
commit 7b06abc
Showing
12 changed files
with
638 additions
and
173 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
| src/DelegateRegistry.sol:DelegateRegistry contract | | | | | | | ||
|----------------------------------------------------|-----------------|--------|--------|--------|---------| | ||
| Deployment Cost | Deployment Size | | | | | | ||
| 1840741 | 9226 | | | | | | ||
| 2124658 | 10644 | | | | | | ||
| Function Name | min | avg | median | max | # calls | | ||
| checkDelegateForAll | 3293 | 3648 | 3648 | 4004 | 2 | | ||
| checkDelegateForContract | 6120 | 6856 | 6856 | 7593 | 2 | | ||
| checkDelegateForERC1155 | 8989 | 10164 | 10164 | 11340 | 2 | | ||
| checkDelegateForERC20 | 8899 | 10053 | 10053 | 11207 | 2 | | ||
| checkDelegateForERC721 | 8981 | 10114 | 10114 | 11248 | 2 | | ||
| delegateAll | 136182 | 136182 | 136182 | 136182 | 2 | | ||
| delegateContract | 114804 | 125754 | 125754 | 136704 | 2 | | ||
| delegateERC1155 | 159739 | 170689 | 170689 | 181639 | 2 | | ||
| delegateERC20 | 137269 | 148219 | 148219 | 159169 | 2 | | ||
| delegateERC721 | 137279 | 148229 | 148229 | 159179 | 2 | | ||
| multicall | 691368 | 691368 | 691368 | 691368 | 1 | | ||
| checkDelegateForAll | 2980 | 3183 | 3183 | 3386 | 2 | | ||
| checkDelegateForContract | 5473 | 5895 | 5895 | 6317 | 2 | | ||
| checkDelegateForERC1155 | 7990 | 8685 | 8685 | 9380 | 2 | | ||
| checkDelegateForERC20 | 7927 | 8610 | 8610 | 9293 | 2 | | ||
| checkDelegateForERC721 | 7991 | 8644 | 8644 | 9297 | 2 | | ||
| delegateAll | 135861 | 135861 | 135861 | 135861 | 2 | | ||
| delegateContract | 114469 | 125419 | 125419 | 136369 | 2 | | ||
| delegateERC1155 | 159393 | 170343 | 170343 | 181293 | 2 | | ||
| delegateERC20 | 136942 | 147892 | 147892 | 158842 | 2 | | ||
| delegateERC721 | 136936 | 147886 | 147886 | 158836 | 2 | | ||
| multicall | 689696 | 689696 | 689696 | 689696 | 1 | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
| src/tools/HashHarness.sol:HashHarness contract | | | | | | | ||
|------------------------------------------------|-----------------|-----|--------|-----|---------| | ||
| Deployment Cost | Deployment Size | | | | | | ||
| 416655 | 2113 | | | | | | ||
| Function Name | min | avg | median | max | # calls | | ||
| allHash | 634 | 634 | 634 | 634 | 1 | | ||
| allLocation | 746 | 746 | 746 | 746 | 1 | | ||
| contractHash | 835 | 835 | 835 | 835 | 1 | | ||
| contractLocation | 873 | 873 | 873 | 873 | 1 | | ||
| decodeType | 393 | 393 | 393 | 393 | 1 | | ||
| encodeType | 351 | 351 | 351 | 351 | 1 | | ||
| erc1155Hash | 843 | 843 | 843 | 843 | 1 | | ||
| erc1155Location | 876 | 876 | 876 | 876 | 1 | | ||
| erc20Hash | 814 | 814 | 814 | 814 | 1 | | ||
| erc20Location | 831 | 831 | 831 | 831 | 1 | | ||
| erc721Hash | 821 | 821 | 821 | 821 | 1 | | ||
| erc721Location | 910 | 910 | 910 | 910 | 1 | | ||
| location | 406 | 406 | 406 | 406 | 1 | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.