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: stabilize limiting functions number in a contract #5361

Merged
merged 14 commits into from
Nov 20, 2021

Conversation

Longarithm
Copy link
Member

@Longarithm Longarithm commented Nov 18, 2021

Stabilize limiting functions number in a contract to 10_000: #4954

While discussing #4826, we found that both contract compilation and function call require a lot of time, if number of wasm functions in it is huge. Even if we fix contract size, function number still makes a big difference.

To mitigate this issue, we limit number of functions in a contract. This shouldn't affect current mainnet contracts because maximal number of functions is ~5k.

Test plan

@matklad
Copy link
Contributor

matklad commented Nov 18, 2021

Note: we have stabilization template here: https://github.com/near/nearcore/blob/master/.github/PULL_REQUEST_TEMPLATE/feature_stabilization.md

@Longarithm Longarithm self-assigned this Nov 18, 2021
@matklad matklad mentioned this pull request Nov 19, 2021
2 tasks
@near-bulldozer near-bulldozer bot merged commit cd575e5 into master Nov 20, 2021
@near-bulldozer near-bulldozer bot deleted the stab-limit branch November 20, 2021 12:22
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.

4 participants