OSDN Git Service

selftests/powerpc/64: Test all paths through copy routines
authorPaul Mackerras <paulus@ozlabs.org>
Fri, 3 Aug 2018 10:13:04 +0000 (20:13 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 7 Aug 2018 14:32:35 +0000 (00:32 +1000)
commit98c45f51f767bfdd71d773cceaceb403352e51ae
treeb9ce68ebda36604610d02d727f60088f9845770b
parenta7c81ce398e2ad304f61d6167155f3ef65a96524
selftests/powerpc/64: Test all paths through copy routines

The hand-coded assembler 64-bit copy routines include feature sections
that select one code path or another depending on which CPU we are
executing on.  The self-tests for these copy routines end up testing
just one path.  This adds a mechanism for selecting any desired code
path at compile time, and makes 2 or 3 versions of each test, each
using a different code path, so as to cover all the possible paths.

Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
[mpe: Add -mcpu=power4 to CFLAGS for older compilers]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/lib/copyuser_64.S
arch/powerpc/lib/copyuser_power7.S
arch/powerpc/lib/memcpy_64.S
arch/powerpc/lib/memcpy_power7.S
tools/testing/selftests/powerpc/copyloops/.gitignore
tools/testing/selftests/powerpc/copyloops/Makefile
tools/testing/selftests/powerpc/copyloops/asm/ppc_asm.h