RISC-V: Fix rtl checking enabled failure with -msave-restore.
[official-gcc.git] / gcc / testsuite / gdc.dg / dg.exp
blob15cbe1c416855a554d20c7fda9a151c3afcbfb28
1 # Copyright (C) 2017-2020 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 # GCC testsuite that uses the `dg.exp' driver.
19 # Load support procs.
20 load_lib gdc-dg.exp
22 # The default option list can be overridden by
23 # TORTURE_OPTIONS="{ { list1 } ... { listN } }"
25 if ![info exists TORTURE_OPTIONS] {
26 set TORTURE_OPTIONS [list \
27 { -O0 } { -O1 } { -O2 } { -O3 } { -Os } \
28 { -O0 -frelease } { -O0 -g } { -O0 -frelease -g } \
29 { -O1 -frelease } { -O1 -g } { -O1 -frelease -g } \
30 { -O2 -frelease } { -O2 -g } { -O2 -frelease -g } \
31 { -O3 -frelease } { -O3 -g } { -O3 -frelease -g } \
32 { -Os -frelease } { -Os -g } { -Os -frelease -g }]
35 # Initialize `dg'.
36 dg-init
38 # Initialize use of torture lists.
39 torture-init
40 set-torture-options $TORTURE_OPTIONS
42 # Main loop.
43 gdc-dg-runtest [lsort \
44 [glob -nocomplain $srcdir/$subdir/*.d ] ] "" ""
46 # Finalize use of torture lists.
47 torture-finish
49 # All done.
50 dg-finish