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 0FB49C433EF for ; Thu, 21 Apr 2022 06:03:10 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 495D36B0071; Thu, 21 Apr 2022 02:03:10 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 445BF6B0073; Thu, 21 Apr 2022 02:03:10 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 30C436B0074; Thu, 21 Apr 2022 02:03:10 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.27]) by kanga.kvack.org (Postfix) with ESMTP id 20EFB6B0071 for ; Thu, 21 Apr 2022 02:03:10 -0400 (EDT) Received: from smtpin10.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay13.hostedemail.com (Postfix) with ESMTP id DA985623DC for ; Thu, 21 Apr 2022 06:03:09 +0000 (UTC) X-FDA: 79379843298.10.5F5AA9F Received: from mail-lj1-f175.google.com (mail-lj1-f175.google.com [209.85.208.175]) by imf18.hostedemail.com (Postfix) with ESMTP id B90871C001F for ; Thu, 21 Apr 2022 06:03:07 +0000 (UTC) Received: by mail-lj1-f175.google.com with SMTP id c15so4461573ljr.9 for ; Wed, 20 Apr 2022 23:03:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=NVUWs35f4WE+aWC7FcpSq4pfrFchzLzCfgbNdTOWfy8=; b=VBqyRxaQG527a7fx7AgAznM8UUHxBASgzvSF4gmMRD4VYJdHUiSNVoPhgu42LoOYtS y6gPAHVOwwUd483vHIRxh7hbgdA8HsUg/bgP6y7Dqxs90ng2yo25hED4GNEKdgjsdXXY mUFQ/gnQ78Lay0jv9vKeHJr4kI/tgiaSFRcic= 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=NVUWs35f4WE+aWC7FcpSq4pfrFchzLzCfgbNdTOWfy8=; b=e5cuzRpZDPgidCYWfcgUgq2oYyEgd13PIpJJ/8h2KqtmByaSZ0fTUBLTHjWJKlDU3K /1TcfnEacqAcqI3Etz3fV+PK6wfxqvM2YQ0pSKkWQd12gHN6Byf6dB7iciWHbGiIRPe5 eNOuZzOI0s4VnAPIKHNc57LlAVkKP4yLOYVW7rxZrcTGqIzidl2n6Ome4EgW4DG0gxN4 Lchy+Qu2uI+amxYTKRQMmN2X4xE86NcJDZured1dqAZjMyJKEjhqRwMxz+iCdg8ARyYy QTqs4W6xnhUbAPCCaCM8MbkD0aavHZOauotdbYvU4qsEdpknCb+9y//02f3YSRsMhlyj MQDQ== X-Gm-Message-State: AOAM5319sdjsTpABn3o0nnBew9YVZe1bXFSgmBIofJoFOYAIdwOUkiTY 1LR4poNfTaKu2GVjP3FhzCIHxGyENXnbChboau0= X-Google-Smtp-Source: ABdhPJzrEzoiFw4CpQoFIz1ebGU/afxuJdZljX/C8XPh2sXk+B0fjIN0NL7Ea3SFV3hdvN163CD7QA== X-Received: by 2002:a05:651c:2122:b0:24d:b9b4:aae5 with SMTP id a34-20020a05651c212200b0024db9b4aae5mr12028373ljq.157.1650520987476; Wed, 20 Apr 2022 23:03:07 -0700 (PDT) Received: from mail-lj1-f174.google.com (mail-lj1-f174.google.com. [209.85.208.174]) by smtp.gmail.com with ESMTPSA id d11-20020a19384b000000b0046bbd144dfesm2061950lfj.125.2022.04.20.23.03.04 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 20 Apr 2022 23:03:05 -0700 (PDT) Received: by mail-lj1-f174.google.com with SMTP id bn33so4469945ljb.6 for ; Wed, 20 Apr 2022 23:03:04 -0700 (PDT) X-Received: by 2002:a2e:91d9:0:b0:24d:c221:4941 with SMTP id u25-20020a2e91d9000000b0024dc2214941mr9547564ljg.164.1650520984267; Wed, 20 Apr 2022 23:03:04 -0700 (PDT) MIME-Version: 1.0 References: <20220415164413.2727220-1-song@kernel.org> <4AD023F9-FBCE-4C7C-A049-9292491408AA@fb.com> <88eafc9220d134d72db9eb381114432e71903022.camel@intel.com> <1650511496.iys9nxdueb.astroid@bobo.none> In-Reply-To: From: Linus Torvalds Date: Wed, 20 Apr 2022 23:02:48 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v4 bpf 0/4] vmalloc: bpf: introduce VM_ALLOW_HUGE_VMAP To: Nicholas Piggin Cc: Mike Rapoport , "akpm@linux-foundation.org" , "ast@kernel.org" , "bp@alien8.de" , "bpf@vger.kernel.org" , "daniel@iogearbox.net" , "dborkman@redhat.com" , "edumazet@google.com" , "hch@infradead.org" , "hpa@zytor.com" , "imbrenda@linux.ibm.com" , Kernel Team , "linux-kernel@vger.kernel.org" , "linux-mm@kvack.org" , "mbenes@suse.cz" , "mcgrof@kernel.org" , "pmladek@suse.com" , "Edgecombe, Rick P" , "song@kernel.org" , Song Liu Content-Type: text/plain; charset="UTF-8" Authentication-Results: imf18.hostedemail.com; dkim=pass header.d=linux-foundation.org header.s=google header.b=VBqyRxaQ; dmarc=none; spf=pass (imf18.hostedemail.com: domain of torvalds@linuxfoundation.org designates 209.85.208.175 as permitted sender) smtp.mailfrom=torvalds@linuxfoundation.org X-Rspam-User: X-Rspamd-Server: rspam08 X-Rspamd-Queue-Id: B90871C001F X-Stat-Signature: 93x3z7fdwy7cbsct68pirugso6rfnc93 X-HE-Tag: 1650520987-84459 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: On Wed, Apr 20, 2022 at 10:48 PM Linus Torvalds wrote: > > The lagepage thing needs to be opt-in, and needs a lot more care. Side note: part of the opt-in really should be about the performance impact. It clearly can be quite noticeable, as outlined by that powerpc case in commit 8abddd968a30 ("powerpc/64s/radix: Enable huge vmalloc mappings"), but it presumably is some _particular_ case that actually matters. But it's equalyl clearly not the module code/data case, since __module_alloc() explicitly disables largepages on powerpc. At a guess, it's one or more of the large hash-table allocations. And it would actually be interesting to hear *which*one*. From the 'git diff' workload, I'd expect it to be the dentry lookup hash table - I can't think of anything else that would be vmalloc'ed that would be remotely interesting - but who knows. So I think the whole "opt in" isn't _purely_ about the "oh, random cases are broken for odd reasons, so let's not enable it by default". I think it would actually be good to literally mark the cases that matter (and have the performance numbers for those cases). Linus