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 9FFCBC52D70 for ; Tue, 6 Aug 2024 16:27:07 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 37E826B0085; Tue, 6 Aug 2024 12:27:07 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 32E4E6B0088; Tue, 6 Aug 2024 12:27:07 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 1CF256B0089; Tue, 6 Aug 2024 12:27:07 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id F37B36B0085 for ; Tue, 6 Aug 2024 12:27:06 -0400 (EDT) Received: from smtpin09.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 99470A1FBE for ; Tue, 6 Aug 2024 16:27:06 +0000 (UTC) X-FDA: 82422350052.09.782EB55 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf24.hostedemail.com (Postfix) with ESMTP id 6BDAB180025 for ; Tue, 6 Aug 2024 16:27:04 +0000 (UTC) Authentication-Results: imf24.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=THClXlqs; spf=pass (imf24.hostedemail.com: domain of peterx@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=peterx@redhat.com; dmarc=pass (policy=none) header.from=redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1722961561; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=dwRzqS6Jrxy/9AqVhW2hvOe8Nx9yRiOYapW2YHF2cyE=; b=K87U4HqZzqJ8zrG9kBr1OSBG4UdfsUar+XDIFwdJZgIZdc+t02RJ2H7MF9w12J1uctkSGB Fr2+JLcfiM5ADhFmtuL1kDXKpH02oLue2ySF5Mqsm6TGkIxIdCmedIAZulwNvHlwR9/wGj eBGGAs57qh6L3OZyXXf/jod+CpXH1ps= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1722961561; a=rsa-sha256; cv=none; b=iY53S6mNPp2DknHcS/PR9NOlH1h8u7FH4nTBGvdi+z6D7Q9ylNQ/gm6oHeWAa/6JY8caiI Pb0O/GJNXSomIYQXC70rUY5D1EGmpfegXQHO2tQZXmGD9uaKQHpmJ275pants5+e5uG190 XI2GPrQ5V0uxNdnvn91nw7lLl1siUnM= ARC-Authentication-Results: i=1; imf24.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=THClXlqs; spf=pass (imf24.hostedemail.com: domain of peterx@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=peterx@redhat.com; dmarc=pass (policy=none) header.from=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1722961623; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=dwRzqS6Jrxy/9AqVhW2hvOe8Nx9yRiOYapW2YHF2cyE=; b=THClXlqsHi+DT/hXzV4Dl+YA0N5BWhvSIk18PlhY+xd2VbQucpmLIvtOWvbqWhH5ECt0n2 MamlOJOQ4+NtJ4VnXX8sexcusHyajySnWJ1ar/R3b4etC5uZv5lbJNpXBdOoecQyLGwWFr f+h3CEUl3J5W8Q6EKn84yi1UbEIDAh0= Received: from mail-qv1-f72.google.com (mail-qv1-f72.google.com [209.85.219.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-237-eMmVctgHMIqNR2uisQ_bLQ-1; Tue, 06 Aug 2024 12:27:02 -0400 X-MC-Unique: eMmVctgHMIqNR2uisQ_bLQ-1 Received: by mail-qv1-f72.google.com with SMTP id 6a1803df08f44-6b95c005dbcso2663866d6.1 for ; Tue, 06 Aug 2024 09:27:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1722961621; x=1723566421; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=dwRzqS6Jrxy/9AqVhW2hvOe8Nx9yRiOYapW2YHF2cyE=; b=sqZHwu/F2GWlasDteXDN8NFuY7mdiuSoMqoDc7BnOZdxvHer7pRWkXNjZnBkssfbzR e01n9Il5uTJCKVJFHXxpdYkwVvmfl49GosmB8s2kGIh9SlCSltG5V8Q6Cd6dXc+JWmWy Rjhy57L+ZeCmVEGNnw1djM1jwhr8lqldZVwuFzgilNwZ7rQ9q6WEKHfSBJer1nkCYJRX Et6zXWR3yMdl0ww0smwVdbbOVnKD4Hegk8KwpEW0YqLk2r+OmD2zeLenXPKHk+4cMMko TfMSg9zjvYsEDZ9LKYuIgUb31ACMIpytraBxC9V0RqMQkoCg4nCJubKG5clq0XHaXk9I Sogw== X-Gm-Message-State: AOJu0YyNfMGPDZM2ig2FcVagOYemOYCsQrH3ZJNqIL+RInQQFEn7RT2B Oo+HbdcgAFEhvOinj+/J4ANY+sjVpe695HyC/vv1w/C2cElHOn6fbZod+gasgX4QfRbn70CCIlW djAWwVF2BlJsb7geDqsW2lO6ned1cd2qG+kLDqQLstHfvOU2J X-Received: by 2002:a05:6214:20e9:b0:6b2:af3c:f710 with SMTP id 6a1803df08f44-6bb9831ea8emr105902186d6.2.1722961621706; Tue, 06 Aug 2024 09:27:01 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEs199fAKj0/OLiUoJmdO3kvLFiPXK+MPCbBppWbqB/Lo+v3asN98Wu552yOIbw7iXXDStHtA== X-Received: by 2002:a05:6214:20e9:b0:6b2:af3c:f710 with SMTP id 6a1803df08f44-6bb9831ea8emr105902046d6.2.1722961621365; Tue, 06 Aug 2024 09:27:01 -0700 (PDT) Received: from x1n (pool-99-254-121-117.cpe.net.cable.rogers.com. [99.254.121.117]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6bb9c88421dsm47964496d6.139.2024.08.06.09.26.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Aug 2024 09:27:00 -0700 (PDT) Date: Tue, 6 Aug 2024 12:26:57 -0400 From: Peter Xu To: David Hildenbrand Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Dave Jiang , Rik van Riel , Dave Hansen , Michael Ellerman , linuxppc-dev@lists.ozlabs.org, Matthew Wilcox , Rick P Edgecombe , Oscar Salvador , Mel Gorman , Andrew Morton , Borislav Petkov , Christophe Leroy , Huang Ying , "Kirill A . Shutemov" , "Aneesh Kumar K . V" , Dan Williams , Thomas Gleixner , Hugh Dickins , x86@kernel.org, Nicholas Piggin , Vlastimil Babka , Ingo Molnar , Alex Thorlton Subject: Re: [PATCH v3 2/8] mm/mprotect: Remove NUMA_HUGE_PTE_UPDATES Message-ID: References: <20240715192142.3241557-1-peterx@redhat.com> <20240715192142.3241557-3-peterx@redhat.com> <054324a3-bc77-426f-a751-06700aad394e@redhat.com> MIME-Version: 1.0 In-Reply-To: <054324a3-bc77-426f-a751-06700aad394e@redhat.com> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Disposition: inline X-Rspam-User: X-Rspamd-Server: rspam04 X-Rspamd-Queue-Id: 6BDAB180025 X-Stat-Signature: i51pqfney9candfc7gzh8dxqr3fgmo1w X-HE-Tag: 1722961624-748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L9b9cGb1oyjiB+7krgYi6/kQ30wNnYOmVMijx4cB1kiBQqIMo5RDXImL7ZsZ7NnNI50ayuF6Cr7u4TK8lgu1lWcoGIb38noMd5+vZ0aQ9YRCRQV1iWWCDgNg6zaUU3J+asIqq6DiTL2XpBE6I+FEaRFyaa1ymMti6/GjtMo5OcqLPBUSDetsuBIOVTuvxUDkJsmNKuVbmD9qKFyXcRXKBP2VM71dvVgPrP4jyN8m2QYrR6QWzHqmgEwuA8ENZJoU/p0hQQuaUXkZIBFWK797U4yCdCDcSQSnLhEObYvsC4M0iL6JJIw3jMaO02YE= 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: List-Subscribe: List-Unsubscribe: On Tue, Aug 06, 2024 at 03:02:00PM +0200, David Hildenbrand wrote: > > Right. > > > > I don't have a reason to change numa_pte_updates semantics yet so far, but > > here there's the problem where numa_huge_pte_updates can be ambiguous when > > there is even PUD involved. > > > > In general, I don't know how I should treat this counter in PUD path even > > if NUMA isn't involved in dax yet; it can be soon involved if we move on > > with using this same path for hugetlb, or when 1G thp can be possible (with > > Yu Zhao's TAO?). > > We shouldn't bother about it in the PUD path at all I think. Especially as > long as NUMA hinting doesn't apply to any of what we would handle on the PUD > path :) Hmm, I just noticed that hugetlb was never involved.. but then how about a potential 1G THP? Do you mean 1G THP will not be accounted in numa balancing too even in the future? The motivation I had this patch in this series is I want to be clear on how I should treat this counter in pud path if it won't go. And when people compare the two paths we'll need to be clear why there's such difference if I ignore it in pud path. Per my current read on this counter, it might be an overkill to do that at all, and it might be simpler we drop it now. > > > > > One other thing I can do is I drop this patch, ignore NUMA_HUGE_PTE_UPDATES > > in PUD dax processing for now. It'll work for this series, but it'll still > > be a problem later. I figured maybe we should simply drop it from now. > > It probably shouldn't block your other fixes and we should likely discuss > that separately. > > I agree that we should look into dropping that PMD counter completely. No strong opinion here. If we prefer keeping that as separate topic, I'll drop this patch. You're right, it's not yet relevant to the fix. Thanks, -- Peter Xu