mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-17 06:33:21 +00:00
Add the CSR company and the Kalimba DSP processor to Triple.
Patch by Matthew Gardiner with fixes by me. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@212745 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
282eda9b74
commit
b5a006e88f
@ -76,7 +76,8 @@ public:
|
||||
le32, // le32: generic little-endian 32-bit CPU (PNaCl / Emscripten)
|
||||
amdil, // amdil: amd IL
|
||||
spir, // SPIR: standard portable IR for OpenCL 32-bit version
|
||||
spir64 // SPIR: standard portable IR for OpenCL 64-bit version
|
||||
spir64, // SPIR: standard portable IR for OpenCL 64-bit version
|
||||
kalimba // Kalimba: generic kalimba
|
||||
};
|
||||
enum VendorType {
|
||||
UnknownVendor,
|
||||
@ -89,7 +90,8 @@ public:
|
||||
Freescale,
|
||||
IBM,
|
||||
ImaginationTechnologies,
|
||||
NVIDIA
|
||||
NVIDIA,
|
||||
CSR
|
||||
};
|
||||
enum OSType {
|
||||
UnknownOS,
|
||||
|
@ -50,6 +50,7 @@ const char *Triple::getArchTypeName(ArchType Kind) {
|
||||
case amdil: return "amdil";
|
||||
case spir: return "spir";
|
||||
case spir64: return "spir64";
|
||||
case kalimba: return "kalimba";
|
||||
}
|
||||
|
||||
llvm_unreachable("Invalid ArchType!");
|
||||
@ -101,6 +102,7 @@ const char *Triple::getArchTypePrefix(ArchType Kind) {
|
||||
case amdil: return "amdil";
|
||||
case spir: return "spir";
|
||||
case spir64: return "spir";
|
||||
case kalimba: return "kalimba";
|
||||
}
|
||||
}
|
||||
|
||||
@ -117,6 +119,7 @@ const char *Triple::getVendorTypeName(VendorType Kind) {
|
||||
case IBM: return "ibm";
|
||||
case ImaginationTechnologies: return "img";
|
||||
case NVIDIA: return "nvidia";
|
||||
case CSR: return "csr";
|
||||
}
|
||||
|
||||
llvm_unreachable("Invalid VendorType!");
|
||||
@ -208,6 +211,7 @@ Triple::ArchType Triple::getArchTypeForLLVMName(StringRef Name) {
|
||||
.Case("amdil", amdil)
|
||||
.Case("spir", spir)
|
||||
.Case("spir64", spir64)
|
||||
.Case("kalimba", kalimba)
|
||||
.Default(UnknownArch);
|
||||
}
|
||||
|
||||
@ -281,6 +285,7 @@ static Triple::ArchType parseArch(StringRef ArchName) {
|
||||
.Case("amdil", Triple::amdil)
|
||||
.Case("spir", Triple::spir)
|
||||
.Case("spir64", Triple::spir64)
|
||||
.Case("kalimba", Triple::kalimba)
|
||||
.Default(Triple::UnknownArch);
|
||||
}
|
||||
|
||||
@ -295,6 +300,7 @@ static Triple::VendorType parseVendor(StringRef VendorName) {
|
||||
.Case("ibm", Triple::IBM)
|
||||
.Case("img", Triple::ImaginationTechnologies)
|
||||
.Case("nvidia", Triple::NVIDIA)
|
||||
.Case("csr", Triple::CSR)
|
||||
.Default(Triple::UnknownVendor);
|
||||
}
|
||||
|
||||
@ -800,6 +806,7 @@ static unsigned getArchPointerBitWidth(llvm::Triple::ArchType Arch) {
|
||||
case llvm::Triple::x86:
|
||||
case llvm::Triple::xcore:
|
||||
case llvm::Triple::spir:
|
||||
case llvm::Triple::kalimba:
|
||||
return 32;
|
||||
|
||||
case llvm::Triple::arm64:
|
||||
@ -851,6 +858,7 @@ Triple Triple::get32BitArchVariant() const {
|
||||
case Triple::arm:
|
||||
case Triple::armeb:
|
||||
case Triple::hexagon:
|
||||
case Triple::kalimba:
|
||||
case Triple::le32:
|
||||
case Triple::mips:
|
||||
case Triple::mipsel:
|
||||
@ -885,6 +893,7 @@ Triple Triple::get64BitArchVariant() const {
|
||||
case Triple::arm:
|
||||
case Triple::armeb:
|
||||
case Triple::hexagon:
|
||||
case Triple::kalimba:
|
||||
case Triple::le32:
|
||||
case Triple::msp430:
|
||||
case Triple::r600:
|
||||
|
Loading…
x
Reference in New Issue
Block a user