@@ -24,6 +24,23 @@ const bytes max_code_sections = [] {
2424 return eof_code_sections_1024;
2525}();
2626
27+ const bytes max_containers = [] {
28+ bytecode code;
29+ for (auto i = 0 ; i < 256 ; ++i)
30+ code += eofcreate ()
31+ .container (static_cast <uint8_t >(i))
32+ .input (push0 (), push0 ())
33+ .salt (push0 ())
34+ .value (push0 ()) +
35+ OP_POP;
36+ code += bytecode{OP_STOP};
37+
38+ auto container = eof_bytecode (code, 4 );
39+ for (auto i = 0 ; i < 256 ; ++i)
40+ container = container.container (eof_bytecode (OP_INVALID));
41+ return container;
42+ }();
43+
2744const bytes max_nested_containers = [] {
2845 bytecode code{};
2946 bytecode nextcode = eof_bytecode (OP_INVALID);
@@ -186,6 +203,8 @@ void eof_validation(benchmark::State& state, evmone::ContainerKind kind, const b
186203using enum evmone::ContainerKind;
187204BENCHMARK_CAPTURE (eof_validation, max_code_sections, runtime, max_code_sections)
188205 ->Unit(benchmark::kMicrosecond );
206+ BENCHMARK_CAPTURE (eof_validation, max_containers, runtime, max_containers)
207+ ->Unit(benchmark::kMicrosecond );
189208BENCHMARK_CAPTURE (eof_validation, stack_height_max_span, runtime, stack_height_max_span)
190209 ->Unit(benchmark::kMicrosecond );
191210BENCHMARK_CAPTURE (eof_validation, max_nested_containers, runtime, max_nested_containers)
0 commit comments