Problem
The pre-charge sequence in process_program_queue (ethexe/runtime/common/src/lib.rs) — charge_for_program, charge_for_code_metadata, charge_for_instrumented_code — is inherited from the Vara processor, which loads program + code data on every dispatch. In ethexe that data is not loaded per dispatch, so the charging is incorrect:
charge_for_instrumented_code(block_config, 0) is passed a hardcoded 0 length (placeholder);
- gas is charged for loading data that ethexe does not load each dispatch.
Goal
Rework the pre-charge algorithm for ethexe's execution model so gas is charged correctly for what is actually loaded/executed per dispatch, rather than reusing Vara's per-dispatch data-loading charges.
Problem
The pre-charge sequence in
process_program_queue(ethexe/runtime/common/src/lib.rs) —charge_for_program,charge_for_code_metadata,charge_for_instrumented_code— is inherited from the Vara processor, which loads program + code data on every dispatch. In ethexe that data is not loaded per dispatch, so the charging is incorrect:charge_for_instrumented_code(block_config, 0)is passed a hardcoded0length (placeholder);Goal
Rework the pre-charge algorithm for ethexe's execution model so gas is charged correctly for what is actually loaded/executed per dispatch, rather than reusing Vara's per-dispatch data-loading charges.