Support -std=f2018
[official-gcc.git] / libgomp / testsuite / libgomp.graphite / graphite.exp
blob48b9531655438a91870515347f4b692406f2a867
1 # Copyright (C) 2009-2017 Free Software Foundation, Inc.
3 # This program is free software; you can redistribute it and/or modify
4 # it under the terms of the GNU General Public License as published by
5 # the Free Software Foundation; either version 3 of the License, or
6 # (at your option) any later version.
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 # GNU General Public License for more details.
13 # You should have received a copy of the GNU General Public License
14 # along with GCC; see the file COPYING3. If not see
15 # <http://www.gnu.org/licenses/>.
17 if [info exists lang_library_path] then {
18 unset lang_library_path
19 unset lang_link_flags
21 if [info exists lang_test_file] then {
22 unset lang_test_file
24 if [info exists lang_include_flags] then {
25 unset lang_include_flags
28 load_lib libgomp-dg.exp
29 load_gcc_lib gcc-dg.exp
31 if ![check_effective_target_pthread] {
32 return
35 if ![check_effective_target_fgraphite] {
36 return
39 # Flags for force-parallel-*.c testcases.
40 set PARALLEL_CFLAGS "-ansi -pedantic-errors -O2 \
41 -ftree-parallelize-loops=4 -floop-parallelize-all \
42 -fdump-tree-parloops-details -fdump-tree-optimized \
43 -fno-loop-strip-mine -fno-loop-block -fdump-tree-graphite-all"
45 # Initialize `dg'.
46 dg-init
48 # Turn on OpenMP.
49 lappend ALWAYS_CFLAGS "additional_flags=-fopenmp"
51 # Gather a list of all tests.
52 set tests [lsort [find $srcdir/$subdir *.c]]
54 set ld_library_path $always_ld_library_path
55 append ld_library_path [gcc-set-multilib-library-path $GCC_UNDER_TEST]
56 set_ld_library_path_env_vars
58 # Run the tests
59 dg-runtest $tests "" $PARALLEL_CFLAGS
61 # All done.
62 dg-finish