Will the web assembly (wasm) have its own syntax?

I heard that W3 is working on network byte code. Will the web assembly (wasm) have its own syntax like nasm and masm? for example, print stuff like

 global _main
extern _MessageBoxA@16
extern _ExitProcess@4

section code use32 class=code
_main:
    push    dword 0      ; UINT uType = MB_OK
    push    dword title  ; LPCSTR lpCaption
    push    dword banner ; LPCSTR lpText
    push    dword 0      ; HWND hWnd = NULL
    call    _MessageBoxA@16

    push    dword 0      ; UINT uExitCode
    call    _ExitProcess@4

section data use32 class=data
    banner: db 'Hello, world!', 0
    title:  db 'Hello', 0

in nasm for windows

or will it be created only from compilation from C / C ++ and other languages?

+4
source share
2 answers

The current working prototype for WebAssembly already has a syntax that also emits the LLVM backend ( CHECK:parts of these tests) used by the WAVM backend . Also see ilwasm and WABT .

? , ( 2017 : ).

WebAssembly , AST, WebAssembly. s- , , bikeshed.


:

WebAssembly, s-, , . (AST) , IR- (CFG).

? ! The wassembler, V8 .

, s-? C ! , , .

? . - , WebAssembly : , , . ? , . , , - , , , , , .

+11

W eb A s s e m bly (WASM) asm.js. GitHUB FAQ :

, , asm.js, WebAssembly , asm.js. -, .

[...]

WebAssembly , C/++, , , C/++, GCC.

0

Source: https://habr.com/ru/post/1608114/


All Articles