make ancient shrink consistent with shrink (#28457)
This commit is contained in:
parent
825b83c95c
commit
c89bd0d6a4
|
@ -4304,7 +4304,7 @@ impl AccountsDb {
|
||||||
let LoadAccountsIndexForShrink {
|
let LoadAccountsIndexForShrink {
|
||||||
alive_total,
|
alive_total,
|
||||||
mut alive_accounts,
|
mut alive_accounts,
|
||||||
unrefed_pubkeys,
|
mut unrefed_pubkeys,
|
||||||
} = self.load_accounts_index_for_shrink(stored_accounts);
|
} = self.load_accounts_index_for_shrink(stored_accounts);
|
||||||
|
|
||||||
// collect
|
// collect
|
||||||
|
@ -4315,7 +4315,7 @@ impl AccountsDb {
|
||||||
unrefed_pubkeys_collect
|
unrefed_pubkeys_collect
|
||||||
.lock()
|
.lock()
|
||||||
.unwrap()
|
.unwrap()
|
||||||
.push(unrefed_pubkeys);
|
.append(&mut unrefed_pubkeys);
|
||||||
alive_total_collect.fetch_add(alive_total, Ordering::Relaxed);
|
alive_total_collect.fetch_add(alive_total, Ordering::Relaxed);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -4421,10 +4421,7 @@ impl AccountsDb {
|
||||||
);
|
);
|
||||||
|
|
||||||
if !all_are_zero_lamports {
|
if !all_are_zero_lamports {
|
||||||
self.add_uncleaned_pubkeys_after_shrink(
|
self.add_uncleaned_pubkeys_after_shrink(slot, unrefed_pubkeys.into_iter().cloned());
|
||||||
slot,
|
|
||||||
unrefed_pubkeys.into_iter().flatten().cloned(),
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
start.stop();
|
start.stop();
|
||||||
|
|
Loading…
Reference in New Issue