[ARM] Better OR's for MVE compares
[llvm-core.git] / test / MC / WebAssembly / data-section.s
blob70d9de2bb934133c25042abaf3a0b4707e254b9b
1 # RUN: llvm-mc -triple=wasm32-unknown-unknown -mattr=+unimplemented-simd128,+nontrapping-fptoint,+exception-handling < %s | FileCheck %s
2 # Check that it converts to .o without errors:
3 # RUN: llvm-mc -triple=wasm32-unknown-unknown -filetype=obj -mattr=+unimplemented-simd128,+nontrapping-fptoint,+exception-handling < %s | obj2yaml | FileCheck -check-prefix=BIN %s
5 # Minimal test for data sections.
7 test0:
8 .functype test0 () -> (i32)
9 i32.const .L.str
10 .Ltestlabel:
11 end_function
13 .section .rodata..L.str,"",@
14 .L.str:
15 .int8 100
16 .size .L.str, 1
19 # CHECK: .text
20 # CHECK-LABEL: test0:
21 # CHECK-NEXT: .functype test0 () -> (i32)
22 # CHECK-NEXT: i32.const .L.str
23 # CHECK-NEXT: .Ltestlabel:
24 # CHECK-NEXT: end_function
26 # CHECK: .section .rodata..L.str,"",@
27 # CHECK-NEXT:.L.str:
28 # CHECK-NEXT: .int8 100
31 # BIN: --- !WASM
32 # BIN-NEXT: FileHeader:
33 # BIN-NEXT: Version: 0x00000001
34 # BIN-NEXT: Sections:
35 # BIN-NEXT: - Type: TYPE
36 # BIN-NEXT: Signatures:
37 # BIN-NEXT: - Index: 0
38 # BIN-NEXT: ReturnType: I32
39 # BIN-NEXT: ParamTypes: []
40 # BIN-NEXT: - Type: IMPORT
41 # BIN-NEXT: Imports:
42 # BIN-NEXT: - Module: env
43 # BIN-NEXT: Field: __linear_memory
44 # BIN-NEXT: Kind: MEMORY
45 # BIN-NEXT: Memory:
46 # BIN-NEXT: Initial: 0x00000001
47 # BIN-NEXT: - Module: env
48 # BIN-NEXT: Field: __indirect_function_table
49 # BIN-NEXT: Kind: TABLE
50 # BIN-NEXT: Table:
51 # BIN-NEXT: ElemType: FUNCREF
52 # BIN-NEXT: Limits:
53 # BIN-NEXT: Initial: 0x00000000
54 # BIN-NEXT: - Type: FUNCTION
55 # BIN-NEXT: FunctionTypes: [ 0 ]
56 # BIN-NEXT: - Type: DATACOUNT
57 # BIN-NEXT: Count: 1
58 # BIN-NEXT: - Type: CODE
59 # BIN-NEXT: Relocations:
60 # BIN-NEXT: - Type: R_WASM_MEMORY_ADDR_SLEB
61 # BIN-NEXT: Index: 1
62 # BIN-NEXT: Offset: 0x00000004
63 # BIN-NEXT: Functions:
64 # BIN-NEXT: - Index: 0
65 # BIN-NEXT: Locals: []
66 # BIN-NEXT: Body: 4180808080000B
67 # BIN-NEXT: - Type: DATA
68 # BIN-NEXT: Segments:
69 # BIN-NEXT: - SectionOffset: 6
70 # BIN-NEXT: InitFlags: 0
71 # BIN-NEXT: Offset:
72 # BIN-NEXT: Opcode: I32_CONST
73 # BIN-NEXT: Value: 0
74 # BIN-NEXT: Content: '64'
75 # BIN-NEXT: - Type: CUSTOM
76 # BIN-NEXT: Name: linking
77 # BIN-NEXT: Version: 2
78 # BIN-NEXT: SymbolTable:
79 # BIN-NEXT: - Index: 0
80 # BIN-NEXT: Kind: FUNCTION
81 # BIN-NEXT: Name: test0
82 # BIN-NEXT: Flags: [ BINDING_LOCAL ]
83 # BIN-NEXT: Function: 0
84 # BIN-NEXT: - Index: 1
85 # BIN-NEXT: Kind: DATA
86 # BIN-NEXT: Name: .L.str
87 # BIN-NEXT: Flags: [ BINDING_LOCAL ]
88 # BIN-NEXT: Segment: 0
89 # BIN-NEXT: Size: 1
90 # BIN-NEXT: SegmentInfo:
91 # BIN-NEXT: - Index: 0
92 # BIN-NEXT: Name: .rodata..L.str
93 # BIN-NEXT: Alignment: 0
94 # BIN-NEXT: Flags: [ ]
95 # BIN-NEXT: ...