-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Switch the runtime from wasmi to wasmtime + cranelift #1700
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
Changes from all commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
fc4a420
runtime: Switch to wasmtime
leoyvens cba9444
graph: unconditionally use `futures::block_on`in `block_on_allow_panic`
leoyvens 54fa314
*: Use more `anyhow::Error`
leoyvens 93dc84e
runtime: Depend on wasmtime master
leoyvens eff818b
graph: Add `CompatErr`
leoyvens cddb1e4
runtime, graphql: Address review
leoyvens ecdfb69
runtime: Use released wasmtime version
leoyvens 058ea6c
runtime: Better `i32` to/from `u32` conversion
leoyvens a42b393
runtime: Use weak references to the instance in host exports
leoyvens 8e2caf5
runtime: Use `anyhow::ensure`
leoyvens 21f9c26
runtime: Properly explain unsafe usage
leoyvens 740f03d
runtime: Expand comments
leoyvens f815c8b
runtime: Rename `instance` and `borrow_instance`
leoyvens d98c0cc
runtime: depend on wasmtime master, use u32 where possible
leoyvens c090839
runtime: Don't disable timeout due to ipfs.map
leoyvens 7d57905
runtime: Address review
leoyvens f8f3116
runtime: Fix flaky tests
leoyvens 33ebb5c
runtime: Spawn test modules that use block_on in their own thread
leoyvens fd616a0
graph: Use tokio block_on instead of futures block_on
leoyvens 1d08115
runtime: Remove redundant `block_in_place` in test
leoyvens 36da2e1
graph: Fix typo
leoyvens 65a2183
runtime: Uncomment test
leoyvens 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
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
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
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
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
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,31 @@ | ||
| // Converts back and forth between `failure::Error` and `anyhow::Error` | ||
| // while we don't migrate fully to `anyhow`. | ||
| pub trait CompatErr { | ||
| type Other; | ||
| fn compat_err(self) -> Self::Other; | ||
| } | ||
|
|
||
| impl CompatErr for failure::Error { | ||
| type Other = anyhow::Error; | ||
|
|
||
| fn compat_err(self) -> anyhow::Error { | ||
| anyhow::Error::from(self.compat()) | ||
| } | ||
| } | ||
|
|
||
| impl CompatErr for anyhow::Error { | ||
| type Other = failure::Error; | ||
|
|
||
| fn compat_err(self) -> failure::Error { | ||
| // Convert as a single error containing all the causes. | ||
| failure::err_msg(format!("{:#}", self)) | ||
| } | ||
| } | ||
|
|
||
| impl<T, E: CompatErr> CompatErr for Result<T, E> { | ||
| type Other = Result<T, E::Other>; | ||
|
|
||
| fn compat_err(self) -> Self::Other { | ||
| self.map_err(CompatErr::compat_err) | ||
| } | ||
| } |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -8,3 +8,5 @@ pub mod ethereum; | |
| pub mod security; | ||
|
|
||
| pub mod lfu_cache; | ||
|
|
||
| pub mod error; | ||
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.