Skip to content

Commit

Permalink
Adds comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
Lichtso committed Feb 22, 2024
1 parent ecf8fa1 commit e8c9cec
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions svm/src/transaction_processor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -731,6 +731,10 @@ impl<FG: ForkGraph> TransactionBatchProcessor<FG> {

let mut timings = ExecuteDetailsTimings::default();
load_program_metrics.submit_datapoint(&mut timings);
// There can be two entries per program when the environment changes.
// One for the old environment before the epoch boundary and one for the new environment after the epoch boundary.
// These two entries have the same deployment slot, so they must differ in their effective slot instead.
// This is done by setting the effective slot of the entry for the new environment to the epoch boundary.
loaded_program.effective_slot = loaded_program
.effective_slot
.max(self.epoch_schedule.get_first_slot_in_epoch(effective_epoch));
Expand Down

0 comments on commit e8c9cec

Please sign in to comment.