- Hands-On Game Development with WebAssembly
- Rick Battagline
- 250字
- 2021-06-24 13:41:00
What is asm.js?
One early attempt to achieve native-like speed in the web browser using JavaScript was asm.js. Although that goal was reached and asm.js was adopted by all the major browser vendors, it never achieved widespread adoption by developers. The beauty of asm.js is that it still runs in most browsers, even in those that do not optimize for it. The idea behind asm.js was that typed arrays could be used in JavaScript to fake a C++ memory heap. The browser simulates pointers and memory allocation in C++, as well as types. A well-designed JavaScript engine can avoid dynamic type checking. Using asm.js, browser makers could get around many of the optimization problems created by the dynamic nature of JavaScript, by just pretending that this version of JavaScript is not dynamically typed. Emscripten, designed as a C++-to-JavaScript compiler, quickly adopted asm.js as the subset of JavaScript that it would compile to because of its improved performance in most browsers. The performance improvements driven by asm.js lead the way to WebAssembly. The same engine modifications used to make asm.js perform well could be used to bootstrap the WebAssembly MVP. Only the addition of a bytecode-to-bytecode compiler was required to take the WebAssembly bytecode and directly convert it into the IR bytecode used by the browser.
- 新媒體跨界交互設計
- Cortex-M3 + μC/OS-II嵌入式系統開發入門與應用
- 電腦軟硬件維修大全(實例精華版)
- 基于ARM的嵌入式系統和物聯網開發
- 深入淺出SSD:固態存儲核心技術、原理與實戰(第2版)
- micro:bit魔法修煉之Mpython初體驗
- AMD FPGA設計優化寶典:面向Vivado/SystemVerilog
- 從零開始學51單片機C語言
- R Deep Learning Essentials
- Visual Media Processing Using Matlab Beginner's Guide
- 固態存儲:原理、架構與數據安全
- Machine Learning Solutions
- 計算機組裝維修與外設配置(高等職業院校教改示范教材·計算機系列)
- 筆記本電腦維修300問
- 基于Proteus仿真的51單片機應用