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

EOF: TXCREATE instruction #702

Merged
merged 7 commits into from
Apr 18, 2024
Merged

EOF: TXCREATE instruction #702

merged 7 commits into from
Apr 18, 2024

Conversation

gumb0
Copy link
Member

@gumb0 gumb0 commented Sep 6, 2023

Based on #553

@gumb0 gumb0 added the EOF label Sep 6, 2023
@gumb0 gumb0 changed the base branch from master to eof-create3 September 6, 2023 13:54
@gumb0 gumb0 force-pushed the eof-create4 branch 3 times, most recently from 3f4d668 to 6fb21e1 Compare September 11, 2023 13:35
@gumb0 gumb0 force-pushed the eof-create3 branch 2 times, most recently from cdd53d5 to 64374ea Compare September 14, 2023 17:00
@gumb0 gumb0 force-pushed the eof-create3 branch 2 times, most recently from bfe5b1e to 1197381 Compare September 20, 2023 11:07
@codecov
Copy link

codecov bot commented Sep 25, 2023

Codecov Report

Attention: Patch coverage is 99.20000% with 7 lines in your changes are missing coverage. Please review.

Project coverage is 98.32%. Comparing base (da95cc2) to head (1b2835f).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #702      +/-   ##
==========================================
+ Coverage   98.27%   98.32%   +0.05%     
==========================================
  Files         129      129              
  Lines       14650    15515     +865     
==========================================
+ Hits        14397    15255     +858     
- Misses        253      260       +7     
Flag Coverage Δ
statetests 27.80% <1.26%> (-1.58%) ⬇️
statetests-silkpre 18.83% <1.26%> (-1.07%) ⬇️
unittests 94.11% <99.20%> (+0.30%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
lib/evmone/advanced_instructions.cpp 100.00% <ø> (ø)
lib/evmone/baseline_instruction_table.cpp 100.00% <ø> (ø)
lib/evmone/eof.hpp 100.00% <100.00%> (ø)
lib/evmone/execution_state.hpp 96.77% <100.00%> (+0.54%) ⬆️
lib/evmone/instructions.hpp 100.00% <ø> (ø)
test/state/host.cpp 98.15% <100.00%> (+0.01%) ⬆️
test/state/host.hpp 100.00% <100.00%> (ø)
test/state/state.cpp 100.00% <100.00%> (ø)
test/state/state.hpp 100.00% <ø> (ø)
test/statetest/statetest_loader.cpp 96.72% <100.00%> (+0.04%) ⬆️
... and 7 more

@gumb0 gumb0 force-pushed the eof-create4 branch 2 times, most recently from 45f792f to d869e2b Compare September 28, 2023 09:35
@gumb0 gumb0 force-pushed the eof-create3 branch 5 times, most recently from 787bc15 to 8f2e254 Compare October 18, 2023 10:51
@gumb0 gumb0 force-pushed the eof-create3 branch 5 times, most recently from 544d807 to bb66969 Compare October 22, 2023 06:24
@pdobacz pdobacz force-pushed the eof-create4 branch 3 times, most recently from f5f0a21 to 7341929 Compare October 26, 2023 09:04
@gumb0 gumb0 force-pushed the eof-create3 branch 2 times, most recently from 327f5ca to 7ba50d5 Compare November 9, 2023 11:47
@gumb0 gumb0 force-pushed the eof-create3 branch 2 times, most recently from 4a02f97 to 3599674 Compare April 3, 2024 10:03
@gumb0 gumb0 force-pushed the eof-create4 branch 2 times, most recently from fd27842 to 17c09c7 Compare April 5, 2024 14:25
Base automatically changed from eof-create3 to master April 16, 2024 09:03
lib/evmone/execution_state.hpp Outdated Show resolved Hide resolved
lib/evmone/instructions_calls.cpp Outdated Show resolved Hide resolved
lib/evmone/instructions_calls.cpp Outdated Show resolved Hide resolved
lib/evmone/instructions_calls.cpp Outdated Show resolved Hide resolved

initcontainer =
state.get_tx_initcode_by_hash(intx::be::store<evmc::bytes32>(initcode_hash));
if (initcontainer.empty())
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you actually provide an empty initcontainer in the transaction?

Copy link
Member Author

@gumb0 gumb0 Apr 17, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually you cannot, we forgot to remove this with the introduction of this rule.

You cannot, but state.get_tx_initcode_by_hash() returns empty bytes_view when initcontainer not found.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please document this.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would change get_tx_initcode_by_hash returning std::optional

lib/evmone/instructions_calls.cpp Show resolved Hide resolved
test/state/host.cpp Outdated Show resolved Hide resolved
test/unittests/state_transition.cpp Outdated Show resolved Hide resolved
test/utils/bytecode.hpp Outdated Show resolved Hide resolved
@gumb0 gumb0 force-pushed the eof-create4 branch 2 times, most recently from cb87439 to 9b4d832 Compare April 17, 2024 13:46
test/utils/bytecode.hpp Show resolved Hide resolved
lib/evmone/instructions_calls.cpp Show resolved Hide resolved
lib/evmone/instructions_calls.cpp Show resolved Hide resolved
@gumb0 gumb0 requested a review from rodiazet April 18, 2024 13:25
@gumb0 gumb0 merged commit 44a029d into master Apr 18, 2024
24 checks passed
@gumb0 gumb0 deleted the eof-create4 branch April 18, 2024 13:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants