[AMDGPU][True16][CodeGen] true16 codegen pattern for v_med3_u/i16 (#121850)
[llvm-project.git] / llvm / test / MC / WebAssembly / comdat-sections.s
blob291e5c6f8de16d46393a94ae45a2537f39fa6628
1 # RUN: llvm-mc -triple=wasm32 -filetype=obj %s -o - | obj2yaml | FileCheck %s
3 .section .text.foo,"G",@,abc123,comdat
4 .globl foo
5 .type foo,@function
6 foo:
7 .functype foo () -> ()
8 return
9 end_function
11 .globl bar
12 bar:
13 .functype bar () -> ()
14 return
15 end_function
17 .section .debug_foo,"G",@,abc123,comdat
18 .int32 42
19 .section .debug_foo,"G",@,duplicate,comdat
20 .int64 234
22 # Check that there are 2 identically-named custom sections, with the desired
23 # contents
24 # CHECK: - Type: CUSTOM
25 # CHECK-NEXT: Name: .debug_foo
26 # CHECK-NEXT: Payload: 2A000000
27 # CHECK-NEXT: - Type: CUSTOM
28 # CHECK-NEXT: Name: .debug_foo
29 # CHECK-NEXT: Payload: EA00000000000000
31 # And check that they are in 2 different comdat groups
32 # CHECK-NEXT:- Type: CUSTOM
33 # CHECK-NEXT: Name: linking
34 # CHECK-NEXT: Version: 2
35 # CHECK: Comdats:
36 # CHECK-NEXT: - Name: abc123
37 # CHECK-NEXT: Entries:
38 # CHECK-NEXT: - Kind: FUNCTION
39 # CHECK-NEXT: Index: 0
41 # If the user forgets to create a new section for a function, one is created for
42 # them by the assembler. Check that it is also in the same group.
43 # CHECK-NEXT: - Kind: FUNCTION
44 # CHECK-NEXT: Index: 1
45 # CHECK-NEXT: - Kind: SECTION
46 # CHECK-NEXT: Index: 4
47 # CHECK-NEXT: - Name: duplicate
48 # CHECK-NEXT: Entries:
49 # CHECK-NEXT: - Kind: SECTION
50 # CHECK-NEXT: Index: 5