On Thu, Jul 18, 2024 at 09:53:05AM -0500, Peter Bergner wrote: > On 7/18/24 8:23 AM, Segher Boessenkool wrote: > > Everything in gcc.target/powerpc is only run for target powerpc*-*-* > > anyway, so make this just > > > > /* { dg-do compile } */ > > > > please. (Or nothing, it is the default after all, but you may want to > > have it explicit). > > Personally, I do like seeing the /* { dg-do compile } */ even though > that is the default in this testsuite directory.
It depends :-) For testsuites that often do something else as well (like in gcc.target), it can be nice to be verbose, yes. > >> +/* { dg-require-effective-target powerpc_vsx_ok } */ > > > > Why is this needed? It needs a comment saying that. > > After Kewen's testsuite patch, powerpc_vsx_ok is pretty useless as it only > checks whether the assembler knows about vsx, and what people normally want > is powerpc_vsx which verifies that the compiler options used to compile the > test support generating VSX insns. That, sure, but even then it does not make any sense. Each of the funcs uses its own -mcpu= so either will have VSX or not, and it doesn't matter at all what the default compiler target does. And, absolutely nothing in this test case uses VSX at all. > > Saying that this is "to test if can use the target attr" is nonsense. > > That does not need Linux either btw. Target selection might not work > > correctly currently on some other systems, but this is not a run test! > > Agreed. Also, if the clones stuff really doesn't work for those > targets even in a compile test, then rather than diabling this way, > I think I'd like to see a target-supports clones_ok test or similar. Yup. Segher