On Wed, 2008-04-23 at 10:56 -0500, Joel Sherrill wrote:
> Hi,
> 
> I am returning to this issue and it is more
> pressing testing powerpc on 4.3.0 and the trunk.
> powerpc-rtems has gone from a relatively small
> percentage of failures to >8300 and this warning
> shows up a lot (5120334 times)!
> 
>  Warning: /home/joel/work-gnat/svn/b-gcc1-powerpc/rtems_gcc_main.o uses 
> hard float, 
> /home/joel/work-gnat/svn/b-gcc1-powerpc/gcc/testsuite/gcc/20010124-1.x0 
> uses soft float
> 
> $ grep "hard float" ./gcc/testsuite/gcc/gcc.log | wc -l
> 5120334
> 
> The target is psim/603e. 
> rtems_gcc_main.o is the configuration file and RTEMS
> initialization task setup for the gcc tests. 
> This file and the RTEMS library for were compiled with
> hard float.
> 
> On this target, we really need to skip these tests to
> get rid of all this noise.  I can't even begin to tell what
> else is broken.
> 
> I had the impression you weren't happy with the code
> you proposed and didn't sweep it in.   Is it an acceptable
> solution?  Or do you all have another idea?

I don't think it's workable, but I understand that the
problem does require a solution.  Is this a fair statement
of the problem?

  Multilib options can include -mcpu= or -march=.

  Many target-specific tests use dg-options to specify use
  of -mcpu= or -march= for that test.

  Multilib options appear in the command line after the options
  specified with -mcpu and can result in using surprising or
  conflicting options for a particular test.

  We need a way to skip a test if the options needed to compile
  that test are not compatible with current multilib options.

This could get ugly, so I'd prefer to find a way to do the
necessary checks outside of the test itself, in a new directive.
If that sounds workable I'll look into it.

Janis

> Janis Johnson wrote:
> > On Fri, 2008-03-14 at 10:21 -0700, Janis Johnson wrote:
> >   
> >> On Fri, 2008-03-14 at 10:18 -0500, Joel Sherrill wrote:
> >>
> >>     
> >>> /* { dg-skip-if "" { *-*-* } { "-mcpu=405" } { "-mcpu=" } } */
> >>>
> >>> I think this is doing what we want it to. It looks like it results
> >>> the tests getting run when -mcpu=405 and excluded when
> >>> -mcpu=603e is set on the board cflags.
> >>>       
> >> The test directives are documented in the internals manual.  From
> >> sourcebuild.texi:
> >>
> >> @item @{ dg-skip-if @var{comment} @{ @var{selector} @}
> >> @{ @var{include-opts} @} @{ @var{exclude-opts} @} @}
> >> Skip the test if the test system is included in @var{selector} and if
> >> each of the options in @var{include-opts} is in the set of options with
> >> which the test would be compiled and if none of the options in
> >> @var{exclude-opts} is in the set of options with which the test would be
> >> compiled.
> >>
> >> The directive above says to skip the test on any target when
> >> "-mcpu=450" is used and "-mcpu=" is not used.  You'd actually
> >> want "-mcpu=*", since "-mcpu=" isn't a full option, but then
> >> the test will never be skipped whenever -mcpu=* is used.
> >>
> >> Proc check_conditional_xfail from framework.exp in DejaGnu
> >> processes the lists of included and excluded option and with
> >> "--verbose --verbose" in RUNTESTFLAGS will print messages to
> >> the test log (e.g. obj_dir/gcc/testsuite/gcc/gcc.log) about
> >> its progress.
> >>
> >> I think that dg-skip-if won't do what you need and you'll need
> >> to add effective-target keywords.
> >>     
> >
> > On the other hand, to run a test for -mcpu=450 but no other -mcpu
> > option, this very ugly directive works (pattern matching is done
> > with globs):
> >
> > /* { dg-skip-if "" { *-*-* } { "" } { "-mcpu=[0-35-9][0-46-9][1-9]*" } } */
> >
> > That kind of thing could get ugly very quickly if there are
> > multiple cpus that would work.
> >
> >   
> 

Reply via email to