On Thu, Jul 20, 2017 at 09:48:13AM -0500, Steven Munroe wrote:
> > > --- gcc/testsuite/gcc.target/powerpc/mmx-packs.c  (nonexistent)
> > > +++ gcc/testsuite/gcc.target/powerpc/mmx-packs.c  (working copy)
> > > @@ -0,0 +1,91 @@
> > > +/* { dg-do run } */
> > > +/* { dg-options "-O3 -mpower8-vector" } */
> > > +/* { dg-require-effective-target lp64 } */
> > > +/* { dg-require-effective-target p8vector_hw { target powerpc*-*-* } }
> > > */
> > 
> > Why have the target selector here, and not on the dg-options line as
> > well?  Don't we need it in both places, or neither?  (I think you don't
> > need it, same for all other files here).
> > 
> I was backed into this because we dont have the 
> /* (dg-require-effective-target p8vector_min } */
> 
> yet. And we don't want to use -mcpu=power8 if we mean power8 or power9
> and later.
> 
> The { target powerpc*-*-* } bit is there to enable possible future
> sharing of DG tests across platforms. So I should either remove the
> target selector or add it any line that the platform specific? For
> example:
> 
> /* { dg-options "-O3 -mpower8-vector" { target powerpc*-*-* } } */
> 
> If you agree with the above, I will correct and commit.

I would just leave it off.  Premature generalization is the root of
all evil.

If ever we share these testcases we probably should have a
{ dg-require-effective-target x86-vector-intrinsics-emulation }
or similar, which we then do not even need to set per testcase (but
instead require it in the .exp for that testsuite directory).

It will work either way currently, of course.


Segher

Reply via email to