1 # Testing that __tls_size and __tls_align are correctly emitted when there are
2 # no thread_local variables.
4 # RUN: llvm-mc -filetype=obj -triple=wasm32-unknown-unknown -o %t.o %s
8 .functype _start () -> ()
11 .section .custom_section.target_features,"",@
20 # RUN: wasm-ld -no-gc-sections --shared-memory --max-memory=131072 --allow-undefined -o %t.wasm %t.o
21 # RUN: obj2yaml %t.wasm | FileCheck %s
22 # CHECK: - Type: GLOBAL
23 # CHECK-NEXT: Globals:
26 # CHECK-NEXT: - Index: 0
27 # CHECK-NEXT: Type: I32
28 # CHECK-NEXT: Mutable: true
29 # CHECK-NEXT: InitExpr:
30 # CHECK-NEXT: Opcode: I32_CONST
31 # CHECK-NEXT: Value: 66560
34 # CHECK-NEXT: - Index: 1
35 # CHECK-NEXT: Type: I32
36 # CHECK-NEXT: Mutable: true
37 # CHECK-NEXT: InitExpr:
38 # CHECK-NEXT: Opcode: I32_CONST
39 # CHECK-NEXT: Value: 0
42 # CHECK-NEXT: - Index: 2
43 # CHECK-NEXT: Type: I32
44 # CHECK-NEXT: Mutable: false
45 # CHECK-NEXT: InitExpr:
46 # CHECK-NEXT: Opcode: I32_CONST
47 # CHECK-NEXT: Value: 0
50 # CHECK-NEXT: - Index: 3
51 # CHECK-NEXT: Type: I32
52 # CHECK-NEXT: Mutable: false
53 # CHECK-NEXT: InitExpr:
54 # CHECK-NEXT: Opcode: I32_CONST
55 # CHECK-NEXT: Value: 0