Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Submit CTest results for compile-only tests to elastic #952

Merged
merged 2 commits into from
Jan 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 28 additions & 4 deletions .gitlab/docker/Dockerfile.spack_build
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,31 @@ RUN spack spec -lI $spack_spec
RUN spack build-env $spack_spec -- bash -c "cmake -B${BUILD_DIR} ${SOURCE_DIR} \
$CMAKE_COMMON_FLAGS $CMAKE_FLAGS && cmake --build ${BUILD_DIR} --target all tests examples"

# Run compile only tests and tests.unit.build
RUN spack build-env $spack_spec -- bash -c "ctest --label-regex COMPILE_ONLY \
--test-dir ${BUILD_DIR} -j${NUM_PROCS} --timeout 30 --output-on-failure --no-compress-output \
-R tests --no-tests=error"
# Run compile only tests and tests.unit.build, submit ctest metrics to elastic
ARG ARCH
ARG BUILD_TYPE
ARG CI_COMMIT_AUTHOR
ARG CI_COMMIT_BRANCH
ARG CI_COMMIT_DESCRIPTION
ARG CI_COMMIT_MESSAGE
ARG CI_COMMIT_SHA
ARG CI_COMMIT_SHORT_SHA
ARG CI_COMMIT_TIMESTAMP
ARG CI_COMMIT_TITLE
ARG COMPILER
ARG CSCS_LOGSTASH_URL
ARG SPACK_COMMIT
ARG SPACK_SPEC
RUN CTEST_XML=$PWD/ctest.xml; \
trap "${SOURCE_DIR}/.gitlab/scripts/collect_ctest_metrics.sh ${CTEST_XML}" EXIT; \
spack build-env $spack_spec -- \
bash -c "ctest \
--output-junit ${CTEST_XML} \
--label-regex COMPILE_ONLY \
--test-dir ${BUILD_DIR} \
-j${NUM_PROCS} \
--timeout 30 \
--output-on-failure \
--no-compress-output \
-R tests \
-no-tests=error"
4 changes: 1 addition & 3 deletions .gitlab/includes/clang11_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ clang11_debug_build:
extends:
- .container-builder
- .variables_clang11_config
- .build_variables_common
- .cmake_variables_common
needs:
- clang11_spack_image
Expand All @@ -56,9 +57,6 @@ clang11_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/clang12_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ clang12_debug_build:
extends:
- .container-builder
- .variables_clang12_config
- .build_variables_common
- .cmake_variables_common
needs:
- clang12_spack_image
Expand All @@ -60,9 +61,6 @@ clang12_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/clang13_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ clang13_debug_build:
extends:
- .container-builder
- .variables_clang13_config
- .build_variables_common
- .cmake_variables_common
needs:
- clang13_spack_image
Expand All @@ -57,9 +58,6 @@ clang13_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/clang14_cuda11_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ clang14_cuda11_debug_build:
extends:
- .container-builder
- .variables_clang14_cuda11_config
- .build_variables_common
- .cmake_variables_common
needs:
- clang14_cuda11_spack_image
Expand All @@ -59,9 +60,6 @@ clang14_cuda11_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/clang15_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ clang15_debug_build:
extends:
- .container-builder
- .variables_clang15_config
- .build_variables_common
- .cmake_variables_common
needs:
- clang15_spack_image
Expand All @@ -55,9 +56,6 @@ clang15_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/clang16_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ clang16_debug_build:
extends:
- .container-builder
- .variables_clang16_config
- .build_variables_common
- .cmake_variables_common
needs:
- clang16_spack_image
Expand All @@ -55,9 +56,6 @@ clang16_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 4 additions & 0 deletions .gitlab/includes/common_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@ variables:
-DPIKA_WITH_CHECK_MODULE_DEPENDENCIES=ON \
-DPIKA_WITH_EXAMPLES=ON -DPIKA_WITH_TESTS=ON \
-DPIKA_WITH_PARALLEL_TESTS_BIND_NONE=ON"
.build_variables_common:
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["ARCH","BASE_IMAGE","BUILD_TYPE","CI_COMMIT_AUTHOR","CI_COMMIT_BRANCH","CI_COMMIT_DESCRIPTION","CI_COMMIT_MESSAGE","CI_COMMIT_SHA","CI_COMMIT_SHORT_SHA","CI_COMMIT_TIMESTAMP","CI_COMMIT_TITLE","COMPILER","CSCS_LOGSTASH_URL","SPACK_COMMIT","SPACK_SPEC","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'

.test_common:
variables:
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/gcc11_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ gcc11_debug_build:
extends:
- .container-builder
- .variables_gcc11_config
- .build_variables_common
- .cmake_variables_common
needs:
- gcc11_spack_image
Expand All @@ -56,9 +57,6 @@ gcc11_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/gcc12_cuda12_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ gcc12_cuda12_debug_build:
extends:
- .container-builder
- .variables_gcc12_cuda12_config
- .build_variables_common
- .cmake_variables_common
needs:
- gcc12_cuda12_spack_image
Expand All @@ -59,9 +60,6 @@ gcc12_cuda12_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/gcc12_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ gcc12_debug_build:
extends:
- .container-builder
- .variables_gcc12_config
- .build_variables_common
- .cmake_variables_common
needs:
- gcc12_spack_image
Expand All @@ -55,9 +56,6 @@ gcc12_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/gcc13_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ gcc13_debug_build:
extends:
- .container-builder
- .variables_gcc13_config
- .build_variables_common
- .cmake_variables_common
needs:
- gcc13_spack_image
Expand All @@ -57,9 +58,6 @@ gcc13_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/gcc9_cuda11_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ gcc9_cuda11_debug_build:
extends:
- .container-builder
- .variables_gcc9_cuda11_config
- .build_variables_common
- .cmake_variables_common
needs:
- gcc9_cuda11_spack_image
Expand All @@ -56,9 +57,6 @@ gcc9_cuda11_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/gcc9_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ gcc9_debug_build:
extends:
- .container-builder
- .variables_gcc9_config
- .build_variables_common
- .cmake_variables_common
needs:
- gcc9_spack_image
Expand All @@ -56,9 +57,6 @@ gcc9_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down
4 changes: 1 addition & 3 deletions .gitlab/includes/hip_pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ gcc12_hip5_debug_build:
extends:
- .container-builder
- .variables_gcc12_hip5_config
- .build_variables_common
- .cmake_variables_common
needs:
- gcc12_hip5_spack_image
Expand All @@ -59,9 +60,6 @@ gcc12_hip5_debug_build:
- CONFIG_TAG=`echo $configuration | sha256sum - | head -c 16`
- export PERSIST_IMAGE_NAME=$CSCS_REGISTRY_PATH/pika-$compiler-$build_type-build:$CONFIG_TAG
- echo -e "PERSIST_IMAGE_NAME=$PERSIST_IMAGE_NAME" >> build.env
variables:
DOCKERFILE: .gitlab/docker/Dockerfile.spack_build
DOCKER_BUILD_ARGS: '["BASE_IMAGE","SOURCE_DIR","BUILD_DIR","CMAKE_COMMON_FLAGS","CMAKE_FLAGS"]'
artifacts:
reports:
dotenv: build.env
Expand Down