Files
clang-p2996/lld/test/wasm/Inputs/globals.yaml
Thomas Lively 393d0f799f [WebAssembly] Allow multivalue signatures in object files
Summary:
Also changes the wasm YAML format to reflect the possibility of having
multiple return types and to put the returns after the params for
consistency with the binary encoding.

Reviewers: aheejin, sbc100

Subscribers: dschuff, jgravelle-google, hiraditya, sunfish, arphaman, rupprecht, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D69156

llvm-svn: 375283
2019-10-18 20:27:30 +00:00

56 lines
1.4 KiB
YAML

--- !WASM
FileHeader:
Version: 0x00000001
Sections:
- Type: TYPE
Signatures:
- Index: 0
ParamTypes:
ReturnTypes:
- I64
- Type: FUNCTION
FunctionTypes: [ 0 ]
- Type: GLOBAL
Globals:
- Index: 0
Type: I64
Mutable: true
InitExpr:
Opcode: I64_CONST
Value: 123
- Index: 1
Type: I64
Mutable: true
InitExpr:
Opcode: I64_CONST
Value: 456
- Type: CODE
Functions:
- Index: 0
Locals:
Body: 2381808080000B
Relocations:
- Type: R_WASM_GLOBAL_INDEX_LEB
Index: 1
Offset: 0x00000004
- Type: CUSTOM
Name: linking
Version: 2
SymbolTable:
- Index: 0
Kind: GLOBAL
Name: unused_global
Flags: [ VISIBILITY_HIDDEN ]
Global: 0
- Index: 1
Kind: GLOBAL
Name: used_global
Flags: [ VISIBILITY_HIDDEN ]
Global: 1
- Index: 2
Kind: FUNCTION
Name: use_global
Flags: [ VISIBILITY_HIDDEN ]
Function: 0
...