1 ## Check how obj2yaml dumps the SHT_LLVM_ADDRSIG section.
3 ## Check that when possible obj2yaml tries to produce the "Name" tag when
4 ## dumping entries of the SHT_LLVM_ADDRSIG section. It falls back to producing
5 ## the "Index" tag when it can't match a symbol index with a symbol table entry.
7 # RUN: yaml2obj --docnum=1 %s -o %t1
8 # RUN: obj2yaml %t1 | FileCheck %s --check-prefix=NAME
10 # NAME: - Name: .llvm_addrsig
11 # NAME-NEXT: Type: SHT_LLVM_ADDRSIG
12 # NAME-NEXT: Link: .symtab
13 # NAME-NEXT: Symbols: [ foo, bar, '3', '4294967295' ]
14 # NAME: - Name: .llvm_addrsig_unlinked
15 # NAME-NEXT: Type: SHT_LLVM_ADDRSIG
16 # NAME-NEXT: Symbols: [ '1', '2', '3', '4294967295' ]
25 Type: SHT_LLVM_ADDRSIG
26 Symbols: [ 1, 2, 3, 0xFFFFFFFF ]
27 - Name: .llvm_addrsig_unlinked
28 Type: SHT_LLVM_ADDRSIG
30 Symbols: [ 1, 2, 3, 0xFFFFFFFF ]
39 ## Check that obj2yaml dumps the SHT_LLVM_ADDRSIG section
40 ## data using the "Content" tag when at least one of the entries is broken,
41 ## e.g. because the entry contains a malformed uleb128 value.
43 # RUN: yaml2obj --docnum=2 %s -o %t2
44 # RUN: obj2yaml %t2 | FileCheck %s --check-prefix=INVALID-ENTRY
46 # INVALID-ENTRY: - Name: .llvm_addrsig
47 # INVALID-ENTRY-NEXT: Type: SHT_LLVM_ADDRSIG
48 # INVALID-ENTRY-NEXT: Content: FFFFFFFFFF
57 Type: SHT_LLVM_ADDRSIG
60 ## obj2yaml produces a "Symbols" tag when describing an empty SHT_LLVM_ADDRSIG section.
62 # RUN: yaml2obj --docnum=3 %s -o %t3
63 # RUN: obj2yaml %t3 | FileCheck %s --check-prefix=EMPTY
65 # EMPTY: - Name: .llvm_addrsig
66 # EMPTY-NEXT: Type: SHT_LLVM_ADDRSIG
67 # EMPTY-NEXT: Symbols: [ ]
76 Type: SHT_LLVM_ADDRSIG