Rafael Vanoni wrote:
> Li, Aubrey wrote:
>> Li, Aubrey wrote:
>>
>>> My system is in idle when this report was obtained.
>>>
>>> I'll investigate it and let you know what's going on.
>>>
>> hmm..., the problem is when pt_cpuidle_stat_collect()
>> calculate C0 residency, it always counts all cpus up.
>>
>> pt_cpuidle_stat_collect(double interval)
>> {
>> ----snip----
>>         /*
>>          * Assume that all the time spent in this interval will
>>          * be the default "0" state. The DTrace walker will reallocate
>>          * time out of the default bucket as it processes aggregation
>>          * records for time spent in other states.
>>          */
>>         g_cstate_info[0].total_time = (long)(interval * g_ncpus * 1000);
>> ----snip----
>> }
>>
>> When we use -c option, C0 should be calculated only on the specific
>> CPU. So, here, g_ncpus is not fit for the -c option.
>>
>> Does this make sense? Do you always test powertop on one logical
>> core system?

Here's another patch with some new changes to cpufreq.c. Let me know 
what you think.

Thanks,
Rafael
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: cpu-option.diff
URL: 
<http://mail.opensolaris.org/pipermail/tesla-dev/attachments/20090106/68b7232a/attachment.ksh>

Reply via email to