From patchwork Mon Jan 9 03:38:38 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Senozhatsky X-Patchwork-Id: 13092913 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 B9C38C5479D for ; Mon, 9 Jan 2023 03:39:22 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 5756D8E0007; Sun, 8 Jan 2023 22:39:22 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 4FDFC8E0001; Sun, 8 Jan 2023 22:39:22 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 377AC8E0007; Sun, 8 Jan 2023 22:39:22 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id 1FAA08E0001 for ; Sun, 8 Jan 2023 22:39:22 -0500 (EST) Received: from smtpin04.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id DFEF61A014D for ; Mon, 9 Jan 2023 03:39:21 +0000 (UTC) X-FDA: 80333855322.04.34A93B2 Received: from mail-pj1-f44.google.com (mail-pj1-f44.google.com [209.85.216.44]) by imf11.hostedemail.com (Postfix) with ESMTP id 58D964000A for ; Mon, 9 Jan 2023 03:39:20 +0000 (UTC) Authentication-Results: imf11.hostedemail.com; dkim=pass header.d=chromium.org header.s=google header.b=c2tPZUtn; dmarc=pass (policy=none) header.from=chromium.org; spf=pass (imf11.hostedemail.com: domain of senozhatsky@chromium.org designates 209.85.216.44 as permitted sender) smtp.mailfrom=senozhatsky@chromium.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1673235560; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=dlWwNcLaCNMrFJn+GAHPbY9EaslTtgv1WCZYoXPvAgg=; b=hOJRmpCggEEqAWcXvmKB9spAFk+qNA8F4W+dWyq1OeqtdmNN5x2NZM/KdOBimGibVhb7dU R6lqgro+P9TMpzfgNAQr+PI/BhdB/4OA4FpN26k3NJT8NV6soHnRS+sMR66jusOhDwRsfJ Eh8SvxvkPBsuWMopI06hXY0UXhpODyY= ARC-Authentication-Results: i=1; imf11.hostedemail.com; dkim=pass header.d=chromium.org header.s=google header.b=c2tPZUtn; dmarc=pass (policy=none) header.from=chromium.org; spf=pass (imf11.hostedemail.com: domain of senozhatsky@chromium.org designates 209.85.216.44 as permitted sender) smtp.mailfrom=senozhatsky@chromium.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1673235560; a=rsa-sha256; cv=none; b=BPVv6Qj8+kWCHAH5uLAeOLW1J8crM4PsqhMleNJ9vAflAMNkdZWYLCq+rGfR3PfPJ+wlX9 E7GUzNUuMsjZ05bVZTRUjQLqg9+u6ATKPq7JWlTGPiyZmm6dtoilnaSU7HdfTy8GcMjkAE PzjkZkKZFiydj7o0IXDQ03YwcI2EE18= Received: by mail-pj1-f44.google.com with SMTP id m7-20020a17090a730700b00225ebb9cd01so11437768pjk.3 for ; Sun, 08 Jan 2023 19:39:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=dlWwNcLaCNMrFJn+GAHPbY9EaslTtgv1WCZYoXPvAgg=; b=c2tPZUtnfZYWUQEK/A+qra/pRjcTxBywGXUW2sLZfBlvY/CSVfMlKyEq0F6U6KfncB 0CBatdDY9OYDgJn4SGVqfFjg16m/HYXm5u1TpVVTtCVDKD+2spct3OLBo9tX8exo6E3a qmYUYHmT+f49hii4ylUIELFNoVNOomwoXRtSI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=dlWwNcLaCNMrFJn+GAHPbY9EaslTtgv1WCZYoXPvAgg=; b=smfdcnaHbLnSIo3pZbIN7B/vJLTNgEBm3zJKlzyD+1hLetffm3AEWJw4nJq/oK6+xM zb5fzvvqcAl64+tYgiCzjY8Rk1NiFHN3WGXIJsszLEur2CkZtjIMF/sXDoMkQyW50rat qfDCQJJLfFuR6+5v/7ZChFQZ5plWbnzKfv0IMBSbBQ62oPIfL0vlADQqvY8yHt1tLsGY r5gXnEv3aproBhR7xLn5uwSsZ8am+Mns7aOPqwaSnTEV10x77uS4TVkaCIIoIshwuyym GjqUmc8GLHgoqnDaZnJzKRCR2iWBb7ZCgoO71cN0UQQqlBAaqajLzJvnDQ5scx/nkf90 +Zag== X-Gm-Message-State: AFqh2krPs3CYTxyb3LJj70EBgvEwI28C6Hfaz34XIRJtuM2ipmuQ7TNZ AnGTxgY1xY9Hza0LfsQp+nZSdQ== X-Google-Smtp-Source: AMrXdXur0oxpjEODUUF9GTMwdIwC4g2lAGrc6cfHN0+4pkbqW99KdO9dMuvuer5o6Azo6AL3Yo2pYw== X-Received: by 2002:a05:6a21:6da8:b0:af:d295:e2f0 with SMTP id wl40-20020a056a216da800b000afd295e2f0mr120307008pzb.27.1673235559303; Sun, 08 Jan 2023 19:39:19 -0800 (PST) Received: from tigerii.tok.corp.google.com ([2401:fa00:8f:203:5ec1:f8d2:ce47:7ddc]) by smtp.gmail.com with ESMTPSA id u5-20020a170902e80500b00189529ed580sm4896685plg.60.2023.01.08.19.39.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 08 Jan 2023 19:39:18 -0800 (PST) From: Sergey Senozhatsky To: Minchan Kim , Andrew Morton Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, Sergey Senozhatsky Subject: [PATCHv2 4/4] zsmalloc: set default zspage chain size to 8 Date: Mon, 9 Jan 2023 12:38:38 +0900 Message-Id: <20230109033838.2779902-5-senozhatsky@chromium.org> X-Mailer: git-send-email 2.39.0.314.g84b9a713c41-goog In-Reply-To: <20230109033838.2779902-1-senozhatsky@chromium.org> References: <20230109033838.2779902-1-senozhatsky@chromium.org> MIME-Version: 1.0 X-Rspamd-Queue-Id: 58D964000A X-Rspamd-Server: rspam09 X-Rspam-User: X-Stat-Signature: wm8ejin5egjsc4x738extzku46cfz7ga X-HE-Tag: 1673235560-691559 X-HE-Meta: U2FsdGVkX19yS9IJgelezdeqESdPub+m6cVTCQovFLpMhP7W5eLf12Jbw3BsUsK09gPct/yESPZFudVhSHs1HSR9kUmQTJDVHRjk3dOcPnIji89BAiNsrdF5W33tKqMP/3+sib4le9r0jLs8QuCuTM3GDliqQ4lndsGJrlx6/IxsuUQrPOfGGI3QXrVQePvCijAUapcSOeIktHAKITI/079D0rJzG234Sketsxx5VtOC4Ev49XScb33H4ztEkybT8pe/OVEkQYfMYXhhQLib46HMATqMH3xfVIr/1gyujdmnqlwjG/qrN0iQRFfpPzDR9FC0Y2cXBf9XsiroOVPnuXyRgkCYCuQqC56UwVKvDiySRyNUQ6PX3Brloy1cHSRTzzazqKhraAUoBsATPmVq/NyXLLMvVIImQ6HLxpdPfux3viy2x/95E+3+bW5fbrtwAoMcGG73bz0l631YMj8cYaGrbNrxQGDSNSgUC0MP99q+Ou8+90oXtAEQF+fcqbPcoXa4/anz19l+e4QKIKjHltkU81gdDerV7tKLDOkHVlIuVRty9FEbZAkD/qLePsqkwtPPTgmPhdzpw48A69apdn4akYN3HhfMTPa0e169BkpwXW9zk/U+bRPFWYD0DPM5H9eO4j1Hou0lBAieYaKcQrmbz7Pyho3zW8HflaSr/JWsz1ewtXeBJ90XPR5VS77LncROZwtwBPxd8SYdMJCNeIM8ZrJew8E6ihEgGrTPyscom6i8nG72/dJNyMt9UXn7IvYpRAbhH6XADUonu7qxailvUajfjX1CLb9nqOIxpJiJIlFlyFGsYj7xagduOeZunQfSeaXScLkutgjtfzo2z9fWpmW/KwKRYr50aIV9lXVQOR/j5R+nOKkQZc32wokEX6rQi5ndXW4y2vHaf+FZERxIvMHH0QhQqybBxSWh6TLWGUIPJwbq1hwQvN8ewpWb6mXf9Me5xHRHRV0V0LL qUsI9c6L LhrcyzLj5ZsHQeDYAv5JK+NyiZOyW7hYibpYgWR5QSe3+v6J4yzCCFBiBcnVSGa4AaWBJCcdgE/BcXtolA22mP5mlXtd78nmtFtqnaHME3DPkeczfdcyQ4g4nQM7xUwH5beGmKffUc6OrUcU= 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: This changes key characteristics (pages per-zspage and objects per-zspage) of a number of size classes which in results in different pool configuration. With zspage chain size of 8 we have more size clases clusters (123) and higher huge size class watermark (3632 bytes). Please read zsmalloc documentation for more details. Signed-off-by: Sergey Senozhatsky Acked-by: Minchan Kim --- mm/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/Kconfig b/mm/Kconfig index 5b2863de4be5..d854a421821b 100644 --- a/mm/Kconfig +++ b/mm/Kconfig @@ -193,7 +193,7 @@ config ZSMALLOC_STAT config ZSMALLOC_CHAIN_SIZE int "Maximum number of physical pages per-zspage" - default 4 + default 8 range 1 16 depends on ZSMALLOC help