35 lines · plain
1# RUN: yaml2obj %s -o %t2# RUN: llvm-objcopy --strip-non-alloc --keep-section=.test --keep-section=.test3 %t %t23# RUN: llvm-objcopy --strip-non-alloc --regex --keep-section='^.test[0-9]+$' %t %t34# RUN: llvm-readobj --file-headers --sections %t2 | FileCheck %s5# RUN: llvm-readobj --file-headers --sections %t3 | FileCheck %s --check-prefix=REGEX6 7!ELF8FileHeader:9 Class: ELFCLASS6410 Data: ELFDATA2LSB11 Type: ET_REL12 Machine: EM_X86_6413Sections:14 - Name: .test15 Type: SHT_PROGBITS16 Flags: [ ]17 - Name: .test218 Type: SHT_PROGBITS19 Flags: [ ]20 - Name: .test321 Type: SHT_PROGBITS22 Flags: [ ]23 24 25# CHECK: SectionHeaderCount: 426 27# CHECK: Name: .test28# CHECK: Name: .test329# CHECK: Name: .shstrtab30 31# REGEX: SectionHeaderCount: 432# REGEX: Name: .test233# REGEX: Name: .test334# REGEX: Name: .shstrtab35