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, testsuite] Run vectorizer tests with -funroll-loops for SPU under -O3.


On Thu, Jun 19, 2008 at 3:57 AM, Ira Rosen <IRAR@il.ibm.com> wrote:
>
> Hi,
>
> For SPU the default value of PARAM_MAX_COMPLETELY_PEEL_TIMES is overridden
> in config/spu/spu.c:spu_override_options() with 1 in case -funroll-loops
> and -fpeel-loops are not set. Therefore, the early loop unrolling pass
> fails to unroll the inner loop in gcc.dg/vect/O3-vect-pr34223.c, preventing
> the vectorization of the outer loop (and causing this testcase to fail).
> This patch turns on -funroll-loops for SPU in case of -O3.
>
> Tested on Cell SPU. O.K. for mainline?

Ok.

Thanks,
Richard.

> Thanks,
> Ira
>
> ChangeLog:
>
>      * gcc.dg/vect/vect.exp: Run tests with -funroll-loops for SPU in case
> of -O3.
>
>
> Index: testsuite/gcc.dg/vect/vect.exp
> ===================================================================
> --- testsuite/gcc.dg/vect/vect.exp      (revision 136861)
> +++ testsuite/gcc.dg/vect/vect.exp      (working copy)
> @@ -245,6 +245,9 @@ dg-runtest [lsort [glob -nocomplain $src
>  # With -O3
>  set DEFAULT_VECTCFLAGS $SAVED_DEFAULT_VECTCFLAGS
>  lappend DEFAULT_VECTCFLAGS "-O3"
> +if  [istarget "spu-*-*"] {
> +  lappend DEFAULT_VECTCFLAGS "-funroll-loops"
> +}
>  dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/O3-*.\[cS\]]]  \
>         "" $DEFAULT_VECTCFLAGS
>
>


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