Skip to content

Commit

Permalink
baseline: Fix code passing to notify_execution_start
Browse files Browse the repository at this point in the history
  • Loading branch information
rodiazet committed Nov 25, 2022
1 parent 1a49010 commit 9676895
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
5 changes: 3 additions & 2 deletions lib/evmone/baseline.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,8 @@ void dispatch_cgoto(
#endif
} // namespace

evmc_result execute(const VM& vm, ExecutionState& state, const CodeAnalysis& analysis) noexcept
evmc_result execute(
const VM& vm, ExecutionState& state, const CodeAnalysis& analysis) noexcept
{
state.analysis.baseline = &analysis; // Assign code analysis for instruction implementations.

Expand All @@ -327,7 +328,7 @@ evmc_result execute(const VM& vm, ExecutionState& state, const CodeAnalysis& ana
auto* tracer = vm.get_tracer();
if (INTX_UNLIKELY(tracer != nullptr))
{
tracer->notify_execution_start(state.rev, *state.msg, code);
tracer->notify_execution_start(state.rev, *state.msg, state.original_code);
dispatch<true>(cost_table, state, code, tracer);
}
else
Expand Down
4 changes: 2 additions & 2 deletions test/unittests/tracing_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,9 @@ class tracing : public Test
{}

public:
explicit EmptyTracer() noexcept {}
explicit EmptyTracer() noexcept = default;

size_t code_size() const noexcept { return m_code.size(); }
[[nodiscard]] size_t code_size() const noexcept { return m_code.size(); }
};
};

Expand Down

0 comments on commit 9676895

Please sign in to comment.