-
Notifications
You must be signed in to change notification settings - Fork 207
[WIP] Invoke the Swift frontend to prescan for dependencies. #47
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
Closed
Conversation
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
Add a new flag -driver-prebuild-module-dependencies to instruct the driver to have the Swift frontend prescan for dependencies, which will allow the driver to explicitly schedule builds for both Swift and C modules, eliminating the need for the frontend to rebuild those modules when it tries to import them. This allows for an overall more coordinated build. At present, this WIP invokes the Swift frontend and then parses the JSON before dumping out the dependency graph, so it's not actually useful for anything.
This utilizes the fast dependency scanning work in the Swift compiler itself (swiftlang/swift#28515), which is also a work in progress. |
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 18, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Compute the order in which dependent modules should be built. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 18, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Compute the order in which dependent modules should be built. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 18, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Compute the order in which dependent modules should be built. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 18, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Compute the order in which dependent modules should be built. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 19, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Compute the order in which dependent modules should be built. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 20, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Compute the order in which dependent modules should be built. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 20, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 20, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 20, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 21, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
artemcm
added a commit
to artemcm/swift-driver
that referenced
this pull request
May 21, 2020
This PR resurrects swiftlang#47 and builds on top of it. Adds new flag -driver-print-module-dependencies-jobs to instruct the driver to scan for dependencies and generate build jobs for each dependent Swift or C module. At present, this WIP does the following: - Invoke the Swift frontend Fast Dependency Scanner to prescan for dependencies. - Construct a Module Dependency Graph from the dependency scanner's JSON output. - Generate and print build jbos for each dependent module. Next Steps: Actually have the driver schedule and execute the dependent module build jobs ahead of time, eliminating the need to re-build those modules when it tries to import them.
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.
Add a new flag
-driver-prebuild-module-dependencies
to instruct the driverto have the Swift frontend prescan for dependencies, which will allow the
driver to explicitly schedule builds for both Swift and C modules,
eliminating the need for the frontend to rebuild those modules when it
tries to import them. This allows for an overall more coordinated
build.
At present, this WIP invokes the Swift frontend and then parses the
JSON before dumping out the dependency graph, so it's not actually
useful for anything.