Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp536625ybg; Wed, 3 Jun 2020 07:16:45 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxepBS238pyJEeWvahYaveHYnVqk2CB698i5VjpySgu2mdtfxAX3pz1s63sxqwvXlIje5Tu X-Received: by 2002:a17:906:2409:: with SMTP id z9mr25882098eja.442.1591193804974; Wed, 03 Jun 2020 07:16:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591193804; cv=none; d=google.com; s=arc-20160816; b=qtIKjrgfPJdlTWWw8DhnFmdag1ull+3va7y6v0S4x2fe2I+x0BYoSUCWnHnQYzG0+t A3eE86gDVviJ0Xr1Nn3ktIlHbjctU4342O3AC8mupW9alBv5hKxx/EMMhOluYjW1p6F8 7p9YavgepA2BjURg1waXMAjaxpgVzbk3nwCgT/a5IqxaPi5qQCDBFORO+VkhcXhB+2K0 cxMnwBYPsUKu+KGXiUTygk1wahCUq3uox4dzROrcxPNCc+x2FHcnMw+a1W7QiWwzZw1e w13o5ow8m7xXHhpgqHxsa5G7uMrMKV8eGmhJqejVkfroQBetRpUQo8XNK2YFhgPkORsB yGQA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:ironport-sdr:dkim-signature; bh=4Ff2FlavwNWCorfCk4OWW1ES8k5kxbCqQvU0uywv4K0=; b=SsOdFYKMdMMos/t8B8K8QDx6lhxmVVmf+UbXVN/pjCU1WyDmxROFLGwn0eV/l80MQQ jhA+x5zxCpzwm7jaf7cdd9seg4bTqvS71V6rMWAmrXqwdt67SNF8VbIewLpZ6K57wkNf tdtZej8wvAkVGVOt98ZrEsGtR5k2Izk026pVLl8JD6W3kG2lB5y3F/Lji41GiPF4+gIE L9DmLw1SIch0IUBKcbYCIx1ZMybkHlOlnQn0sASOsvZzXckznnW0bgRhYgL+U8CPKGzj /UzhTLKZt7+V2uPHINwrmct0j4S8ZfrvkknDLp4jo+X3WblCR5aLpk+DjQIkynR9sLap L2hg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=tVfb+69e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u15si1154419edq.598.2020.06.03.07.16.21; Wed, 03 Jun 2020 07:16:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=tVfb+69e; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726173AbgFCOOI (ORCPT + 99 others); Wed, 3 Jun 2020 10:14:08 -0400 Received: from smtp-fw-9101.amazon.com ([207.171.184.25]:54210 "EHLO smtp-fw-9101.amazon.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725882AbgFCOOI (ORCPT ); Wed, 3 Jun 2020 10:14:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1591193648; x=1622729648; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version; bh=4Ff2FlavwNWCorfCk4OWW1ES8k5kxbCqQvU0uywv4K0=; b=tVfb+69e/SsRImO1ca/5EtBZf7wUe4xWDRzJjv1qR3f7PRl7kXl8lLvO QKEdHcEw7j43+ODTZCsWsfxEwv/+kSI1iPC6hMrcnzKlFdirC7MYOj+Li hswKZAf3PnTDCDGWldYsJJSu197tGFSSpw3ojpYnICFJtiQcGdupfcTFC o=; IronPort-SDR: 9LPTo87SywWCVFvOKx9F2B7bSyqWuI15pbcIlfIhXQMnPvAPH8bAMF7pI2Asnp0wHrIHkBx6DC FEioX7uvQnOQ== X-IronPort-AV: E=Sophos;i="5.73,467,1583193600"; d="scan'208";a="41265128" Received: from sea32-co-svc-lb4-vlan3.sea.corp.amazon.com (HELO email-inbound-relay-2b-4e24fd92.us-west-2.amazon.com) ([10.47.23.38]) by smtp-border-fw-out-9101.sea19.amazon.com with ESMTP; 03 Jun 2020 14:14:07 +0000 Received: from EX13MTAUEA002.ant.amazon.com (pdx4-ws-svc-p6-lb7-vlan2.pdx.amazon.com [10.170.41.162]) by email-inbound-relay-2b-4e24fd92.us-west-2.amazon.com (Postfix) with ESMTPS id 3C4ECA1C6F; Wed, 3 Jun 2020 14:14:05 +0000 (UTC) Received: from EX13D31EUA001.ant.amazon.com (10.43.165.15) by EX13MTAUEA002.ant.amazon.com (10.43.61.77) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 3 Jun 2020 14:14:04 +0000 Received: from u886c93fd17d25d.ant.amazon.com (10.43.160.90) by EX13D31EUA001.ant.amazon.com (10.43.165.15) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 3 Jun 2020 14:13:48 +0000 From: SeongJae Park To: CC: SeongJae Park , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , Subject: [RFC v2 5/9] Docs/damon: Document 'initial_regions' feature Date: Wed, 3 Jun 2020 16:11:31 +0200 Message-ID: <20200603141135.10575-6-sjpark@amazon.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200603141135.10575-1-sjpark@amazon.com> References: <20200603141135.10575-1-sjpark@amazon.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.43.160.90] X-ClientProxiedBy: EX13D45UWB002.ant.amazon.com (10.43.161.78) To EX13D31EUA001.ant.amazon.com (10.43.165.15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: SeongJae Park This commit documents the 'initial_regions' feature. Signed-off-by: SeongJae Park --- Documentation/admin-guide/mm/damon/usage.rst | 34 ++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/Documentation/admin-guide/mm/damon/usage.rst b/Documentation/admin-guide/mm/damon/usage.rst index 18a19c35b4f3..137ed770c2d6 100644 --- a/Documentation/admin-guide/mm/damon/usage.rst +++ b/Documentation/admin-guide/mm/damon/usage.rst @@ -326,6 +326,40 @@ having pids 42 and 4242 as the processes to be monitored and check it again:: Note that setting the pids doesn't start the monitoring. +Initla Monitoring Target Regions +-------------------------------- + +DAMON automatically sets and updates the monitoring target regions so that +entire memory mappings of target processes can be covered. However, users +might want to limit the monitoring region to specific address ranges, such as +the heap, the stack, or specific file-mapped area. Or, some users might know +the initial access pattern of their workloads and therefore want to set optimal +initial regions for the 'adaptive regions adjustment'. + +In such cases, users can explicitly set the initial monitoring target regions +as they want, by writing proper values to the ``init_regions`` file. Each line +of the input should represent one region in below form.:: + + + +The ``pid`` should be already in ``pids`` file, and the regions should be +passed in address order. For example, below commands will set a couple of +address ranges, ``1-100`` and ``100-200`` as the initial monitoring target +region of process 42, and another couple of address ranges, ``20-40`` and +``50-100`` as that of process 4242.:: + + # cd /damon + # echo "42 1 100 + 42 100 200 + 4242 20 40 + 4242 50 100" > init_regions + +Note that this sets the initial monitoring target regions only. DAMON will +automatically updates the boundary of the regions after one ``regions update +interval``. Therefore, users should set the ``regions update interval`` large +enough. + + Record ------ -- 2.17.1