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

chore: Fixes to the boojum integration PR #415

Merged
merged 15 commits into from
Nov 6, 2023

Conversation

StanislavBreadless
Copy link
Contributor

What ❔

Fixes comments by @Deniallugo and @mm-zk

Why ❔

Checklist

  • PR title corresponds to the body of PR (we generate changelog entries from PRs).
  • Tests for the changes have been added / updated.
  • Documentation comments have been added / updated.
  • Code has been formatted via zk fmt and zk lint.

@StanislavBreadless StanislavBreadless requested a review from a team as a code owner November 6, 2023 11:28
@StanislavBreadless StanislavBreadless changed the title Fixes to the boojum integration PR chore: Fixes to the boojum integration PR Nov 6, 2023
let pubdata = pubdata_information.build_pubdata();

assert!(
pubdata.len() / 32 <= OPERATOR_PROVIDED_L1_MESSENGER_PUBDATA_SLOTS - 2,
Copy link
Collaborator

Choose a reason for hiding this comment

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

nit: this assert is a little bit incorrect - if pubdata.len is not divisible by 32.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it is enforced by build_pubdata that it is divisible by 32

@@ -49,6 +47,7 @@ impl<S: WriteStorage, H: HistoryMode> Vm<S, H> {
tracers,
self.storage.clone(),
refund_tracers,
Some(PubdataTracer::new(self.batch_env.clone(), execution_mode)),
Copy link
Contributor

Choose a reason for hiding this comment

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

why do we need some if it's always enabled?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I am thinking that maybe custom implementations might not need it

Copy link
Contributor

Choose a reason for hiding this comment

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

what is the custom implementation?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I don't think that @mm-zk 's tooling would be broken if the pubdata tracer is always put there, though still I thought that our general approach is to preserve choices for the users of the VM

Copy link
Contributor

Choose a reason for hiding this comment

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

ok... just less checks is a bit better performance wise :)

Copy link
Collaborator

Choose a reason for hiding this comment

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

I don't have strong opinions here (as long as this tracer doesn't prevent test bootloader from running)

core/lib/types/src/eth_sender.rs Outdated Show resolved Hide resolved
Copy link
Contributor

github-actions bot commented Nov 6, 2023

Detected VM performance changes

Benchmark name Difference in runtime
slot_hash_collision -2.6%
write_and_decode -2.6%
event_spam -2.5%
decode_shl_sub -2.7%
access_memory -2.5%

@StanislavBreadless StanislavBreadless merged commit ac9c6e2 into boojum-integration Nov 6, 2023
@StanislavBreadless StanislavBreadless deleted the sb-fixes-for-pr branch November 6, 2023 14:07
toni-calvin pushed a commit to lambdaclass/zksync-era that referenced this pull request Aug 8, 2024
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.

4 participants