From a11bf68f6c72cb024c2ce36db99c416ab312ec78 Mon Sep 17 00:00:00 2001 From: Daniel Sanders Date: Fri, 18 Jul 2014 14:28:19 +0000 Subject: [PATCH] Add MIPS Technologies to the vendors in llvm::Triple. This is a prerequisite for checking for 'mti' and 'img' in a consistent way in clang. Previously 'img' could use Triple::getVendor() but 'mti' could only use Triple::getVendorName(). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@213381 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/llvm/ADT/Triple.h | 1 + lib/Support/Triple.cpp | 2 ++ 2 files changed, 3 insertions(+) diff --git a/include/llvm/ADT/Triple.h b/include/llvm/ADT/Triple.h index 3d6f12c80e4..b96f1143552 100644 --- a/include/llvm/ADT/Triple.h +++ b/include/llvm/ADT/Triple.h @@ -105,6 +105,7 @@ public: Freescale, IBM, ImaginationTechnologies, + MipsTechnologies, NVIDIA, CSR }; diff --git a/lib/Support/Triple.cpp b/lib/Support/Triple.cpp index 25ddb7689d4..714d9e8f296 100644 --- a/lib/Support/Triple.cpp +++ b/lib/Support/Triple.cpp @@ -117,6 +117,7 @@ const char *Triple::getVendorTypeName(VendorType Kind) { case Freescale: return "fsl"; case IBM: return "ibm"; case ImaginationTechnologies: return "img"; + case MipsTechnologies: return "mti"; case NVIDIA: return "nvidia"; case CSR: return "csr"; } @@ -298,6 +299,7 @@ static Triple::VendorType parseVendor(StringRef VendorName) { .Case("fsl", Triple::Freescale) .Case("ibm", Triple::IBM) .Case("img", Triple::ImaginationTechnologies) + .Case("mti", Triple::MipsTechnologies) .Case("nvidia", Triple::NVIDIA) .Case("csr", Triple::CSR) .Default(Triple::UnknownVendor);