2013-02-28 04:01:43 +08:00
|
|
|
RUN: lld-core -reader ELF -writer ELF -o %t1 %p/Inputs/phdr.i386
|
|
|
|
RUN: elf-dump %t1 | FileCheck -check-prefix=ED %s
|
2013-01-26 07:23:24 +08:00
|
|
|
|
|
|
|
RUN: lld -core -target x86_64-linux -output=%t1 %p/Inputs/relocs.x86-64 \
|
2013-02-15 04:32:00 +08:00
|
|
|
RUN: -output-type=static && llvm-objdump -p %t1 \
|
|
|
|
RUN: | FileCheck %s -check-prefix=X86_64
|
2012-11-22 05:07:36 +08:00
|
|
|
|
2013-02-08 04:33:55 +08:00
|
|
|
|
2012-12-27 10:26:30 +08:00
|
|
|
ED: (('p_type', 0x00000001)
|
|
|
|
ED: ('p_flags', 0x00000005)
|
2013-01-07 16:00:04 +08:00
|
|
|
ED: ('p_offset', 0x00000000)
|
2012-12-27 10:26:30 +08:00
|
|
|
ED: ('p_vaddr', 0x00000000)
|
|
|
|
ED: ('p_paddr', 0x00000000)
|
2013-01-07 16:00:04 +08:00
|
|
|
ED: ('p_filesz', 0x000000d9)
|
|
|
|
ED: ('p_memsz', 0x000000d9)
|
2012-12-27 10:26:30 +08:00
|
|
|
ED: ('p_align', 0x00001000)
|
|
|
|
ED: ),
|
|
|
|
ED: # Program Header 1
|
|
|
|
ED: (('p_type', 0x00000001)
|
2013-02-08 04:33:55 +08:00
|
|
|
ED: ('p_flags', 0x00000004)
|
2013-01-07 16:00:04 +08:00
|
|
|
ED: ('p_offset', 0x00001000)
|
2012-12-27 10:26:30 +08:00
|
|
|
ED: ('p_vaddr', 0x00001000)
|
|
|
|
ED: ('p_paddr', 0x00001000)
|
2013-02-08 04:33:55 +08:00
|
|
|
ED: ('p_filesz', 0x0000008c)
|
|
|
|
ED: ('p_memsz', 0x0000008c)
|
|
|
|
ED: ('p_align', 0x00001000)
|
|
|
|
ED: ),
|
|
|
|
ED: # Program Header 2
|
|
|
|
ED: (('p_type', 0x00000001)
|
|
|
|
ED: ('p_flags', 0x00000006)
|
|
|
|
ED: ('p_offset', 0x00002000)
|
|
|
|
ED: ('p_vaddr', 0x00002000)
|
|
|
|
ED: ('p_paddr', 0x00002000)
|
2012-12-27 10:26:30 +08:00
|
|
|
ED: ('p_filesz', 0x00000104)
|
|
|
|
ED: ('p_memsz', 0x00000004)
|
|
|
|
ED: ('p_align', 0x00001000)
|
|
|
|
ED: ),
|
2013-02-08 04:33:55 +08:00
|
|
|
ED: # Program Header 3
|
2012-12-27 10:26:30 +08:00
|
|
|
ED: (('p_type', 0x00000001)
|
|
|
|
ED: ('p_flags', 0x00000006)
|
|
|
|
ED: ('p_offset', 0x00004000)
|
|
|
|
ED: ('p_vaddr', 0x00004000)
|
|
|
|
ED: ('p_paddr', 0x00004000)
|
|
|
|
ED: ('p_filesz', 0x00000004)
|
2013-02-08 04:16:12 +08:00
|
|
|
ED: ('p_memsz', 0x00004008)
|
2012-12-27 10:26:30 +08:00
|
|
|
ED: ('p_align', 0x00001000)
|
|
|
|
ED: ),
|
2013-01-26 07:23:24 +08:00
|
|
|
|
|
|
|
X86_64: vaddr 0x0000000000400000
|