• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1## This checks that when the header section of a group is removed, the tool
2## drops the flag SHF_GROUP for preserved members of that group.
3
4# RUN: yaml2obj %s -o - \
5# RUN:   | llvm-objcopy -R .group - - \
6# RUN:   | llvm-readobj --sections - \
7# RUN:   | FileCheck %s
8
9# CHECK:      Name: .foo
10# CHECK-NEXT: Type: SHT_PROGBITS
11# CHECK-NEXT: Flags [
12# CHECK-NEXT:   SHF_ALLOC
13# CHECK-NEXT: ]
14
15--- !ELF
16FileHeader:
17  Class:      ELFCLASS64
18  Data:       ELFDATA2LSB
19  Type:       ET_REL
20  Machine:    EM_X86_64
21Sections:
22  - Name:     .group
23    Type:     SHT_GROUP
24    Info:     foo_grp
25    Members:
26      - SectionOrType:  GRP_COMDAT
27      - SectionOrType:  .foo
28  - Name:     .foo
29    Type:     SHT_PROGBITS
30    Flags:    [ SHF_ALLOC, SHF_GROUP ]
31Symbols:
32  - Name:     foo_grp
33    Section:  .group
34