Remove dead code.
authorEli Bendersky <eliben@google.com>
Wed, 15 May 2013 22:41:28 +0000 (22:41 +0000)
committerEli Bendersky <eliben@google.com>
Wed, 15 May 2013 22:41:28 +0000 (22:41 +0000)
This method is not being used/tested anywhere.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@181943 91177308-0d34-0410-b5e6-96231b3b80d8

include/llvm/IR/Module.h
lib/IR/Module.cpp

index cb500ffe7cb6a642b715b077c5e2fad7f5dad7a2..d414405818261089c1f566a67e410e0604ed4bc1 100644 (file)
@@ -340,10 +340,6 @@ public:
   Constant *getOrInsertFunction(StringRef Name, Type *RetTy, ...)
     END_WITH_NULL;
 
-  Constant *getOrInsertTargetIntrinsic(StringRef Name,
-                                       FunctionType *Ty,
-                                       AttributeSet AttributeList);
-
   /// getFunction - Look up the specified function in the module symbol table.
   /// If it does not exist, return null.
   Function *getFunction(StringRef Name) const;
index 8affcc94696044f9d42338249a7eedd47856880f..3f505aa3e095f4e7eec69553511ec52ada82316c 100644 (file)
@@ -168,23 +168,6 @@ Constant *Module::getOrInsertFunction(StringRef Name,
   return F;
 }
 
-Constant *Module::getOrInsertTargetIntrinsic(StringRef Name,
-                                             FunctionType *Ty,
-                                             AttributeSet AttributeList) {
-  // See if we have a definition for the specified function already.
-  GlobalValue *F = getNamedValue(Name);
-  if (F == 0) {
-    // Nope, add it
-    Function *New = Function::Create(Ty, GlobalVariable::ExternalLinkage, Name);
-    New->setAttributes(AttributeList);
-    FunctionList.push_back(New);
-    return New; // Return the new prototype.
-  }
-
-  // Otherwise, we just found the existing function or a prototype.
-  return F;
-}
-
 Constant *Module::getOrInsertFunction(StringRef Name,
                                       FunctionType *Ty) {
   return getOrInsertFunction(Name, Ty, AttributeSet());