# RUN: yaml2obj %s -o %t
# RUN: lldb-test object-file %t | FileCheck %s

# CHECK: Plugin name: xcoff
# CHECK: Architecture: powerpc64-ibm-aix
# CHECK: Executable: true
# CHECK: Stripped: false
# CHECK: Type: executable
# CHECK: Strata: unknown
# CHECK: Name: .text
# CHECK-NEXT: Type: code
# CHECK-NEXT: Permissions: r-x
# CHECK: Name: .data
# CHECK-NEXT: Type: data
# CHECK-NEXT: Permissions: rw-
# CHECK: Name: .bss
# CHECK-NEXT: Type: zero-fill
# CHECK-NEXT: Permissions: rw-
# CHECK: Name: .loader
# CHECK-NEXT: Type: regular
# CHECK-NEXT: Permissions: r--
# CHECK: Name: .dwline
# CHECK-NEXT: Type: dwarf-line
# CHECK-NEXT: Permissions: r--
# CHECK: Name: .dwinfo
# CHECK-NEXT: Type: dwarf-info
# CHECK-NEXT: Permissions: r--
# CHECK: Name: .dwabrev
# CHECK-NEXT: Type: dwarf-abbrev
# CHECK-NEXT: Permissions: r--

--- !XCOFF
FileHeader:
  MagicNumber:     0x1DF
  NumberOfSections: 7 
  CreationTime:    000000000
  Flags:           0x1002
Sections:
  - Name:            .text
    Address:         0x10000268
    Size:            0x512
    FileOffsetToData: 0x268
    FileOffsetToRelocations: 0xECC
    FileOffsetToLineNumbers: 0x0
    NumberOfRelocations: 0x24
    NumberOfLineNumbers: 0x0
    Flags:           [ STYP_TEXT ]
    SectionData:     80C20000
  - Name:            .data
    Address:         0x2000077A
    Size:            0x242
    FileOffsetToData: 0x77A
    FileOffsetToRelocations: 0x1034
    FileOffsetToLineNumbers: 0x0
    NumberOfRelocations: 0x25
    NumberOfLineNumbers: 0x0
    Flags:           [ STYP_DATA ]
    SectionData:     '' 
  - Name:            .bss
    Address:         0x200009BC
    Size:            0x10
    FileOffsetToData: 0x0
    FileOffsetToRelocations: 0x0
    FileOffsetToLineNumbers: 0x0
    NumberOfRelocations: 0x0
    NumberOfLineNumbers: 0x0
    Flags:           [ STYP_BSS ]
    SectionData:     ''
  - Name:            .loader
    Address:         0x0
    Size:            0x3A4
    FileOffsetToData: 0x9BC
    FileOffsetToRelocations: 0x0
    FileOffsetToLineNumbers: 0x0
    NumberOfRelocations: 0x0
    NumberOfLineNumbers: 0x0
    Flags:           [ STYP_LOADER ]
    SectionData:     00000001
  - Name:            .dwline
    Address:         0x0
    Size:            0x73
    FileOffsetToData: 0xD60
    FileOffsetToRelocations: 0x11A6
    FileOffsetToLineNumbers: 0x0
    NumberOfRelocations: 0x5
    NumberOfLineNumbers: 0x0
    Flags:           [ STYP_DWARF ]
    SectionData:     FFFFFFFF
  - Name:            .dwinfo
    Address:         0x0
    Size:            0xB4
    FileOffsetToData: 0xDD4
    FileOffsetToRelocations: 0x11D8
    FileOffsetToLineNumbers: 0x0
    NumberOfRelocations: 0x6
    NumberOfLineNumbers: 0x0
    Flags:           [ STYP_DWARF ]
    SectionData:     FFFFFFFF
  - Name:            .dwabrev
    Address:         0x0
    Size:            0x43
    FileOffsetToData: 0xE88
    FileOffsetToRelocations: 0x0
    FileOffsetToLineNumbers: 0x0
    NumberOfRelocations: 0x0
    NumberOfLineNumbers: 0x0
    Flags:           [ STYP_DWARF ]
    SectionData:     01110125
StringTable:     {}
...
