Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp1007630ybb; Wed, 1 Apr 2020 13:50:59 -0700 (PDT) X-Google-Smtp-Source: ADFU+vubUW0lhvfH3n6gJQTsNEAVVuTsCWQWC/5wNweh7kXlX/F35elMBzpV8MnL2eZyyQET5Tdm X-Received: by 2002:a9d:3423:: with SMTP id v32mr8445974otb.46.1585774259532; Wed, 01 Apr 2020 13:50:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585774259; cv=none; d=google.com; s=arc-20160816; b=gw/1FV/fxv1DYsfFNM3MBzswIz19SY9A9VmvY4spYd1SmNa6fpYEdHSsAKRsviml0w o8p4U1K7/LkWKxsiY0TsAfIb/o7itI38uaEMxzzficWr+EiVCutQPMMEbX3CJbs/oSlv FoetiNNeWPkYP+ef09HyC4+4hFteKJnGz161WxpLPPvC4oFV7e2A81GORiyf2Wqlewfq 2RN/+xvf2rMegmeac8gyoYq6XtMleJnl2goa4KeD2hH6E16mq6FdJHKk1BZGXLq/kg93 /iNsj3BLErzuB7/wER5NNzJoT+GA3q6PsFclRvDOQ00hnT9+x8jMCiEkfctVHa9QLsDX 519Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=ChzHASHm/TaTfFYQF8dFqluK5hccbTbRDahFmV/GYAg=; b=qob67Z01LtYH3ZfydW8XzLMrIqNtZwcAB/4/SI64BPeXCLNVVp4HQdRSaLSnxXuUur lr1biSmqVuwmBPkm5DK4wBJZ3fDIrXYMY4Oa4KmdeS426tsdqQPzYpi+r4yEoyqo3WFr LayUXMVVVRm0213XQHssDGgB0M7cs/aFFsYibAPbtIpWZWwfhuKuxIVlVx/uVJMG1pX+ 3g4mSjdVTjuv7VIExb1JvTu5bLGuAPExI8+IzhpWBVTTKPBC0f149JpMqEyTaEWoYnN6 gvpMCnr9PDXeR5glZLTRR3xmPbp/qAn7uE7Q2Fd0JfJ9UZE9AROMHftnK0G1KYxC5vpq HNLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@joelfernandes.org header.s=google header.b=qARTqRBe; 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 n4si1355657oie.121.2020.04.01.13.50.47; Wed, 01 Apr 2020 13:50:59 -0700 (PDT) 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; dkim=pass header.i=@joelfernandes.org header.s=google header.b=qARTqRBe; 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 S1733008AbgDAUuP (ORCPT + 99 others); Wed, 1 Apr 2020 16:50:15 -0400 Received: from mail-qt1-f173.google.com ([209.85.160.173]:41105 "EHLO mail-qt1-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732710AbgDAUuO (ORCPT ); Wed, 1 Apr 2020 16:50:14 -0400 Received: by mail-qt1-f173.google.com with SMTP id i3so1400450qtv.8 for ; Wed, 01 Apr 2020 13:50:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joelfernandes.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=ChzHASHm/TaTfFYQF8dFqluK5hccbTbRDahFmV/GYAg=; b=qARTqRBehTmAwNC2T13cmie795aSz9hOx+Z+GpD1GXwTWnXyRaHIGFvPnnMp19QkJw hwFtyHpCx8LiBOZlOPi5WFcbxDYY/C7GU+nTFtAbvbVyJN2nJMl8T8gvy56c0JtbaUq5 HiuZwbUrjOvZoPvkhXmftgH+T+rEbfCI8l1G8= 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; bh=ChzHASHm/TaTfFYQF8dFqluK5hccbTbRDahFmV/GYAg=; b=pDPnceKQtVHyZXR5eJbih+b81IXocfi+S+fzrOV79euqovn08hLXu0BhizQsBY38NF w6uT3mp4wUPry6D9qau3IZZJMFaHj8607MU3pNytVFRPdaDV1yDAe55COKc4hTQDbILw Kwhk+RuWXNkn1SYly5cCuNCzqEAqCQMxpltaYmDUq0GKnLbXXfZN+eNt9Li6L6PQGwED ISoqL2TPEiEuRidOt/sitqbmtWb8Yc+GhjdmthdjYUSAigTZ2ad2mw3UhsLmh+P13T84 iz6hXvuFlIWqEp6Wsjv3KLlF3xiGht+oyKcAoSrUtI+y0EuUrHkIy4Nlpla5nSpDZxA9 UKbQ== X-Gm-Message-State: ANhLgQ0QrLVamna+0OXdS4SCuaYdNqpjNnwG0Hlo/bFk1bLD3N06AfO9 nghwXE78v39+x03sxQNGinuWJQ== X-Received: by 2002:ac8:266c:: with SMTP id v41mr12580604qtv.174.1585774213440; Wed, 01 Apr 2020 13:50:13 -0700 (PDT) Received: from localhost ([2620:15c:6:12:9c46:e0da:efbf:69cc]) by smtp.gmail.com with ESMTPSA id y41sm2234552qtc.72.2020.04.01.13.50.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Apr 2020 13:50:12 -0700 (PDT) Date: Wed, 1 Apr 2020 16:50:12 -0400 From: Joel Fernandes To: "Paul E. McKenney" Cc: urezki@gmail.com, linux-kernel@vger.kernel.org, rcu@vger.kernel.org Subject: Re: What should we be doing to stress-test kfree_rcu()? Message-ID: <20200401205012.GC206273@google.com> References: <20200401184415.GA7619@paulmck-ThinkPad-P72> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200401184415.GA7619@paulmck-ThinkPad-P72> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 01, 2020 at 11:44:15AM -0700, Paul E. McKenney wrote: > Hello! > > What should we be doing to stress-test kfree_rcu(), including its ability > to cope with OOM conditions? Yes, rcuperf runs are nice, but they are not > currently doing much more than testing base functionality, performance, > and scalability. I already stress kfree_rcu() with rcuperf right now to a point of OOM and make sure it does not OOM. The way I do this is set my VM to low memory (like 512MB) and then flood kfree_rcu()s. After the shrinker changes, I don't see OOM with my current rcuperf settings. Not saying that my testing is sufficient, just saying this is what I do. It would be good to get a real workload to trigger lot of kfree_rcu() activity as well especially on low memory systems. Any ideas on that? One idea could be to trigger memory pressure from unrelated allocations (such as userspace memory hogs), and see how it perform with memory-pressure. For one, the shrinker should trigger in such situations to force the queue into waiting for a GP in such situations instead of batching too much. We are also missing vmalloc() tests. I remember Vlad had some clever vmalloc tests around for his great vmalloc rewrites :). Vlad, any thoughts on getting to stress kvfree_rcu()? thanks, - Joel