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

Use ccache for speed up Build with S2E CI #522

Draft
wants to merge 5 commits into
base: feature/use-ninja-on-build-ci
Choose a base branch
from
Draft
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
19 changes: 18 additions & 1 deletion .github/workflows/build_with_s2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,23 @@ jobs:
with:
arch: amd64_x86

- name: Install ccache
id: install-ccache
shell: bash
run: |
choco install ccache
ccache --show-stats --verbose
CACHE_DIR=$(ccache -k cache_dir)
echo "cache_dir=${CACHE_DIR}" >> "$GITHUB_OUTPUT"

- name: cache by ccache
uses: actions/cache@v3
sksat marked this conversation as resolved.
Show resolved Hide resolved
with:
path: |
${{ steps.install-ccache.outputs.cache_dir }}
key: ccache-${{ runner.os }}-${{ hashFiles('./c2a-core/**', './s2e-user/**', './s2e-core/**') }}
restore-keys: ccache-${{ runner.os }}-

- name: cache extlib
id: cache-extlib
uses: actions/cache@v3
Expand Down Expand Up @@ -95,5 +112,5 @@ jobs:
run: |
cl.exe
cmake --version
cmake -A Win32 -DCMAKE_CONFIGURATION_TYPES:STRING="Debug" -DEXT_LIB_DIR=../s2e-core/ExtLibraries -DFLIGHT_SW_DIR=../c2a-core -DC2A_NAME=Examples/${{ matrix.example }} -DUSE_C2A=ON
cmake -A Win32 -DCMAKE_CXX_COMPILER_LAUNCHER=ccache -DCMAKE_CONFIGURATION_TYPES:STRING="Debug" -DEXT_LIB_DIR=../s2e-core/ExtLibraries -DFLIGHT_SW_DIR=../c2a-core -DC2A_NAME=Examples/${{ matrix.example }} -DUSE_C2A=ON
cmake --build . --clean-first