[PATCH] D96757: [InstrProfiling] Use ELF section groups for counters, data and values
David Li via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Feb 16 11:36:31 PST 2021
davidxl added inline comments.
================
Comment at: llvm/lib/Transforms/Instrumentation/InstrProfiling.cpp:833
auto MaybeSetComdat = [=](GlobalVariable *GV) {
- if (NeedComdat)
+ if (NeedComdat) {
GV->setComdat(M->getOrInsertComdat(TT.isOSBinFormatCOFF() ? GV->getName()
----------------
maybe this:
bool UseSectGroup = (NeedComdat || TT.isOSBinFormatELF());
if (UseSectGroup) {
auto GroupName = ..
Comdat *C = M->getOrInsertComdat(GroupName);
if (!NeedComdat)
C->setSelectionKind(Comdat::NoDuplicates);
GV->setComdat(C);
}
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D96757/new/
https://reviews.llvm.org/D96757
More information about the llvm-commits
mailing list