Component Size & Performance: JCO/SpiderMonkey vs QuickJS
還沒有人認領這個 Issue。
評估
- 難度
- 5/5
- 預估耗時
- 一週以上
- 新手友好度
- 25/100
- Issue 類型
- 缺陷
- 描述清晰度
- 需要釐清
- 活躍度
- 冷清
- 技術堆疊
- javascript, rust, wasm
- 領域
- compilers, performance
研究方向
重現 JCO、搭配 weval/aot 的 JCO,以及使用 QuickJS 的 Rust 所報告的三個元件大小、fib(40) 執行時間和啟動時程式碼產生時間。issue 未列出任何檔案、測試或進入點,因此請先要求或尋找承諾提供的程式碼範例,並確認是否由 SpiderMonkey 造成。完成的標準是解釋這項差異,或找出具體的最佳化機會。
由索引模型根據 Issue 內容生成。
描述
Hi there,
Let me start by saying that I'm missing a lot of context and that my approach is extremely naive, so please tell me to bugger off. Yet, I would still like to better understand the rational or state-of-the-world.
I'm playing around with various WASI components, mostly in Rust and JS. I did certainly notice the chunky component size of my JS components whenever wasmtime had to recompile them. I didn't think too much of it, thinking that's just the price to pay for bundling an interpreter. However, eventually I built a rust WASI component bundling QuickJS (via the rquickjs crate), which turned out to be slightly faster and significantly smaller. For comparison:
- JCO => 13M
- JCO + weval/aot => 29M
- Rust + QuickJS => 1.9M
Running a naive fibonacci implementation just to get a sense of performance, I get for fib(40):
- JCO => 45s
- JCO + weval/aot => 29s
- Rust + QuickJS => 26s
And startup codgegen/compile times are hugely different roughly propotional to the difference in component size.
I've no clue if this actually SpiderMonkey or if there's something else going on, however I didn't expect the difference to be quite so substantial. Could you help me understand what I'm missing or is this an opportunity?
Thanks,
Sebastian
EDIT: I'm happy to back this up with code-examples, I mostly just wanted to reach out and see if this is something you're aware off or have seen before.
- 主要語言
- Rust
- 星號
- 392
- 分支
- 54
- 平均合併
- 2 天 18 小時
- 30 天內合併 PR
- 3
貢獻指南
這個儲存庫沒有索引到貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
bytecodealliance/ComponentizeJS 的其他 Issue
-
難度 2/5 1-3 小時 新手友好度 72/100
-
enhancement
難度 4/5 3-5 天 新手友好度 56/100
-
難度 3/5 1-2 天 新手友好度 52/100
-
難度 4/5 3-5 天 新手友好度 45/100
-
難度 4/5 3-5 天 新手友好度 48/100
bytecodealliance/ComponentizeJS#335 · 3 則留言 ·
查看 bytecodealliance/ComponentizeJS 的全部 Issue
相似的 Issue
-
bug github_actions
難度 2/5 1-3 小時 新手友好度 75/100
registrystack/registry-stack#1393 ·
-
難度 2/5 1-3 小時 新手友好度 75/100
longbridge/gpui-kit#3223 ·
-
bug engine
難度 2/5 1-3 小時 新手友好度 65/100
rocky-data/rocky#2181 ·
-
難度 2/5 1-3 小時 新手友好度 70/100
oasisprotocol/oasis-sdk#2523 ·
-
bot:ai-assisted component:indexer QA-roadmap status:untriaged
難度 2/5 1-3 小時 新手友好度 75/100
midnightntwrk/midnight-indexer#1557 ·