Stream: git-wasmtime

Topic: wasmtime / PR #6893 wasi-nn: remove `BackendKind`, add wr...


view this post on Zulip Wasmtime GitHub notifications bot (Aug 23 2023 at 17:13):

abrown opened PR #6893 from abrown:remove-backend-kind to bytecodealliance:main:

One improvement that came from discussions with @geekbeast is that BackendKind, the enum used for differentiating between ML implementation, is no longer necessary. Instead, we can use the generated GraphEncoding type as the key to map to the right implementation.

Also, this PR adopts the Wrapper(Box<dyn ...>) pattern everywhere, which now includes backends and registries. Since wasi-nn accepts multiple implementations for all of these things, we need a way to virtually dispatch to the right implementation. Previously we used the Box<dyn ...> type explicitly in many places but this change opts to use a wrapper around this, expecting users to create the wrapper via From and Into and internally accessing the implementation via Deref and DerefMut. The idea is to eliminate some of the "type clutter;" let me know if you agree.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 23 2023 at 17:13):

abrown requested wasmtime-core-reviewers for a review on PR #6893.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 23 2023 at 17:13):

abrown requested fitzgen for a review on PR #6893.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 23 2023 at 17:15):

abrown updated PR #6893.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 23 2023 at 17:59):

abrown updated PR #6893.

view this post on Zulip Wasmtime GitHub notifications bot (Aug 24 2023 at 22:26):

alexcrichton submitted PR review:

Nothing looks obviously wrong here to me but I'm not super familiar with the NN stuff of wasi-nn. It sounds like you're ok with that though so feel free to merge with my cursory review of "seems fine"

view this post on Zulip Wasmtime GitHub notifications bot (Aug 25 2023 at 03:32):

abrown merged PR #6893.


Last updated: Nov 22 2024 at 17:03 UTC