New pass to make internal linkage symbol names unique.
authorSriraman Tallam <tmsriram@google.com>
Mon, 20 Apr 2020 21:41:30 +0000 (14:41 -0700)
committerSriraman Tallam <tmsriram@google.com>
Mon, 20 Apr 2020 22:05:22 +0000 (15:05 -0700)
commit365b60fc9371209f855d89f5d08c3f5ea9400711
treef113cf6fbef0dd6b0968463e81b0e4a37a43898d
parenta9b137f9ffba8cb25dfd7dd1fb613e8aac121b37
New pass to make internal linkage symbol names unique.

With clang option -funique-internal-linkage-symbols, symbols with
internal linkage get names with the module hash appended.

Differential Revision: https://reviews.llvm.org/D78243
llvm/include/llvm/InitializePasses.h
llvm/include/llvm/Transforms/Utils.h
llvm/include/llvm/Transforms/Utils/UniqueInternalLinkageNames.h [new file with mode: 0644]
llvm/lib/Transforms/Utils/CMakeLists.txt
llvm/lib/Transforms/Utils/UniqueInternalLinkageNames.cpp [new file with mode: 0644]
llvm/lib/Transforms/Utils/Utils.cpp
llvm/test/Transforms/UniqueInternalLinkageNames/unique_symbol_names.ll [new file with mode: 0644]
llvm/utils/gn/secondary/llvm/lib/Transforms/Utils/BUILD.gn