This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH, i386 testsuite]: Move arrays out of test function to enable vectorization.


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]