Skip to content

wasmtime: Option to return default values for unknown imports#6010

Merged
fitzgen merged 1 commit into
bytecodealliance:mainfrom
fitzgen:default-values-unknown-imports
Mar 13, 2023
Merged

wasmtime: Option to return default values for unknown imports#6010
fitzgen merged 1 commit into
bytecodealliance:mainfrom
fitzgen:default-values-unknown-imports

Conversation

@fitzgen
Copy link
Copy Markdown
Member

@fitzgen fitzgen commented Mar 13, 2023

Similar to the --trap-unknown-imports option, which defines unknown function imports with functions that trap when called, this new --default-values-unknown-imports option defines unknown function imports with a function that returns the default values for the result types (either zero or null depending on the value type).

Similar to the `--trap-unknown-imports` option, which defines unknown function
imports with functions that trap when called, this new
`--default-values-unknown-imports` option defines unknown function imports with
a function that returns the default values for the result types (either zero or
null depending on the value type).
@fitzgen fitzgen requested a review from alexcrichton March 13, 2023 21:01
@fitzgen
Copy link
Copy Markdown
Member Author

fitzgen commented Mar 13, 2023

This allows us to run sightglass benchmarks with the regular wasmtime CLI, which is pretty handy.

@fitzgen fitzgen added this pull request to the merge queue Mar 13, 2023
@github-actions github-actions Bot added the wasmtime:api Related to the API of the `wasmtime` crate itself label Mar 13, 2023
@github-actions
Copy link
Copy Markdown

Subscribe to Label Action

cc @peterhuene

Details This issue or pull request has been labeled: "wasmtime:api"

Thus the following users have been cc'd because of the following labels:

  • peterhuene: wasmtime:api

To subscribe or unsubscribe from this label, edit the .github/subscribe-to-label.json configuration file.

Learn more.

Merged via the queue into bytecodealliance:main with commit 90c9bec Mar 13, 2023
@fitzgen fitzgen deleted the default-values-unknown-imports branch March 13, 2023 22:21
@jameysharp
Copy link
Copy Markdown
Contributor

Saying this "is pretty handy" is a heck of an understatement!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

wasmtime:api Related to the API of the `wasmtime` crate itself

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants