Skip to content

[Caching] Add fast swift instance setup for cache replay #73265

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

Merged
merged 1 commit into from
Apr 26, 2024

Conversation

cachemeifyoucan
Copy link
Contributor

Add a fast path to create swift CompilerInstance when it is only used to replay output when there is a cache hit. The normal setup function is very expensive to call, especially in cache mode to setup inputs, and it needs to be called once per input file from libSwiftScan API due to the current caching granularity.

The fast path will only construct the part that is needed for output replay, including the CAS, the output backend and caching diagnostic processor.

rdar://127062609

Add a fast path to create swift CompilerInstance when it is only used to
replay output when there is a cache hit. The normal `setup` function is
very expensive to call, especially in cache mode to setup inputs, and it
needs to be called once per input file from libSwiftScan API due to the
current caching granularity.

The fast path will only construct the part that is needed for output
replay, including the CAS, the output backend and caching diagnostic
processor.

rdar://127062609
@cachemeifyoucan
Copy link
Contributor Author

@swift-ci please smoke test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants