forked from OSchip/llvm-project
42 lines
1004 B
YAML
42 lines
1004 B
YAML
# Ensures that implicitly added sections can be ordered within Sections.
|
|
# RUN: yaml2obj %s -o %t
|
|
# RUN: llvm-readobj -sections %t | FileCheck %s --check-prefix=SECTION
|
|
# RUN: llvm-nm --dynamic %t | FileCheck %s --check-prefix=SYMBOL
|
|
|
|
!ELF
|
|
FileHeader:
|
|
Class: ELFCLASS64
|
|
Data: ELFDATA2LSB
|
|
Type: ET_DYN
|
|
Machine: EM_X86_64
|
|
Sections:
|
|
- Name: .data
|
|
Type: SHT_PROGBITS
|
|
Flags: [ SHF_ALLOC, SHF_WRITE ]
|
|
DynamicSymbols:
|
|
- Name: dynglobal
|
|
Type: STT_OBJECT
|
|
Section: .data
|
|
Binding: STB_GLOBAL
|
|
- Name: dynweak
|
|
Type: STT_OBJECT
|
|
Section: .data
|
|
Binding: STB_WEAK
|
|
- Name: dynlocal
|
|
Type: STT_OBJECT
|
|
Section: .data
|
|
Binding: STB_LOCAL
|
|
|
|
# SECTION: Name: .dynsym
|
|
# SECTION-NEXT: Type: SHT_DYNSYM
|
|
# SECTION-NEXT: Flags
|
|
# SECTION-NEXT: SHF_ALLOC
|
|
# SECTION: Name: .dynstr
|
|
# SECTION-NEXT: Type: SHT_STRTAB
|
|
# SECTION-NEXT: Flags
|
|
# SECTION-NEXT: SHF_ALLOC
|
|
|
|
# SYMBOL-DAG: D dynglobal
|
|
# SYMBOL-DAG: V dynweak
|
|
# SYMBOL-DAG: d dynlocal
|