summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST/Decl.cpp
diff options
context:
space:
mode:
authorTeresa Johnson <tejohnson@google.com>2015-11-10 21:09:06 +0000
committerTeresa Johnson <tejohnson@google.com>2015-11-10 21:09:06 +0000
commit2d5fb8cac4ec7b6f763c6f91b52f6a954ad99942 (patch)
tree0def0e94c9a600926ff70b62935510dd70b15395 /clang/lib/AST/Decl.cpp
parent6db4640b801f1d749495e20d77f9129196ac8686 (diff)
downloadbcm5719-llvm-2d5fb8cac4ec7b6f763c6f91b52f6a954ad99942.tar.gz
bcm5719-llvm-2d5fb8cac4ec7b6f763c6f91b52f6a954ad99942.zip
Ensure ModuleLinker materializes complete comdat groups
Summary: The module linker lazy links some "discardable if unused" global values (e.g. linkonce), materializing and linking them only if they are referenced in the module. If a comdat group contains a linkonce member that is not referenced, however, it would not be materialized and linked, leading to an incomplete comdat group. If there are other object files not part of the same LTO link that also define and use that comdat group, the linker may select the incomplete group leading to link time unsats. To solve this, whenever a global value body is linked, make sure we materialize any other members of the same comdat group that are not yet materialized. This ensures they are in the lazy link list and get linked as well. Added new test and adjusted old test to remove parts that didn't make sense with fix. Reviewers: rafael Subscribers: dexonsmith, davidxl, llvm-commits Differential Revision: http://reviews.llvm.org/D14516 llvm-svn: 252647
Diffstat (limited to 'clang/lib/AST/Decl.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud