mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-09-21 09:05:10 -07:00
ccache stats
This commit is contained in:
parent
ae37762ee1
commit
9f4af75f09
1 changed files with 12 additions and 14 deletions
|
|
@ -164,16 +164,6 @@ fi
|
||||||
# Add cmake --build flags
|
# Add cmake --build flags
|
||||||
buildflags=(--config "$BUILDTYPE")
|
buildflags=(--config "$BUILDTYPE")
|
||||||
|
|
||||||
function ccachestatsverbose() {
|
|
||||||
# note, verbose only works on newer ccache, discard the error
|
|
||||||
local got
|
|
||||||
if got="$(ccache --show-stats --verbose 2>/dev/null)"; then
|
|
||||||
echo "$got"
|
|
||||||
else
|
|
||||||
ccache --show-stats
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# Compile
|
# Compile
|
||||||
if [[ $RUNNER_OS == macOS ]]; then
|
if [[ $RUNNER_OS == macOS ]]; then
|
||||||
# QTDIR is needed for macOS since we actually only use the cached thin Qt binaries instead of the install-qt-action,
|
# QTDIR is needed for macOS since we actually only use the cached thin Qt binaries instead of the install-qt-action,
|
||||||
|
|
@ -258,8 +248,14 @@ elif [[ $RUNNER_OS == Windows ]]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ $USE_CCACHE ]]; then
|
if [[ $USE_CCACHE ]]; then
|
||||||
echo "::group::Show ccache stats"
|
echo "::group::Clear ccache stats"
|
||||||
ccachestatsverbose
|
# https://ccache.dev/manual/4.13.6.html#_command_line_options
|
||||||
|
ccache --version
|
||||||
|
ccache --show-config
|
||||||
|
ccache --show-stats # remove again
|
||||||
|
ccache --show-log-stats # helpful?
|
||||||
|
ccache --zero-stats # zero former cache statistics (but not the configuration options)
|
||||||
|
ccache --show-stats # helpful?
|
||||||
echo "::endgroup::"
|
echo "::endgroup::"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
@ -280,8 +276,10 @@ if [[ $USE_CCACHE ]]; then
|
||||||
ccache --evict-older-than "$CCACHE_EVICTION_AGE"
|
ccache --evict-older-than "$CCACHE_EVICTION_AGE"
|
||||||
echo "::endgroup::"
|
echo "::endgroup::"
|
||||||
fi
|
fi
|
||||||
echo "::group::Show ccache stats again"
|
echo "::group::Show ccache stats"
|
||||||
ccachestatsverbose
|
ccache --verify # remove again
|
||||||
|
ccache --show-stats --verbose # too verbose?
|
||||||
|
ccache --show-compression # helpful?
|
||||||
echo "::endgroup::"
|
echo "::endgroup::"
|
||||||
elif [[ $CCACHE_EVICTION_AGE ]]; then
|
elif [[ $CCACHE_EVICTION_AGE ]]; then
|
||||||
echo "::error file=$0::ccache eviction is enabled while ccache is disabled!"
|
echo "::error file=$0::ccache eviction is enabled while ccache is disabled!"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue