aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Transforms/Utils/ModuleUtils.cpp
diff options
context:
space:
mode:
authorEvgeniy Stepanov <eugeni.stepanov@gmail.com>2017-04-27 20:27:23 +0000
committerEvgeniy Stepanov <eugeni.stepanov@gmail.com>2017-04-27 20:27:23 +0000
commit716f0ff2228a7f1117f4c8ad718225d6e303b212 (patch)
tree9971fb60604d0337aacdc7cffb3ce460af9183f1 /llvm/lib/Transforms/Utils/ModuleUtils.cpp
parentcdc549329fb843b02e568c2304759c34ee5317a8 (diff)
downloadllvm-716f0ff2228a7f1117f4c8ad718225d6e303b212.zip
llvm-716f0ff2228a7f1117f4c8ad718225d6e303b212.tar.gz
llvm-716f0ff2228a7f1117f4c8ad718225d6e303b212.tar.bz2
[asan] Put ctor/dtor in comdat.
When possible, put ASan ctor/dtor in comdat. The only reason not to is global registration, which can be TU-specific. This is not the case when there are no instrumented globals. This is also limited to ELF targets, because MachO does not have comdat, and COFF linkers may GC comdat constructors. The benefit of this is a lot less __asan_init() calls: one per DSO instead of one per TU. It's also necessary for the upcoming gc-sections-for-globals change on Linux, where multiple references to section start symbols trigger quadratic behaviour in gold linker. This is a second re-land of r298756. This time with a flag to disable the whole thing to avoid a bug in the gold linker: https://sourceware.org/bugzilla/show_bug.cgi?id=19002 llvm-svn: 301586
Diffstat (limited to 'llvm/lib/Transforms/Utils/ModuleUtils.cpp')
0 files changed, 0 insertions, 0 deletions