Allow tree-ssa.exp to be run by itself
diff mbox series

Message ID 1579658198-16020-1-git-send-email-apinski@marvell.com
State New
Headers show
Series
  • Allow tree-ssa.exp to be run by itself
Related show

Commit Message

Andrew Pinski Jan. 22, 2020, 1:56 a.m. UTC
From: Andrew Pinski <apinski@marvell.com>

tree-ssa testcases sometimes check autovect effective target
but does not set it up.  On MIPS, those testcases fail with
some TCL error messages.  This fixes the issue by calling
check_vect_support_and_set_flags inside tree-ssa.exp.
There might be other .exp files which need to be done this
way too but I have not checked all of them.

OK?  Tested on x86_64-linux-gnu and a cross to mips64-octeon-linux-gnu.
Both full run of the testsuite and running tree-ssa.exp by itself.

Thanks,
Andrew Pinski

testsuite/ChangeLog:
* tree-ssa.exp: Set DEFAULT_VECTCFLAGS and DEFAULT_VECTCFLAGS.
Call check_vect_support_and_set_flags also.
---
 gcc/testsuite/gcc.dg/tree-ssa/tree-ssa.exp | 11 +++++++++++
 1 file changed, 11 insertions(+)

Comments

Jeff Law Jan. 22, 2020, 8:37 p.m. UTC | #1
On Tue, 2020-01-21 at 17:56 -0800, apinski@marvell.com wrote:
> From: Andrew Pinski <apinski@marvell.com>
> 
> tree-ssa testcases sometimes check autovect effective target
> but does not set it up.  On MIPS, those testcases fail with
> some TCL error messages.  This fixes the issue by calling
> check_vect_support_and_set_flags inside tree-ssa.exp.
> There might be other .exp files which need to be done this
> way too but I have not checked all of them.
> 
> OK?  Tested on x86_64-linux-gnu and a cross to mips64-octeon-linux-gnu.
> Both full run of the testsuite and running tree-ssa.exp by itself.
> 
> Thanks,
> Andrew Pinski
> 
> testsuite/ChangeLog:
> * tree-ssa.exp: Set DEFAULT_VECTCFLAGS and DEFAULT_VECTCFLAGS.
> Call check_vect_support_and_set_flags also.
OK
jeff
>
Jakub Jelinek Jan. 22, 2020, 11:39 p.m. UTC | #2
On Tue, Jan 21, 2020 at 05:56:38PM -0800, apinski@marvell.com wrote:
> From: Andrew Pinski <apinski@marvell.com>
> 
> tree-ssa testcases sometimes check autovect effective target
> but does not set it up.  On MIPS, those testcases fail with
> some TCL error messages.  This fixes the issue by calling
> check_vect_support_and_set_flags inside tree-ssa.exp.
> There might be other .exp files which need to be done this
> way too but I have not checked all of them.
> 
> OK?  Tested on x86_64-linux-gnu and a cross to mips64-octeon-linux-gnu.
> Both full run of the testsuite and running tree-ssa.exp by itself.

I don't see how this could have been tested on x86_64-linux, it breaks there
a lot of tests (ditto i686-linux).  My wild guess is that it changes the
default dg-do action for tests that don't have any, which in tree-ssa.exp
used to be dg-do compile but now it tries to link them or run them.
But it seems like it even affects the dg-do default for tests later in other
*.exp files, e.g. various i386.exp tests, some ubsan.exp etc.
What tree-ssa tests were the reason for this change?
I see
pr88497-1.c:/* { dg-require-effective-target vect_double } */
pr88497-2.c:/* { dg-require-effective-target vect_float } */
pr88497-3.c:/* { dg-require-effective-target vect_int } */
pr88497-4.c:/* { dg-require-effective-target vect_int } */
pr88497-5.c:/* { dg-require-effective-target vect_int } */
is that just those?  Or the tests that use vect_cmdline_needed effective
target?

