This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, i386 testsuite]: Move arrays out of test function to enable vectorization.
- From: Dave Korn <dave dot korn dot cygwin at googlemail dot com>
- To: Uros Bizjak <ubizjak at gmail dot com>
- Cc: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 14 Jul 2009 20:21:48 +0100
- Subject: Re: [PATCH, i386 testsuite]: Move arrays out of test function to enable vectorization.
- References: <4A5CD2CB.5030409@gmail.com>
Uros Bizjak wrote:
> * gcc.target/i386/sse-recip-vec.c: Move arrays out of test
> function to enable vectorization.
> * gcc.target/i386/sse2-lrint-vec.c: Ditto.
> * gcc.target/i386/sse2-lrintf-vec.c: Ditto.
Hm.
> Index: sse-recip-vec.c
> +float r[N];
> static void
> sse_test (void)
> {
> - float r[N];
Unlike the other arrays, that one is uninitialised, and so is liable to end
up as a COMMON. Bog-standard i386 COFF doesn't support aligned common
allocations, so these could end up unaligned. (Are there any bog-standard
i386 COFF targets? Perhaps not. binutils still has some, at any rate.)
You might want to add a trivial initialiser to make sure they get assigned
to the .data section, or perhaps if any affected targets do turn up, they
could add -fno-common to the target-specific dg CFLAGS.
cheers,
DaveK