2013-01-26 07:23:24 +08:00
|
|
|
RUN: lld-core -reader ELF -writer ELF -o %t1 %p/Inputs/phdr.i386 | elf-dump %t1 | FileCheck -check-prefix=ED %s
|
|
|
|
|
|
|
|
RUN: lld -core -target x86_64-linux -output=%t1 %p/Inputs/relocs.x86-64 \
|
|
|
|
RUN: && llvm-objdump -p %t1 | FileCheck %s -check-prefix=X86_64
|
2012-11-22 05:07:36 +08:00
|
|
|
|
2012-12-27 10:26:30 +08:00
|
|
|
ED: # Program Header 0
|
|
|
|
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)
|
|
|
|
ED: ('p_flags', 0x00000006)
|
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)
|
|
|
|
ED: ('p_filesz', 0x00000104)
|
|
|
|
ED: ('p_memsz', 0x00000004)
|
|
|
|
ED: ('p_align', 0x00001000)
|
|
|
|
ED: ),
|
|
|
|
ED: # Program Header 2
|
|
|
|
ED: (('p_type', 0x00000001)
|
|
|
|
ED: ('p_flags', 0x00000006)
|
|
|
|
ED: ('p_offset', 0x00004000)
|
|
|
|
ED: ('p_vaddr', 0x00004000)
|
|
|
|
ED: ('p_paddr', 0x00004000)
|
|
|
|
ED: ('p_filesz', 0x00000004)
|
|
|
|
ED: ('p_memsz', 0x00004005)
|
|
|
|
ED: ('p_align', 0x00001000)
|
|
|
|
ED: ),
|
|
|
|
ED: # Program Header 3
|
|
|
|
ED: (('p_type', 0x00000001)
|
|
|
|
ED: ('p_flags', 0x00000004)
|
|
|
|
ED: ('p_offset', 0x00005000)
|
|
|
|
ED: ('p_vaddr', 0x00009000)
|
|
|
|
ED: ('p_paddr', 0x00009000)
|
|
|
|
ED: ('p_filesz', 0x0000008c)
|
|
|
|
ED: ('p_memsz', 0x0000008c)
|
|
|
|
ED: ('p_align', 0x00001000)
|
|
|
|
ED: ),
|
2013-01-26 07:23:24 +08:00
|
|
|
|
|
|
|
X86_64: vaddr 0x0000000000400000
|