fn inspect_and_collect_results(
        &mut self,
        dispatcher: &mut TracerDispatcher<S, H::Vm1_5_2>,
        execution_mode: VmExecutionMode,
        with_refund_tracer: bool,
        custom_pubdata_tracer: Option<PubdataTracer<S>>,
    ) -> (VmExecutionStopReason, VmExecutionResultAndLogs) {
        let refund_tracers = with_refund_tracer
            .then_some(RefundsTracer::new(self.batch_env.clone(), self.subversion));
        let mut tx_tracer: DefaultExecutionTracer<S, H::Vm1_5_2> = DefaultExecutionTracer::new(
            self.system_env.default_validation_computational_gas_limit,
            self.system_env
                .base_system_smart_contracts
                .evm_emulator
                .is_some(),
            execution_mode,
            mem::take(dispatcher),
            self.storage.clone(),
            refund_tracers,
            custom_pubdata_tracer.or_else(|| {
                Some(PubdataTracer::new(
                    self.batch_env.clone(),
                    execution_mode,
                    self.subversion,
                    None,
                ))
            }),
            self.subversion,
        );

        let timestamp_initial = Timestamp(self.state.local_state.timestamp);
        let cycles_initial = self.state.local_state.monotonic_cycle_counter;
        let gas_remaining_before = self.gas_remaining();

        let stop_reason = self.execute_with_default_tracer(&mut tx_tracer);

        let gas_remaining_after = self.gas_remaining();

        let logs = self.collect_execution_logs_after_timestamp(timestamp_initial);

        let (refunds, pubdata_published) = tx_tracer
            .refund_tracer
            .as_ref()
            .map(|x| (x.get_refunds(), x.pubdata_published()))
            .unwrap_or_default();

        let statistics = self.get_statistics(
            timestamp_initial,
            cycles_initial,
            gas_remaining_before,
            gas_remaining_after,
            pubdata_published,
            logs.total_log_queries_count,
            circuit_statistic_from_cycles(tx_tracer.circuits_tracer.statistics),
        );
        let result = tx_tracer.result_tracer.into_result();
        let factory_deps_marked_as_known = VmEvent::extract_bytecodes_marked_as_known(&logs.events);
        let dynamic_factory_deps = self.decommit_dynamic_bytecodes(factory_deps_marked_as_known);
        *dispatcher = tx_tracer.dispatcher;

        let result = VmExecutionResultAndLogs {
            result,
            logs,
            statistics,
            refunds,
            dynamic_factory_deps,
        };

        (stop_reason, result)
    }
Execute VM with given traces until the stop reason is reached.
Collect the result from the default tracers.
core/lib/multivm/src/versions/vm_latest/implementation/execution.rs