Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp89181imu; Fri, 14 Dec 2018 15:04:28 -0800 (PST) X-Google-Smtp-Source: AFSGD/UflNJsMDZgVToXJZzU6l4hInXsm9cZvVF99G/REsfio6LuJzc0rdSDISWSXueMMtJV2o3s X-Received: by 2002:a17:902:2c83:: with SMTP id n3mr4655082plb.104.1544828668850; Fri, 14 Dec 2018 15:04:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1544828668; cv=none; d=google.com; s=arc-20160816; b=MHTPRnYjuhThSbmJT6jhO9rB7YdISXU0HmDMJz5bcxni3K9RPwL9rnru8+rQROVcHq g5BaE2/oncVteXr46n7dy3a1J9I6u8Y3dla8/YTY/2JMnnuhTAFx4+D5Zgd6Qe31iLET S7Y1hTMfY6x5ICzyxSu+HfEsyxuaRcEVoqwDfj5IzP9PQIPs+hfiX1fjtEXJm5yaI4He +FNaq+RXbE4iDB+LwDH1FxD7qRjHXq3DlEDcDlsJgcmEnBPD3MZXgY7AGGRx094VhYPU QJgKOiOlNhRP3G2IHub9tPkiBF/yxOxuBj3IsoOotE2RhDtQTzMZPWGVCxx5CYniLShb vI4A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=8ylXBwUHUp/AHX4BZPSE6g0fwobKPJEsFH/Fxi+Stfo=; b=Vtk56fZJj3XPEZHSXmpaHG5VqT5vO9HzgVpj6Eoaz94Kq2dRfSUa+hSY+8Ktu8t26r vyJj1BFmJT5zilphO1Gpi3IpCZkycHbH0AXjS/6GQlRDsXO1F5Y+E1Vm7FlCWFV1yx4q CCaDf0tfHdAHRo5MgGODjTm6jdUnxGz1Z+6yb3kPntPq93L6Jx0AjwqMwmiGkicDQIlC Z+ZNpBQAmagAdKW4QXQMXaRddEDi306gbiLKALhQjU7l74YMHiWg3p8vAZkYXPMVXSGM R56OZwHeCbhRizmhOvHTDAZyaFd/vcCHvjHTOvkq+COaA4+2T5YHy4dM3rq42KghEE9m G2wA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y17si4788517pll.10.2018.12.14.15.04.12; Fri, 14 Dec 2018 15:04:28 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730682AbeLNXDN (ORCPT + 99 others); Fri, 14 Dec 2018 18:03:13 -0500 Received: from outbound-smtp13.blacknight.com ([46.22.139.230]:41545 "EHLO outbound-smtp13.blacknight.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729029AbeLNXDN (ORCPT ); Fri, 14 Dec 2018 18:03:13 -0500 Received: from mail.blacknight.com (unknown [81.17.254.10]) by outbound-smtp13.blacknight.com (Postfix) with ESMTPS id 5F3B91C2072 for ; Fri, 14 Dec 2018 23:03:11 +0000 (GMT) Received: (qmail 31182 invoked from network); 14 Dec 2018 23:03:11 -0000 Received: from unknown (HELO stampy.163woodhaven.lan) (mgorman@techsingularity.net@[37.228.245.71]) by 81.17.254.9 with ESMTPA; 14 Dec 2018 23:03:11 -0000 From: Mel Gorman To: Linux-MM Cc: David Rientjes , Andrea Arcangeli , Linus Torvalds , Michal Hocko , ying.huang@intel.com, kirill@shutemov.name, Andrew Morton , Linux List Kernel Mailing , Mel Gorman Subject: [PATCH 02/14] mm, compaction: Rearrange compact_control Date: Fri, 14 Dec 2018 23:02:58 +0000 Message-Id: <20181214230310.572-3-mgorman@techsingularity.net> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20181214230310.572-1-mgorman@techsingularity.net> References: <20181214230310.572-1-mgorman@techsingularity.net> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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. Signed-off-by: Mel Gorman --- mm/internal.h | 6 +++--- 1 file 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; struct compact_control { struct list_head freepages; /* List of free pages to migrate to */ struct list_head migratepages; /* List of pages being migrated */ - struct zone *zone; unsigned int nr_freepages; /* Number of isolated free pages */ unsigned int nr_migratepages; /* Number of pages to migrate */ - unsigned long total_migrate_scanned; - unsigned long total_free_scanned; unsigned long free_pfn; /* isolate_freepages search base */ unsigned long migrate_pfn; /* isolate_migratepages search base */ unsigned long last_migrated_pfn;/* Not yet flushed page being freed */ + struct zone *zone; + unsigned long total_migrate_scanned; + unsigned long total_free_scanned; const gfp_t gfp_mask; /* gfp mask of a direct compactor */ int order; /* order a direct compactor needs */ int migratetype; /* migratetype of direct compactor */ -- 2.16.4