linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
To: Mel Gorman <mgorman@techsingularity.net>
Cc: Takashi Iwai <tiwai@suse.de>, linux-kernel@vger.kernel.org
Subject: Re: ACPI _CST introduced performance regresions on Haswll
Date: Tue, 6 Oct 2020 21:29:24 +0200	[thread overview]
Message-ID: <25f31d3e-7a67-935f-93ba-32216a5084e2@intel.com> (raw)
In-Reply-To: <20201006190322.GL3227@techsingularity.net>

On 10/6/2020 9:03 PM, Mel Gorman wrote:
> On Tue, Oct 06, 2020 at 06:00:18PM +0200, Rafael J. Wysocki wrote:
>>> server systems") and enable-cst is the commit. It was not fixed by 5.6 or
>>> 5.9-rc8. A lot of bisections ended up here including kernel compilation,
>>> tbench, syscall entry/exit microbenchmark, hackbench, Java workloads etc.
>>>
>>> What I don't understand is why. The latencies for c-state exit states
>>> before and after the patch are both as follows
>>>
>>> /sys/devices/system/cpu/cpu0/cpuidle/state0/latency:0
>>> /sys/devices/system/cpu/cpu0/cpuidle/state1/latency:2
>>> /sys/devices/system/cpu/cpu0/cpuidle/state2/latency:10
>>> /sys/devices/system/cpu/cpu0/cpuidle/state3/latency:33
>>> /sys/devices/system/cpu/cpu0/cpuidle/state4/latency:133
>>>
>>> Perf profiles did not show up anything interesting. A diff of
>>> /sys/devices/system/cpu/cpu0/cpuidle/state0/ before and after the patch
>>> showed up nothing interesting. Any idea why exactly this patch shows up
>>> as being hazardous on Haswell in particular?
>>>
>> Presumably, some of the idle states are disabled by default on the affected
>> machines.
>>
>> Can you check the disable and default_status attributes of each state before
>> and after the commit in question?
>>
> # grep . pre-cst/cpuidle/state*/disable
> pre-cst/cpuidle/state0/disable:0
> pre-cst/cpuidle/state1/disable:0
> pre-cst/cpuidle/state2/disable:0
> pre-cst/cpuidle/state3/disable:0
> pre-cst/cpuidle/state4/disable:0
> # grep . enable-cst/cpuidle/state*/disable
> enable-cst/cpuidle/state0/disable:0
> enable-cst/cpuidle/state1/disable:0
> enable-cst/cpuidle/state2/disable:0
> enable-cst/cpuidle/state3/disable:0
> enable-cst/cpuidle/state4/disable:0
> # grep . pre-cst/cpuidle/state*/default_status
> pre-cst/cpuidle/state0/default_status:enabled
> pre-cst/cpuidle/state1/default_status:enabled
> pre-cst/cpuidle/state2/default_status:enabled
> pre-cst/cpuidle/state3/default_status:enabled
> pre-cst/cpuidle/state4/default_status:enabled
>
> After the commit, the default_status file does not appear in /sys
>
Something is amiss, then, because the commit doesn't affect the presence 
of this file.

The only thing it does is to set the use_acpi flag for several processor 
models in intel_idle.c.

It can be effectively reversed by removing all of the ".use_acpi = 
true," lines from intel_idle.c.

In particular, please check if changing the value of use_acpi in struct 
idle_cpu_hsx from 'true' to 'false' alone (without reverting the commit) 
makes the issue go away in 5.9-rc8 (the default_status file should be 
present regardless).

Cheers!



  reply	other threads:[~2020-10-06 19:29 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-06  8:36 ACPI _CST introduced performance regresions on Haswll Mel Gorman
2020-10-06 16:00 ` Rafael J. Wysocki
2020-10-06 19:03   ` Mel Gorman
2020-10-06 19:29     ` Rafael J. Wysocki [this message]
2020-10-06 21:18       ` Mel Gorman
2020-10-07 15:45         ` Rafael J. Wysocki
2020-10-08  9:09           ` Mel Gorman
2020-10-08 17:15             ` Rafael J. Wysocki
2020-10-08 17:34               ` Mel Gorman
2020-10-13 18:55                 ` Rafael J. Wysocki
2020-10-14 22:37                   ` Mel Gorman
2020-10-15 18:34                     ` Mel Gorman
2020-10-16 13:41                       ` Rafael J. Wysocki
2020-10-16 14:09                         ` Mel Gorman
2020-10-16 15:29                           ` Rafael J. Wysocki
2020-10-06 19:47     ` Mel Gorman
2020-10-07 15:40       ` Rafael J. Wysocki
2020-10-07 19:23         ` Mel Gorman

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=25f31d3e-7a67-935f-93ba-32216a5084e2@intel.com \
    --to=rafael.j.wysocki@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@techsingularity.net \
    --cc=tiwai@suse.de \
    /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).