-
Notifications
You must be signed in to change notification settings - Fork 10.6k
[DependencyScanning] Perform Clang Module By-Name Dependency Query Using a Shared Clang Compiler Instance #85555
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
Conversation
|
Note that |
|
Please test with following PR: @swift-ci please smoke test |
…and finalization.
fffde38 to
59c3895
Compare
|
Please test with following PR: @swift-ci please smoke test |
|
Please test with following PR: @swift-ci please smoke test |
|
@swift-ci please smoke test |
|
@swift-ci please test |
|
@swift-ci please test llvm |
|
@swift-ci please smoke test |
|
@swift-ci please test |
artemcm
left a comment
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.
Very cool!
|
@swift-ci please smoke test |
|
Thanks for the suggestions! The latest commit folds the initialization into a |
Conflicts: include/swift/DependencyScan/ModuleDependencyScanner.h lib/DependencyScan/ModuleDependencyScanner.cpp lib/DependencyScan/ScanDependencies.cpp
|
Please test with following PR: @swift-ci please smoke test |
|
Please test with following PR: @swift-ci please smoke test Windows |
…xt instance that does not exist. (#12029) The by-name lookup APIs are intended for Swift. swiftlang/swift#85555 teaches Swift to use it. The original intention was to invoke the finalization API explicitly. swiftlang/swift#85555 folds the finalization step into the module dependency scanner's destructor. This leads to a case where if an initialization error occurs, the CIWithContext may not be setup for some workers, and calling the finalization API is incorrect. This PR checks against the existence of the CIWithContext and then performs the finalization. rdar://136303612
This PR teaches Swift to take advantage of the new clang dependency scanning API to use a single clang compiler instance per dependency scanning worker to perform by-name queries.
rdar://136303612