-
Notifications
You must be signed in to change notification settings - Fork 638
Description
We’ve been using sccache successfully for normal compilation, but we recently started adding clang-tidy to our default build pipeline. This significantly increases CPU load because, even though the compilation step is usually cached by sccache, we still need to run the clang-tidy analysis on each file.
In theory, I could write my own caching layer for clang-tidy or use something like ctcache. However, ctcache is Python-based - which I’d prefer not to add as a dependency - and using two separate caching tools would complicate things. sccache already has robust features like statistics, cache eviction, and quotas that ctcache doesn’t seem to provide.
I understand that supporting clang-tidy is not as simple as adding another compiler backend, since it doesn’t produce build artifacts and mainly outputs to stdout.
I'm currently working on a proof of concept to explore whether clang-tidy support could fit within sccache. Before investing more time: would the project be open to a PR adding support for caching linters like clang-tidy, or is this considered outside the scope of sccache?
If it's out of scope, I’ll focus on alternative solutions.