Skip to content

Commit

Permalink
ci: Add ccache stats output (#1489)
Browse files Browse the repository at this point in the history
This should help diagnose CI job performance.
  • Loading branch information
paulgessinger committed Sep 6, 2022
1 parent f5d312f commit f3ea581
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .github/workflows/analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ jobs:
- name: Configure
run: >
ccache -z &&
cmake -B build -S .
-GNinja
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
Expand All @@ -47,6 +48,8 @@ jobs:
-DACTS_LOG_FAILURE_THRESHOLD=WARNING
- name: Build
run: cmake --build build
- name: ccache stats
run: ccache -s
- name: Unit tests
run: cmake --build build --target test
- name: Remove .o files
Expand Down
30 changes: 29 additions & 1 deletion .github/workflows/builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ jobs:
# versions
run: >
${SETUP} &&
ccache -z &&
cmake -B build -S .
-GNinja
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
Expand Down Expand Up @@ -83,6 +84,9 @@ jobs:
- name: Build
run: ${SETUP} && cmake --build build

- name: ccache stats
run: ${SETUP} && ccache -s

- name: Unit tests
run: ${SETUP} && cmake --build build --target test

Expand Down Expand Up @@ -142,6 +146,7 @@ jobs:
# dd4hep CMake configuration that gets triggered on recent CMake
# versions
run: >
ccache -z &&
cmake -B build -S .
-GNinja
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
Expand All @@ -160,6 +165,9 @@ jobs:
- name: Build
run: cmake --build build

- name: ccache stats
run: ccache -s

- name: Unit tests
run: cmake --build build --target test

Expand Down Expand Up @@ -309,6 +317,7 @@ jobs:
# dd4hep CMake configuration that gets triggered on recent CMake
# versions
run: >
ccache -z &&
cmake -B build -S .
-GNinja
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
Expand All @@ -327,6 +336,9 @@ jobs:
- name: Build
run: cmake --build build

- name: ccache stats
run: ccache -s

- name: Unit tests
run: cmake --build build --target test

Expand Down Expand Up @@ -376,6 +388,7 @@ jobs:
# Install tbb-devel also to build the examples
run: >
dnf -y install ninja-build tbb-devel ccache
&& ln -s $(find / -type f -name 'ccache') /usr/local/bin/ccache
- name: Cache build
uses: actions/cache@v3
Expand All @@ -387,9 +400,10 @@ jobs:
- name: Configure
run: >
ccache -z &&
cmake -B build -S .
-GNinja
-DCMAKE_CXX_COMPILER_LAUNCHER=$(find / -type f -name "ccache")
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
-DCMAKE_BUILD_TYPE=Release
-DCMAKE_CXX_FLAGS=-Werror
-DCMAKE_INSTALL_PREFIX="${INSTALL_DIR}"
Expand All @@ -404,6 +418,8 @@ jobs:
run: ${SETUP} && ( cmake --build build || cmake --build build )
# The above line is required as a sort of retry mechanism. Without it,
# the build fails for technical reasons.
- name: ccache stats
run: ccache -s
- name: Unit tests
run: ${SETUP} && ${PRELOAD} && cmake --build build --target test
- name: Integration tests
Expand Down Expand Up @@ -479,6 +495,7 @@ jobs:
# dd4hep CMake configuration that gets triggered on recent CMake
# versions such as the one installed via homebrew
run: >
ccache -z &&
cmake -B build -S .
-GNinja
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
Expand All @@ -494,6 +511,8 @@ jobs:
-DACTS_BUILD_EXAMPLES_EDM4HEP=ON
- name: Build
run: cmake --build build
- name: ccache stats
run: ccache -s
- name: Unit tests
run: cmake --build build --target test
- name: Integration tests
Expand Down Expand Up @@ -533,6 +552,7 @@ jobs:
- name: Configure
run: >
ccache -z &&
cmake -B build -S .
-GNinja
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
Expand All @@ -543,6 +563,8 @@ jobs:
-DACTS_BUILD_UNITTESTS=ON
- name: Build
run: cmake --build build
- name: ccache stats
run: ccache -s

exatrkx:
runs-on: ubuntu-latest
Expand All @@ -560,6 +582,7 @@ jobs:
- name: Configure
run: >
ccache -z &&
cmake -B build -S .
-GNinja
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
Expand All @@ -570,6 +593,8 @@ jobs:
-DACTS_BUILD_EXAMPLES_PYTHON_BINDINGS=ON
- name: Build
run: cmake --build build
- name: ccache stats
run: ccache -s

sycl:
runs-on: ubuntu-latest
Expand All @@ -591,6 +616,7 @@ jobs:
- name: Configure
run: >
source /opt/intel/oneapi/setvars.sh
&& ccache -z
&& cmake -B build -S .
-GNinja
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache
Expand All @@ -604,4 +630,6 @@ jobs:
run: >
source /opt/intel/oneapi/setvars.sh
&& cmake --build build
- name: ccache stats
run: ccache -s

0 comments on commit f3ea581

Please sign in to comment.