Skip to contentSkip to conversation

mm-compaction-skip-fast-freepages-isolation-if-enough-freepages-are-isolated.patch removed from -mm tree

merged mm-stable Andrew Morton 1 participant 1 message Jun 9, 2023

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: mm: compaction: skip fast freepages isolation if enough freepages are isolated
has been removed from the -mm tree. Its filename was
mm-compaction-skip-fast-freepages-isolation-if-enough-freepages-are-isolated.patch

This patch was dropped because it was merged into the mm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: Baolin Wang <[email protected]>
Subject: mm: compaction: skip fast freepages isolation if enough freepages are isolated
Date: Thu, 25 May 2023 20:54:01 +0800

I've observed that fast isolation often isolates more pages than cc->migratepages, and the excess freepages will be released back to the buddy system. So skip fast freepages isolation if enough freepages are isolated to save some CPU cycles.

---

 mm/compaction.c |    4 ++++
 1 file changed, 4 insertions(+)
mm/compaction.c renamed from mm/compaction.c~mm-compaction-skip-fast-freepages-isolation-if-enough-freepages-are-isolated +4 -0
@@ -1528,6 +1528,10 @@ static void fast_isolate_freepages(struc
 
 		spin_unlock_irqrestore(&cc->zone->lock, flags);
 
+		/* Skip fast search if enough freepages isolated */
+		if (cc->nr_freepages >= cc->nr_migratepages)
+			break;
+
 		/*
 		 * Smaller scan on next order so the total scan is related
 		 * to freelist_scan_limit.

_

Patches currently in -mm which might be from [email protected] are