Received: by 2002:a05:6602:18e:0:0:0:0 with SMTP id m14csp7038014ioo; Thu, 2 Jun 2022 20:48:09 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz9zJaCrAPF4kVnUoQ+x5UGAcSWzngoMfD1Ju1f6nQUOxaC0z6ieMvTHuR6lv/7TMKPf21k X-Received: by 2002:a17:907:1c01:b0:6f4:2692:e23 with SMTP id nc1-20020a1709071c0100b006f426920e23mr6893266ejc.243.1654228089076; Thu, 02 Jun 2022 20:48:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654228089; cv=none; d=google.com; s=arc-20160816; b=eVj++aBovFv7sXS6c1nVuxJEhgbpHQmzHgiboSAMzC5UsOjGOeUiBLaCqYfO1kLFcq JCWEHOKf47yQCKPVTMKXrBImBsNi16Q1be9hdddOvlZ1+xxqsX64QFTCwd38UeEpJZcg 2j9KNK0mQ/cx6vLELbVrKKpP4PEHL3nS/1kBfMuVwGL609i8930iQJOZSC4qPpiOhq7w di1fXAcjiiiReYzzRWqkxa6SH297nMGCekPjadzweNDZ+57+j4BxArbNV5G6brZ9njdI QRIauEdVbQVUfjC/qIiCwQzkZkGbrCCQltUK8GWFd6RAa/VrMTQSJUHcjnQNC6eP5l1I NVHg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=qh8fGTes/FbVdpZZWVUAdeYCe4U1Ro7VMchHPwNNYhY=; b=W7ACFIvcqwZ2Sk+TF+GTNAzIwBphMmZdjW6eZYAtTGDJCHLM5lO0IFjPFdjIwo1T47 SiP5AkJNE1t9Rk1vmCjVuB4+gC1C0sMfe11EggnNm4IG66dGnmhxHl322NTvot19MEO4 I5onMuqzVUAN9KPDlvJWMs4izIFE6wx1TX3jsa1IMe5t3DKBo5mQoJMiZsTRxJQ9N31D 239Emp3Y1QppMtlfrozDFfbWY0rj+LgBFGORE+97IuRxuzKozFN2maUeOdlPqQ77nHmU XOq3V90VvLokpKZ2RW2aQQgQvqdsn+SdWRTkj4n3B6LUc9QL98N+5l4UMskVOzPmZIlG 8vvw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=VlRGNEn0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r13-20020a508d8d000000b0042dd3ba4769si69588edh.148.2022.06.02.20.47.43; Thu, 02 Jun 2022 20:48:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=VlRGNEn0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237884AbiFBSNp (ORCPT + 99 others); Thu, 2 Jun 2022 14:13:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55714 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234302AbiFBSNn (ORCPT ); Thu, 2 Jun 2022 14:13:43 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5A28312D1A for ; Thu, 2 Jun 2022 11:13:43 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id EFEF8616D1 for ; Thu, 2 Jun 2022 18:13:42 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id D4A6AC385A5; Thu, 2 Jun 2022 18:13:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1654193622; bh=TQCbTyESjzKocFJ0uHcl7XKEvJfqI5iTnWmUWKSmWA4=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=VlRGNEn0vm1qYmNdTZwu0UeX/BSvILFmfMDNz9L4PZ/bALKOqVpDL0oO8pFJdbZQf cKZA/bh8Z3c0J40YeuyBxy+ybLwWLcTveg2HEA2IJp/RH/N4noxBrMhcF9wWygH9mr pWkk0wGpvr3sHR9J37QbaWnrW313/TarOb3saYzI= Date: Thu, 2 Jun 2022 11:13:41 -0700 From: Andrew Morton To: Jakub =?UTF-8?B?TWF0xJtuYQ==?= Cc: linux-mm@kvack.org, patches@lists.linux.dev, linux-kernel@vger.kernel.org, vbabka@suse.cz, mhocko@kernel.org, mgorman@techsingularity.net, willy@infradead.org, liam.howlett@oracle.com, hughd@google.com, kirill@shutemov.name, riel@surriel.com, rostedt@goodmis.org, peterz@infradead.org Subject: Re: [PATCH 1/2] [PATCH 1/2] mm: refactor of vma_merge() Message-Id: <20220602111341.6674e4d862d6d925b0eebcb3@linux-foundation.org> In-Reply-To: <20220602145642.16948-2-matenajakub@gmail.com> References: <20220602145642.16948-1-matenajakub@gmail.com> <20220602145642.16948-2-matenajakub@gmail.com> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-redhat-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-9.7 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2 Jun 2022 16:56:41 +0200 Jakub Matěna wrote: > Refactor vma_merge() to make it shorter and more understandable. > Main change is the elimination of code duplicity in the case of > merge next check. This is done by first doing checks and caching > the results before executing the merge itself. The variable 'area' is > divided into 'mid' and 'res' as previously it was used for two purposes, > as the middle VMA between prev and next and also as the result of the > merge itself. Exit paths are also unified. > Thanks, but unfortunately the code you're working on here has changed greatly in Liam's mapletree patchset. Could you please take a look at the mm-unstable branch at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm and decide if you want to tackle it?