Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(31)

Unified Diff: src/IceTypes.h

Issue 395193005: Start processing function blocks in Subzero. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Fix nits in patch set 4. Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/IceTypes.h
diff --git a/src/IceTypes.h b/src/IceTypes.h
index 6bc2ded5ec63f8d9d388eef2cd14426a7a6b8928..813f7d705b485ae72e34103fa5c960c0d0e1b695 100644
--- a/src/IceTypes.h
+++ b/src/IceTypes.h
@@ -20,8 +20,14 @@
namespace Ice {
+enum TypeFlag {
+ // Define each flag as a power of 2, so that we can build flag bitsets.
+ TypeFlagIsInteger = 0x1,
+ TypeFlagIsFloating = 0x2
+};
+
enum Type {
-#define X(tag, size, align, elts, elty, str) tag,
+#define X(tag, size, align, elts, elty, str, flags) tag,
ICETYPE_TABLE
#undef X
IceType_NUM
@@ -46,6 +52,8 @@ size_t typeAlignInBytes(Type Ty);
size_t typeNumElements(Type Ty);
Type typeElementType(Type Ty);
+bool isIntegerType(Type Ty);
+bool isFloatingType(Type Ty);
inline bool isVectorType(Type Ty) { return typeNumElements(Ty) > 1; }
template <> Ostream &operator<<(class Ostream &Str, const Type &Ty);

Powered by Google App Engine
This is Rietveld 408576698