From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7D9B9C433F5 for ; Tue, 3 May 2022 16:20:09 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id D10796B009E; Tue, 3 May 2022 12:20:08 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id CBF756B009F; Tue, 3 May 2022 12:20:08 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B877F6B00A0; Tue, 3 May 2022 12:20:08 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.26]) by kanga.kvack.org (Postfix) with ESMTP id AC16B6B009E for ; Tue, 3 May 2022 12:20:08 -0400 (EDT) Received: from smtpin21.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay11.hostedemail.com (Postfix) with ESMTP id 8B2D0806B1 for ; Tue, 3 May 2022 16:20:08 +0000 (UTC) X-FDA: 79424943696.21.88FF115 Received: from mail-ot1-f48.google.com (mail-ot1-f48.google.com [209.85.210.48]) by imf13.hostedemail.com (Postfix) with ESMTP id C3C4720089 for ; Tue, 3 May 2022 16:19:55 +0000 (UTC) Received: by mail-ot1-f48.google.com with SMTP id y14-20020a9d460e000000b00605ee347da1so9425073ote.8 for ; Tue, 03 May 2022 09:20:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cmpxchg-org.20210112.gappssmtp.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=pfrAvdzMCVZFNr1VGcMbw6Nne+rB0bgZkaiibREqMIU=; b=bjX47vSczG1UpwH3woF/YW1tOq4qwOigdHqC8RnYt8ontvKStM/OyGy6Fg4gb/gOBd aiqht5tAc9gdlWq600yIp3edBd36547azxQvtgNA//tbrO39YIcdPwAtKWqmNcOB71Sg 8xVeZ834lbX3e90FUK3DATi0XMfR8tTasux+j/T1OjkSaPOIh9yTlvfWWSkfwDaLPCPE Lny6fgHDdw84kBu5jCnf5esY0y48lkdDrHJ6NMY5HaDrUWobWG0hltWpfBzeIwJ786x7 FdCvX6IxoV6MYoZKZeaBBU9DR6N7LnUB6mARk+X39bCaaLlwQGfOZuDU7Lgx9LHAt1cy 7SUQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=pfrAvdzMCVZFNr1VGcMbw6Nne+rB0bgZkaiibREqMIU=; b=TvKPIrpVAz+NU7Xrg4v/9UqMU6qTmrMLbgH85a4HO1gUsweQdrpNaW8EkaXvVByaAL M3Y2HqdBMn7Z4adg5Xw+AkzaKO14H1ALCxL/h4P+K1GdThwwuj8YlXFTFj1Bhls17qsc zypYPGOaocg8ZhwwvYqISySu1sZVLZzDs9Jp7WmpkLUsxq/3I+xVOqOo5nGqj6oXWFSt kcuso8CbGrjqSiniqZ4gMuM+0Bj60VVphRYeDoeTkIDVnhKiJLLxlQcrd/lNjHs6aRVd TkVA5wt0fyJUGY/lF9BZO3qbRwwKKUY0HHJx/MSkt8pBvhxf6rj6LEaPA1TAQGaK0diy jOyA== X-Gm-Message-State: AOAM533Ao8To0mewdBoXLIOuaytthdNKeCtPhDYoq+fYN8x+sAraUovp zR7c37HSE3Pr9I4S2ueCtpfx3w== X-Google-Smtp-Source: ABdhPJyf1vYXk/t1rih2OFKGuCF7QinnVRCE8lSe9hdTQjKHj2zYLNKr5Rv67OSeKwElMSDqc07dVg== X-Received: by 2002:a05:6830:1183:b0:606:698:717e with SMTP id u3-20020a056830118300b006060698717emr5424639otq.309.1651594806311; Tue, 03 May 2022 09:20:06 -0700 (PDT) Received: from localhost ([8.34.116.185]) by smtp.gmail.com with ESMTPSA id k18-20020a9d7612000000b0060603221254sm4044642otl.36.2022.05.03.09.20.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 03 May 2022 09:20:05 -0700 (PDT) Date: Tue, 3 May 2022 09:19:16 -0700 From: Johannes Weiner To: Wonhyuk Yang Cc: Mel Gorman , Andrew Morton , Ohhoon Kwon , JaeSang Yoo , Jiyoup Kim , Donghyeok Kim , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm/page_alloc: cache the result of node_dirty_ok() Message-ID: References: <20220430011032.64071-1-vvghjk1234@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220430011032.64071-1-vvghjk1234@gmail.com> X-Rspam-User: X-Rspamd-Server: rspam11 X-Rspamd-Queue-Id: C3C4720089 X-Stat-Signature: xdnkyxd6ky5hkoit9w5o9pt8x5iuac51 Authentication-Results: imf13.hostedemail.com; dkim=pass header.d=cmpxchg-org.20210112.gappssmtp.com header.s=20210112 header.b=bjX47vSc; spf=pass (imf13.hostedemail.com: domain of hannes@cmpxchg.org designates 209.85.210.48 as permitted sender) smtp.mailfrom=hannes@cmpxchg.org; dmarc=pass (policy=none) header.from=cmpxchg.org X-HE-Tag: 1651594795-152504 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Sat, Apr 30, 2022 at 10:10:32AM +0900, Wonhyuk Yang wrote: > To spread dirty page, nodes are checked whether > it reached the dirty limit using the expensive > node_dirty_ok(). To reduce the number of calling > node_dirty_ok(), last node that hit the dirty > limit is cached. > > Instead of caching the node, caching both node > and it's result of node_dirty_ok() can reduce > the number of calling node_dirty_ok() more than > before. > > Signed-off-by: Wonhyuk Yang Acked-by: Johannes Weiner Looks good to me. I like Andrew's naming fixlet as well.