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 1AB74C433F5 for ; Wed, 23 Feb 2022 17:36:47 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 7EABA8D0031; Wed, 23 Feb 2022 12:36:46 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 7997E8D0011; Wed, 23 Feb 2022 12:36:46 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 6613B8D0031; Wed, 23 Feb 2022 12:36:46 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.28]) by kanga.kvack.org (Postfix) with ESMTP id 428868D0011 for ; Wed, 23 Feb 2022 12:36:46 -0500 (EST) Received: from smtpin03.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id DD39320DA7 for ; Wed, 23 Feb 2022 17:36:45 +0000 (UTC) X-FDA: 79174749570.03.D0147D8 Received: from mail-pj1-f46.google.com (mail-pj1-f46.google.com [209.85.216.46]) by imf05.hostedemail.com (Postfix) with ESMTP id 5E61910000D for ; Wed, 23 Feb 2022 17:36:45 +0000 (UTC) Received: by mail-pj1-f46.google.com with SMTP id ev16-20020a17090aead000b001bc3835fea8so3607244pjb.0 for ; Wed, 23 Feb 2022 09:36:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=9K/GhD3mBJKJfMoG9/SHoE1BaOvqq/kZ5fjGls7Vrzk=; b=GrXqvdiQ+f/6aJHP2/6pgqGdbCGeNZPAPC0fvz0CZTNKZ4JdcbLTjdAxWzYLunBJte ZSnPsbx6Gr0HXBN36lwoklBCuhIVcmY0dALIOGZT+0H8+rsBP1z8epRjQZlgdv2Id7LL QHkVp0W4VpLweRa1Lwunxy8HPINhfsva5jRD8qizoNBqXFi5h1SCJQQSrPNAJaq0D9Hx KkTA2vv3Gl7QwQ3d4mOmRGCc/v3UcU2U/yfgJvaNeSgM4aBpIJJ5zH27LY0SZSrTRFBh 3BjcjHcfaXHcwv8OQOJzZUCAQjr9u9cKKImm1cCyoXPO0Hah2Alt00SgSU9C/ObK5H4W KA/Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=9K/GhD3mBJKJfMoG9/SHoE1BaOvqq/kZ5fjGls7Vrzk=; b=SPwVOltWV+eKxp4z6PvSv6h4qEOlXE9m5anNQUoMiNxJc/KpCmvS41PjEvB3zZEAqm tUgKH+NN1rnG0sZsYZN7rxv2hBUt1btiU9eFNBJ6y+/kvHfq46DoT7l2I3obdyZkBfHr R3j65OHjZO5NsWEc80hGsaNlF/xf4c+KVpZpBvZEvEP6Ehynnem/Yp9pySuDniMSWEpn X81dWmZ6Oq8V4pc8/RPecloslb9WoqGba1odGpYErKNWGNHzBtRdVvb4kRJlY7+iGlKd KtHLhQ8/FmxQsJO0nxvwUmGOqWXXU3d9DLTpC2uGHt9AybUneJ9oyrKtWpASLFTyOple WWig== X-Gm-Message-State: AOAM532cxQSHhLhrPpRxRmfpkJfpNgRIvryyUEkpnrNTvZPtYmN/V0La rRBoMaNFuddTEmaLqNRCiJZ7237gJPqH0TI/7mYa1g== X-Google-Smtp-Source: ABdhPJwYLMFzOFXq/qxmNQzwcd0zAfmcd14EGKLi1bS86UNTC8RyO7q/i7uSFCXOTfVrE4eE8VTx/SQbvhxSDsLIpeU= X-Received: by 2002:a17:902:f647:b0:14f:c37d:34ec with SMTP id m7-20020a170902f64700b0014fc37d34ecmr691889plg.6.1645637803977; Wed, 23 Feb 2022 09:36:43 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Shakeel Butt Date: Wed, 23 Feb 2022 09:36:32 -0800 Message-ID: Subject: Re: Regression in workingset_refault latency on 5.15 To: Daniel Dao Cc: Ivan Babrou , kernel-team , Linux MM , Johannes Weiner , Roman Gushchin , Feng Tang , Michal Hocko , Hillf Danton , =?UTF-8?Q?Michal_Koutn=C3=BD?= , Andrew Morton , Linus Torvalds Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: 5E61910000D X-Stat-Signature: od988emxkbrzrkzgbh3tndmhkgremebr X-Rspam-User: Authentication-Results: imf05.hostedemail.com; dkim=pass header.d=google.com header.s=20210112 header.b=GrXqvdiQ; spf=pass (imf05.hostedemail.com: domain of shakeelb@google.com designates 209.85.216.46 as permitted sender) smtp.mailfrom=shakeelb@google.com; dmarc=pass (policy=reject) header.from=google.com X-Rspamd-Server: rspam05 X-HE-Tag: 1645637805-660530 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000002, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Wed, Feb 23, 2022 at 9:07 AM Daniel Dao wrote: > > On Wed, Feb 23, 2022 at 4:00 PM Shakeel Butt wrote: > > > > Can you share a bit more detail on your hardware configuration (num of > > > cpus) and if possible the flamegraph? > > > > > We have a mix of 96 and 128 cpus. I'm not yet sure if it's possible to share > the flamegraphs. We may have to come back to that later if necessary. > Can you please first confirm if you are running 5.15.19 kernel? If that is the case then it means the machine is seeing (nr_cpus * 32) stat updates. Couple of questions: 1) Did you see any call stack other than xfs read where expensive mem_cgroup_flush_stats() is showing up? 2) Can you please use the similar bpf+kprobe tracing for the memcg_rstat_updated() (or __mod_memcg_lruvec_state()) to find the source of frequent stat updates. 3) I am still pondering why disabling swap resolves the issue for you. Is that only for a workload different from xfs read? 4) Can you please also trace cgroup_rstat_flush_locked()?