Comments (1)
@kungfuboy 你好,TS 本身对性能没有什么提升,如果有需要并且在确定兼容性可以接受的情况下是可以替换成 Wasm 的。如果确定是纯计算的逻辑很多,那么转成 Wasm 肯定性能是会有大幅度提升的。如果重写难度不大可以考虑用 C++ 或者 Rust 重写。C++ 的话走 Emscripten 可以同时降级到 ASM.js,而 Go 的话由于胶水代码体积还是很大,目前不太建议。AssemblyScript 可以试试看,有没有 BUG 只能回归测试看一下了,覆盖率高的话也是可以用的。总体看你的能力和精力平衡选择,毕竟用 C++/Rust 重写需要考虑很多问题,不是很熟练的话也很容易出现 OOM 或者内容泄露的问题。
from book-diso-webassembly.
Related Issues (15)
- [Emscripten] Use "-s MODULARIZE" to initialize module in an async style.
- 第七章7.3.4 touch事件Demo和7.4.2事件Demo无法运行
- 请问对于编库产生的wasm文件如何调用 HOT 1
- test(7).js:2404 LinkError: WebAssembly.instantiate(): table import 25 is smaller than initial 30, got 14 HOT 1
- test(7).js:1267 Uncaught RangeError: WebAssembly.Memory(): could not allocate memory HOT 1
- 对于data段的描述存在疑惑 HOT 1
- 错误:编译参数错误 HOT 1
- p25 node -trace_parse app.js HOT 1
- p135,typo,lable HOT 1
- 一本不错的书 HOT 1
- p23 typo: lzay parsing HOT 1
- 关于第15页最后两行产生式的疑问 HOT 1
- p145 'br_if指令' 表述歧义 HOT 1
- run WebAssembly Standalone type report TypeError HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from book-diso-webassembly.