[PATCH] cpufreq: intel_pstate: Update Balance performance EPP for Sapphire Rapids

From: Srinivas Pandruvada
Date: Wed Feb 22 2023 - 01:45:48 EST


While majority of server OS distributions are deployed with performance
governor as the default, some distributions like Ubuntu uses powersave
governor as the default.

While the powersave governor has much lower power, the performance is
lower than +25% for several workloads compared to performance governor.

One report is published by www.Phoronix.com showing difference of 37%.

The goal here is to keep mean performance delta of powersave governor
from performance governor around 10% to 12% by running wide variety
of server workloads. For some bursty workload, this delta can be still
large, as ramp up of frequency will still lag with powersave governor
irrespective of EPP setting. The performance governor always requests
maximum frequency.

Based on experiments, EPP of 0x00, 0x10, 0x20, the performance delta for
powersave governor is around 12%. But the EPP 0x20 has 18% lower average
power.

Also experimets are done by raising intel_pstate sysfs min_perf_pct as
high as 50%. This didn't bring in any additional improvements compared
to just changing EPP.

>From the Alder Lake processor generation, intel_pstate driver has
capability to update EPP for the default balance_performance based
on the CPU model. Use the same method to update the default
balance_performance EPP for the Sapphire Rapids processor to 0x20.

Link: https://www.phoronix.com/review/centos-clear-spr/6
Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@xxxxxxxxxxxxxxx>
---
drivers/cpufreq/intel_pstate.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/cpufreq/intel_pstate.c b/drivers/cpufreq/intel_pstate.c
index fd73d6d2b808..32a4004d155d 100644
--- a/drivers/cpufreq/intel_pstate.c
+++ b/drivers/cpufreq/intel_pstate.c
@@ -3372,6 +3372,7 @@ static const struct x86_cpu_id intel_epp_balance_perf[] = {
* AlderLake Mobile CPUs.
*/
X86_MATCH_INTEL_FAM6_MODEL(ALDERLAKE_L, 102),
+ X86_MATCH_INTEL_FAM6_MODEL(SAPPHIRERAPIDS_X, 32),
{}
};

--
2.39.1