[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <7c86c4470906230045k578bc146wa0e09e4094d937a5@mail.gmail.com>
Date: Tue, 23 Jun 2009 09:45:03 +0200
From: stephane eranian <eranian@...glemail.com>
To: "Wang, Yong Y" <yong.y.wang@...el.com>
Cc: Ingo Molnar <mingo@...e.hu>,
Peter Zijlstra <a.p.zijlstra@...llo.nl>,
LKML <linux-kernel@...r.kernel.org>,
Paul Mackerras <paulus@...ba.org>,
Andi Kleen <andi@...stfloor.org>
Subject: Re: perf_counter Atom patch
Hi,
On Tue, Jun 23, 2009 at 5:38 AM, Wang, Yong Y<yong.y.wang@...el.com> wrote:
>> From: stephane eranian [mailto:eranian@...glemail.com]
>>
>> I would like to better understand what makes you think
>> this is the case.
>>
>
> Because I observed that the output of 'perf stat -e 0:0 -e 0:1 -e 0:6 <cmd>'
> is always like below without the quirk.
>
> Performance counter stats for '<cmd>':
>
> 0 cycles
> 0 instructions
> 0 bus-cycles
>
>> Perfmon is working on Atom and there, fixed counters work perfectly:
>> $ head -6 /proc/cpuinfo
>> processor : 0
>> vendor_id : GenuineIntel
>> cpu family : 6
>> model : 28
>> model name : Intel(R) Atom(TM) CPU 230 @ 1.60GHz
>> stepping : 2
>> ...
>
> My cpuinfo is below and the only difference I can see is 270 vs 230.
>
> processor : 0
> vendor_id : GenuineIntel
> cpu family : 6
> model : 28
> model name : Intel(R) Atom(TM) CPU N270 @ 1.60GHz
> stepping : 2
>
Unfortunately, I don't have a N270 to compare with your results.
We need to verify whether or not N270 implements the fixed counters.
Does it report architected perfmon v3 or v1?
> The return value of CPUID(0xa) is indeed bogus, too and there is another quirk for that in
> intel_pmu_init() in arch/x86/kernel/cpu/perf_counter.c
>
> x86_pmu.num_counters_fixed = max((int)edx.split.num_counters_fixed, 3);
>
> Is this what you were talking about?
Not quite, because with the max() you'd have a problem on Intel Core
Duo/Solo processors
as they do implement the first generation of architected perfmon and
that one did not have
fixed counters. So you'd have to special case family=6 model=14.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists