-
Notifications
You must be signed in to change notification settings - Fork 213
Add -sil-output-dir and -ir-output-dir driver options #1995
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
base: main
Are you sure you want to change the base?
Conversation
swiftlang/swift#84392 is the PR for the swift-frontend flags |
@swift-ci please test |
1 similar comment
@swift-ci please test |
flag: "-serialize-diagnostics-path") | ||
|
||
// Add SIL and IR outputs when explicitly requested via directory options, file maps, or -save-temps | ||
let saveTempsWithoutFileMap = parsedOptions.hasArgument(.saveTemps) && outputFileMap == nil |
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.
SwiftDriver is meant to provide some forward/backward compatibility with different swift-frontend versions. In this case where -save-temps
has been provided, can this check whether the frontend supports the -sil-output-dir
option before it it concludes that it should pass the option down? Otherwise, new driver with old swift-frontend will fail for existing users of -save-temps
.
This enables generating SIL and LLVM IR files during normal compilation using the frontend -sil-output-path and -ir-output-path flags. Supports both single-file and WMO modes with file map integration. rdar://160297898
This extends -save-temps to emit SIL and IR alongside existing temporary files. In the case where an output file map is used with -save-temps, e.g. incremental compilation, only emit the SIL and IR if it has been requested as an output in the filemap. rdar://160297896
e062312
to
8bf76e3
Compare
@swift-ci please test |
@swift-ci please test |
This enables generating SIL and LLVM IR files during normal compilation using the frontend -sil-output-path and -ir-output-path flags.
Supports both single-file and WMO modes with ile map integration.
rdar://160297898