Stream: git-wasmtime

Topic: wasmtime / PR #2115 Propagate module-linking types to `wa...


view this post on Zulip Wasmtime GitHub notifications bot (Aug 07 2020 at 16:46):

alexcrichton opened PR #2115 from expose-module-linking-types to main:

This commit adds lots of plumbing to get the type section from the
module linking proposal plumbed all the way through to the wasmtime
crate and the wasmtime-c-api crate. This isn't all that useful right
now because Wasmtime doesn't support imported/exported
modules/instances, but this is all necessary groundwork to getting that
exported at some point. I've added some light tests but I suspect the
bulk of the testing will come in a future commit.

One major change in this commit is that SignatureIndex no longer
follows type type index space in a wasm module. Instead a new
TypeIndex type is used to track that. Function signatures, still
indexed by SignatureIndex, are then packed together tightly.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 07 2020 at 17:32):

alexcrichton updated PR #2115 from expose-module-linking-types to main:

This commit adds lots of plumbing to get the type section from the
module linking proposal plumbed all the way through to the wasmtime
crate and the wasmtime-c-api crate. This isn't all that useful right
now because Wasmtime doesn't support imported/exported
modules/instances, but this is all necessary groundwork to getting that
exported at some point. I've added some light tests but I suspect the
bulk of the testing will come in a future commit.

One major change in this commit is that SignatureIndex no longer
follows type type index space in a wasm module. Instead a new
TypeIndex type is used to track that. Function signatures, still
indexed by SignatureIndex, are then packed together tightly.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 04 2020 at 16:53):

alexcrichton updated PR #2115 from expose-module-linking-types to main:

This commit adds lots of plumbing to get the type section from the
module linking proposal plumbed all the way through to the wasmtime
crate and the wasmtime-c-api crate. This isn't all that useful right
now because Wasmtime doesn't support imported/exported
modules/instances, but this is all necessary groundwork to getting that
exported at some point. I've added some light tests but I suspect the
bulk of the testing will come in a future commit.

One major change in this commit is that SignatureIndex no longer
follows type type index space in a wasm module. Instead a new
TypeIndex type is used to track that. Function signatures, still
indexed by SignatureIndex, are then packed together tightly.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 04 2020 at 17:01):

alexcrichton updated PR #2115 from expose-module-linking-types to main:

This commit adds lots of plumbing to get the type section from the
module linking proposal plumbed all the way through to the wasmtime
crate and the wasmtime-c-api crate. This isn't all that useful right
now because Wasmtime doesn't support imported/exported
modules/instances, but this is all necessary groundwork to getting that
exported at some point. I've added some light tests but I suspect the
bulk of the testing will come in a future commit.

One major change in this commit is that SignatureIndex no longer
follows type type index space in a wasm module. Instead a new
TypeIndex type is used to track that. Function signatures, still
indexed by SignatureIndex, are then packed together tightly.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 04 2020 at 19:55):

fitzgen submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 04 2020 at 19:55):

fitzgen submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 04 2020 at 19:55):

fitzgen created PR Review Comment:

Was the allow(missing_docs) intended to be temporary while getting something up and running?

view this post on Zulip Wasmtime GitHub notifications bot (Nov 04 2020 at 19:55):

fitzgen created PR Review Comment:

Commented out code?

Also, is getting the ty so perf sensitive that we have to use potentially-UB-inducing unreachable_unchecked over regular unreachable?

view this post on Zulip Wasmtime GitHub notifications bot (Nov 04 2020 at 19:55):

fitzgen created PR Review Comment:

ditto

view this post on Zulip Wasmtime GitHub notifications bot (Nov 04 2020 at 19:56):

fitzgen submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 04 2020 at 19:56):

fitzgen created PR Review Comment:

I guess this is going into an FFI language boundary... Did the auto-abort on unwind across FFI stuff re-merge? If so, then we should use unreachable!(), if not then we should abort ourselves I think.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 05 2020 at 15:34):

alexcrichton submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 05 2020 at 15:34):

alexcrichton created PR Review Comment:

Oh I figured the docs wouldn't really go much beyond what the code already says here, but I can add some strings.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 05 2020 at 15:35):

alexcrichton submitted PR Review.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 05 2020 at 15:35):

alexcrichton created PR Review Comment:

Oh this was copied from the other types in the C API, but I think it makes more sense to just add this back in as necessary later on.

Also yeah I doubt that unreachable_unchecked is really worth it here, and an unreachable!() should be fine.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 06 2020 at 20:03):

alexcrichton updated PR #2115 from expose-module-linking-types to main:

This commit adds lots of plumbing to get the type section from the
module linking proposal plumbed all the way through to the wasmtime
crate and the wasmtime-c-api crate. This isn't all that useful right
now because Wasmtime doesn't support imported/exported
modules/instances, but this is all necessary groundwork to getting that
exported at some point. I've added some light tests but I suspect the
bulk of the testing will come in a future commit.

One major change in this commit is that SignatureIndex no longer
follows type type index space in a wasm module. Instead a new
TypeIndex type is used to track that. Function signatures, still
indexed by SignatureIndex, are then packed together tightly.

view this post on Zulip Wasmtime GitHub notifications bot (Nov 06 2020 at 20:48):

alexcrichton merged PR #2115.


Last updated: Dec 23 2024 at 12:05 UTC