aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/IntrinsicLowering.cpp
diff options
context:
space:
mode:
authorEli Bendersky <eliben@chromium.org>2013-06-28 13:25:56 -0700
committerEli Bendersky <eliben@chromium.org>2013-06-28 13:25:56 -0700
commit331ef6ecbef4e3f3afa8ae627ad5b3528a534e04 (patch)
tree4440cd227f449d9d0ac0d7b97accab48a945876f /lib/CodeGen/IntrinsicLowering.cpp
parent46f7d96a210d9524fcb050a3e8bf5e0f65081442 (diff)
Revert the IntrinsicLowering logic that preserves externals for intrinsics.
This is no longer required, following our recent PNaCl ABI cleanups. BUG=None R=jvoung@chromium.org Review URL: https://codereview.chromium.org/18031017
Diffstat (limited to 'lib/CodeGen/IntrinsicLowering.cpp')
-rw-r--r--lib/CodeGen/IntrinsicLowering.cpp33
1 files changed, 0 insertions, 33 deletions
diff --git a/lib/CodeGen/IntrinsicLowering.cpp b/lib/CodeGen/IntrinsicLowering.cpp
index b094fa28e1..07f0ccf52f 100644
--- a/lib/CodeGen/IntrinsicLowering.cpp
+++ b/lib/CodeGen/IntrinsicLowering.cpp
@@ -92,39 +92,6 @@ static CallInst *ReplaceCallWith(const char *NewFn, CallInst *CI,
# define setjmp_undefined_for_msvc
#endif
-// @LOCALMOD-BEGIN
-// Calls to these functions may materialize as part of a conversion
-// from an intrinsic.
-// So if these functions are available in bitcode form we need to:
-// * make sure they do not get discarded -- if there is a chance that
-// a caller might materialize
-// * make sure they do not get specialized for a given callsite
-// Both problems are avoided by pretending there are unknown callers.
-// The function: IntrinsicLowering::AddPrototypes() below does just that.
-//
-// We are in the process of removing the need for this list.
-// Intrinsics that are truly supported will have versions of these
-// functions exported by native libs, so that they can be found.
-// Bitcode can then internalize symbols.
-static const char *IntrinsicNames[] = {
- NULL
-};
-
-StringSet<> IntrinsicLowering::FuncNames;
-
-const StringSet<> &IntrinsicLowering::GetFuncNames() {
- if (FuncNames.empty()) {
- for (unsigned i=0; IntrinsicNames[i]; ++i)
- FuncNames.insert(IntrinsicNames[i]);
- }
- return FuncNames;
-}
-
-bool IntrinsicLowering::IsCalledByIntrinsic(const StringRef &FuncName) {
- return IntrinsicLowering::GetFuncNames().count(FuncName) > 0;
-}
-// @LOCALMOD-END
-
void IntrinsicLowering::AddPrototypes(Module &M) {
LLVMContext &Context = M.getContext();
for (Module::iterator I = M.begin(), E = M.end(); I != E; ++I)