[Skiboot] [PATCH] power9-dd1:slw: Modify the stop0_lite latency & residency.

Gautham R Shenoy ego at linux.vnet.ibm.com
Fri Apr 21 14:45:24 AEST 2017


Hi Mikey,

On Thu, Apr 20, 2017 at 04:00:55PM +1000, Michael Neuling wrote:
[..snip..]
> > 
> > Hence, bump up the exit latency of stop0_lite to 1us. Since the target
> > residency is chosen to be 10 times the exit latency, set the target
> > residency to 10us.
> > 
> > With these values, we see a 50% improvement in the number of context
> > switches:
> > =====================================================================
> > x latency_200ns_residency_2us
> > + latency_1us_residency_10us
> >     N           Min           Max        Median           Avg        Stddev
> > x 100        222784        473466        294510     302295.26       45380.6
> > + 100        281790        710784        514878     510224.62     85163.252
> > Difference at 99.0% confidence
> > 	207929 +/- 24858.3
> > 	68.7835% +/- 8.22319%
> > 	(Student's t, pooled s = 68235.5)
> > =====================================================================
> > 
> > The cpuidle usage statistics show that we choose stop0_lite less often
> > in such cases.
> 
> Do you have numbers on how much this changes power usage? I assume it gets worse
> when we apply this.

I don't yet have numbers on the change in the power usage. That said,
the stop0,1,2_lite states are not expected to be saving any power as
they don't lose even the GPR state. They provide a light weight
mechanism to yield the cycles to the sibling threads in the core.

So, on idle systems when the expected latency is greater than 1us, the
cpuidle will pick stop0. Only in case when the latency is smaller than
that will cpuidle fallback to snooze.

This makes sense since stop0,1,2_lite states require an interrupt to
be woken up while snooze doesn't, and the bumped up latency value
incorporates the delay for the interrupt to be delivered to the thread
in stop0_lite state.

> 
> Mikey

--
Thanks and Regards
gautham.



More information about the Skiboot mailing list