-oformat output-format
`-oformat' option can be used to specify the binary format for the output object file.
Patch implements binary format output type.
Paths
| Differential D23769
[ELF] - Implemented --oformat binary option. ClosedPublic Authored by grimar on Aug 22 2016, 7:29 AM.
Details Summary -oformat output-format Patch implements binary format output type.
Diff Detail Event TimelineComment Actions For reference https://reviews.freebsd.org/D7409 is the proposed FreeBSD change to switch to a linker script for the boot components (and make use of --oformat binary). Comment Actions
As I mentioned earlier in llvm-mails, gold implementation is differs with ld for --oformat binary. I am looking on sys/boot/i386/boot.ldscript at the page you posted and see the next lines: SECTIONS { . = 0x08048000 + SIZEOF_HEADERS; That means that gold will produce output > 128mb while gnu ld will do the same layout as this patch do and output will depend only on size of sections. I just re-checked this using stub files: .text .globl _start _start: test.script: SECTIONS { . = 0x08048000 + SIZEOF_HEADERS; .text : { *(.text*) } } llvm-mc -filetype=obj -triple=x86_64-pc-linux test.s -o test.o So I think that means this patch do what is expected.
Comment Actions
ruiu edited edge metadata. Comment ActionsLGTM. Thank you for doing this!
This revision is now accepted and ready to land.Aug 25 2016, 1:22 AM Closed by commit rL279726: [ELF] - Implemented --oformat binary option. (authored by grimar). · Explain WhyAug 25 2016, 2:13 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 68857 ELF/Config.h
ELF/Driver.cpp
ELF/Options.td
ELF/Writer.cpp
test/ELF/oformat-binary.s
|
Remove = false.