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 X-Spam-Level: X-Spam-Status: No, score=-5.4 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1410BC43461 for ; Tue, 8 Sep 2020 17:55:32 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 7DFB8206A5 for ; Tue, 8 Sep 2020 17:55:31 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=chrisdown.name header.i=@chrisdown.name header.b="mXw6ltxY" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7DFB8206A5 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chrisdown.name Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 8BD186B0037; Tue, 8 Sep 2020 13:55:30 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 846406B0055; Tue, 8 Sep 2020 13:55:30 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 736636B005A; Tue, 8 Sep 2020 13:55:30 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0099.hostedemail.com [216.40.44.99]) by kanga.kvack.org (Postfix) with ESMTP id 585516B0037 for ; Tue, 8 Sep 2020 13:55:30 -0400 (EDT) Received: from smtpin20.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id 0CF631EF2 for ; Tue, 8 Sep 2020 17:55:30 +0000 (UTC) X-FDA: 77240646420.20.dust03_320ce79270d6 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin20.hostedemail.com (Postfix) with ESMTP id CFE1E180C07A3 for ; Tue, 8 Sep 2020 17:55:29 +0000 (UTC) X-HE-Tag: dust03_320ce79270d6 X-Filterd-Recvd-Size: 3812 Received: from mail-ej1-f66.google.com (mail-ej1-f66.google.com [209.85.218.66]) by imf44.hostedemail.com (Postfix) with ESMTP for ; Tue, 8 Sep 2020 17:55:29 +0000 (UTC) Received: by mail-ej1-f66.google.com with SMTP id r7so10478975ejs.11 for ; Tue, 08 Sep 2020 10:55:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chrisdown.name; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=TV+cBfgEjWVdVoWjdO7bHOv3j1JRscD3Rid2RHJ0lps=; b=mXw6ltxYv094vVJyfjQHwLyMd/gz4JbYYLmPyFYL2epCAoy8RwjhTkYZqVsbcIbHiA 9NRTBM3UutItGJYkE50cl713yDhTAbsoPROgxlSZvJdZAxVxWL+8+Qa4ntoVN9BmPCGA x3JRUW47Q3VFrjDJwQpiTiUSRrmgA1J7e0fTc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=TV+cBfgEjWVdVoWjdO7bHOv3j1JRscD3Rid2RHJ0lps=; b=SCbso+FAsswwPylko+VtIMqgdLE0mPoDD/mE1ir0v9mP7+7zEaul45hes0HLxgTni2 9i3nl/XbTz5J2E0CW/ysYM9cfc0bARlyA1MoimWH1PZwBDW/t6oLlezMdoUXeNaRLAa3 9Z8Og2kgmPwop1sP4YCpQ5GYMlaLcAURpYZAuAielPNkMpJBN15xLj1Cga2AzkofOG+8 exZW/8xBAKQcQ8YXiP3mQNEOyX4bX/ute/mkYIxtcVF2SujyvBpRkKGJWSa4iXntT1dE fyNE3l/t77Rm9PcxN9q1+IndfAn79qy6QyH+wEMc/xkD1zJDJfBOxr+YPglx/zE98ZlD VWag== X-Gm-Message-State: AOAM530s/yUg9pLwZPuj+34+U7W1hII8upGhXJ6h6ToSKA5+MGpybI6t gFz1WLgdWGw0b1lwIJt8Vmg9zA== X-Google-Smtp-Source: ABdhPJyWsgZ1h969nhhwtClEC/BY/00rQAZgfGlUd6u+VFTLe0qhGDmhTQp4ndVfR7shOT6vOpzU6A== X-Received: by 2002:a17:906:5495:: with SMTP id r21mr26234185ejo.33.1599587728032; Tue, 08 Sep 2020 10:55:28 -0700 (PDT) Received: from localhost ([2620:10d:c093:400::5:4614]) by smtp.gmail.com with ESMTPSA id n7sm18371091eji.13.2020.09.08.10.55.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Sep 2020 10:55:27 -0700 (PDT) Date: Tue, 8 Sep 2020 18:55:27 +0100 From: Chris Down To: Vlastimil Babka Cc: zangchunxin@bytedance.com, akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Muchun Song Subject: Re: [PATCH] mm/vmscan: fix infinite loop in drop_slab_node Message-ID: <20200908175527.GA1336071@chrisdown.name> References: <20200908142456.89626-1-zangchunxin@bytedance.com> <20200908150945.GA1301981@chrisdown.name> <07c6ebf1-e2b3-11a2-538f-4ac542a4373b@suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <07c6ebf1-e2b3-11a2-538f-4ac542a4373b@suse.cz> User-Agent: Mutt/1.14.6 (2020-07-11) X-Rspamd-Queue-Id: CFE1E180C07A3 X-Spamd-Result: default: False [0.00 / 100.00] X-Rspamd-Server: rspam03 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000442, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Vlastimil Babka writes: >On 9/8/20 5:09 PM, Chris Down wrote: >> drop_caches by its very nature can be extremely performance intensive -- if >> someone wants to abort after trying too long, they can just send a >> TASK_KILLABLE signal, no? If exiting the loop and returning to usermode doesn't >> reliably work when doing that, then _that's_ something to improve, but this >> looks premature to me until that's demonstrated not to work. > >Hm there might be existings scripts (even though I dislike those) running >drop_caches periodically, and they are currently not set up to be killed, so one >day it might surprise someone. Dropping should be a one-time event, not a >continual reclaim. Sure, but these scripts can send it to their child themselves instead of using WCE, no? As far as I know, that's the already supported way to abort drop_caches-induced reclaim.