From patchwork Mon Jul 1 19:27:02 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: SeongJae Park X-Patchwork-Id: 13718584 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 6F428C2BD09 for ; Mon, 1 Jul 2024 19:27:19 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 7F9E16B00AE; Mon, 1 Jul 2024 15:27:18 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 7593D6B00AF; Mon, 1 Jul 2024 15:27:18 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 51F5C6B00B1; Mon, 1 Jul 2024 15:27:18 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 141166B00AE for ; Mon, 1 Jul 2024 15:27:18 -0400 (EDT) Received: from smtpin18.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 80D75413DC for ; Mon, 1 Jul 2024 19:27:17 +0000 (UTC) X-FDA: 82292167314.18.3304F3F Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by imf16.hostedemail.com (Postfix) with ESMTP id D8354180016 for ; Mon, 1 Jul 2024 19:27:15 +0000 (UTC) Authentication-Results: imf16.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=SqTrsWas; dmarc=pass (policy=none) header.from=kernel.org; spf=pass (imf16.hostedemail.com: domain of sj@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=sj@kernel.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1719862011; 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=F0OyRXQAfKLH+bsC+1nV7hvoxzwTzIpnmYG8prKMxZU=; b=uMlRhWCLajtLgRUWFnhPl5mqSrq/JomgEcP7Sc6FEBD9Y3V/EsztbHqZiINNWbrij7tsH0 nttWwYfyAiR2nSYv0nBd+d0riEKATl5RAHdPkEa49YJpmg5b9UwfFBXUaloylYeCrUslK6 NocADGfAgCuTS8Kir7q3+b6oiTgl+3c= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1719862011; a=rsa-sha256; cv=none; b=ug+jIw4ou88ORfFspoO2B2U6Mr/r9nVR5UNU5PAiNMYR+0U742TqfxKPQDzHl6uy8rr0Bh qKyVTvuTZTHXoZmoiFGK/Op1G2DhEG0/ExWShnxaEkgVGukIEjf67cotRTXkPNF/hXzUOW L6pIF65H3O5goUbEnbst3KSb52dgn40= ARC-Authentication-Results: i=1; imf16.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=SqTrsWas; dmarc=pass (policy=none) header.from=kernel.org; spf=pass (imf16.hostedemail.com: domain of sj@kernel.org designates 139.178.84.217 as permitted sender) smtp.mailfrom=sj@kernel.org Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id 15A6961791; Mon, 1 Jul 2024 19:27:15 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 65E82C4AF0F; Mon, 1 Jul 2024 19:27:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1719862034; bh=rJ3ulbTwJLxSK96iYt4sNzwcCfFFXn8buJECo4dQpTY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=SqTrsWasCO9YZQkdSM3QfYQxJG7JeXh+GPBfrnWwYuEEdvLsLiSebNb3Vh4KqQSq/ 9qow/oTaq2r0k/ubIKn3M0y2bStvbP2Qso3zi0Vaph0JxWnymFBzLpAMR/JzZhpLLB pBWXrLejrCSlPIc6OUeaVSlHVootzYshYHLiK5Mh1pnjpYt4ZTKK7rPG5FPnO1TbDI mGi/kniviA+TRPt6uqcyDG8A0KixgKd9/4Gw8obiLKK3feCcMjBeGaRZG2dkMKBHpu 6YSvOTk+G/13Qxe+GJE/+NR/RVCVhfypcxfcMgdsVaEH76ADaNYIJipHKgE5oPawLk D/qaDN0re7N1A== From: SeongJae Park To: Andrew Morton Cc: SeongJae Park , Jonathan Corbet , damon@lists.linux.dev, linux-mm@kvack.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 5/9] Docs/mm/damon/design: move 'Configurable Operations Set' section into 'Operations Set Layer' section Date: Mon, 1 Jul 2024 12:27:02 -0700 Message-Id: <20240701192706.51415-6-sj@kernel.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240701192706.51415-1-sj@kernel.org> References: <20240701192706.51415-1-sj@kernel.org> MIME-Version: 1.0 X-Rspamd-Server: rspam07 X-Rspamd-Queue-Id: D8354180016 X-Stat-Signature: 3fqzdhhmgbwu36t6wc5k3wpo5bp5qkut X-Rspam-User: X-HE-Tag: 1719862035-252628 X-HE-Meta: U2FsdGVkX19qNLN1ErYQ4i1+OnHpke3aAMEPLKpjMIRl5My59/jM7f6pa1i2O2FK+u6JmM5bXMsiG6T5lWEvm396wYWrDI2AR6vzqGkJPFS9UXTh5mBKfuH2imS2oEZaw6wZDjabpV8q9E/ivHIQh0w7nLsdsCIed7g2ypJoW3hP8nOi/JxPB6j0eAMx97Np7Sw1IMP8e4SpQw3pgKSJH/ZZxaoBg/AO5NMW2grx9r0uwzUSxTQdj3T08IxJkAvCnpvoUDU0LW6eiPdTQlN4XMhSUtsxp2but8NdNyI6KY6iXE86O9BhX0AI7rDPI3H/9KUDh/yHKMkacVs3XfyayumMFijUSjJSs7E0XLABxy7NQaWB32ikmbCGRqrKcNNTIG9broGGbvzTh1+ZBjoxXyvASfW5L1UN7KXU4ngINanQcgP45VtZPyYPjT6mYW5KW0si1AX14aTLpAdRa0IjCplm6jA62ZCk9XXtj98lM8I/5Pz7z8RlW5otJRbxJXPy+rgjoGYh6OWEGa1mCVSmG+c/zIn2h43IcF6mF3GWODpVb4drmePZb/7782dT9NHNGLVIxGRjUrW54lsGJ537GNNWhNpk54VbreBNEsXCtDPXZTNplQXIhOXfhVC2SmqrJlZ8A5een8BTnI7Flj7OmuiitVUJPLDWxy6TofsuExW8HvYRUdeiOu4PClFNm/Y1LMFlpas3kpXBqKkXsqtKrCXtNAxU2y8QBLAlkHdDfpwm4H7XJx4SLb7gPxZQYh8EjNdf1mdydwKvqcQZhg+IK1ET4fyZRQGQIjBsiGCm8brK2Ep+VsMCBocVoVin4600N+uQsjlGatsHta+S5IC0OTN7YkMtr9U0qA/aAxy/UbxIN84SmZbeodqLZc9GhTlOcnq0xgAoNGD5BIO7ltMl8CZ1v4uXmlznU7rk5dUnML89Snw6etRbLb/orYog65cHvk/fuc8flKT9dQn25XV x4RYfIet RFpQxbybonkjGTCREoMgeaNIPqE6Ojy3tpF1CznwGnEgHXEyPLBXpYDVRKQ/eQ7dB3xnufqm0s3lL+T9G+Dg2C0fR5Azfdm1dxM4Etp1P4FwQ0v4dJqIGtDM2W6PGNAQk5dWXyYyy1/unc/Erb7qjkcJnYYd9l+tO6HfztgEf4I2pTBYiwOmvm7tgIM6U7AX1Wioi6vQGBcq4vNE6wXN1ebNu2WLrLsLRxYx1wJV2SH/5nlY= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000005, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: 'Configurable Operations Set' section is for providing a description of the pluggability of the operations set layer. Just after that, 'Operations Set Layer' section, which is dedicated for the entire things of the layer, follows. The layout is odd, and some descriptions are duplicated. Move 'Configurable Operations Set' section into 'Operations Set Layer' and re-write some of the detailed descriptions. Signed-off-by: SeongJae Park --- Documentation/mm/damon/design.rst | 47 +++++++++++++++---------------- 1 file changed, 22 insertions(+), 25 deletions(-) diff --git a/Documentation/mm/damon/design.rst b/Documentation/mm/damon/design.rst index 991839200f80..f7029bc840ce 100644 --- a/Documentation/mm/damon/design.rst +++ b/Documentation/mm/damon/design.rst @@ -33,30 +33,6 @@ DAMON subsystem is configured with three layers including layer. -.. _damon_design_configurable_operations_set: - -Configurable Operations Set ---------------------------- - -For data access monitoring and additional low level work, DAMON needs a set of -implementations for specific operations that are dependent on and optimized for -the given target address space. On the other hand, the accuracy and overhead -tradeoff mechanism, which is the core logic of DAMON, is in the pure logic -space. DAMON separates the two parts in different layers, namely DAMON -Operations Set and DAMON Core Logics Layers, respectively. It further defines -the interface between the layers to allow various operations sets to be -configured with the core logic. - -Due to this design, users can extend DAMON for any address space by configuring -the core logic to use the appropriate operations set. If any appropriate set -is unavailable, users can implement one on their own. - -For example, physical memory, virtual memory, swap space, those for specific -processes, NUMA nodes, files, and backing memory devices would be supportable. -Also, if some architectures or devices supporting special optimized access -check primitives, those will be easily configurable. - - Programmable Modules -------------------- @@ -72,11 +48,32 @@ used by the user space end users. Operations Set Layer ==================== -The monitoring operations are defined in two parts: +.. _damon_design_configurable_operations_set: + +For data access monitoring and additional low level work, DAMON needs a set of +implementations for specific operations that are dependent on and optimized for +the given target address space. For example, below two operations for access +monitoring are address-space dependent. 1. Identification of the monitoring target address range for the address space. 2. Access check of specific address range in the target space. +DAMON consolidates these implementations in a layer called DAMON Operations +Set, and defines the interface between it and the upper layer. The upper layer +is dedicated for DAMON's core logics including the mechanism for control of the +monitoring accruracy and the overhead. + +Hence, DAMON can easily be extended for any address space and/or available +hardware features by configuring the core logic to use the appropriate +operations set. If there is no available operations set for a given purpose, a +new operations set can be implemented following the interface between the +layers. + +For example, physical memory, virtual memory, swap space, those for specific +processes, NUMA nodes, files, and backing memory devices would be supportable. +Also, if some architectures or devices support special optimized access check +features, those will be easily configurable. + DAMON currently provides below three operation sets. Below two subsections describe how those work.