Conversation
22afd7b to
0505324
Compare
|
verified that it has started working fine and passing all the e2e tests in https://github.com/tetratelabs/proxy-wasm-go-sdk |
|
hmm..... I haven't been able to identify the cause...... |
|
as for the performance, they seem to have the compile time optimization configurations: https://github.com/bytecodealliance/wasmtime/blob/main/crates/c-api/include/wasmtime.h#L84-L105 |
|
@PiotrSikora I followed Lizan's advice and decided to use smart pointers 🙂 But I still have struggles to identify the root cause of memory leakage when used in Envoy. Besides that, I believe this is ready for review. Please take a look! @lizan I need your advice on C++, bazel in general 🙂 |
e2f60d1 to
37a3c80
Compare
|
@PiotrSikora I managed to generate BUILD files for wasmtime in 37a3c80 , which is based on https://github.com/mathetake/bazel-wasmtime-c-api repo where I used cargo-raze and a few of manual tweeks. PTAL! 😃 |
|
Could you split this into 2 PRs? One that just adds Wasmtime build machinery, and another with an actual implementation. |
PiotrSikora
left a comment
There was a problem hiding this comment.
Generally, it looks great, thanks!
A left a few nits, and it looks that you're missing getStrippedSource().
Signed-off-by: mathetake <takeshi@tetrate.io>
Signed-off-by: mathetake <takeshi@tetrate.io>
Signed-off-by: mathetake <takeshi@tetrate.io>
Signed-off-by: mathetake <takeshi@tetrate.io>
Signed-off-by: mathetake <takeshi@tetrate.io>
Signed-off-by: mathetake <takeshi@tetrate.io>
|
Why disabling cache? |
|
wasmtime's cache spawns a new thread for a cache worker, and I thought it would affect the host's performance, although the same may be true for V8. and what's more, it seems to use file system rather than in-memory cache: https://github.com/bytecodealliance/wasmtime/blob/main/crates/cache/src/worker.rs#L404 That said, I'm not sure how impactful it is, so I disable it for now (as an experimental runtime) @PiotrSikora anythought? |
|
Ah, OK. Sounds good! btw: |
Signed-off-by: mathetake <takeshi@tetrate.io>
Thanks! Updated |
|
envoyproxy/envoy@a871b14 also updated for envoy |
PiotrSikora
left a comment
There was a problem hiding this comment.
A few more nits before merge.
Signed-off-by: mathetake <takeshi@tetrate.io>
Signed-off-by: mathetake <takeshi@tetrate.io>
Signed-off-by: mathetake <takeshi@tetrate.io>
Signed-off-by: mathetake <takeshi@tetrate.io>
|
Ah, one more thing. You need to include |
Signed-off-by: mathetake <takeshi@tetrate.io>
|
Thanks! |
Commit Message: wasm: Add Wasmtime as a new runtime Additional Description: add a new wasm runtime named Wasmtime Risk Level: low Testing: run in `bazel.compile_time_options` build target as WAVM. Docs Changes: Docs will be provided in subsequent PRs. Release Notes: enable Wasmtime as a Wasm filter runtime optionally. ref: proxy-wasm/proxy-wasm-cpp-host#73 Signed-off-by: mathetake <takeshi@tetrate.io> Co-authored-by: Piotr Sikora <piotrsikora@google.com>
Commit Message: wasm: Add Wasmtime as a new runtime Additional Description: add a new wasm runtime named Wasmtime Risk Level: low Testing: run in `bazel.compile_time_options` build target as WAVM. Docs Changes: Docs will be provided in subsequent PRs. Release Notes: enable Wasmtime as a Wasm filter runtime optionally. ref: proxy-wasm/proxy-wasm-cpp-host#73 Signed-off-by: mathetake <takeshi@tetrate.io> Co-authored-by: Piotr Sikora <piotrsikora@google.com>
Signed-off-by: mathetake takeshi@tetrate.io