From: Joel Rosdahl Date: Mon, 20 Mar 2023 19:42:14 +0000 (+0100) Subject: fix: Disable the inode cache by default X-Git-Tag: v4.7.5^0 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9b1033f3ae534e5aad02c10f663b589b8f28c026;p=thirdparty%2Fccache.git fix: Disable the inode cache by default There have reports of ccache processes hanging on futex calls related to the inode cache. (The inode cache synchronization mechanism has been reworked not to use pthread mutexes in ccache 4.8, so the inode cache is enabled by default in 4.8 and newer.) --- diff --git a/LICENSE.adoc b/LICENSE.adoc index b863cecda..0f97424bd 100644 --- a/LICENSE.adoc +++ b/LICENSE.adoc @@ -35,7 +35,7 @@ The copyright for ccache as a whole is as follows: ---- Copyright (C) 2002-2007 Andrew Tridgell -Copyright (C) 2009-2022 Joel Rosdahl and other contributors +Copyright (C) 2009-2023 Joel Rosdahl and other contributors ---- diff --git a/doc/MANUAL.adoc b/doc/MANUAL.adoc index 48328fa8e..86c9b19b3 100644 --- a/doc/MANUAL.adoc +++ b/doc/MANUAL.adoc @@ -756,7 +756,7 @@ might be incorrect. If true, ccache will cache source file hashes based on device, inode and timestamps. This reduces the time spent on hashing include files since the - result can be resused between compilations. The default is true. The feature + result can be resused between compilations. The default is false. The feature requires <> to be located on a local filesystem of a supported type. + diff --git a/doc/NEWS.adoc b/doc/NEWS.adoc index 724990408..d81460276 100644 --- a/doc/NEWS.adoc +++ b/doc/NEWS.adoc @@ -1,5 +1,16 @@ = Ccache news +== Ccache 4.7.5 + +Release date: 2023-03-20 + +=== Bug fixes + +- Disabled the inode cache by default again since there have reports of ccache + processes hanging on futex calls related to the inode cache. + + [small]#_[contributed by Joel Rosdahl]_# + + == Ccache 4.7.4 Release date: 2022-11-21 diff --git a/src/Config.hpp b/src/Config.hpp index b75ff43c4..cc5d27172 100644 --- a/src/Config.hpp +++ b/src/Config.hpp @@ -1,4 +1,4 @@ -// Copyright (C) 2019-2022 Joel Rosdahl and other contributors +// Copyright (C) 2019-2023 Joel Rosdahl and other contributors // // See doc/AUTHORS.adoc for a complete list of contributors. // @@ -181,7 +181,7 @@ private: bool m_hash_dir = true; std::string m_ignore_headers_in_manifest; std::string m_ignore_options; - bool m_inode_cache = true; + bool m_inode_cache = false; bool m_keep_comments_cpp = false; double m_limit_multiple = 0.8; std::string m_log_file; diff --git a/src/core/mainoptions.cpp b/src/core/mainoptions.cpp index 2283162fa..37cc4b995 100644 --- a/src/core/mainoptions.cpp +++ b/src/core/mainoptions.cpp @@ -1,4 +1,4 @@ -// Copyright (C) 2021-2022 Joel Rosdahl and other contributors +// Copyright (C) 2021-2023 Joel Rosdahl and other contributors // // See doc/AUTHORS.adoc for a complete list of contributors. // @@ -70,7 +70,7 @@ constexpr const char VERSION_TEXT[] = Features: {2} Copyright (C) 2002-2007 Andrew Tridgell -Copyright (C) 2009-2022 Joel Rosdahl and other contributors +Copyright (C) 2009-2023 Joel Rosdahl and other contributors See for a complete list of contributors. diff --git a/test/suites/inode_cache.bash b/test/suites/inode_cache.bash index 830ef8c75..48d7d7127 100644 --- a/test/suites/inode_cache.bash +++ b/test/suites/inode_cache.bash @@ -1,4 +1,6 @@ SUITE_inode_cache_PROBE() { + export CCACHE_INODECACHE=1 + if $HOST_OS_WINDOWS; then echo "inode cache not available on Windows" return @@ -16,6 +18,7 @@ SUITE_inode_cache_PROBE() { } SUITE_inode_cache_SETUP() { + export CCACHE_INODECACHE=1 export CCACHE_DEBUG=1 unset CCACHE_NODIRECT export CCACHE_TEMPDIR="${CCACHE_DIR}/tmp" # isolate inode cache file