This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH], Add check ppc_cpu_supports_hw to testsuite
- From: Peter Bergner <bergner at vnet dot ibm dot com>
- To: Michael Meissner <meissner at linux dot vnet dot ibm dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>, Segher Boessenkool <segher at kernel dot crashing dot org>, David Edelsohn <dje dot gcc at gmail dot com>, Bill Schmidt <wschmidt at linux dot vnet dot ibm dot com>
- Date: Wed, 28 Jun 2017 09:58:40 -0500
- Subject: Re: [PATCH], Add check ppc_cpu_supports_hw to testsuite
- Authentication-results: sourceware.org; auth=none
- References: <20170627235321.GA13753@ibm-tiger.the-meissners.org>
On 6/27/17 6:53 PM, Michael Meissner wrote:
> This adds a target supports option in dejagnu so that future tests can use this
> to determine whether or not to test target_clones.
I like the idea, but some comments...
> + #ifdef __MACH__
> + asm volatile ("xxlor vs0,vs0,vs0");
> + #else
> + asm volatile ("xxlor 0,0,0");
> + #endif
What is this hunk for? We're only interested in the return value from
the builtin below, correct?
> + if (!__builtin_cpu_supports ("vsx"))
> + return 1;
> + return 0;
...and more importantly, why limit us to testing "vsx"? Why not test
for "ppc32", which should be true for *all* kernels we'd ever run on,
including ppc32, ppc64 and ppc64le?
Peter