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 90E60C4828F for ; Fri, 9 Feb 2024 08:54:46 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 53D146B0071; Fri, 9 Feb 2024 03:54:45 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 4C5A76B0072; Fri, 9 Feb 2024 03:54:45 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 366E36B0074; Fri, 9 Feb 2024 03:54:45 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id 22F416B0071 for ; Fri, 9 Feb 2024 03:54:45 -0500 (EST) Received: from smtpin29.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 8CF2740FF4 for ; Fri, 9 Feb 2024 08:54:44 +0000 (UTC) X-FDA: 81771654888.29.7CC2481 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by imf21.hostedemail.com (Postfix) with ESMTP id C42DC1C0012 for ; Fri, 9 Feb 2024 08:54:41 +0000 (UTC) Authentication-Results: imf21.hostedemail.com; dkim=none; dmarc=pass (policy=none) header.from=arm.com; spf=pass (imf21.hostedemail.com: domain of ryan.roberts@arm.com designates 217.140.110.172 as permitted sender) smtp.mailfrom=ryan.roberts@arm.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1707468882; 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:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=4EbEK6uSKeo6+RlzYntR0TiW8j97nryR7kdruoe+eVs=; b=pQUH8TSzeb1+02/qetG8ThvcmpuhMO7VT3MNZl7ActnpsoL9JE8FKy1sX274F1Mo0XJnkp gDOoF8CSb35HGTKXWYyLK6peunDWaRz3ar9YtBZgQvRvUYvNT04KCfSP1TE1b1v1KwFUYk HzMqpn7RrW/3GH7fwS4G67PqJFGaWUE= ARC-Authentication-Results: i=1; imf21.hostedemail.com; dkim=none; dmarc=pass (policy=none) header.from=arm.com; spf=pass (imf21.hostedemail.com: domain of ryan.roberts@arm.com designates 217.140.110.172 as permitted sender) smtp.mailfrom=ryan.roberts@arm.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1707468882; a=rsa-sha256; cv=none; b=j4Ean3mMtoBkMLJGoxTjRGPxcycNsh/ORh3sAEZWRRXFUxrsi2DR6BlfoOlrWm9FAJLery rnBPzWBs1WQUWVogN5+BkSH07NEsGF0LDP5w5fTCGUd29B6QieMh4t5/XO0f5XA0yuIBOA 1ecTIMyMKBpoG//xyaI9nTVx2M4aXJo= Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 9D4E6DA7; Fri, 9 Feb 2024 00:55:22 -0800 (PST) Received: from [10.57.65.115] (unknown [10.57.65.115]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 6688A3F762; Fri, 9 Feb 2024 00:54:36 -0800 (PST) Message-ID: <3ba54c94-8e44-4dd6-9a25-2cf81b07336f@arm.com> Date: Fri, 9 Feb 2024 08:54:34 +0000 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v5 00/25] Transparent Contiguous PTEs for User Mappings To: Mark Rutland Cc: Catalin Marinas , Will Deacon , Ard Biesheuvel , Marc Zyngier , James Morse , Andrey Ryabinin , Andrew Morton , Matthew Wilcox , David Hildenbrand , Kefeng Wang , John Hubbard , Zi Yan , Barry Song <21cnbao@gmail.com>, Alistair Popple , Yang Shi , Nicholas Piggin , Christophe Leroy , "Aneesh Kumar K.V" , "Naveen N. Rao" , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , "H. Peter Anvin" , linux-arm-kernel@lists.infradead.org, x86@kernel.org, linuxppc-dev@lists.ozlabs.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org References: <20240202080756.1453939-1-ryan.roberts@arm.com> Content-Language: en-GB From: Ryan Roberts In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Rspamd-Server: rspam09 X-Rspamd-Queue-Id: C42DC1C0012 X-Stat-Signature: mk7nsqx6ahiqxnf1oamot36qt5mh16ox X-Rspam-User: X-HE-Tag: 1707468881-558965 X-HE-Meta: U2FsdGVkX1/jCp8+XigtHZVBl4yLviDhYT3OXh84r0vcXFlffpNdi1gWm35V7S9Hbj3GiyyTd22zMUOmJY5Sdb/dINxSVKVIoJYyTWTlCC5hb1NakQxQxOGc53URJlGn6mgqopxo2lwLzYUOLA2UtsrqgFhHO6yUrqhvbTg47fW++dfNa+YFSV7HbKIapV/g9lKYcVq131jaisbP2k4f6GIqmdoLZYup0AKYr2qiZYXchRhtKm9HVRmgygqeIoUKs9HuLpAjgV49EXEk9Brul0B10UNFqzpUyQO4q2uD3Z7pwUJhIpYfe3UDvqHmM5PhFmjXBKNtiiF9sCeKcFafbdRpnCESqy7rhmBBQtxqJh6NEJLWjm/Qx2vWgbEtj76B1yO4ZoQJ/0/rLgxZNHnJ8fBspvbQ/mj51zTnwAgBYIwMrU+ieReZ8annj5ZBO8zzQxdhlN3B/dYkLXhCPgtJiTkkzDmqZ9B2UAsCb4WOvZycS0JlHm99fnz/eyS8myG6Dcs4w0DVsBAJOOeWFxtfDJvxe9gWZtWc0XibIWe0JyDX3mzhG311D2vqO99OTwR1/um0Ty1X4VOGbujLKNEi+516VUuEeufxTdMtGC/vmOAiS2TRE/k6mSwYqmQwD+Be6OV7auYc5aX2Gn8Kxe4U7z4hTtbBdcL225JGMXa8RsLHZn8OE+G0CbqLWZBCMO6D5sX1ILkccjTuSABVrJOQt2aojPc4zO+uMehDbmDvlbuboEFzp9OP6PJ2NtM2FzWIEih7XYSXcd8YQ41rtzrovkIvJYaaFTPUHAGvQPkaISRe+wphn/QbUhangtRdwpbPMZeqk7mUocEOB44CkIIxdXMZFc7vvQDGqFT31P10V3fRTttMIt2OUvfv3UMKhkTrTJy9eT0tZrl5LmlQcli9sB2nRxtzDWUcbsGBHaR7Ks20NXASFTCipD0vHLuAzxL3eTqmftEvDrI3zWPVtXG 5WZV14b5 ndQbgmrChSoBjwIahj07PeDvM9BiD5MIxnlaYk/H9Bxy2+wFhoZwvLZnwEO6hrNHp50t2/dPdbnNb70yS4OCEwnVSrIxWvHfXYnfzozYRt3IyGJmIzm1a2ujhpoSxub5P9aWybwJFfHoAGzHIESNyJUHlxltB8WK/UFSdCmUBmtmLx/CaRwKAOMWuKkz6RrGULFRPw/6pnUviEjgURIeaNA0rq7Yqf2W0OGSL68DD9PeIAUvuxmnf2CM4R74PBrVPF+eO4kKl7UUORt7AlF82vcWlUA== 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 08/02/2024 17:34, Mark Rutland wrote: > On Fri, Feb 02, 2024 at 08:07:31AM +0000, Ryan Roberts wrote: >> Hi All, > > Hi Ryan, > > I assume this is the same as your 'features/granule_perf/contpte-lkml_v' branch > on https://gitlab.arm.com/linux-arm/linux-rr/ Yep - great detective work! features/granule_perf/contpte-lkml_v5 corresponds exactly to what I posted with all the dependencies in place. > > I've taken a quick look, and I have a few initial/superficial comments before > digging into the detail on the important changes. Thanks for doing this! > >> Patch Layout >> ============ >> >> In this version, I've split the patches to better show each optimization: >> >> - 1-2: mm prep: misc code and docs cleanups > > I'm not confident enough to comment on patch 2, but these look reasonable to > me. Thanks. David has acked patch 2 already so I think we are good there. > >> - 3-8: mm,arm,arm64,powerpc,x86 prep: Replace pte_next_pfn() with more >> general pte_advance_pfn() > > These look fine to me. Thanks! > >> - 9-18: arm64 prep: Refactor ptep helpers into new layer > > The result of patches 9-17 looks good to me, but the intermediate stages where > some functions are converted is a bit odd, and it's a bit painful for review > since you need to skip ahead a few patches to see the end result to tell that > the conversions are consistent and complete. > > IMO it'd be easier for review if that were three patches: > > 1) Convert READ_ONCE() -> ptep_get() > 2) Convert set_pte_at() -> set_ptes() > 3) All the "New layer" renames and addition of the trivial wrappers Yep that makes sense. I'll start prepping that today. I'll hold off reposting until I have your comments on 19-25. I'm also hoping that David will repost the zap series today so that it can get into mm-unstable by mid-next week. Then I'll repost on top of that, hopefully by end of next week, folding in all your comments. This should give planty of time to soak in linux-next. Thanks, Ryan > > Patch 18 looks fine to me. > >> - 19: functional contpte implementation >> - 20-25: various optimizations on top of the contpte implementation > > I'll try to dig into these over the next few days. > > Mark.