From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ua1-x930.google.com (mail-ua1-x930.google.com [IPv6:2607:f8b0:4864:20::930]) by sourceware.org (Postfix) with ESMTPS id 307303858D20 for ; Wed, 31 Jan 2024 15:18:44 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 307303858D20 Authentication-Results: sourceware.org; dmarc=fail (p=none dis=none) header.from=rodriguez.im Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=cristianrodriguez.net ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 307303858D20 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::930 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1706714325; cv=none; b=Rygs8Jm21ZhJgUcnk6j+vWTJZzWXimBWXzexx7u8yZbt9KoDQL+xTtLoMuLdyrXBFiLdK8w00tbAnWSvYoV9MOhzvOEmdwLSd9JbLvaQ0r8D1FlpJ7bfKWFN1BsNFrcZcumeC9mRIzyJX+fwfv1y6EJMZ+Uv3cw3ArhGTdTDUdY= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1706714325; c=relaxed/simple; bh=BimdPN0UD0iQ6pEMrpu7TrawMYBFJ4Pih+WNO0B6+1s=; h=DKIM-Signature:MIME-Version:From:Date:Message-ID:Subject:To; b=W4GvUUv5E/N96qia7hqoCdJzf/psJrgNCWyK7N4EqLspPCqhb5gOGi/Kxaub7d39xj5z1IncDELxGKma6JR1MAtBMIdDazCmOup5zbte5A38uYPUH9YxqHkcrf1NNpbqNkcMtukoljen40exrvU35YikKPSk5xOoDQv0//KPEuY= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-ua1-x930.google.com with SMTP id a1e0cc1a2514c-7d3029b5e1fso91700241.0 for ; Wed, 31 Jan 2024 07:18:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rodriguez.im; s=google; t=1706714323; x=1707319123; darn=sourceware.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=DC/uOPflor2esnin6Duf0AkqzsVoBFIA7oTap9MRWa4=; b=V4S1TRMfm1MQt/xv+5PNG+hJ9a3BPyZWOdDzzx9teOC6KpyVPY2PXrGamftd4/i+Yo 1HxMm1Nw850z0lJPRnrgulOCqTAFQorBzVN6hrKiGBEScZ0NWHnHjx3Ml+7r3gTPv7yI O+lliyEFGhiBIRCg9Bt7SyoIQfE8YpmjrVeNU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706714323; x=1707319123; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=DC/uOPflor2esnin6Duf0AkqzsVoBFIA7oTap9MRWa4=; b=otHTzgVRCuGN/ZZ03XrcEEUZrxM80pd5urKLnzgsN4nu0az35PFnS1ZIxK7GavXXGd 8FZCWmtdlvJO33G6qD0p2BKrvgho3Z9So40A6p44z95oP8hBreyq2QKy4ASLNePCwttz ZUn+F1k/iO4YLljaZKskuONrYjukOVuAIuVfWFVE0hlI3KR2Zl7YVTtVL0uJ6yW2aKcV JG7PLLJE9qrhWECfbXflHOBxGesIKYDSd03EaOzxCmNnsHVLXCUThM+5pbtdmGnK01Zt m+waOzmC8kHeAu6K36Lw3y8QUgZ6RtDIOvWEF8WyYDVb8cfT/xfwVzrjfwlMAaS+Oup8 z6IA== X-Forwarded-Encrypted: i=0; AJvYcCWgdu7EC4UmvhyjXTZNA/FxGNCCFmw4MaLfxysASQjGILkA6j0blzDEdrDd0/CB7542oCPp8T5CCB5edFt31bK0KFzOE0z6F3dn X-Gm-Message-State: AOJu0YyLQsKlSW4CHJUaYNPMJTmhXIU6VB/e5ClYu+A9PNpUhLSFrtVc LaBXxA0dhcqrqahlzg6TkFgkQImjx8sVH/4xHfdLsRSQOxhylI1iJeq+bpqATiy9X2No9D2VFKm 5IHbq9EDloRVhdI2gqQouNLHI/tNhjVdgnWgZEVR+zGxSqc1OcA== X-Google-Smtp-Source: AGHT+IEPBaDz/iSJMDUwxtjFCQi76jdO077hgTjii3FJYZUPhkXtHE0QsBPmyGa/pvO4TaMKntDHpdpC8wyXh/bHAB0= X-Received: by 2002:a05:6122:3659:b0:4b7:3417:b5a4 with SMTP id dv25-20020a056122365900b004b73417b5a4mr1580329vkb.1.1706714323244; Wed, 31 Jan 2024 07:18:43 -0800 (PST) MIME-Version: 1.0 References: <20230420172436.2013698-1-adhemerval.zanella@linaro.org> <4115d7fd-d7a7-cdb1-3833-daf45186480f@linaro.org> <967b94b4-d819-278f-1782-6b758d0841b6@linaro.org> <877cjqym2n.fsf@oldenburg.str.redhat.com> <87aa8879-8590-4cb1-9ad1-563c09707356@linaro.org> In-Reply-To: <87aa8879-8590-4cb1-9ad1-563c09707356@linaro.org> From: =?UTF-8?Q?Cristian_Rodr=C3=ADguez?= Date: Wed, 31 Jan 2024 12:18:32 -0300 Message-ID: Subject: Re: [PATCH] nptl: Disable THP on thread stack if it incurs in large RSS usage To: Adhemerval Zanella Netto Cc: Florian Weimer , Wilco Dijkstra , "libc-alpha@sourceware.org" , Cupertino Miranda Content-Type: multipart/alternative; boundary="000000000000f897d906103f6410" X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: --000000000000f897d906103f6410 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Jan 31, 2024 at 8:30=E2=80=AFAM Adhemerval Zanella Netto < adhemerval.zanella@linaro.org> wrote: > > > On 31/01/24 04:54, Florian Weimer wrote: > > * Cristian Rodr=C3=ADguez: > > > >> On Tue, May 23, 2023 at 5:48=E2=80=AFAM Wilco Dijkstra via Libc-alpha < > libc-alpha@sourceware.org> > >> wrote: > >> > >>> However even switching off THP for all small stacks (eg. default size > or smaller) > >>> would avoid the random use of THP without needing to set the tunable. > >>> > >>> Cheers, > >>> Wilco > >> > >> > >> Didn't found the exact message to reply.. but this one is close enough. > MAP_STACK implies no > >> transparent hugepages since linux kernel commit > >> > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit= /?id=3Dc4608d1bf7c6536d1a3d233eb21e50678681564e > > > > It's an odd choice for fixing the regression. I commented on the > > linux-mm thread. It's also surprising to see such changes being made > > without larger discussion. > > Do you have a link for this discussion? > Doesn't this also imply that the kernel expects the MAP_GROWSDOWN flag #if _STACK_GROWS_DOWN to do the right thing elsewhere ? --000000000000f897d906103f6410--