Skip to content

Commit 0f2f85c

Browse files
authored
Merge pull request NVIDIA#1440 from allisonvacanti/suppress-icc-failures
Suppress scan failures in icc gpuCI.
2 parents 503806a + e6ac76a commit 0f2f85c

1 file changed

Lines changed: 28 additions & 5 deletions

File tree

ci/common/build.bash

Lines changed: 28 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,18 @@ function echo_and_run_timed {
4141
time ${@:2}
4242
}
4343

44+
# join_delimit <delimiter> [value [value [...]]]
45+
# Combine all values into a single string, separating each by a single character
46+
# delimiter. Eg:
47+
# foo=(bar baz kramble)
48+
# joined_foo=$(join_delimit "|" "${foo[@]}")
49+
# echo joined_foo # "bar|baz|kramble"
50+
function join_delimit {
51+
local IFS="${1}"
52+
shift
53+
echo "${*}"
54+
}
55+
4456
################################################################################
4557
# VARIABLES - Set up bash and environmental variables.
4658
################################################################################
@@ -178,15 +190,26 @@ fi
178190

179191
append CTEST_FLAGS "--output-on-failure"
180192

193+
CTEST_EXCLUSION_REGEXES=()
194+
181195
if [[ "${BUILD_TYPE}" == "cpu" ]]; then
182-
append CTEST_FLAGS "-E ^cub|^thrust.*cuda"
196+
CTEST_EXCLUSION_REGEXES+=("^cub" "^thrust.*cuda")
197+
fi
198+
199+
if [[ "${CXX_TYPE}" == "icc" ]]; then
200+
# The free version of icpc used in gpuCI seems to have a compiler bug that
201+
# causes a scan test to produce incorrect output.
202+
CTEST_EXCLUSION_REGEXES+=("thrust\\.cpp\\.tbb\\.cpp..\\.test\\.scan$")
203+
fi
204+
205+
if [[ -n "${CTEST_EXCLUSION_REGEXES[@]}" ]]; then
206+
CTEST_EXCLUSION_REGEX=$(join_delimit "|" "${CTEST_EXCLUSION_REGEXES[@]}")
207+
append CTEST_FLAGS "-E ${CTEST_EXCLUSION_REGEX}"
183208
fi
184209

185210
if [[ -n "${@}" ]]; then
186-
for arg in "${@}"
187-
do
188-
append CTEST_FLAGS "-R ^${arg}$"
189-
done
211+
CTEST_INCLUSION_REGEX=$(join_delimit "|" "${@}")
212+
append CTEST_FLAGS "-R ${CTEST_INCLUSION_REGEX[@]}"
190213
fi
191214

192215
# Export variables so they'll show up in the logs when we report the environment.

0 commit comments

Comments
 (0)