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 for gcc.dg/tree-ssa/loop-1.c test case on IA64.


On Tue, Jan 18, 2005 at 03:16:17PM -0800, Steve Ellcey wrote:
> > From mark@codesourcery.com  Tue Jan 18 11:22:30 2005
> > 
> > Steve Ellcey wrote:
> >
> > > Setting up a special effective-target keyword sounds like a lot of work
> > > for one test.  How about the following?
> > > 
> > > /* { dg-final {scan-assembler times "foo" 5 { xfail hppa-*-* ia64-*-* } } } */
> > > /* { dg-final {scan-assembler-times "foo,%r" 5 { target hppa-*-* } } }      */
> > > /* { dg-final {scan-assembler-times "= foo" 5 { target ia64-*-* } } }       */
> > > 
> > > Is the listing of two triplet patterns in the xfail considered kosher?
> > > I found a few examples of it in other tests.
> > 
> > That would work, but it would be confusing, as it would not seem that 
> > there's some test in this file which is failing on PA and IA64, when 
> > that's not really true.  You could mitigate that with a comment, but I'd 
> > prefer that we not abuse XFAIL in this way.
> > 
> > I know this stuff is a hassle.
> 
> I wonder if we should have a 'skip' option (in addition to target and
> xfail) so we don't have to use xfail for this.  There is 'dg-skip-if',
> but that skips the entire test and the test does have value for the hppa
> and ia64 platforms so I wouldn't want to skip it entirely.

So that "skip" would be just like "target" but with the result negated?
What we really need is logical expressions in target and xfail lists,
but I don't want to design, implement, and maintain that.
 
> Another option with this specific test is to remove the assembler scan
> and just use the existing tree-dump scans to verify that the loop was
> unrolled.  I don't know what people think about that idea.
> 
> Otherwise using xfail (and having comments to describe why) seems like
> the best solution.

Using xfail isn't the right thing to do, but unfortunately there's no
easy way to do it correctly.  One ugly solution, which I mentioned
before, is to have a special effective-target keyword for everything
other than hppa and ia64.  Another ugly solution is to add to the
existing TCL test within the dg-final directive; that's usually
something to be avoided, but this test already has:

/* { dg-final { if [ istarget hppa*-*-* ] { scan-assembler-times "foo,%r" 5} else { scan-assembler-times "foo" 5} } }  */

Perhaps xfail with a comment isn't all that ugly after all.

Janis


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