CFamily Analysis Cache Questions

Hello @Sam_Anthonisz,

You are right. This is one reason for cache entry invalidation. Another reason is change in the compilation command. You can think of it this way: if the compiler thinks that a source file should be recompiled then it is a cache miss.

The main branch updates the cache and it is the one that is used. PR doesn’t update the cache. there is one entry per source file and it comes from the latest analysis of the main branch.

No, because the cache isn’t updated from PR.

This doesn’t take care of the case where multiple PR are running in parallel. Currently, the default cache is simple and covers simple cases (easy win).

For more complicated cases, you can control CFamily cache by using explicitly the filesystem cache.
This way you can decide when to update the cache in a way that is tailored to your workflow. Also, You can have multiple filesystem caches (a cache per PR).

I hope it is clearer now!

Thanks,