Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3412986imu; Fri, 18 Jan 2019 09:56:18 -0800 (PST) X-Google-Smtp-Source: ALg8bN5gf08CJQx1FCVwxL5Xn+ofgyFAbfrUk0ijfJQs2jndBKSp/hgQboAvnb1oItfewfO5VTzs X-Received: by 2002:a63:6ac5:: with SMTP id f188mr18808169pgc.165.1547834178587; Fri, 18 Jan 2019 09:56:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547834178; cv=none; d=google.com; s=arc-20160816; b=HBZr/fsViNy0xph1H/VMJ2KqRXEji+Wx/9097Q6YCaqbNfPeCSOQS1JcneiBoHaUha gQC6X86K52Q3ZpYczqE8hOg9cdp8MaAoWHan0vvwb78bejoG71QdgZBJlW02e3k15z1d cSh8CymRhQwZT77Ms/UEcE1fFVYKz2V/k+M87Ago8wwQll85rpphRQl3PuokDOAwWH+9 lz2sg2N/qIab4j2IZLZSjUj5Sp59HrrGd0IwiMG3KoNfu5FCdQnrix30yYeWxUNeQ3Sz BG7nv9+Wb3HoakWJpHntVIPPKBro0a+PIDk/uveE2b1aHQZs1Pk4wc9OjDv4ku2CdSJQ 29Xw== 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=XY602cqHy6JklbpqaWogx0es27AK1EZmJD68GbOsrjc=; b=yxRNanHgqmH41U5AW1be2+P/H0sql62Lz4wMdcoIT25ma0esNYmkH5SYw1X0P3rHn4 pQK2ybTz6FEIGSp5mxjjjOpUfJdCJo7MLH/lnlKTiZe79br1hDkt720AroB7Jz5lWABe 6Y58ONfPRzCACwVkgR3tm0TrqEMEhZmSESsbulsg2yZ5jBEdnrpZHBj4ZS5Mt+pN2fOD EwEM/lRnJFoqmYIbOjZcH/+3FJHXEjG/wDmSmNHCXShHO/vHcz7t97+4hTP3ESJrPaXq n28ddoQrCgaC6yB0xJZ5o4UbXLh7QWBLcQEsJhur1BPegDQrYCg0eIp2RlsyFtp4/20D 7Jww== 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 q24si4713153pgi.334.2019.01.18.09.55.59; Fri, 18 Jan 2019 09:56:18 -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 S1728848AbfARRxK (ORCPT + 99 others); Fri, 18 Jan 2019 12:53:10 -0500 Received: from outbound-smtp13.blacknight.com ([46.22.139.230]:55130 "EHLO outbound-smtp13.blacknight.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728426AbfARRxK (ORCPT ); Fri, 18 Jan 2019 12:53:10 -0500 Received: from mail.blacknight.com (unknown [81.17.254.16]) by outbound-smtp13.blacknight.com (Postfix) with ESMTPS id 7EC9B1C35AC for ; Fri, 18 Jan 2019 17:53:08 +0000 (GMT) Received: (qmail 2023 invoked from network); 18 Jan 2019 17:53:08 -0000 Received: from unknown (HELO stampy.163woodhaven.lan) (mgorman@techsingularity.net@[37.228.229.96]) by 81.17.254.9 with ESMTPA; 18 Jan 2019 17:53:08 -0000 From: Mel Gorman To: Andrew Morton Cc: David Rientjes , Andrea Arcangeli , Vlastimil Babka , Linux List Kernel Mailing , Linux-MM , Mel Gorman Subject: [PATCH 08/22] mm, compaction: Ignore the fragmentation avoidance boost for isolation and compaction Date: Fri, 18 Jan 2019 17:51:22 +0000 Message-Id: <20190118175136.31341-9-mgorman@techsingularity.net> X-Mailer: git-send-email 2.16.4 In-Reply-To: <20190118175136.31341-1-mgorman@techsingularity.net> References: <20190118175136.31341-1-mgorman@techsingularity.net> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When pageblocks get fragmented, watermarks are artifically boosted to reclaim pages to avoid further fragmentation events. However, compaction is often either fragmentation-neutral or moving movable pages away from unmovable/reclaimable pages. As the true watermarks are preserved, allow compaction to ignore the boost factor. The expected impact is very slight as the main benefit is that compaction is slightly more likely to succeed when the system has been fragmented very recently. On both 1-socket and 2-socket machines for THP-intensive allocation during fragmentation the success rate was increased by less than 1% which is marginal. However, detailed tracing indicated that failure of migration due to a premature ENOMEM triggered by watermark checks were eliminated. Signed-off-by: Mel Gorman Acked-by: Vlastimil Babka --- mm/page_alloc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/page_alloc.c b/mm/page_alloc.c index fc769ff4fb2c..6607cb7131b0 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -3071,7 +3071,7 @@ int __isolate_free_page(struct page *page, unsigned int order) * watermark, because we already know our high-order page * exists. */ - watermark = min_wmark_pages(zone) + (1UL << order); + watermark = zone->_watermark[WMARK_MIN] + (1UL << order); if (!zone_watermark_ok(zone, 0, watermark, 0, ALLOC_CMA)) return 0; -- 2.16.4