1 # This test tests that if two possible parent segments have the same offset that
2 # they're disambiguated based on their original index. This ensures that cycles
5 # RUN: yaml2obj %s -o %t
6 # RUN: llvm-objcopy %t %t2
7 # RUN: llvm-readobj --program-headers %t2 | FileCheck %s
18 Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
23 Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
40 #CHECK: ProgramHeaders [
41 #CHECK-NEXT: ProgramHeader {
42 #CHECK-NEXT: Type: PT_LOAD (0x1)
43 #CHECK-NEXT: Offset: 0x2000
44 #CHECK-NEXT: VirtualAddress: 0x0
45 #CHECK-NEXT: PhysicalAddress: 0x0
46 #CHECK-NEXT: FileSize: 4096
47 #CHECK-NEXT: MemSize: 4096
48 #CHECK-NEXT: Flags [ (0x5)
49 #CHECK-NEXT: PF_R (0x4)
50 #CHECK-NEXT: PF_X (0x1)
52 #CHECK-NEXT: Alignment: 4096
54 #CHECK-NEXT: ProgramHeader {
55 #CHECK-NEXT: Type: PT_LOAD (0x1)
56 #CHECK-NEXT: Offset: 0x1000
57 #CHECK-NEXT: VirtualAddress: 0x0
58 #CHECK-NEXT: PhysicalAddress: 0x0
59 #CHECK-NEXT: FileSize: 8192
60 #CHECK-NEXT: MemSize: 8192
61 #CHECK-NEXT: Flags [ (0x5)
62 #CHECK-NEXT: PF_R (0x4)
63 #CHECK-NEXT: PF_X (0x1)
65 #CHECK-NEXT: Alignment: 4096
67 #CHECK-NEXT: ProgramHeader {
68 #CHECK-NEXT: Type: PT_LOAD (0x1)
69 #CHECK-NEXT: Offset: 0x1000
70 #CHECK-NEXT: VirtualAddress: 0x0
71 #CHECK-NEXT: PhysicalAddress: 0x0
72 #CHECK-NEXT: FileSize: 8192
73 #CHECK-NEXT: MemSize: 8192
74 #CHECK-NEXT: Flags [ (0x5)
75 #CHECK-NEXT: PF_R (0x4)
76 #CHECK-NEXT: PF_X (0x1)
78 #CHECK-NEXT: Alignment: 4096