Skip to content

Commit

Permalink
Add inlines
Browse files Browse the repository at this point in the history
Signed-off-by: Danil <[email protected]>
  • Loading branch information
Deniallugo committed Oct 26, 2023
1 parent b0cf6e2 commit a566038
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
13 changes: 0 additions & 13 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions core/lib/multivm/src/versions/vm_latest/tracers/dispatcher.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,14 @@ impl<S: WriteStorage, H: HistoryMode> Default for TracerDispatcher<S, H> {
}

impl<S: WriteStorage, H: HistoryMode> DynTracer<S, SimpleMemory<H>> for TracerDispatcher<S, H> {
#[inline(always)]
fn before_decoding(&mut self, _state: VmLocalStateData<'_>, _memory: &SimpleMemory<H>) {
for tracer in self.tracers.iter() {
tracer.borrow_mut().before_decoding(_state, _memory);
}
}

#[inline(always)]
fn after_decoding(
&mut self,
_state: VmLocalStateData<'_>,
Expand All @@ -52,6 +54,7 @@ impl<S: WriteStorage, H: HistoryMode> DynTracer<S, SimpleMemory<H>> for TracerDi
}
}

#[inline(always)]
fn before_execution(
&mut self,
_state: VmLocalStateData<'_>,
Expand All @@ -65,6 +68,8 @@ impl<S: WriteStorage, H: HistoryMode> DynTracer<S, SimpleMemory<H>> for TracerDi
.before_execution(_state, _data, _memory, _storage.clone());
}
}

#[inline(always)]
fn after_execution(
&mut self,
_state: VmLocalStateData<'_>,
Expand All @@ -87,6 +92,7 @@ impl<S: WriteStorage, H: HistoryMode> VmTracer<S, H> for TracerDispatcher<S, H>
}
}
/// Run after each vm execution cycle
#[inline(always)]
fn finish_cycle(
&mut self,
_state: &mut ZkSyncVmState<S, H>,
Expand Down

0 comments on commit a566038

Please sign in to comment.