-
Notifications
You must be signed in to change notification settings - Fork 195
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
[Macros] Add support for wasm plugins #1582
Draft
kabiroberai
wants to merge
17
commits into
swiftlang:main
Choose a base branch
from
kabiroberai:kabir/wasm-plugins
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+104
−12
Draft
Changes from 2 commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
faa0a3a
Update Options.swift
kabiroberai d9e3c31
Pass wasm-plugin-server-path to frontend
kabiroberai 0081b2b
hasWasmPlugins
kabiroberai 018b4c2
Add test for wasm plugins
kabiroberai fb902b1
tweaks
kabiroberai 4914507
Merge branch 'main' into kabir/wasm-plugins
kabiroberai a6db182
swift-wasm-plugin-server => swift-plugin-server
kabiroberai 39f0a6e
Use -load-plugin
kabiroberai 1eb80db
Move pluginServerPath extension
kabiroberai 3e450cb
Tweaks
kabiroberai 5634596
Merge branch 'main' into kabir/wasm-plugins
kabiroberai dc640ff
Preserve order of options
kabiroberai 74e989c
formatting
kabiroberai 80ca24d
Minor renaming
kabiroberai 7b8f8f6
Merge branch 'main' into kabir/wasm-plugins
kabiroberai 4783e1d
Merge branch 'main' into kabir/wasm-plugins
kabiroberai 25482bc
Merge branch 'main' into kabir/wasm-plugins
kabiroberai File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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.
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.
I think instead this chunk of code should live in
WebAssemblyToolchain
's implementation oftoolchain.addPlatformSpecificCommonFrontendOptions
so that other platforms' command-lines don't unnecessarily end up with this flag.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.
To clarify, wasm macros can be invoked by any toolchain and so this server can also be used by any toolchain — it's independent of the target triple.
That said we could still be smarter about this and only pass along the wasm-server iff the user has also passed in a wasm macro. I avoided this initially because I didn't want the Driver to have to parse plugin load options to determine if a wasm macro was being loaded, but if cluttering up the options is a concern then it might be worth it. What do you think?
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.
Updated with a
hasWasmPlugins
check, let me know if this looks better!