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

Reduce stack operations in make_setter #2468

Merged
merged 3 commits into from
Oct 4, 2021

Conversation

charles-cooper
Copy link
Member

@charles-cooper charles-cooper commented Oct 3, 2021

What I did

Optimize and simplify make_setter, cleaning out some inefficient bytecode that was introduced in #2447

How I did it

How to verify it

Description for the changelog

Cute Animal Picture

image

@codecov-commenter
Copy link

codecov-commenter commented Oct 3, 2021

Codecov Report

Merging #2468 (a07179d) into master (93287e5) will increase coverage by 0.14%.
The diff coverage is 71.11%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2468      +/-   ##
==========================================
+ Coverage   84.39%   84.53%   +0.14%     
==========================================
  Files          93       93              
  Lines        9271     9223      -48     
  Branches     2102     2084      -18     
==========================================
- Hits         7824     7797      -27     
+ Misses        952      938      -14     
+ Partials      495      488       -7     
Impacted Files Coverage Δ
vyper/old_codegen/return_.py 93.75% <ø> (ø)
vyper/old_codegen/abi.py 70.29% <50.00%> (ø)
vyper/old_codegen/parser_utils.py 83.37% <68.42%> (+3.91%) ⬆️
vyper/old_codegen/expr.py 79.31% <100.00%> (ø)
..._codegen/function_definitions/external_function.py 96.93% <100.00%> (-0.04%) ⬇️
vyper/old_codegen/self_call.py 94.73% <100.00%> (ø)
vyper/old_codegen/stmt.py 88.00% <100.00%> (ø)
vyper/old_codegen/types/check.py 100.00% <100.00%> (ø)
vyper/builtin_functions/functions.py 88.95% <0.00%> (-0.35%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 93287e5...a07179d. Read the comment docs.

@charles-cooper charles-cooper changed the title Reduce copies in make_setter Reduce stack operations in make_setter Oct 3, 2021
simplify the number of cases, and also improve the heuristic for whether
offsets can be calculated at compile time
this avoids a double dereference.
@charles-cooper charles-cooper merged commit cf74331 into vyperlang:master Oct 4, 2021
@charles-cooper charles-cooper deleted the reduce_copies branch October 4, 2021 18:57
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.

None yet

3 participants