-
Notifications
You must be signed in to change notification settings - Fork 566
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Disable preprocessor cache with -MD and friends #2195
Conversation
Also hook up too_hard_for_preprocessor_cache_mode, because it wasn't.
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2195 +/- ##
===========================================
+ Coverage 30.91% 42.55% +11.64%
===========================================
Files 53 53
Lines 20112 20328 +216
Branches 9755 9684 -71
===========================================
+ Hits 6217 8650 +2433
- Misses 7922 7976 +54
+ Partials 5973 3702 -2271 ☔ View full report in Codecov by Sentry. |
preprocessor_cache_mode_config, | ||
)? | ||
} else { | ||
None |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you please add a log entry here ? might be hard to debug otherwise for people who might want to use it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would need to mention what specifically makes it too hard for the preprocessor cache, though, otherwise the log is not going to be useful (like cannot_cache!
). Maybe more of a followup?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done in #2197. I'll rebase this one when that one is merged.
sccache has two modes: - normal mode - preprocessor cache mode (aka direct mode in ccache) In the former case, the preprocessor is invoked and creates the dep file itself. Whatever sccache does after that is going to overwrite a fresh file with potentially wrong information, since the cache key is not indexed on the elements that would affect the contents of the dep file, resulting in issue mozilla#2321. In the latter case, sccache currently doesn't handle the situation appropriately (issue mozilla#2194), which is why preprocessor cache mode is automatically disabled when the dependency flags are on the command line (mozilla#2195). Which also means we fallback to the case above.
sccache has two modes: - normal mode - preprocessor cache mode (aka direct mode in ccache) In the former case, the preprocessor is invoked and creates the dep file itself. Whatever sccache does after that is going to overwrite a fresh file with potentially wrong information, since the cache key is not indexed on the elements that would affect the contents of the dep file, resulting in issue mozilla#2321. In the latter case, sccache currently doesn't handle the situation appropriately (issue mozilla#2194), which is why preprocessor cache mode is automatically disabled when the dependency flags are on the command line (mozilla#2195). Which also means we fallback to the case above.
sccache has two modes: - normal mode - preprocessor cache mode (aka direct mode in ccache) In the former case, the preprocessor is invoked and creates the dep file itself. Whatever sccache does after that is going to overwrite a fresh file with potentially wrong information, since the cache key is not indexed on the elements that would affect the contents of the dep file, resulting in issue #2321. In the latter case, sccache currently doesn't handle the situation appropriately (issue #2194), which is why preprocessor cache mode is automatically disabled when the dependency flags are on the command line (#2195). Which also means we fallback to the case above.
Also hook up too_hard_for_preprocessor_cache_mode, because it wasn't.