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: frontend optimizations #3781

Merged
merged 3 commits into from
Feb 14, 2024

Conversation

charles-cooper
Copy link
Member

What I did

a couple compilation-time optimizations. bring total time down by 5% (vyper -f bytecode), and time in frontend code down by 20% (vyper -f annotated_ast).

How I did it

cache VyperNode.get_fields(), it's a hotspot
optimize get_common_types, the line rejected = [i for i in common_types if i not in common] is a hotspot

How to verify it

Commit message

Commit message for the final, squashed PR. (Optional, but reviewers will appreciate it! Please see our commit message style guide for what we would ideally like to see in a commit message.)

Description for the changelog

Cute Animal Picture

Put a link to a cute animal picture inside the parenthesis-->

@codecov-commenter
Copy link

codecov-commenter commented Feb 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (4b4e188) 84.98% compared to head (b9dec91) 84.99%.

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #3781   +/-   ##
=======================================
  Coverage   84.98%   84.99%           
=======================================
  Files          92       92           
  Lines       13709    13714    +5     
  Branches     3077     3079    +2     
=======================================
+ Hits        11651    11656    +5     
  Misses       1570     1570           
  Partials      488      488           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@charles-cooper charles-cooper merged commit 29205ba into vyperlang:master Feb 14, 2024
84 checks passed
@charles-cooper charles-cooper deleted the perf/frontend branch February 14, 2024 18:15
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