From 90a70d9b5b7d329694d4a63223f3f85cd3af30e4 Mon Sep 17 00:00:00 2001 From: "mergify[bot]" <37929162+mergify[bot]@users.noreply.github.com> Date: Thu, 3 Feb 2022 22:07:28 +0000 Subject: [PATCH] Use lazy_rent_collection directly (#22410) (#22920) (cherry picked from commit 9bc2592da1713faac982233f054ab311a531e4fc) Co-authored-by: Brooks Prumo --- runtime/src/bank.rs | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/runtime/src/bank.rs b/runtime/src/bank.rs index b48226b1e6..13c71e16bb 100644 --- a/runtime/src/bank.rs +++ b/runtime/src/bank.rs @@ -4543,7 +4543,7 @@ impl Bank { } fn collect_rent_eagerly(&self) { - if !self.enable_eager_rent_collection() { + if self.lazy_rent_collection.load(Relaxed) { return; } @@ -4568,14 +4568,6 @@ impl Bank { self.lazy_rent_collection.store(true, Relaxed); } - fn enable_eager_rent_collection(&self) -> bool { - if self.lazy_rent_collection.load(Relaxed) { - return false; - } - - true - } - fn rent_collection_partitions(&self) -> Vec { if !self.use_fixed_collection_cycle() { // This mode is for production/development/testing.