1 # RUN: yaml2obj %s -o %t
2 # RUN: llvm-objcopy %t %t2
3 # RUN: llvm-readobj --sections %t2 | FileCheck %s
5 ## This checks that llvm-objcopy layouts sections in the order of their offsets
6 ## in the input file in spite of the order of section headers is different.
9 # CHECK-NEXT: Name: foo
12 # CHECK-NEXT: SHF_ALLOC
14 # CHECK-NEXT: Address:
15 # CHECK-NEXT: Offset: 0x50
17 # CHECK-NEXT: Name: bar
18 # CHECK-NEXT: Type: SHT_PROGBITS
20 # CHECK-NEXT: SHF_ALLOC
22 # CHECK-NEXT: Address:
23 # CHECK-NEXT: Offset: 0x40
25 # CHECK-NEXT: Name: baz
26 # CHECK-NEXT: Type: SHT_PROGBITS
28 # CHECK-NEXT: SHF_ALLOC
30 # CHECK-NEXT: Address:
31 # CHECK-NEXT: Offset: 0x48
45 Content: 0000000000000000
51 Content: 0000000000000000
57 Content: 0000000000000000
58 - Type: SectionHeaderTable
60 ## Note: the order of section headers differs from their layout.