+FAIL: gcc.dg/tree-ssa/20030920-1.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/20030920-1.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/builtin-snprintf-3.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/builtin-snprintf-3.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/builtin-sprintf-7.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/builtin-sprintf-7.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/builtin-sprintf-8.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/builtin-sprintf-8.c compilation failed to produce executable
+UNRESOLVED: gcc.dg/tree-ssa/forwprop-29.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/ipa-split-3.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/ipa-split-3.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/ivopt_5.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/ivopt_5.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/loop-14.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/loop-14.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/loop-15.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/loop-15.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/loop-22.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/loop-22.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr20739.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr20739.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr25485.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr25485.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr25501.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr25501.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr26899.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr26899.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr77808.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr77808.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr84436-2.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr84436-2.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr84436-3.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr84436-3.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr86061.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr86061.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr87205-2.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr87205-2.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr87205.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr87205.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/pr87287.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/pr87287.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/ssa-dse-36.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/ssa-dse-36.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/ssa-dse-37.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/ssa-dse-37.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/ssa-dse-38.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/ssa-dse-38.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/switch-3.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/switch-3.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/upcast-1.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/upcast-1.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/vrp103.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/vrp103.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/vrp104.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/vrp104.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/vrp106.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/vrp106.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/vrp107.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/vrp107.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/vrp108.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/vrp108.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/vrp109.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/vrp109.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/vrp110.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/vrp110.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/vrp72.c execution test
+FAIL: gcc.dg/tree-ssa/vrp73.c execution test
+FAIL: gcc.dg/tree-ssa/vrp75.c execution test
+FAIL: gcc.dg/tree-ssa/vrp97.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/vrp97.c compilation failed to produce executable
+FAIL: gcc.dg/tree-ssa/wholeprogram-2.c (test for excess errors)
+UNRESOLVED: gcc.dg/tree-ssa/wholeprogram-2.c compilation failed to produce executable

	Jakub
Jakub Jelinek Jan. 23, 2020, 12:07 a.m. UTC | #3
On Thu, Jan 23, 2020 at 12:39:34AM +0100, Jakub Jelinek wrote:
> I don't see how this could have been tested on x86_64-linux, it breaks there
> a lot of tests (ditto i686-linux).  My wild guess is that it changes the
> default dg-do action for tests that don't have any, which in tree-ssa.exp
> used to be dg-do compile but now it tries to link them or run them.
> But it seems like it even affects the dg-do default for tests later in other
> *.exp files, e.g. various i386.exp tests, some ubsan.exp etc.
> What tree-ssa tests were the reason for this change?
> I see
> pr88497-1.c:/* { dg-require-effective-target vect_double } */
> pr88497-2.c:/* { dg-require-effective-target vect_float } */
> pr88497-3.c:/* { dg-require-effective-target vect_int } */
> pr88497-4.c:/* { dg-require-effective-target vect_int } */
> pr88497-5.c:/* { dg-require-effective-target vect_int } */
> is that just those?  Or the tests that use vect_cmdline_needed effective
> target?

The following patch fixes those, though I'd really like to understand what
was the problem (which tests and why) for you.

2020-01-23  Jakub Jelinek  <jakub@redhat.com>

	* gcc.dg/tree-ssa/tree-ssa.exp: Save and restore
	dg-do-what-default around check_vect_support_and_set_flags call.

--- gcc/testsuite/gcc.dg/tree-ssa/tree-ssa.exp.jj	2020-01-22 22:37:04.523532825 +0100
+++ gcc/testsuite/gcc.dg/tree-ssa/tree-ssa.exp	2020-01-23 00:42:17.530766641 +0100
@@ -28,8 +28,13 @@ set DEFAULT_VECTCFLAGS ""
 global EFFECTIVE_TARGETS
 set EFFECTIVE_TARGETS ""
 
+global dg-do-what-default
+set save-dg-do-what-default ${dg-do-what-default}
+
 check_vect_support_and_set_flags
 
