From: "Hunt, David" <david.hunt@intel.com>
To: "Sexton, Rory" <rory.sexton@intel.com>, dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH v2 2/3] examples/vm_power_manager: Allowing power managing of idle cores
Date: Thu, 25 Jun 2020 11:17:56 +0100 [thread overview]
Message-ID: <33dc3a9f-b3ca-ac3a-0f02-148d24bf3b2b@intel.com> (raw)
In-Reply-To: <20200518103902.27927-2-rory.sexton@intel.com>
Hi Rory,
On 18/5/2020 11:39 AM, Sexton, Rory wrote:
> This change is required to allow the branch ratio algorithm to
> power manage cores with no workload running on them. This is
> useful both when idle cores don't use C-states and for a number of
> hyperthreading scenarios.
>
> Signed-off-by: Rory Sexton <rory.sexton@intel.com>
> ---
> examples/vm_power_manager/oob_monitor_x86.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/examples/vm_power_manager/oob_monitor_x86.c b/examples/vm_power_manager/oob_monitor_x86.c
> index 3c514475f..a5b1c168c 100644
> --- a/examples/vm_power_manager/oob_monitor_x86.c
> +++ b/examples/vm_power_manager/oob_monitor_x86.c
> @@ -96,12 +96,12 @@ apply_policy(int core)
> g_branch_misses = miss_diff;
>
> if (hits_diff < (INTERVAL*100)) {
> - /* Likely no workload running on this core. Skip. */
> - return -1.0;
> + /* Likely no workload running on this core. */
> + ratio = 0.0;
> + } else {
> + ratio = (float)miss_diff * (float)100 / (float)hits_diff;
> }
>
> - ratio = (float)miss_diff * (float)100 / (float)hits_diff;
> -
> /*
> * Store the last few directions that the ratio indicates
> * we should take. If there's on 'up', then we scale up
Good enhancement. It hadn't occurred to me to manage non-PMD workloads,
but I agree that when
C-States are disabled on a system, there may be cases where this
algorithm is useful to save power.
Reviewed-by: David Hunt <david.hunt@intel.com>
next prev parent reply other threads:[~2020-06-25 10:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-05-18 10:39 [dpdk-dev] [PATCH v2 1/3] examples/vm_power_manager: Make branch ratio threshold per core Sexton, Rory
2020-05-18 10:39 ` [dpdk-dev] [PATCH v2 2/3] examples/vm_power_manager: Allowing power managing of idle cores Sexton, Rory
2020-06-25 10:17 ` Hunt, David [this message]
2020-05-18 10:39 ` [dpdk-dev] [PATCH v2 3/3] doc: update vm_power_manager cmdline options in doc Sexton, Rory
2020-06-25 10:21 ` Hunt, David
2020-06-25 10:14 ` [dpdk-dev] [PATCH v2 1/3] examples/vm_power_manager: Make branch ratio threshold per core Hunt, David
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=33dc3a9f-b3ca-ac3a-0f02-148d24bf3b2b@intel.com \
--to=david.hunt@intel.com \
--cc=dev@dpdk.org \
--cc=rory.sexton@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).