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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 67EAEC433EF for ; Thu, 7 Oct 2021 15:38:48 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id D177D60FC3 for ; Thu, 7 Oct 2021 15:38:47 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org D177D60FC3 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linux.alibaba.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id 2988D6B0071; Thu, 7 Oct 2021 11:38:47 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 248346B0072; Thu, 7 Oct 2021 11:38:47 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 15E8D900002; Thu, 7 Oct 2021 11:38:47 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0064.hostedemail.com [216.40.44.64]) by kanga.kvack.org (Postfix) with ESMTP id 033F66B0071 for ; Thu, 7 Oct 2021 11:38:47 -0400 (EDT) Received: from smtpin09.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with ESMTP id A2EEF82499A8 for ; Thu, 7 Oct 2021 15:38:46 +0000 (UTC) X-FDA: 78670049052.09.D3A9C86 Received: from out30-44.freemail.mail.aliyun.com (out30-44.freemail.mail.aliyun.com [115.124.30.44]) by imf06.hostedemail.com (Postfix) with ESMTP id 04137801B7E3 for ; Thu, 7 Oct 2021 15:38:43 +0000 (UTC) X-Alimail-AntiSpam:AC=PASS;BC=-1|-1;BR=01201311R691e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04395;MF=baolin.wang@linux.alibaba.com;NM=1;PH=DS;RN=4;SR=0;TI=SMTPD_---0UqqzqC._1633621112; Received: from 30.15.247.23(mailfrom:baolin.wang@linux.alibaba.com fp:SMTPD_---0UqqzqC._1633621112) by smtp.aliyun-inc.com(127.0.0.1); Thu, 07 Oct 2021 23:38:33 +0800 Subject: Re: [PATCH 0/2] Support hugetlb charge moving at task migration To: Michal Hocko Cc: akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org References: From: Baolin Wang Message-ID: Date: Thu, 7 Oct 2021 23:39:15 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.14.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=gbk; format=flowed Content-Transfer-Encoding: 7bit X-Rspamd-Server: rspam01 X-Rspamd-Queue-Id: 04137801B7E3 X-Stat-Signature: oe1bp79pmsf9aou18cp6t6p57sp7sbqf Authentication-Results: imf06.hostedemail.com; dkim=none; dmarc=pass (policy=none) header.from=alibaba.com; spf=pass (imf06.hostedemail.com: domain of baolin.wang@linux.alibaba.com designates 115.124.30.44 as permitted sender) smtp.mailfrom=baolin.wang@linux.alibaba.com X-HE-Tag: 1633621123-236868 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: Hi Michal, (Sorry for late reply due to my holidays) On 2021/9/30 18:46, Michal Hocko wrote: > On Wed 29-09-21 18:19:26, Baolin Wang wrote: >> Hi, >> >> Now in the hugetlb cgroup, charges associated with a task aren't moved >> to the new hugetlb cgroup at task migration, which is odd for hugetlb >> cgroup usage. > > Could you elaborate some more about the usecase and/or problems you see > with the existing semantic? The problems is that, it did not check if the tasks can move to the new hugetlb cgroup if the new hugetlb cgroup has a limitation, and the hugetlb cgroup usage is incorrect when moving tasks among hugetlb cgroups. > >> This patch set adds hugetlb cgroup charge moving when >> migrate tasks among cgroups, which are based on the memcg charge moving. > > Memcg charge moving has shown some problems over time and hence this is > not part of cgroup v2 interface anymore. Even for cgroup v1 this has Sorry, I missed this part, could you elaborate on the issues? I can have a close look about the problems of memcg charge moving. > been an opt-in. I do not see anything like that in this patch series. > Why should all existing workloads follow a different semantic during > task migration now? But I think it is reasonable for some cases moving the old charging to the new cgroup when task migration. Maybe I can add a new hugetlb cgroup file to control if need this or not? Thanks for your comments.