[PATCH] D32064: [asan] Disable ASan global-GC depending on the target and compiler flags
Evgeniy Stepanov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Apr 17 14:50:48 PDT 2017
eugenis added inline comments.
================
Comment at: lib/Driver/SanitizerArgs.cpp:636
+ case llvm::Triple::COFF:
+ return DataSections;
+ case llvm::Triple::ELF:
----------------
rnk wrote:
> We can return true for COFF here. By adding a comdat during asan instrumentation, we effectively implement -fdata-sections ourselves. If the user really wanted -fno-data-sections for some reason, they're out of luck right now.
What do you mean by "out of luck", will it break compilation?
Because the point of this change is not to enable data-sections unless asked by the user. Data sections greatly inflate ELF object file size (not sure how big is the effect on COFF) and we should not do that by default.
Repository:
rL LLVM
https://reviews.llvm.org/D32064
More information about the cfe-commits
mailing list