Skip to content

Commit

Permalink
Fix Jenkins CI (#1038)
Browse files Browse the repository at this point in the history
Disable for now the HIP CI since the runner is having problems
  • Loading branch information
sethrj committed Dec 1, 2023
1 parent 9cc4998 commit 1d646fb
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 43 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/build-full.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,11 +105,9 @@ jobs:
- name: Build examples
# TODO: asan needs -fsanitize=address
# TODO: rocm+ndebug fails to propagate HIP library link
# TODO: logger gets initialized in SimpleOffload::Build before run manager
if: >-
${{ matrix.special != 'asan'
&& !(matrix.image == 'centos-rocm' && matrix.buildtype == 'ndebug')
&& !(matrix.geometry == 'vecgeom' && matrix.buildtype != 'ndebug')
}}
run: |
. /etc/profile
Expand Down
35 changes: 1 addition & 34 deletions .jenkins
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
pipeline {
options {
disableConcurrentBuilds(abortPrevious: true)
newContainerPerStage()
}
triggers {
issueCommentTrigger('.*do: test')
Expand All @@ -9,40 +10,6 @@ pipeline {
stages {
stage('Build') {
parallel {
stage('rocm-ndebug-orange') {
agent {
docker {
image 'celeritas/ci-centos7-rocm5:2022-12-14.2'
label 'AMD_Radeon_Instinct_MI100 && rocm-docker'
args '--device=/dev/kfd --device=/dev/dri --security-opt seccomp=unconfined'
}
}
steps {
sh 'entrypoint-shell ./scripts/ci/run-ci.sh centos-rocm ndebug-orange'
}
post {
always {
xunit reduceLog: false, tools:[CTest(deleteOutputFiles: true, failIfNotNew: true, pattern: 'build/Testing/**/*.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
}
}
}
stage('rocm-ndebug-orange-float') {
agent {
docker {
image 'celeritas/ci-centos7-rocm5:2022-12-14.2'
label 'AMD_Radeon_Instinct_MI100 && rocm-docker'
args '--device=/dev/kfd --device=/dev/dri --security-opt seccomp=unconfined'
}
}
steps {
sh 'entrypoint-shell ./scripts/ci/run-ci.sh centos-rocm ndebug-orange-float'
}
post {
always {
xunit reduceLog: false, tools:[CTest(deleteOutputFiles: true, failIfNotNew: true, pattern: 'build/Testing/**/*.xml', skipNoTestFiles: false, stopProcessingIfError: true)]
}
}
}
stage('cuda-debug-orange') {
agent {
docker {
Expand Down
21 changes: 18 additions & 3 deletions scripts/ci/run-ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ if [ -z "${CELER_SOURCE_DIR}" ]; then
fi
cd "${CELER_SOURCE_DIR}"
CELER_SOURCE_DIR=$(pwd)
ln -fs scripts/cmake-presets/ci-${OS}.json CMakeUserPresets.json

# Source environment script if necessary
_ENV_SCRIPT="scripts/env/ci-${OS}.sh"
Expand All @@ -22,6 +21,14 @@ fi

# Fetch tags for version provenance
git fetch --tags

# Clean older builds from jenkins *BEFORE* setting up presets
git clean -fxd
# Stale tmp files?
rm -rf /tmp/ompi.*

# Link preset script
ln -fs scripts/cmake-presets/ci-${OS}.json CMakeUserPresets.json
# Configure
cmake --preset=${CMAKE_PRESET}
# Build and (optionally) install
Expand All @@ -32,7 +39,7 @@ export CELER_TEST_STRICT=1

# Run tests
cd build
ctest \
ctest -T Test \
-j16 --timeout 180 \
--no-compress-output --output-on-failure \
--test-output-size-passed=65536 --test-output-size-failed=1048576 \
Expand All @@ -46,8 +53,16 @@ test -x "${CELER_SOURCE_DIR}/install/bin/celer-sim"
test -x "${CELER_SOURCE_DIR}/install/bin/celer-g4"
"${CELER_SOURCE_DIR}/install/bin/celer-sim" --version


# Test examples against installed celeritas
export CMAKE_PRESET
export CELER_SOURCE_DIR
exec ${CELER_SOURCE_DIR}/scripts/ci/test-examples.sh
case "${CMAKE_PRESET}" in
*-vecgeom*)
# VecGeom is in use: ubuntu flags are too strict for it
export LDFLAGS=-Wl,--no-as-needed
;;
esac

# Test examples against installed celeritas
exec ${CELER_SOURCE_DIR}/scripts/ci/test-examples.sh
7 changes: 3 additions & 4 deletions src/celeritas/ext/GeantUtils.cc
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ void disable_geant_signal_handler()
* G4RunManager::GetNumberOfThreads isn't virtual before Geant4 v10.7.0 so we
* need to explicitly dynamic cast to G4MTRunManager to get the number of
* threads.
*
* In tasking mode, the result may be zero!
*/
int get_geant_num_threads(G4RunManager const& runman)
{
Expand All @@ -58,10 +60,7 @@ int get_geant_num_threads(G4RunManager const& runman)
result = runman_mt->GetNumberOfThreads();
}
#endif
// TODO: even if run manager exists, it might not be initialized, so the
// result might be nonpositive. See debug-vecgeom 'minimal' example
// failure.
CELER_ENSURE(result > 0);
CELER_ENSURE(result >= 0);
return result;
}

Expand Down

0 comments on commit 1d646fb

Please sign in to comment.