OSDN Git Service

557df3d6d0fcaf99e9ec47f295c400e51a680dbb
[android-x86/external-llvm.git] / test / tools / llvm-nm / format-sysv-binding.test
1 # XFAIL: *
2 # For a symbol in a text section the class character for an unrecognised binding
3 # value is '?' in gnu-nm but llvm-nm prints 'T'. Filed as:
4 # https://bugs.llvm.org/show_bug.cgi?id=41711
5
6 # RUN: yaml2obj %s > %t.o
7 # RUN: llvm-nm %t.o --format=sysv | FileCheck %s
8
9 !ELF
10 FileHeader:
11   Class:   ELFCLASS64
12   Data:    ELFDATA2LSB
13   Type:    ET_REL
14   Machine: EM_X86_64
15 Sections:
16   - Name:  .text
17     Type:  SHT_PROGBITS
18     Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
19 Symbols:
20   - Name:    symbol_local
21     Binding: STB_LOCAL
22     Section: .text
23     Value:   0x101
24     Size:    8
25   - Name:    symbol_weak
26     Binding: STB_WEAK
27     Section: .text
28     Value:   0x102
29     Size:    4
30   - Name:    symbol_undefined_binding
31     Binding: 5
32     Section: .text
33     Value:   0x1004
34     Size:    32
35   - Name:    symbol_global
36     Binding: STB_GLOBAL
37     Section: .text
38     Value:   0x103
39     Size:    16
40
41 # CHECK:      symbol_global {{.*}}|   T  |
42 # CHECK-NEXT: symbol_local  {{.*}}|   t  |
43 # CHECK-NEXT: symbol_unrecognised_binding {{.*}}| ? |
44 # CHECK-NEXT: symbol_weak {{.*}}|   W  |