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

Keep only the last event index in ExecutionContextSnapshot #4534

Merged
merged 1 commit into from
Nov 16, 2023

Conversation

bilboquet
Copy link
Contributor

@bilboquet bilboquet commented Nov 14, 2023

  • document all added functions
  • try in sandbox /simulation/labnet
    • if part of node-launch, checked using the resync_check flag
  • unit tests on the added/changed features
    • make tests compile
    • make tests pass
  • add logs allowing easy debugging in case the changes caused problems
  • if the API has changed, update the API specification

@bilboquet
Copy link
Contributor Author

Slot execution time comparison

Code has been instrumented with many traces, hence the execution time for 5k transactions which used to be around 80ms on this computer raised to around 200ms on average.
Anyway the trace are the same in both cases and with the fix the code perform better.

test case without fix with fix
5k failing roll sells (each fails generate an event) 4707 ms 259 ms
Execution time of 5k roll buys 173 ms 161 ms
Execution time of 5k roll sells 198 ms 168 ms
Execution time of 5k transactions 203 ms 191 ms
2 Execution of 1k messages executing 454 async msg took 270047 µs
executing 454 async msg took 215032 µs
executing 92 async msg took 30476 µs
executing 454 async msg took 264684 µs
executing 454 async msg took 219176 µs
executing 92 async msg took 31194 µs
executing 454 async msg took 200977 µs
executing 454 async msg took 169043 µs
executing 92 async msg took 28021 µs
executing 454 async msg took 201414 µs
executing 454 async msg took 169810 µs
executing 92 async msg took 27887 µs

@bilboquet bilboquet requested review from Eitu33 and damip November 14, 2023 18:52
@damip
Copy link
Member

damip commented Nov 14, 2023

Nice study of execution times ! I think we are good thanks to this fix :)

@Leo-Besancon Leo-Besancon linked an issue Nov 16, 2023 that may be closed by this pull request
@Leo-Besancon Leo-Besancon changed the base branch from main to buildnet_wip November 16, 2023 16:00
@bilboquet bilboquet merged commit d054524 into buildnet_wip Nov 16, 2023
9 of 11 checks passed
@bilboquet bilboquet deleted the fix-event-snapshot branch November 16, 2023 16:01
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.

Remove events from speculative state snapshot
3 participants