+set dg-do-what-default ${save-dg-do-what-default}
+
 # If a testcase doesn't have special options, use these.
 global DEFAULT_CFLAGS
 if ![info exists DEFAULT_CFLAGS] then {


	Jakub
Andrew Pinski Jan. 23, 2020, 12:22 a.m. UTC | #4
On Wed, Jan 22, 2020 at 3:39 PM Jakub Jelinek <jakub@redhat.com> wrote:
>
> On Tue, Jan 21, 2020 at 05:56:38PM -0800, apinski@marvell.com wrote:
> > From: Andrew Pinski <apinski@marvell.com>
> >
> > tree-ssa testcases sometimes check autovect effective target
> > but does not set it up.  On MIPS, those testcases fail with
> > some TCL error messages.  This fixes the issue by calling
> > check_vect_support_and_set_flags inside tree-ssa.exp.
> > There might be other .exp files which need to be done this
> > way too but I have not checked all of them.
> >
> > OK?  Tested on x86_64-linux-gnu and a cross to mips64-octeon-linux-gnu.
> > Both full run of the testsuite and running tree-ssa.exp by itself.
>
> I don't see how this could have been tested on x86_64-linux, it breaks there
> a lot of tests (ditto i686-linux).  My wild guess is that it changes the
> default dg-do action for tests that don't have any, which in tree-ssa.exp
> used to be dg-do compile but now it tries to link them or run them.
> But it seems like it even affects the dg-do default for tests later in other
> *.exp files, e.g. various i386.exp tests, some ubsan.exp etc.
> What tree-ssa tests were the reason for this change?
> I see
> pr88497-1.c:/* { dg-require-effective-target vect_double } */
> pr88497-2.c:/* { dg-require-effective-target vect_float } */
> pr88497-3.c:/* { dg-require-effective-target vect_int } */
> pr88497-4.c:/* { dg-require-effective-target vect_int } */
> pr88497-5.c:/* { dg-require-effective-target vect_int } */
> is that just those?
Yes it is just those.
check_effective_target_vect_double calls into et-is-effective-target
for mips*-*-* target.
et-is-effective-target is only ever used by the MIPS targets.
It was introduced by g:9b7937cf8a06.

So I did originally test it and it was working beforehand but I just
to retest it and I got the failures you listed below.
I also notice the setting of dg-do-what-default in
check_vect_support_and_set_flags now too :(.

Thanks,
Andrew


> Or the tests that use vect_cmdline_needed effective target?
>
> +FAIL: gcc.dg/tree-ssa/20030920-1.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/20030920-1.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/builtin-snprintf-3.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/builtin-snprintf-3.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/builtin-sprintf-7.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/builtin-sprintf-7.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/builtin-sprintf-8.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/builtin-sprintf-8.c compilation failed to produce executable
> +UNRESOLVED: gcc.dg/tree-ssa/forwprop-29.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/ipa-split-3.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/ipa-split-3.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/ivopt_5.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/ivopt_5.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/loop-14.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/loop-14.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/loop-15.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/loop-15.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/loop-22.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/loop-22.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr20739.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr20739.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr25485.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr25485.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr25501.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr25501.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr26899.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr26899.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr77808.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr77808.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr84436-2.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr84436-2.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr84436-3.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr84436-3.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr86061.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr86061.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr87205-2.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr87205-2.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr87205.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr87205.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/pr87287.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/pr87287.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/ssa-dse-36.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/ssa-dse-36.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/ssa-dse-37.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/ssa-dse-37.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/ssa-dse-38.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/ssa-dse-38.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/switch-3.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/switch-3.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/upcast-1.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/upcast-1.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/vrp103.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/vrp103.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/vrp104.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/vrp104.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/vrp106.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/vrp106.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/vrp107.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/vrp107.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/vrp108.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/vrp108.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/vrp109.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/vrp109.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/vrp110.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/vrp110.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/vrp72.c execution test
> +FAIL: gcc.dg/tree-ssa/vrp73.c execution test
> +FAIL: gcc.dg/tree-ssa/vrp75.c execution test
> +FAIL: gcc.dg/tree-ssa/vrp97.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/vrp97.c compilation failed to produce executable
> +FAIL: gcc.dg/tree-ssa/wholeprogram-2.c (test for excess errors)
> +UNRESOLVED: gcc.dg/tree-ssa/wholeprogram-2.c compilation failed to produce executable
>
>         Jakub
>
Jakub Jelinek Jan. 23, 2020, 12:34 a.m. UTC | #5
On Wed, Jan 22, 2020 at 04:22:54PM -0800, Andrew Pinski wrote:
> > I see
> > pr88497-1.c:/* { dg-require-effective-target vect_double } */
> > pr88497-2.c:/* { dg-require-effective-target vect_float } */
> > pr88497-3.c:/* { dg-require-effective-target vect_int } */
> > pr88497-4.c:/* { dg-require-effective-target vect_int } */
> > pr88497-5.c:/* { dg-require-effective-target vect_int } */
> > is that just those?
> Yes it is just those.
> check_effective_target_vect_double calls into et-is-effective-target
> for mips*-*-* target.
> et-is-effective-target is only ever used by the MIPS targets.
> It was introduced by g:9b7937cf8a06.
> 
> So I did originally test it and it was working beforehand but I just
> to retest it and I got the failures you listed below.
> I also notice the setting of dg-do-what-default in
> check_vect_support_and_set_flags now too :(.

My preference would be to revert your patch and move those 5
tests where they belong (i.e. gcc.dg/vect/) instead.

	Jakub
Andrew Pinski Jan. 23, 2020, 12:38 a.m. UTC | #6
On Wed, Jan 22, 2020 at 4:34 PM Jakub Jelinek <jakub@redhat.com> wrote:
>
> On Wed, Jan 22, 2020 at 04:22:54PM -0800, Andrew Pinski wrote:
> > > I see
> > > pr88497-1.c:/* { dg-require-effective-target vect_double } */
> > > pr88497-2.c:/* { dg-require-effective-target vect_float } */
> > > pr88497-3.c:/* { dg-require-effective-target vect_int } */
> > > pr88497-4.c:/* { dg-require-effective-target vect_int } */
> > > pr88497-5.c:/* { dg-require-effective-target vect_int } */
> > > is that just those?
> > Yes it is just those.
> > check_effective_target_vect_double calls into et-is-effective-target
> > for mips*-*-* target.
> > et-is-effective-target is only ever used by the MIPS targets.
> > It was introduced by g:9b7937cf8a06.
> >
> > So I did originally test it and it was working beforehand but I just
> > to retest it and I got the failures you listed below.
> > I also notice the setting of dg-do-what-default in
> > check_vect_support_and_set_flags now too :(.
>
> My preference would be to revert your patch and move those 5
> tests where they belong (i.e. gcc.dg/vect/) instead.

I agree.  Let me do that.  I looked to see if
"dg-require-effective-target vect_*" is used in any other testcase
outside of gomp/graphite/vect/target testsuite and there is none
other.

Thanks,
Andrew

>
>         Jakub
>

Patch
diff mbox series

diff --git a/gcc/testsuite/gcc.dg/tree-ssa/tree-ssa.exp b/gcc/testsuite/gcc.dg/tree-ssa/tree-ssa.exp
index 7d262ffd0fb..464fef628f8 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/tree-ssa.exp
+++ b/gcc/testsuite/gcc.dg/tree-ssa/tree-ssa.exp
@@ -19,6 +19,17 @@ 
 # Load support procs.
 load_lib gcc-dg.exp
 
+# Set up flags used for tests that don't specify options.
+global DEFAULT_VECTCFLAGS
+set DEFAULT_VECTCFLAGS ""
+
+# Set up a list of effective targets to run vector tests for all supported
+# targets.
+global EFFECTIVE_TARGETS
+set EFFECTIVE_TARGETS ""
+
+check_vect_support_and_set_flags
+
 # If a testcase doesn't have special options, use these.
 global DEFAULT_CFLAGS
 if ![info exists DEFAULT_CFLAGS] then {