+2019-05-20 Thomas Rodgers <trodgers@redhat.com>
+
+ * testsuite/lib/libstdc++.exp (check_effective_target_tbb-backend):
+ Add check for Thread Building Blocks 2018 or later.
+
2019-05-20 Jonathan Wakely <jwakely@redhat.com>
* testsuite/experimental/names.cc: Only include Networking TS headers
# Return 1 if tbb parallel backend is available
proc check_effective_target_tbb-backend { } {
- global cxxflags
-
- # Set up and preprocess a C++ test program that depends
- # on tbb
- set src tbb_backend[pid].cc
-
- set f [open $src "w"]
- puts $f "#include <tbb/tbb.h>"
- close $f
- set lines [v3_target_compile $src /dev/null preprocess ""]
- file delete $src
-
- if [string match "" $lines] {
- # No error message, preprocessing succeeded.
- verbose "check_v3_tbb-backend: `1'" 2
- return 1
- }
- verbose "check_v3_tbb-backend: `0'" 2
- return 0
+ global cxxflags
+
+ # Set up and preprocess a C++ test program that depends
+ # on tbb
+ set src tbb_backend[pid].cc
+
+ set f [open $src "w"]
+ puts $f "#include <tbb/tbb.h>"
+ puts $f "#if TBB_INTERFACE_VERSION < 10000"
+ puts $f "# error Intel(R) Threading Building Blocks 2018 is required; older versions are not supported."
+ puts $f "#endif"
+ close $f
+
+ set lines [v3_target_compile $src /dev/null preprocess ""]
+ file delete $src
+
+ if [string match "" $lines] {
+ # No error message, preprocessing succeeded.
+ verbose "check_v3_tbb-backend: `1'" 2
+ return 1
+ }
+ verbose "check_v3_tbb-backend: `0'" 2
+ return 0
}
set additional_prunes ""