[PATCH] D21849: [AMDGPU] Add metadata for runtime

Nikolay Haustov via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 14 05:58:52 PDT 2016


nhaustov added a subscriber: nhaustov.
nhaustov requested changes to this revision.
nhaustov added a reviewer: nhaustov.
This revision now requires changes to proceed.

================
Comment at: lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp:927
@@ +926,3 @@
+    emitRuntimeMDIntValue(OutStreamer, RuntimeMD::KeyArgValueType,
+                          getRuntimeMDValueType(T, BaseTypeName), 2);
+
----------------
DataType enum is defined as char, but here 2 bytes are used.

================
Comment at: lib/Target/AMDGPU/AMDGPURuntimeMetadata.h:98
@@ +97,3 @@
+
+  enum LanguageVersion {
+    V100          = 100,
----------------
Are these OpenCL versions? Enum here seems to be overly restricting. Can this field just be a short integer?

================
Comment at: lib/Target/AMDGPU/AMDGPURuntimeMetadata.h:115
@@ +114,3 @@
+
+    enum DataType : char {
+      Struct  = 0,
----------------
Change to ValueType?

================
Comment at: lib/Target/AMDGPU/AMDGPURuntimeMetadata.h:130
@@ +129,3 @@
+
+    enum TypeQualifier : char {
+      Const    = 1,
----------------
This can be now removed.


https://reviews.llvm.org/D21849





More information about the llvm-commits mailing list