-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Place build.db under the scratch directory #7471
Merged
kateinoigakukun
merged 3 commits into
apple:main
from
kateinoigakukun:yt/place-build-db-under-scratch-dir
May 29, 2024
Merged
Place build.db under the scratch directory #7471
kateinoigakukun
merged 3 commits into
apple:main
from
kateinoigakukun:yt/place-build-db-under-scratch-dir
May 29, 2024
+154
−33
Conversation
This file contains 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
@swift-ci test |
kateinoigakukun
requested review from
bnbarham,
MaxDesiatov and
tomerd
as code owners
April 22, 2024 15:45
MaxDesiatov
added
enhancement
build system
Changes to interactions with build systems
labels
Apr 22, 2024
kateinoigakukun
force-pushed
the
yt/place-build-db-under-scratch-dir
branch
from
May 27, 2024 11:00
2ec6fb1
to
010745d
Compare
@swift-ci test |
The build database should be shared between different triple builds to re-generate the build manifest correctly. Also this change splits llbuild target names for each triple to avoid cache invalidation when switching triple.
kateinoigakukun
force-pushed
the
yt/place-build-db-under-scratch-dir
branch
from
May 27, 2024 11:21
010745d
to
6be1d40
Compare
@swift-ci test |
@swift-ci test windows |
xedin
reviewed
May 27, 2024
xedin
reviewed
May 27, 2024
This change is to make the target names of llbuild targets unique by target triple so that switching triples will not invalidate target artifact cache.
@swift-ci test |
@swift-ci test Windows |
domciiiiix
approved these changes
May 28, 2024
xedin
approved these changes
May 28, 2024
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.
LGTM, thank you! I started a source compatibility build with these changes @ apple/swift#73908
Ok, source compat tests passed. At least this change does not break initial clean build 😌 |
xedin
pushed a commit
that referenced
this pull request
Jun 7, 2024
The build database should be shared between different triple builds to re-generate the build manifest correctly. With the current implementation, the following build command sequence fails: ``` $ swift build --experimental-swift-sdk wasm32-unknown-wasi $ swift build $ swift build --experimental-swift-sdk wasm32-unknown-wasi $ swift build $ swift build --experimental-swift-sdk wasm32-unknown-wasi ``` This changes the llbuild build database to be placed under `.build/build.db` instead of `.build/<product triple>/build.db`. Also this change splits llbuild target names for each triple to avoid cache invalidation when switching triple. `build.db` will be shared across product target triples, and SwiftPM will keep consistent cache state when switching triples. (cherry picked from commit e9399c2)
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.
Motivation:
The build database should be shared between different triple builds to re-generate the build manifest correctly.
With the current implementation, the following build command sequence fails:
Modifications:
This changes the llbuild build database to be placed under
.build/build.db
instead of.build/<product triple>/build.db
.Also this change splits llbuild target names for each triple to avoid cache invalidation when switching triple.
Result:
build.db
will be shared across product target triples, and SwiftPM will keep consistent cache state when switching triples.