summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMel Gorman <mgorman@techsingularity.net>2019-03-05 18:44:28 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2019-03-06 00:07:16 -0500
commitc5943b9c5312d4fa23175ff146e901b865e4a60a (patch)
tree625c23c5a4844d31b5618311b2233c91bc3072de
parentc5fbd937b603885f1db3280ca212ed28add895bc (diff)
mm, compaction: rearrange compact_control
compact_control spans two cache lines with write-intensive lines on both. Rearrange so the most write-intensive fields are in the same cache line. This has a negligible impact on the overall performance of compaction and is more a tidying exercise than anything. Link: http://lkml.kernel.org/r/20190118175136.31341-3-mgorman@techsingularity.net Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Andrea Arcangeli <aarcange@redhat.com> Cc: Dan Carpenter <dan.carpenter@oracle.com> Cc: David Rientjes <rientjes@google.com> Cc: YueHaibing <yuehaibing@huawei.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--mm/internal.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/mm/internal.h b/mm/internal.h
index 5564841fce36..867af5425432 100644
--- a/mm/internal.h
+++ b/mm/internal.h
@@ -184,14 +184,14 @@ extern int user_min_free_kbytes;
184struct compact_control { 184struct compact_control {
185 struct list_head freepages; /* List of free pages to migrate to */ 185 struct list_head freepages; /* List of free pages to migrate to */
186 struct list_head migratepages; /* List of pages being migrated */ 186 struct list_head migratepages; /* List of pages being migrated */
187 struct zone *zone;
188 unsigned int nr_freepages; /* Number of isolated free pages */ 187 unsigned int nr_freepages; /* Number of isolated free pages */
189 unsigned int nr_migratepages; /* Number of pages to migrate */ 188 unsigned int nr_migratepages; /* Number of pages to migrate */
190 unsigned long total_migrate_scanned;
191 unsigned long total_free_scanned;
192 unsigned long free_pfn; /* isolate_freepages search base */ 189 unsigned long free_pfn; /* isolate_freepages search base */
193 unsigned long migrate_pfn; /* isolate_migratepages search base */ 190 unsigned long migrate_pfn; /* isolate_migratepages search base */
194 unsigned long last_migrated_pfn;/* Not yet flushed page being freed */ 191 unsigned long last_migrated_pfn;/* Not yet flushed page being freed */
192 struct zone *zone;
193 unsigned long total_migrate_scanned;
194 unsigned long total_free_scanned;
195 const gfp_t gfp_mask; /* gfp mask of a direct compactor */ 195 const gfp_t gfp_mask; /* gfp mask of a direct compactor */
196 int order; /* order a direct compactor needs */ 196 int order; /* order a direct compactor needs */
197 int migratetype; /* migratetype of direct compactor */ 197 int migratetype; /* migratetype of direct compactor */