[llvm] r287111 - Add a little endian variant of TCE.
Pekka Jaaskelainen via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 16 07:22:24 PST 2016
Author: pjaaskel
Date: Wed Nov 16 09:22:23 2016
New Revision: 287111
URL: http://llvm.org/viewvc/llvm-project?rev=287111&view=rev
Log:
Add a little endian variant of TCE.
Modified:
llvm/trunk/include/llvm/ADT/Triple.h
llvm/trunk/lib/Support/Triple.cpp
Modified: llvm/trunk/include/llvm/ADT/Triple.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/ADT/Triple.h?rev=287111&r1=287110&r2=287111&view=diff
==============================================================================
--- llvm/trunk/include/llvm/ADT/Triple.h (original)
+++ llvm/trunk/include/llvm/ADT/Triple.h Wed Nov 16 09:22:23 2016
@@ -71,6 +71,7 @@ public:
sparcel, // Sparc: (endianness = little). NB: 'Sparcle' is a CPU variant
systemz, // SystemZ: s390x
tce, // TCE (http://tce.cs.tut.fi/): tce
+ tcele, // TCE little endian (http://tce.cs.tut.fi/): tcele
thumb, // Thumb (little endian): thumb, thumbv.*
thumbeb, // Thumb (big endian): thumbeb
x86, // X86: i[3-9]86
Modified: llvm/trunk/lib/Support/Triple.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Support/Triple.cpp?rev=287111&r1=287110&r2=287111&view=diff
==============================================================================
--- llvm/trunk/lib/Support/Triple.cpp (original)
+++ llvm/trunk/lib/Support/Triple.cpp Wed Nov 16 09:22:23 2016
@@ -46,6 +46,7 @@ StringRef Triple::getArchTypeName(ArchTy
case sparcel: return "sparcel";
case systemz: return "s390x";
case tce: return "tce";
+ case tcele: return "tcele";
case thumb: return "thumb";
case thumbeb: return "thumbeb";
case x86: return "i386";
@@ -274,6 +275,7 @@ Triple::ArchType Triple::getArchTypeForL
.Case("sparcv9", sparcv9)
.Case("systemz", systemz)
.Case("tce", tce)
+ .Case("tcele", tcele)
.Case("thumb", thumb)
.Case("thumbeb", thumbeb)
.Case("x86", x86)
@@ -391,6 +393,7 @@ static Triple::ArchType parseArch(String
.Case("sparcel", Triple::sparcel)
.Cases("sparcv9", "sparc64", Triple::sparcv9)
.Case("tce", Triple::tce)
+ .Case("tcele", Triple::tcele)
.Case("xcore", Triple::xcore)
.Case("nvptx", Triple::nvptx)
.Case("nvptx64", Triple::nvptx64)
@@ -632,6 +635,7 @@ static Triple::ObjectFormatType getDefau
case Triple::spir64:
case Triple::systemz:
case Triple::tce:
+ case Triple::tcele:
case Triple::thumbeb:
case Triple::wasm32:
case Triple::wasm64:
@@ -1155,6 +1159,7 @@ static unsigned getArchPointerBitWidth(l
case llvm::Triple::sparc:
case llvm::Triple::sparcel:
case llvm::Triple::tce:
+ case llvm::Triple::tcele:
case llvm::Triple::thumb:
case llvm::Triple::thumbeb:
case llvm::Triple::x86:
@@ -1237,6 +1242,7 @@ Triple Triple::get32BitArchVariant() con
case Triple::sparc:
case Triple::sparcel:
case Triple::tce:
+ case Triple::tcele:
case Triple::thumb:
case Triple::thumbeb:
case Triple::x86:
@@ -1278,6 +1284,7 @@ Triple Triple::get64BitArchVariant() con
case Triple::msp430:
case Triple::r600:
case Triple::tce:
+ case Triple::tcele:
case Triple::xcore:
case Triple::sparcel:
case Triple::shave:
@@ -1369,6 +1376,7 @@ Triple Triple::getBigEndianArchVariant()
T.setArch(UnknownArch);
break;
+ case Triple::tcele: T.setArch(Triple::tce); break;
case Triple::aarch64: T.setArch(Triple::aarch64_be); break;
case Triple::bpfel: T.setArch(Triple::bpfeb); break;
case Triple::mips64el:T.setArch(Triple::mips64); break;
@@ -1392,7 +1400,6 @@ Triple Triple::getLittleEndianArchVarian
case Triple::ppc:
case Triple::sparcv9:
case Triple::systemz:
- case Triple::tce:
// ARM is intentionally unsupported here, changing the architecture would
// drop any arch suffixes.
@@ -1401,6 +1408,7 @@ Triple Triple::getLittleEndianArchVarian
T.setArch(UnknownArch);
break;
+ case Triple::tce: T.setArch(Triple::tcele); break;
case Triple::aarch64_be: T.setArch(Triple::aarch64); break;
case Triple::bpfeb: T.setArch(Triple::bpfel); break;
case Triple::mips64: T.setArch(Triple::mips64el); break;
@@ -1447,6 +1455,7 @@ bool Triple::isLittleEndian() const {
case Triple::x86:
case Triple::x86_64:
case Triple::xcore:
+ case Triple::tcele:
case Triple::renderscript32:
case Triple::renderscript64:
return true;
More information about the llvm-commits
mailing list