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

ancient_pack: don't sort slots #1743

Closed
wants to merge 1 commit into from

Conversation

HaoranYi
Copy link

Problem

We don't need to sort the slots for ancient storage packing. These slots will
be sorted by different criteria later.

Summary of Changes

Don't sort the slots for ancient storage packing.

Fixes #

@HaoranYi
Copy link
Author

A follow up of #1730

@HaoranYi HaoranYi force-pushed the accounts-db/donot_sort branch from 3373aa9 to 80e05b5 Compare June 14, 2024 16:17
@@ -9774,6 +9774,12 @@ pub mod tests {
fn get_storage_for_slot(&self, slot: Slot) -> Option<Arc<AccountStorageEntry>> {
self.storage.get_slot_storage_entry(slot)
}

fn get_sorted_potential_ancient_slots(&self, oldest_non_ancient_slot: Slot) -> Vec<Slot> {
Copy link
Author

@HaoranYi HaoranYi Jun 14, 2024

Choose a reason for hiding this comment

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

Move the original get_sorted_potential_ancient_slots to test-only context to keep test happy 😄

@HaoranYi HaoranYi force-pushed the accounts-db/donot_sort branch from 5d90a88 to 46e2531 Compare June 17, 2024 14:36
@HaoranYi HaoranYi force-pushed the accounts-db/donot_sort branch from 46e2531 to 5e50b38 Compare June 17, 2024 22:17
@HaoranYi HaoranYi closed this Jun 17, 2024
@HaoranYi
Copy link
Author

won't do.

@HaoranYi HaoranYi deleted the accounts-db/donot_sort branch June 17, 2024 22:32
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.

1 participant