Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp4060632rdh; Tue, 28 Nov 2023 10:39:50 -0800 (PST) X-Google-Smtp-Source: AGHT+IHn/W5XOdQbwc0NyY0G4SXVxqvXLjn+aRYBPhLvngDgFdt0h+0yXAHpAeTYcGnkeJ+LqwxA X-Received: by 2002:a17:903:643:b0:1cc:4ff3:c837 with SMTP id kh3-20020a170903064300b001cc4ff3c837mr13945766plb.68.1701196790265; Tue, 28 Nov 2023 10:39:50 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1701196790; cv=pass; d=google.com; s=arc-20160816; b=VdrFVdnUNXTxCCwZqaK1jqdnVCMtfjDIeGiVymyIZflH/u41dl5dlhmG/sxDeeD1gu u5/IweAm5p/8lndKbRFDc56kwLI/rS5md6epDPtiFVGBz2XEBKLkhjzoMgEwo8BATAB5 jNaej2P39Sg/7m3LjnO3nplcWKsVNQWYH2UwAYRw6yl4Oxg3SSD3I9tnbOI3bq4J42sU tQzTAreY2EDMMYX6OWtOpvgaRQCZLgPcyLfCMn7yiwsrWhPCbOxmr01UlQc5OSR1BGns lpDk361ePILVtXkK3kHlufxQHVXjSK8FIWzprftF3rjPeDeUPJ4hmVGBBcuKaea7hS9B puxg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :in-reply-to:from:references:cc:to:content-language:subject :user-agent:date:message-id:dkim-signature; bh=2oIAzroTe2CFHljGWXCN2mJnpB+EifQiGcEMeUdCHpY=; fh=/zLBVW8mF0H95XO2b6spVliDXEZSoqEMZwpvKCLvFcI=; b=ns61Ir9vIKaNHAyFmbgMA0p9lXIaXvbctb/wo9DBEUHoFTQu6qYy3+aBwgjtxHayJi /vNhbttkyAvYqGz7UHhxxJB8u6tdU6AuqqHUqUOoYs/2hJoLb1YfEzTFj7MJCvFgHJ8q ELKWnJdtH15lghk/xEHJGhHwzksfRMD5MsdPf7QrJpGxFQiQmgY2dgzhxdMZuJybxReP CqJh9aQrRKwXn4GpB6MIamRUdT4rFbSLdzkfWUXAkChbR5flStE8snd3Joee+fd4PaF5 onYPxfKe7YLYudU1lMWZBaSKLzapV6WBWkevq2EYYiF4gB8kPSoxcOnkjIxNYDe5liuF eWVQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@Nvidia.com header.s=selector2 header.b=ObIqFYLs; arc=pass (i=1 spf=pass spfdomain=nvidia.com dkim=pass dkdomain=nvidia.com dmarc=pass fromdomain=nvidia.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=nvidia.com Return-Path: Received: from howler.vger.email (howler.vger.email. [23.128.96.34]) by mx.google.com with ESMTPS id q12-20020a170902eb8c00b001c74d844254si13084872plg.101.2023.11.28.10.39.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 28 Nov 2023 10:39:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) client-ip=23.128.96.34; Authentication-Results: mx.google.com; dkim=pass header.i=@Nvidia.com header.s=selector2 header.b=ObIqFYLs; arc=pass (i=1 spf=pass spfdomain=nvidia.com dkim=pass dkdomain=nvidia.com dmarc=pass fromdomain=nvidia.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.34 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=nvidia.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by howler.vger.email (Postfix) with ESMTP id 59680806136E; Tue, 28 Nov 2023 10:39:47 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at howler.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346507AbjK1Sj1 (ORCPT + 99 others); Tue, 28 Nov 2023 13:39:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52248 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234874AbjK1SjZ (ORCPT ); Tue, 28 Nov 2023 13:39:25 -0500 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (mail-mw2nam10on2088.outbound.protection.outlook.com [40.107.94.88]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 30695137 for ; Tue, 28 Nov 2023 10:39:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Nre+SEworX6kCcnmct3Jm1tQiGqia+TIGuHFEx4G0RCpVC/+AO5uA5/uwfa0NlKm4BdFXh2++AiEgr9T3P2Mn30tHOGHDC2EXWgTJhusiprE5Lr5QB2YfRBdJxaJPD1p5c/RsV8Tu2xd4+8jGENUjLT2FQlSPdS5ZuhYnUdNxzPPJIxEXtKXdDN+F63AX8HjRUFDr3wSZ1QfpKh5LwYuTWVR7if7xtECYD6pAiV8WxVW66H8g7C7/Ky2VDqQ4/2vAnCghSygrTT5UYvkz4jkCyPUE1YAr+UdNfONdN9CgXDMjX2QFMJ8QjHbdbTCZ5m4TkAXBIzngg2ZgZYRqqg7kQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=2oIAzroTe2CFHljGWXCN2mJnpB+EifQiGcEMeUdCHpY=; b=Mj2Qq9jUDHPVyki7d8dPZn8JugS2vG36o8ydGLYlQTyUbyFLS1wOmvUQwgOwXH+koqSJ3ZpkhUckG6WjlWhcC6Jixy8lTeTPg+/gMrGitrgryZT2Fvvym8jlsKoDzCZyXoL1oDOfLYGlazS3qMqLEJ41CBDchq6ccP5OKvHnpRJddgaokOoq0XAJtyKRnWBGtkqhx8jYaH0NfMjycxGx5oH2DtxX+GqU/FszleOGFIcGvIk3zTuV8si1C8Ysklzec+a8Cjr1OUDhl+GwvNJBQJyeTblOopj7bL9hY5W+UcJQvmxlFOzPnl2um0j2u4HM71G++5Ys3Cm8vOSbcU0AvA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nvidia.com; dmarc=pass action=none header.from=nvidia.com; dkim=pass header.d=nvidia.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2oIAzroTe2CFHljGWXCN2mJnpB+EifQiGcEMeUdCHpY=; b=ObIqFYLsoaeajC7W6Bb2N0zettUJ/WGM95pG139NCAJgJkMLLydRoiRD4NFlgLcAkVg+d5WVJedVTggwn+i842XPVGsJvF3b8JfCOgnR2WxnpXHSu7GddmC4TGvVXHxjyyRgPNjj+s1vl3uWR9cw/+03kalXU0pnetjvxEczcpM6JQsRpjyTRvMKe/Oua8S8Y8OrSWEyViMC0pPD0Y6sflX1u5BW81kgX82SYyuRlYL/t7Ynze3HPdnN1Qn8Rk8JDlj3A+zm8aLwzgi8zP/Ekh3PpYy5H6U+KSpKelR97bOGsClUfx+i0DbMVY0WxBOpOP83esCKqYqGDwWHpysgMg== Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=nvidia.com; Received: from BY5PR12MB4130.namprd12.prod.outlook.com (2603:10b6:a03:20b::16) by DM4PR12MB5134.namprd12.prod.outlook.com (2603:10b6:5:391::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7025.27; Tue, 28 Nov 2023 18:39:25 +0000 Received: from BY5PR12MB4130.namprd12.prod.outlook.com ([fe80::6b9f:df87:1ee2:88ca]) by BY5PR12MB4130.namprd12.prod.outlook.com ([fe80::6b9f:df87:1ee2:88ca%6]) with mapi id 15.20.7025.022; Tue, 28 Nov 2023 18:39:25 +0000 Message-ID: <47d27539-6cf1-4375-9bbb-2ebb9a2acfb3@nvidia.com> Date: Tue, 28 Nov 2023 10:39:00 -0800 User-Agent: Mozilla Thunderbird Subject: Re: [RESEND PATCH v7 00/10] Small-sized THP for anonymous memory Content-Language: en-US To: Ryan Roberts , David Hildenbrand , Alistair Popple Cc: Matthew Wilcox , Andrew Morton , Yin Fengwei , Yu Zhao , Catalin Marinas , Anshuman Khandual , Yang Shi , "Huang, Ying" , Zi Yan , Luis Chamberlain , Itaru Kitayama , "Kirill A. Shutemov" , David Rientjes , Vlastimil Babka , Hugh Dickins , Kefeng Wang , linux-mm@kvack.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <20231122162950.3854897-1-ryan.roberts@arm.com> <9c8f6d2a-7ed8-45d2-9684-d77489bd99b8@redhat.com> <26c361bc-6d87-4a57-9fae-ef635c9039c7@redhat.com> <87sf4rppuc.fsf@nvdebian.thelocal> <51e6c9f1-e863-464b-b5f3-d7f60a7ebed6@arm.com> <58af512c-3d7d-4774-88f7-6336c9384b61@arm.com> <137902b6-24dc-4d51-9be2-6f94aa9dbc3a@redhat.com> From: John Hubbard In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: YT1PR01CA0096.CANPRD01.PROD.OUTLOOK.COM (2603:10b6:b01:2d::35) To BY5PR12MB4130.namprd12.prod.outlook.com (2603:10b6:a03:20b::16) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BY5PR12MB4130:EE_|DM4PR12MB5134:EE_ X-MS-Office365-Filtering-Correlation-Id: 9865e2ed-dca9-4cf0-d508-08dbf04158b6 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Y6vU2ATqo5ob5UgzGWnCTQuvmKLkvsjG9cd2BB6RO4XZdDByHyqlsZ5H8G89etqgD6yIdrR91UQqKtrv/bX1iWbCLmxnsQQ5BtJpo5PE5luTmPSS9XrYNxd9VF4bQ30O6zzUL3UeNWpYsQDUUQAxZ/Ggjhnbc24CgK+vaptnZFnWl/qr3Fww3xMMqYpeC1BTdUTLbbhxbD/xh4XUZqKVe68LDN2PGzEXj9Ud557n41lGw2CdL6NabNfWFr9dHXwmNEv+dYrYDbBvc/zynH+OZxWl3mZq6wGSswDYlMBdN54pyUkTX8tiVeTZfnNi2G8bhN2McWEzc6e8Aqqb7glAqi7pw+H0EmeNaCDbl+KxuMd7lPX8JdkIQ5TrraJTEdWnIioBqMejj++DtmP3u5U0ZpZ2ixI8GXc7+IIJDxcWptfOvFI9pCI0I4pCTp9jRcJnfSmXkdNrej6tkg1PeHS/bfQnfRRqB1liOmgdZwyiJhDxL1B/k0SVWqQQUEREwMXwW0b2rD9MJZ8R4FBL9nVpYst+fuVXFbmI4gt/95WpqpMvxhRgT9MnsvNVd21tfd7BFW3DibUGMaM516YzDhet4Jagc5PtyzzaqTqr7gF1wY2oAViI51T4CAhDIqEfNYxXqYxYBCoKp6Yg0RmnEHDizw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BY5PR12MB4130.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(136003)(39860400002)(346002)(396003)(366004)(376002)(230922051799003)(64100799003)(186009)(451199024)(1800799012)(2616005)(6506007)(6666004)(6512007)(53546011)(8676002)(8936002)(4326008)(6486002)(110136005)(86362001)(478600001)(2906002)(5660300002)(54906003)(31696002)(316002)(66946007)(66476007)(6636002)(66556008)(38100700002)(83380400001)(31686004)(7416002)(41300700001)(36756003)(43740500002)(45980500001);DIR:OUT;SFP:1101; X-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VGoyamp2ZDhHcUMrRTlK?= =?utf-8?B?MXF1TURiVW5jRXMyY1JOL1lnOUQ2S3hPdzV3RzNsK2J6UzVkU1dJc2FWU01y?= =?utf-8?B?N2VRdzNVcHBjM3ZyZFRUaVZ2WTZ2UGpNK3VUcjdLVE1acTNXbERoT3N6YkhF?= =?utf-8?B?WVVsQjNJTHdSSU16MTluc1FLaE1pZE16bVExK2hLZ3IxdlVUWE5IVk5RMUVu?= =?utf-8?B?YWx1YS9vNGR0cngyL1lsQWZ1TWU4bTJvOUtxZ1lJSENKM1h2VXJROVgwWmI5?= =?utf-8?B?Ulk0NGthaEtIcE5tK1c4cFFuNXRER0pFUnNhdWR6QStKZHBTRWRXQzZKNkFV?= =?utf-8?B?anR6dEpSR3lYOEVHcXhOWGZVbWVLSXdNcmEydW9HeW9pQ3NSSVZqczdPMjBy?= =?utf-8?B?eEtjajRrSG9XSmNxMzNMSEFlZEc5QjQ2em5nRmZzcWltRUh1YndRZVM3clQw?= =?utf-8?B?SXc9PQ==?= X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9865e2ed-dca9-4cf0-d508-08dbf04158b6 X-MS-Exchange-CrossTenant-AuthSource: BY5PR12MB4130.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Nov 2023 18:39:25.6890 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: EiXkG7mJEHo+mUBW9GsZgtsztQqXh3sU1K1u2AJxqiKSJxn/Qm0iMbXSlShkAK44vnQm1RuLS8BQsKLFtjZqEg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR12MB5134 X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on howler.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (howler.vger.email [0.0.0.0]); Tue, 28 Nov 2023 10:39:47 -0800 (PST) On 11/28/23 07:34, Ryan Roberts wrote: > On 28/11/2023 14:09, David Hildenbrand wrote: >> On 28.11.23 13:15, Ryan Roberts wrote: >>> On 28/11/2023 08:48, David Hildenbrand wrote: >>> How about we just stop trying to come up with a term for the "small-sized THP" >>> vs "PMD-sized THP" and instead invent a name that covers ALL THP: >>> >>> "multi-size THP" vs "PMD-sized THP". >>> >>> Then in the docs we can talk about how multi-size THP introduces the ability to >>> allocate memory in blocks that are bigger than a base page but smaller than >>> traditional PMD-size, in increments of a power-of-2 number of pages. >> >> So you're thinking of something like "multi-size THP" as a feature name, and >> stating that for now we limit it to <= PMD size. mTHP would be the short name? > > Sure. Sounds workable to me, too. > >> >> For the stats, we'd document that "AnonHugePages" and friends only count >> traditional PMD-sized THP for historical reasons -- and that AnonHugePages >> should have been called AnonHugePmdMapped (which we could still add as an alias >> and document why AnonHugePages is weird). > > Sounds good to me. OK. > >> >> Regarding new stats, maybe an interface that indicates the actual sizes would be >> best. As discussed, extending the existing single-large-file statistics might >> not be possible and we'd have to come up with a new interface, that maybe >> completely lacks "AnonHugePages" and directly goes for the individual sizes. > > Yes, but I think we are agreed this is future work. > We do want to have at least some way to verify that mTHP is active from day 0, though. thanks, -- John Hubbard NVIDIA