[PATCH] Add 'shave' processor name to Triple
Douglas Katzman
dougk at google.com
Fri Jun 12 11:05:52 PDT 2015
http://reviews.llvm.org/D10413
Files:
include/llvm/ADT/Triple.h
lib/Support/Triple.cpp
Index: include/llvm/ADT/Triple.h
===================================================================
--- include/llvm/ADT/Triple.h
+++ include/llvm/ADT/Triple.h
@@ -84,7 +84,8 @@
spir, // SPIR: standard portable IR for OpenCL 32-bit version
spir64, // SPIR: standard portable IR for OpenCL 64-bit version
kalimba, // Kalimba: generic kalimba
- LastArchType = kalimba
+ shave, // SHAVE: Movidius SoC
+ LastArchType = shave
};
enum SubArchType {
NoSubArch,
Index: lib/Support/Triple.cpp
===================================================================
--- lib/Support/Triple.cpp
+++ lib/Support/Triple.cpp
@@ -59,6 +59,7 @@
case spir: return "spir";
case spir64: return "spir64";
case kalimba: return "kalimba";
+ case shave: return "shave";
}
llvm_unreachable("Invalid ArchType!");
@@ -120,6 +121,7 @@
case spir:
case spir64: return "spir";
case kalimba: return "kalimba";
+ case shave: return "shave";
}
}
@@ -252,6 +254,7 @@
.Case("spir", spir)
.Case("spir64", spir64)
.Case("kalimba", kalimba)
+ .Case("shave", shave)
.Default(UnknownArch);
}
@@ -356,6 +359,7 @@
.Case("spir", Triple::spir)
.Case("spir64", Triple::spir64)
.StartsWith("kalimba", Triple::kalimba)
+ .Case("shave", Triple::shave)
.Default(Triple::UnknownArch);
}
@@ -1004,6 +1008,7 @@
case llvm::Triple::hsail:
case llvm::Triple::spir:
case llvm::Triple::kalimba:
+ case llvm::Triple::shave:
return 32;
case llvm::Triple::aarch64:
@@ -1075,6 +1080,7 @@
case Triple::thumbeb:
case Triple::x86:
case Triple::xcore:
+ case Triple::shave:
// Already 32-bit.
break;
@@ -1107,6 +1113,7 @@
case Triple::thumbeb:
case Triple::xcore:
case Triple::sparcel:
+ case Triple::shave:
T.setArch(UnknownArch);
break;
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D10413.27585.patch
Type: text/x-patch
Size: 1910 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150612/df179b3f/attachment.bin>
More information about the llvm-commits
mailing list