summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Sanders <daniel.sanders@imgtec.com>2016-07-19 10:22:19 +0000
committerDaniel Sanders <daniel.sanders@imgtec.com>2016-07-19 10:22:19 +0000
commit2cb55d7dfdfbc92ce77705f5c31e629bb09b45bb (patch)
tree70353f242deb13d9addcf0fb48fc6e46b01c66db
parentbbe3860244468d2471ae9c1f69d738f3c148fed8 (diff)
downloadbcm5719-llvm-2cb55d7dfdfbc92ce77705f5c31e629bb09b45bb.tar.gz
bcm5719-llvm-2cb55d7dfdfbc92ce77705f5c31e629bb09b45bb.zip
[mips] Recognise the triple used by Debian stretch for mips64el.
Summary: The triple used for this distribution is mips64el-linux-gnuabi64. Reviewers: sdardis Subscribers: sdardis, llvm-commits Differential Revision: https://reviews.llvm.org/D22406 llvm-svn: 275966
-rw-r--r--llvm/include/llvm/ADT/Triple.h6
-rw-r--r--llvm/lib/Support/Triple.cpp2
2 files changed, 6 insertions, 2 deletions
diff --git a/llvm/include/llvm/ADT/Triple.h b/llvm/include/llvm/ADT/Triple.h
index 47813049d2f..b98f8407d07 100644
--- a/llvm/include/llvm/ADT/Triple.h
+++ b/llvm/include/llvm/ADT/Triple.h
@@ -174,6 +174,7 @@ public:
UnknownEnvironment,
GNU,
+ GNUABI64,
GNUEABI,
GNUEABIHF,
GNUX32,
@@ -476,8 +477,9 @@ public:
bool isGNUEnvironment() const {
EnvironmentType Env = getEnvironment();
- return Env == Triple::GNU || Env == Triple::GNUEABI ||
- Env == Triple::GNUEABIHF || Env == Triple::GNUX32;
+ return Env == Triple::GNU || Env == Triple::GNUABI64 ||
+ Env == Triple::GNUEABI || Env == Triple::GNUEABIHF ||
+ Env == Triple::GNUX32;
}
/// Checks if the environment could be MSVC.
diff --git a/llvm/lib/Support/Triple.cpp b/llvm/lib/Support/Triple.cpp
index cfa12a9f0b2..2bac2a31067 100644
--- a/llvm/lib/Support/Triple.cpp
+++ b/llvm/lib/Support/Triple.cpp
@@ -201,6 +201,7 @@ const char *Triple::getEnvironmentTypeName(EnvironmentType Kind) {
switch (Kind) {
case UnknownEnvironment: return "unknown";
case GNU: return "gnu";
+ case GNUABI64: return "gnuabi64";
case GNUEABIHF: return "gnueabihf";
case GNUEABI: return "gnueabi";
case GNUX32: return "gnux32";
@@ -468,6 +469,7 @@ static Triple::EnvironmentType parseEnvironment(StringRef EnvironmentName) {
return StringSwitch<Triple::EnvironmentType>(EnvironmentName)
.StartsWith("eabihf", Triple::EABIHF)
.StartsWith("eabi", Triple::EABI)
+ .StartsWith("gnuabi64", Triple::GNUABI64)
.StartsWith("gnueabihf", Triple::GNUEABIHF)
.StartsWith("gnueabi", Triple::GNUEABI)
.StartsWith("gnux32", Triple::GNUX32)
OpenPOWER on IntegriCloud