[PATCH] D28498: [asan] Make ASan compatible with linker dead stripping on Linux.

Mehdi AMINI via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 17 15:14:48 PST 2017

mehdi_amini added inline comments.

Comment at: lib/CodeGen/TargetLoweringObjectFileImpl.cpp:228
+  if (SectionName == "asan_globals") {
+    Flags |= ELF::SHF_ASSOCIATED;
pcc wrote:
> Should this be testing a new flag on GlobalObject, rather than the section name?
> Also, do we need to teach globaldce about this?
MachO version is using `llvm.compiler.used` to avoid having to teach GlobalDCE and other part of LLVM about a special section semantics.



More information about the llvm-commits mailing list