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

Unified Diff: src/IceTypes.h

Issue 205613002: Initial skeleton of Subzero. (Closed) Base URL: https://gerrit.chromium.org/gerrit/p/native_client/pnacl-subzero.git@master
Patch Set: Use non-anonymous structs so that array_lengthof works Created 6 years, 8 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
« no previous file with comments | « src/IceOperand.cpp ('k') | src/IceTypes.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/IceTypes.h
diff --git a/src/IceTypes.h b/src/IceTypes.h
new file mode 100644
index 0000000000000000000000000000000000000000..b3d28c3714884734f1ae9bc814282812da8e2ed1
--- /dev/null
+++ b/src/IceTypes.h
@@ -0,0 +1,36 @@
+//===- subzero/src/IceTypes.h - Primitive ICE types -------------*- C++ -*-===//
+//
+// The Subzero Code Generator
+//
+// This file is distributed under the University of Illinois Open Source
+// License. See LICENSE.TXT for details.
+//
+//===----------------------------------------------------------------------===//
+//
+// This file declares a few properties of the primitive types allowed
+// in Subzero. Every Subzero source file is expected to include
+// IceTypes.h.
+//
+//===----------------------------------------------------------------------===//
+
+#ifndef SUBZERO_SRC_ICETYPES_H
+#define SUBZERO_SRC_ICETYPES_H
+
+#include "IceTypes.def"
+
+namespace Ice {
+
+enum Type {
+#define X(tag, size, align, str) tag,
+ ICETYPE_TABLE
+#undef X
+};
+
+size_t typeWidthInBytes(Type Ty);
+size_t typeAlignInBytes(Type Ty);
+
+template <> Ostream &operator<<(class Ostream &Str, const Type &Ty);
+
+} // end of namespace Ice
+
+#endif // SUBZERO_SRC_ICETYPES_H
« no previous file with comments | « src/IceOperand.cpp ('k') | src/IceTypes.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698