[PATCH] D129401: [libLTO] Set data-sections by default in libLTO for ELF and XCOFF.
Quinn Pham via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 11 07:55:52 PDT 2022
quinnp added inline comments.
================
Comment at: llvm/lib/LTO/LTOCodeGenerator.cpp:351
+ llvm::Triple::ObjectFormatType ObjectFormat = Triple.getObjectFormat();
+ if (!codegen::getExplicitDataSections() &&
+ (ObjectFormat == llvm::Triple::ObjectFormatType::ELF ||
----------------
w2yehia wrote:
> any reason we do this for ELF and XCOFF only?
I don't think there is a particular reason that we do this for ELF and XCOFF only. We needed this fixed for `AIX` (`XCOFF`) and wanted to change `Linux` (`ELF`) to match the behaviour of `lld`/`gold` at the same time. I'm not sure what other file formats need for this so I did not include them.
@hubert.reinterpretcast might have a better answer for this.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D129401/new/
https://reviews.llvm.org/D129401
More information about the llvm-commits
mailing list