4 ms·
Every developer I've talked to has had the same experience with compilation caches as me: they're great. Until one day you waste a couple hours of your time cha
by orlp 1y ago
Every developer I've talked to has had the same experience with compilation caches as me: they're great. Until one day you waste a couple hours of your time chasing a bug caused by a stale cache. From that point on your trust is shattered, and there's always a little voice in the back of your head when debugging something which says "could this be caused by a stale cache?". And you turn it off again for peace of mind.
- johnisgood 1y agoWhat kind of compilation caches, something like ccache[1]? Do you use it, or would you? It is for C and C++. Check out the features, they are pretty neat, IMO! The documentation may come in handy: 1. https://ccache.dev/manual/4.11.3.html#_how_ccache_works https://ccache.dev/manual/4.11.3.html#_how_ccache_works 2. https://ccache.dev/manual/4.11.3.html#_cache_statistics https://ccache.dev/manual/4.11.3.html#_cache_statistics and so forth. [1] https://ccache.dev https://ccache.dev (ccache - a fast C/C++ compiler cache)
- Y_Y 1y agoThere are three hard problems in computer science, cache invalidation and naming things.
- aengelke 1y agoOr rather: There are 2 hard problems in computer science: cache invalidation, naming things, and off-by-1 errors. (source: https://martinfowler.com/bliki/TwoHardThings.html https://martinfowler.com/bliki/TwoHardThings.html)
- ACCount37 1y agoDon't you just do "flush the cache, rebuild" at the first suspicion? If the bug abruptly goes away, it was stale cache. It usually doesn't.