<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-dev/tools/testing/selftests/powerpc/benchmarks/context_switch.c, branch linus/master</title>
<subtitle>Linux kernel development work - see feature branches</subtitle>
<id>https://git.zx2c4.com/linux-dev/atom/tools/testing/selftests/powerpc/benchmarks/context_switch.c?h=linus%2Fmaster</id>
<link rel='self' href='https://git.zx2c4.com/linux-dev/atom/tools/testing/selftests/powerpc/benchmarks/context_switch.c?h=linus%2Fmaster'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/'/>
<updated>2020-09-08T12:24:10Z</updated>
<entry>
<title>selftests/powerpc: Don't touch VMX/VSX on older CPUs</title>
<updated>2020-09-08T12:24:10Z</updated>
<author>
<name>Michael Ellerman</name>
<email>mpe@ellerman.id.au</email>
</author>
<published>2020-08-19T01:57:26Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=09275d717d1b2d7d5ed91f2140bb34246514a1b4'/>
<id>urn:sha1:09275d717d1b2d7d5ed91f2140bb34246514a1b4</id>
<content type='text'>
If we're running on a CPU without VMX/VSX then don't touch them. This
is fragile, the compiler could spill a VMX/VSX register and break the
test anyway. But in practice it seems to work, ie. the test runs to
completion on a system without VSX with this change.

Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
Link: https://lore.kernel.org/r/20200819015727.1977134-8-mpe@ellerman.id.au
</content>
</entry>
<entry>
<title>selftests/powerpc: Fix CPU affinity for child process</title>
<updated>2020-07-29T12:30:34Z</updated>
<author>
<name>Harish</name>
<email>harish@linux.ibm.com</email>
</author>
<published>2020-06-09T08:14:23Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=854eb5022be04f81e318765f089f41a57c8e5d83'/>
<id>urn:sha1:854eb5022be04f81e318765f089f41a57c8e5d83</id>
<content type='text'>
On systems with large number of cpus, test fails trying to set
affinity by calling sched_setaffinity() with smaller size for affinity
mask. This patch fixes it by making sure that the size of allocated
affinity mask is dependent on the number of CPUs as reported by
get_nprocs().

Fixes: 00b7ec5c9cf3 ("selftests/powerpc: Import Anton's context_switch2 benchmark")
Reported-by: Shirisha Ganta &lt;shiganta@in.ibm.com&gt;
Signed-off-by: Sandipan Das &lt;sandipan@linux.ibm.com&gt;
Signed-off-by: Harish &lt;harish@linux.ibm.com&gt;
Reviewed-by: Kamalesh Babulal &lt;kamalesh@linux.vnet.ibm.com&gt;
Reviewed-by: Satheesh Rajendran &lt;sathnaga@linux.vnet.ibm.com&gt;
Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
Link: https://lore.kernel.org/r/20200609081423.529664-1-harish@linux.ibm.com
</content>
</entry>
<entry>
<title>treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152</title>
<updated>2019-05-30T18:26:32Z</updated>
<author>
<name>Thomas Gleixner</name>
<email>tglx@linutronix.de</email>
</author>
<published>2019-05-27T06:55:01Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=2874c5fd284268364ece81a7bd936f3c8168e567'/>
<id>urn:sha1:2874c5fd284268364ece81a7bd936f3c8168e567</id>
<content type='text'>
Based on 1 normalized pattern(s):

  this program is free software you can redistribute it and or modify
  it under the terms of the gnu general public license as published by
  the free software foundation either version 2 of the license or at
  your option any later version

extracted by the scancode license scanner the SPDX license identifier

  GPL-2.0-or-later

has been chosen to replace the boilerplate/reference in 3029 file(s).

Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Reviewed-by: Allison Randal &lt;allison@lohutok.net&gt;
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190527070032.746973796@linutronix.de
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>selftests/powerpc: context_switch: Fix pthread errors</title>
<updated>2017-10-13T08:41:56Z</updated>
<author>
<name>Cyril Bur</name>
<email>cyrilbur@gmail.com</email>
</author>
<published>2017-07-04T01:21:15Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=89aca4753eb451a48f65a12b02640365dba3d4ea'/>
<id>urn:sha1:89aca4753eb451a48f65a12b02640365dba3d4ea</id>
<content type='text'>
Turns out pthreads returns an errno and doesn't set errno. This doesn't
play well with perror().

Signed-off-by: Cyril Bur &lt;cyrilbur@gmail.com&gt;
Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
</content>
</entry>
<entry>
<title>selftests/powerpc: context_switch use private futexes with threads</title>
<updated>2017-06-05T06:55:01Z</updated>
<author>
<name>Nicholas Piggin</name>
<email>npiggin@gmail.com</email>
</author>
<published>2017-06-04T12:06:22Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=b27ce776852078df9e14a223b375db6507096963'/>
<id>urn:sha1:b27ce776852078df9e14a223b375db6507096963</id>
<content type='text'>
This reduces overhead of mutex locking and increases context switch
rate significantly (which helps to measure and profile the context
switch path).

