官术网_书友最值得收藏!

  • Learn WebAssembly
  • Mike Rourke
  • 224字
  • 2021-08-13 15:38:48

Language concepts

The Core Specification states WebAssembly encodes a low-level, assembly-like programming language. The specification defines the structure, execution, and validation of this language as well as the details of the binary and text formats. The language itself is structured around the following concepts:

  • Values, or rather value types that WebAssembly provides
  • Instructions that are executed within the stack machine
  • Traps produced under error conditions and abort execution
  • Functions into which code is organized, each of which takes a sequence of values as parameters and returns a sequence of values as a result
  • Tables, which are arrays of values of a particular element type (such as function references) that are selectable by the executing program
  • Linear Memory, which is an array of raw bytes that can be used to store and load values
  • Modules, WebAssembly binary (.wasm file) that contains function, tables, and linear memories
  • Embedder, the mechanism by which WebAssembly can be executed in a host environment, such as a web browser

Functions, tables, memory, and modules have direct correlations with the JavaScript API and are important to be aware of. These concepts describe the underlying structure of the language itself and how to write or encode WebAssembly. With regard to usage, understanding the corresponding semantic phases of WebAssembly provides a complete definition of the technology:

Language concepts and their relationship
主站蜘蛛池模板: 酒泉市| 清徐县| 曲周县| 桂平市| 基隆市| 论坛| 兰坪| 棋牌| 邹平县| 石城县| 阿城市| 霍城县| 和平县| 孟津县| 松滋市| 鄂托克旗| 来宾市| 根河市| 剑河县| 二连浩特市| 齐齐哈尔市| 融水| 铜鼓县| 富源县| 凌源市| 平邑县| 道孚县| 洛隆县| 迁安市| 瑞昌市| 西青区| 德化县| 得荣县| 兴文县| 祁连县| 开原市| 封丘县| 岗巴县| 乾安县| 多伦县| 五寨县|