87 lines · plain
1# RUN: yaml2obj %p/Inputs/COFF/i386.yaml | llvm-objdump -t - \2# RUN: | FileCheck %s -check-prefix COFF-i3863 4# COFF-i386: file format5# COFF-i386: SYMBOL TABLE:6# COFF-i386: [ 0](sec 1)(fl 0x00)(ty 0)(scl 3) (nx 1) 0x00000000 .text7# COFF-i386: AUX scnlen 0x24 nreloc 3 nlnno 0 checksum 0x0 assoc 1 comdat 08# COFF-i386: [ 2](sec 2)(fl 0x00)(ty 0)(scl 3) (nx 1) 0x00000000 .data9# COFF-i386: AUX scnlen 0xd nreloc 0 nlnno 0 checksum 0x0 assoc 2 comdat 010# COFF-i386: [ 4](sec 1)(fl 0x00)(ty 20)(scl 2) (nx 0) 0x00000000 _main11# COFF-i386: [ 5](sec 2)(fl 0x00)(ty 0)(scl 3) (nx 0) 0x00000000 L_.str12# COFF-i386: [ 6](sec 0)(fl 0x00)(ty 0)(scl 2) (nx 0) 0x00000000 _puts13# COFF-i386: [ 7](sec 0)(fl 0x00)(ty 0)(scl 2) (nx 0) 0x00000000 _SomeOtherFunction14 15# RUN: yaml2obj %s -o %t.elf-i38616# RUN: llvm-objdump -t %t.elf-i386 | FileCheck %s --check-prefix=ELF-i38617 18# ELF-i386: {{.*}}elf-i386: file format19# ELF-i386: SYMBOL TABLE:20# ELF-i386: 00000000 l df *ABS* 00000000 trivial-object-test.s21# ELF-i386: 00000000 l d .text 00000000 .text22# ELF-i386: 00000024 l d .rodata.str1.1 00000000 .rodata.str1.123# ELF-i386: 00000031 l d .note.GNU-stack 00000000 .note.GNU-stack24# ELF-i386: 00000000 g F .text 00000024 main25# ELF-i386: 00000000 *UND* 00000000 SomeOtherFunction26# ELF-i386: 00000000 *UND* 00000000 puts27 28--- !ELF29FileHeader:30 Class: ELFCLASS3231 Data: ELFDATA2LSB32 Type: ET_REL33 Machine: EM_38634Sections:35 - Name: .text36 Type: SHT_PROGBITS37 Flags: [ SHF_ALLOC, SHF_EXECINSTR ]38 - Name: .rodata.str1.139 Type: SHT_PROGBITS40 Flags: [ SHF_ALLOC, SHF_MERGE, SHF_STRINGS ]41 Address: 0x000000000000002442 - Name: .note.GNU-stack43 Type: SHT_PROGBITS44 Address: 0x000000000000003145Symbols:46 - Name: trivial-object-test.s47 Type: STT_FILE48 Index: SHN_ABS49 - Name: .text50 Type: STT_SECTION51 Section: .text52 - Name: .rodata.str1.153 Type: STT_SECTION54 Section: .rodata.str1.155 - Name: .note.GNU-stack56 Type: STT_SECTION57 Section: .note.GNU-stack58 - Name: main59 Type: STT_FUNC60 Section: .text61 Binding: STB_GLOBAL62 Size: 0x000000000000002463 - Name: SomeOtherFunction64 Binding: STB_GLOBAL65 - Name: puts66 Binding: STB_GLOBAL67 68# RUN: llvm-objdump -t %p/Inputs/trivial-object-test.macho-i386 \69# RUN: | FileCheck %s -check-prefix macho-i38670 71# macho-i386: trivial-object-test.macho-i386: file format mach-o 32-bit i38672# macho-i386: SYMBOL TABLE:73# macho-i386: 00000000 g F __TEXT,__text _main74# macho-i386: 00000000 *UND* _SomeOtherFunction75# macho-i386: 00000000 *UND* _puts76 77# RUN: llvm-objdump -t %p/Inputs/shared-object-test.elf-i386 \78# RUN: | FileCheck %s -check-prefix ELF-shared79 80# ELF-shared: shared-object-test.elf-i386: file format81# ELF-shared: SYMBOL TABLE:82# ELF-shared: 00000200 l F .text 00000003 local_func83# ELF-shared: 000012b8 l O *ABS* 00000000 .hidden _GLOBAL_OFFSET_TABLE_84# ELF-shared: 00001248 l O *ABS* 00000000 .hidden _DYNAMIC85# ELF-shared: 000012c4 g O .data 00000004 defined_sym86# ELF-shared: 000001f0 g F .text 00000003 global_func87