fitzgen requested alexcrichton for a review on PR #1781.
fitzgen opened PR #1781 from externref
to master
:
This is enough to get an
externref -> externref
identity function passing.However,
externref
s that are dropped by compiled Wasm code are (safely) leaked. Follow up work will leverage cranelift's stack maps to resolve this issue.
fitzgen updated PR #1781 from externref
to master
:
This is enough to get an
externref -> externref
identity function passing.However,
externref
s that are dropped by compiled Wasm code are (safely) leaked. Follow up work will leverage cranelift's stack maps to resolve this issue.
fitzgen updated PR #1781 from externref
to master
:
This is enough to get an
externref -> externref
identity function passing.However,
externref
s that are dropped by compiled Wasm code are (safely) leaked. Follow up work will leverage cranelift's stack maps to resolve this issue.
fitzgen updated PR #1781 from externref
to master
:
This is enough to get an
externref -> externref
identity function passing.However,
externref
s that are dropped by compiled Wasm code are (safely) leaked. Follow up work will leverage cranelift's stack maps to resolve this issue.
alexcrichton submitted PR Review.
alexcrichton submitted PR Review.
alexcrichton created PR Review Comment:
Since
data
isn't an owned value this doesn't actually do anything, right?
alexcrichton created PR Review Comment:
.unwrap()
?
alexcrichton created PR Review Comment:
Perhaps defer to https://doc.rust-lang.org/std/alloc/fn.handle_alloc_error.html?
alexcrichton created PR Review Comment:
This looks like it's sharing a lot of code with allocation below, could that be refactored out to a shared function?
alexcrichton created PR Review Comment:
Is this a place in the C API where the store should be passed in?
alexcrichton created PR Review Comment:
Looks like this file became executable?
alexcrichton created PR Review Comment:
This can probably just be deleted now, it doesn't seem to serve too much purpose any more
alexcrichton created PR Review Comment:
This and traits below seem dangerous since I'd naively expect it to defer to the underlying type (which can't be done here b/c it's not generic). Could this be exposed as a free-function?
alexcrichton created PR Review Comment:
This seems like a fine API to expose though, especially because
Caller
below exposes it too
alexcrichton created PR Review Comment:
out of date comment?
alexcrichton created PR Review Comment:
Ideally we'd move this out of the
wasmtime
crate entirely. Can all thehost_info
stuff move towasm_store_t
in the C API? I think the C API could store aRc<wasm_store_t>
on all the exported types, right?
alexcrichton created PR Review Comment:
The only reason this is here is for the
host_info
APIs, right? If so I would personally prefer that we just jettison that support from the C API for now. I think we should find a better way for implementing that, if necessary, instead of altering the design of thewasmtime
crate itself.
alexcrichton created PR Review Comment:
Can this structure move to the C API?
alexcrichton created PR Review Comment:
Could this pass in
self.store()
and defer toDebug for Store
?
fitzgen submitted PR Review.
fitzgen created PR Review Comment:
Yeah, this is more of a doing-everything-by-the-book and crossing-out-ts-and-dotting-our-is sort of thing for avoiding UB, but it is maybe overly conservative.
fitzgen submitted PR Review.
fitzgen created PR Review Comment:
This is needed for the
wasi_instance_bind_import
WASI C API function -- do you happen to know if this is part of the C API or part of wasi?
fitzgen submitted PR Review.
fitzgen created PR Review Comment:
As mentioned in chat, it is useful to have this built into the
wasmtime
crate so that host infos can be cleaned up when their associatedexternref
goes away.
fitzgen submitted PR Review.
fitzgen created PR Review Comment:
Store
doesn't implementDebug
, but I can add an impl.
fitzgen updated PR #1781 from externref
to master
:
This is enough to get an
externref -> externref
identity function passing.However,
externref
s that are dropped by compiled Wasm code are (safely) leaked. Follow up work will leverage cranelift's stack maps to resolve this issue.
fitzgen updated PR #1781 from externref
to master
:
This is enough to get an
externref -> externref
identity function passing.However,
externref
s that are dropped by compiled Wasm code are (safely) leaked. Follow up work will leverage cranelift's stack maps to resolve this issue.
fitzgen requested alexcrichton for a review on PR #1781.
fitzgen updated PR #1781 from externref
to master
:
This is enough to get an
externref -> externref
identity function passing.However,
externref
s that are dropped by compiled Wasm code are (safely) leaked. Follow up work will leverage cranelift's stack maps to resolve this issue.
alexcrichton submitted PR Review.
alexcrichton created PR Review Comment:
Ah I think that's just part of WASI, but this seems fine to add anyway
alexcrichton submitted PR Review.
fitzgen merged PR #1781.
Last updated: Nov 22 2024 at 16:03 UTC