summaryrefslogtreecommitdiffstats
path: root/lld/lib/ReaderWriter/PECOFF/LinkerGeneratedSymbolFile.cpp
diff options
context:
space:
mode:
authorRui Ueyama <ruiu@google.com>2015-08-06 16:19:35 +0000
committerRui Ueyama <ruiu@google.com>2015-08-06 16:19:35 +0000
commit251b0e268bef44159ad6916b972ba9c74ce51384 (patch)
tree841faf6ee22c2de7a7faed3f9dd81cd33f691d62 /lld/lib/ReaderWriter/PECOFF/LinkerGeneratedSymbolFile.cpp
parentf77e909f0a19ffd3223e1afef14c4afa5959197a (diff)
downloadbcm5719-llvm-251b0e268bef44159ad6916b972ba9c74ce51384.tar.gz
bcm5719-llvm-251b0e268bef44159ad6916b972ba9c74ce51384.zip
COFF: Remove the old COFF linker and make link an alias to link2.
It's time to remove old COFF linker because the new one is now complete. llvm-svn: 244226
Diffstat (limited to 'lld/lib/ReaderWriter/PECOFF/LinkerGeneratedSymbolFile.cpp')
-rw-r--r--lld/lib/ReaderWriter/PECOFF/LinkerGeneratedSymbolFile.cpp48
1 files changed, 0 insertions, 48 deletions
diff --git a/lld/lib/ReaderWriter/PECOFF/LinkerGeneratedSymbolFile.cpp b/lld/lib/ReaderWriter/PECOFF/LinkerGeneratedSymbolFile.cpp
deleted file mode 100644
index a11410784b8..00000000000
--- a/lld/lib/ReaderWriter/PECOFF/LinkerGeneratedSymbolFile.cpp
+++ /dev/null
@@ -1,48 +0,0 @@
-//===- lib/ReaderWriter/PECOFF/LinkerGeneratedSymbolFile.cpp --------------===//
-//
-// The LLVM Linker
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-#include "LinkerGeneratedSymbolFile.h"
-
-namespace lld {
-namespace pecoff {
-
-// Find decorated symbol, namely /sym@[0-9]+/ or /\?sym@@.+/.
-bool findDecoratedSymbol(PECOFFLinkingContext *ctx,
- std::string sym, std::string &res) {
- const std::set<std::string> &defined = ctx->definedSymbols();
- // Search for /sym@[0-9]+/
- {
- std::string s = sym + '@';
- auto it = defined.lower_bound(s);
- for (auto e = defined.end(); it != e; ++it) {
- if (!StringRef(*it).startswith(s))
- break;
- if (it->size() == s.size())
- continue;
- StringRef suffix = StringRef(*it).substr(s.size());
- if (suffix.find_first_not_of("0123456789") != StringRef::npos)
- continue;
- res = *it;
- return true;
- }
- }
- // Search for /\?sym@@.+/
- {
- std::string s = "?" + ctx->undecorateSymbol(sym).str() + "@@";
- auto it = defined.lower_bound(s);
- if (it != defined.end() && StringRef(*it).startswith(s)) {
- res = *it;
- return true;
- }
- }
- return false;
-}
-
-} // namespace pecoff
-} // namespace lld
OpenPOWER on IntegriCloud