Merged
Conversation
We now pass -P to the preprocessor, which inhibits the generation
of linemarkers. This has two positive side effects:
1. Absolute file paths and file names are excluded from the
preprocessor output, which makes the hash independent of
the location of the source and build directories.
2. The preprocessing step is slightly faster (in one case it
was 20% faster) and the preprocessor output is smaller (in
the aforementioned case the output was 23% smaller) which
should translate into faster hashing too.
Contributor
Author
|
According to my testing, this PR fixes #207 for GCC (and hopefully Clang too). |
Contributor
|
Great find! Since we no longer compile from the preprocessor output this shouldn't harm anything and it fixes this longstanding issue in a simple way. I think there still might be some quirks about file paths in debug info, but we can sort that out later. It turns out MSVC does have an equivalent option: |
Contributor
Author
|
Sweet! This makes sccache much more attractive for our slightly heterogeneous machine park. |
Contributor
|
We punted and just do all our CI builds in the same Docker image in the same paths. :) |
tottoto
pushed a commit
to tottoto/sccache
that referenced
this pull request
Feb 6, 2026
BREAKING CHANGE: Add new `Decoder/Encoder` traits and use `EncodeBuf/DecodeBuf` over `BytesMut` directly.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We now pass -P to the preprocessor, which inhibits the generation
of linemarkers. This has two positive side effects:
Absolute file paths and file names are excluded from the
preprocessor output, which makes the hash independent of
the location of the source and build directories.
The preprocessing step is slightly faster (in one case it
was 20% faster) and the preprocessor output is smaller (in
the aforementioned case the output was 23% smaller) which
should translate into faster hashing too.