717c478953
gcc/ * Makefile.in (dg_target_exps): Remove. (check_gcc_parallelize): Change to just an upper bound number. (check-%-subtargets): Always print the non-parallelized goals. (check_p_vars, check_p_comma, check_p_subwork): Remove. (check_p_count, check_p_numbers0, check_p_numbers1, check_p_numbers2, check_p_numbers3, check_p_numbers4, check_p_numbers5, check_p_numbers6): New variables. (check_p_numbers): Set to sequence from 1 to 9999. (check_p_subdirs): Set to sequence from 1 to minimum of $(check_p_count) and either GCC_TEST_PARALLEL_SLOTS env var if set, or 128. (check-%, check-parallel-%): Rewritten so that for parallelized testing each job runs all the *.exp files, with GCC_RUNTEST_PARALLELIZE_DIR set in environment. gcc/go/ * Make-lang.in (check_go_parallelize): Change to just an upper bound number. gcc/fortran/ * Make-lang.in (check_gfortran_parallelize): Change to just an upper bound number. gcc/cp/ * Make-lang.in (check_g++_parallelize): Change to just an upper bound number. gcc/objc/ * Make-lang.in (check_objc_parallelize): Change to just an upper bound number. gcc/ada/ * gcc-interface/Make-lang.in (check_acats_numbers0, check_acats_numbers1, check_acats_numbers2, check_acats_numbers3, check_acats_numbers4, check_acats_numbers5, check_acats_numbers6, check_acats_numbers, check_acats_subdirs): New variables. (check_acats_targets): Use $(check_acats_subdirs). (check-acats, check-acats%): Rewritten so that for parallelized testing each job runs all the chapters files, with GCC_RUNTEST_PARALLELIZE_DIR set in environment. Prepare the support directory sequentially and share it. (check-acats-subtargets): Always print just check-acats. gcc/testsuite/ * lib/gcc-defs.exp (gcc_parallel_test_run_p, gcc_parallel_test_enable): New procedures. If GCC_RUNTEST_PARALLELIZE_DIR is set in environment, override runtest_file_p to invoke also gcc_parallel_test_run_p. * g++.dg/guality/guality.exp (check_guality): Save/restore test_counts array around the body of the procedure. * gcc.dg/guality/guality.exp (check_guality): Likewise. * g++.dg/plugin/plugin.exp: Run all the tests serially by the first parallel runtest encountering it. * gcc.dg/plugin/plugin.exp: Likewise. * gcc.misc-tests/matrix1.exp: Likewise. * gcc.misc-tests/dhry.exp: Likewise. * gcc.misc-tests/acker1.exp: Likewise. * gcc.misc-tests/linkage.exp: Likewise. * gcc.misc-tests/mg.exp: Likewise. * gcc.misc-tests/mg-2.exp: Likewise. * gcc.misc-tests/sort2.exp: Likewise. * gcc.misc-tests/sieve.exp: Likewise. * gcc.misc-tests/options.exp: Likewise. * gcc.misc-tests/help.exp: Likewise. * go.test/go-test.exp (go-gc-tests): Use gcc_parallel_test_enable {0, 1} around all handling of each test. * objc.dg/gnu-encoding/gnu-encoding.exp: Likewise. * ada/acats/run_all.sh: Parallelize using mkdir inside of a shared directory. Avoid forking and expr uses if shell supports $(()). libstdc++-v3/ * testsuite/Makefile.am (check_p_numbers0, check_p_numbers1, check_p_numbers2, check_p_numbers3, check_p_numbers4, check_p_numbers5, check_p_numbers6, check_p_numbers, check_p_subdirs): New variables. (check_DEJAGNU_normal_targets): Use check_p_subdirs. (check-DEJAGNU): Rewritten so that for parallelized testing each job runs all the *.exp files, with GCC_RUNTEST_PARALLELIZE_DIR set in environment. * testsuite/Makefile.in: Regenerated. * testsuite/lib/libstdc++.exp (gcc_parallel_test_run_p, gcc_parallel_test_enable): New procedures. If GCC_RUNTEST_PARALLELIZE_DIR is set in environment, override runtest_file_p to invoke also gcc_parallel_test_run_p. * testsuite/libstdc++-abi/abi.exp: Run all the tests serially by the first parallel runtest encountering it. Fix up path of the extract_symvers script. * testsuite/libstdc++-xmethods/xmethods.exp: Run all the tests serially by the first parallel runtest encountering it. Run dg-finish even in case of error. From-SVN: r215273
75 lines
2.5 KiB
Plaintext
75 lines
2.5 KiB
Plaintext
# Copyright (C) 2005-2014 Free Software Foundation, Inc.
|
|
#
|
|
# This program is free software; you can redistribute it and/or modify
|
|
# it under the terms of the GNU General Public License as published by
|
|
# the Free Software Foundation; either version 3 of the License, or
|
|
# (at your option) any later version.
|
|
#
|
|
# This program is distributed in the hope that it will be useful,
|
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
# GNU General Public License for more details.
|
|
#
|
|
# You should have received a copy of the GNU General Public License
|
|
# along with this program; see the file COPYING3. If not see
|
|
# <http://www.gnu.org/licenses/>.
|
|
|
|
# If there is no baseline file, or we can't find the library, skip
|
|
# this test. Or, hey, if we don't support this kind of symbol
|
|
# versioning test: don't run it.
|
|
|
|
# Only run whole abi.exp in one instance, serially.
|
|
if ![gcc_parallel_test_run_p abi] {
|
|
return
|
|
}
|
|
gcc_parallel_test_enable 0
|
|
|
|
if { [string match "*-*-darwin*" $target_triplet] } {
|
|
set lib $blddir/src/.libs/libstdc++.dylib
|
|
} else {
|
|
set lib $blddir/src/.libs/libstdc++.so
|
|
}
|
|
|
|
# Build the support objects.
|
|
v3-build_support
|
|
|
|
if { (${v3-symver} == 0) || ![info exists baseline_dir] \
|
|
|| ![file exists $baseline_dir] \
|
|
|| ![file exists $lib] } {
|
|
gcc_parallel_test_enable 1
|
|
return
|
|
}
|
|
|
|
set baseline_subdir "[eval exec $cxx $baseline_subdir_switch]"
|
|
|
|
set baseline_file \
|
|
[file join $baseline_dir $baseline_subdir "baseline_symbols.txt"]
|
|
# If there is no ABI-specific reference file use that of the default ABI.
|
|
if ![file exists $baseline_file] {
|
|
set baseline_file [file join $baseline_dir "baseline_symbols.txt"]
|
|
}
|
|
if ![file exists $baseline_file] {
|
|
gcc_parallel_test_enable 1
|
|
return
|
|
}
|
|
send_log "Checking $lib against $baseline_file\n"
|
|
|
|
# Figure out what symbols are defined by the active build of the library.
|
|
remote_exec "build" "$blddir/scripts/extract_symvers" \
|
|
[list $lib "current_symbols.txt"]
|
|
|
|
# Build the abi_check program.
|
|
if { [v3_target_compile "$srcdir/util/testsuite_abi_check.cc" "abi_check" \
|
|
"executable" [list "additional_flags=-w"]] != "" } {
|
|
error "could not compile testsuite_abi_check.cc"
|
|
}
|
|
|
|
remote_download "target" $baseline_file "baseline_symbols.txt"
|
|
remote_download "target" "current_symbols.txt" "current_symbols.txt"
|
|
set result [${tool}_load "./abi_check" \
|
|
[list "--check-verbose" "current_symbols.txt" \
|
|
"baseline_symbols.txt"]]
|
|
[lindex $result 0] "libstdc++-abi/abi_check"
|
|
|
|
gcc_parallel_test_enable 1
|