-
Notifications
You must be signed in to change notification settings - Fork 279
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
perf: Fix cloning of executor #4955
perf: Fix cloning of executor #4955
Conversation
fbf620e
to
871dbcf
Compare
871dbcf
to
99a3113
Compare
so this comment was correct until executor wasm was added to snapshot. Was using |
|
yes, I know that. What I'm saying is if you can directly serialize/deserialize the |
99a3113
to
f2f2c5e
Compare
Changed to serialize |
9acb399
to
23648bd
Compare
Signed-off-by: Dmitry Murzin <diralik@yandex.ru>
Signed-off-by: Dmitry Murzin <diralik@yandex.ru>
Signed-off-by: Dmitry Murzin <diralik@yandex.ru>
Signed-off-by: Dmitry Murzin <diralik@yandex.ru>
23648bd
to
39befad
Compare
* perf: Fix cloning of executor * Serialize `wasmtime::Module` directly for snapshots --------- Signed-off-by: Dmitry Murzin <diralik@yandex.ru>
I think changing to EDIT: docs to |
// SAFETY: `Module::deserialize` is safe when calling for bytes received from `Module::serialize`. | ||
// We store serialization result on disk and then load it back so should be ok. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can't guarantee that...
How can we end in this situation that we serialize with one and deserialize with another version of |
@mversic update of iroha version which in theory should preserve backward compatibility for block store and snapshot. |
So we should change back to |
Opened #5009 |
Description
I am debugging tps of a single peer (#4727), measured performance of
Sumeragi::try_create_block
, and noticed that executor cloning takes about 25% oftry_create_block
. This is because ofLoadedExecutor::raw_executor
which was added for snapshot creation. Could be fixed by addingArc
.It is also interesting that other wasm-related code takes a lot of time, e.g.
wasmtime::Linker::instantitate
andwasmtime::Store::into_data
.Linked issue
Related: #4727
Benefits
Slightly optimize block creation performance
Checklist
CONTRIBUTING.md