Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1389848
| From | Peter Zijlstra <peterz@infradead.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 01/11] x86, perf: Support sysfs files depending on SMT status |
| Date | 2016-04-28 10:20 +0200 |
| Message-ID | <rsPl1-8pu-25@gated-at.bofh.it> (permalink) |
| References | <rsDWy-7mg-7@gated-at.bofh.it> <rsDWA-7mg-39@gated-at.bofh.it> <rsPbk-8iP-25@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Thu, Apr 28, 2016 at 10:06:09AM +0200, Peter Zijlstra wrote:
> On Wed, Apr 27, 2016 at 01:00:41PM -0700, Andi Kleen wrote:
> > From: Andi Kleen <ak@linux.intel.com>
> >
> > Add a way to show different sysfs events attributes depending on
> > HyperThreading is on or off. This is difficult to determine
> > early at boot, so we just do it dynamically when the sysfs
> > attribute is read.
>
> Thomas would like to have this in the general (x86) topology bits.
>
> Because having SMT enabled (or not) is not something perf specific (nor
> Intel, because apparently AMD is going to do proper SMT too with their
> Zen micro-arch), and might very well be useful for other thingies to
> know.
>
> So I suppose it should end up somewhere around:
>
> /sys/devices/system/cpu/
FWIW I think we already can tell if SMT is enabled by doing something
like:
for i in /sys/devices/system/cpu/cpu*/topology/thread_siblings_list;
do
SMT=`cat $i | awk --field-separator "," '{print NF}'`;
if [ $SMT -gt 1 ] ; then
echo ENABLED;
break;
fi;
done
With pretty much the same races as this interface has, no?
In any case, a single value is certainly easier than the above.
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Add top down metrics to perf stat Andi Kleen <andi@firstfloor.org> - 2016-04-27 22:10 +0200
[PATCH 09/11] perf, tools, stat: Basic support for TopDown in perf stat Andi Kleen <andi@firstfloor.org> - 2016-04-27 22:10 +0200
[PATCH 07/11] perf, tools, stat: Avoid fractional digits for integer scales Andi Kleen <andi@firstfloor.org> - 2016-04-27 22:10 +0200
[PATCH 01/11] x86, perf: Support sysfs files depending on SMT status Andi Kleen <andi@firstfloor.org> - 2016-04-27 22:10 +0200
Re: [PATCH 01/11] x86, perf: Support sysfs files depending on SMT status Peter Zijlstra <peterz@infradead.org> - 2016-04-28 10:10 +0200
Re: [PATCH 01/11] x86, perf: Support sysfs files depending on SMT status Peter Zijlstra <peterz@infradead.org> - 2016-04-28 10:20 +0200
[PATCH 04/11] x86, perf: Use new ht_on flag in HT leak workaround Andi Kleen <andi@firstfloor.org> - 2016-04-27 22:10 +0200
[PATCH 05/11] perf, tools: Parse an .aggr-per-core event attribute Andi Kleen <andi@firstfloor.org> - 2016-04-27 22:10 +0200
csiph-web