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

Drop the call kind runtime argument #159

Merged
merged 3 commits into from
Sep 10, 2019
Merged

Drop the call kind runtime argument #159

merged 3 commits into from
Sep 10, 2019

Conversation

chfast
Copy link
Member

@chfast chfast commented Sep 10, 2019

No description provided.

@codecov-io
Copy link

codecov-io commented Sep 10, 2019

Codecov Report

Merging #159 into master will decrease coverage by 4.11%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master     #159      +/-   ##
==========================================
- Coverage    90.2%   86.09%   -4.12%     
==========================================
  Files          21       21              
  Lines        2246     2229      -17     
  Branches      220      220              
==========================================
- Hits         2026     1919     -107     
- Misses        196      283      +87     
- Partials       24       27       +3

@axic
Copy link
Member

axic commented Sep 10, 2019

Is it such a big speed bump its worth the code duplication (in the binary)?

It doesn't matter for compiling to C, but it could if we actually manage compiling it to Wasm. However it is minor I suppose.

@axic
Copy link
Member

axic commented Sep 10, 2019

Couldn't you merge delegatecall/staticcall into call now with if constexpr ?

@chfast
Copy link
Member Author

chfast commented Sep 10, 2019

This is only done for removing this additional immediate value. I don't have any benchmarks for calls. There is a way to de-duplicate the code again (and for all other calls) by using a proxy function. But I want to keep the information about the call kind effectively in the function pointer.

template <kind>
void op_call(...)
{
    op_call_impl(kind, ...);
}

@chfast
Copy link
Member Author

chfast commented Sep 10, 2019

Couldn't you merge delegatecall/staticcall into call now with if constexpr ?

I could if I had more time. #160

@chfast
Copy link
Member Author

chfast commented Sep 10, 2019

I'm merging this leaving the mentioned issues for later discussion and future work.

@chfast chfast merged commit 9370155 into master Sep 10, 2019
@chfast chfast deleted the call_kind branch September 10, 2019 09:18
jwasinger pushed a commit to jwasinger/evmone that referenced this pull request Apr 27, 2021
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.

3 participants