public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] testsuite: Move gimplefe40.c and gimplefe41.c
@ 2021-04-15 15:55 Robin Dapp
  2021-04-16  6:38 ` Richard Biener
  0 siblings, 1 reply; 4+ messages in thread
From: Robin Dapp @ 2021-04-15 15:55 UTC (permalink / raw)
  To: gcc-patches

[-- Attachment #1: Type: text/plain, Size: 829 bytes --]

Hi,

the gimplefe40 and gimplefe41.c tests expect vector capabilities 
(vect_float etc.) yet are not in the vect subdirectory.  This causes 
both to be called unconditionally without prior target-specific vector 
setup normally performed by vect/vect.exp.

There is a target-specific option for powerpc

  /* { dg-additional-options "-maltivec" { target { powerpc*-*-* && 
powerpc_altivec_ok } } } */

which enables Altivec on supported targets but I'd rather not create 
another special case for s390.  I suppose the better solution is to move 
these tests to the vect subdirectory.

Is this OK?

Regards
  Robin

--

gcc/testsuite/ChangeLog:

         * gcc.dg/gimplefe-40.c: Moved to...
         * gcc.dg/vect/gimplefe-40.c: ...here.
         * gcc.dg/gimplefe-41.c: Moved to...
         * gcc.dg/vect/gimplefe-41.c: ...here.

[-- Attachment #2: gcc-gimplefe-move.diff --]
[-- Type: text/x-patch, Size: 904 bytes --]

commit 1acd4d01c41aeea78ec3c188beb25b245dda4c8b
Author: Robin Dapp <rdapp@linux.ibm.com>
Date:   Wed Mar 17 09:08:42 2021 +0100

    [PATCH] testsuite: Move gimplefe-4[0|1] tests.
    
    The gimplefe-40.c and gimplefe-41.c test cases require vect_* effective
    targets even though they reside in gcc.dg.  By default e.g.
    DEFAULT_VECTCFLAGS which is used to add target-specific machine or build
    flags is only applied in the ./vect subdirectory.  Move these tests
    there.

diff --git a/gcc/testsuite/gcc.dg/gimplefe-40.c b/gcc/testsuite/gcc.dg/vect/gimplefe-40.c
similarity index 100%
rename from gcc/testsuite/gcc.dg/gimplefe-40.c
rename to gcc/testsuite/gcc.dg/vect/gimplefe-40.c
diff --git a/gcc/testsuite/gcc.dg/gimplefe-41.c b/gcc/testsuite/gcc.dg/vect/gimplefe-41.c
similarity index 100%
rename from gcc/testsuite/gcc.dg/gimplefe-41.c
rename to gcc/testsuite/gcc.dg/vect/gimplefe-41.c

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] testsuite: Move gimplefe40.c and gimplefe41.c
  2021-04-15 15:55 [PATCH] testsuite: Move gimplefe40.c and gimplefe41.c Robin Dapp
@ 2021-04-16  6:38 ` Richard Biener
  2021-04-16  7:02   ` Robin Dapp
  0 siblings, 1 reply; 4+ messages in thread
From: Richard Biener @ 2021-04-16  6:38 UTC (permalink / raw)
  To: Robin Dapp; +Cc: GCC Patches

On Thu, Apr 15, 2021 at 6:50 PM Robin Dapp via Gcc-patches
<gcc-patches@gcc.gnu.org> wrote:
>
> Hi,
>
> the gimplefe40 and gimplefe41.c tests expect vector capabilities
> (vect_float etc.) yet are not in the vect subdirectory.  This causes
> both to be called unconditionally without prior target-specific vector
> setup normally performed by vect/vect.exp.
>
> There is a target-specific option for powerpc
>
>   /* { dg-additional-options "-maltivec" { target { powerpc*-*-* &&
> powerpc_altivec_ok } } } */
>
> which enables Altivec on supported targets but I'd rather not create
> another special case for s390.  I suppose the better solution is to move
> these tests to the vect subdirectory.
>
> Is this OK?

Do the testcases currently fail?  How?  In principle moving to vect/
is OK but then having the gimplefe testcases in one place is nice ...

Richard.

> Regards
>   Robin
>
> --
>
> gcc/testsuite/ChangeLog:
>
>          * gcc.dg/gimplefe-40.c: Moved to...
>          * gcc.dg/vect/gimplefe-40.c: ...here.
>          * gcc.dg/gimplefe-41.c: Moved to...
>          * gcc.dg/vect/gimplefe-41.c: ...here.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] testsuite: Move gimplefe40.c and gimplefe41.c
  2021-04-16  6:38 ` Richard Biener
@ 2021-04-16  7:02   ` Robin Dapp
  2021-04-16  9:29     ` Richard Biener
  0 siblings, 1 reply; 4+ messages in thread
From: Robin Dapp @ 2021-04-16  7:02 UTC (permalink / raw)
  To: Richard Biener; +Cc: GCC Patches

> Do the testcases currently fail?  How?  In principle moving to vect/
> is OK but then having the gimplefe testcases in one place is nice ...

yes, they ICE on targets that do not have vector capabilities:

gimplefe-40.c:7:1: internal compiler error: in emit_move_insn, at 
expr.c:3821

Normally we run vector tests with a higher arch level (when going 
through lib/target-supports.exp via vect.exp 
check_vect_support_and_set_flags).

[..]
	} elseif [check_effective_target_s390_vx] {
	    lappend DEFAULT_VECTCFLAGS "-march=z13" "-mzarch"
             set dg-do-what-default run
[..]

I suppose the same happens on powerpc, hence the dg-additional-options, 
but I haven't checked.

Regards
  Robin

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] testsuite: Move gimplefe40.c and gimplefe41.c
  2021-04-16  7:02   ` Robin Dapp
@ 2021-04-16  9:29     ` Richard Biener
  0 siblings, 0 replies; 4+ messages in thread
From: Richard Biener @ 2021-04-16  9:29 UTC (permalink / raw)
  To: Robin Dapp; +Cc: GCC Patches

On Fri, Apr 16, 2021 at 9:02 AM Robin Dapp <rdapp@linux.ibm.com> wrote:
>
> > Do the testcases currently fail?  How?  In principle moving to vect/
> > is OK but then having the gimplefe testcases in one place is nice ...
>
> yes, they ICE on targets that do not have vector capabilities:
>
> gimplefe-40.c:7:1: internal compiler error: in emit_move_insn, at
> expr.c:3821
>
> Normally we run vector tests with a higher arch level (when going
> through lib/target-supports.exp via vect.exp
> check_vect_support_and_set_flags).
>
> [..]
>         } elseif [check_effective_target_s390_vx] {
>             lappend DEFAULT_VECTCFLAGS "-march=z13" "-mzarch"
>              set dg-do-what-default run
> [..]
>
> I suppose the same happens on powerpc, hence the dg-additional-options,
> but I haven't checked.

OK, so the move to gcc.dg/vect/ is fine then.

Thanks,
Richard.

> Regards
>   Robin

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-04-16  9:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-15 15:55 [PATCH] testsuite: Move gimplefe40.c and gimplefe41.c Robin Dapp
2021-04-16  6:38 ` Richard Biener
2021-04-16  7:02   ` Robin Dapp
2021-04-16  9:29     ` Richard Biener

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).