[PATCH] D130125: [lld-macho] Fold __objc_imageinfo sections
Jez Ng via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 19 14:33:57 PDT 2022
int3 created this revision.
int3 added a reviewer: lld-macho.
Herald added projects: lld-macho, All.
int3 requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Previously, we treated it as a regular ConcatInputSection. However, ld64
actually parses its contents and uses that to synthesize a single image
info struct, generating one 8-byte section instead of `8 * number of
object files`.
I'm not entirely sure what impact this section has on the runtime, so I
just tried to follow ld64's semantics as closely as possible in this
diff. My main motivation though was to reduce binary size.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D130125
Files:
lld/MachO/Driver.cpp
lld/MachO/SyntheticSections.cpp
lld/MachO/SyntheticSections.h
lld/MachO/Writer.cpp
lld/test/MachO/objc-imageinfo.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D130125.445946.patch
Type: text/x-patch
Size: 12672 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220719/25656e35/attachment.bin>
More information about the llvm-commits
mailing list