[PATCH] D134070: [lld-macho] Implement --icf=fbsafe that is more similar to ld64's -deduplicate_safe
Jez Ng via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 16 12:53:53 PDT 2022
int3 created this revision.
int3 added reviewers: lld-macho, kyulee.
Herald added a reviewer: ributzka.
Herald added projects: lld-macho, All.
int3 requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
`--icf=safe` gives us results that are way too conservative. Ideally
we'd like to fix that, but it's probably non-trivial, and would affect
ELF targets too (since the logic to mark things as address-significant
in MC isn't arch-specific).
As such, this diff implements an approach that is very similar to what
is currently available in ld64.
Test Plan:
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D134070
Files:
lld/MachO/Config.h
lld/MachO/Driver.cpp
lld/MachO/ICF.cpp
lld/MachO/ICF.h
lld/test/FBMachO/icf-fbsafe.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D134070.460861.patch
Type: text/x-patch
Size: 3992 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220916/5cd9e686/attachment.bin>
More information about the llvm-commits
mailing list