Signed-off-by: Nicholas Piggin &lt;npiggin@gmail.com&gt;
Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
</content>
</entry>
<entry>
<title>selftests/powerpc: Move shared headers into new include dir</title>
<updated>2016-11-17T06:11:47Z</updated>
<author>
<name>Simon Guo</name>
<email>wei.guo.simon@gmail.com</email>
</author>
<published>2016-09-30T02:32:51Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=15ec3997aa3bffc461f7b47ca9365d4b0323c671'/>
<id>urn:sha1:15ec3997aa3bffc461f7b47ca9365d4b0323c671</id>
<content type='text'>
There are some functions, especially register related, which can
be shared across multiple selftests/powerpc test directories.

This patch creates a new include directory to store those shared
files, so that the file layout becomes more neat.

Signed-off-by: Simon Guo &lt;wei.guo.simon@gmail.com&gt;
[mpe: Reworked to move the headers only]
Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
</content>
</entry>
<entry>
<title>selftests/powerpc: Fix generation of vector instructions/types in context_switch</title>
<updated>2016-07-05T13:49:50Z</updated>
<author>
<name>Cyril Bur</name>
<email>cyrilbur@gmail.com</email>
</author>
<published>2016-03-03T23:06:40Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=f2418ae8a81760b4dec8d5e3e7f1faf45c422e9d'/>
<id>urn:sha1:f2418ae8a81760b4dec8d5e3e7f1faf45c422e9d</id>
<content type='text'>
Currently it doesn't appear the resulting binary actually uses any
Altivec or VSX instructions the solution is to explicitly tell GCC to
use vector instructions and use vector types in the code.

Part of this this issue can be GCC version specific:

GCC 4.9.x is happy to use Altivec and VSX instructions if altivec.h is
includedi (and possibly if vector types are used), this also means that
4.9.x will use VSX instructions even if only -maltivec is passed. It is
also possible that Altivec instructions will be used even without
-maltivec or -mabi=altivec.

GCC 5.2.x complains about the lack of -maltivec parameter if altivec.h
is included and will not use VSX unless -mvsx is present on commandline.

GCC 5.3.0 has a regression that means __attribute__((__target__("no-vsx"))
fails to build. A fix is targeted for 5.4.

Furthermore LTO (Link Time Optimisation) doesn't play well with
__attribute__((__target__("no-vsx")), LTO can cause GCC to forget about
the attribute and compile with VSX instructions regardless. Be wary when
enabling -flfo for this test.

Signed-off-by: Cyril Bur &lt;cyrilbur@gmail.com&gt;
Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
</content>
</entry>
<entry>
<title>selftests/powerpc: Fix usage message in context_switch</title>
<updated>2016-07-05T13:49:49Z</updated>
<author>
<name>Cyril Bur</name>
<email>cyrilbur@gmail.com</email>
</author>
<published>2016-03-03T23:06:39Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=94fa56a96a39914551694673fdb483b8924b0e56'/>
<id>urn:sha1:94fa56a96a39914551694673fdb483b8924b0e56</id>
<content type='text'>
When we inverted the behaviour of the flags we forgot to update the
usage message.

Fixes: 51c21e72eb99 ("selftests/powerpc: Make context_switch touch FP/altivec/vector by default")
Signed-off-by: Cyril Bur &lt;cyrilbur@gmail.com&gt;
Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
</content>
</entry>
<entry>
<title>selftests/powerpc: Make context_switch touch FP/altivec/vector by default</title>
<updated>2015-12-16T23:46:43Z</updated>
<author>
<name>Michael Ellerman</name>
<email>mpe@ellerman.id.au</email>
</author>
<published>2015-12-02T09:44:11Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=51c21e72eb99d1136614135d633baae269893778'/>
<id>urn:sha1:51c21e72eb99d1136614135d633baae269893778</id>
<content type='text'>
Simply because it touches more code paths that way, and therefore tests
more things.

Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
Acked-by: Anton Blanchard &lt;anton@samba.org&gt;
</content>
</entry>
<entry>
<title>selftests/powerpc: Make context_switch do something with no args</title>
<updated>2015-12-16T23:46:42Z</updated>
<author>
<name>Michael Ellerman</name>
<email>mpe@ellerman.id.au</email>
</author>
<published>2015-12-02T09:44:10Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=ea0c321784565c681507e02acf900deaa1e9e952'/>
<id>urn:sha1:ea0c321784565c681507e02acf900deaa1e9e952</id>
<content type='text'>
For ease of use make the context_switch test do something useful when
called with no arguments.

Default to a 30 second run, using threads, doing yield, and use any
online cpu. Make it print out what it's doing to avoid confusion.

Signed-off-by: Michael Ellerman &lt;mpe@ellerman.id.au&gt;
Acked-by: Anton Blanchard &lt;anton@samba.org&gt;
</content>
</entry>
</feed>
