Add mips64 & mips64el to Triple. Patch by Liu with modifications.
[oota-llvm.git] / lib / VMCore / Type.cpp
index 51e6006eee419aaf727d167429344b654e5596a4..10184bc6f0e3a79719869d3db86c15c7ef10af77 100644 (file)
@@ -412,13 +412,6 @@ void StructType::setBody(ArrayRef<Type*> Elements, bool isPacked) {
   NumContainedTys = Elements.size();
 }
 
-StructType *StructType::createNamed(LLVMContext &Context, StringRef Name) {
-  StructType *ST = new (Context.pImpl->TypeAllocator) StructType(Context);
-  if (!Name.empty())
-    ST->setName(Name);
-  return ST;
-}
-
 void StructType::setName(StringRef Name) {
   if (Name == getName()) return;
 
@@ -487,7 +480,7 @@ StructType *StructType::get(Type *type, ...) {
 
 StructType *StructType::create(LLVMContext &Context, ArrayRef<Type*> Elements,
                                StringRef Name, bool isPacked) {
-  StructType *ST = createNamed(Context, Name);
+  StructType *ST = create(Context, Name);
   ST->setBody(Elements, isPacked);
   return ST;
 }
@@ -497,7 +490,7 @@ StructType *StructType::create(LLVMContext &Context, ArrayRef<Type*> Elements) {
 }
 
 StructType *StructType::create(LLVMContext &Context) {
-  return create(Context, ArrayRef<Type*>(), StringRef());
+  return create(Context, StringRef());
 }
 
 
@@ -528,36 +521,6 @@ StructType *StructType::create(StringRef Name, Type *type, ...) {
 }
 
 
-
-
-
-StructType *StructType::createNamed(LLVMContext &Context, StringRef Name,
-                                    ArrayRef<Type*> Elements, bool isPacked) {
-  StructType *ST = createNamed(Context, Name);
-  ST->setBody(Elements, isPacked);
-  return ST;
-}
-
-StructType *StructType::createNamed(StringRef Name, ArrayRef<Type*> Elements,
-                                    bool isPacked) {
-  assert(!Elements.empty() &&
-         "This method may not be invoked with an empty list");
-  return createNamed(Elements[0]->getContext(), Name, Elements, isPacked);
-}
-
-StructType *StructType::createNamed(StringRef Name, Type *type, ...) {
-  assert(type != 0 && "Cannot create a struct type with no elements with this");
-  LLVMContext &Ctx = type->getContext();
-  va_list ap;
-  SmallVector<llvm::Type*, 8> StructFields;
-  va_start(ap, type);
-  while (type) {
-    StructFields.push_back(type);
-    type = va_arg(ap, llvm::Type*);
-  }
-  return llvm::StructType::createNamed(Ctx, Name, StructFields);
-}
-
 StringRef StructType::getName() const {
   assert(!isLiteral() && "Literal structs never have names");
   if (SymbolTableEntry == 0) return StringRef();